com.tensegrity.palowebviewer.modules.engine.client
Class PaloServerModelProxy

java.lang.Object
  extended by com.tensegrity.palowebviewer.modules.engine.client.PaloServerModelProxy
All Implemented Interfaces:
IPaloServerModel
Direct Known Subclasses:
PaloServerModelLogger

public class PaloServerModelProxy
extends java.lang.Object
implements IPaloServerModel


Constructor Summary
PaloServerModelProxy(IPaloServerModel paloServerModel)
           
 
Method Summary
 void addListener(IPaloServerModelListener listener)
          Add listener for the palo server model.
 void checkAndSave(XView view, ICallback callback)
           
 void checkElement(XDimension dim, XElement element, IVerificationCallback callback)
           
 void checkElement(XSubset subset, XElement element, IVerificationCallback callback)
           
 void clear()
          Clears the root of the model and notifies listeners(IPaloServerModelListener.modelChanged()).
 XElement getElement(XDimension dimension, XElement element)
           
 XFolder getFavoriteViewsRoot()
           
 XObject getObject(XPath path)
           
protected  IPaloServerModel getPaloServerModel()
           
 XRoot getRoot()
          Returns root of the server.
 boolean isObjectValid(XObject object)
          checks if the object belongs to actual model
 boolean isOn()
          Tells whether this model is on.
 boolean isUpdatingHierarchy()
           
 void loadChildren(XObject object, int type)
           
 void loadDefaultView(XCube cube)
           
 void loadFavoriteViews()
           
 void loadPath(XObject hierarchyRoot, XElement element, IElementPathCallback callback)
           
 void loadView(java.lang.String[] path, ILoadViewCallback callback)
           
 void loadView(XViewLink link, ILoadViewCallback callback)
           
 void query(XQueryPath[] queries, IQueryCallback callback)
           
 void reloadSubTree(XObject obejct)
           
 void reloadTree()
           
 void removeListener(IPaloServerModelListener listener)
          Remove listener for the palo server model.
 void saveView(XView view, ICallback callback)
           
 java.lang.String toString()
           
 void turnOff()
          Turns off the model.
 void turnOn()
          Turns on the model.
 void updateCell(XPath cube, IXPoint point, IResultElement value, ICellUpdateCallback callback)
          Updates value pointed by path.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

PaloServerModelProxy

public PaloServerModelProxy(IPaloServerModel paloServerModel)
Method Detail

getPaloServerModel

protected IPaloServerModel getPaloServerModel()

addListener

public void addListener(IPaloServerModelListener listener)
Description copied from interface: IPaloServerModel
Add listener for the palo server model.

Specified by:
addListener in interface IPaloServerModel
Parameters:
listener - - listener to add.

checkElement

public void checkElement(XDimension dim,
                         XElement element,
                         IVerificationCallback callback)
Specified by:
checkElement in interface IPaloServerModel

checkElement

public void checkElement(XSubset subset,
                         XElement element,
                         IVerificationCallback callback)
Specified by:
checkElement in interface IPaloServerModel

clear

public void clear()
Description copied from interface: IPaloServerModel
Clears the root of the model and notifies listeners(IPaloServerModelListener.modelChanged()).

Specified by:
clear in interface IPaloServerModel

getElement

public XElement getElement(XDimension dimension,
                           XElement element)
Specified by:
getElement in interface IPaloServerModel

getObject

public XObject getObject(XPath path)
Specified by:
getObject in interface IPaloServerModel

getRoot

public XRoot getRoot()
Description copied from interface: IPaloServerModel
Returns root of the server. So we can ask for other things on it.

Specified by:
getRoot in interface IPaloServerModel

isObjectValid

public boolean isObjectValid(XObject object)
Description copied from interface: IPaloServerModel
checks if the object belongs to actual model

Specified by:
isObjectValid in interface IPaloServerModel

isOn

public boolean isOn()
Description copied from interface: IPaloServerModel
Tells whether this model is on.

Specified by:
isOn in interface IPaloServerModel

loadChildren

public void loadChildren(XObject object,
                         int type)
Specified by:
loadChildren in interface IPaloServerModel

loadDefaultView

public void loadDefaultView(XCube cube)
Specified by:
loadDefaultView in interface IPaloServerModel

loadPath

public void loadPath(XObject hierarchyRoot,
                     XElement element,
                     IElementPathCallback callback)
Specified by:
loadPath in interface IPaloServerModel

query

public void query(XQueryPath[] queries,
                  IQueryCallback callback)
Specified by:
query in interface IPaloServerModel

reloadSubTree

public void reloadSubTree(XObject obejct)
Specified by:
reloadSubTree in interface IPaloServerModel

reloadTree

public void reloadTree()
Specified by:
reloadTree in interface IPaloServerModel

removeListener

public void removeListener(IPaloServerModelListener listener)
Description copied from interface: IPaloServerModel
Remove listener for the palo server model.

Specified by:
removeListener in interface IPaloServerModel
Parameters:
listener - - listener to remove.

saveView

public void saveView(XView view,
                     ICallback callback)
Specified by:
saveView in interface IPaloServerModel

turnOff

public void turnOff()
Description copied from interface: IPaloServerModel
Turns off the model. Turns off the model, so it can not be used to communicate with server. Call to #loadObject will be ignored.

Specified by:
turnOff in interface IPaloServerModel

turnOn

public void turnOn()
Description copied from interface: IPaloServerModel
Turns on the model. Turns on the model, so it can be used to communicate with server.

Specified by:
turnOn in interface IPaloServerModel

updateCell

public void updateCell(XPath cube,
                       IXPoint point,
                       IResultElement value,
                       ICellUpdateCallback callback)
Description copied from interface: IPaloServerModel
Updates value pointed by path. Callback is invoked if update successed

Specified by:
updateCell in interface IPaloServerModel
callback - - can be null

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

checkAndSave

public void checkAndSave(XView view,
                         ICallback callback)
Specified by:
checkAndSave in interface IPaloServerModel

isUpdatingHierarchy

public boolean isUpdatingHierarchy()
Specified by:
isUpdatingHierarchy in interface IPaloServerModel

getFavoriteViewsRoot

public XFolder getFavoriteViewsRoot()
Specified by:
getFavoriteViewsRoot in interface IPaloServerModel

loadFavoriteViews

public void loadFavoriteViews()
Specified by:
loadFavoriteViews in interface IPaloServerModel

loadView

public void loadView(XViewLink link,
                     ILoadViewCallback callback)
Specified by:
loadView in interface IPaloServerModel

loadView

public void loadView(java.lang.String[] path,
                     ILoadViewCallback callback)
Specified by:
loadView in interface IPaloServerModel