Class Xena
java.lang.Objectau.gov.naa.digipres.xena.core.Xena
public class Xena
- extends java.lang.Object
This class represents an instance of XENA. it will be able to load plugins, normalise, and a few other odds and ends. It should act as an intermediary between outside applications and xena. Xena should be a 'black box', called from any application that needs preservation services (such as a stand alone preservation tool or part of a larger preservation workflow). The Xena class allows access to Xena objects by allowing applications to get a reference to the plugin manager, which will then allow users to get component plugin managers and so on.
| Constructor Summary | |
|---|---|
Xena()
Class Constructor. |
|
| Method Summary | |
|---|---|
ExportResult |
export(XenaInputSource xis,
java.io.File destinationDir)
Export a Xena file to its original form. |
ExportResult |
export(XenaInputSource xis,
java.io.File destinationDir,
boolean overwrite)
Export a Xena file to it's original form. |
ExportResult |
export(XenaInputSource xis,
java.io.File destinationDir,
java.lang.String outputFileName,
boolean overwrite)
Export a Xena file to it's original form. |
AbstractFileNamer |
getActiveFileNamer()
This returns the currently active FileNamer. |
MetaDataWrapperPlugin |
getActiveMetaDataWrapperPlugin()
This returns currently active meta data wrapper plugin. |
AbstractMetaDataWrapper |
getActiveWrapper()
This returns currently active meta data wrapper plugin. |
Guess |
getBestGuess(XenaInputSource xis)
Return the best guess for this object. |
Guess |
getBestGuess(XenaInputSource xis,
java.util.List<java.lang.String> disabledTypeList)
Return the best guess for this object, with the given list of type names disabled. |
java.util.Map<XenaInputSource,NormaliserResults> |
getChildren(java.util.Collection<XenaInputSource> xisColl)
Returns a set of XISs which have been classified as 'children' by the filters loaded in BatchFilterManager. |
java.util.Map<XenaInputSource,NormaliserResults> |
getChildren(java.util.Iterator<XenaInputSource> xisIter)
Returns a set of XISs which have been classified as 'children' by the filters loaded in BatchFilterManager. |
java.io.File |
getDestinationDir()
Return the destination directory that Xena is currently outputting to. |
java.util.Collection<AbstractFileNamer> |
getFileNamers()
This returns the list of FileNamer objects that xena knows about. |
java.util.List<Guess> |
getGuesses(XenaInputSource xis)
Return the guesses for a given XenaInputSource sorted by likelihood that they are in fact the most likely guess. |
java.util.List<MetaDataWrapperPlugin> |
getMetaDataWrappers()
This returns a list of Meta Data Wrapper Plugins currently available. |
Type |
getMostLikelyType(XenaInputSource xis)
Return the most likely type for this object. |
Type |
getMostLikelyType(XenaInputSource xis,
java.util.List<java.lang.String> disabledTypeList)
Return the most likely type for this object. |
AbstractNormaliser |
getNormaliser(java.lang.String name)
Return the normaliser based on name - for example, "binary" returns the binary normaliser. |
AbstractNormaliser |
getNormaliser(Type type)
Returns the normaliser for a given Xena type. |
PluginManager |
getPluginManager()
Return the plugin Manager |
static java.lang.String |
getVersion()
Return the current version. |
void |
loadPlugin(java.lang.String pluginName)
Load a single plugin by name. |
void |
loadPlugins(java.io.File pluginLocation)
Load plugins from a file object. |
void |
loadPlugins(java.util.List<java.lang.String> pluginList)
Load a number of plugins by name. |
NormaliserResults |
normalise(XenaInputSource xis)
Normalise the xena input source by getting the currently active directory that is set in the fileNamerManager, active fileNamer and active wrapper, and then call: normalise(XenaInputSource, File, FileNamer, XMLFilter)
Return the NormaliserDataStore that is returned as a result of the normalisation. |
NormaliserResults |
normalise(XenaInputSource xis,
AbstractNormaliser normaliser)
Normalise a list of XenaInputSources using a specified normaliser. |
NormaliserResults |
normalise(XenaInputSource xis,
AbstractNormaliser normaliser,
java.io.File destinationDir)
Normalise a XenaInputSource using a specified normaliser. |
NormaliserResults |
normalise(XenaInputSource xis,
AbstractNormaliser normaliser,
java.io.File destinationDir,
AbstractFileNamer fileNamer,
AbstractMetaDataWrapper wrapper)
Normalise the list of XenaInputSources using the specified normaliser, FileNamer, wrapper and send the results to the specified destination directory. |
NormaliserResults |
normalise(XenaInputSource xis,
java.io.File destinationDir)
Normalise the xena input source to the destination directory, by getting the active fileNamer and wrapper, and then calling: normalise(XenaInputSource, File, FileNamer, XMLFilter) |
NormaliserResults |
normalise(XenaInputSource xis,
java.io.File destinationDir,
AbstractFileNamer fileNamer,
AbstractMetaDataWrapper wrapper)
Normalise the xena input source to the destination directory using the fileNamer and wrapper. |
NormaliserResults |
normalise(XenaInputSource xis,
java.io.File destinationDir,
AbstractMetaDataWrapper wrapper,
boolean convertOnly)
Normalise the xena input source to the destination directory, by getting the active fileNamer and using the emptywrapper if a convertOnly is specified. |
NormaliserResults |
normalise(XenaInputSource xis,
java.io.File destinationDir,
boolean convertOnly)
Normalise the xena input source to the destination directory, by getting the active fileNamer and wrapper, and then calling: normalise(XenaInputSource, File, FileNamer, XMLFilter, ConvertOnly) |
void |
registerXenaListener(XenaListener listener)
add/register a Xena listener. |
void |
removeXenaListener(XenaListener listener)
Remove/Unregister a Xena listener. |
void |
setActiveFileNamer(AbstractFileNamer fileNamer)
This sets the currently active FileNamer to the fileNamer specified. |
void |
setActiveFileNamer(java.lang.String fileNamerName)
This sets the currently active FileNamer to the fileNamer that has the name specified. |
void |
setActiveMetaDataWrapperPlugin(MetaDataWrapperPlugin metaDataWrapperPlugin)
Set the active meta data wrapper plugin |
void |
setActiveMetaDataWrapperPlugin(java.lang.String name)
Set the active meta data wrapper plugin to by name. |
void |
setBasePath(java.lang.String basePath)
Set the base path by which files should have their relative path recorded. |
void |
setDestinationDir(java.io.File destinationDir)
Set the active directory to output Xena files to. |
java.lang.String |
toString()
Return a string representation of this object. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
Xena
public Xena()
- Class Constructor.
| Method Detail |
|---|
registerXenaListener
public void registerXenaListener(XenaListener listener)
- add/register a Xena listener.
Once registered the listener will start receiving Xena event messages.
- Parameters:
listener- The XenaListener to register with Xena.
removeXenaListener
public void removeXenaListener(XenaListener listener)
- Remove/Unregister a Xena listener.
The listener will no longer receive xena message events.
- Parameters:
listener- The XenaLister to remove.
getVersion
public static java.lang.String getVersion()
- Return the current version.
- Returns:
- String
loadPlugin
public void loadPlugin(java.lang.String pluginName)
throws XenaException
- Load a single plugin by name. The plugin should exist on
the class path. If the plugin is unable to found, then
a XenaException may be thrown.
This is often the preferred way of loading plugins, since if a third party application is asking Xena to load a number of plugins and for any reason can not load one, this will allow the calling application to know exactly which plugin has failed to load. However, since plugins have dependencies, it is often easier to simply use the method loadPlugins(List<String> pluginList)
- Parameters:
pluginName- The name of the plugin- Throws:
XenaException- See Also:
loadPlugins(List)
loadPlugins
public void loadPlugins(java.util.List<java.lang.String> pluginList)
throws XenaException
- Load a number of plugins by name. The plugins should already be on the
class path.
This method should be used when a number of plugins are to be loaded through Xena, especially when some of these plugins have dependencies. Using this method, the plugin manager will actually load the plugins in the correct order to ensure that any dependencies are correctly handled.
Limitations: When loading plugins with this method there is a potential problem that if there is a major error loading a plugin, then it may be difficult to work out which plugins were loaded.
- Parameters:
pluginList- The String names of the plugins to be loaded- Throws:
XenaException- If there is an exception while loading plugins.
loadPlugins
public void loadPlugins(java.io.File pluginLocation)
throws XenaException,
java.io.IOException
- Load plugins from a file object. The file object is either jar file or a
folder containing one or more jar files.
- Parameters:
pluginLocation-- Throws:
XenaException- In case of plugin being unable to be loaded for some reasonIOExcetpion- In case of plugin being unable to be loaded for some reasonjava.io.IOException
toString
public java.lang.String toString()
- Return a string representation of this object.
Currently doesn't do much - simply returns the string Xena.
- Overrides:
toStringin classjava.lang.Object
- Returns:
- The name of this object
getPluginManager
public PluginManager getPluginManager()
- Return the plugin Manager
- Returns:
- Returns the pluginManager.
getGuesses
public java.util.List<Guess> getGuesses(XenaInputSource xis)
throws XenaException,
java.io.IOException
- Return the guesses for a given XenaInputSource sorted by likelihood that they are in fact the
most likely guess. Guesses of equal likelihood are ranked non deterministically. Or alphabetically,
which, for Xena, amounts to pretty much the same thing.
This method makes all the guessers perform a guess on the object, which results is computationally expensive. Unless all possible guesses are required, it is recommended that the method getBestGuess(XenaInputSource xis) be used instead.
- Parameters:
xis-- Returns:
- A list of Guess objects for the XenaInputSource.
- Throws:
XenaExceptionjava.io.IOException- See Also:
#GuesserManager.getGuesses(XenaInputSource xis)
getBestGuess
public Guess getBestGuess(XenaInputSource xis)
throws java.io.IOException
- Return the best guess for this object. The guess is simply the xena type
and an Integer value corresponding to the value of a guess. The higher
the better. For guesses with equal 'value', the plugin loaded latest is
preferred.
- Parameters:
xis-- Returns:
- The best Guess for this XenaInputSource
- Throws:
java.io.IOException- See Also:
getBestGuess(XenaInputSource, List)
getBestGuess
public Guess getBestGuess(XenaInputSource xis,
java.util.List<java.lang.String> disabledTypeList)
throws java.io.IOException
- Return the best guess for this object, with the given list of type
names disabled. The guess is simply the xena type
and an Integer value corresponding to the value of a guess. The higher
the better. For guesses with equal 'value', the plugin loaded latest is
preferred.
- Parameters:
xis-disabledTypeList- A list of strings that are the names of types that are disabled.- Returns:
- The best Guess for this XenaInputSource
- Throws:
java.io.IOException
getMostLikelyType
public Type getMostLikelyType(XenaInputSource xis)
throws XenaException,
java.io.IOException
- Return the most likely type for this object.
- Parameters:
xis-- Returns:
- The best Guess for this XenaInputSource
- Throws:
XenaExceptionjava.io.IOException
getMostLikelyType
public Type getMostLikelyType(XenaInputSource xis,
java.util.List<java.lang.String> disabledTypeList)
throws XenaException,
java.io.IOException
- Return the most likely type for this object.
- Parameters:
xis-- Returns:
- The best Guess for this XenaInputSource
- Throws:
XenaExceptionjava.io.IOException
getFileNamers
public java.util.Collection<AbstractFileNamer> getFileNamers()
- This returns the list of FileNamer objects that xena knows about.
- Returns:
- The collection of FileNamers
setActiveFileNamer
public void setActiveFileNamer(java.lang.String fileNamerName)
throws XenaException
- This sets the currently active FileNamer to the fileNamer that has the name
specified.
- Parameters:
fileNamerName- the name of the fileNamer to be the active filenamer.- Throws:
XenaException- in the case that the fileNamer named cannot be set to be the active filenamer.
setActiveFileNamer
public void setActiveFileNamer(AbstractFileNamer fileNamer)
throws XenaException
- This sets the currently active FileNamer to the fileNamer specified.
- Parameters:
fileNamer- the fileNamer to be the active filenamer.- Throws:
XenaException- in the case that the specified fileNamer cannot be set to be the active filenamer.
getActiveFileNamer
public AbstractFileNamer getActiveFileNamer()
- This returns the currently active FileNamer.
- Returns:
- The currently active FileNamer.
setDestinationDir
public void setDestinationDir(java.io.File destinationDir)
- Set the active directory to output Xena files to. This may be overridden at any time by
specifying the destination directory to xena, in which case the primary output file of the
normalisation will be sent to that directory.
- Parameters:
the- output directory to set the
getDestinationDir
public java.io.File getDestinationDir()
- Return the destination directory that Xena is currently outputting to.
- Returns:
- the current destination directory.
getMetaDataWrappers
public java.util.List<MetaDataWrapperPlugin> getMetaDataWrappers()
- This returns a list of Meta Data Wrapper Plugins currently available. Each Meta
Data Wrapper plugin consists of a name, an outer tag name, and a wrapper and
unwrapper class.
- Returns:
- The list of filters
getActiveMetaDataWrapperPlugin
public MetaDataWrapperPlugin getActiveMetaDataWrapperPlugin()
- This returns currently active meta data wrapper plugin.
- Returns:
- The currently active wrapper.
getActiveWrapper
public AbstractMetaDataWrapper getActiveWrapper()
throws XenaException
- This returns currently active meta data wrapper plugin.
- Returns:
- The currently active wrapper.
- Throws:
XenaException
setActiveMetaDataWrapperPlugin
public void setActiveMetaDataWrapperPlugin(java.lang.String name)
throws XenaException
- Set the active meta data wrapper plugin to by name.
- Parameters:
name- - the name of the meta data wrapper plugin that should be the active one.- Throws:
XenaException- - in the case that the named plugin is not able to be loaded.
setActiveMetaDataWrapperPlugin
public void setActiveMetaDataWrapperPlugin(MetaDataWrapperPlugin metaDataWrapperPlugin)
- Set the active meta data wrapper plugin
- Parameters:
metaDataWrapperPlugin- - the MetaDataWrapperPlugin that should be active.
setBasePath
public void setBasePath(java.lang.String basePath)
throws XenaException
- Set the base path by which files should have their relative path recorded.
This is used by the filter manager to determine how to name the files
that come into xena. By default, this will usually be set to null - files will
have their full names recorded in the meta data.
Specifically, all URIs for files will be set to be relative to the supplied base path. This is useful as often the location of the file only important relative to something else. For example, if the contents of a web server are to be normalised, it is useful to know where a file is relative to the base of the web server content, but not to, say, the C drive.
- Parameters:
String- the name of the base path- Throws:
XenaException- - when the path is incorrect.
getNormaliser
public AbstractNormaliser getNormaliser(Type type)
throws XenaException
- Returns the normaliser for a given Xena type.
- Parameters:
type-- Returns:
- The normaliser for this Xena Type.
- Throws:
XenaException
getNormaliser
public AbstractNormaliser getNormaliser(java.lang.String name)
throws XenaException
- Return the normaliser based on name - for example, "binary" returns the
binary normaliser.
- Parameters:
name-- Returns:
- a normaliser with the name specified.
- Throws:
XenaException
normalise
public NormaliserResults normalise(XenaInputSource xis)
throws XenaException
- Normalise the xena input source by getting the currently active directory that
is set in the fileNamerManager, active fileNamer and active wrapper, and then
call:
normalise(XenaInputSource, File, FileNamer, XMLFilter)Return the NormaliserDataStore that is returned as a result of the normalisation.- Parameters:
xis- - the xena input source to be normalised- Returns:
- A NormaliserDataStore object with the results of the normalisation.
- Throws:
XenaException- in the case of an error occurring during the normalisation process.- See Also:
au.gov.naa.digipres.xena.kernel.filenamer.FileNamerManager.getDestinationDir()
normalise
public NormaliserResults normalise(XenaInputSource xis,
java.io.File destinationDir)
throws XenaException
- Normalise the xena input source to the destination directory, by
getting the active fileNamer and wrapper, and then calling:
normalise(XenaInputSource, File, FileNamer, XMLFilter)Return the NormaliserDataStore that is generated as a result of the normalisation.
NOTE This method will update the destination directory for the fileNamerManager so that if any sub-packages are created during normalisation they will be output to the same location.
- Parameters:
xis- - the XenaInputSource to normalisedestinationDir- - destination directory for the normalised files- Returns:
- A NormaliserDataStore object with the results of the normalisation.
- Throws:
XenaException- in the case of an error occurring during the normalisation process.
normalise
public NormaliserResults normalise(XenaInputSource xis,
java.io.File destinationDir,
boolean convertOnly)
throws XenaException
- Normalise the xena input source to the destination directory, by
getting the active fileNamer and wrapper, and then calling:
normalise(XenaInputSource, File, FileNamer, XMLFilter, ConvertOnly)Return the NormaliserDataStore that is generated as a result of the normalisation.
NOTE This method will update the destination directory for the fileNamerManager so that if any sub-packages are created during normalisation they will be output to the same location.
- Parameters:
xis- - the XenaInputSource to normalisedestinationDir- - destination directory for the normalised filesconvertOnly- - if true only convert the input to an Open Format file- Returns:
- A NormaliserDataStore object with the results of the normalisation.
- Throws:
XenaException- in the case of an error occurring during the normalisation process.
normalise
public NormaliserResults normalise(XenaInputSource xis,
java.io.File destinationDir,
AbstractFileNamer fileNamer,
AbstractMetaDataWrapper wrapper)
throws XenaException
- Normalise the xena input source to the destination directory using the fileNamer
and wrapper. If the XenaInputSource has not got a type set, then guess
the type of the xis, and update the XenaInputSource type field. Then get
the appropriate normaliser based on the type of the XenaInputSource.
Then use the specified fileNamer, wrapper and destination directory to normalise the files.
Return a list of NormaliserDataStore objects for each xena input source.
NOTE This method will update the destination directory for the fileNamerManager so that if any sub-packages are created during normalisation they will be output to the same location.
- Parameters:
xis- - the XenaInputSource to normalisedestinationDir- - destination directory for the normalised filesfileNamer- - an instance of a FileNamer object to return the output filewrapper- - an instance of an XMLFilter to 'wrap' the normalised data stream in meta data.- Returns:
- A NormaliserDataStore object with the results of the normalisation.
- Throws:
XenaException- in the case of an error occurring during the normalisation process.
normalise
public NormaliserResults normalise(XenaInputSource xis,
java.io.File destinationDir,
AbstractMetaDataWrapper wrapper,
boolean convertOnly)
throws XenaException
- Normalise the xena input source to the destination directory, by
getting the active fileNamer and using the emptywrapper if a convertOnly is specified.
Normalise the xena input source to the destination directory using the fileNamer
and wrapper. If the XenaInputSource has not got a type set, then guess
the type of the xis, and update the XenaInputSource type field. Then get
the appropriate normaliser based on the type of the XenaInputSource.
Then use the specified fileNamer and destination directory to normalise the files.
Return a list of NormaliserDataStore objects for each xena input source.
This only performs the convertOnly normalisation.
Return the NormaliserDataStore that is generated as a result of the normalisation.
NOTE This method will update the destination directory for the fileNamerManager so that if any sub-packages are created during normalisation they will be output to the same location.
- Parameters:
xis- - the XenaInputSource to normalisedestinationDir- - destination directory for the normalised filesxis- - the XenaInputSource to normalisedestinationDir- - destination directory for the normalised fileswrapper- - an instance of an XMLFilter to 'wrap' the normalised data stream in meta data.- Returns:
- A NormaliserDataStore object with the results of the normalisation.
- Throws:
XenaException- in the case of an error occurring during the normalisation process.XenaException- in the case of an error occurring during the normalisation process.
normalise
public NormaliserResults normalise(XenaInputSource xis,
AbstractNormaliser normaliser)
throws XenaException
- Normalise a list of XenaInputSources using a specified normaliser. For
example, the binary normaliser :) Returns a list of NormaliserDataStore
objects corresponding to each XenaInputSource.
WARNING It is possible a normaliser may require the type field in the XenaInputSource to be set. This should be done by the calling application. It is generally recommended that rather than specifying a normaliser, the type field in the XenaInputSource is set appropriately instead.
- Parameters:
xis- - the XenaInputSource to normalisenormaliser- - a instance of a normaliser to use.- Returns:
- A NormaliserDataStore object with the results of the normalisation.
- Throws:
XenaException- in the case of an error occurring during the normalisation process.
normalise
public NormaliserResults normalise(XenaInputSource xis,
AbstractNormaliser normaliser,
java.io.File destinationDir)
throws XenaException
- Normalise a XenaInputSource using a specified normaliser. For
example, the binary normaliser :) Returns a NormaliserDataStore object with the results
of the normalisation for a particular XenaInputSource. Send the output files to the
specified destination.
NOTE This method will update the destination directory for the fileNamerManager so that if any sub-packages are created during normalisation they will be output to the same location.
WARNING It is possible a normaliser may require the type field in the XenaInputSource to be set. This should be done by the calling application. It is generally recommended that rather than specifying a normaliser, the type field in the XenaInputSource is set appropriately instead.
- Parameters:
xis- - the XenaInputSource to normalisenormaliser- - a instance of a normaliser to use.destinationDir- - destination directory for the normalised files- Returns:
- A NormaliserDataStore object with the results of the normalisation.
- Throws:
XenaException- in the case of an error occurring during the normalisation process.
normalise
public NormaliserResults normalise(XenaInputSource xis,
AbstractNormaliser normaliser,
java.io.File destinationDir,
AbstractFileNamer fileNamer,
AbstractMetaDataWrapper wrapper)
throws XenaException
- Normalise the list of XenaInputSources using the specified normaliser,
FileNamer, wrapper and send the results to the specified destination
directory. Return the list of NormaliserDataStore objects corresponding
to each XenaInputSource.
NOTE This method will update the destination directory for the fileNamerManager so that if any sub-packages are created during normalisation they will be output to the same location.
WARNING It is possible a normaliser may require the type field in the XenaInputSource to be set. This should be done by the calling application. It is generally recommended that rather than specifying a normaliser, the type field in the XenaInputSource is set appropriately instead.
- Parameters:
xis- - the XenaInputSource to normalisenormaliser- - a instance of a normaliser to use.destinationDir- - destination directory for the normalised filesfileNamer- - an instance of a FileNamer object to return the output filewrapper- - an instance of an XMLFilter to 'wrap' the normalised data stream in meta data.- Returns:
- A NormaliserDataStore object with the results of the normalisation.
- Throws:
XenaException- in the case of an error occurring during the normalisation process.
export
public ExportResult export(XenaInputSource xis,
java.io.File destinationDir)
throws XenaException
- Export a Xena file to its original form. It is possible that a normalised file may not be able to
be returned to it's original form, it is also possible that if it is exported some information may be lost.
The built in binary normaliser is an example of a normaliser that will always return an exact copy of the original file.
An example of the first behaviour is the NAA office normaliser - since we don't know from which office application the office document originated, we are unable to export it to its original form.
An example of the second behaviour is the NAA image normaliser - if we take an image and normalise it we will end up with a PNG file, but during encoding some information may have been lost. If the file is exported, it is possible the resulting file will have a lower resolution or colour palette.
- Parameters:
xis- - A xena input source that is to be exported.destinationDir- - the destination directory for the exported file.- Returns:
- ExportResult an object that contains all the information about the export.
- Throws:
XenaException- - Thrown if for some reason there is an error exporting. This may be from the following:- IOException reading the xis parameter;
- Error configuring the parser while exporting;
- A SAXException occurring during the export process
- A XenaException for some other reason, including there not being a denormaliser for this type, or the Xena file not being recognised at all, or the output file already existing.
- See Also:
ExportResult
export
public ExportResult export(XenaInputSource xis,
java.io.File destinationDir,
boolean overwrite)
throws XenaException
- Export a Xena file to it's original form. It is possible that a normalised file may not be able to
be returned to it's original form, it is also possible that if it is exported some information may be lost.
This method differs from the default export method in that it requires a flag to specify whether or not to overwrite files when we perform the export.
- Parameters:
xis- - A xena input source that is to be exported.destinationDir- - the destination directory for the exported file.- Returns:
- ExportResult an object that contains all the information about the export.
- Throws:
XenaException- - Thrown if for some reason there is an error exporting. This may be from the following:- IOException reading the xis parameter;
- Error configuring the parser while exporting;
- A SAXException occurring during the export process
- A XenaException for some other reason, including there not being a denormaliser for this type, or the Xena file not being recognised at all.
- See Also:
ExportResult,export(XenaInputSource xis, File destinationDir)
export
public ExportResult export(XenaInputSource xis,
java.io.File destinationDir,
java.lang.String outputFileName,
boolean overwrite)
throws XenaException
- Export a Xena file to it's original form. It is possible that a normalised file may not be able to
be returned to it's original form, it is also possible that if it is exported some information may be lost.
This method differs from the default export method in that it requires a flag to specify whether or not to overwrite files when we perform the export.
- Parameters:
xis- - A xena input source that is to be exported.destinationDir- - the destination directory for the exported file.outputFileName-destinationDir-- Returns:
- ExportResult an object containing all the information about the export.
- Throws:
XenaException- - Thrown if for some reason there is an error exporting. This may be from the following:- IOException reading the xis parameter;
- Error configuring the parser while exporting;
- A SAXException occurring during the export process
- A XenaException for some other reason, including there not being a denormaliser for this type, or the Xena file not being recognised at all.
- See Also:
export(XenaInputSource xis, File destinationDir)
getChildren
public java.util.Map<XenaInputSource,NormaliserResults> getChildren(java.util.Collection<XenaInputSource> xisColl)
- Returns a set of XISs which have been classified as 'children' by
the filters loaded in BatchFilterManager. Child XISs will be
normalised as part of the normalising process for their parent,
and thus should not be normalised separately.
This version takes a Collection of XenaInputSources.
- Parameters:
xisColl- a collection of XenaInputSources- Returns:
- The map that contains the XIS's that will be embedded into the normalised object produced by normalisation of the parent XIS. It also contains a NormaliserResults object for the child XISs as the value component of each element.
- Throws:
XenaException
getChildren
public java.util.Map<XenaInputSource,NormaliserResults> getChildren(java.util.Iterator<XenaInputSource> xisIter)
- Returns a set of XISs which have been classified as 'children' by
the filters loaded in BatchFilterManager. Child XISs will be
normalised as part of the normalising process for their parent,
and thus should not be normalised separately.
This version takes an Iterator of XenaInputSources. This version should be used for
large data sets, eg backed by a ScrollableResults from a database.
- Parameters:
xisIter- an Iterator over XenaInputSources- Returns:
- The map that contains the XIS's that will be embedded into the normalised object produced by normalisation of the parent XIS. It also contains a NormaliserResults object for the child XISs as the value component of each element.
- Throws:
XenaException



au.gov.naa.digipres.xena.core.Xena