planetj.dataengine.operation
Class Operation

java.lang.Object
  |
  +--planetj.database.Row
        |
        +--planetj.dataengine.PropertyRow
              |
              +--planetj.dataengine.operation.Operation
All Implemented Interfaces:
Cloneable, IBatchProcessObject, IBusinessObject, ICSVRow, IDistributedExecutableObject, IFDFObject, IGuarded, INamedCollection, INavigationObject, IOperation, IRowCreator, IXMLObject, Serializable
Direct Known Subclasses:
HTMLOperation, JavaOperation, SelectionOperation, SQLOperation, UserAuthenticationListOperation, UserAuthorizationListOperation

public class Operation
extends PropertyRow
implements IOperation

Represents an operation that can be executed. An operation may be contained in an Application, or may run independent of any Application. Note that a single Operation object is often shared by multiple users of an Application, so user specific data should not be stored in an Operation.

Author:
PlanetJ Corporation
See Also:
Serialized Form

Nested Class Summary
 
Nested classes inherited from class planetj.database.Row
Row.SpacingRow
 
Field Summary
static String className
          Class name.
 
Fields inherited from class planetj.database.Row
COPY, DELETE, INSERT, MODE_COPY, MODE_DELETE, MODE_INSERT, MODE_READ, MODE_SEARCH, MODE_UNKNOWN, MODE_UPDATE, READ, UPDATE
 
Fields inherited from interface planetj.dataengine.operation.IOperation
ALLOW_DELETES, ALLOW_DETAILS, ALLOW_INSERTS, ALLOW_UPDATES, APPLICABLE_CODE_ONLY, APPLICABLE_ONLY_FOR_DISPLAY, APPLICABLE_ONLY_FOR_SQL, APPLICATION_ID, AUTHORIZE_EXECUTE_OPERATION, AUTO_RUN_ID, AUTO_RUN_STATUS, CACHE_LEVEL, CONNECTION_ALIAS, CURRENT_FIELD, CURRENT_REQUEST, CURRENT_RESPONSE, CURRENT_ROW, CURRENT_ROW_COLLECTION, CURRENT_SERVLET, CURRENT_USER, DEPENDS_ON_ID, DESCRIPTION, DETAILS_JSP_FILE, DISPLAY_COLUMNS, DISPLAY_ORDER, ENCRYPTION_ID, EXECUTION_MODE, EXECUTION_MODE_NO, EXECUTION_MODE_YES, INSTRUCTIONS, JSP_FILE, LABEL, OPERATION_CLASS, OPERATION_CODE, OPERATION_DISPLAY_MODE, OPERATION_DISPLAY_MODE_FULL, OPERATION_DISPLAY_MODE_SKINNY, OPERATION_ID, OPERATION_SET, OPERATION_SQL, OPERATION_TABLE_NAME, OUTPUT_ALIAS, OWNER_ID, PARAMETERS_JSP_FILE, PARENT_ID, PERFORMACE_STATISTICS_ID, PROPERTIES, ROW_CLASS, ROW_COLLECTION_CLASS, ROW_COUNT, SECURITY_ID, SECURITY_TYPE, SET_NAME, THEME_ID, TITLE, TYPE, TYPE_ASSOCIATED_JAVA_OPERATION, TYPE_ASSOCIATED_JOIN, TYPE_ASSOCIATION_1_TO_1, TYPE_ASSOCIATION_1_TO_MANY, TYPE_AUTHENTICATION, TYPE_AUTO_POPULATE, TYPE_AUTORUN_BATCH_PROCESS, TYPE_AUTORUN_EMAIL, TYPE_BLOB_DOWNLOAD, TYPE_EMAIL, TYPE_EXECUTION_GROUP, TYPE_FILE_UPLOAD, TYPE_HTML_CODE, TYPE_HTML_REFERENCE, TYPE_HTML_REFERENCE_ASSOCIATION, TYPE_JAVA_OPERATION, TYPE_JSP_REFERENCE, TYPE_POSSIBLE_VALUES, TYPE_POSSIBLE_VALUES_SEARCH, TYPE_POSSIBLE_VALUES_SELECTOR, TYPE_REFERER_AUTHORIZATION_OPERATION, TYPE_SQL, TYPE_UNKNOWN, TYPE_USER_AUTHENTICATION_LIST_OPERATION, TYPE_USER_AUTHORIZATION_LIST_OPERATION, TYPE_USER_AUTHORIZATION_OPERATION, TYPE_VIEW_SELECTED_ASSOCIATION, USAGE_ID
 
