com.sibvisions.rad.model.remote
Class RemoteDataSource

java.lang.Object
  extended by com.sibvisions.rad.model.mem.MemDataSource
      extended by com.sibvisions.rad.model.remote.RemoteDataSource
All Implemented Interfaces:
IDataSource

public class RemoteDataSource
extends MemDataSource

The RemoteDataSource is a remote DataSource for all RemoteDataBook's, which uses a connection to the server to forward the storage operation to server objects.

See Also:
RemoteDataBook, MemDataSource

Constructor Summary
RemoteDataSource()
          It constructs a new RemoteDataSource.
RemoteDataSource(AbstractConnection pConnection)
          It constructs a new RemoteDataSource with the given AbstractConnection.
 
Method Summary
 AbstractConnection getConnection()
          Returns the AbstractConnection to the server IStorage object.
static MetaData getMetaData(String pKey)
          Returns the column meta data from the client cache.
 void open()
          It opens the IDataSource.
static void putMetaData(String pKey, MetaData pMetaData)
          Puts the column meta data to the client cache.
 void setConnection(AbstractConnection pConnection)
          Sets the AbstractConnection to the server IStorage object.
 
Methods inherited from class com.sibvisions.rad.model.mem.MemDataSource
addDataBook, close, finalize, getDataBooks, getWritebackIsolationLevel, isOpen, reloadAllDataBooks, removeDataBook, restoreAllDataBooks, saveAllDataBooks, setWritebackIsolationLevel, toString
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

RemoteDataSource

public RemoteDataSource()
It constructs a new RemoteDataSource.


RemoteDataSource

public RemoteDataSource(AbstractConnection pConnection)
It constructs a new RemoteDataSource with the given AbstractConnection.

Parameters:
pConnection - the AbstractConnection to use for the communication to the server.
Method Detail

open

public void open()
          throws ModelException
It opens the IDataSource.

Specified by:
open in interface IDataSource
Overrides:
open in class MemDataSource
Throws:
ModelException - if the open dosn't work out.

getConnection

public AbstractConnection getConnection()
Returns the AbstractConnection to the server IStorage object.

Returns:
the AbstractConnection to the server IStorage object.

setConnection

public void setConnection(AbstractConnection pConnection)
Sets the AbstractConnection to the server IStorage object.

Parameters:
pConnection - the AbstractConnection to set

getMetaData

public static MetaData getMetaData(String pKey)
Returns the column meta data from the client cache.

Parameters:
pKey - is the AbstractConnection.getLifeCacleName() + RemoteDataBook.getName()
Returns:
the MetaData[] from the client cache

putMetaData

public static void putMetaData(String pKey,
                               MetaData pMetaData)
Puts the column meta data to the client cache.

Parameters:
pKey - is the AbstractConnection.getLifeCacleName() + RemoteDataBook.getName()
pMetaData - the MetaData[] to cache


Copyright © 2009 SIB Visions GmbH. All Rights Reserved.