public abstract class BasePackageWriter extends Object implements IPackageWriter
| Modifier and Type | Field and Description |
|---|---|
protected boolean |
copiedTargetsLikeApproved |
protected int |
docId |
protected String |
extractionType |
protected String |
inputRootDir |
protected Manifest |
manifest |
protected Parameters |
params |
protected String |
rootDir |
protected ISkeletonWriter |
skelWriter |
protected boolean |
supporstOneOutputPerInput |
protected String |
tempTmxPathAlternates |
protected String |
tempTmxPathApproved |
protected String |
tempTmxPathLeverage |
protected String |
tempTmxPathUnApproved |
protected boolean |
tmxInfoAlreadySet |
protected String |
tmxPathAlternates |
protected String |
tmxPathApproved |
protected String |
tmxPathLeverage |
protected String |
tmxPathUnApproved |
protected TMXWriter |
tmxWriterAlternates |
protected TMXWriter |
tmxWriterApproved |
protected TMXWriter |
tmxWriterLeverage |
protected TMXWriter |
tmxWriterUnApproved |
protected boolean |
useLetterCodes |
protected boolean |
zeroBasedLetterCodes |
| Constructor and Description |
|---|
BasePackageWriter(String extractionType) |
| Modifier and Type | Method and Description |
|---|---|
void |
cancel()
Cancels the current process.
|
protected void |
copySupportMaterial() |
protected Event |
creatRawDocumentEventSet(String inputPath,
String defaultEncoding,
LocaleId srcLoc,
LocaleId trgLoc) |
EncoderManager |
getEncoderManager()
Gets the current encoder manager for this writer.
|
String |
getMainOutputPath() |
Parameters |
getParameters()
Gets the current parameters for this writer.
|
ISkeletonWriter |
getSkeletonWriter()
Gets the skeleton writer associated with this writer.
|
Event |
handleEvent(Event event)
Handles the filter events.
|
protected void |
initializeTMXWriters() |
protected void |
processDocumentPart(Event event) |
protected void |
processEndBatch() |
protected void |
processEndBatchItem() |
protected abstract Event |
processEndDocument(Event event) |
protected void |
processEndGroup(Event event) |
protected void |
processEndSubDocument(Event event) |
protected void |
processRawDocument(Event event) |
protected void |
processStartBatch() |
protected void |
processStartBatchItem() |
protected void |
processStartDocument(Event event) |
protected void |
processStartGroup(Event event) |
protected void |
processStartSubDocument(Event event) |
protected abstract void |
processTextUnit(Event event) |
void |
setBatchInformation(String packageRoot,
LocaleId srcLoc,
LocaleId trgLoc,
String inputRootDir,
String rootDir,
String packageId,
String projectId,
String creatorParams,
String tempPackageRoot) |
void |
setDocumentInformation(String relativeInputPath,
String filterConfigId,
String filterParameters,
String inputEncoding,
String relativeTargetPath,
String targetEncoding,
ISkeletonWriter skelWriter) |
void |
setOptions(LocaleId locale,
String defaultEncoding)
Sets the options for this writer.
|
void |
setOutput(OutputStream output)
Sets the output through its output stream.
|
void |
setOutput(String path)
Sets the output through the path of the output file.
|
void |
setParameters(IParameters params)
Sets new parameters for this writer.
|
void |
setSupporstOneOutputPerInput(boolean supporstOneOutputPerInput) |
protected void |
setTMXInfo(boolean generate,
String pathApproved,
boolean useLetterCodes,
boolean zerobasedletterCodes,
boolean overwrite) |
protected void |
writeTMXEntries(ITextUnit tu) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitclose, getNameprotected Parameters params
protected Manifest manifest
protected int docId
protected String extractionType
protected ISkeletonWriter skelWriter
protected boolean supporstOneOutputPerInput
protected String inputRootDir
protected String rootDir
protected TMXWriter tmxWriterApproved
protected String tmxPathApproved
protected String tempTmxPathApproved
protected TMXWriter tmxWriterUnApproved
protected String tmxPathUnApproved
protected String tempTmxPathUnApproved
protected TMXWriter tmxWriterAlternates
protected String tmxPathAlternates
protected String tempTmxPathAlternates
protected TMXWriter tmxWriterLeverage
protected String tmxPathLeverage
protected String tempTmxPathLeverage
protected boolean copiedTargetsLikeApproved
protected boolean useLetterCodes
protected boolean zeroBasedLetterCodes
protected boolean tmxInfoAlreadySet
public BasePackageWriter(String extractionType)
public Parameters getParameters()
IFilterWritergetParameters in interface IFilterWritergetParameters in interface IPackageWriterpublic void setParameters(IParameters params)
IFilterWritersetParameters in interface IFilterWritersetParameters in interface IPackageWriterparams - The new parameters to use.public void setBatchInformation(String packageRoot, LocaleId srcLoc, LocaleId trgLoc, String inputRootDir, String rootDir, String packageId, String projectId, String creatorParams, String tempPackageRoot)
setBatchInformation in interface IPackageWriterpublic String getMainOutputPath()
public void cancel()
IFilterWritercancel in interface IFilterWriterpublic EncoderManager getEncoderManager()
IFilterWritergetEncoderManager in interface IFilterWriterpublic ISkeletonWriter getSkeletonWriter()
IFilterWritergetSkeletonWriter in interface IFilterWriterpublic Event handleEvent(Event event)
IFilterWriterhandleEvent in interface IFilterWriterevent - The event to process.public void setOptions(LocaleId locale, String defaultEncoding)
IFilterWritersetOptions in interface IFilterWriterlocale - the output locale.defaultEncoding - Name of the character set encoding for the output.public void setOutput(String path)
IFilterWritersetOutput in interface IFilterWriterpath - Full path of the output file.public void setOutput(OutputStream output)
IFilterWritersetOutput in interface IFilterWriteroutput - Output stream to use for the output.protected void processStartBatch()
protected void setTMXInfo(boolean generate,
String pathApproved,
boolean useLetterCodes,
boolean zerobasedletterCodes,
boolean overwrite)
protected void initializeTMXWriters()
protected void processEndBatch()
protected void processStartBatchItem()
protected void processEndBatchItem()
protected void processRawDocument(Event event)
public void setDocumentInformation(String relativeInputPath, String filterConfigId, String filterParameters, String inputEncoding, String relativeTargetPath, String targetEncoding, ISkeletonWriter skelWriter)
setDocumentInformation in interface IPackageWriterprotected void processStartDocument(Event event)
protected void processStartSubDocument(Event event)
protected void processEndSubDocument(Event event)
protected void processStartGroup(Event event)
protected void processEndGroup(Event event)
protected void processDocumentPart(Event event)
protected abstract void processTextUnit(Event event)
protected void writeTMXEntries(ITextUnit tu)
public void setSupporstOneOutputPerInput(boolean supporstOneOutputPerInput)
setSupporstOneOutputPerInput in interface IPackageWriterprotected Event creatRawDocumentEventSet(String inputPath, String defaultEncoding, LocaleId srcLoc, LocaleId trgLoc)
protected void copySupportMaterial()
Copyright © 2021. All rights reserved.