com.edustructures.sifworks
Class AgentProperties

java.lang.Object
  extended by java.util.Dictionary<K,V>
      extended by java.util.Hashtable<java.lang.Object,java.lang.Object>
          extended by java.util.Properties
              extended by com.edustructures.sifworks.ADKProperties
                  extended by com.edustructures.sifworks.AgentProperties
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, java.util.Map<java.lang.Object,java.lang.Object>

public class AgentProperties
extends ADKProperties

Properties describing the operational settings of the agent or a zone.

The constructor will initialize each property to its default value if the property is defined in the Java System properties (more precisely, any System property that begins with the string "adk.") Otherwise the ADK's factory defaults are used. Because of this it is possible to adjust an agent's properties at runtime with the -D java command-line option.

The properties below are currently defined. Most properties can be set in both the agent or zone scope so that configurable options can be defined on a zone-by-zone basis. Properties set in the agent scope are global to the agent and inherited by all zones that have not explicitly overridden the property. To set a property in the agent scope, call Agent.getProperties method to obtain the agent's properties object, then call its setter methods. To set a property in the zone scope, call a zone's Zone.getProperties method to obtain the zone's AgentProperties object, then call its setter methods.

Property / Description
Default
adk.messaging.mode
Indicates whether the agent should operate in Push or Pull mode. Possible values include AgentMessagingMode.PUSH and AgentMessagingMode.PULL. When Push mode is selected, the agent establishes a local socket to listen for incoming messages sent by the ZIS. (The Transport object associated with a zone dictates the type and parameters of the local socket. Transport properties are set independently in Transport objects.) When Pull mode is selected, the agent periodically polls the ZIS to check its queue for new messages. The default polling frequency can adjusted with the adk.messaging.pullFrequency property. Per SIF specification, an agent must use the same messaging mode from the time it is registered on the ZIS until it is unregistered.

