public class CrowdinFileFactory extends Object
| Constructor and Description |
|---|
CrowdinFileFactory(AbstractCrowdinMojo _mojo) |
| Modifier and Type | Method and Description |
|---|---|
static String |
encodeMinusCharacterInPath(String path,
boolean isEncode) |
boolean |
isTranslation(String _filename)
Checks whether a file is a translation or not, depending of the format of its filename.
|
Matcher |
matchTranslation(String _filename)
Compares the given filename on a defined pattern to identify its parts (name, lang, type).
|
CrowdinFile |
prepareCrowdinFile(String _path,
String _name,
String _project)
Creates and returns a CrowdinFile (master).
|
CrowdinTranslation |
prepareCrowdinTranslation(CrowdinFile _master,
File _translationFile)
Creates and return a CrowdinTranslation.
|
public CrowdinFileFactory(AbstractCrowdinMojo _mojo)
public CrowdinFile prepareCrowdinFile(String _path, String _name, String _project)
_path - the real path of the file on the system_name - the name with the Crowdin path_project - the project in Crowdinpublic boolean isTranslation(String _filename)
_filename - the name of the filepublic Matcher matchTranslation(String _filename)
_filename - the filename to match on the patternpublic CrowdinTranslation prepareCrowdinTranslation(CrowdinFile _master, File _translationFile)
_master - The master CrowdinFile for this translation_translationFile - the real FileCopyright © 2003–2017 eXo Platform SAS. All rights reserved.