OBEROn SDK

com.oberon.ooql.sdk
Class Validation

java.lang.Object
  extended by com.oberon.ooql.sdk.OBBase
      extended by com.oberon.ooql.sdk.AdminComponent
          extended by com.oberon.ooql.sdk.Validation
All Implemented Interfaces:
java.io.Serializable

public class Validation
extends AdminComponent
implements java.io.Serializable

Represents a Lifecycle Stage validation.

Version:
5.0
See Also:
Serialized Form

Field Summary
static int IGNORE_VALIDATION
          Validation Ignore
static int REFUSE_VALIDATION
          Validation Refuse
static int VALIDATE_VALIDATION
          Validation Validate
 
Fields inherited from class com.oberon.ooql.sdk.AdminComponent
bsOptions
 
Constructor Summary
Validation()
           
Validation(java.lang.String name)
           
 
Method Summary
 void addIgnoreUser(java.lang.String actorTypeName)
          Add access right to ignore this Validation to an actor
 void addIgnoreUser(java.lang.String actorType, java.lang.String actorName)
          Add access right to ignore this Validation to an actor
 void addRefuseUser(java.lang.String actorTypeName)
          Add access right to refuse this Validation to an actor
 void addRefuseUser(java.lang.String actorType, java.lang.String actorName)
          Add access right to refuse this Validation to an actor
 void addValidateUser(java.lang.String actorTypeName)
          Add access right to validate this Validation to an actor
 void addValidateUser(java.lang.String actorType, java.lang.String actorName)
          Add access right to validate this Validation to an actor
 java.lang.String compareUpdate(Validation refValidation, boolean checkImage, Framework framework)
          Return the OOQL command to update this Stage-Validation object and let it become equals to another reference object.
 boolean equals(Validation validation)
          Check if this Validation is equal to another
 void fromXML(org.jdom.Element rootElement)
          Load the Validation object from XML element tree
static java.lang.String getAccessAsString(int accessType)
          Convert validation access to OOQL equivalent String
 java.lang.String getChangeCommand()
          Return the OOQL command to update this Lifecycle-Stage-Validation with the settled properties
 java.lang.String getCreateCommand(boolean force)
          [Inherited but not used]
 java.lang.String getCreateCommand(java.lang.String operator)
          Return the OOQL command to add this Validation with the settled properties to a Lifecycle-Stage
 java.util.Vector<java.lang.String> getIgnoreUsers()
          Return the list of ignore access rights for this Validation.
 java.lang.String getProperty(java.lang.String propertyName, java.util.Vector<java.lang.Object> filterArgs, java.lang.String token, Framework framework)
          Get a property for this Lifecycle-Stage-Validation object by its OOQL identifier
 java.util.Vector<java.lang.String> getRefuseUsers()
          Return the list of refuse access rights for this Validation.
 java.lang.String getSaveCommand(boolean force)
          [Inherited but not used]
 Stage getStage()
          Get the related Stage
 java.lang.String getStageFork()
          Get the final destination Stage
 java.util.Vector<?> getTargetNames(java.lang.String composedName, java.util.Vector<java.lang.Object> filterArgs, Framework framework)
          Return a Vector of administrative object names extracted by using an OOQL selector
 java.util.Vector<java.lang.String> getValidateUsers()
          Return the list of validate access rights for this Validation.
 boolean hasIgnoreAccess(Framework framework)
          Check if the current framework User has access to ignore this Validation (ignore delegations)
 boolean hasIgnoreAccess(java.lang.String objectID, Framework framework)
          Check if the current framework User has access to ignore this Validation for a specific ObjectObj
 boolean hasIgnoreAccess(java.lang.String objectID, java.lang.String userName, Framework framework)
          Check if a User has access to ignore this Validation for a specific ObjectObj
 boolean hasRefuseAccess(Framework framework)
          Check if the current framework User has access to refuse this Validation (ignore delegations)
 boolean hasRefuseAccess(java.lang.String objectID, Framework framework)
          Check if the current framework User has access to refuse this Validation for a specific ObjectObj
 boolean hasRefuseAccess(java.lang.String objectID, java.lang.String userName, Framework framework)
          Check if a User has access to refuse this Validation for a specific ObjectObj
 boolean hasValidateAccess(Framework framework)
          Check if the current framework User has access to validate this Validation (ignore delegations)
 boolean hasValidateAccess(java.lang.String objectID, Framework framework)
          Check if the current framework User has access to validate this Validation for a specific ObjectObj
 boolean hasValidateAccess(java.lang.String objectID, java.lang.String userName, Framework framework)
          Check if a User has access to validate this Validation for a specific ObjectObj
 void removeIgnoreUser(java.lang.String actorTypeName)
          Remove the actor access right to ignore this Validation
 void removeIgnoreUser(java.lang.String actorType, java.lang.String actorName)
          Remove the actor access right to ignore this Validation
 void removeRefuseUser(java.lang.String actorTypeName)
          Remove the actor access right to refuse this Validation
 void removeRefuseUser(java.lang.String actorType, java.lang.String actorName)
          Remove the actor access right to refuse this Validation
 void removeValidateUser(java.lang.String actorTypeName)
          Remove the actor access right to validate this Validation
 void removeValidateUser(java.lang.String actorType, java.lang.String actorName)
          Remove the actor access right to validate this Validation
 void setStage(Stage stage)
          Link the Validation with the related Stage
 void setStageFork(java.lang.String stageName)
          Set the final destination Stage assigned when the Validation is satisfied
 java.lang.String toString()
          Return the Validation object properties as a single String
 java.lang.String toString(java.lang.String indent)
          Return the Validation object properties as a single String
 org.jdom.Element toXML(boolean getImage, boolean fullDump, Framework framework)
          Return the Validation properties as XML element tree
 org.jdom.Element toXML(Framework framework)
          Return the Validation properties as XML element tree
 void updateIgnoreUsers(java.util.Vector<java.lang.String> users)
          Update the ignore users on the basis of a given list
 void updateRefuseUsers(java.util.Vector<java.lang.String> users)
          Update the refuse users on the basis of a given list
 void updateValidateUsers(java.util.Vector<java.lang.String> users)
          Update the validate users on the basis of a given list
 
