@Mojo(name="generate-help-files",
defaultPhase=PROCESS_SOURCES,
requiresProject=true,
requiresDependencyResolution=COMPILE)
@Execute(goal="generate-help-ids")
public class GenerateHelpFilesMojo
extends AbstractGenerateHelpMojo
AbstractJaxxMojo.JaxxFileUpdater| Modifier and Type | Field and Description |
|---|---|
protected static String |
AUTOREMOVE_LINE |
protected File |
contentTemplate
The template used to generate helpset content file.
|
protected Properties |
helpIds
The help ids discovered.
|
protected String |
helpsetName
The name of the helpset to generate.
|
protected File |
helpsetTemplate
The template used to generate helpset file.
|
protected File |
idsFile |
protected String |
indexFileName |
protected File |
indexTemplate
The template used to generate helpset index file.
|
protected String |
mapFileName |
protected File |
mapTemplate
The template used to generate helpset map file.
|
protected File |
outputHelp
The directory where to create or update help files.
|
protected String |
tocFileName |
protected File |
tocTemplate
The template used to generate helpset toc file.
|
protected int |
touchedFiles |
generateSearch, localesgenerateHelp| Constructor and Description |
|---|
GenerateHelpFilesMojo() |
| Modifier and Type | Method and Description |
|---|---|
protected boolean |
checkSkip() |
protected void |
doActionForLocale(Locale locale,
boolean isDefaultLocale,
File localizedTarget,
String localePath)
Do the action for the given locale.
|
protected void |
doGen(File template,
File f,
Properties env) |
protected int |
generateContentFiles(File localizedTarget,
Properties env,
String localePath) |
protected boolean |
generateHelpsetFile(File file,
Properties env) |
protected NodeItem |
generateIndexFile(File file,
Properties env) |
protected Properties |
generateMapFile(File file,
Properties env) |
protected NodeItem |
generateTocFile(File file,
Properties env) |
File |
getTargetDirectory() |
void |
init() |
protected void |
postDoAction()
Call back after doing all stuff for all locales declared
|
protected void |
preDoAction()
Call back before doing all stuff for all locales declared
|
protected org.nuiton.plugin.VelocityTemplateGenerator |
prepareGenerator(File template) |
void |
setTargetDirectory(File targetDirectory) |
cleanHelpIdsStore, doAction, getHelpIdsFilename, getHelpIdsStoreFile, getMergeHelpIdsFilename, getMergeHelpIdsStoreFile, getOutputHelpIds, loadHelpIds, removeQuote, setHelpIdsFilename, setMergeHelpIdsFilename, setOutputHelpIds, storeHelpIdscheckPackaging, getEncoding, getLastModified, getProject, isForce, isVerbose, setEncoding, setForce, setProject, setVerboseacceptPackaging, addCompileSourceRoots, addDirectoryToUrlsList, addResourceDir, addTestCompileSourceRoots, addTestResourceDir, addUrlToUrlsList, afterExecute, backupFile, checkEncoding, checkResource, checkRunOnceDone, copyFile, createDirectoryIfNecessary, createNewFile, deleteFile, execute, getBackupFile, getFileFromBasedir, getFilesToTreate, getFilesToTreateForRoots, getRootProject, getTemplate, hasClassPath, initClassLoader, isExecutionRoot, isFileNewerThanPomFile, needInvoke, needInvoke, rejectPackaging, removeCompileSourceRoots, removeTestCompileSourceRoots, renameFile, writeFilegetLog, getPluginContext, setLog, setPluginContextprotected static final String AUTOREMOVE_LINE
@Parameter(property="jaxx.outputHelp",
defaultValue="${project.basedir}/src/main/help",
required=true)
protected File outputHelp
@Parameter(property="jaxx.helpsetName",
defaultValue="${project.artifactId}",
required=true)
protected String helpsetName
@Parameter(property="jaxx.helpsetTemplate",
defaultValue="/defaultHelpSet.hs.vm",
required=true)
protected File helpsetTemplate
@Parameter(property="jaxx.mapTemplate",
defaultValue="/defaultMap.jhm.vm",
required=true)
protected File mapTemplate
@Parameter(property="jaxx.indexTemplate",
defaultValue="/defaultIndex.xml.vm",
required=true)
protected File indexTemplate
@Parameter(property="jaxx.tocTemplate",
defaultValue="/defaultToc.xml.vm",
required=true)
protected File tocTemplate
@Parameter(property="jaxx.contentTemplate",
defaultValue="/defaultContent.html.vm",
required=true)
protected File contentTemplate
protected String mapFileName
protected String indexFileName
protected String tocFileName
protected int touchedFiles
protected File idsFile
protected Properties helpIds
public File getTargetDirectory()
getTargetDirectory in class AbstractJaxxMojopublic void setTargetDirectory(File targetDirectory)
setTargetDirectory in class AbstractJaxxMojopublic void init()
throws Exception
init in class AbstractGenerateHelpMojoExceptionprotected boolean checkSkip()
checkSkip in class AbstractGenerateHelpMojoprotected void preDoAction()
AbstractGenerateHelpMojopreDoAction in class AbstractGenerateHelpMojoprotected void postDoAction()
AbstractGenerateHelpMojopostDoAction in class AbstractGenerateHelpMojoprotected void doActionForLocale(Locale locale, boolean isDefaultLocale, File localizedTarget, String localePath) throws Exception
AbstractGenerateHelpMojodoActionForLocale in class AbstractGenerateHelpMojolocale - the locale to treateisDefaultLocale - true if given locale is de the default
localelocalizedTarget - where are stored help files for the given localelocalePath - the locale path to use (is default if
given locale is default).Exception - if any pbprotected int generateContentFiles(File localizedTarget, Properties env, String localePath) throws Exception
Exceptionprotected boolean generateHelpsetFile(File file, Properties env) throws Exception
Exceptionprotected Properties generateMapFile(File file, Properties env) throws Exception
Exceptionprotected NodeItem generateIndexFile(File file, Properties env) throws Exception
Exceptionprotected NodeItem generateTocFile(File file, Properties env) throws Exception
Exceptionprotected void doGen(File template, File f, Properties env) throws Exception
ExceptionCopyright © 2008–2019 Ultreia.io. All rights reserved.