Version:
1.0
See Also:
getMessagingMode(),
AgentProperties.PULL
adk.messaging.transport
The transport protocol to use (e.g. "http", "https"), getTransportProtocol(), "http"
adk.messaging.pullFrequency
For pull agents: the polling frequency in milliseconds, getPullFrequency(), 30 seconds
adk.messaging.pullDelayOnError
For pull agents, gets the amount of time in milliseconds the agent will delay when it encounters a transport error or disconnected zone when attempting to pull the next message from its queue., getPullDelayOnError(), 3 minutes
adk.messaging.maxBufferSize
The maximum size of messages (in bytes) that can be processed by this agent. This setting is used whenever the SIF_MaxBufferSize element is required in a SIF_Register or SIF_Request message., getMaxBufferSize(), 393216
adk.messaging.effectiveBufferSize
The maximum size of messages (in bytes) that will be processed in-memory before the ADK off-loads the message to the local file system for processing. This setting is used internally to influence memory management but is not used in any SIF messages., getEffectiveBufferSize(), 32000
adk.keepMessageContent
Determines if the ADK will retain SIF_Message XML content after it processes a message. When enabled, the SIFMessageInfo.getMessage method returns a non-null value (otherwise it returns null). A SIFMessageInfo object is passed to all message handlers such as Subscriber.onEvent, Publisher.onQuery, and QueryResults.onQueryResults, getKeepMessageContent(), false
adk.messaging.strictVersioning
When set to true, the agent will only parse messages received from agents that are using the same version of SIF as this agent. An agent declares the version of SIF it will use when initializing the ADK's class framework. When false, the agent parses messages from all versions of SIF supported by the ADK's SIF Data Objects (SDO) library., getStrictVersioning(), false
adk.messaging.oneObjectPerResponse
Instructs the ADK to return one SIF Data Object per SIF_Response packet. When disabled (the default), the ADK fits as many SIF Data Objects in a single response packet as allowed by the requestor's SIF_MaxBufferSize., getOneObjectPerResponse(), false
adk.messaging.processEventsFromSelf
Instructs the ADK to process SIF_Event messages that were reported by this agent (i.e. the SourceId of the SIF_Event matches the SourceId of this agent). By default, such events are ignored by the class framework and automatically acknowledged as successfully received., getProcessEventsFromSelf(), false
adk.messaging.noRequestIndividualElements
A compatibility option that instructs the ADK to render SIF_Request messages without SIF_Element field restrictions. When this property is enabled, the class framework will not include SIF_Element elements in SIF_Request messages even if you have called the Query.addFieldRestriction method. This property can be used when requesting data from agents that do not work well if SIF_Elements are present in the SIF_Request., getNoRequestIndividualElements(), false
adk.messaging.disableDispatcher
Advanced - Disables the ADK's message dispatcher, causing all messages received by the agent to be ignored and disposed of immediately without dispatching to the agent's message handlers. This property is only useful in rare situations when an agent sends messages to the zone integration server but does not want to process any messages in its queue., getDisableMessageDispatcher(), false
adk.compatibility.useZoneStatusSystemControl
When this property is true and the ADK is initialized for SIF 1.5 or later, it will issue a synchronous SIF_SystemControl/SIF_GetZoneStatus message when the Zone.getZoneStatus method is called instead of using asynchronous SIF_Request messages. This mechanism of obtaining SIF_ZoneStatus is preferred over the traditional SIF_Request method, but is not officially supported in SIF as of 1.5. It is considered experimental. When this property is false (the default), the ADK issues SIF_Requests to obtain the SIF_ZoneStatus object., getUseZoneStatusSystemControl(), true if the ADK is initialize to SIF 2.0 or later, otherwise false
adk.provisioning.zisVersion
Defines the latest version of the SIF Specification supported by the Zone Integration Server to which the agent is connecting. This property defaults to the latest version of the SIF Specification supported by the ADK. Currently, it affects how SIF_Register messages are sent: if the ZIS supports SIF 1.1 or later, the ADK will send a SIF_Register with multiple SIF_Version elements, one for each version of the SIF Specification supported by the ADK. The first SIF_Version will be the version passed to the ADK.initialize method. If the ZIS does not support SIF 1.1 or later, the ADK will send a SIF_Register with a single SIF_Version element where the value is equal to the version passed to the ADK.initialize method., getZisVersion(), 1.1
adk.provisioning.overrideSifVersions
Overrides the way the ADK prepares SIF_Register/SIF_Version elements to include only the list of versions specified in the comma-delimited list. When connecting to a SIF 1.1 or later zone integration server, the class framework will include a SIF_Version element for the version of SIF used to initialize the ADK, followed by one additional SIF_Version element for each version specified by this property., getOverrideSifVersions(), null
adk.provisioning.batch
Controls how the ADK prepares SIF_Provide and SIF_Subscribe provisioning messages. When this property is set to false (the default), the ADK sends an individual SIF_Provide and SIF_Subscribe message to the zone for each SIF Data Object. If any of the messages fail with an Access Control error (Category 4), the error is recorded as a warning and subsequently returned by the Zone.getConnectWarnings method. All other SIF Errors result in an exception thrown by the Zone.connect method. When this property is set to true, SIF Data Objects are batched into a single message that will be accepted or rejected as a group by the zone integration server., isBatchProvisioning(), false
adk.provisioning.mode
The provisioning mode in effect for this zone. Possible values: "adk" for ADK-managed provisioning; "zis" for ZIS-managed provisioning; or "agent" for Agent-managed provisioning. Refer to the ADK Developer Guide for an explanation of the three provisioning modes., getProvisioningMode(), "adk"
adk.provisioning.legacy
Whether the ADK will provision the agent using the legacy SIF_Subscribe and SIF_Provide messages even if it is running in SIF 2.0. By default, the ADK will elect to use the new SIF_Provision method in SIF 2.0. However, this property may need to be set if the agent is running in SIF 2.0 against a ZIS that has not properly implemented the SIF_Provision message., getProvisionInLegacyMode(), false
adk.provisioning.ignoreErrors
A compatibility option that determines if the ADK will throw exceptions when a SIF_Error is received by the ZIS during ADK-managed provisioning. This property should be enabled when connecting to the OpenSIF ZIS (0.9.x) because that it incorrectly treats attempt to re-provide or re-subscribe as errors instead of successful statuses., getIgnoreProvisioningErrors(), false
adk.provisioning.icon
A valid URL to an icon for the agent that matches the specification for SIF_Icon. If this property is specified, it will be sent to the ZIS during agent registration., getAgentIconURL(), null
adk.provisioning.agentVendor
The name of the vendor who developed this SIF agent. This information is available in SIF_Register and SIFZoneSTatus, getAgentVendor(), null
adk.provisioning.agentVersion
The version number of this agent, e.g. "2.0.1.11", getAgentVersion(), null
adk.provisioning.applicationName
The name of the application that this agent services. This information is available in SIF_Register and SIFZoneSTatus, getApplicationName(), null
adk.provisioning.applicationVendor
The name of the vendor who developed the application that this agent services. This information is available in SIF_Register and SIFZoneSTatus, getApplicationVendor(), null
adk.provisioning.applicationVersion
The version number of the application that this agent services, e.g. "2.0.1.11", getApplicationVersion(), null
adk.queue.disable
Disables the Agent Local Queue false
adk.security.authenticationLevel
Authentication level to use for all communications with this zone. This value is specified in the header of all SIF messages to direct the Zone Integration Server to protect sending of the agent's messages to another agent with a lower authentication level., getAuthenticationLevel(), 0
adk.security.encryptionLevel
Encryption level to use for all communications with this zone. This value is specified in the header of all SIF messages to direct the Zone Integration Server to protect sending of the agent's messages to another agent with a lower encryption level., getEncryptionLevel(), 0
adk.encryption.algorithm
The default algorithm used for writing passwords, getDefaultEncryptionAlgorithm(),  
adk.encryption.key
The default key used for writing passwords., getDefaultEncryptionKeyName(),  
adk.encryption.keys.[KeyName]
The actual key to use for encryption or decryption where "keyname" matches the @KeyName attribute of the AuthenticationInfoPassword object, ADKProperties.getProperty(String),  

, Serialized Form


Field Summary
static java.lang.String PROP_DEFAULT_TIMEOUT
          adk.defaultTimeout
static java.lang.String PROP_DISABLE_DISPATCHER
          The adk.messaging.disableDispatcher property
static java.lang.String PROP_EFFECTIVE_BUFFER_SIZE
          The adk.messaging.effectiveBufferSize property
static java.lang.String PROP_FILESERVER_DIRECTORY
          adk.fileServerDirectory
static java.lang.String PROP_IGNORE_PROVISIONING_ERRORS
          adk.provisioning.ignoreErrors
static java.lang.String PROP_KEEP_MESSAGE_CONTENT
          adk.keepMessageContent
static java.lang.String PROP_MAX_BUFFER_SIZE
          The adk.messaging.maxBufferSize property
static java.lang.String PROP_MESSAGING_MODE
          The adk.messaging.mode property
static java.lang.String PROP_MESSAGING_TRANSPORT
          The adk.messaging.transport property
static java.lang.String PROP_NOREQUESTINDIVIDUALELEMENTS
          adk.messaging.noRequestIndividualElements
static java.lang.String PROP_ONEOBJECTPERRESPONSE
          adk.messaging.oneResponsePerPacket
static java.lang.String PROP_PROCESSEVENTSFROMSELF
          adk.messaging.processEventsFromSelf
static java.lang.String PROP_PROVISIONING_AGENT_VENDOR
          adk.provisioning.agentVendor
static java.lang.String PROP_PROVISIONING_AGENT_VERSION
          adk.provisioning.agentVersion
static java.lang.String PROP_PROVISIONING_APP_NAME
          adk.provisioning.applicationName
static java.lang.String PROP_PROVISIONING_APP_VENDOR
          adk.provisioning.applicationVendor
static java.lang.String PROP_PROVISIONING_APP_VERSION
          adk.provisioning.applicationVersion
static java.lang.String PROP_PROVISIONING_BATCH
          adk.provisioning.batch
static java.lang.String PROP_PROVISIONING_ICON
          adk.provisioning.icon
static java.lang.String PROP_PROVISIONING_LEGACY
          adk.provisioning.legacy
static java.lang.String PROP_PROVISIONING_MODE
          adk.provisioning.mode
static java.lang.String PROP_PROVISIONING_OVERRIDESIFVERSIONS
          adk.provisioning.overrideSifVersions
static java.lang.String PROP_PROVISIONING_ZISVERSION
          adk.provisioning.zisVersion
static java.lang.String PROP_PULL_ACKACK
          adk.messaging.pullAckAck
static java.lang.String PROP_PULL_DELAY_ON_ERROR
          adk.messaging.pullFrequency
static java.lang.String PROP_PULL_FREQUENCY
          adk.messaging.pullFrequency
static java.lang.String PROP_SLEEP_ON_DISC
          The adk.messaging.sleepOnDisconnect property
static java.lang.String PROP_STRICT_VERSIONING
          adk.messaging.strictVersioning
static java.lang.String PROP_USE_ZONE_STATUS_SYSTEM_CONTROL
          adk.compatibility.useZoneStatusSystemControl
 
Constructor Summary
AgentProperties(AgentProperties inherit)
          Constructor
 
