org.acmsl.antmake
Class MakeRulesTemplate

java.lang.Object
  |
  +--org.acmsl.antmake.MakeRulesTemplate

public abstract class MakeRulesTemplate
extends java.lang.Object

Template to generate Make-rules files.

Version:
$Revision: 1.3 $
Author:
Jose San Leandro

Field Summary
static java.lang.String DEFAULT_BASE_FOLDER_VARIABLE
          The default base folder variable.
static java.lang.String DEFAULT_BODY
          The default Make-Rules body.
static java.lang.String DEFAULT_CLASSPATH_ENV_DECLARATION
          The default classpath declaration.
static java.lang.String DEFAULT_FILE_SEPARATOR
          The default file separator.
static java.lang.String DEFAULT_HEADER
          The default header.
static java.lang.String DEFAULT_JAVAC_FLAGS
          The default javac flags.
static java.lang.String DEFAULT_PATH_SEPARATOR
          The default path separator.
 
Constructor Summary
MakeRulesTemplate(java.lang.String projectName)
          Builds a MakeRulesTemplate using given information.
MakeRulesTemplate(java.lang.String header, java.lang.String body, java.lang.String javacFlags, java.lang.String classpathEnv, java.lang.String baseFolder, java.lang.String pathSeparator, java.lang.String fileSeparator, java.lang.String projectName)
          Builds a MakeRulesTemplate using given information.
 
Method Summary
 void addClasspathItem(java.lang.String item)
          Adds a new classpath item.
 java.lang.String getBaseFolder()
          Retrieves the base folder.
 java.lang.String getBody()
          Retrieves the body.
 java.lang.String getClasspathEnv()
          Retrieves the CLASSPATH_ENV.
protected  java.util.Collection getClasspathItems()
          Retrieves the classpath items.
 java.lang.String getFileSeparator()
          Retrieves the file separator.
 java.lang.String getHeader()
          Retrieves the header.
 java.lang.String getJavacFlags()
          Retrieves the JAVACFLAGS.
 java.lang.String getPathSeparator()
          Retrieves the path separator.
 java.lang.String getProjectName()
          Retrieves the project name.
protected  void setBaseFolder(java.lang.String baseFolder)
          Specifies the base folder.
protected  void setBody(java.lang.String body)
          Specifies the body.
protected  void setClasspathEnv(java.lang.String classpathEnv)
          Specifies the CLASSPATH_ENV.
protected  void setClasspathItems(java.util.Collection classpathItems)
          Specifies the classes.
protected  void setFileSeparator(java.lang.String fileSeparator)
          Specifies the file separator.
protected  void setHeader(java.lang.String header)
          Specifies the header.
protected  void setJavacFlags(java.lang.String javacFlags)
          Specifies the JAVACFLAGS.
protected  void setPathSeparator(java.lang.String pathSeparator)
          Specifies the path separator.
protected  void setProjectName(java.lang.String projectName)
          Specifies the project name.
 java.lang.String toString()
          Retrieves the weaved Make-Rules file contents.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

DEFAULT_HEADER

public static final java.lang.String DEFAULT_HEADER
The default header.

See Also:
Constant Field Values

DEFAULT_BODY

public static final java.lang.String DEFAULT_BODY
The default Make-Rules body.

See Also:
Constant Field Values

DEFAULT_JAVAC_FLAGS

public static final java.lang.String DEFAULT_JAVAC_FLAGS
The default javac flags.

See Also:
Constant Field Values

DEFAULT_CLASSPATH_ENV_DECLARATION

public static final java.lang.String DEFAULT_CLASSPATH_ENV_DECLARATION
The default classpath declaration.

See Also:
Constant Field Values

DEFAULT_BASE_FOLDER_VARIABLE

public static final java.lang.String DEFAULT_BASE_FOLDER_VARIABLE
The default base folder variable.

See Also:
Constant Field Values

DEFAULT_PATH_SEPARATOR

public static final java.lang.String DEFAULT_PATH_SEPARATOR
The default path separator.

See Also:
Constant Field Values

DEFAULT_FILE_SEPARATOR

public static final java.lang.String DEFAULT_FILE_SEPARATOR
The default file separator.

See Also:
Constant Field Values
Constructor Detail

MakeRulesTemplate

public MakeRulesTemplate(java.lang.String header,
                         java.lang.String body,
                         java.lang.String javacFlags,
                         java.lang.String classpathEnv,
                         java.lang.String baseFolder,
                         java.lang.String pathSeparator,
                         java.lang.String fileSeparator,
                         java.lang.String projectName)
Builds a MakeRulesTemplate using given information.

Parameters:
header - the header.
body - the body.
javacFlags - the flags to Javac.
classpathEnv - the classpath env template.
baseFolder - the base folder.
pathSeparator - the path separator variable.
fileSeparator - the file separator variable.
projectName - the project name.

MakeRulesTemplate

public MakeRulesTemplate(java.lang.String projectName)
Builds a MakeRulesTemplate using given information.

Parameters:
projectName - the project name.
Method Detail

setHeader

protected void setHeader(java.lang.String header)
Specifies the header.

Parameters:
header - the new header.

getHeader

public java.lang.String getHeader()
Retrieves the header.

Returns:
such information.

setBody

protected void setBody(java.lang.String body)
Specifies the body.

Parameters:
body - the new body.

getBody

public java.lang.String getBody()
Retrieves the body.

Returns:
such information.

setJavacFlags

protected void setJavacFlags(java.lang.String javacFlags)
Specifies the JAVACFLAGS.

Parameters:
javacFlags - the new javac flags.

getJavacFlags

public java.lang.String getJavacFlags()
Retrieves the JAVACFLAGS.

Returns:
such information.

setClasspathEnv

protected void setClasspathEnv(java.lang.String classpathEnv)
Specifies the CLASSPATH_ENV.

Parameters:
classpathEnv - the new classpath env.

getClasspathEnv

public java.lang.String getClasspathEnv()
Retrieves the CLASSPATH_ENV.

Returns:
such information.

setBaseFolder

protected void setBaseFolder(java.lang.String baseFolder)
Specifies the base folder.

Parameters:
baseFolder - the new base folder.

getBaseFolder

public java.lang.String getBaseFolder()
Retrieves the base folder.

Returns:
such information.

setPathSeparator

protected void setPathSeparator(java.lang.String pathSeparator)
Specifies the path separator.

Parameters:
pathSeparator - the new path separator.

getPathSeparator

public java.lang.String getPathSeparator()
Retrieves the path separator.

Returns:
such information.

setFileSeparator

protected void setFileSeparator(java.lang.String fileSeparator)
Specifies the file separator.

Parameters:
fileSeparator - the new file separator.

getFileSeparator

public java.lang.String getFileSeparator()
Retrieves the file separator.

Returns:
such information.

setProjectName

protected void setProjectName(java.lang.String projectName)
Specifies the project name.

Parameters:
projectName - the new project name.

getProjectName

public java.lang.String getProjectName()
Retrieves the project name.

Returns:
such information.

setClasspathItems

protected void setClasspathItems(java.util.Collection classpathItems)
Specifies the classes.


getClasspathItems

protected java.util.Collection getClasspathItems()
Retrieves the classpath items.

Returns:
such collection.

addClasspathItem

public void addClasspathItem(java.lang.String item)
Adds a new classpath item.

Parameters:
item - the new item.

toString

public java.lang.String toString()
Retrieves the weaved Make-Rules file contents.

Overrides:
toString in class java.lang.Object
Returns:
such contents.


Copyright © 2004 ACM S.L.. All Rights Reserved.