interface SCC_COMMON:ENTITY:IEntity
Implementing Classes: SCC_COMMON:ENTITY:FileAttachment, SCC_COMMON:ENTITY:AbstractEntity
See Also: BasicEntity, StagedEntity, StagedHREntity
Summary
Property Summary:
|
public Array of string |
baseProps: A list of properties that are controlled on the base entities, so the property name cannot be changed. |
|
public Array of ChildEntity |
ChildEntityArray: An array of all the ChildEntities of the current entity. |
|
public Record |
data: This entities a backing record. |
|
public boolean |
entityDelete: Marks this entity for deletion, and prevents save. |
|
public string |
entityID: ID of the entity from the registry. |
|
public string |
entityName: The name of the entity as defined in the registry. |
|
public Array of DataKey |
keyCollection: A collection of key values to be used when population of this entity occurs. |
|
public IEntity |
parent: parent Entity, null if it is at the top level of tree. |
|
public ChildEntity |
parentCE: The child entity that encompasses all the entities of a particular type under the parent. |
|
public string |
SCC_ENTITY_INST_ID: Entity Instance Id. |
|
public boolean |
selfServiceMode: Self Service mode flag. |
|
public boolean |
STAGE_MODE: Specifies if this entity is currently in Stage Mode (True) and working with the stage record, or in Production Mode (False) and working with the production record. |
|
public string |
UPDATE_RULE: Specifies the update rule to use for the purposes of Data Update Rule. |
|
public string |
USER_CONTEXT: The user that this is being run on behalf of, since adds and updates may be done from administrative mode on behalf of a given user. |
|
public Array of string |
XSDFieldList: A string list of all the fields for the current entity for the XSD. This is used in conjunction with buildXSD to determine if key fields are required, based on if their parent has the same key. |
Method Summary:
|
public void |
buildXSD(XmlNode xmlnode): Builds the xml schema section pertaining to this entity. |
|
public void |
clearDataPreImage(): Clears the DataPreImage for this entity and all its children. |
|
public void |
delete(boolean p_entityDelete): Sets entityDelete property for this entity and all its children. |
|
public void |
demote(number p_tempID): Moves data from production records to staging record. |
|
public void |
destroy(): Perform cleanup activity on this entity. |
|
public void |
fill(Record p_inRec out, boolean p_clearState): Fill (Populate) this entity using the given record, and populates all children based on the key structure. |
|
public void |
fillFromKeys(boolean p_clearState): Performs a select by key based on the fields on the underlying record. This should be run on the top level entity to start a fill. |
|
public void |
fromXmlNode(XmlNode parentNode): Converts data from XML to the entity model. |
|
public Rowset |
generateRowset(): This method generates a rowset of data for the underlying record of this entity based on the keys of the parent. It is used as part of the fill process for building out the entity tree. The method is called as if it were a static method, so it is not associated with any particular entity data. The base implementation dynamically matches keys from the parent to the child and builds the query for the rowset based on that. |
|
public string |
generateXSD(): Begins generation of an xml schema, based on the registry using this entity as the root. |
|
public ChildEntity |
getChildEntity(string p_entityID): Retrieves the ChildEntity Object based on the entity ID. |
|
public string |
getLOVDescr(string propname): Returns the LOV Description based on the associated property name when parsed from XML. |
|
public number |
getMaxSeqNbrSQL(): Retrieves the maximum sequence number from the database based on the key structure of the current entity. |
|
public any |
getProperty(string propname) |
|
public void |
hardDelete(MessageLogBase p_messageLog out): Performs the actual delete of all objects marked with the entityDelete flag. |
|
public boolean |
hasEffdt(): Checks if this entity has an effective date. |
|
public boolean |
hasEffseq(): Checks if this entity has an effective sequence. |
|
public boolean |
hasKey(string p_keyname): Checks if the current entity has a particular field as a key. |
|
public boolean |
isEqualKeys(IEntity p_entity): Determine Entity Key Equality. |
|
public boolean |
isEqualKeysRecord(Record p_rec): Allows the given record to be compared with this entity for equality. Compares for equality based on the underlying entity record content. RECOMMENDATION: Override this method if you need to do custom equality checking. |
|
public void |
prePublish(Rowset p_changesRS out): Uses the workflowPreimage and post images of the entity to build a PSCAMA Rowset in preparation for publish. The parameter Rowset may be Null. Data should be appended to this rowset if it is NON-Null. |
|
public void |
preSave(): Perform pre-Save activities on this entity. |
|
public void |
preSaveChildren() |
|
public void |
PreSaveFirst(): Pre-Save code that only runs on the first entity of a child array. |
|
public void |
promote(string emplID, MessageLogBase p_log out): Moves Data from Staging to Production Records (does not validate or save). |
|
public void |
publish(Rowset p_changesRS, boolean p_onlineMode): Takes a PSCAMA based rowset of information to be published during workflow Uses that information to construct a Message and according to the onlineMode publishes the Message data in realtime or to the batch delay table. |
|
public void |
save(MessageLogBase p_messageLog out): Save this entity and all its children. |
|
public void |
setChildren(): Builds out the structure of the ChildEntityArray object based on the registry. |
|
public void |
setDefault(): Sets default values for record fields. |
|
public void |
setProperty(string propname, any value) |
|
public void |
setStageMode(boolean p_stageInd): Changes the Stage_Mode property, as well as any related records. This should not be used once data has been set, to convert data use promote or demote. |
|
public void |
setUserContext(string p_userContext): Sets the value of the UserContext property. |
|
public void |
toXmlNode(XmlNode parentNode): Converts the data from the entity structure to XML. |
|
public void |
updateFromRecord(Record rec): Updates by matching fields in the record to fields in the underlying record on the entity. Values are only set if the value has changed. Values are set using properties, so any additional get-set logic is handled. |
|
public void |
updateKeyFields(): Updates the keyfields of all children based on the current entity. This allows key changes to roll down properly. |
|
public void |
validate(MessageLogBase p_messageLog out): Validate this entities' contents (and all its children). |
|
public void |
validateFirst(MessageLogBase p_messageLog out): Validation code that only runs on the first entity of a child array. |
|
public void |
workflow(boolean p_onlineMode): Orchestrates the prepublish and publish methods for this entity and all children. |
Details
Property Details:
|
baseProps |
public Array of string |
|
ChildEntityArray |
public Array of ChildEntity |
|
data |
public Record |
|
entityDelete |
public boolean |
|
entityID |
public string |
|
entityName |
public string |
|
keyCollection |
public Array of DataKey |
|
parent |
public IEntity |
|
parentCE |
public ChildEntity |
|
SCC_ENTITY_INST_ID |
public string |
|
selfServiceMode |
public boolean |
|
STAGE_MODE |
public boolean |
|
UPDATE_RULE |
public string |
|
USER_CONTEXT |
public string |
|
XSDFieldList |
public Array of string |
Method Details:
|
buildXSD |
Parameters: XmlNode xmlnode: The Tools XmlNode object of the parent that should be continued by this entity. |
|
clearDataPreImage |
N/A |
|
delete |
Parameters: boolean p_entityDelete: The value to be set for the entityDelete property. |
|
demote |
Parameters: number p_tempID: The tempid to replace the emplid with. |
|
destroy |
N/A |
|
fill |
Parameters: Record p_inRec(out): This record populates the record underlying this entity. boolean p_clearState: If the clearstate is true the datapreimage is populated as well. |
|
fillFromKeys |
Parameters: boolean p_clearState: Whether or not to RESET this entities pre-image. |
|
fromXmlNode |
Parameters: XmlNode parentNode: The XML node to pull from. |
|
generateRowset |
Return: Rowset - a rowset populated based on the parent keys, or null if no rows are found. |
|
generateXSD |
Return: string - the XSD as a string. |
|
getChildEntity |
Parameters: string p_entityID: The entity ID, based on the registry, of the ChildEntity object to retrieve. Return: ChildEntity |
|
getLOVDescr |
Parameters: string propname: The property name to get a LOV Description based on. Return: string |
|
getMaxSeqNbrSQL |
Return: number - the maximum sequence number found. |
|
getProperty |
Parameters: string propname Return: any |
|
hardDelete |
Parameters: MessageLogBase p_messageLog(out): The MessageLog object to log all errors/warnings to. |
|
hasEffdt |
Return: boolean - true if it has an effective date false otherwise. |
|
hasEffseq |
Return: boolean - true if it has an effective sequence false otherwise. |
|
hasKey |
Parameters: string p_keyname: The name of the field to check. Return: boolean - true if the field is a key, false if the field is not a key or the entity does not include it. |
|
isEqualKeys |
Parameters: IEntity p_entity: The entity to compare the current entity to. Return: boolean - true if the entity keys are equal false otherwise. |
|
isEqualKeysRecord |
Parameters: Record p_rec Return: boolean |
|
prePublish |
Parameters: Rowset p_changesRS(out) |
|
preSave |
N/A |
|
preSaveChildren |
N/A |
|
PreSaveFirst |
N/A |
|
promote |
Parameters: string emplID: The emplid for production to replace the tempid from staging. MessageLogBase p_log(out): The MessageLog object to log all errors/warnings to. |
|
publish |
Parameters: Rowset p_changesRS boolean p_onlineMode |
|
save |
Parameters: MessageLogBase p_messageLog(out): The messagelog object to log errors and warnings to. |
|
setChildren |
N/A |
|
setDefault |
N/A |
|
setProperty |
Parameters: string propname any value |
|
setStageMode |
Parameters: boolean p_stageInd: The value to set the stage mode to, if the value passed matches the current stage mode no changes are made. |
|
setUserContext |
Parameters: string p_userContext: The value set for the property UserContext. |
|
toXmlNode |
Parameters: XmlNode parentNode: The XML parent node to push the xml to. |
|
updateFromRecord |
Parameters: Record rec: The record object to copy data from. |
|
updateKeyFields |
N/A |
|
validate |
Parameters: MessageLogBase p_messageLog(out): The messagelog object to log errors and warnings to. |
|
validateFirst |
Parameters: MessageLogBase p_messageLog(out): The MessageLog object to log all errors/warnings to. |
|
workflow |
Parameters: boolean p_onlineMode |