Package com.thortech.xl.ejb.beansimpl
Class tcExportOperationsBean
java.lang.Object
Thor.API.Base.tcBaseUtility
com.thortech.xl.ejb.beansimpl.tcExportOperationsBean
- All Implemented Interfaces:
com.thortech.xl.dataobj.tcErrorReceiver,com.thortech.xl.orb.api.operations._tcUtilityIntfOperations,com.thortech.xl.server.tcOrbServerObject,Serializable,javax.ejb.EnterpriseBean,javax.ejb.SessionBean,tcUtilityOperationsIntf,tcExportOperationsIntf
public class tcExportOperationsBean
extends tcBaseUtility
implements javax.ejb.SessionBean, tcExportOperationsIntf
Server-side API class for Exports using Deployment Manager
The APIs will be called in following order:
- findObjects : Find objects to be exported
- getExportXML(objectCollection, description) : Get the xml by passing the object collection
- Author:
- evandana
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class Thor.API.Base.tcBaseUtility
tcBaseUtility.Entities -
Field Summary
Fields inherited from class Thor.API.Base.tcBaseUtility
ALL_ATTR_OB, DATE_FORMAT_SYS_PROP, DEFAULT_DATE_PATTERN, DEFAULT_LOCALE, DISPLAYNAME, FIRSTNAME, LASTNAME, LKU_GROUP, MANAGERKEY, OBJECTCLASS_COL_CODE, ORG_NAME, ORGANIZATION_KEY_COL_CODE, ORGANIZATION_NAME_COL_CODE, ORGANIZATION_PARENT_KEY_COL_CODE, ORGANIZATION_PARENT_NAME_COL_CODE, ORGKEY, ORGNAME, PARENTORGNAME, ROLE_KEY_COL_CODE, ROLE_NAME_COL_CODE, STATUS, USER_ENTITY, USER_MANAGEMENT, USERID, USERKEY, USR_DEFINED_COLUMN_CONSTANT, USR_KEY_COL_CODE, USR_MANAGER_DISPLAY_NAME_COL_CODE, USR_MANAGER_DISPLAY_NAME_LABEL, USR_MANAGER_FIRST_NAME_COL_CODE, USR_MANAGER_FIRST_NAME_COLUMN, USR_MANAGER_FIRST_NAME_LABEL, USR_MANAGER_KEY_COL_CODE, USR_MANAGER_LAST_NAME_COL_CODE, USR_MANAGER_LAST_NAME_COLUMN, USR_MANAGER_LAST_NAME_LABEL, USR_MANAGER_LOGIN_COL_CODE, USR_MANAGER_LOGIN_COLUMN, USR_MANAGER_LOGIN_LABEL -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionarrangeSelectionAsATree(Collection objects) Arranges the passed objects as a TreevoidTheejbActivate()method as required by the EJB specification.
The activate method is called when the instance is activated from its passive" state.voidPopulate SchemaFacade and initializes SchemaInstancevoidTheejbPassivate()method as required by the EJB specification.
The activate method is called when the instance is activated from its "passive" state.findObjects(String type, String searchPattern) Find the objects for a given type, with a given searchPattern.getDependencies(Collection root) Return a list of dependent objects for the selected root objectsGet the tree view to be displayed for export operationgetExportXML(Collection rootObjects, String description) Export selected objects.com.thortech.xl.ddm.engine.SchemaFacadeRetrieve the categories name via iterating all the root objects metadata, which are having the actual data.retrieveChildren(Collection objects) Retrieve the children of the selected objects as a treeretrieveDependencyTree(Collection objects) Find dependencies, and return them as a tree.voidsetSchema(com.thortech.xl.ddm.engine.SchemaFacade schema) Methods inherited from class Thor.API.Base.tcBaseUtility
addError, addErrorReceiver, addReject, clearErrors, close, ejbRemove, getDataBase, getDefaultLocaleCode, getEJBContext, getErrors, getMap, getMapping, getName, getQueryFilter, getRejections, getSessionContext, getUnAuthorizedTargetFieldSet, removeErrorReceiver, removeInstance, setCountry, setLanguage, setSessionContext, setVariantMethods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface javax.ejb.SessionBean
ejbRemove, setSessionContextMethods inherited from interface Thor.API.Base.tcUtilityOperationsIntf
close, getName, setCountry, setLanguage, setVariant
-
Constructor Details
-
tcExportOperationsBean
public tcExportOperationsBean()
-
-
Method Details
-
ejbPassivate
Description copied from class:tcBaseUtilityTheejbPassivate()method as required by the EJB specification.
The activate method is called when the instance is activated from its "passive" state. The instance should acquire any resource that it has released earlier in theejbActivate()method.
This method is called with no transaction context.- Specified by:
ejbPassivatein interfacejavax.ejb.SessionBean- Overrides:
ejbPassivatein classtcBaseUtility- Throws:
javax.ejb.EJBException- Thrown if the instance could not perform the function requested by the container because of an system-level error.RemoteException
-
ejbActivate
Description copied from class:tcBaseUtilityTheejbActivate()method as required by the EJB specification.
The activate method is called when the instance is activated from its passive" state. The instance should acquire any resource that it has released earlier in theejbPassivate()method.
This method is called with no transaction context.- Specified by:
ejbActivatein interfacejavax.ejb.SessionBean- Overrides:
ejbActivatein classtcBaseUtility- Throws:
javax.ejb.EJBException- Thrown if the instance could not perform the function requested by the container because of an system-level error.RemoteException
-
ejbCreate
Populate SchemaFacade and initializes SchemaInstance- Throws:
DDMExceptionjavax.ejb.CreateException
-
getExportView
Get the tree view to be displayed for export operation- Specified by:
getExportViewin interfacetcExportOperationsIntf- Returns:
- Collection of RootObjects
- Throws:
tcAPIException
-
getExportXML
Export selected objects. Generate doc object to export all the selected root objects in the form of xml.- Specified by:
getExportXMLin interfacetcExportOperationsIntf- Parameters:
rootObjects-description- string containing the description of exported XML- Returns:
- string containing the export XML
- Throws:
tcAPIException
-
getDependencies
Return a list of dependent objects for the selected root objects- Specified by:
getDependenciesin interfacetcExportOperationsIntf- Parameters:
rootObjects-- Returns:
- collection of dependent objects
- Throws:
tcAPIExceptiontcAPIException
-
findObjects
Find the objects for a given type, with a given searchPattern. searchPattern can have '*' to indicate any pattern. Type can be a name, or '*' to indicate all types- Specified by:
findObjectsin interfacetcExportOperationsIntf- Parameters:
type-name-- Returns:
- objects matched
- Throws:
tcAPIException
-
retrieveCategories
Retrieve the categories name via iterating all the root objects metadata, which are having the actual data.- Specified by:
retrieveCategoriesin interfacetcExportOperationsIntf- Returns:
- category collection. Collection contains strings
- Throws:
tcAPIException
-
retrieveChildren
Retrieve the children of the selected objects as a tree- Specified by:
retrieveChildrenin interfacetcExportOperationsIntf- Parameters:
objects- (Collection of root objects)- Returns:
- children of the selected elements as a tree
- Throws:
DDMExceptiontcAPIException
-
retrieveDependencyTree
Find dependencies, and return them as a tree. Tree only contains the children of the dependencies. Not their parents.- Specified by:
retrieveDependencyTreein interfacetcExportOperationsIntf- Parameters:
objects-- Returns:
- dependencies with all the children
- Throws:
tcAPIException
-
arrangeSelectionAsATree
Arranges the passed objects as a Tree- Specified by:
arrangeSelectionAsATreein interfacetcExportOperationsIntf- Parameters:
objects-- Returns:
- collection arranged as a tree as much as possible
- Throws:
tcAPIException
-
setSchema
public void setSchema(com.thortech.xl.ddm.engine.SchemaFacade schema) -
getSchema
public com.thortech.xl.ddm.engine.SchemaFacade getSchema()
-