|
OBEROn SDK | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.oberon.ooql.sdk.Framework
public class Framework
Defines the OBEROn session parameters and status.
Field Summary | |
---|---|
static int |
MESSAGE_ALL
Undefined message type |
static int |
MESSAGE_ERROR
Error message type |
static int |
MESSAGE_INFO
Info message type |
static int |
MESSAGE_WARNING
Warning message type |
Constructor Summary | |
---|---|
Framework(Framework framework)
Create (clone) the new OBEROn session from another Framework. |
|
Framework(java.lang.String text)
Generate a new OBEROn session from a text String |
|
Framework(java.lang.String userName,
java.lang.String password)
Create a new OBEROn session for a given User account |
Method Summary | |
---|---|
void |
abortTrans()
Abort a opened OBEROn transaction |
void |
appendResult(java.lang.String text)
Append a text to the console output |
void |
appendResultLog(java.lang.String text)
Append a text to the console output |
void |
changePassword(java.lang.String newPassword,
java.lang.String oldPassword)
Change the User password on database. |
void |
clearResult()
Set the console output text |
void |
clearResultLog()
Set the console output text |
void |
commitTrans()
Commit a opened OBEROn transaction |
void |
emptyEnv()
Remove all environment variables. |
void |
errorMsg(java.lang.String message)
Add a session error message. |
java.util.BitSet |
getAdminAccess()
Return the User administrative accesses |
java.util.Hashtable<java.lang.String,java.lang.Integer> |
getAdminCounters()
Get the administrative object synch counters |
java.util.BitSet |
getBasicAccess()
Return the User basic accesses |
java.lang.String |
getBuildVersion()
Get Build version |
int |
getConnectionId()
Get SQL connection ID |
int |
getDataBaseId()
Get SQL database ID |
java.lang.String |
getEnv(java.lang.String varName)
Get an environment variable value. |
java.util.Enumeration<java.lang.String> |
getEnvKeys()
Get the list of defined environment variables or null if it is empty |
int |
getID()
Return the Framework ID |
java.lang.String |
getLanguage()
Get the user language. |
java.util.Vector<java.lang.String> |
getMessages()
Get the session messages |
java.lang.String |
getMessages(int msgType,
java.lang.String indent)
Get session messages |
java.lang.String |
getPassword()
Return the settled User password |
Framework |
getPreviousFramework()
Return the previous framework from the Framework stack |
java.lang.String |
getRenderingEngine()
Return the rendering engine for user interface |
java.lang.String |
getResult()
Return the console output. |
java.lang.String |
getResultLog()
Return the console output. |
java.util.BitSet |
getSystemAccess()
Return the User system accesses |
java.lang.String |
getTransportFormat()
Convert the Framework parameters to a text String for HTTP transport |
java.util.Hashtable<java.lang.String,java.lang.Integer> |
getUserCounters(java.lang.String userName)
Get the administrative user-object synch counters |
int |
getUserId()
Return the User administrative object ID |
java.lang.String |
getUserName()
Return the User name |
void |
infoMsg(java.lang.String message)
Add a session information message. |
boolean |
isActiveTrans()
Check if there is an opened transaction |
boolean |
isFieldValueConversion()
Check if the field values are converted according to the user Metric System |
boolean |
isFilterHidden()
Check if the filter hidden mode is active |
boolean |
isLinked()
Check if the session is opened |
boolean |
isSQLTrace()
Check if the sql-trace mode is active |
boolean |
isSuperUser()
Check if the current User is defined as SuperUser |
boolean |
isTriggersActive()
Check if the event triggers are active or not |
boolean |
isUserEnabled(int accessType,
int operation)
Check if the current User is enabled to perform a specific operation |
boolean |
isVerbose()
Check if the verbose mode is active |
void |
link()
Open the session and read User properties from the database |
void |
listActivity(java.lang.String application,
java.lang.String processID,
java.lang.String stepName,
Selector selector,
java.io.DataOutputStream outStream)
List the user activities (to-do list) for the running processes |
java.lang.String |
listEnv()
Get the list of defined environment variables with their values. |
java.lang.String |
listEnv(java.lang.String indent)
Get the list of defined environment variables with their values. |
void |
openTrans()
Open an OBEROn transaction |
void |
removeMessages(int msgType)
Delete session messages |
void |
resetFrom(Framework framework)
Copy the new OBEROn session properties from another Framework instance |
Framework |
restore()
Close the current Framework and return to the previous extracted from the Framework stack. |
void |
setConnectionId(int connectionID)
Set SQL connection ID |
void |
setDataBaseId(int databaseID)
Set SQL database ID |
void |
setEnv(java.lang.String varName,
java.lang.String value)
Set a session environment variable. |
java.util.Hashtable<java.lang.String,java.lang.String> |
setEnvFromRequest(ApplicationRequest request,
boolean fields)
Set a session environment variable. |
void |
setFieldValueConversion(boolean convertValues)
Set if the field values must be converted according to the user Metric System |
void |
setFilterHidden(boolean filter)
Set the filter hidden mode. |
void |
setLanguage(java.lang.String language)
Set the Framework language |
void |
setMessages(java.util.Vector<java.lang.String> messages)
Set messages. |
void |
setPassword(java.lang.String password)
Set the User password. |
void |
setRenderingEngine(java.lang.String engineName)
Set the rendering engine for user interface |
void |
setResult(java.lang.String text)
Set the output text |
void |
setSQLTrace(boolean sqlTrace)
Set the sql-trace mode. |
void |
setTriggersActive(boolean triggers)
Turn on/off the event triggers |
void |
setUserName(java.lang.String userName)
Set the User name. |
void |
setVerbose(boolean verbose)
Set the verbose mode. |
Framework |
switchTo(java.lang.String userName,
java.lang.String password)
Generate a new Framework for another User and copy the session status. |
java.lang.String |
toString()
Return the Framework properties as a single String |
void |
undefineEnv(java.lang.String varName)
Remove a session environment variable. |
void |
unlink()
Close the session |
void |
warningMsg(java.lang.String message)
Add a session warning message. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final int MESSAGE_ALL
public static final int MESSAGE_ERROR
public static final int MESSAGE_WARNING
public static final int MESSAGE_INFO
Constructor Detail |
---|
public Framework(java.lang.String userName, java.lang.String password) throws OberonException
userName
- the User
namepassword
- the User password
OberonException
- if the session cannot be openedpublic Framework(Framework framework) throws OberonException
OberonException
- if the session cannot be openedpublic Framework(java.lang.String text) throws OberonException
OberonException
Method Detail |
---|
public void resetFrom(Framework framework) throws OberonException
OberonException
public int getID()
public void setUserName(java.lang.String userName)
userName
- the User
namepublic java.lang.String getUserName()
User
name
public void setPassword(java.lang.String password)
password
- the User
passwordpublic java.lang.String getPassword()
User
password
public void changePassword(java.lang.String newPassword, java.lang.String oldPassword) throws OberonException
User
password on database.
newPassword
- the new passwordoldPassword
- the old password
OberonException
User.setPassword(String)
public void setRenderingEngine(java.lang.String engineName)
engineName
- the rendering engine namepublic java.lang.String getRenderingEngine()
public void setDataBaseId(int databaseID)
databaseID
- the SQL database ID (identifies the SQL database)public int getDataBaseId()
public void setConnectionId(int connectionID)
connectionID
- the SQL connection ID (identifies the SQL channel)public int getConnectionId()
public java.lang.String getBuildVersion()
public void setLanguage(java.lang.String language)
public java.lang.String getLanguage()
public int getUserId()
User
administrative object ID
public java.util.BitSet getBasicAccess()
User
basic accesses
User.getBasicAccess()
public java.util.BitSet getAdminAccess()
User
administrative accesses
User.getAdminAccess()
public java.util.BitSet getSystemAccess()
User
system accesses
User.getSystemAccess()
public boolean isSuperUser()
User
is defined as SuperUser
User.isSuperUser()
public boolean isUserEnabled(int accessType, int operation) throws OberonException
accessType
- the access type (one of User.BASIC
User.SYSTEM
User.ADMIN
)operation
- the operation id ( see User
access constants )
OberonException
public void link() throws OberonException
User
properties from the database
OberonException
- usually due to DB SQL exceptions or wrong userName / passwordpublic void unlink() throws OberonException
OberonException
public boolean isLinked()
public void openTrans() throws OberonException
OberonException
- when the session is not openedpublic void commitTrans() throws OberonException
OberonException
- when the session is not openedpublic void abortTrans() throws OberonException
OberonException
- when the session is not openedpublic boolean isActiveTrans()
public void setFieldValueConversion(boolean convertValues)
public boolean isFieldValueConversion()
public void setVerbose(boolean verbose)
public boolean isVerbose()
public void setSQLTrace(boolean sqlTrace)
public boolean isSQLTrace()
public void setTriggersActive(boolean triggers)
triggers
- true to active the triggerspublic boolean isTriggersActive()
public void setFilterHidden(boolean filter)
filter
- if true skip the hidden objects for all administrative queriespublic boolean isFilterHidden()
public Framework getPreviousFramework()
switchTo(String, String)
public Framework switchTo(java.lang.String userName, java.lang.String password) throws OberonException
userName
- the User
namepassword
- the User password
OberonException
public Framework restore() throws OberonException
OberonException
public void listActivity(java.lang.String application, java.lang.String processID, java.lang.String stepName, Selector selector, java.io.DataOutputStream outStream) throws java.io.IOException, OberonException
application
- filter activities for a specific applicationprocessID
- return only activities for a specific process (ID)stepName
- return only activities for a specific Stepselector
- selection parameters for the activities (Step)outStream
- the stream for the results (if null the result is stored into the framework)
java.io.IOException
OberonException
getResult()
public java.util.Hashtable<java.lang.String,java.lang.Integer> getAdminCounters() throws OberonException
OberonException
public java.util.Hashtable<java.lang.String,java.lang.Integer> getUserCounters(java.lang.String userName) throws OberonException
OberonException
public void setEnv(java.lang.String varName, java.lang.String value)
varName
- the variable namevalue
- its valuepublic void undefineEnv(java.lang.String varName)
varName
- the variable namepublic void emptyEnv()
public java.lang.String getEnv(java.lang.String varName)
public java.util.Enumeration<java.lang.String> getEnvKeys()
public java.lang.String listEnv()
public java.lang.String listEnv(java.lang.String indent)
indent
- indentation stringpublic java.util.Hashtable<java.lang.String,java.lang.String> setEnvFromRequest(ApplicationRequest request, boolean fields)
request
- the Application requestfields
- if true returns table of fieldspublic void errorMsg(java.lang.String message)
message
- the message textpublic void warningMsg(java.lang.String message)
message
- the message textpublic void infoMsg(java.lang.String message)
message
- the message textpublic void setMessages(java.util.Vector<java.lang.String> messages)
messages
- Vector of the message texts formatted as: <MessageType>[<MessageText>]public void removeMessages(int msgType)
msgType
- the type of message to removepublic java.util.Vector<java.lang.String> getMessages()
public java.lang.String getMessages(int msgType, java.lang.String indent)
msgType
- the type of messagepublic void clearResult()
public void appendResult(java.lang.String text)
public void setResult(java.lang.String text)
public java.lang.String getResult()
public void clearResultLog()
public void appendResultLog(java.lang.String text)
public java.lang.String getResultLog()
public java.lang.String toString()
toString
in class java.lang.Object
public java.lang.String getTransportFormat()
|
OBEROn SDK | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |