org.nuiton.i18n.plugin
Class GenerateMojo

java.lang.Object
  extended by org.apache.maven.plugin.AbstractMojo
      extended by org.nuiton.plugin.AbstractPlugin
          extended by org.nuiton.i18n.plugin.AbstractI18nMojo
              extended by org.nuiton.i18n.plugin.GenerateMojo
All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo, org.nuiton.plugin.Plugin, org.nuiton.plugin.PluginWithEncoding

public class GenerateMojo
extends AbstractI18nMojo

Merge new generated i18n bundles with older existing ones.

Author:
jruchaud , chemit
Is defined to be executed in:
goal:
get
Is defined by the goal name:
gen
Is bound to the specified phase of the standard build lifecycle:
generate-resources

Nested Class Summary
 
Nested classes/interfaces inherited from interface org.nuiton.plugin.Plugin
org.nuiton.plugin.Plugin.InitState, org.nuiton.plugin.Plugin.Packaging
 
Field Summary
protected  boolean checkBundle
          A flag to check that bundles are complete (no missing i18n translations).
protected  boolean keepBackup
          To keep a backup of old i18n bundles (suffiex by a ~).
protected  boolean keepGetters
          To keep generated getter files.
protected  boolean showEmpty
          A flag to show missing i18n translation.
 
Fields inherited from class org.nuiton.i18n.plugin.AbstractI18nMojo
artifactId, bundles, encoding, genSrc, locales, out, project, silent, src, strictMode, verbose
 
Fields inherited from interface org.apache.maven.plugin.Mojo
ROLE
 
Constructor Summary
GenerateMojo()
           
 
Method Summary
protected  boolean checkSkip()
           
protected  void doAction()
           
 
Methods inherited from class org.nuiton.i18n.plugin.AbstractI18nMojo
addGetter, backupFile, checkBundle, checkPackaging, getArtifactId, getBackupFile, getEncoding, getGetterFile, getI18nFile, getProject, init, isSilent, isStrictMode, isVerbose, needGeneration, setEncoding, setProject, setVerbose
 
Methods inherited from class org.nuiton.plugin.AbstractPlugin
acceptPackaging, addCompileSourceRoots, addDirectoryToUrlsList, addResourceDir, addTestCompileSourceRoots, addTestResourceDir, addUrlToUrlsList, afterExecute, checkEncoding, checkResource, checkRunOnceDone, copyFile, createDirectoryIfNecessary, createNewFile, deleteFile, execute, getFileFromBasedir, getFilesToTreate, getFilesToTreateForRoots, getRootProject, getTemplate, hasClassPath, initClassLoader, isExecutionRoot, isFileNewerThanPomFile, rejectPackaging, removeCompileSourceRoots, removeTestCompileSourceRoots, renameFile, writeFile
 
Methods inherited from class org.apache.maven.plugin.AbstractMojo
getLog, getPluginContext, setLog, setPluginContext
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.apache.maven.plugin.Mojo
execute, getLog, setLog
 

Field Detail

checkBundle

protected boolean checkBundle
A flag to check that bundles are complete (no missing i18n translations).

Since:
1.0.0
Is defined by:
expression:
${i18n.checkBundle}
default-value:
true
Is required.

showEmpty

protected boolean showEmpty
A flag to show missing i18n translation.

Note : Need the checkBundle to be activated).

Since:
1.0.0
Is defined by:
expression:
${i18n.showEmpty}
default-value:
false
Is required.

keepBackup

protected boolean keepBackup
To keep a backup of old i18n bundles (suffiex by a ~).

Note: By default, this property is not active.

Is defined by:
expression:
${i18n.keepBackup}
default-value:
false

keepGetters

protected boolean keepGetters
To keep generated getter files.

Note: By default, this property is not active.

Is defined by:
expression:
${i18n.keepGetters}
default-value:
false
Constructor Detail

GenerateMojo

public GenerateMojo()
Method Detail

checkSkip

protected boolean checkSkip()
Overrides:
checkSkip in class org.nuiton.plugin.AbstractPlugin

doAction

protected void doAction()
                 throws Exception
Specified by:
doAction in class org.nuiton.plugin.AbstractPlugin
Throws:
Exception


Copyright © 2007-2011 CodeLutin. All Rights Reserved.