Methods inherited from class com.oberon.ooql.sdk.AdminComponent
checkChangeName, getAdminType, getCommonProperty, getCommonTargetNames, getCrtDate, getDescription, getEditBasicCommand, getImage, getImageData, getImageFile, getModDate, getModUser, getName, getOldName, hasImage, setCrtDate, setDescription, setImage, setImageData, setImageFile, setModDate, setModUser, setName, toCommonXML, toXML
 
Methods inherited from class com.oberon.ooql.sdk.OBBase
addChange, addUniqueChange, ChangesFromXML, ChangesToXML, getChanges, getChangesAsString, getId, isLinked, removeChange, resetChanges, setId, setLinked
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

VALIDATE_VALIDATION

public static final int VALIDATE_VALIDATION
Validation Validate

See Also:
Constant Field Values

REFUSE_VALIDATION

public static final int REFUSE_VALIDATION
Validation Refuse

See Also:
Constant Field Values

IGNORE_VALIDATION

public static final int IGNORE_VALIDATION
Validation Ignore

See Also:
Constant Field Values
Constructor Detail

Validation

public Validation()

Validation

public Validation(java.lang.String name)
           throws OberonException
Parameters:
name - the name of the administrative object
Throws:
OberonException - if the name contains invalid characters
Method Detail

setStage

public void setStage(Stage stage)
Link the Validation with the related Stage

Since:
4.0

getStage

public Stage getStage()
Get the related Stage

Since:
4.0

setStageFork

public void setStageFork(java.lang.String stageName)
Set the final destination Stage assigned when the Validation is satisfied


getStageFork

public java.lang.String getStageFork()
Get the final destination Stage


getAccessAsString

public static java.lang.String getAccessAsString(int accessType)
Convert validation access to OOQL equivalent String


addValidateUser

public void addValidateUser(java.lang.String actorType,
                            java.lang.String actorName)
Add access right to validate this Validation to an actor

Parameters:
actorType - the actor type: can be ActorAccess.USER , ActorAccess.TEAM , ActorAccess.ASSIGNMENT
actorName - the actor name

addValidateUser

public void addValidateUser(java.lang.String actorTypeName)
Add access right to validate this Validation to an actor

Parameters:
actorTypeName - actor type: (one of ActorAccess.USER , ActorAccess.TEAM , ActorAccess.ASSIGNMENT) "|" actor name

removeValidateUser

public void removeValidateUser(java.lang.String actorType,
                               java.lang.String actorName)
Remove the actor access right to validate this Validation

Parameters:
actorType - the actor type: can be ActorAccess.USER , ActorAccess.TEAM , ActorAccess.ASSIGNMENT
actorName - the actor name

removeValidateUser

public void removeValidateUser(java.lang.String actorTypeName)
Remove the actor access right to validate this Validation

