|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectwt.step.processor.StepProcessor
wt.step.processor.WTStepProcessor
Extends the StepProcessor functionality to manage the import and export of STEP related files through packaged archives attached to WTDocuments as content.
StepProcessor
Field Summary | |
private static WTStepProcessor |
_theInstance
|
Fields inherited from class wt.step.processor.StepProcessor |
|
Constructor Summary | |
private |
WTStepProcessor()
Access only through getInstance() as a Singleton. |
Method Summary | |
void |
export(ExportSelection exportSelection)
Extends the StepProcessor to package up the generated STEP file and add it as primary content to a WTDocument. |
private void |
extractContentToDirectory(WTDocument doc,
File dir)
Extract the first content item of the given document as a package file, into the given directory. |
private File |
findBaseStepFile(File dir)
Finds the STEP file for a zip file import. |
static String |
getConversionLog()
|
static String[] |
getExportSchemaNames()
|
static String[] |
getImportFileList(WTDocument doc)
Gets a list of all files in the ZIP file excluding directories and the first STEP (.stp) file in the base directory. |
static String[] |
getImportSchemaNames()
|
static WTStepProcessor |
getInstance()
Get the one and only instance of the WTStepProcessor |
private static InputStream |
getPackageFileContentStream(WTDocument doc)
Accesses the first content item of the given document as an InputStream. |
private File |
getTempDir()
Create a temporary directory file. |
void |
importStepFile(WTDocument stepFilesHolder,
String importSchema,
ImportScheme versionsImportScheme,
String importFolder,
String[] importFilesList,
ManagedBaseline baseline)
Extends the StepProcessor functionality to import from a WTDocument rather than a file directory structure. |
(package private) static String[] |
listWithoutStpFile(String[] originalList)
|
private void |
packageAndAddToDocument(WTDocument document,
File contentDir,
String exportName)
Build a package file from the exported directory structure and upload it as primary content of the given document. |
Methods inherited from class wt.step.processor.StepProcessor |
exportObjects, getImportedInstances, importStepFile |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private static WTStepProcessor _theInstance
Constructor Detail |
private WTStepProcessor() throws TransferException
Method Detail |
public static final WTStepProcessor getInstance() throws TransferException
TransferException
public static String[] getExportSchemaNames() throws TransferException
TransferException
SchemaConverter.getExportSchemaNames()
public static String[] getImportSchemaNames() throws TransferException
TransferException
SchemaConverter.getImportSchemaNames()
public void export(ExportSelection exportSelection) throws TransferException
exportSelection
- What and where to export.
TransferException
private void packageAndAddToDocument(WTDocument document, File contentDir, String exportName) throws TransferException
TransferException
private File getTempDir()
public void importStepFile(WTDocument stepFilesHolder, String importSchema, ImportScheme versionsImportScheme, String importFolder, String[] importFilesList, ManagedBaseline baseline) throws TransferException
stepFilesHolder
- The WTDocument with the package file to be imported
as content (primary or secondary).baseline
- Optional baseline for holding imported items.
TransferException
StepProcessor.importStepFile(java.lang.String, java.lang.String, wt.step.processor.ImportScheme, java.lang.String, java.lang.String[], wt.vc.baseline.ManagedBaseline)
private void extractContentToDirectory(WTDocument doc, File dir) throws TransferException
TransferException
private static InputStream getPackageFileContentStream(WTDocument doc) throws TransferException
TransferException
private File findBaseStepFile(File dir) throws TransferException
Throws
- a TransferException is no '.stp' file is found.
TransferException
public static String[] getImportFileList(WTDocument doc) throws TransferException
TransferException
static String[] listWithoutStpFile(String[] originalList)
public static String getConversionLog()
SchemaConverter.getConversionLog()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |