Ontimize 5.2072EN

com.ontimize.gui.preferences
Class DatabaseApplicationPreferences

java.lang.Object
  extended byjava.rmi.server.RemoteObject
      extended byjava.rmi.server.RemoteServer
          extended byjava.rmi.server.UnicastRemoteObject
              extended bycom.ontimize.gui.preferences.DatabaseApplicationPreferences
All Implemented Interfaces:
java.rmi.Remote, RemoteApplicationPreferences, java.io.Serializable

public class DatabaseApplicationPreferences
extends java.rmi.server.UnicastRemoteObject
implements RemoteApplicationPreferences

See Also:
Serialized Form

Field Summary
static java.lang.String ENTITY_NAME
           
protected  java.lang.String entityName
          Preference's entity name.
static java.lang.String ID
           
protected  java.lang.String idCol
          Table column name of the IDs.
protected  java.lang.Object idValule
          Value of the ID column.
protected  EntityReferenceLocator locator
           
static java.lang.String PREFERENCE_NAME
           
static java.lang.String PREFERENCE_VALUE
           
protected  java.lang.String prefNameCol
          Table column name of the Preference Names.
protected  java.lang.String prefValueCol
          Table column name of the Preference Values.
static java.lang.String USE_PRIVILEGED_ID
           
protected  boolean usePrivilegedId
           
static java.lang.String USER
           
protected  java.lang.String userNameCol
          Table column name of the Users.
 
Fields inherited from class java.rmi.server.RemoteObject
ref
 
Fields inherited from interface com.ontimize.gui.preferences.RemoteApplicationPreferences
KEY_USER_PREFERENCE
 
Constructor Summary
DatabaseApplicationPreferences(int port, java.util.Hashtable param, EntityReferenceLocator locator)
          Constructs a new DatabaseApplicationPreferences.
 
Method Summary
 Entity getEntityReference(java.lang.String entityName)
           
 java.lang.String getRemotePreference(int sessionId, java.lang.String user, java.lang.String preferenceName)
          Method to get the preferences remotely.
 void loadRemotePreferences(int sessionId)
          Method to load the preferences from the preferences file remotely.
 void saveRemotePreferences(int sessionId)
          Method to save the preferences stored into the buffer to the preferences file remotely.
 void setRemotePreference(int sessionId, java.lang.String user, java.lang.String preferenceName, java.lang.String value)
          Method to set the preferences remotely.
 
Methods inherited from class java.rmi.server.UnicastRemoteObject
clone, exportObject, exportObject, exportObject, unexportObject
 
Methods inherited from class java.rmi.server.RemoteServer
getClientHost, getLog, setLog
 
Methods inherited from class java.rmi.server.RemoteObject
equals, getRef, hashCode, toString, toStub
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

ID

public static final java.lang.String ID
See Also:
Constant Field Values

USER

public static final java.lang.String USER
See Also:
Constant Field Values

PREFERENCE_NAME

public static final java.lang.String PREFERENCE_NAME
See Also:
Constant Field Values

PREFERENCE_VALUE

public static final java.lang.String PREFERENCE_VALUE
See Also:
Constant Field Values

ENTITY_NAME

public static final java.lang.String ENTITY_NAME
See Also:
Constant Field Values

USE_PRIVILEGED_ID

public static final java.lang.String USE_PRIVILEGED_ID
See Also:
Constant Field Values

locator

protected EntityReferenceLocator locator

entityName

protected java.lang.String entityName
Preference's entity name.


idCol

protected java.lang.String idCol
Table column name of the IDs.


userNameCol

protected java.lang.String userNameCol
Table column name of the Users.


prefNameCol

protected java.lang.String prefNameCol
Table column name of the Preference Names.


prefValueCol

protected java.lang.String prefValueCol
Table column name of the Preference Values.


idValule

protected java.lang.Object idValule
Value of the ID column.


usePrivilegedId

protected boolean usePrivilegedId
Constructor Detail

DatabaseApplicationPreferences

public DatabaseApplicationPreferences(int port,
                                      java.util.Hashtable param,
                                      EntityReferenceLocator locator)
                               throws java.rmi.RemoteException
Constructs a new DatabaseApplicationPreferences.

Parameters:
port - The port.
param - Hashtable with the parameters
locator - The locator.

attribute meaning
PreferenceId The column name that contains the ID of the table
User The column name with that contains name of the users
PreferenceName The column name with that contains name of the preference
PreferenceValue The column name that contains the value of the preference
EntityName The name of the Entity of the preferences
The parameters are:
Throws:
java.rmi.RemoteException
Method Detail

getEntityReference

public Entity getEntityReference(java.lang.String entityName)
                          throws java.lang.Exception
Throws:
java.lang.Exception

getRemotePreference

public java.lang.String getRemotePreference(int sessionId,
                                            java.lang.String user,
                                            java.lang.String preferenceName)
                                     throws java.lang.Exception
Description copied from interface: RemoteApplicationPreferences
Method to get the preferences remotely.

Specified by:
getRemotePreference in interface RemoteApplicationPreferences
Parameters:
sessionId - The session ID.
user - String with the user.
preferenceName - String with the preference name.
Returns:
a String with the preferences.
Throws:
java.lang.Exception

setRemotePreference

public void setRemotePreference(int sessionId,
                                java.lang.String user,
                                java.lang.String preferenceName,
                                java.lang.String value)
                         throws java.lang.Exception
Description copied from interface: RemoteApplicationPreferences
Method to set the preferences remotely.

Specified by:
setRemotePreference in interface RemoteApplicationPreferences
Parameters:
sessionId - The session ID.
user - String with the user.
preferenceName - String with the preference name.
value - String with the preference value.
Throws:
java.lang.Exception

loadRemotePreferences

public void loadRemotePreferences(int sessionId)
                           throws java.lang.Exception
Description copied from interface: RemoteApplicationPreferences
Method to load the preferences from the preferences file remotely.

Specified by:
loadRemotePreferences in interface RemoteApplicationPreferences
Parameters:
sessionId - The session ID.
Throws:
java.lang.Exception

saveRemotePreferences

public void saveRemotePreferences(int sessionId)
                           throws java.lang.Exception
Description copied from interface: RemoteApplicationPreferences
Method to save the preferences stored into the buffer to the preferences file remotely.

Specified by:
saveRemotePreferences in interface RemoteApplicationPreferences
Parameters:
sessionId - The session ID.
Throws:
java.lang.Exception

Ontimize