Parameters:
actorTypeName - actor type: (one of ActorAccess.USER , ActorAccess.TEAM , ActorAccess.ASSIGNMENT) "|" actor name

updateValidateUsers

public void updateValidateUsers(java.util.Vector<java.lang.String> users)
Update the validate users on the basis of a given list

Parameters:
users - list of accesses formatted as actorType|actorName
Since:
4.0

getValidateUsers

public java.util.Vector<java.lang.String> getValidateUsers()
Return the list of validate access rights for this Validation.

Returns:
Vector of access rights formatted as actorType|actorName
See Also:
addValidateUser(String, String)

hasValidateAccess

public boolean hasValidateAccess(Framework framework)
Check if the current framework User has access to validate this Validation (ignore delegations)


hasValidateAccess

public boolean hasValidateAccess(java.lang.String objectID,
                                 Framework framework)
Check if the current framework User has access to validate this Validation for a specific ObjectObj

Parameters:
framework - the current framework
objectID - the ObjectObj ID

hasValidateAccess

public boolean hasValidateAccess(java.lang.String objectID,
                                 java.lang.String userName,
                                 Framework framework)
Check if a User has access to validate this Validation for a specific ObjectObj

Parameters:
userName - the User Name
framework - the current framework
objectID - the ObjectObj ID

addRefuseUser

public void addRefuseUser(java.lang.String actorType,
                          java.lang.String actorName)
Add access right to refuse this Validation to an actor

Parameters:
actorType - the actor type: can be ActorAccess.USER , ActorAccess.TEAM , ActorAccess.ASSIGNMENT
actorName - the actor name

addRefuseUser

public void addRefuseUser(java.lang.String actorTypeName)
Add access right to refuse this Validation to an actor

Parameters:
actorTypeName - actor type: (one of ActorAccess.USER , ActorAccess.TEAM , ActorAccess.ASSIGNMENT) "|" actor name

removeRefuseUser

public void removeRefuseUser(java.lang.String actorType,
                             java.lang.String actorName)
Remove the actor access right to refuse this Validation

Parameters:
actorType - the actor type: can be ActorAccess.USER , ActorAccess.TEAM , ActorAccess.ASSIGNMENT
actorName - the actor name

removeRefuseUser

public void removeRefuseUser(java.lang.String actorTypeName)
Remove the actor access right to refuse this Validation

Parameters:
actorTypeName - actor type: (one of ActorAccess.USER , ActorAccess.TEAM , ActorAccess.ASSIGNMENT) "|" actor name

updateRefuseUsers

public void updateRefuseUsers(java.util.Vector<java.lang.String> users)
Update the refuse users on the basis of a given list

Parameters:
users - list of accesses formatted as actorType|actorName
Since:
4.0

getRefuseUsers

public java.util.Vector<java.lang.String> getRefuseUsers()
Return the list of refuse access rights for this Validation.

Returns:
Vector of access rights formatted as actorType|actorName
See Also:
addRefuseUser(String, String)

hasRefuseAccess

public boolean hasRefuseAccess(Framework framework)
Check if the current framework User has access to refuse this Validation (ignore delegations)


hasRefuseAccess

public boolean hasRefuseAccess(java.lang.String objectID,
                               Framework framework)
Check if the current framework User has access to refuse this Validation for a specific ObjectObj

Parameters:
framework - the current framework
objectID - the ObjectObj ID

hasRefuseAccess

public boolean hasRefuseAccess(java.lang.String objectID,
                               java.lang.String userName,
                               Framework framework)
Check if a User has access to refuse this Validation for a specific ObjectObj

Parameters:
userName - the User Name
framework - the current framework
objectID - the ObjectObj ID

addIgnoreUser

public void addIgnoreUser(java.lang.String actorType,
                          java.lang.String actorName)
Add access right to ignore this Validation to an actor

Parameters:
actorType - the actor type: can be ActorAccess.USER , ActorAccess.TEAM , ActorAccess.ASSIGNMENT
actorName - the actor name

addIgnoreUser

public void addIgnoreUser(java.lang.String actorTypeName)
Add access right to ignore this Validation to an actor

Parameters:
actorTypeName - actor type: (one of ActorAccess.USER , ActorAccess.TEAM , ActorAccess.ASSIGNMENT) "|" actor name

removeIgnoreUser

public void removeIgnoreUser(java.lang.String actorType,
                             java.lang.String actorName)
Remove the actor access right to ignore this Validation