Fields inherited from interface planetj.dataengine.security.IGuarded
TYPE_ID_UNKNOWN, TYPE_NAME_FIELD, TYPE_NAME_SQLOPERATION, TYPE_SECURED_BY_LEVEL, TYPE_SECURED_BY_OPERATION, TYPE_UNSECURED
 
Constructor Summary
Operation()
           
 
Method Summary
 IMagicRequest createMagicRequest(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Creates a MagicRequest for viewing this operation.
 IMagicRequest createMagicRequest(String id, Field basedOnField, Row basedOnRow, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Creates a MagicRequest for viewing this operation.
 IMagicRequest createMagicRequest(String id, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Creates a MagicRequest for viewing this operation.
 IMagicRequest createMagicRequest(String id, Row basedOnRow, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Creates a MagicRequest for viewing this operation.
 Row createRow(Row row)
          Initializes this SQLOperation as it is retrieved from the DB
 Object execute(ExecutingContext ec)
          Executes this operation from the given executing context and Field.
 Object execute(ExecutingContext ec, Field field)
          Executes this operation from the given executing context and Field.
 Object execute(ExecutingContext ed, Row row)
          Executes this operation from the given executing context and Row.
 Application getApplication()
          Gets the Application assoicated with this Operation (may be null if there is no such application).
 int getApplicationId()
          Gets the ID of this SQLOperation's Application
 Integer getApplicationIdAsInteger()
          Gets the ID of this SQLOperation's Application
 int getAutoRunId()
          Gets the autorun ID of this SQLOperation
 AutoRunOperation getAutoRunOperation()
          Get this operation's auto-run operation, which describes how and if this operation should be automatically run.
 int getAutoRunStatus()
          Gets the autorun status of this operation.
 RowCollection getChildren()
          Gets the children Operations of this Operation (may be null if Operation does not have any children)
 String getConnectionAlias()
          Get the alias of the system where this Operation's data is located.
 String getDefaultOperationCode()
          Return a default string to use on the operation field.
 String getDeleteConfirmationMessage()
          Get the message used when deleting an operation.
 RowCollection getDependants()
          Gets the dependant Operations of this Operation (may be null if Operation does not have any children)
 Operation getDependsOn()
          Gets the Operation this Operation depends on (may be null if Operation does not depend on another Operation)
 int getDependsOnId()
          Get the id of the Operation this Operation depends on.
 Integer getDependsOnIdAsInteger()
          Get the id of the Operation this Operation depends on.
 String getDetailsJspFile()
          Gets the JSP used to display this SQLOperation's details
 List getDisplayColumns()
          Gets the display columns as Strings in a List
 String getDisplayColumnsAsString()
          Gets the display columns, separated by commas in a String
 String[] getDisplayColumnsAsStringArray()
          Gets the display columns as Strings in an Array.
 int getDisplayOrder()
          Gets this SQLOperation's display order.
 int getId()
          Gets the id of this Operation
 Integer getIdAsInteger()
          Gets the id of this operation.
 String getInstructions()
          Gets this SQLOperation's instructions
 String getJspFile()
          Gets this SQLOperation's JSP file
 String getLabel()
          Gets the label for this SQLOperation .
 LayoutDisplayPropertyGroup getLayoutProperties()
          Gets this Operation's layout properties.
 IOperationContext getNewContext()
          Gets a new IOperationContext for this operation.
static Class getOperationClass(int operationType)
          Gets the Operation java class which should be used to represent an operation of the specified type
 String getOperationCode()
          Gets this SQLOperation's SQL
 String getOperationSetName()
          Gets this SQLOperation's operation set name.
 String getOutputAlias()
          Gets this SQLOperation's Output Alias
 int getOwnerId()
          Gets the owner ID of this SQLOperation
 Field getOwnerIdField()
          Returns the Owner Id Field
 Operation getParent()
          Gets the parent Operation of this Operation (may be null if Operation does not have a parent)
 int getParentId()
          Get the parent id of this Operation.
 Integer getParentIdAsInteger()
          Get the parent id of this operation.
 String getPropertyFieldName()
          Get the name of the Field containing this Row's properties..
 Class getRowClass()
          Gets the Row class to use when this SQLOperation's query is run (may be null)
 String getRowClassName()
          Gets the name of the Row class to use when this SQLOperation's query is run (may be null)
 Class getRowCollectionClass()
          Gets the RowCollection class to use when this SQLOperation's query is run (may be null)
 String getRowCollectionClassName()
          Gets the name of the RowCollection class to use when this SQLOperation's query is run (may be null)
 int getRowCount()
          Gets the row count to use when retrieving rows for this SQLOperation
 PropertyGroupList getRowPropertyGroups()
          Gets this SQLOperation's operation set name.
 int getSecurityId()
          Gets the security ID of this SQLOperation
 int getSecurityType()
          Check whether this Operation is protected (secured)
 int getType()
          Gets the type of this Operation.
 int getUsageId()
          Gets the usageId of the field.
 String getUserMessageForOperation(int pMode)
          Returns a message for the user based on the Mode of the Row
 boolean hasDependants()
          Tests to see if this Operation has any dependant operations.
 int insert(SQLContext context)
          Inserts this Row into its table.
 boolean isAllowDeletes()
          Tests whether or not rows can be deleted from this results of this SQLOperation if this SQLOperation is a query
 boolean isAllowDetails()
          Tests whether or not the details of a row in this ListView can be viewed
 boolean isAllowInserts()
          Tests whether or not rows can be inserted into the results of this SQLOperation
 boolean isAllowUpdates()
          Tests whether or not the results of this SQLOperation can be updated, if this SQLOperation is a query
 boolean isAssociation()
          Check if this Operation is an association.
 boolean isAuthentication()
          Test if this SQLOperation is a Authentication type.
 boolean isAuthorizedForExecution(Row pRow, ExecutingContext pEc)
          Test for authority to execute this operation.
 boolean isAutoPopulate()
          Test if this SQLOperation is an Auto Populate.
 boolean isAutoRunOperation()
          Tests if this operation is an autorun operation.
 boolean isBlobDownload()
          Test if this SQLOperation is a Blob Download.
 boolean isChild()
          Test to see if this Operation has a parent Operation.
 boolean isContextCurrent(IOperationContext context)
          Test if the context was created from this operation, and if the contents of the context are still valid.
 boolean isDependant()
          Test to see if this Operation depends on another Operation.
 boolean isDisplayable(ExecutingContext pEc)
          Test if this SQLOperation is displayable
 boolean isExecutionGroup()
          Check to see if this operation is an execution group.
 boolean isFileUpload()
          Test if this SQLOperation is a File Upload.
 boolean isHtml()
          Tests if this operation is an HTML operation
 boolean isHTMLAssociation()
          Check if this Operation is an HTML assocation type.
 boolean isHtmlCode()
          Check to see if this operation is HTML code.
 boolean isHtmlReference()
          Check to see if this operation is a HTML reference.
 boolean isHtmlReferenceAssociation()
          Check to see if this operation is an HTML reference association.
 boolean isJava()
          Tests if this operation is an Java operation
 boolean isJavaAssociation()
          Check to see if this operation is a Associated Java Operation
 boolean isJSPReference()
          Check to see if this operation is a JSP reference.
 boolean isOneToManyAssociation()
          Test if this SQLOperation is a 1-Many association.
 boolean isOneToOneAssociation()
          Test if this SQLOperation is a 1-1 association.
 boolean isParent()
          Test to see if this Operation has any children Operations.
 boolean isPossibleValues()
          Test if this SQLOperation is a Possible Values type.
 boolean isPossibleValuesSearch()
          Test if this SQLOperation is a Possible Values Search type.
 boolean isPossibleValuesSelector()
          Test if this SQLOperation is a PossibleValuesSelector.
 boolean isSQL()
          Test if this SQLOperation is a SQL type.
 boolean isSQLAssociation()
          Test if this SQLOperation is a Association type.
 boolean isUserAuthenticationListOperation()
          Test if this SQLOperation is a User Authentication List Operation type.
 boolean isUserAuthorizationListOperation()
          Test if this SQLOperation is a User Authorization List Operation type.
 boolean isUserAuthorizationOperation()
          Test if this SQLOperation is a User Authorization Operation type.
 boolean isUserPromptingRequired()
          Does the user need to be prompted for input.
 void setDefaultOperationCode()
          Sets the default operation code for this operation instance.
 void setDisplayColumns(List cols)
          Sets the display columns as Strings in a List
 void setDisplayColumns(String value)
          Sets this display columns for this SQLOperation as a String, containing the column names separated by commas
 void setDisplayColumns(String[] cols)
          Sets the display columns as Strings in an Array
 void setId(int value)
          Sets the id of this Operation
 void setId(Integer value)
          Sets the id of this Operation
 void setRowClass(Class newRowClass)
          Sets the Java class to use when retrieving this SQLOperation's rows
 void setRowClassName(String rowClass)
          Sets the Java class to use when retrieving this SQLOperations's rows
 void setRowCollectionClass(Class newRowCollectionClass)
          Sets the Java class to use when retrieving this SQLOperation's row collection
 void setRowCollectionClassName(String rowCollectionClass)
          Sets the Java class to use when retrieving this SQLOperation's row collection
 void setRowCount(int value)
          Sets this SQLOperation's row count
 void setUsageId(int usageid)
          Gets the usageId of the field.
 Row statusChanged(Field pField, ExecutingContext ec)
          Invoked when a status change takes place on of this Row's fields.
 String toString()
          Returns a String representation of this Row.
 int update(Connection conn, ExecutingContext ec)
          Updates the database with the values in this Row.
 boolean validate(ExecutingContext ec)
          Validate this Row based on it's configuration and field values.
 
Methods inherited from class planetj.dataengine.PropertyRow
getProperties, getRowPropertyGroup, getRowPropertyGroups, setProperties, transferDataTo
 
Methods inherited from class planetj.database.Row
add, add, addObject, addPropertyChangeListener, addPropertyChangeListener, addRowEventListener, addRowEventListeners, addTable, appendDisplayType, batchProcess, clearFields, clearTables, clearValidationException, clone, cloneRow, commitFieldValues, commitFieldValues, commitFieldValues, concatenateFieldFullLengthValues, concatenateFieldValues, containsField, copy, copyIntoRowFieldsWithCommonFieldNames, copyIntoRowFieldsWithCommonFieldNames, copyIntoRowFieldsWithCommonUsageIds, copyIntoRowFieldsWithGivenFieldNames, copyIntoRowFieldsWithGivenFieldNames, create, create, create, create, create, create, create, create, create, create, create, create, create, create, create, defaultMerge, delete, delete, delete, delete, deleteObject, divide, duplicateKey, equals, equals, equalsInstance, executeDistributedAction, fieldHasPossibleValuesSQLOperation, getAssociation, getAssociation, getAssociationByOperationUsageId, getAssociationOperation, getAttribute, getColumnSpan, getCompleteRow, getCompleteRow, getConfigProperty, getCopiedFieldValues, getCSVRow, getCSVRow, getDatabaseRow, getDatabaseRow, getDeleteConfirmation, getDisplayValue, getDistributedRequestorURL, getExternalName, getExternalNames, getFDFData, getFDTable, getField, getField, getField, getFieldDefaultValue, getFieldDescriptor, getFieldDescriptor, getFieldDescriptor, getFieldDescriptorsWithUsage, getFieldDescriptorsWithUsageId, getFieldDescriptorWithUsageId, getFieldDisplayValue, getFieldNames, getFields, getFields, getFieldSets, getFieldSQLObject, getFieldsToDisplay, getFieldsToDisplayStrict, getFieldsToDisplayStrict, getFieldStyleClass, getFieldValue, getFieldWithUsageId, getHeaderText, getLibraryName, getMaxFieldLengths, getMaxFieldLengths, getMaxInsertRetries, getMetaDataSystemAlias, getNamed, getNamesOfUpdatedFields, getNavigationKey, getNavigationListKey, getPercentage, getPhysicalFieldNames, getPropertyGroup, getPropertyGroups, getPropertyGroups, getRowCollection, getRowDisplayAttributes, getRowDisplayAttributes, getRowKey, getSecuredTypeId, getSecuredTypeName, getSQL, getSQLContext, getStaticAttribute, getSum, getSystemAlias, getTable, getTable, getTableName, getTables, getTimestamp, getUpdatedFields, getUseWOWLibrary, getValidationExceptions, getValueAsBoolean, getValueAsByte, getValueAsDate, getValueAsDate, getValueAsDouble, getValueAsDouble, getValueAsFloat, getValueAsFullLengthString, getValueAsInt, getValueAsLong, getValueAsNumber, getValueAsNumber, getValueAsShort, getValueAsString, getValueAsString, getValueByUsageId, getValues, getXMLData, getXMLData, getXMLHeaderData, handleDistributed, hasChildRows, hasMultipleStyleClasses, hasPropertyChangeListeners, insert, insert, insert, is, isARow, isARowCollection, isChanged, isChangedRealTime, isChangedSinceLastCheck, isCloneNeeded, isContainsAllFields, isCopyable, isDeletable, isDistinctRow, isDistributed, isEditable, isEmpty, isFieldApplicable, isFieldAuthorizedForEdit, isFieldAuthorizedForRead, isFieldDisplayable, isFieldReadOnly, isFieldRequired, isFieldRequiredOnSearch, isFieldsChanged, isFieldValueNotBlank, isFieldValuesDatabaseDefaults, isGenerateChildRows, isGroupByRow, isGuarded, isHasColumnNames, isInARowCollection, isIncrementorResetAfterMaxInsertRetries, isInitializeDerivedFieldsEnabled, isJoinedRow, isKeyFieldsPresent, isLogicalRow, isMultipleDeleteEnabled, isPhysicalRow, isPropertyChangeEventsEnabled, isReturningFromPossibleValuesSearch, isRowKeyed, isSelectable, isUnionRow, isValidateRequired, isValidationRequiredForAutoPopulate, isViewable, iterator, merge, newField, newField, newField, newField, populate, postCreate, prepareForDetails, prepareFromFieldNames, removeNavigationKey, removePropertyChangeListener, removePropertyChangeListener, removeRowEventListener, removeRowEventListeners, replaceField, replaceFieldValues, rollbackChanges, setAttribute, setDistributed, setDistributedRequestorURL, setDistributedTargetURL, setFieldInitialValue, setFieldValue, setFieldValue, setFieldValue, setFieldValueAsString, setFieldValueAsString, setFieldValuesAsDate, setFieldValuesToDefault, setFieldValuesWithCommonFieldNames, setFieldValuesWithCommonFieldNames, setFieldValuesWithCommonUsageIds, setFieldValueToDefault, setMultipleDeleteEnabled, setNavigationKey, setPropertyChangeEventsEnabled, setPropertyGroups, setReturningFromPossibleValuesSearch, setSavepoint, setSavepoint, setSavepoint, setStaticAttribute, setTables, setTables, setUseWOWLibrary, setValidateRequired, setValues, size, splitAndSetFieldValues, toCSV, toDOC, toDOC, toFDF, toPDF, toPDF, toString, toUpperCase, toXML, transferDataTo, update, update, update, updateObject, validate, validate, validateRowOperation
 
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

className

public static final String className
Class name.

Constructor Detail

Operation

public Operation()
Method Detail

getDeleteConfirmationMessage

public String getDeleteConfirmationMessage()
Get the message used when deleting an operation.

Overrides:
getDeleteConfirmationMessage in class Row

createMagicRequest

public IMagicRequest createMagicRequest(String id,
                                        javax.servlet.http.HttpServletRequest request,
                                        javax.servlet.http.HttpServletResponse response)
Creates a MagicRequest for viewing this operation.


createMagicRequest

public IMagicRequest createMagicRequest(String id,
                                        Field basedOnField,
                                        Row basedOnRow,
                                        javax.servlet.http.HttpServletRequest request,
                                        javax.servlet.http.HttpServletResponse response)
                                 throws CMException
Creates a MagicRequest for viewing this operation.

CMException

createMagicRequest

public IMagicRequest createMagicRequest(String id,
                                        Row basedOnRow,
                                        javax.servlet.http.HttpServletRequest request,
                                        javax.servlet.http.HttpServletResponse response)
                                 throws CMException
Creates a MagicRequest for viewing this operation.

CMException

createMagicRequest

public IMagicRequest createMagicRequest(javax.servlet.http.HttpServletRequest request,
                                        javax.servlet.http.HttpServletResponse response)
Creates a MagicRequest for viewing this operation.


createRow

public Row createRow(Row row)
              throws CMException
Initializes this SQLOperation as it is retrieved from the DB

Specified by:
createRow in interface IRowCreator
Overrides:
createRow in class PropertyRow
Parameters:
row - A Row containing data read from the database (it will always be equal to this)
Returns:
A Row which the DataEngine will add to a RowCollection
CMException

execute

public Object execute(ExecutingContext ec)
               throws CMException
Executes this operation from the given executing context and Field. Subclasses may override as needed. This method primarily servers as a convenience method for execute(ExecutingContext, Row).

Parameters:
ec - ExecutingContext in which to execute this Operation
CMException

execute

public Object execute(ExecutingContext ec,
                      Field field)
               throws CMException
Executes this operation from the given executing context and Field. Subclasses may override as needed. This method primarily servers as a convenience method for execute(ExecutingContext, Row).

Parameters:
ec - ExecutingContext in which to execute this Operation
field - Field containing a value and Row with values that may be used in execution of this Operation
CMException

execute

public Object execute(ExecutingContext ed,
                      Row row)
               throws CMException
Executes this operation from the given executing context and Row. Subclasses should override to provide functionality.

Parameters:
row - Row containing values that may be used in execution of this Operation
CMException

getApplication

public Application getApplication()
                           throws CMException
Gets the Application assoicated with this Operation (may be null if there is no such application).

CMException

getApplicationId

public int getApplicationId()
Gets the ID of this SQLOperation's Application


getApplicationIdAsInteger

public Integer getApplicationIdAsInteger()
Gets the ID of this SQLOperation's Application


getAutoRunStatus

public int getAutoRunStatus()
Gets the autorun status of this operation. If no value is set, the operation's auto run status is enabled


getAutoRunId

public int getAutoRunId()
Gets the autorun ID of this SQLOperation


getAutoRunOperation

public AutoRunOperation getAutoRunOperation()
                                     throws CMException
Get this operation's auto-run operation, which describes how and if this operation should be automatically run. Null is returned if this operation does not have a auto-run operation

CMException

getChildren

public RowCollection getChildren()
                          throws CMException
Gets the children Operations of this Operation (may be null if Operation does not have any children)

Overrides:
getChildren in class Row
Returns:
children Operations (null if no children exists)
CMException

getConnectionAlias

public String getConnectionAlias()
Get the alias of the system where this Operation's data is located. This may be different than the alias of the system where the Operation table itself is located, which is returned by the getSystemAlias() method. If no connection alias has been specified for this Operation, then the connection alias of this Operation's application (if this Operation has an application) is returned.

Returns:
alias for system where this Operation's data resides.

getDefaultOperationCode

public String getDefaultOperationCode()
Return a default string to use on the operation field. Subclasses can override to provide a context sensitive op code. NOTE: This statement is used because on the iSeries, all systems have a table in library QIWS called QCUSTCDT.


getDependants

public RowCollection getDependants()
                            throws CMException
Gets the dependant Operations of this Operation (may be null if Operation does not have any children)

Returns:
dependant Operations (null if no dependants exists)
CMException

getDependsOn

public Operation getDependsOn()
                       throws CMException
Gets the Operation this Operation depends on (may be null if Operation does not depend on another Operation)

CMException

getDependsOnId

public int getDependsOnId()
Get the id of the Operation this Operation depends on.

Returns:
depends on id; -1 if Operation doesn't depend on another Operation

getDependsOnIdAsInteger

public Integer getDependsOnIdAsInteger()
Get the id of the Operation this Operation depends on.

Returns:
id

getDetailsJspFile

public String getDetailsJspFile()
Gets the JSP used to display this SQLOperation's details


getDisplayColumns

public List getDisplayColumns()
Gets the display columns as Strings in a List


getDisplayColumnsAsString

public String getDisplayColumnsAsString()
Gets the display columns, separated by commas in a String


getDisplayColumnsAsStringArray

public String[] getDisplayColumnsAsStringArray()
Gets the display columns as Strings in an Array. If no columns are specified, null is returned


getDisplayOrder

public int getDisplayOrder()
Gets this SQLOperation's display order. The display order determine how listings of SQLOperations are ordered


getId

public int getId()
Gets the id of this Operation


getIdAsInteger

public Integer getIdAsInteger()
Gets the id of this operation.

Returns:
id

getInstructions

public String getInstructions()
Gets this SQLOperation's instructions


getJspFile

public String getJspFile()
Gets this SQLOperation's JSP file


getLabel

public String getLabel()
Gets the label for this SQLOperation . The label is the text displayed on the link to the SQLOperation


getLayoutProperties

public LayoutDisplayPropertyGroup getLayoutProperties()
Gets this Operation's layout properties.


getNewContext

public final IOperationContext getNewContext()
                                      throws CMException
Gets a new IOperationContext for this operation.

CMException

getOperationClass

public static Class getOperationClass(int operationType)
Gets the Operation java class which should be used to represent an operation of the specified type


getOutputAlias

public String getOutputAlias()
Gets this SQLOperation's Output Alias


getOperationCode

public String getOperationCode()
Gets this SQLOperation's SQL


getOperationSetName

public String getOperationSetName()
Gets this SQLOperation's operation set name. The OperationSet determines how listings of SQLOperations are grouped.


getOwnerId

public int getOwnerId()
Gets the owner ID of this SQLOperation


getOwnerIdField

public Field getOwnerIdField()
Returns the Owner Id Field

See Also:
IOwner

getParent

public Operation getParent()
                    throws CMException
Gets the parent Operation of this Operation (may be null if Operation does not have a parent)

Returns:
parent Operation (null if no parent exists)
CMException

getParentId

public int getParentId()
Get the parent id of this Operation.

Returns:
parent id; -1 if Operation does not have a parent Operation

getParentIdAsInteger

public Integer getParentIdAsInteger()
Get the parent id of this operation.

Returns:
id

getPropertyFieldName

public String getPropertyFieldName()
Get the name of the Field containing this Row's properties..

Specified by:
getPropertyFieldName in class PropertyRow

getRowClass

public Class getRowClass()
Gets the Row class to use when this SQLOperation's query is run (may be null)


getRowClassName

public String getRowClassName()
Gets the name of the Row class to use when this SQLOperation's query is run (may be null)


getRowCollectionClass

public Class getRowCollectionClass()
Gets the RowCollection class to use when this SQLOperation's query is run (may be null)


getRowCollectionClassName

public String getRowCollectionClassName()
Gets the name of the RowCollection class to use when this SQLOperation's query is run (may be null)


getRowCount

public int getRowCount()
Gets the row count to use when retrieving rows for this SQLOperation


getRowPropertyGroups

public PropertyGroupList getRowPropertyGroups()
Gets this SQLOperation's operation set name. The OperationSet determines how listings of SQLOperations are grouped.

Overrides:
getRowPropertyGroups in class PropertyRow

getSecurityId

public int getSecurityId()
Gets the security ID of this SQLOperation


getSecurityType

public int getSecurityType()
Check whether this Operation is protected (secured)

Specified by:
getSecurityType in interface IGuarded
Overrides:
getSecurityType in class Row
Returns:
boolean

getType

public int getType()
Gets the type of this Operation.


getUsageId

public int getUsageId()
Gets the usageId of the field. A FieldDescriptor can be assigned a usageId to identify a particular usage. This can be used by powerful method to dynamically copy data with the same usageId. UI code can be written to look for fields with a particular usageId such as an electronic store where JSPs might anticipate a RowCollection coming in with usage fields for ItemId, ItemImage, Item Price, etc. It is the ultimate decoupling of UI, business logic, and Data See the documentaiton since it's pretty complicated especially for you.


getUserMessageForOperation

public String getUserMessageForOperation(int pMode)
Returns a message for the user based on the Mode of the Row

Overrides:
getUserMessageForOperation in class Row
Returns:
String message for the user
See Also:
(see Row constants to find the modes.

hasDependants

public boolean hasDependants()
                      throws CMException
Tests to see if this Operation has any dependant operations.

CMException

insert

public int insert(SQLContext context)
           throws CMException
Inserts this Row into its table.

Overrides:
insert in class PropertyRow
Returns:
The number of Rows that were inserted
CMException

isAllowDeletes

public boolean isAllowDeletes()
Tests whether or not rows can be deleted from this results of this SQLOperation if this SQLOperation is a query


isAllowDetails

public boolean isAllowDetails()
Tests whether or not the details of a row in this ListView can be viewed


isAllowInserts

public boolean isAllowInserts()
Tests whether or not rows can be inserted into the results of this SQLOperation


isAllowUpdates

public boolean isAllowUpdates()
Tests whether or not the results of this SQLOperation can be updated, if this SQLOperation is a query


isAssociation

public boolean isAssociation()
Check if this Operation is an association.


isAuthentication

public boolean isAuthentication()
Test if this SQLOperation is a Authentication type.


isAuthorizedForExecution

public boolean isAuthorizedForExecution(Row pRow,
                                        ExecutingContext pEc)
                                 throws CMException
Test for authority to execute this operation.

CMException

isAutoPopulate

public boolean isAutoPopulate()
Test if this SQLOperation is an Auto Populate.


isAutoRunOperation

public boolean isAutoRunOperation()
Tests if this operation is an autorun operation. This method is necessary - sometimes autorun operations may be stored in a SQLOperation object.


isBlobDownload

public boolean isBlobDownload()
Test if this SQLOperation is a Blob Download.


isChild

public boolean isChild()
Test to see if this Operation has a parent Operation.


isContextCurrent

public boolean isContextCurrent(IOperationContext context)
                         throws CMException
Test if the context was created from this operation, and if the contents of the context are still valid. (Changing an operation should invalidate all of the contexts created from it)

Returns:
true if invoking getNewContext() on this object would return a context equal to the one passed in
CMException

isDependant

public boolean isDependant()
                    throws CMException
Test to see if this Operation depends on another Operation.

CMException

isDisplayable

public boolean isDisplayable(ExecutingContext pEc)
Test if this SQLOperation is displayable


isExecutionGroup

public boolean isExecutionGroup()
Check to see if this operation is an execution group.


isFileUpload

public boolean isFileUpload()
Test if this SQLOperation is a File Upload.


isHtml

public boolean isHtml()
Tests if this operation is an HTML operation


isHTMLAssociation

public boolean isHTMLAssociation()
Check if this Operation is an HTML assocation type.


isHtmlCode

public boolean isHtmlCode()
Check to see if this operation is HTML code.


isHtmlReference

public boolean isHtmlReference()
Check to see if this operation is a HTML reference.


isHtmlReferenceAssociation

public boolean isHtmlReferenceAssociation()
Check to see if this operation is an HTML reference association.


isJava

public boolean isJava()
Tests if this operation is an Java operation


isJavaAssociation

public boolean isJavaAssociation()
Check to see if this operation is a Associated Java Operation


isJSPReference

public boolean isJSPReference()
Check to see if this operation is a JSP reference.


isOneToManyAssociation

public boolean isOneToManyAssociation()
Test if this SQLOperation is a 1-Many association.


isOneToOneAssociation

public boolean isOneToOneAssociation()
Test if this SQLOperation is a 1-1 association.


isParent

public boolean isParent()
                 throws CMException
Test to see if this Operation has any children Operations.

CMException

isPossibleValues

public boolean isPossibleValues()
Test if this SQLOperation is a Possible Values type.


isPossibleValuesSearch

public boolean isPossibleValuesSearch()
Test if this SQLOperation is a Possible Values Search type.


isPossibleValuesSelector

public boolean isPossibleValuesSelector()
Test if this SQLOperation is a PossibleValuesSelector.


isSQL

public boolean isSQL()
Test if this SQLOperation is a SQL type.


isSQLAssociation

public boolean isSQLAssociation()
Test if this SQLOperation is a Association type.


isUserAuthenticationListOperation

public boolean isUserAuthenticationListOperation()
Test if this SQLOperation is a User Authentication List Operation type.


isUserAuthorizationListOperation

public boolean isUserAuthorizationListOperation()
Test if this SQLOperation is a User Authorization List Operation type.


isUserAuthorizationOperation

public boolean isUserAuthorizationOperation()
Test if this SQLOperation is a User Authorization Operation type.


isUserPromptingRequired

public boolean isUserPromptingRequired()
                                throws CMException
Does the user need to be prompted for input. Subclasses should override if they need it.

CMException

setDefaultOperationCode

public void setDefaultOperationCode()
                             throws CMException
Sets the default operation code for this operation instance. This method is called if the WOW user changes the operation type which causes a stateChange operation which in turn calls this operation. We then update the OP CODE field within a WOW operation to be something useful for the type of operation.

CMException

setDisplayColumns

public void setDisplayColumns(String[] cols)
                       throws CMException
Sets the display columns as Strings in an Array

CMException

setDisplayColumns

public void setDisplayColumns(String value)
                       throws CMException
Sets this display columns for this SQLOperation as a String, containing the column names separated by commas

CMException

setDisplayColumns

public void setDisplayColumns(List cols)
                       throws CMException
Sets the display columns as Strings in a List

CMException

setId

public void setId(int value)
           throws CMException
Sets the id of this Operation

CMException

setId

public void setId(Integer value)
           throws CMException
Sets the id of this Operation

CMException

setRowClass

public void setRowClass(Class newRowClass)
                 throws CMException
Sets the Java class to use when retrieving this SQLOperation's rows

CMException

setRowClassName

public void setRowClassName(String rowClass)
                     throws CMException
Sets the Java class to use when retrieving this SQLOperations's rows

CMException

setRowCollectionClass

public void setRowCollectionClass(Class newRowCollectionClass)
                           throws CMException
Sets the Java class to use when retrieving this SQLOperation's row collection

CMException

setRowCollectionClassName

public void setRowCollectionClassName(String rowCollectionClass)
                               throws CMException
Sets the Java class to use when retrieving this SQLOperation's row collection

CMException

setRowCount

public void setRowCount(int value)
                 throws CMException
Sets this SQLOperation's row count

CMException

setUsageId

public void setUsageId(int usageid)
                throws CMException
Gets the usageId of the field. A FieldDescriptor can be assigned a usageId to identify a particular usage. This can be used by powerful method to dynamically copy data with the same usageId. UI code can be written to look for fields with a particular usageId such as an electronic store where JSPs might anticipate a RowCollection coming in with usage fields for ItemId, ItemImage, Item Price, etc. It is the ultimate decoupling of UI, business logic, and Data See the documentaiton since it's pretty complicated especially for you.

CMException

statusChanged

public Row statusChanged(Field pField,
                         ExecutingContext ec)
                  throws CMException
Invoked when a status change takes place on of this Row's fields. Subclasses may override this method, but they should call it on the superclass when they do.

Overrides:
statusChanged in class Row
Parameters:
pField - The field whose status has changed
ec - The current executing context
Returns:
The "new" row resulting from the status change. Usually this is this same row, but a row may choose to replace itself with another row and return that other row.
CMException

toString

public String toString()
Returns a String representation of this Row.

Overrides:
toString in class Object
Returns:
String

update

public int update(Connection conn,
                  ExecutingContext ec)
           throws CMException
Updates the database with the values in this Row. If concurrent alterations to the database prevent this row from being updated, a ConcurrentAlterationException is thrown.

Overrides:
update in class PropertyRow
Parameters:
conn - The connection to use for the update
Returns:
The number of updated rows
CMException

validate

public boolean validate(ExecutingContext ec)
                 throws CMException
Validate this Row based on it's configuration and field values.

Overrides:
validate in class Row
Parameters:
ec - current context in which application is executing
Returns:
true, if Row and Fields are valid; false otherwise.
CMException