org.gcube.portlets.user.results.client.model
Class Model

java.lang.Object
  extended by org.gcube.portlets.user.results.client.model.Model

public class Model
extends Object

The Model class represents the current application state in the MVC pattern

Version:
January 2009 (0.1)
Author:
Massimiliano Assante, ISTI-CNR - massimiliano.assante@isti.cnr.it

Field Summary
static Model singleton
           
 
Constructor Summary
Model(Controller controller)
           
 
Method Summary
static Model get()
           
 BasketModel getBasketModel()
           
 ResultsetServiceAsync getResultService()
           
 void getResultsFromSearchService(int mode)
          Look in the session if there are results, if so display them.
 void getResultsFromSession()
          Look in the session if there are results, if so display them.
 void loadResults()
          This method is called if the user has not searched per collection
 void setBasketModel(BasketModel basketModel)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

singleton

public static Model singleton
Constructor Detail

Model

public Model(Controller controller)
Parameters:
controller -
Method Detail

get

public static Model get()
Returns:
.

loadResults

public void loadResults()
This method is called if the user has not searched per collection


getResultsFromSession

public void getResultsFromSession()
Look in the session if there are results, if so display them. if not display no results were found


getResultsFromSearchService

public void getResultsFromSearchService(int mode)
Look in the session if there are results, if so display them. if not display no results were found

Parameters:
mode - if mode == 0 get the first record of the resultset, mode == 1 get the previous, mode = 2 get the next

getResultService

public ResultsetServiceAsync getResultService()

getBasketModel

public BasketModel getBasketModel()

setBasketModel

public void setBasketModel(BasketModel basketModel)


Copyright © 2013. All Rights Reserved.