Parameters:
actorType - the actor type: can be ActorAccess.USER , ActorAccess.TEAM , ActorAccess.ASSIGNMENT
actorName - the actor name

removeIgnoreUser

public void removeIgnoreUser(java.lang.String actorTypeName)
Remove the actor access right to ignore this Validation

Parameters:
actorTypeName - actor type: (one of ActorAccess.USER , ActorAccess.TEAM , ActorAccess.ASSIGNMENT) "|" actor name

updateIgnoreUsers

public void updateIgnoreUsers(java.util.Vector<java.lang.String> users)
Update the ignore users on the basis of a given list

Parameters:
users - list of accesses formatted as actorType|actorName
Since:
4.0

getIgnoreUsers

public java.util.Vector<java.lang.String> getIgnoreUsers()
Return the list of ignore access rights for this Validation.

Returns:
Vector of access rights formatted as actorType|actorName
See Also:
addIgnoreUser(String, String)

hasIgnoreAccess

public boolean hasIgnoreAccess(Framework framework)
Check if the current framework User has access to ignore this Validation (ignore delegations)


hasIgnoreAccess

public boolean hasIgnoreAccess(java.lang.String objectID,
                               Framework framework)
Check if the current framework User has access to ignore this Validation for a specific ObjectObj

Parameters:
framework - the current framework
objectID - the ObjectObj ID

hasIgnoreAccess

public boolean hasIgnoreAccess(java.lang.String objectID,
                               java.lang.String userName,
                               Framework framework)
Check if a User has access to ignore this Validation for a specific ObjectObj

Parameters:
userName - the User Name
framework - the current framework
objectID - the ObjectObj ID

equals

public boolean equals(Validation validation)
Check if this Validation is equal to another

Parameters:
validation - the Validation to compare with this Validation

getProperty

public java.lang.String getProperty(java.lang.String propertyName,
                                    java.util.Vector<java.lang.Object> filterArgs,
                                    java.lang.String token,
                                    Framework framework)
Get a property for this Lifecycle-Stage-Validation object by its OOQL identifier

Specified by:
getProperty in class OBBase
Parameters:
propertyName - OOQL property identifier/name (example: stagefork , validate ...)
filterArgs - extra arguments used to compute properties
token - separator token for complex properties
framework - the current framework
Returns:
the property value

getTargetNames

public java.util.Vector<?> getTargetNames(java.lang.String composedName,
                                          java.util.Vector<java.lang.Object> filterArgs,
                                          Framework framework)
Return a Vector of administrative object names extracted by using an OOQL selector

Specified by:
getTargetNames in class OBBase
Parameters:
composedName - OOQL property identifier/name
filterArgs - extra arguments used to compute properties
framework - the current framework
Returns:
a Vector of target names, used to extract their (sub)properties values

toString

public java.lang.String toString()
Return the Validation object properties as a single String

Overrides:
toString in class java.lang.Object

toString

public java.lang.String toString(java.lang.String indent)
Return the Validation object properties as a single String

Parameters:
indent - set the row indent chars

toXML

public org.jdom.Element toXML(Framework framework)
Return the Validation properties as XML element tree

Parameters:
framework - the current framework

toXML

public org.jdom.Element toXML(boolean getImage,
                              boolean fullDump,
                              Framework framework)
Return the Validation properties as XML element tree

Parameters:
fullDump - true to include detailed information
framework - the current framework

fromXML

public void fromXML(org.jdom.Element rootElement)
Load the Validation object from XML element tree

Overrides:
fromXML in class AdminComponent

getCreateCommand

public java.lang.String getCreateCommand(boolean force)
[Inherited but not used]


getSaveCommand

public java.lang.String getSaveCommand(boolean force)
[Inherited but not used]


getCreateCommand

public java.lang.String getCreateCommand(java.lang.String operator)
Return the OOQL command to add this Validation with the settled properties to a Lifecycle-Stage

Parameters:
operator - OOQL operator (example: "add" (update Stage) , or empty (add new Stage) )

getChangeCommand

public java.lang.String getChangeCommand()
Return the OOQL command to update this Lifecycle-Stage-Validation with the settled properties


compareUpdate

public java.lang.String compareUpdate(Validation refValidation,
                                      boolean checkImage,
                                      Framework framework)
                               throws OberonException
Return the OOQL command to update this Stage-Validation object and let it become equals to another reference object.

Parameters:
refValidation - the reference Validation object
framework - the current framework
Throws:
OberonException
See Also:
fromXML(Element)

OBEROn SDK

Copyright © 2008-2014 Mirko Solazzi. All Rights Reserved.