@Deprecated
public abstract class EventHandlerBase
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
EventHandlerBase.DbField
Deprecated.
Data structure describing a single JSON field formatting parameters.
|
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
CONTENT_TYPE_TEXT_UFT8
Deprecated.
|
static java.lang.String |
INPUT_TRANSLATABLE
Deprecated.
Input & Output parameters names used in helper methods.
|
protected org.apache.log4j.Logger |
log
Deprecated.
Logger instance that can be used by subclasses.
|
static java.lang.String |
OUTPUT_TRANSLATABLE
Deprecated.
Description of the Field
|
static java.lang.String |
PREFERENCES_MAIL_HOST
Deprecated.
|
static java.lang.String |
PREFERENCES_MAIL_HOST_PASSWORD
Deprecated.
|
static java.lang.String |
PREFERENCES_MAIL_HOST_PORT
Deprecated.
|
static java.lang.String |
PREFERENCES_MAIL_HOST_USER_ID
Deprecated.
|
static java.lang.String |
RESPONSE
Deprecated.
Key for the HttpServletResponse value in the Map
|
Modifier | Constructor and Description |
---|---|
protected |
EventHandlerBase()
Deprecated.
Parameterless constructor for subclasses.
|
Modifier and Type | Method and Description |
---|---|
static java.io.InputStream |
applyViewXsl(EventHandlerContext context,
java.lang.String viewName,
org.dom4j.Document xml,
java.lang.String xslPath,
boolean isPdf)
Deprecated.
Do not use. This method is for 1.0 views.
|
static void |
checkAddInLicense(java.lang.String applicationName,
java.lang.String applicationSecurityKey)
Deprecated.
Checks that:
|
static com.archibus.datasource.data.DataRecord |
createRecordFromJSON(org.json.JSONObject object)
Deprecated.
Do not use.
|
static java.util.List<com.archibus.datasource.data.DataRecord> |
createRecordsFromJSON(org.json.JSONArray array)
Deprecated.
Do not use.
|
protected static com.archibus.db.ViewField.Immutable |
createVirtualField(EventHandlerContext context,
java.lang.String javaClass,
java.lang.String fieldName,
boolean localizedFormat)
Deprecated.
Create virtual field, mapped to javaClass type.
|
static java.lang.String |
determineXsltFilePath(EventHandlerContext context,
java.lang.String viewName)
Deprecated.
Do not use. This method is for 1.0 views.
|
protected static void |
executeDbAdd(EventHandlerContext context,
java.lang.String tableName,
java.util.Map values)
Deprecated.
Do not use. Use
DataSource#saveRecord() instead. |
static void |
executeDbCommit(EventHandlerContext context)
Deprecated.
Do not use. Use
SqlUtils.commit() instead. |
static void |
executeDbDelete(EventHandlerContext context,
java.lang.String tableName,
java.util.Map aValues)
Deprecated.
Do not use. Use
DataSource#deleteRecord() instead. |
static void |
executeDbRollback(EventHandlerContext context)
Deprecated.
Do not use. Use
SqlUtils.rollback() instead. |
static void |
executeDbSave(EventHandlerContext context,
java.lang.String tableName,
java.util.Map values)
Deprecated.
Do not use. Use
DataSource#saveRecord() instead. |
static void |
executeDbSave(EventHandlerContext context,
java.lang.String tableName,
java.util.Map values,
java.util.Map oldFieldValues,
boolean newRecord)
Deprecated.
Do not use. Use
DataSource#saveRecord() instead. |
static void |
executeDbSql(EventHandlerContext context,
java.lang.String sql,
boolean updatedRecordsRequired)
Deprecated.
Do not use. Use
SqlUtils#executeUpdate() instead. |
static void |
executeDbSql(EventHandlerContext context,
java.lang.String tableName,
java.lang.String sql,
boolean updatedRecordsRequired)
Deprecated.
Do not use. Use
SqlUtils#executeUpdate() instead. |
protected static void |
executeDbSqlCommands(EventHandlerContext context,
java.util.Vector sqlCommands,
boolean updatedRecordsRequired)
Deprecated.
Do not use. Use
SqlUtils#executeUpdate() instead. |
static void |
executeDbSqlNoParameters(EventHandlerContext context,
java.lang.String sql,
boolean updatedRecordsRequired)
Deprecated.
Do not use. Use
SqlUtils#executeUpdate() instead. |
static java.lang.String |
expandParameters(com.archibus.schema.DbServer.Immutable dbServer,
com.archibus.config.ContextCacheable.Immutable context,
java.util.Map parameters,
java.lang.String stringWithParameters)
Deprecated.
Do not use # parameters in application code. Use ${} parameters instead.
|
static java.lang.String |
expandParameters(EventHandlerContext context,
java.lang.String stringWithParameters)
Deprecated.
Do not use # parameters in application code. Use ${} parameters instead.
|
static java.util.Map |
filterWithPrefix(java.util.Map values,
java.lang.String prefix)
Deprecated.
Do not use.
|
static java.lang.String |
formatFieldValue(EventHandlerContext context,
java.lang.Object aValue,
java.lang.String javaClass,
java.lang.String fieldName,
boolean localizedFormat)
Deprecated.
Do not use.
|
static java.lang.String |
formatMessage(EventHandlerContext context,
java.lang.String message,
java.lang.Object[] args)
Deprecated.
Formats text message.
|
static java.lang.String |
formatSqlAddDays(EventHandlerContext context,
java.lang.String aIsoDate,
java.lang.String aDaysToAdd)
Deprecated.
Do not use.
|
static java.lang.String |
formatSqlAddDaysToExpression(EventHandlerContext context,
java.lang.String aDateExp,
java.lang.String aDaysToAdd)
Deprecated.
Do not use.
|
static java.lang.String |
formatSqlAddMinutes(EventHandlerContext context,
java.lang.String aIsoTime,
java.lang.String aMinutesToAdd)
Deprecated.
Do not use.
|
static java.lang.String |
formatSqlAddMinutesToExpression(EventHandlerContext context,
java.lang.String aDateExp,
java.lang.String aMinutesToAdd)
Deprecated.
Do not use.
|
static java.lang.String |
formatSqlAddOneMonth(EventHandlerContext context)
Deprecated.
Do not use.
|
static java.lang.String |
formatSqlConcat(EventHandlerContext context)
Deprecated.
Do not use. Use the sql.concat binding expression instead.
|
static java.lang.String |
formatSqlConvertIntToChar(EventHandlerContext context,
java.lang.String aValue)
Deprecated.
Do not use.
|
static java.lang.String |
formatSqlConvertToInt(EventHandlerContext context,
java.lang.String aValue)
Deprecated.
Do not use.
|
static java.lang.String |
formatSqlConvertToString(EventHandlerContext context,
java.lang.String aValue)
Deprecated.
Do not use.
|
static java.lang.String |
formatSqlDateTime(EventHandlerContext context,
java.lang.String aIsoDate,
java.lang.String aIsoTime)
Deprecated.
Do not use.
|
static java.lang.String |
formatSqlDaysBetween(EventHandlerContext context,
java.lang.String aFirstDate,
java.lang.String aSecondDate)
Deprecated.
Do not use. Use the sql.daysBetween binding expression instead.
|
static java.lang.String |
formatSqlDbCrLf(EventHandlerContext context)
Deprecated.
Do not use.
|
static java.lang.String |
formatSqlDbTab(EventHandlerContext context)
Deprecated.
Do not use.
|
static java.lang.String |
formatSqlDummyTable(EventHandlerContext context)
Deprecated.
Do not use.
|
static java.lang.String |
formatSqlFieldValue(EventHandlerContext context,
java.lang.Object aValue,
java.lang.String javaClass,
java.lang.String fieldName)
Deprecated.
Do not use. Use the DataSource API instead.
|
static java.lang.String |
formatSqlHoursBetween(EventHandlerContext context,
java.lang.String aFirstDate,
java.lang.String aFirstTime,
java.lang.String aSecondDate,
java.lang.String aSecondTime)
Deprecated.
Do not use. Use the sql.hoursBetween binding expression instead.
|
static java.lang.String |
formatSqlHoursBetweenFields(EventHandlerContext context,
java.lang.String fromDateField,
java.lang.String fromTimeField,
java.lang.String toDateField,
java.lang.String toTimeField)
Deprecated.
Do not use. Use the sql.hoursBetween binding expression instead.
|
static java.lang.String |
formatSqlIsNull(EventHandlerContext context,
java.lang.String aValue)
Deprecated.
Do not use. Use the sql.isNull binding expression instead.
|
static java.lang.String |
formatSqlIsoToNativeDate(EventHandlerContext context,
java.lang.String aIsoDate)
Deprecated.
Do not use.
|
static java.lang.String |
formatSqlIsoToNativeTime(EventHandlerContext context,
java.lang.String aIsoTime)
Deprecated.
Do not use.
|
static java.lang.String |
formatSqlMonthsBetween(EventHandlerContext context,
java.lang.String aFirstDate,
java.lang.String aSecondDate)
Deprecated.
Do not use.
|
static java.lang.String |
formatSqlReplace0WithDefault(EventHandlerContext context,
java.lang.String aValue,
java.lang.String defaultValue)
Deprecated.
Do not use. Use the sql.replaceZero binding expression instead.
|
static java.lang.String |
formatSqlReplace0WithHuge(EventHandlerContext context,
java.lang.String aValue)
Deprecated.
Do not use. Use the sql.replaceZero binding expression instead.
|
static java.lang.String |
formatSqlWeeksBetween(EventHandlerContext context,
java.lang.String aFirstDate,
java.lang.String aSecondDate)
Deprecated.
Do not use.
|
static java.util.List |
fromJSONArray(org.json.JSONArray array)
Deprecated.
Do not use.
|
static java.util.List |
fromJSONArray(java.lang.String data)
Deprecated.
Do not use.
|
static java.util.Map |
fromJSONObject(org.json.JSONObject object)
Deprecated.
Do not use.
|
static java.util.Map |
fromJSONObject(java.lang.String data)
Deprecated.
Do not use.
|
static org.dom4j.Document |
generateViewXml(EventHandlerContext context,
java.lang.String viewName,
org.dom4j.Element action)
Deprecated.
Do not use. This method is for 1.0 views.
|
static int |
getActivityLicensesAvailable()
Deprecated.
|
static int |
getActivityLicensesInUse()
Deprecated.
|
static boolean |
getActivityParameterBoolean(EventHandlerContext context,
java.lang.String activityId,
java.lang.String paramId)
Deprecated.
Use
ActivityParameterManager instead. |
static boolean |
getActivityParameterBoolean(EventHandlerContext context,
java.lang.String activityId,
java.lang.String paramId,
boolean defaultValue)
Deprecated.
Use
ActivityParameterManager instead. |
static java.lang.Double |
getActivityParameterDouble(EventHandlerContext context,
java.lang.String activityId,
java.lang.String paramId)
Deprecated.
Use
ActivityParameterManager instead. |
static java.lang.Double |
getActivityParameterDouble(EventHandlerContext context,
java.lang.String activityId,
java.lang.String paramId,
double defaultValue)
Deprecated.
Use
ActivityParameterManager instead. |
static java.lang.Integer |
getActivityParameterInt(EventHandlerContext context,
java.lang.String activityId,
java.lang.String paramId)
Deprecated.
Use
ActivityParameterManager instead. |
static java.lang.Integer |
getActivityParameterInt(EventHandlerContext context,
java.lang.String activityId,
java.lang.String paramId,
int defaultValue)
Deprecated.
Use
ActivityParameterManager instead. |
static java.lang.String |
getActivityParameterString(EventHandlerContext context,
java.lang.String activityId,
java.lang.String paramId)
Deprecated.
Use
ActivityParameterManager instead. |
static java.lang.String[] |
getAllFieldNames(EventHandlerContext context,
java.lang.String tableName)
Deprecated.
Find a table's field names
|
protected static EventHandlerContext |
getContextForChainedRule(EventHandlerContext containerRuleContext,
java.lang.String chainedRuleKey)
Deprecated.
Do not use.
|
protected static com.archibus.config.Database.Immutable |
getDatabase(EventHandlerContext context)
Deprecated.
Do not use. Applications do not need access to Database.Immutable.
|
static java.sql.Date |
getDateValue(EventHandlerContext context,
java.lang.Object value)
Deprecated.
Do not use. Use the DataSource API instead.
|
static java.sql.Date |
getDateValueFromNeutral(EventHandlerContext context,
java.lang.String value)
Deprecated.
Do not use. Use the DataSource API instead.
|
static com.archibus.db.DbConnection.ThreadSafe |
getDbConnection(EventHandlerContext context)
Deprecated.
Do not use. Applications do not need access to DbConnection.ThreadSafe.
|
protected static com.archibus.schema.DbServer.Immutable |
getDbServer(EventHandlerContext context)
Deprecated.
Do not use. Applications do not need access to DbServer.Immutable.
|
static java.lang.String |
getEmailAddress(EventHandlerContext context,
java.lang.String em_id)
Deprecated.
Returns email address from em table for specified em_id.
|
static java.lang.String |
getEmailAddress(EventHandlerContext context,
java.lang.String tableName,
java.lang.String fieldName,
java.lang.String fieldValue)
Deprecated.
Gets email address from specified table.
|
static java.lang.String |
getEmailFrom(EventHandlerContext context)
Deprecated.
|
static java.lang.String |
getEmailHost(EventHandlerContext context)
Deprecated.
|
static java.lang.String |
getEmailPassword(EventHandlerContext context)
Deprecated.
|
static java.lang.String |
getEmailPort(EventHandlerContext context)
Deprecated.
|
static java.lang.String |
getEmailUserId(EventHandlerContext context)
Deprecated.
|
static java.lang.String |
getEnumFieldDisplayedValue(EventHandlerContext context,
java.lang.String tableName,
java.lang.String fieldName,
java.lang.String storedValue)
Deprecated.
Find an Enum field's corresponding localized displayed value given one of its stored values \
(e.g.
|
static java.lang.String[] |
getEnumFieldStoredValues(EventHandlerContext context,
java.lang.String tableName,
java.lang.String fieldName)
Deprecated.
Find an Enum field's stored values
|
static java.lang.Integer |
getFieldAfmType(EventHandlerContext context,
java.lang.String tableName,
java.lang.String fieldName)
Deprecated.
Find a field's afm type (e.g.
|
static java.lang.String[] |
getFieldMultiLineHeadings(EventHandlerContext context,
java.lang.String tableName,
java.lang.String fieldName)
Deprecated.
Find a field's multiLine headings
|
static java.lang.String |
getFieldMultiLineHeadingsAsString(EventHandlerContext context,
java.lang.String tableName,
java.lang.String fieldName,
java.lang.String paddingCharacters)
Deprecated.
Find a field's multiLine headings and concatenated by provided characters into a single
string (e.g.
|
static java.lang.String |
getFieldSingleLineHeading(EventHandlerContext context,
java.lang.String tableName,
java.lang.String fieldName)
Deprecated.
Find a field's single line heading
|
static java.lang.Integer |
getFieldSqlType(EventHandlerContext context,
java.lang.String tableName,
java.lang.String fieldName)
Deprecated.
Find a field's sql type ((e.g.
|
static java.lang.String[] |
getForeignFieldNames(EventHandlerContext context,
java.lang.String tableName,
java.lang.String fieldName)
Deprecated.
|
static java.lang.Integer |
getIntegerValue(EventHandlerContext context,
java.lang.Object value)
Deprecated.
Do not use. Use the DataSource API instead.
|
static java.lang.String |
getJDBCString(EventHandlerContext context)
Deprecated.
Do not use.
|
static JobManager.ThreadSafe |
getJobManager(EventHandlerContext context)
Deprecated.
Do not use. Use
Context.getJobManager() instead. |
static int |
getLicensesAvailable(EventHandlerContext context,
java.lang.String activityId)
Deprecated.
Returns the number of available licenses for specified activity.
|
static int |
getLicensesInUse(EventHandlerContext context,
java.lang.String activityId)
Deprecated.
Returns the number of in-use licenses for specified activity.
|
protected static java.util.Locale |
getLocale(EventHandlerContext context)
Deprecated.
Do not use. Use
Context.getLocale() instead. |
protected static java.util.Map |
getParameters(EventHandlerContext context,
java.lang.String[] names,
java.lang.String[] expressions)
Deprecated.
Do not use. Instead, declare workflow rule inputs as Java method parameters.
|
static com.archibus.config.ContextCacheable.Immutable |
getParentContext(EventHandlerContext context)
Deprecated.
Do not use. Applications do not need access to ContextCacheable.Immutable.
|
protected static java.lang.String |
getParentContextAttribute(EventHandlerContext context,
java.lang.String attributeName)
Deprecated.
Do not use. Applications do not need access to parent context attributes.
|
protected static java.lang.String |
getParentContextAttributeXPath(EventHandlerContext context,
java.lang.String attributeXPath)
Deprecated.
Do not use. Applications do not need access to parent context attributes.
|
protected static com.archibus.config.Project.Immutable |
getProject(EventHandlerContext context)
Deprecated.
Do not use. Use
Context.getProject() instead:
ContextStore.get().getProject() |
static java.lang.String |
getReferenceTableName(EventHandlerContext context,
java.lang.String tableName,
java.lang.String fieldName)
Deprecated.
|
static java.lang.String[] |
getTableFkFieldNames(EventHandlerContext context,
java.lang.String tableName)
Deprecated.
|
static java.lang.String[] |
getTablePkFieldNames(EventHandlerContext context,
java.lang.String tableName)
Deprecated.
|
static java.sql.Time |
getTimeValue(EventHandlerContext context,
java.lang.Object value)
Deprecated.
Do not use. Use the DataSource API instead.
|
static java.sql.Time |
getTimeValueFromNeutral(EventHandlerContext context,
java.lang.String value)
Deprecated.
Do not use. Use the DataSource API instead.
|
static java.lang.String |
getTranslatableFieldName(EventHandlerContext context,
java.lang.String tableName,
java.lang.String fieldName,
java.util.Locale locale)
Deprecated.
|
protected static com.archibus.security.UserAccount.Immutable |
getUserAccount(EventHandlerContext context)
Deprecated.
Do not use. Use
Context.getUserAccount() instead:
ContextStore.get().getUserAccount() |
protected static com.archibus.security.UserRole.Immutable |
getUserRole(EventHandlerContext context)
Deprecated.
Do not use. Use
User.getRole() instead:
ContextStore.get().getUser().getRole() |
protected int |
getViewFormatVersion(EventHandlerContext context)
Deprecated.
Retrieves the view format version from the input parameter.
|
protected static java.lang.String |
getWebCentralPath(EventHandlerContext context)
Deprecated.
Use
Context.getWebAppPath() instead. |
protected static com.archibus.jobmanager.WorkflowRulesContainer.ThreadSafe |
getWorkflowRulesContainer(EventHandlerContext context)
Deprecated.
Do not use. Applications do not need access to WorkflowRulesContainer.ThreadSafe.
|
static boolean |
isActivityLicenseEnabled(EventHandlerContext context,
java.lang.String activityId)
Deprecated.
Returns whether specified activity license is enabled.
|
static boolean |
isOracle(EventHandlerContext context)
Deprecated.
Use
SqlUtils.isOracle() instead. |
static boolean |
isSqlServer(EventHandlerContext context)
Deprecated.
Use
SqlUtils.isSqlServer() instead. |
static boolean |
isSybase(EventHandlerContext context)
Deprecated.
Use
SqlUtils.isSybase() instead. |
static java.lang.String |
literal(EventHandlerContext context,
java.lang.String aValue)
Deprecated.
Do not use. Use
SqlUtils#makeLiteralOrBlank() instead. |
static com.archibus.view.ViewImpl |
loadView(EventHandlerContext context,
java.lang.String viewName)
Deprecated.
Do not use. This method is for 1.0 views.
|
protected static org.dom4j.Document |
loadViewXml(EventHandlerContext context,
java.lang.String viewName)
Deprecated.
Loads or retrieves from cache the view object specified by name.
|
static java.lang.String |
localizeMessage(EventHandlerContext context,
java.lang.String activityId,
java.lang.String referencedBy,
java.lang.String messageId,
java.lang.String localeName)
Deprecated.
Localizes specified message from the messages database table, using either the current user
locale or specified locale.
|
static java.lang.String |
localizeString(com.archibus.config.ContextCacheable.Immutable contextParent,
java.lang.String message,
java.lang.String className)
Deprecated.
Localizes text message.
|
static java.lang.String |
localizeString(EventHandlerContext context,
java.util.Locale targetLocale,
java.lang.String message,
java.lang.String key2,
java.lang.String sourceName)
Deprecated.
Localizes text message.
|
java.lang.String |
localizeString(EventHandlerContext context,
java.lang.String message)
Deprecated.
Localizes text message.
|
static java.lang.String |
localizeString(EventHandlerContext context,
java.lang.String message,
java.lang.String className)
Deprecated.
Localizes text message.
|
static java.lang.String |
localizeString(EventHandlerContext context,
java.lang.String localeCode,
java.lang.String message,
java.lang.String key2,
java.lang.String sourceName)
Deprecated.
Localizes text message.
|
static java.lang.String |
localizeString(java.lang.String message,
java.lang.String className)
Deprecated.
Localizes text message.
|
protected static java.lang.String |
notNull(java.lang.Object o)
Deprecated.
Do not use. Use
StringUtil#notNull() instead. |
static java.lang.Object |
parseFieldValue(EventHandlerContext context,
java.lang.String aValue,
java.lang.String javaClass,
java.lang.String fieldName)
Deprecated.
Do not use.
|
static java.lang.Object |
parseFieldValue(EventHandlerContext context,
java.lang.String aValue,
java.lang.String javaClass,
java.lang.String fieldName,
boolean localizedFormat)
Deprecated.
Do not use.
|
protected static java.util.List |
parseJSONArray(EventHandlerContext context,
org.json.JSONArray jsonArray)
Deprecated.
Parses field names and values from the JSON array of records.
|
protected static java.util.Map |
parseJSONObject(EventHandlerContext context,
org.json.JSONObject jsonObject)
Deprecated.
Parses field names and values from the JSON object.
|
protected static java.util.Map |
parseRecord(EventHandlerContext context,
org.dom4j.Element recordElement)
Deprecated.
Parses field names and values from specified XML record.
|
static java.lang.Object |
parseSqlFieldValue(EventHandlerContext context,
java.lang.String aValue,
java.lang.String javaClass,
java.lang.String fieldName,
boolean localizedFormat)
Deprecated.
Do not use.
|
protected static java.lang.Object |
parseValue(EventHandlerContext context,
java.lang.String fullName,
java.lang.String value)
Deprecated.
Parsed unformatted field value.
|
protected java.lang.String |
prepareMessage(EventHandlerContext context,
java.lang.String message,
java.lang.Object[] args)
Deprecated.
Localizes and formats text message.
|
static java.lang.String |
prepareMessage(EventHandlerContext context,
java.lang.String activityId,
java.lang.String referencedBy,
java.lang.String messageId,
java.lang.String localeName,
java.lang.Object[] args)
Deprecated.
Localizes and formats specified message from the messages database table, using either the
current user locale or specified locale.
|
static void |
queryDbRecords(EventHandlerContext eventHandlerContext,
java.lang.String sql,
java.util.List viewFields,
java.util.Map keyFields,
DataSource.RecordHandler recordHandler)
Deprecated.
Do not use. Use
DataSource#queryRecords() instead. |
static void |
queryDbRecords(EventHandlerContext eventHandlerContext,
java.lang.String sql,
java.lang.String mainTableName,
java.util.List viewFields,
java.util.Map keyFields,
DataSource.RecordHandler recordHandler)
Deprecated.
Do not use. Use
DataSource#queryRecords() instead. |
static java.util.List<com.archibus.datasource.data.DataRecord> |
retrieveDbDataRecords(EventHandlerContext context,
java.lang.String sql,
java.util.List viewFields,
java.util.Map keyFields,
int recordLimit,
javax.xml.rpc.holders.BooleanHolder hasMoreRecords,
org.dom4j.Element xmlRecords)
Deprecated.
Do not use. Use
DataSource instead. |
protected static java.util.List |
retrieveDbRecords(EventHandlerContext context,
java.lang.String sql)
Deprecated.
Do not use. Use
DataSource instead. |
static java.util.List |
retrieveDbRecords(EventHandlerContext context,
java.lang.String sql,
java.util.List viewFields,
java.util.Map keyFields,
int recordLimit,
javax.xml.rpc.holders.BooleanHolder hasMoreRecords,
org.dom4j.Element xmlRecords)
Deprecated.
Do not use. Use
DataSource instead. |
protected static java.lang.Double |
retrieveStatistic(EventHandlerContext context,
java.lang.String operation,
java.lang.String sql,
java.lang.String tableName,
java.lang.String fieldName)
Deprecated.
Use
DataStatistics instead. |
protected static void |
runWorkflowRule(EventHandlerContext context,
java.lang.String ruleId,
boolean asyncMode)
Deprecated.
Do not use. Invoke workflow rules either directly as Java classes, or as
long-running jobs using
JobManager . |
protected static com.archibus.db.RetrievedRecords.Immutable |
searchAndRetrieve(EventHandlerContext context,
java.lang.String mainTable,
java.lang.String[] mainFields,
java.lang.String[] standardTables,
java.lang.String[][] standardFields,
com.archibus.db.RestrictionBase.Immutable[] restrictions)
Deprecated.
Do not use. Use the DataSource API instead.
|
protected static java.util.List |
selectDbRecords(EventHandlerContext eventHandlerContext,
java.lang.String sql)
Deprecated.
Do not use. Use
DataSource instead. |
protected static java.util.List |
selectDbRecords(EventHandlerContext context,
java.lang.String tableName,
java.lang.String[] fieldNames,
java.lang.String whereExpression)
Deprecated.
Do not use. Use
DataSource instead. |
protected static java.util.List |
selectDbRecords(EventHandlerContext context,
java.lang.String tableName,
java.lang.String[] fieldNames,
java.lang.String[] standardTables,
java.lang.String[][] standardFields,
com.archibus.db.RestrictionBase.Immutable[] restrictions,
boolean formatValues,
int recordLimit)
Deprecated.
Do not use. Use
DataSource instead. |
protected static java.util.List |
selectDbRecords(EventHandlerContext context,
java.lang.String tableName,
java.lang.String[] fieldNames,
java.lang.String[] standardTables,
java.lang.String[][] standardFields,
java.lang.String whereExpression,
boolean formatValues,
int recordLimit)
Deprecated.
Do not use. Use
DataSource instead. |
protected static java.util.List |
selectDbRecords(EventHandlerContext context,
java.lang.String tableName,
java.lang.String[] fieldNames,
java.lang.String[] standardTables,
java.lang.String[][] standardFields,
java.lang.String whereExpression,
java.util.Map fieldValues,
boolean formatValues,
int recordLimit)
Deprecated.
Do not use. Use
DataSource instead. |
protected static java.lang.Object |
selectDbValue(EventHandlerContext context,
java.lang.String tableName,
java.lang.String fieldName,
java.lang.String whereExpression)
Deprecated.
Do not use. Use
DataSource instead. |
protected static java.lang.Object[] |
selectDbValues(EventHandlerContext context,
java.lang.String tableName,
java.lang.String[] fieldNames,
java.lang.String whereExpression)
Deprecated.
Do not use. Use
DataSource instead. |
static void |
sendEmail(java.lang.String text,
java.lang.String from,
java.lang.String host,
java.lang.String subject,
java.lang.String to)
Deprecated.
Use
MailSender instead. |
static void |
sendEmail(java.lang.String text,
java.lang.String from,
java.lang.String host,
java.lang.String subject,
java.lang.String to,
java.util.ArrayList cc,
java.util.ArrayList bcc,
java.lang.String userId,
java.lang.String password)
Deprecated.
Use
MailSender instead. |
static void |
sendEmail(java.lang.String text,
java.lang.String from,
java.lang.String host,
java.lang.String subject,
java.lang.String to,
java.util.ArrayList cc,
java.util.ArrayList bcc,
java.lang.String userId,
java.lang.String password,
java.util.ArrayList attachmentFileNames)
Deprecated.
Use
MailSender instead. |
static void |
sendEmail(java.lang.String text,
java.lang.String from,
java.lang.String host,
java.lang.String subject,
java.lang.String to,
java.util.ArrayList cc,
java.lang.String userId,
java.lang.String password)
Deprecated.
Use
MailSender instead. |
static void |
sendEmail(java.lang.String text,
java.lang.String from,
java.lang.String host,
java.lang.String port,
java.lang.String subject,
java.lang.String to,
java.util.ArrayList cc,
java.util.ArrayList bcc,
java.lang.String userId,
java.lang.String password,
java.util.ArrayList attachmentFileNames)
Deprecated.
Use
MailSender instead. |
static void |
sendEmail(java.lang.String text,
java.lang.String from,
java.lang.String host,
java.lang.String port,
java.lang.String subject,
java.lang.String to,
java.util.ArrayList cc,
java.util.ArrayList bcc,
java.lang.String userId,
java.lang.String password,
java.util.ArrayList attachmentFileNames,
java.lang.String contentType)
Deprecated.
Use
MailSender instead. |
static void |
sendEmail(java.lang.String text,
java.lang.String from,
java.lang.String host,
java.lang.String port,
java.lang.String subject,
java.lang.String to,
java.util.ArrayList cc,
java.util.ArrayList bcc,
java.lang.String userId,
java.lang.String password,
java.util.ArrayList attachmentFileNames,
java.lang.String contentType,
java.lang.String activityId)
Deprecated.
Use
MailSender instead. |
static void |
sendEmail(java.lang.String text,
java.lang.String from,
java.lang.String host,
java.lang.String subject,
java.lang.String to,
java.lang.String userId,
java.lang.String password)
Deprecated.
Use
MailSender instead. |
static java.util.Map |
stripPrefix(java.util.Map values)
Deprecated.
Do not use.
|
static org.json.JSONArray |
toJSONArray(java.util.List records)
Deprecated.
Do not use.
|
static org.json.JSONObject |
toJSONObject(java.util.Map record)
Deprecated.
Do not use.
|
protected static void |
writeStringToResponse(EventHandlerContext context,
java.lang.String str,
java.lang.String contentType)
Deprecated.
Write string to HttpServletResponse
|
public static final java.lang.String CONTENT_TYPE_TEXT_UFT8
public static final java.lang.String PREFERENCES_MAIL_HOST_PASSWORD
public static final java.lang.String PREFERENCES_MAIL_HOST_USER_ID
public static final java.lang.String PREFERENCES_MAIL_HOST
public static final java.lang.String PREFERENCES_MAIL_HOST_PORT
public static final java.lang.String RESPONSE
protected final org.apache.log4j.Logger log
public static final java.lang.String INPUT_TRANSLATABLE
public static final java.lang.String OUTPUT_TRANSLATABLE
protected EventHandlerBase()
@Deprecated public static com.archibus.config.ContextCacheable.Immutable getParentContext(EventHandlerContext context)
context
- Workflow rule execution context.@Deprecated protected static com.archibus.security.UserAccount.Immutable getUserAccount(EventHandlerContext context)
Context.getUserAccount()
instead:
ContextStore.get().getUserAccount()
context
- Workflow rule execution context.@Deprecated protected static com.archibus.security.UserRole.Immutable getUserRole(EventHandlerContext context)
User.getRole()
instead:
ContextStore.get().getUser().getRole()
context
- Workflow rule execution context.@Deprecated protected static com.archibus.jobmanager.WorkflowRulesContainer.ThreadSafe getWorkflowRulesContainer(EventHandlerContext context)
context
- Workflow rule execution context.@Deprecated protected static com.archibus.config.Project.Immutable getProject(EventHandlerContext context)
Context.getProject()
instead:
ContextStore.get().getProject()
context
- Workflow rule execution context.@Deprecated protected static com.archibus.schema.DbServer.Immutable getDbServer(EventHandlerContext context)
context
- Workflow rule execution context.@Deprecated public static com.archibus.db.DbConnection.ThreadSafe getDbConnection(EventHandlerContext context)
context
- Workflow rule execution context.@Deprecated protected static com.archibus.config.Database.Immutable getDatabase(EventHandlerContext context)
context
- Workflow rule execution context.@Deprecated protected static java.util.Locale getLocale(EventHandlerContext context)
Context.getLocale()
instead.context
- Workflow rule execution context.@Deprecated protected static java.lang.String getParentContextAttribute(EventHandlerContext context, java.lang.String attributeName)
context
- Workflow rule execution context.attributeName
- Attribute name (not an XPath expression).@Deprecated protected static java.lang.String getParentContextAttributeXPath(EventHandlerContext context, java.lang.String attributeXPath)
context
- Workflow rule execution context.attributeXPath
- Xpath of the attribute.@Deprecated public static JobManager.ThreadSafe getJobManager(EventHandlerContext context)
Context.getJobManager()
instead.context
- @Deprecated protected static java.util.Map getParameters(EventHandlerContext context, java.lang.String[] names, java.lang.String[] expressions)
context
- Workflow rule execution context.names
- Array of parameter names.expressions
- XPath expressions to select parameter values. If null, names are used
instead.@Deprecated public static java.util.Map stripPrefix(java.util.Map values)
values
- Map@Deprecated public static java.util.Map filterWithPrefix(java.util.Map values, java.lang.String prefix)
values
- Mapprefix
- Usually a table name.@Deprecated public static java.lang.String literal(EventHandlerContext context, java.lang.String aValue)
SqlUtils#makeLiteralOrBlank()
instead.context
- Workflow rule execution context.aValue
- String value, e.q. PLANNED.@Deprecated public static java.lang.String expandParameters(EventHandlerContext context, java.lang.String stringWithParameters)
context
- Workflow rule execution context.stringWithParameters
- Input string with macros.@Deprecated public static java.lang.String expandParameters(com.archibus.schema.DbServer.Immutable dbServer, com.archibus.config.ContextCacheable.Immutable context, java.util.Map parameters, java.lang.String stringWithParameters)
dbServer
- context
- parameters
- stringWithParameters
- @Deprecated protected static EventHandlerContext getContextForChainedRule(EventHandlerContext containerRuleContext, java.lang.String chainedRuleKey)
containerRuleContext
- Context of the container rule.chainedRuleKey
- Key of the chained rule in the container context.@Deprecated protected static java.lang.String notNull(java.lang.Object o)
StringUtil#notNull()
instead.o
- Any object reference.@Deprecated protected static java.lang.Double retrieveStatistic(EventHandlerContext context, java.lang.String operation, java.lang.String sql, java.lang.String tableName, java.lang.String fieldName)
DataStatistics
instead.context
- Workflow rule execution context.operation
- Aggregating operation namesql
- Custom SQL query to execute.tableName
- Name of the database table.fieldName
- Name of the database field.@Deprecated public static void executeDbSave(EventHandlerContext context, java.lang.String tableName, java.util.Map values)
DataSource#saveRecord()
instead.context
- Workflow rule execution context.tableName
- Name of the database table to update.values
- Map@Deprecated public static void executeDbSave(EventHandlerContext context, java.lang.String tableName, java.util.Map values, java.util.Map oldFieldValues, boolean newRecord)
DataSource#saveRecord()
instead.context
- tableName
- values
- oldFieldValues
- newRecord
- @Deprecated protected static void executeDbAdd(EventHandlerContext context, java.lang.String tableName, java.util.Map values)
DataSource#saveRecord()
instead.context
- Workflow rule execution context.tableName
- Name of the database table to update.values
- Map@Deprecated public static void executeDbDelete(EventHandlerContext context, java.lang.String tableName, java.util.Map aValues)
DataSource#deleteRecord()
instead.context
- Workflow rule execution context.tableName
- Name of the database table to update.aValues
- Map@Deprecated public static void executeDbSql(EventHandlerContext context, java.lang.String sql, boolean updatedRecordsRequired)
SqlUtils#executeUpdate()
instead.context
- Workflow rule execution context.sql
- SQL query to execute.updatedRecordsRequired
- If true, and no records were updated, an exception is thrown.@Deprecated public static void executeDbSql(EventHandlerContext context, java.lang.String tableName, java.lang.String sql, boolean updatedRecordsRequired)
SqlUtils#executeUpdate()
instead.context
- Workflow rule execution context.sql
- SQL query to execute.updatedRecordsRequired
- If true, and no records were updated, an exception is thrown.@Deprecated public static void executeDbSqlNoParameters(EventHandlerContext context, java.lang.String sql, boolean updatedRecordsRequired)
SqlUtils#executeUpdate()
instead.context
- Workflow rule execution context.sql
- SQL query to execute.updatedRecordsRequired
- If true, and no records were updated, an exception is thrown.@Deprecated protected static void executeDbSqlCommands(EventHandlerContext context, java.util.Vector sqlCommands, boolean updatedRecordsRequired)
SqlUtils#executeUpdate()
instead.context
- Workflow rule execution context.sqlCommands
- List of SQL queriesupdatedRecordsRequired
- If true, and no records were updated, an exception is thrown.@Deprecated public static void executeDbCommit(EventHandlerContext context)
SqlUtils.commit()
instead.context
- Workflow rule execution context.@Deprecated public static void executeDbRollback(EventHandlerContext context)
SqlUtils.rollback()
instead.context
- Workflow rule execution context.@Deprecated protected static java.lang.Object selectDbValue(EventHandlerContext context, java.lang.String tableName, java.lang.String fieldName, java.lang.String whereExpression)
DataSource
instead.context
- Workflow rule execution context.tableName
- Table name.fieldName
- Field name to return.whereExpression
- Expression to use inside WHERE clause to select one record.@Deprecated protected static java.lang.Object[] selectDbValues(EventHandlerContext context, java.lang.String tableName, java.lang.String[] fieldNames, java.lang.String whereExpression) throws com.archibus.utility.ExceptionBase
DataSource
instead.context
- Workflow rule execution context.tableName
- Table name.fieldNames
- Field names to return.whereExpression
- Expression to use inside WHERE clause to select one record.com.archibus.utility.ExceptionBase
- Exception might be thrown by the implementation.@Deprecated protected static java.util.List selectDbRecords(EventHandlerContext context, java.lang.String tableName, java.lang.String[] fieldNames, java.lang.String whereExpression) throws com.archibus.utility.ExceptionBase
DataSource
instead.context
- Workflow rule execution context.tableName
- Table name.fieldNames
- Field names to return.whereExpression
- Expression to use inside WHERE clause to select many records.com.archibus.utility.ExceptionBase
- Exception might be thrown by the implementation.@Deprecated protected static java.util.List selectDbRecords(EventHandlerContext context, java.lang.String tableName, java.lang.String[] fieldNames, java.lang.String[] standardTables, java.lang.String[][] standardFields, java.lang.String whereExpression, boolean formatValues, int recordLimit)
DataSource
instead.context
- Workflow rule execution context.tableName
- Table name.fieldNames
- Field names to return.whereExpression
- Expression to use inside WHERE clause to select many record.standardTables
- Table names of standard tables.standardFields
- Field names of standard tables.formatValues
- Whether record values should be formatted to strings.recordLimit
- Maximum number of records to retrieve.@Deprecated protected static java.util.List selectDbRecords(EventHandlerContext context, java.lang.String tableName, java.lang.String[] fieldNames, java.lang.String[] standardTables, java.lang.String[][] standardFields, java.lang.String whereExpression, java.util.Map fieldValues, boolean formatValues, int recordLimit)
DataSource
instead.context
- Workflow rule execution context.tableName
- Table name.fieldNames
- Field names to return.whereExpression
- Expression to use inside WHERE clause to select many record.fieldValues
- Map for parsed restriction where table.field = valuestandardTables
- Table names of standard tables.standardFields
- Field names of standard tables.formatValues
- Whether record values should be formatted to strings.recordLimit
- Maximum number of records to retrieve.@Deprecated protected static java.util.List selectDbRecords(EventHandlerContext context, java.lang.String tableName, java.lang.String[] fieldNames, java.lang.String[] standardTables, java.lang.String[][] standardFields, com.archibus.db.RestrictionBase.Immutable[] restrictions, boolean formatValues, int recordLimit) throws com.archibus.utility.ExceptionBase
DataSource
instead.context
- Workflow rule execution context.tableName
- Table name.fieldNames
- Field names to return.standardTables
- Table names of standard tables.standardFields
- Field names of standard tables.restrictions
- Restrictions to be applied when selecting records.formatValues
- Whether record values should be formatted to strings.recordLimit
- Maximum number of records to retrieve.com.archibus.utility.ExceptionBase
- Exception might be thrown by the implementation.@Deprecated protected static java.util.List selectDbRecords(EventHandlerContext eventHandlerContext, java.lang.String sql)
DataSource
instead.context
- Workflow rule execution context.sql
- SQL query to SELECT zero or more records.@Deprecated protected static java.util.List retrieveDbRecords(EventHandlerContext context, java.lang.String sql)
DataSource
instead.context
- Workflow rule execution context.sql
- SQL query to SELECT zero or more records.@Deprecated public static java.util.List retrieveDbRecords(EventHandlerContext context, java.lang.String sql, java.util.List viewFields, java.util.Map keyFields, int recordLimit, javax.xml.rpc.holders.BooleanHolder hasMoreRecords, org.dom4j.Element xmlRecords)
DataSource
instead.context
- Workflow rule execution context.sql
- SQL query to SELECT zero or more records.viewFields
- MapkeyFields
- MaprecordLimit
- How many records can be retrieved.hasMoreRecords
- Set to true if the recordLimit has been reached, but there are more
records to read.@Deprecated public static java.util.List<com.archibus.datasource.data.DataRecord> retrieveDbDataRecords(EventHandlerContext context, java.lang.String sql, java.util.List viewFields, java.util.Map keyFields, int recordLimit, javax.xml.rpc.holders.BooleanHolder hasMoreRecords, org.dom4j.Element xmlRecords)
DataSource
instead.context
- sql
- viewFields
- keyFields
- recordLimit
- hasMoreRecords
- xmlRecords
- @Deprecated public static void queryDbRecords(EventHandlerContext eventHandlerContext, java.lang.String sql, java.util.List viewFields, java.util.Map keyFields, DataSource.RecordHandler recordHandler)
DataSource#queryRecords()
instead.context
- sql
- viewFields
- keyFields
- recordHandler
- @Deprecated public static void queryDbRecords(EventHandlerContext eventHandlerContext, java.lang.String sql, java.lang.String mainTableName, java.util.List viewFields, java.util.Map keyFields, DataSource.RecordHandler recordHandler)
DataSource#queryRecords()
instead.eventHandlerContext
- sql
- mainTableName
- viewFields
- keyFields
- recordHandler
- @Deprecated public static org.json.JSONObject toJSONObject(java.util.Map record)
record
- The map of values.@Deprecated public static org.json.JSONArray toJSONArray(java.util.List records)
records
- The list of records.@Deprecated public static java.util.Map fromJSONObject(org.json.JSONObject object)
object
- The JSON object.@Deprecated public static java.util.Map fromJSONObject(java.lang.String data) throws java.text.ParseException
data
- - The JSON string.java.text.ParseException
@Deprecated public static java.util.List fromJSONArray(org.json.JSONArray array)
array
- JSON array containing JSON objects@Deprecated public static java.util.List fromJSONArray(java.lang.String data) throws java.text.ParseException
data
- a string to hold JSON array containing JSON objectsjava.text.ParseException
@Deprecated public static java.util.List<com.archibus.datasource.data.DataRecord> createRecordsFromJSON(org.json.JSONArray array)
array
- JSON array containing JSON objects, one per data record@Deprecated public static com.archibus.datasource.data.DataRecord createRecordFromJSON(org.json.JSONObject object)
object
- JSON object containing record values and old values@Deprecated public static java.lang.Integer getIntegerValue(EventHandlerContext context, java.lang.Object value)
context
- Workflow rule execution context.value
- Database value, can be Integer or BigDecimal.@Deprecated public static java.sql.Date getDateValue(EventHandlerContext context, java.lang.Object value)
context
- Workflow rule execution context.value
- Database value, can be Date or Timestamp.@Deprecated public static java.sql.Time getTimeValue(EventHandlerContext context, java.lang.Object value)
context
- Workflow rule execution context.value
- Database value, can be Time or Timestamp.@Deprecated public static java.sql.Date getDateValueFromNeutral(EventHandlerContext context, java.lang.String value)
@Deprecated public static java.sql.Time getTimeValueFromNeutral(EventHandlerContext context, java.lang.String value)
@Deprecated protected static com.archibus.db.RetrievedRecords.Immutable searchAndRetrieve(EventHandlerContext context, java.lang.String mainTable, java.lang.String[] mainFields, java.lang.String[] standardTables, java.lang.String[][] standardFields, com.archibus.db.RestrictionBase.Immutable[] restrictions)
context
- Workflow rule execution context.mainTable
- Name of the main table of the join.mainFields
- Names of the fields from the main table.standardTables
- Names of the standard table of the join.standardFields
- Names of the fields from the standard table.restrictions
- Restrictions to be applied when selecting records.@Deprecated public static boolean isSybase(EventHandlerContext context)
SqlUtils.isSybase()
instead.context
- Workflow rule execution context.@Deprecated public static boolean isOracle(EventHandlerContext context)
SqlUtils.isOracle()
instead.context
- Workflow rule execution context.@Deprecated public static java.lang.String getJDBCString(EventHandlerContext context)
@Deprecated public static boolean isSqlServer(EventHandlerContext context)
SqlUtils.isSqlServer()
instead.context
- Workflow rule execution context.@Deprecated public static java.lang.String formatSqlFieldValue(EventHandlerContext context, java.lang.Object aValue, java.lang.String javaClass, java.lang.String fieldName)
context
- Workflow rule execution context.aValue
- Value to be formattedjavaClass
- Java class name, the value will be converted from the type of.fieldName
- Field name - will be used in exception.@Deprecated public static java.lang.String formatSqlIsNull(EventHandlerContext context, java.lang.String aValue)
context
- Workflow rule execution context.aValue
- Arguments of IsNull function, e.g. "price, 0.00"@Deprecated public static java.lang.String formatSqlConvertToInt(EventHandlerContext context, java.lang.String aValue)
context
- Workflow rule execution context.aValue
- Arguments of Convert function, e.g. "2.34"@Deprecated public static java.lang.String formatSqlConvertIntToChar(EventHandlerContext context, java.lang.String aValue)
context
- Workflow rule execution context.aValue
- Arguments of Convert function, e.g. "231"@Deprecated public static java.lang.String formatSqlConvertToString(EventHandlerContext context, java.lang.String aValue)
context
- Workflow rule execution context.aValue
- Arguments of Convert function, e.g. "07/22/2006"@Deprecated public static java.lang.String formatSqlDateTime(EventHandlerContext context, java.lang.String aIsoDate, java.lang.String aIsoTime)
context
- Workflow rule execution contextaIsoDate
- Date in ISO formataIsoTime
- Time in ISO format@Deprecated public static java.lang.String formatSqlConcat(EventHandlerContext context)
context
- Workflow rule execution context.@Deprecated public static java.lang.String formatSqlReplace0WithHuge(EventHandlerContext context, java.lang.String aValue)
context
- Workflow rule execution context.aValue
- Arguments of Replace function, e.g. "0"@Deprecated public static java.lang.String formatSqlReplace0WithDefault(EventHandlerContext context, java.lang.String aValue, java.lang.String defaultValue)
context
- Workflow rule execution context.aValue
- Arguments of Replace function, e.g. "0"@Deprecated public static java.lang.String formatSqlDummyTable(EventHandlerContext context)
context
- Workflow rule execution context.@Deprecated public static java.lang.String formatSqlDbCrLf(EventHandlerContext context)
context
- Workflow rule execution context.@Deprecated public static java.lang.String formatSqlDbTab(EventHandlerContext context)
context
- Workflow rule execution context.@Deprecated public static java.lang.String formatSqlAddMinutes(EventHandlerContext context, java.lang.String aIsoTime, java.lang.String aMinutesToAdd)
context
- Workflow rule execution context.aIsoTime
- Time string in ISO formataMinutesToAdd
- Number of minutes to add to aDate@Deprecated public static java.lang.String formatSqlAddMinutesToExpression(EventHandlerContext context, java.lang.String aDateExp, java.lang.String aMinutesToAdd)
context
- Workflow rule execution context.aDateExp
- Date expression, e.g. a database date column nameaMinutesToAdd
- Number of minutes to add to aDate@Deprecated public static java.lang.String formatSqlAddDays(EventHandlerContext context, java.lang.String aIsoDate, java.lang.String aDaysToAdd)
context
- Workflow rule execution context.aDaysToAdd
- Number of days to add to aDateaIsoDate
- Description of the Parameter@Deprecated public static java.lang.String formatSqlAddDaysToExpression(EventHandlerContext context, java.lang.String aDateExp, java.lang.String aDaysToAdd)
context
- Workflow rule execution context.aDateExp
- Date expression, e.g. a database date column nameaDaysToAdd
- Number of daysto add to aDate@Deprecated public static java.lang.String formatSqlDaysBetween(EventHandlerContext context, java.lang.String aFirstDate, java.lang.String aSecondDate)
context
- Workflow rule execution context.aFirstDate
- Date in ISO formataSecondDate
- Date in ISO format@Deprecated public static java.lang.String formatSqlHoursBetween(EventHandlerContext context, java.lang.String aFirstDate, java.lang.String aFirstTime, java.lang.String aSecondDate, java.lang.String aSecondTime)
context
- Workflow rule execution context.aFirstDate
- Date in ISO formataFirstTime
- Time in ISO formataSecondDate
- Date in ISO formataSecondTime
- Time in ISO format@Deprecated public static java.lang.String formatSqlHoursBetweenFields(EventHandlerContext context, java.lang.String fromDateField, java.lang.String fromTimeField, java.lang.String toDateField, java.lang.String toTimeField)
context:
- Event handler context.fromDateField:
- from date field name.fromTimeField:
- from time field name.toDateField:
- to date field name.toTimeField:
- to time field name.@Deprecated public static java.lang.String formatSqlMonthsBetween(EventHandlerContext context, java.lang.String aFirstDate, java.lang.String aSecondDate)
context
- Workflow rule execution context.aFirstDate
- Date in ISO formataSecondDate
- Date in ISO format@Deprecated public static java.lang.String formatSqlWeeksBetween(EventHandlerContext context, java.lang.String aFirstDate, java.lang.String aSecondDate)
context
- Workflow rule execution context.aFirstDate
- Date in ISO formataSecondDate
- Date in ISO format@Deprecated public static java.lang.String formatSqlAddOneMonth(EventHandlerContext context)
context
- Workflow rule execution context.@Deprecated public static java.lang.String formatSqlIsoToNativeDate(EventHandlerContext context, java.lang.String aIsoDate)
context
- Workflow rule execution context.aIsoDate
- Date in ISO format, or "CURRENT DATE".@Deprecated public static java.lang.String formatSqlIsoToNativeTime(EventHandlerContext context, java.lang.String aIsoTime)
context
- Workflow rule execution context.aIsoTime
- Description of the Parameter@Deprecated public static java.lang.String formatFieldValue(EventHandlerContext context, java.lang.Object aValue, java.lang.String javaClass, java.lang.String fieldName, boolean localizedFormat)
context
- Workflow rule execution context.aValue
- Value to be formattedjavaClass
- Java class name, the value will be converted to the type of.fieldName
- Field name - will be used in exception.localizedFormat
- If true, localized Format will be used (for reports), otherwise
non-localized Format will be used (neutral format, for edit forms)@Deprecated public static java.lang.Object parseFieldValue(EventHandlerContext context, java.lang.String aValue, java.lang.String javaClass, java.lang.String fieldName)
context
- Workflow rule execution context.javaClass
- Java class name, the value will be converted to the type of.aValue
- Value to be parsed.fieldName
- Field name - will be used in exception.@Deprecated public static java.lang.Object parseSqlFieldValue(EventHandlerContext context, java.lang.String aValue, java.lang.String javaClass, java.lang.String fieldName, boolean localizedFormat)
context
- Workflow rule execution context.javaClass
- Java class name.aValue
- Value to be parsed.fieldName
- Field name - will be used in exception.localizedFormat
- Description of the Parameter@Deprecated public static java.lang.Object parseFieldValue(EventHandlerContext context, java.lang.String aValue, java.lang.String javaClass, java.lang.String fieldName, boolean localizedFormat)
context
- Description of the ParameteraValue
- Description of the ParameterjavaClass
- Description of the ParameterfieldName
- Field name - will be used in exception.localizedFormat
- Description of the Parameterprotected static java.util.Map parseRecord(EventHandlerContext context, org.dom4j.Element recordElement)
context
- Workflow rule execution context.recordElement
- XML record to be parsed.protected static java.util.Map parseJSONObject(EventHandlerContext context, org.json.JSONObject jsonObject)
context
- jsonObject
- protected static java.util.List parseJSONArray(EventHandlerContext context, org.json.JSONArray jsonArray)
context
- jsonArray
- protected static java.lang.Object parseValue(EventHandlerContext context, java.lang.String fullName, java.lang.String value)
context
- fullName
- value
- protected static com.archibus.db.ViewField.Immutable createVirtualField(EventHandlerContext context, java.lang.String javaClass, java.lang.String fieldName, boolean localizedFormat)
context
- Workflow rule execution context.javaClass
- Java class name, the value will be converted to the type of.fieldName
- Field name.localizedFormat
- If true, localized Format will be used (for reports), otherwise
non-localized Format will be used (neutral format, for edit forms)protected static org.dom4j.Document loadViewXml(EventHandlerContext context, java.lang.String viewName)
context
- Workflow rule execution context.viewName
- View name, e.q. "rooms-simplest.axvw".@Deprecated public static com.archibus.view.ViewImpl loadView(EventHandlerContext context, java.lang.String viewName)
context
- Workflow rule execution context.viewName
- View name, e.q. "rooms-simplest.axvw".@Deprecated public static org.dom4j.Document generateViewXml(EventHandlerContext context, java.lang.String viewName, org.dom4j.Element action)
context
- Workflow rule execution context.viewName
- View name, e.q. "rooms-simplest.axvw".action
- Action to be handled.@Deprecated public static java.io.InputStream applyViewXsl(EventHandlerContext context, java.lang.String viewName, org.dom4j.Document xml, java.lang.String xslPath, boolean isPdf)
context
- Workflow rule execution context.xml
- XML to be processed.xslPath
- XSL file path.isPdf
- Is PDF: if true, a PDF FOP driver will be used to generate PDF document.viewName
- View name, e.q. "rooms-simplest.axvw".@Deprecated public static java.lang.String determineXsltFilePath(EventHandlerContext context, java.lang.String viewName)
context
- Workflow rule execution context.viewName
- View name.public static java.lang.String localizeString(EventHandlerContext context, java.lang.String message, java.lang.String className)
context
- Workflow rule execution context.message
- Text message.className
- Caller's class name.public java.lang.String localizeString(EventHandlerContext context, java.lang.String message)
context
- Workflow rule execution context.message
- Text message.public static java.lang.String localizeString(java.lang.String message, java.lang.String className)
message
- Text message to localize.className
- Caller's class name.public static java.lang.String localizeString(com.archibus.config.ContextCacheable.Immutable contextParent, java.lang.String message, java.lang.String className)
context
- Workflow rule execution context.message
- Text message.className
- Caller's class name.public static java.lang.String localizeString(EventHandlerContext context, java.lang.String localeCode, java.lang.String message, java.lang.String key2, java.lang.String sourceName)
context
- Workflow rule execution context.localeCode
- five letter code for target language and country.message
- Text message.key2
- message type.sourceName
- the descriptor name or file name of the message source, a key into the
localization map.public static java.lang.String localizeString(EventHandlerContext context, java.util.Locale targetLocale, java.lang.String message, java.lang.String key2, java.lang.String sourceName)
context
- Workflow rule execution context.locale
- Locale object for target language and country.message
- Text message.key2
- message type.sourceName
- the descriptor name or file name of the message source, a key into the
localization map.public static java.lang.String formatMessage(EventHandlerContext context, java.lang.String message, java.lang.Object[] args)
context
- Workflow rule execution context.message
- Text message to be formatted.args
- Array of objects to be injected into formatted message.protected java.lang.String prepareMessage(EventHandlerContext context, java.lang.String message, java.lang.Object[] args)
context
- Workflow rule execution context.message
- Text message to localize and format.args
- Array of objects to be injected into formatted message.public static java.lang.String localizeMessage(EventHandlerContext context, java.lang.String activityId, java.lang.String referencedBy, java.lang.String messageId, java.lang.String localeName)
context
- Workflow rule execution content.activityId
- messages.activity_idreferencedBy
- messages.reference_bymessageId
- messages.message_idlocaleName
- Name of the user locale (i.e. "en_US"). If null or empty string, the
current user locale is used.public static java.lang.String prepareMessage(EventHandlerContext context, java.lang.String activityId, java.lang.String referencedBy, java.lang.String messageId, java.lang.String localeName, java.lang.Object[] args)
context
- Workflow rule execution content.activityId
- messages.activity_idreferencedBy
- messages.reference_bymessageId
- messages.message_idlocaleName
- Name of the user locale (i.e. "en_US"). If null or empty string, the
current user locale is used.args
- Array of objects to be injected into formatted message.@Deprecated public static void sendEmail(java.lang.String text, java.lang.String from, java.lang.String host, java.lang.String subject, java.lang.String to)
MailSender
instead.text
- Message text to send.from
- "from" email address.host
- Mail server host address.subject
- Message subject.to
- "to" email address.@Deprecated public static void sendEmail(java.lang.String text, java.lang.String from, java.lang.String host, java.lang.String subject, java.lang.String to, java.lang.String userId, java.lang.String password)
MailSender
instead.text
- Message text to send.from
- "from" email address.host
- Mail server host address.subject
- Message subject.to
- "to" email address.userId
- User ID of the SMTP mail server.password
- Password of the SMTP mail server.@Deprecated public static void sendEmail(java.lang.String text, java.lang.String from, java.lang.String host, java.lang.String subject, java.lang.String to, java.util.ArrayList cc, java.lang.String userId, java.lang.String password)
MailSender
instead.text
- Message text to send.from
- "from" email address.host
- Mail server host address.subject
- Message subject.to
- "to" email address.userId
- User ID of the SMTP mail server.password
- Password of the SMTP mail server.cc
- List of "cc" email addresses.@Deprecated public static void sendEmail(java.lang.String text, java.lang.String from, java.lang.String host, java.lang.String subject, java.lang.String to, java.util.ArrayList cc, java.util.ArrayList bcc, java.lang.String userId, java.lang.String password)
MailSender
instead.text
- Message text to send.from
- "from" email address.host
- Mail server host address.subject
- Message subject.to
- "to" email address.userId
- User ID of the SMTP mail server.password
- Password of the SMTP mail server.cc
- List of "cc" email addresses.bcc
- List of "bcc" email addresses.@Deprecated public static void sendEmail(java.lang.String text, java.lang.String from, java.lang.String host, java.lang.String subject, java.lang.String to, java.util.ArrayList cc, java.util.ArrayList bcc, java.lang.String userId, java.lang.String password, java.util.ArrayList attachmentFileNames)
MailSender
instead.text
- Message text to send.from
- "from" email address.host
- Mail server host address.subject
- Message subject.to
- "to" email address.userId
- User ID of the SMTP mail server.password
- Password of the SMTP mail server.cc
- List of "cc" email addresses.bcc
- List of "bcc" email addresses.attachmentFileNames
- List of attachment file names.@Deprecated public static void sendEmail(java.lang.String text, java.lang.String from, java.lang.String host, java.lang.String port, java.lang.String subject, java.lang.String to, java.util.ArrayList cc, java.util.ArrayList bcc, java.lang.String userId, java.lang.String password, java.util.ArrayList attachmentFileNames)
MailSender
instead.text
- Message text to send.from
- "from" email address.host
- Mail server host address.host
- Mail server port.subject
- Message subject.to
- "to" email address.userId
- User ID of the SMTP mail server.password
- Password of the SMTP mail server.cc
- List of "cc" email addresses.bcc
- List of "bcc" email addresses.attachmentFileNames
- List of attachment file names.@Deprecated public static void sendEmail(java.lang.String text, java.lang.String from, java.lang.String host, java.lang.String port, java.lang.String subject, java.lang.String to, java.util.ArrayList cc, java.util.ArrayList bcc, java.lang.String userId, java.lang.String password, java.util.ArrayList attachmentFileNames, java.lang.String contentType)
MailSender
instead.text
- Message text to send.from
- "from" email address.host
- Mail server host address.host
- Mail server port.subject
- Message subject.to
- "to" email address.userId
- User ID of the SMTP mail server.password
- Password of the SMTP mail server.cc
- List of "cc" email addresses.bcc
- List of "bcc" email addresses.attachmentFileNames
- List of attachment file names.contentType
- Allows for changing content type to html.@Deprecated public static void sendEmail(java.lang.String text, java.lang.String from, java.lang.String host, java.lang.String port, java.lang.String subject, java.lang.String to, java.util.ArrayList cc, java.util.ArrayList bcc, java.lang.String userId, java.lang.String password, java.util.ArrayList attachmentFileNames, java.lang.String contentType, java.lang.String activityId)
MailSender
instead.text
- Message text to send.from
- "from" email address.host
- Mail server host address.host
- Mail server port.subject
- Message subject.to
- "to" email address.userId
- User ID of the SMTP mail server.password
- Password of the SMTP mail server.cc
- List of "cc" email addresses.bcc
- List of "bcc" email addresses.attachmentFileNames
- List of attachment file names.contentType
- Allows for changing content type to html.activityId
- The current activity ID.@Deprecated public static java.lang.String getEmailPort(EventHandlerContext context)
context
- Workflow rule execution context.@Deprecated public static java.lang.String getEmailHost(EventHandlerContext context)
context
- Workflow rule execution context.@Deprecated public static java.lang.String getEmailFrom(EventHandlerContext context)
context
- Workflow rule execution context.@Deprecated public static java.lang.String getEmailUserId(EventHandlerContext context)
context
- Workflow rule execution context.@Deprecated public static java.lang.String getEmailPassword(EventHandlerContext context)
context
- Workflow rule execution context.@Deprecated protected static java.lang.String getWebCentralPath(EventHandlerContext context)
Context.getWebAppPath()
instead.context
- Workflow rule execution context.public static java.lang.String getEmailAddress(EventHandlerContext context, java.lang.String tableName, java.lang.String fieldName, java.lang.String fieldValue)
context
- Workflow rule execution context.tableName
- Table containing email records, such as "em".fieldName
- Key field name, such as "em_id".fieldValue
- Key field value, such as "AI"public static java.lang.String getEmailAddress(EventHandlerContext context, java.lang.String em_id)
context
- Workflow rule execution context.em_id
- em_id value from em table.@Deprecated protected static void runWorkflowRule(EventHandlerContext context, java.lang.String ruleId, boolean asyncMode)
JobManager
.context
- Workflow rule execution context.ruleId
- Full rule ID, e.q. "AbCommonResources-notify".asyncMode
- If true, the rule will run asyncronously without blocking the caller.@Deprecated public static java.lang.Integer getActivityParameterInt(EventHandlerContext context, java.lang.String activityId, java.lang.String paramId)
ActivityParameterManager
instead.context
- Workflow rule execution context.activityId
- Activity code, e.g. "AbCommonResources".paramId
- Parameter code, e.g. "TimelineStartTime".@Deprecated public static java.lang.Integer getActivityParameterInt(EventHandlerContext context, java.lang.String activityId, java.lang.String paramId, int defaultValue)
ActivityParameterManager
instead.context
- Workflow rule execution context.activityId
- Activity code, e.g. "AbCommonResources".paramId
- Parameter code, e.g. "TimelineStartTime".defaultValue
- to be used when specified parameter is not defined in the database.@Deprecated public static java.lang.Double getActivityParameterDouble(EventHandlerContext context, java.lang.String activityId, java.lang.String paramId)
ActivityParameterManager
instead.context
- Workflow rule execution context.activityId
- Activity code, e.g. "AbCommonResources".paramId
- Parameter code, e.g. "TimelineStartTime".@Deprecated public static java.lang.Double getActivityParameterDouble(EventHandlerContext context, java.lang.String activityId, java.lang.String paramId, double defaultValue)
ActivityParameterManager
instead.context
- Workflow rule execution context.activityId
- Activity code, e.g. "AbCommonResources".paramId
- Parameter code, e.g. "TimelineStartTime".defaultValue
- to be used when specified parameter is not defined in the database.@Deprecated public static boolean getActivityParameterBoolean(EventHandlerContext context, java.lang.String activityId, java.lang.String paramId)
ActivityParameterManager
instead.context
- Workflow rule execution context.activityId
- Activity code, e.g. "AbCommonResources".paramId
- Parameter code, e.g. "TimelineStartTime".@Deprecated public static boolean getActivityParameterBoolean(EventHandlerContext context, java.lang.String activityId, java.lang.String paramId, boolean defaultValue)
ActivityParameterManager
instead.context
- Workflow rule execution context.activityId
- Activity code, e.g. "AbCommonResources".paramId
- Parameter code, e.g. "TimelineStartTime".defaultValue
- to be used when specified parameter is not defined in the database.@Deprecated public static java.lang.String getActivityParameterString(EventHandlerContext context, java.lang.String activityId, java.lang.String paramId)
ActivityParameterManager
instead.context
- Workflow rule execution context.activityId
- Activity code, e.g. "AbCommonResources".paramId
- Parameter code, e.g. "TimelineStartTime".protected static void writeStringToResponse(EventHandlerContext context, java.lang.String str, java.lang.String contentType) throws com.archibus.utility.ExceptionBase
context
- Workflow rule execution context.contentType
- Content Type of the response.str
- String will be written into the response.com.archibus.utility.ExceptionBase
- If there is IOException in the writer.public static boolean isActivityLicenseEnabled(EventHandlerContext context, java.lang.String activityId)
context
- activityId
- public static int getLicensesAvailable(EventHandlerContext context, java.lang.String activityId)
context
- activityId
- public static int getLicensesInUse(EventHandlerContext context, java.lang.String activityId)
context
- activityId
- @Deprecated public static int getActivityLicensesAvailable()
@Deprecated public static int getActivityLicensesInUse()
public static java.lang.String[] getAllFieldNames(EventHandlerContext context, java.lang.String tableName)
context
- Workflow rule execution context.tableName
- Table namepublic static java.lang.Integer getFieldAfmType(EventHandlerContext context, java.lang.String tableName, java.lang.String fieldName)
context
- Workflow rule execution context.tableName
- Table namefieldName
- Field namepublic static java.lang.Integer getFieldSqlType(EventHandlerContext context, java.lang.String tableName, java.lang.String fieldName)
context
- Workflow rule execution context.tableName
- Table namefieldName
- Field name@Deprecated public static java.lang.String[] getTablePkFieldNames(EventHandlerContext context, java.lang.String tableName)
context
- Workflow rule execution context.tableName
- Table name@Deprecated public static java.lang.String[] getTableFkFieldNames(EventHandlerContext context, java.lang.String tableName)
context
- Workflow rule execution context.tableName
- Table name@Deprecated public static java.lang.String[] getForeignFieldNames(EventHandlerContext context, java.lang.String tableName, java.lang.String fieldName)
context
- Workflow rule execution context.tableName
- Table namefieldName
- Field name@Deprecated public static java.lang.String getReferenceTableName(EventHandlerContext context, java.lang.String tableName, java.lang.String fieldName)
context
- Workflow rule execution context.tableName
- Table namefieldName
- Field name@Deprecated public static java.lang.String getTranslatableFieldName(EventHandlerContext context, java.lang.String tableName, java.lang.String fieldName, java.util.Locale locale)
context
- Workflow rule execution context.tableName
- Table namefieldName
- Field namelocale
- public static java.lang.String[] getEnumFieldStoredValues(EventHandlerContext context, java.lang.String tableName, java.lang.String fieldName)
context
- Workflow rule execution context.tableName
- Table namefieldName
- Field namepublic static java.lang.String getEnumFieldDisplayedValue(EventHandlerContext context, java.lang.String tableName, java.lang.String fieldName, java.lang.String storedValue)
context
- Workflow rule execution contexttableName
- Table namefieldName
- Field nameenumStoredValue
- Enum field's stored valuepublic static java.lang.String getFieldSingleLineHeading(EventHandlerContext context, java.lang.String tableName, java.lang.String fieldName)
context
- Workflow rule execution contexttableName
- Table namefieldName
- Field namepublic static java.lang.String[] getFieldMultiLineHeadings(EventHandlerContext context, java.lang.String tableName, java.lang.String fieldName)
context
- Workflow rule execution contexttableName
- Table namefieldName
- Field namepublic static java.lang.String getFieldMultiLineHeadingsAsString(EventHandlerContext context, java.lang.String tableName, java.lang.String fieldName, java.lang.String paddingCharacters)
context
- Workflow rule execution contexttableName
- Table namefieldName
- Field namepaddingCharacters
- padding Characters such as " " or public static void checkAddInLicense(java.lang.String applicationName, java.lang.String applicationSecurityKey)
1. The customer name in the add-in license file is the same as "Licensed To" property in the stock ARCHIBUS license file.
2. The applicationSecurityKey matches the securityKey in the add-in license file.
Third-party applications call this license check at key places (the beginning of the public methods) in their workflow rules.
applicationName
- Third-party application name, for example "MyARCHIBUSAddIn".applicationSecurityKey
- Security key of the application, for example
"k1ndl33secure!my$add-in".com.archibus.utility.ExceptionBase
- if the check fails.protected int getViewFormatVersion(EventHandlerContext context)
context
-