Package wt.ixb.publicforapps
Class ApplicationImportHandlerTemplate
java.lang.Object
wt.ixb.publicforapps.ApplicationImportHandlerTemplate
- All Implemented Interfaces:
ApplicationExpImportHandler,ApplicationImportHandler
- Direct Known Subclasses:
ApplicationImportHandlerForJar,ApplicationImportHandlerForRepository,ApplicationImportHandlerForXml
/** Class extends
Supported API: true
Extendable: true
ApplicationImportHandler interface with trivial implementations. It
can be used by application to make application less dependent of future extension of
ApplicationImportHandler interface. Supported API: true
Extendable: true
-
Field Summary
Fields inherited from interface wt.ixb.publicforapps.ApplicationExpImportHandler
IMPORTANCE_LEVEL_DEFAULT, PREFIX_SEPERATOR, USERLOG_PREFIX -
Method Summary
Modifier and TypeMethodDescriptionvoidcleanUpAfterImport(boolean outcome) do some cleanup operations after import
Supported API: truevoidNotifies application about objects after being persisted.getContentAsApplicationData(String contentId) Returns ApplicationData representing input information for import process.getContentAsInputStream(String contentId) Returns InputStream representing input information for import process
Supported API: true
get the value of attribute formatType
Supported API: trueReturns the value of the current IX application context.long
get the size of jarEntryPath
Supported API: trueint
get the value of attribute userLogLevel
Supported API: truevoidimportObjectNotification(Object object, boolean created, IxbElement fileXML) Notifies application about objects, that are created in import process.boolean
get the value of attribute ixbWithGUI
Supported API: truebooleanGets the value of the attribute: multiple.booleanGet the flag as true or false respectively based on if multi thread Import is applicable or not.voidsetFormatType(ExportImportFormatType formatType)
set the value of attribute formatType
Supported API: truevoidsetIXApplicationContext(IXApplicationContext appContext) Sets the value of the IX application context.voidsetIxbWithGUI(boolean ixbWithGUI)
set the value of attribute ixbWithGUI
Supported API: truevoidsetMultiple(boolean multiple) Sets the value of the attribute: multiple.voidsetUserLogLevel(int userLogLevel)
set the value of attribute userLogLevel
Supported API: truevoidstoreLogMessage(String resourceBundle, String messageKey, Object[] textInserts) Supplies the localized log message for the application.voidstoreLogMessage(String resourceBundle, String messageKey, Object[] textInserts, int importanceLevel) Supplies the localized log message for the application.
-
Method Details
-
isMultithreadedImportApplicable
public boolean isMultithreadedImportApplicable()Get the flag as true or false respectively based on if multi thread Import is applicable or not.
Supported API: true- Returns:
- boolean
-
isMultiple
public boolean isMultiple()Gets the value of the attribute: multiple.
Supported API: true- Returns:
- multiple
- Throws:
WTException
-
setMultiple
public void setMultiple(boolean multiple) Sets the value of the attribute: multiple.
Supported API: true- Parameters:
multiple-- Throws:
WTException
-
cleanUpAfterImport
do some cleanup operations after import
Supported API: true- Parameters:
outcome-- Throws:
WTException
-
getContentAsInputStream
Returns InputStream representing input information for import process
Supported API: true- Specified by:
getContentAsInputStreamin interfaceApplicationImportHandler- Parameters:
contentId- The unique id to identify the content data, such as the file name (including the path) in a jar file.- Returns:
- InputStream
- Throws:
WTException
-
getContentAsApplicationData
Returns ApplicationData representing input information for import process. Import application does not have really implement this method. It can simple returnnull.
Supported API: true- Specified by:
getContentAsApplicationDatain interfaceApplicationImportHandler- Parameters:
contentId- The unique id to identify the content data, such as the file name (including the path) in a jar file.- Returns:
- ApplicationData
- Throws:
WTException
-
importObjectNotification
public void importObjectNotification(Object object, boolean created, IxbElement fileXML) throws WTException Notifies application about objects, that are created in import process.
Supported API: true- Specified by:
importObjectNotificationin interfaceApplicationImportHandler- Parameters:
object-created- "true" if import process creates new object and "false" otherwise.fileXML-- Throws:
WTException
-
finalizeImportObjectNotification
Notifies application about objects after being persisted.
Supported API: true- Specified by:
finalizeImportObjectNotificationin interfaceApplicationImportHandler- Parameters:
object-- Throws:
WTException
-
storeLogMessage
public void storeLogMessage(String resourceBundle, String messageKey, Object[] textInserts, int importanceLevel) throws WTException Supplies the localized log message for the application.
Supported API: true- Specified by:
storeLogMessagein interfaceApplicationExpImportHandler- Parameters:
resourceBundle-messageKey-textInserts-importanceLevel-- Throws:
WTException
-
storeLogMessage
public void storeLogMessage(String resourceBundle, String messageKey, Object[] textInserts) throws WTException Supplies the localized log message for the application.
Supported API: true- Parameters:
resourceBundle-messageKey-textInserts-- Throws:
WTException
-
getSize
get the size of jarEntryPath
Supported API: true- Parameters:
jarEntryPath-- Returns:
- size
- Throws:
WTException
-
isIxbWithGUI
public boolean isIxbWithGUI()
get the value of attribute ixbWithGUI
Supported API: true- Returns:
- ixbWithGUI
-
setIxbWithGUI
public void setIxbWithGUI(boolean ixbWithGUI)
set the value of attribute ixbWithGUI
Supported API: true- Parameters:
ixbWithGUI-
-
getUserLogLevel
public int getUserLogLevel()
get the value of attribute userLogLevel
Supported API: true- Returns:
- userLogLevel
-
setUserLogLevel
public void setUserLogLevel(int userLogLevel)
set the value of attribute userLogLevel
Supported API: true- Parameters:
userLogLevel-
-
getFormatType
get the value of attribute formatType
Supported API: true- Returns:
- formatType
-
setFormatType
set the value of attribute formatType
Supported API: true- Parameters:
formatType-
-
setIXApplicationContext
Sets the value of the IX application context.
Supported API: true- Parameters:
appContext-
-
getIXApplicationContext
Returns the value of the current IX application context.
Supported API: true- Returns:
-