com.google.template.soy.xliffmsgplugin
Class XliffMsgPlugin
java.lang.Object
com.google.template.soy.xliffmsgplugin.XliffMsgPlugin
- All Implemented Interfaces:
- SoyMsgPlugin
public class XliffMsgPlugin
- extends Object
- implements SoyMsgPlugin
Message plugin for XLIFF format.
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
XliffMsgPlugin
@Inject
public XliffMsgPlugin()
generateExtractedMsgsFile
public CharSequence generateExtractedMsgsFile(SoyMsgBundle msgBundle,
SoyMsgBundleHandler.OutputFileOptions options)
throws SoyMsgException
- Description copied from interface:
SoyMsgPlugin
- Builds the content of an output message file (one that will be sent for translation) from a
given message bundle object containing messages extracted from source files.
- Specified by:
generateExtractedMsgsFile in interface SoyMsgPlugin
- Parameters:
msgBundle - The bundle of messages extracted from source files.options - The options to use for generating the output message file (e.g. the source
locale/language of the messages). Not all options will apply to all message plugins.
- Returns:
- The content of the generated output file.
- Throws:
SoyMsgException - If there was an error building the file content.
parseTranslatedMsgsFile
public SoyMsgBundle parseTranslatedMsgsFile(String inputFileContent)
throws SoyMsgException
- Description copied from interface:
SoyMsgPlugin
- Parses the content of an input message file (one that has been translated) and builds a
message bundle object.
- Specified by:
parseTranslatedMsgsFile in interface SoyMsgPlugin
- Parameters:
inputFileContent - The content of the translated message file.
- Returns:
- The message bundle object built from the message file.
- Throws:
SoyMsgException - If there was an error parsing the file content.