|
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.OBBase com.oberon.ooql.sdk.AdminBase
public abstract class AdminBase
A base class for Admin Objects. This class provides the common basic features for all the OBEROn administrative objects
Field Summary | |
---|---|
java.util.BitSet |
bsOptions
Set for object options |
static int |
HIDDEN_OPTION
The Hidden flag index inside the Option Set |
Method Summary | |
---|---|
void |
addFeature(Feature feature)
Add a Feature to the administrative object |
boolean |
changedApplication()
Check if the element has changed the application Menu |
java.lang.String |
checkChangeName()
Check if the object name was changed |
boolean |
checkCounters(java.util.Hashtable<java.lang.String,java.lang.Integer> hDBCounters)
Compares the administrative object synch counters; [INTERNAL USAGE] |
boolean |
checkCounters(java.lang.String sCounters)
Compares the administrative object synch counters; [INTERNAL USAGE] |
abstract void |
create(Framework framework)
Create a new object on the database |
abstract void |
destroy(Framework framework)
Remove the object from the database. |
void |
fromXML(org.jdom.Element rootElement)
Load the administrative object basic properties from XML element tree |
java.lang.String |
getAdminType()
Get the administrative object Type |
java.lang.String |
getApplication()
Get the application Menu name. |
java.lang.String |
getCommonProperty(java.lang.String propertyName,
java.lang.String token,
Framework framework)
Get a (basic) property for the administrative object by its OOQL identifier |
java.util.Vector<java.lang.String> |
getCommonTargetNames(java.lang.String composedName,
Framework framework)
Return a Vector of administrative object names extracted by using an OOQL selector |
java.util.Hashtable<java.lang.String,java.lang.Integer> |
getCounters()
Get administrative object synch counters; [INTERNAL USAGE] This is used to check if the object instance is synchronized with the database |
java.lang.String |
getCreateBasicCommand(java.lang.String options)
Return the OOQL command to create the administrative object with the settled basic properties |
java.lang.String |
getCreateCommand()
Return the OOQL command to create the object with the settled properties |
abstract java.lang.String |
getCreateCommand(boolean force)
Return the OOQL command to create the object with the settled properties |
java.lang.String |
getCrtDate()
Return the administrative object creation date |
java.lang.String |
getDescription()
Get the administrative object Description |
java.lang.String |
getEditBasicCommand(java.lang.String propertyName)
Return the OOQL command to edit a given administrative object basic property |
Feature |
getFeature(java.lang.String featureName,
Framework framework)
Return a specific Feature associated to the administrative object |
java.util.Vector<Feature> |
getFeatures(Framework framework)
Return the Features associated to the administrative object |
java.lang.String |
getFeaturesAsString(java.lang.String delim,
java.lang.String indent,
Framework framework)
Return the Features associated to the administrative object as single String |
byte[] |
getImage()
Return the administrative object icon |
static byte[] |
getImage(int adminId)
Return a administrative object icon |
static byte[] |
getImage(java.lang.String adminType,
java.lang.String name)
Return a administrative object icon |
java.lang.String |
getImageData()
Return the administrative object icon codified as base64 string data |
java.lang.String |
getImageFile()
Return the administrative object icon file path. |
java.lang.String |
getModDate()
Return the administrative object last modification date |
java.lang.String |
getModUser()
Return the administrative object modification User |
java.lang.String |
getName()
Get the administrative object Name |
java.lang.String |
getOldName()
Get the original administrative object Name keep the value read from DB |
java.util.Vector<java.lang.String> |
getPlainFeatures(Framework framework)
Return the Feature s associated to the administrative object |
java.lang.String |
getSaveCommand()
Return the OOQL command to update the object with the modified properties. |
abstract java.lang.String |
getSaveCommand(boolean force)
Return the OOQL command to update the object with the modified properties. |
long |
getSVNRevision()
Return the administrative object SVN revision |
org.jdom.Element |
getXMLFeatureList(Framework framework)
Return the Features as XML element tree |
boolean |
hasImage()
Test if the administrative object has an image icon |
boolean |
isHidden()
Return if the administrative object is or not hidden |
abstract void |
link(Framework framework,
java.util.Hashtable<java.lang.String,java.lang.Integer> counters)
Open the object: connect the memory instance with the database instance |
void |
setApplication(java.lang.String menuName)
Set the application Menu name. |
void |
setCounters(java.util.Hashtable<java.lang.String,java.lang.Integer> counters)
Set administrative object synch counters; [INTERNAL USAGE] |
void |
setCrtDate(java.lang.String date)
Set the administrative object creation date; [INTERNAL USAGE] |
void |
setDescription(java.lang.String description)
Set the administrative object Description |
void |
setHidden(boolean hidden)
Set the administrative object Hidden flag; Hidden objects are filtered when an admin query is performed |
void |
setImage(byte[] image)
Set the administrative object icon; |
void |
setImageData(java.lang.String base64ImageData)
Set the administrative object icon from a base64 string data; |
void |
setImageFile(java.lang.String fileName)
Set the administrative object icon importing it from a file; |
void |
setModDate(java.lang.String date)
Set the administrative object modification date; [INTERNAL USAGE] |
void |
setModUser(java.lang.String userName)
Set the administrative object modification User; [INTERNAL USAGE] |
void |
setName(java.lang.String name)
Set the administrative object Name |
void |
setSVNRevision(long revision)
Set the administrative object SVN revision; |
void |
show(Selector selector,
java.io.DataOutputStream outStream,
Framework framework)
Show the admin object properties |
static void |
show(java.lang.String type,
java.lang.String name,
Selector selector,
java.io.DataOutputStream outStream,
Framework framework)
Show the properties for the given administrative object |
org.jdom.Element |
toCommonXML(boolean getImage,
boolean fullDump,
Framework framework)
Return the administrative object basic properties as XML element tree |
java.lang.String |
toString()
Return the administrative object basic properties as a single String |
java.lang.String |
toString(Framework framework)
Return the administrative object basic properties as a single String |
abstract org.jdom.Element |
toXML(boolean getImage,
boolean fullDump,
Framework framework)
Return the object properties as XML element tree |
abstract org.jdom.Element |
toXML(Framework framework)
Return the object properties as XML element tree |
org.jdom.Element |
toXML(java.lang.String adminType,
boolean getImage,
boolean fullDump,
Framework framework)
Return the administrative object basic properties as XML element tree |
abstract void |
unlink(Framework framework)
Close the object: disconnect the memory instance from the database instance |
abstract void |
write(Framework framework)
Update the object to the database |
Methods inherited from class com.oberon.ooql.sdk.OBBase |
---|
addChange, addUniqueChange, ChangesFromXML, ChangesToXML, getChanges, getChangesAsString, getId, getProperty, getTargetNames, isLinked, removeChange, resetChanges, setId, setLinked |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final int HIDDEN_OPTION
public java.util.BitSet bsOptions
Method Detail |
---|
public abstract void create(Framework framework) throws OberonException
OberonException
public abstract void link(Framework framework, java.util.Hashtable<java.lang.String,java.lang.Integer> counters) throws OberonException
OberonException
public abstract void write(Framework framework) throws OberonException
OberonException
public abstract void destroy(Framework framework) throws OberonException
OberonException
public abstract void unlink(Framework framework) throws OberonException
OberonException
public java.lang.String getAdminType()
public void setName(java.lang.String name) throws OberonException
name
- the name of the administrative object
OberonException
- if the name contains the pipe '|' characterpublic java.lang.String getOldName()
public java.lang.String getName()
getName
in class OBBase
public java.lang.String checkChangeName()
public void setDescription(java.lang.String description)
description
- the description to set for the administrative objectpublic java.lang.String getDescription()
public void setHidden(boolean hidden)
hidden
- the hidden flagFramework.setFilterHidden(boolean)
public boolean isHidden()
public void setImage(byte[] image)
image
- the image datapublic byte[] getImage()
public void setImageFile(java.lang.String fileName)
fileName
- the image file absolute pathpublic java.lang.String getImageFile()
setImageFile(String)
public void setImageData(java.lang.String base64ImageData)
base64ImageData
- the base64 image datapublic java.lang.String getImageData()
public boolean hasImage()
public static byte[] getImage(java.lang.String adminType, java.lang.String name) throws OberonException
adminType
- the administrative object type (ex.: class , field , lifecycle ... )name
- the object name
OberonException
public static byte[] getImage(int adminId) throws OberonException
adminId
- the administrative object Id
OberonException
public void setModDate(java.lang.String date)
date
- the modification datepublic java.lang.String getModDate()
public void setCrtDate(java.lang.String date)
date
- the creation datepublic java.lang.String getCrtDate()
public void setModUser(java.lang.String userName)
userName
- the User
name who performed the last operation on the objectpublic java.lang.String getModUser()
User
name who performed the last operation on the objectpublic void setSVNRevision(long revision)
revision
- the SVN revisionpublic long getSVNRevision()
public void setApplication(java.lang.String menuName)
Menu
name.
Create association between the administrative object and a specific application.
menuName
- the application main Menu
namepublic java.lang.String getApplication()
Menu
name.
public boolean changedApplication()
Menu
public java.util.Vector<Feature> getFeatures(Framework framework)
framework
- the current framework
Feature
objectspublic java.util.Vector<java.lang.String> getPlainFeatures(Framework framework)
Feature
s associated to the administrative object
framework
- the current framework
public java.lang.String getFeaturesAsString(java.lang.String delim, java.lang.String indent, Framework framework)
delim
- item separatorindent
- item indent charactersframework
- the current framework
Feature
objectspublic Feature getFeature(java.lang.String featureName, Framework framework)
featureName
- the Feature
nameframework
- the current frameworkpublic void addFeature(Feature feature) throws OberonException
feature
- the Feature
object to add
OberonException
- when the feature name contains invalid characterspublic static void show(java.lang.String type, java.lang.String name, Selector selector, java.io.DataOutputStream outStream, Framework framework) throws java.io.IOException, OberonException
type
- the type of the objectname
- the name of the objectselector
- selection parameters (if null return all the object properties)outStream
- the stream for the results (if null the result is stored into the framework)framework
- the current framework
java.io.IOException
- when the output stream return an exception
OberonException
- for all other problemsFramework.getResult()
public void show(Selector selector, java.io.DataOutputStream outStream, Framework framework) throws java.io.IOException, OberonException
selector
- selection parameters (if null return all the object properties)outStream
- the stream for the results (if null the result is stored into the framework)framework
- the current framework
java.io.IOException
- when the output stream return an exception
OberonException
- for all other problemsFramework.getResult()
public abstract org.jdom.Element toXML(Framework framework)
framework
- the current frameworkpublic abstract org.jdom.Element toXML(boolean getImage, boolean fullDump, Framework framework)
getImage
- true to include "imagedata" element with the base64 encoded image datafullDump
- true to include detailed informationframework
- the current frameworkpublic void setCounters(java.util.Hashtable<java.lang.String,java.lang.Integer> counters)
counters
- hash table with counter valuespublic java.util.Hashtable<java.lang.String,java.lang.Integer> getCounters()
public boolean checkCounters(java.util.Hashtable<java.lang.String,java.lang.Integer> hDBCounters)
public boolean checkCounters(java.lang.String sCounters)
public java.lang.String getCommonProperty(java.lang.String propertyName, java.lang.String token, Framework framework)
propertyName
- OOQL property identifier/name (example: id , name , moddate , description ...)token
- separator token for complex propertiesframework
- the current framework
public java.util.Vector<java.lang.String> getCommonTargetNames(java.lang.String composedName, Framework framework)
composedName
- OOQL property identifier/name (example: feature , feature[name] .. )framework
- the current framework
public java.lang.String toString()
toString
in class java.lang.Object
public java.lang.String toString(Framework framework)
framework
- the current frameworkpublic org.jdom.Element getXMLFeatureList(Framework framework)
public org.jdom.Element toXML(java.lang.String adminType, boolean getImage, boolean fullDump, Framework framework)
adminType
- the object admin typegetImage
- true to include "imagedata" element with the base64 encoded image datafullDump
- true to include detailed informationframework
- the current frameworkpublic org.jdom.Element toCommonXML(boolean getImage, boolean fullDump, Framework framework)
getImage
- true to include "imagedata" element with the base64 encoded image datafullDump
- true to include detailed informationframework
- the current frameworkpublic void fromXML(org.jdom.Element rootElement)
public java.lang.String getCreateCommand()
public abstract java.lang.String getCreateCommand(boolean force)
force
- if true append the "force" options at the endpublic java.lang.String getSaveCommand()
public abstract java.lang.String getSaveCommand(boolean force)
force
- if true append the "force" options at the endpublic java.lang.String getCreateBasicCommand(java.lang.String options)
options
- usually empty: "" - used only for particular type of administrative objects Field
object it's something like "type integer"public java.lang.String getEditBasicCommand(java.lang.String propertyName)
propertyName
- the name of the property (example: name, description , ....)
|
OBEROn SDK | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |