Package com.arbortext.epic.cms
Interface CMSAdapter
- All Known Implementing Classes:
CMSAdapterImpl
public interface CMSAdapter
Represents an installed content management system (CMS) adapter.
- Since:
- Epic 5.2
-
Method Summary
Modifier and TypeMethodDescriptionEstablishes a content management system (CMS) session.createEvent(String eventType) Creates a CMS adapter event.intgetAclId()Specifies the adapter ID associated with thisCMSAdapterobject.getName()Specifies the human-readable name for this adapter.Specifies the adapter qualified name associated with this adapter.getUserData(String key) Retrieves application data from the adapter.booleangetValid()Indicates whether this adapter object is still valid.booleanhasFeature(String feature) Indicates whether this adapter implements a specified feature.No feature strings are currently defined.voidsetOldUserData(String data) Can be used to allow theconnectmethod to work with older adapters ("Oracle iFS Adapter" or "Documentum Adapter").voidsetUserData(String key, String data) Stores some application data on the adapter.
-
Method Details
-
getName
String getName()Specifies the human-readable name for this adapter. -
getQualifiedName
String getQualifiedName()Specifies the adapter qualified name associated with this adapter. Each adapter is guaranteed to have a unique qualified name. -
getAclId
int getAclId()Specifies the adapter ID associated with thisCMSAdapterobject. You can use this ID with the Arbortext Command Language (ACL) programming language such as with thesess_connect()function. However, such usage is discouraged because the appropriate AOM method should be used instead. -
getValid
boolean getValid()Indicates whether this adapter object is still valid. Some (older) adapters can get unloaded before application exit. -
hasFeature
Indicates whether this adapter implements a specified feature.No feature strings are currently defined.- Parameters:
feature- Specifies the name of the feature.- Returns:
- Returns
trueif the feature is supported. Returnsfalseif it is not. - Throws:
CMSException- Raised for any error.
-
connect
Establishes a content management system (CMS) session. On success, this session will become the "active" session. See theactiveSessionattribute of theApplicationinterface for more details.- Parameters:
loginId- Specifies the CMS user name.password- Specifies the password for theloginIdparameter.dmsId- Specifies the CMS-specific identifier for the repository domain, library, docbase, and so forth.- Returns:
- A new CMS session.
- Throws:
CMSException- Raised for any error.
-
createEvent
Creates a CMS adapter event.- Parameters:
eventType- Specifies the type ofEventinterface to be created. The event modules supported by this method areCMSAdapterConnectEventandCMSAdapterDisconnectEvent. If theEventis to be dispatched with thedispatchEventmethod, the appropriate eventinitmethod must be called after creation in order to initialize theEvent's values. As an example, a user wishing to synthesize aCMSAdapterPreConnectevent would callcreateEventwith the parameter "CMSAdapterPreConnect". TheinitCMSAdapterConnectEventmethod could then be called on the newly createdCMSAdapterConnectEventto set the specific type ofCMSAdapterConnectEventto be dispatched and to set its context information.- Returns:
- The newly created
Event - Throws:
AOMException- Raised if the implementation does not support the type ofEventinterface requested.- Since:
- Arbortext 5.4
-
getUserData
Retrieves application data from the adapter. This method enables user interface or application code to retrieve named data that was previously stored by calling thesetUserDatamethod.- Parameters:
key- Specifies the unique key used to identify the data.- Returns:
- The data associated with the given key, or
nullif there is none. - Throws:
CMSException- Raised for any error.
-
setUserData
Stores some application data on the adapter. Any existing data for the samekeyis replaced by the new data. This method enables user interface or application code to associate named data with the adapter, which it can later retrieve by calling thegetUserDatamethod. User data is not saved between PTC Arbortext Editor or PTC Arbortext Publishing Engine sessions.
Some adapters may support additional arguments to certain methods by having the application callsetUserDatawith a predefined key just before calling the method. The adapter documentation will describe any such additional arguments.- Parameters:
key- Specifies the unique key used to identify the data.data- Specifies the data to associate with the given key, ornullto remove any existing data for the key.- Throws:
CMSException- Raised for any error.
-
setOldUserData
Can be used to allow theconnectmethod to work with older adapters ("Oracle iFS Adapter" or "Documentum Adapter"). Some older adapters require usage of a "user data" field while connecting.
This stores the given data for use with the next call to theconnectmethod. After that call, the stored data will be automatically erased so it won't affect future calls.This should only be used with older adapters and will have no effect on newer adapters.The data is stored directly with this AOM object. If this object is disposed before the method call, the data will not be available for use by the method. To avoid any issues, set the data immediately before making the method call.- Parameters:
data- Specifies the value to store as the old user data.
-