Method Summary
 java.lang.String getAgentIconURL()
          Gets the URL to the agent's icon.
 java.lang.String getAgentVendor()
          The name of the vendor who developed this SIF agent.
 java.lang.String getAgentVersion()
          The version of this SIF Agent, e.g.
 java.lang.String getApplicationName()
          The name of the application that this agent services.
 java.lang.String getApplicationVendor()
          The name of the vendor who developed the application serviced by this agent.
 java.lang.String getApplicationVersion()
          The version of the application serviced by this agent, e.g.
 int getAuthenticationLevel()
           
 java.lang.String getDefaultEncryptionAlgorithm()
          Determines the default encryption algorithm used for writing passwords in the Authentication object.
 java.lang.String getDefaultEncryptionKeyName()
          Retrieves the default encryption key name used for writing passwords in the Authentication object
 int getDefaultTimeout()
          Gets the default timeout value used by the ADK for functions that accept a timeout as a parameter.
 boolean getDisableMessageDispatcher()
          Determines if the ADK's message dispatcher is disabled.
 boolean getDisableQueue()
           
 int getEffectiveBufferSize()
          Gets the maximum size of SIF messages that can be processed by this agent in-memory before off-loading the message to the local file system.
 byte[] getEncryptionKey(java.lang.String keyName)
          Returns the encryption key with the specified name.
 int getEncryptionLevel()
           
 boolean getIgnoreProvisioningErrors()
          A compatibility option that determines if the ADK will throw exceptions when a SIF_Error is received by the ZIS during ADK-managed provisioning.
 boolean getKeepMessageContent()
           
 int getMaxBufferSize()
          Gets the maximum size of SIF messages that can be processed by this agent when sending and receiving.
 AgentMessagingMode getMessagingMode()
          Gets the preferred agent mode of operation (push or pull).
 boolean getNoRequestIndividualElements()
          A compatibility option that determines if the ADK renders SIF_Request messages with SIF_Element field restrictions.
 boolean getOneObjectPerResponse()
          Determines if the ADK renders SIF_Response packets with one SIF Data Object per packet regardless of the requestor's SIF_MaxBufferSize value.
 java.lang.String getOverrideSifVersions()
          Gets the value passed to the setSifVersions method, or null if that method has not been called.
 boolean getProcessEventsFromSelf()
          Determines if the ADK processes or ignores SIF_Event messages that were reported by this agent (i.e.
 AgentProvisioningMode getProvisioningMode()
          Gets the provisioning mode for this zone
 boolean getProvisionInLegacyMode()
          Gets whether the ADK will provision the agent using the legacy SIF_Subscribe and SIF_Provide messages even if it is running in SIF 2.0.
 boolean getPullAckAck()
           
 int getPullDelayOnError()
          For pull agents, gets the amount of time in milliseconds the agent will delay when it encounters a transport error or disconnected zone when attempting to pull the next message from its queue.
 int getPullFrequency()
          Gets the Pull frequency when the agent is registered in Pull mode.
 boolean getSleepOnDisconnect()
          Determines if the ADK should send a SIF_Sleep message to a zone when disconnecting.
 boolean getStrictVersioning()
           
 java.lang.String getTransportProtocol()
          Gets the name of the Transport Protocol to use for this agent or zone.
 boolean getUseZoneStatusSystemControl()
          When this property is true and the ADK is initialized for SIF 1.5 or later, it will issue a synchronous SIF_SystemControl/SIF_GetZoneStatus message when the Zone.getZoneStatus method is called instead of using asynchronous SIF_Request messages.
 java.lang.String getZisVersion()
          Gets the latest version of the SIF Specification supported by the Zone Integration Server to which the agent is connecting.
 boolean isBatchProvisioning()
          Determines how the ADK prepares SIF_Provide and SIF_Subscribe messages.
 void setAgentIconURL(java.lang.String URL)
          Sets the URL to the agent's icon.
 void setAgentVendor(java.lang.String name)
          The name of the vendor who developed this SIF agent.
 void setAgentVersion(java.lang.String version)
          The version of this SIF Agent, e.g.
 void setApplicationName(java.lang.String name)
          The name of the application that this agent services.
 void setApplicationVendor(java.lang.String name)
          The name of the vendor who developed the application serviced by this agent.
 void setApplicationVersion(java.lang.String version)
          The version of this the Application serviced by this agent, e.g.
 void setAuthenticationLevel(int level)
           
 void setBatchProvisioning(boolean batch)
          Controls how the ADK prepares SIF_Provide and SIF_Subscribe messages.
 void setDefaultEncryptionAlgorithm(java.lang.String algorithm)
          Instructs the ADK to use the specified password algorithm when writing passwords in the Authentication object.
 void setDefaultEncryptionKeyName(java.lang.String keyName)
          Sets the default encryption key name used for writing passwords in the Authentication object
 void setDefaultTimeout(int ms)
          Sets the default timeout value used by the ADK for functions that accept a timeout as a parameter.
 void setDisableMessageDispatcher(boolean disable)
          Disables the ADK's message dispatcher.
 void setDisableQueue(boolean disable)
           
 void setEffectiveBufferSize(int bytes)
          Sets the maximum size of SIF messages that can be processed by this agent in-memory before off-loading the message to the local file system.
 void setEncryptionKey(java.lang.String keyName, byte[] key)
          Adds the encryption key with the specified name to the properties
 void setEncryptionLevel(int level)
           
 void setIgnoreProvisioningErrors(boolean ignore)
          A compatibility option that determines if the ADK will throw exceptions when a SIF_Error is received by the ZIS during ADK-managed provisioning.
 void setKeepMessageContent(boolean keep)
           
 void setMaxBufferSize(int bytes)
          Sets the maximum size of packets that can be processed by this agent when sending and receiving.
 void setMessagingMode(AgentMessagingMode mode)
          Sets the preferred agent mode of operation (push or pull).
 void setNoRequestIndividualElements(boolean enable)
          A compatibility option that determines if the ADK renders SIF_Request messages with SIF_Element field restrictions.
 void setOneObjectPerResponse(boolean enable)
          Determines if the ADK renders SIF_Response packets with one SIF Data Object per packet regardless of the requestor's SIF_MaxBufferSize value.
 void setOverrideSifVersions(java.lang.String versions)
          Overrides the versions of SIF supported by the agent when the class framework sends a SIF_Register message to the zone.
 void setProcessEventsFromSelf(boolean process)
          Instructs the ADK to process or ignore SIF_Event messages that were reported by this agent (i.e.
 void setProvisioningMode(AgentProvisioningMode mode)
          Sets the provisioning mode for this zone
 void setProvisionInLegacyMode(boolean provLegacy)
          Sets whether the ADK will use the legacy SIF_Subscribe and SIF_Provide messages to provision the agent, even if running in SIF 2.0.
 void setPullAckAck(boolean enabled)
           
 void setPullDelayOnError(int ms)
          For pull agents, sets the amount of time in milliseconds the agent will delay when it encounters a transport error or disconnected zone when attempting to pull the next message from its queue.
 void setPullFrequency(int ms)
          Sets the Pull frequency when the agent is registered in Pull mode.
 void setSleepOnDisconnect(boolean sleep)
          Determines if the ADK should send a SIF_Sleep message to a zone when disconnecting.
 void setStrictVersioning(boolean enabled)
           
 void setTransportProtocol(java.lang.String protocol)
          Sets the name of the Transport Protocol used by this agent or zone.
 void setUseZoneStatusSystemControl(boolean enabled)
          When this property is true and the ADK is initialized for SIF 1.5 or later, it will issue a synchronous SIF_SystemControl/SIF_GetZoneStatus message when the Zone.getZoneStatus method is called instead of using asynchronous SIF_Request messages.
 void setZisVersion(java.lang.String version)
          Gets the latest version of the SIF Specification supported by the Zone Integration Server to which the agent is connecting.
 
Methods inherited from class com.edustructures.sifworks.ADKProperties
getParent, getProperty, getProperty, getProperty, getProperty, setProperty, setProperty, setProperty
 
Methods inherited from class java.util.Properties
list, list, load, loadFromXML, propertyNames, save, store, storeToXML, storeToXML
 
Methods inherited from class java.util.Hashtable
clear, clone, contains, containsKey, containsValue, elements, entrySet, equals, get, hashCode, isEmpty, keys, keySet, put, putAll, remove, size, toString, values
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

PROP_DEFAULT_TIMEOUT

public static final java.lang.String PROP_DEFAULT_TIMEOUT
adk.defaultTimeout

See Also:
Constant Field Values

PROP_MESSAGING_MODE

public static final java.lang.String PROP_MESSAGING_MODE
The adk.messaging.mode property

See Also:
Constant Field Values

PROP_SLEEP_ON_DISC

public static final java.lang.String PROP_SLEEP_ON_DISC
The adk.messaging.sleepOnDisconnect property

See Also:
Constant Field Values

PROP_DISABLE_DISPATCHER

public static final java.lang.String PROP_DISABLE_DISPATCHER
The adk.messaging.disableDispatcher property

See Also:
Constant Field Values

PROP_MESSAGING_TRANSPORT

public static final java.lang.String PROP_MESSAGING_TRANSPORT
The adk.messaging.transport property

See Also:
Constant Field Values

PROP_MAX_BUFFER_SIZE

public static final java.lang.String PROP_MAX_BUFFER_SIZE
The adk.messaging.maxBufferSize property

See Also:
Constant Field Values

PROP_EFFECTIVE_BUFFER_SIZE

public static final java.lang.String PROP_EFFECTIVE_BUFFER_SIZE
The adk.messaging.effectiveBufferSize property

See Also:
Constant Field Values

PROP_PULL_FREQUENCY

public static final java.lang.String PROP_PULL_FREQUENCY
adk.messaging.pullFrequency

See Also:
Constant Field Values

PROP_PULL_DELAY_ON_ERROR

public static final java.lang.String PROP_PULL_DELAY_ON_ERROR
adk.messaging.pullFrequency

See Also:
Constant Field Values

PROP_PULL_ACKACK

public static final java.lang.String PROP_PULL_ACKACK
adk.messaging.pullAckAck

See Also:
Constant Field Values

PROP_STRICT_VERSIONING

public static final java.lang.String PROP_STRICT_VERSIONING
adk.messaging.strictVersioning

See Also:
Constant Field Values

PROP_ONEOBJECTPERRESPONSE

public static final java.lang.String PROP_ONEOBJECTPERRESPONSE
adk.messaging.oneResponsePerPacket

See Also:
Constant Field Values

PROP_PROCESSEVENTSFROMSELF

public static final java.lang.String PROP_PROCESSEVENTSFROMSELF
adk.messaging.processEventsFromSelf

See Also:
Constant Field Values

PROP_NOREQUESTINDIVIDUALELEMENTS

public static final java.lang.String PROP_NOREQUESTINDIVIDUALELEMENTS
adk.messaging.noRequestIndividualElements

See Also:
Constant Field Values

PROP_USE_ZONE_STATUS_SYSTEM_CONTROL

public static final java.lang.String PROP_USE_ZONE_STATUS_SYSTEM_CONTROL
adk.compatibility.useZoneStatusSystemControl

See Also:
Constant Field Values

PROP_PROVISIONING_ZISVERSION

public static final java.lang.String PROP_PROVISIONING_ZISVERSION
adk.provisioning.zisVersion

See Also:
Constant Field Values

PROP_PROVISIONING_OVERRIDESIFVERSIONS

public static final java.lang.String PROP_PROVISIONING_OVERRIDESIFVERSIONS
adk.provisioning.overrideSifVersions

See Also:
Constant Field Values

PROP_PROVISIONING_BATCH

public static final java.lang.String PROP_PROVISIONING_BATCH
adk.provisioning.batch

See Also:
Constant Field Values

PROP_PROVISIONING_LEGACY

public static final java.lang.String PROP_PROVISIONING_LEGACY
adk.provisioning.legacy

See Also:
Constant Field Values

PROP_PROVISIONING_MODE

public static final java.lang.String PROP_PROVISIONING_MODE
adk.provisioning.mode

See Also:
Constant Field Values

PROP_PROVISIONING_ICON

public static final java.lang.String PROP_PROVISIONING_ICON
adk.provisioning.icon

See Also:
Constant Field Values

PROP_PROVISIONING_AGENT_VENDOR

public static final java.lang.String PROP_PROVISIONING_AGENT_VENDOR
adk.provisioning.agentVendor

See Also:
Constant Field Values

PROP_PROVISIONING_AGENT_VERSION

public static final java.lang.String PROP_PROVISIONING_AGENT_VERSION
adk.provisioning.agentVersion

See Also:
Constant Field Values

PROP_PROVISIONING_APP_NAME

public static final java.lang.String PROP_PROVISIONING_APP_NAME
adk.provisioning.applicationName

See Also:
Constant Field Values

PROP_PROVISIONING_APP_VENDOR

public static final java.lang.String PROP_PROVISIONING_APP_VENDOR
adk.provisioning.applicationVendor

See Also:
Constant Field Values

PROP_PROVISIONING_APP_VERSION

public static final java.lang.String PROP_PROVISIONING_APP_VERSION
adk.provisioning.applicationVersion

See Also:
Constant Field Values

PROP_FILESERVER_DIRECTORY

public static final java.lang.String PROP_FILESERVER_DIRECTORY
adk.fileServerDirectory

See Also:
Constant Field Values

PROP_IGNORE_PROVISIONING_ERRORS

public static final java.lang.String PROP_IGNORE_PROVISIONING_ERRORS
adk.provisioning.ignoreErrors

See Also:
Constant Field Values

PROP_KEEP_MESSAGE_CONTENT

public static final java.lang.String PROP_KEEP_MESSAGE_CONTENT
adk.keepMessageContent

See Also:
Constant Field Values
Constructor Detail

AgentProperties

public AgentProperties(AgentProperties inherit)
Constructor

Parameters:
inherit - The parent AgentProperties from which properties will be inherited when not explicitly set on this object
Method Detail

getMessagingMode

public AgentMessagingMode getMessagingMode()
Gets the preferred agent mode of operation (push or pull). The default value is PULL_MODE.

Returns:
Either PUSH_MODE or PULL_MODE

setMessagingMode

public void setMessagingMode(AgentMessagingMode mode)
Sets the preferred agent mode of operation (push or pull).

Parameters:
mode - Either PUSH_MODE or PULL_MODE

setSleepOnDisconnect

public void setSleepOnDisconnect(boolean sleep)
Determines if the ADK should send a SIF_Sleep message to a zone when disconnecting. The default is true.

Parameters:
sleep - true if the ADK should place the agent's ZIS queue in sleep mode when disconnecting.

getSleepOnDisconnect

public boolean getSleepOnDisconnect()
Determines if the ADK should send a SIF_Sleep message to a zone when disconnecting. The default is true.

Returns:
true if the ADK should place the agent's ZIS queue in sleep mode when disconnecting.

setDisableMessageDispatcher

public void setDisableMessageDispatcher(boolean disable)
Disables the ADK's message dispatcher. When disabled, all messages received by the ADK are disposed of immediately without dispatching to the agent's message handlers. This property should only be set true in rare cases when the agent should send but not receive messages. The default is false.

Parameters:
disable - true if the ADK should disable its message dispatcher

getDisableMessageDispatcher

public boolean getDisableMessageDispatcher()
Determines if the ADK's message dispatcher is disabled. When disabled, all messages received by the ADK are disposed of immediately without dispatching to the agent's message handlers. This property should only be set true in rare cases when the agent should send but not receive messages. The default is false.

Returns:
true if the ADK's has disabled its message dispatcher

getOneObjectPerResponse

public boolean getOneObjectPerResponse()
Determines if the ADK renders SIF_Response packets with one SIF Data Object per packet regardless of the requestor's SIF_MaxBufferSize value. By default, this property is disabled, causing the ADK to fit as many SIF Data Objects per SIF_Response packet as possible.

Returns:
true if the ADK should render SIF_Response packets with one object per packet

setOneObjectPerResponse

public void setOneObjectPerResponse(boolean enable)
Determines if the ADK renders SIF_Response packets with one SIF Data Object per packet regardless of the requestor's SIF_MaxBufferSize value. By default, this property is disabled, causing the ADK to fit as many SIF Data Objects per SIF_Response packet as possible.

Parameters:
enable - true if the ADK should render SIF_Response packets with one object per packet

getNoRequestIndividualElements

public boolean getNoRequestIndividualElements()
A compatibility option that determines if the ADK renders SIF_Request messages with SIF_Element field restrictions. When this property is enabled, the class framework will not include SIF_Element elements in SIF_Request messages even if you have called the Query.addFieldRestriction method. This property can be used when requesting data from agents that do not work well if SIF_Elements are present in the SIF_Request.

Returns:
true if the ADK should not include SIF_Element elements in SIF_Request messages

setNoRequestIndividualElements

public void setNoRequestIndividualElements(boolean enable)
A compatibility option that determines if the ADK renders SIF_Request messages with SIF_Element field restrictions. When this property is enabled, the class framework will not include SIF_Element elements in SIF_Request messages even if you have called the Query.addFieldRestriction method. This property can be used when requesting data from agents that do not work well if SIF_Elements are present in the SIF_Request.


getMaxBufferSize

public int getMaxBufferSize()
Gets the maximum size of SIF messages that can be processed by this agent when sending and receiving. The default value is 32K.

Returns:
The maximum packet size in bytes

setMaxBufferSize

public void setMaxBufferSize(int bytes)
Sets the maximum size of packets that can be processed by this agent when sending and receiving.

Parameters:
bytes - The maximum packet size in bytes

getEffectiveBufferSize

public int getEffectiveBufferSize()
Gets the maximum size of SIF messages that can be processed by this agent in-memory before off-loading the message to the local file system. Used internally to influence memory management.

Returns:
The effective buffer size (in bytes)

setEffectiveBufferSize

public void setEffectiveBufferSize(int bytes)
Sets the maximum size of SIF messages that can be processed by this agent in-memory before off-loading the message to the local file system. Used internally to influence memory management.

Parameters:
bytes - The maximum packet size in bytes

getPullFrequency

public int getPullFrequency()
Gets the Pull frequency when the agent is registered in Pull mode. By default, a Pull agent will query the ZIS for new messages every 30 seconds.

Returns:
The number of milliseconds between Pull requests

setPullFrequency

public void setPullFrequency(int ms)
Sets the Pull frequency when the agent is registered in Pull mode.

Parameters:
ms - the number of milliseconds between Pull requests

getPullDelayOnError

public int getPullDelayOnError()
For pull agents, gets the amount of time in milliseconds the agent will delay when it encounters a transport error or disconnected zone when attempting to pull the next message from its queue.

Returns:
The pull delay (in milliseconds)

setPullDelayOnError

public void setPullDelayOnError(int ms)
For pull agents, sets the amount of time in milliseconds the agent will delay when it encounters a transport error or disconnected zone when attempting to pull the next message from its queue.


getPullAckAck

public boolean getPullAckAck()

setPullAckAck

public void setPullAckAck(boolean enabled)

getStrictVersioning

public boolean getStrictVersioning()

setStrictVersioning

public void setStrictVersioning(boolean enabled)

setZisVersion

public void setZisVersion(java.lang.String version)
Gets the latest version of the SIF Specification supported by the Zone Integration Server to which the agent is connecting. This property defaults to the latest version of the SIF Specification supported by the ADK.

Currently, it affects how SIF_Register messages are sent: if the ZIS supports SIF 1.1 or later, the ADK will send a SIF_Register with multiple SIF_Version elements, one for each version of the SIF Specification supported by the ADK. The first SIF_Version will be the version passed to the ADK.initialize method. If the ZIS does not support SIF 1.1 or later, the ADK will send a SIF_Register with a single SIF_Version element where the value is equal to the version passed to the ADK.initialize method.

Parameters:
version - The latest version of the SIF Specification supported by the Zone Integration Server (e.g. "1.1", "1.0r1", etc.)

getZisVersion

public java.lang.String getZisVersion()
Gets the latest version of the SIF Specification supported by the Zone Integration Server to which the agent is connecting.

Returns:
A SIF Version number (e.g. "1.1", "1.0r1", etc.)

setOverrideSifVersions

public void setOverrideSifVersions(java.lang.String versions)
Overrides the versions of SIF supported by the agent when the class framework sends a SIF_Register message to the zone.

Parameters:
versions - A comma-delimited list of SIF version or wildcard tags. When connecting to a SIF 1.1 or later zone integration server, the class framework will include a SIF_Version element for the version of SIF used to initialize the ADK, followed by one additional SIF_Version element for each version specified by this value.

getOverrideSifVersions

public java.lang.String getOverrideSifVersions()
Gets the value passed to the setSifVersions method, or null if that method has not been called.


getProvisioningMode

public AgentProvisioningMode getProvisioningMode()
Gets the provisioning mode for this zone

Returns:
An AgentProvisioningMode value

setProvisioningMode

public void setProvisioningMode(AgentProvisioningMode mode)
Sets the provisioning mode for this zone

Parameters:
mode - The provisioning mode to use

getProvisionInLegacyMode

public boolean getProvisionInLegacyMode()
Gets whether the ADK will provision the agent using the legacy SIF_Subscribe and SIF_Provide messages even if it is running in SIF 2.0. NOTE: The ADK will ALWAYs provision the agent in legacy mode if the ADK is initialized to SIF 1.5r1 or less

Returns:
True if legacy provisioning should be used

setProvisionInLegacyMode

public void setProvisionInLegacyMode(boolean provLegacy)
Sets whether the ADK will use the legacy SIF_Subscribe and SIF_Provide messages to provision the agent, even if running in SIF 2.0.

Parameters:
provLegacy - True if legacy provisioining should be used

getTransportProtocol

public java.lang.String getTransportProtocol()
Gets the name of the Transport Protocol to use for this agent or zone.

Returns:
The name of the Transport Protocol (defaults to http)

setTransportProtocol

public void setTransportProtocol(java.lang.String protocol)
Sets the name of the Transport Protocol used by this agent or zone.

Parameters:
The - name of a Transport Protocol supported by the ADK (currently http or https)

getDisableQueue

public boolean getDisableQueue()

setDisableQueue

public void setDisableQueue(boolean disable)

getKeepMessageContent

public boolean getKeepMessageContent()

setKeepMessageContent

public void setKeepMessageContent(boolean keep)

getIgnoreProvisioningErrors

public boolean getIgnoreProvisioningErrors()
A compatibility option that determines if the ADK will throw exceptions when a SIF_Error is received by the ZIS during ADK-managed provisioning. This property should be enabled when connecting to the OpenSIF ZIS (0.9.x) because that it incorrectly treats attempt to re-provide or re-subscribe as errors instead of successful statuses.

Returns:

setIgnoreProvisioningErrors

public void setIgnoreProvisioningErrors(boolean ignore)
A compatibility option that determines if the ADK will throw exceptions when a SIF_Error is received by the ZIS during ADK-managed provisioning. This property should be enabled when connecting to the OpenSIF ZIS (0.9.x) because that it incorrectly treats attempt to re-provide or re-subscribe as errors instead of successful statuses.

Parameters:
ignore -

setUseZoneStatusSystemControl

public void setUseZoneStatusSystemControl(boolean enabled)
When this property is true and the ADK is initialized for SIF 1.5 or later, it will issue a synchronous SIF_SystemControl/SIF_GetZoneStatus message when the Zone.getZoneStatus method is called instead of using asynchronous SIF_Request messages. This mechanism of obtaining SIF_ZoneStatus is preferred over the traditional SIF_Request method, but is not officially supported in SIF as of 1.5. It is considered experimental. When this property is false (the default), the ADK issues SIF_Requests to obtain the SIF_ZoneStatus object.

Parameters:
enabled -

getUseZoneStatusSystemControl

public boolean getUseZoneStatusSystemControl()
When this property is true and the ADK is initialized for SIF 1.5 or later, it will issue a synchronous SIF_SystemControl/SIF_GetZoneStatus message when the Zone.getZoneStatus method is called instead of using asynchronous SIF_Request messages. This mechanism of obtaining SIF_ZoneStatus is preferred over the traditional SIF_Request method, but is not officially supported in SIF as of 1.5. It is considered experimental. When this property is false (the default), the ADK issues SIF_Requests to obtain the SIF_ZoneStatus object.

Returns:

getAuthenticationLevel

public int getAuthenticationLevel()

setAuthenticationLevel

public void setAuthenticationLevel(int level)

getEncryptionLevel

public int getEncryptionLevel()

setEncryptionLevel

public void setEncryptionLevel(int level)

getDefaultTimeout

public int getDefaultTimeout()
Gets the default timeout value used by the ADK for functions that accept a timeout as a parameter.

Returns:
A timeout value in milliseconds (defaults to 30000)

setDefaultTimeout

public void setDefaultTimeout(int ms)
Sets the default timeout value used by the ADK for functions that accept a timeout as a parameter.


isBatchProvisioning

public boolean isBatchProvisioning()
Determines how the ADK prepares SIF_Provide and SIF_Subscribe messages.

Returns:
false if the ADK should send an individual SIF_Provide and SIF_Subscribe message to the zone for each SIF Data Object. If any of the messages fail with an Access Control error (Category 4), the error is recorded as a warning and subsequently returned by the Zone.getConnectWarnings method. All other SIF Errors result in an exception thrown by the Zone.connect method. When this property is set to true, SIF Data Objects are batched into a single message that will be accepted or rejected as a group by the zone integration server.

setBatchProvisioning

public void setBatchProvisioning(boolean batch)
Controls how the ADK prepares SIF_Provide and SIF_Subscribe messages.

Parameters:
batch - false if the ADK should send an individual SIF_Provide and SIF_Subscribe message to the zone for each SIF Data Object. If any of the messages fail with an Access Control error (Category 4), the error is recorded as a warning and subsequently returned by the Zone.getConnectWarnings method. All other SIF Errors result in an exception thrown by the Zone.connect method. When this property is set to true, SIF Data Objects are batched into a single message that will be accepted or rejected as a group by the zone integration server.

getProcessEventsFromSelf

public boolean getProcessEventsFromSelf()
Determines if the ADK processes or ignores SIF_Event messages that were reported by this agent (i.e. the SourceId of the SIF_Event matches the SourceId of this agent). By default, such events are ignored by the class framework and automatically acknowledged as successfully received.

Returns:
true if the class framework will process SIF_Event messages that were reported by this agent; false if it will ignore them

setProcessEventsFromSelf

public void setProcessEventsFromSelf(boolean process)
Instructs the ADK to process or ignore SIF_Event messages that were reported by this agent (i.e. the SourceId of the SIF_Event matches the SourceId of this agent). By default, such events are ignored by the class framework and automatically acknowledged as successfully received.

Parameters:
process - true to process SIF_Event messages that were reported by this agent; false to ignore them

getDefaultEncryptionAlgorithm

public java.lang.String getDefaultEncryptionAlgorithm()
Determines the default encryption algorithm used for writing passwords in the Authentication object.

Returns:
Returns the default encryption algorithm

setDefaultEncryptionAlgorithm

public void setDefaultEncryptionAlgorithm(java.lang.String algorithm)
Instructs the ADK to use the specified password algorithm when writing passwords in the Authentication object.

Parameters:
algorithm - The algorithm to use as the default from the PasswordAlgorithm enum ( e.g. "RC2" )

getDefaultEncryptionKeyName

public java.lang.String getDefaultEncryptionKeyName()
Retrieves the default encryption key name used for writing passwords in the Authentication object

Returns:
the encryption key name to use

setDefaultEncryptionKeyName

public void setDefaultEncryptionKeyName(java.lang.String keyName)
Sets the default encryption key name used for writing passwords in the Authentication object

Parameters:
keyName -

getEncryptionKey

public byte[] getEncryptionKey(java.lang.String keyName)
                        throws java.io.IOException
Returns the encryption key with the specified name.

Parameters:
keyName - The name that the key is saved under in the properties
Returns:
The encryption key or null if not found
Throws:
java.io.IOException

setEncryptionKey

public void setEncryptionKey(java.lang.String keyName,
                             byte[] key)
                      throws java.io.IOException
Adds the encryption key with the specified name to the properties

Parameters:
keyName - The name to save the key under
key - The encryption key
Throws:
java.io.IOException

getAgentIconURL

public java.lang.String getAgentIconURL()
Gets the URL to the agent's icon. The icon must meet the requirements for the SIF_Icon element. If this property is set, the agent will send a <SIF_Icon> element during agent registration

Returns:
the URL to the agent's ICON

setAgentIconURL

public void setAgentIconURL(java.lang.String URL)
Sets the URL to the agent's icon. The icon must meet the requirements for the SIF_Icon element. If this property is set, the agent will send a <SIF_Icon> element during agent registration

Parameters:
URL - The URL to the agent's icon

getAgentVendor

public java.lang.String getAgentVendor()
The name of the vendor who developed this SIF agent. If set, this information will sent to the ZIS during agent registration.

Returns:
the name of the vendor that developed this agent

setAgentVendor

public void setAgentVendor(java.lang.String name)
The name of the vendor who developed this SIF agent. If set, this information will sent to the ZIS during agent registration.

Parameters:
name - The URL to the agent's icon

getAgentVersion

public java.lang.String getAgentVersion()
The version of this SIF Agent, e.g. "2.0.0.11"

Returns:
the version of this SIF Agent

setAgentVersion

public void setAgentVersion(java.lang.String version)
The version of this SIF Agent, e.g. "2.0.0.11"

Parameters:
version - the version of this SIF Agent

getApplicationName

public java.lang.String getApplicationName()
The name of the application that this agent services. This information is available in SIF_Register and SIFZoneStatus

Returns:
the name of the application serviced by this agent

setApplicationName

public void setApplicationName(java.lang.String name)
The name of the application that this agent services. This information is available in SIF_Register and SIFZoneStatus

Parameters:
name - The name of the application

getApplicationVendor

public java.lang.String getApplicationVendor()
The name of the vendor who developed the application serviced by this agent. If set, this information will sent to the ZIS during agent registration.

Returns:
the name of the vendor that developed the application serviced by this agent

setApplicationVendor

public void setApplicationVendor(java.lang.String name)
The name of the vendor who developed the application serviced by this agent. If set, this information will sent to the ZIS during agent registration.

Parameters:
name - The name of the vendor of the application serviced by this agent

getApplicationVersion

public java.lang.String getApplicationVersion()
The version of the application serviced by this agent, e.g. "2.0.0.11"

Returns:
the version of the application serviced by this agent

setApplicationVersion

public void setApplicationVersion(java.lang.String version)
The version of this the Application serviced by this agent, e.g. "2.0.0.11"

Parameters:
version - the version of the application serviced by this agent


Copyright © 2001-2007 Edustructures LLC. All Rights Reserved. SIFWorks® and ADK® are registered trademarks of Edustructures LLC. SIF™ and Schools Interoperability Framework are trademarks of the Schools Interoperability Framework Association.