public class DefaultResourceImportHandler extends Object implements ResourceImportHandler
ResourceImportHandler.Status| Constructor and Description |
|---|
DefaultResourceImportHandler(BuiltInResources resType) |
DefaultResourceImportHandler(String resType)
Deprecated.
|
| Modifier and Type | Method and Description |
|---|---|
DomainPath |
createResource(String ns,
String itemName,
int version,
Outcome outcome,
boolean reset,
Object transactionKey)
Methods migrated from Bootstrap
|
CollectionArrayList |
getCollections(String name,
Integer version,
Outcome outcome)
Returns any collections that this Resource Item stored in the outcome should contain.
|
CollectionArrayList |
getCollections(String name,
String ns,
String location,
Integer version)
Returns any collections that this Resource Item should contain.
|
String |
getName()
The name of the imported resource managed by the handler
|
DomainPath |
getPath(String name,
String ns)
Returns the DomainPath for a specific resource
|
PropertyDescriptionList |
getPropDesc()
Should return all of the Properties the resource Item will have on creation.
|
String |
getResourceChangeDetails()
Reads the XML string that was created during the createResource() and importResource() methods
|
Outcome |
getResourceOutcome(String name,
String ns,
String location,
Integer version)
Generate the outcome that the resource should contain.
|
DomainPath |
getTypeRoot()
The directory context to search for existing resources.
|
String |
getWorkflowName()
Gives the CompActDef name to instantiate to provide the workflow for this type of resource.
|
DomainPath |
importResource(String ns,
String itemName,
int version,
ItemPath itemPath,
Outcome outcome,
boolean reset,
Object transactionKey)
Verify a resource Item against a Module version, but supplies the resource outcomes directly
instead of through a location lookup.
|
DomainPath |
importResource(String ns,
String itemName,
int version,
ItemPath itemPath,
String dataLocation,
boolean reset,
Object transactionKey)
Creates or updates resource Item against a Module version, using a ResourceImportHandler configured
finding the outcome at the given dataLocation.
|
public DefaultResourceImportHandler(BuiltInResources resType) throws Exception
Exception@Deprecated public DefaultResourceImportHandler(String resType) throws Exception
Exceptionpublic CollectionArrayList getCollections(String name, String ns, String location, Integer version) throws Exception
ResourceImportHandlergetCollections in interface ResourceImportHandlername - the name of the Resource Itemns - the namaspace of the module declaring the Resource Itemlocation - the location of the XML file on the boot directoryversion - the version of the Resource ItemException - something went wrongpublic CollectionArrayList getCollections(String name, Integer version, Outcome outcome) throws Exception
ResourceImportHandlergetCollections in interface ResourceImportHandlername - the name of the Resource Itemversion - the version of the Resource Itemoutcome - Outcome containing the XML representing the Resource ItemException - something went wrongpublic DomainPath getTypeRoot()
ResourceImportHandlergetTypeRoot in interface ResourceImportHandlerpublic String getName()
ResourceImportHandlergetName in interface ResourceImportHandlerpublic DomainPath getPath(String name, String ns)
ResourceImportHandlergetPath in interface ResourceImportHandlername - - resource namens - - module namespacepublic Outcome getResourceOutcome(String name, String ns, String location, Integer version) throws InvalidDataException, ObjectNotFoundException
ResourceImportHandlergetResourceOutcome in interface ResourceImportHandlername - the name of the resourcens - the namespace defined in the modulelocation - the location of the resource fileversion - the specified versionInvalidDataException - - if the supplied resources are not validObjectNotFoundException - - data was not found to handle requestpublic PropertyDescriptionList getPropDesc()
ResourceImportHandlergetPropDesc in interface ResourceImportHandlerpublic String getWorkflowName()
ResourceImportHandlergetWorkflowName in interface ResourceImportHandlerpublic DomainPath createResource(String ns, String itemName, int version, Outcome outcome, boolean reset, Object transactionKey) throws Exception
createResource in interface ResourceImportHandlerns - the NameSpace of the ModuleitemName - name of the resource Itemversion - version of the resource Itemoutcome - the Outcome to be used to create the resourcereset - whether the resources shall be updated even if the current version was modified
by someone other than the bootstrapper. Use system property 'Module.reset' or 'Module.${namespace}.reset'
to control if bootstrap should overwrite the resourceException - errors that are raised during the processpublic DomainPath importResource(String ns, String itemName, int version, ItemPath itemPath, String dataLocation, boolean reset, Object transactionKey) throws Exception
ResourceImportHandlerimportResource in interface ResourceImportHandlerns - the NameSpace of the ModuleitemName - name of the resource Itemversion - version of the resource ItemitemPath - the fixed UUID of the ItemdataLocation - the location of the resource xml available from the classpath to be used as Outcomereset - whether the resources shall be updated even if the current version was modified
by someone other than the bootstrapper. Use system property 'Module.reset' or 'Module.${namespace}.reset'
to control if bootstrap should overwrite the resourceException - errors that are raised during the processpublic DomainPath importResource(String ns, String itemName, int version, ItemPath itemPath, Outcome outcome, boolean reset, Object transactionKey) throws Exception
ResourceImportHandlerimportResource in interface ResourceImportHandlerns - the NameSpace of the ModuleitemName - name of the resource Itemversion - version of the resource ItemitemPath - the fixed UUID of the Itemreset - whether the resources shall be updated even if the current version was modified
by someone other than the bootstrapper. Use system property 'Module.reset' or 'Module.${namespace}.reset'
to control if bootstrap should overwrite the resourceException - errors that are raised during the processpublic String getResourceChangeDetails()
ResourceImportHandlergetResourceChangeDetails in interface ResourceImportHandlerCopyright © 1997–2020 CRISTAL-iSE. All rights reserved.