public class UpdatableDBObjectTemplate extends java.lang.Object implements UpdatableDBObject
Constructor and Description |
---|
UpdatableDBObjectTemplate()
The public no-arg constructor is required in any (class that implements) DBObject.
|
UpdatableDBObjectTemplate(int attribute1,
java.lang.String attribute2)
Other constructors may exist to serve the application programs
|
Modifier and Type | Method and Description |
---|---|
int |
getAttribute1()
Gets some attribute of this class
|
java.lang.String |
getAttribute2()
Gets some other attribute of this class
|
UpdatableDBObject |
getPreUpdateState()
Gets The state of the object as it was built by the J/R bridging engine immediately after the object was created from a database tuple (and which should have been set by/using the setPreUpdateState() method.
|
java.lang.String |
getRelvar1Attribute1()
Gets the value of some attribute of this class for use in the Java-to-SIRA_PRISE part of the bridge.
|
java.lang.String |
getRelvar1Attribute2()
Gets the value of some other attribute of this class for use in the Java-to-SIRA_PRISE part of the bridge.
|
java.lang.String |
getRelvar2Attribute1()
Gets the value of some attribute of this class for use in the Java-to-SIRA_PRISE part of the bridge.
|
void |
setAttribute1(int attribute1)
Sets some attribute of this class
|
void |
setAttribute1FromDB(java.lang.String attribute1)
Sets some attribute of this class, given a SIRA_PRISE string representation of the value to set.
|
void |
setAttribute2(java.lang.String attribute2)
Sets some other attribute of this class
|
void |
setAttribute2FromDB(java.lang.String attribute2)
Sets some other attribute of this class, given a SIRA_PRISE string representation of the value to set.
|
void |
setPreUpdateState()
This method is called by the J/R bridging engine after an object has been setup from some tuple retrieved from the database.
|
public UpdatableDBObjectTemplate()
public UpdatableDBObjectTemplate(int attribute1, java.lang.String attribute2)
attribute1
- some attribute of this classattribute2
- some other attribute of this classpublic final int getAttribute1()
public final java.lang.String getAttribute2()
public final java.lang.String getRelvar1Attribute1()
public final java.lang.String getRelvar1Attribute2()
public final java.lang.String getRelvar2Attribute1()
public final void setAttribute1(int attribute1)
attribute1
- some attribute of this classpublic final void setAttribute1FromDB(java.lang.String attribute1)
attribute1
- The SIRA_PRISE string representation of a value for some attribute of this classpublic final void setAttribute2(java.lang.String attribute2)
attribute2
- some other attribute of this classpublic final void setAttribute2FromDB(java.lang.String attribute2)
attribute2
- The SIRA_PRISE string representation of a value for some other attribute of this class. Note in particular the call to BracketParser.unMeta(). This is because the String values that are passed to these setter methods are always in 'escaped' format, i.e. if one of the characters '(', ')' or '\' is part of the actual value of the attribute, then any appearance of these characters is represented by the character sequences '\(', '\)' or '\\' respectively (note that in a java source, the latter is actually written as four consecutive backslashes, because java itself also 'escapes' backslash characters). This allows in
particular to correctly treat values that contain opening and closing parentheses to denote component values of the value. E.g. a date value could be passed to this setter method as the String "D(31)M(12)Y(1999)". Thus, string values that represent filenames or directory names can also be dealt with appropriately : the set...FromDB() method will be invoked with a String value of, e.g. "directory\\filename", and the "regular" setter method available to the application could be invoked with a string value of "directory\filename", as the application is likely to want to have it.public final void setPreUpdateState()
UpdatableDBObject
setPreUpdateState
in interface UpdatableDBObject
public final UpdatableDBObject getPreUpdateState()
UpdatableDBObject
getPreUpdateState
in interface UpdatableDBObject