org.cantaloop.cgimlet.lang.java
Class JFieldTemplate
java.lang.Object
|
+--org.cantaloop.cgimlet.lang.java.AbstractTemplate
|
+--org.cantaloop.cgimlet.lang.java.JFieldTemplate
- All Implemented Interfaces:
- FieldTemplate, Template
- public class JFieldTemplate
- extends AbstractTemplate
- implements FieldTemplate
- Version:
- 0.2.0 ($Revision: 1.2 $)
- Author:
- David Leuschner, Stefan Heimann
Constructor Summary |
JFieldTemplate(Modifier modifier,
Type type,
java.lang.String name,
java.lang.String initValue)
|
JFieldTemplate(Type type,
java.lang.String name)
Creates a new JFieldTemplate instance.
|
JFieldTemplate(Type type,
java.lang.String name,
java.lang.String initValue)
Creates a new JFieldTemplate instance.
|
Method Summary |
java.lang.String |
getCode()
Returns the code for the field. |
java.lang.String |
getInitValue()
Sets the code the field should be initialized with. |
Type |
getType()
|
void |
setInitValue(java.lang.String init)
Sets the code the field should be initialized with. |
void |
setType(Type t)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
m_type
protected Type m_type
m_initValue
protected java.lang.String m_initValue
m_isStatic
protected boolean m_isStatic
m_isFinal
protected boolean m_isFinal
JFieldTemplate
public JFieldTemplate(Type type,
java.lang.String name)
- Creates a new
JFieldTemplate
instance.
The field is private, non-final and non-static by default.
- Parameters:
type
- the type of the fieldname
- the name of the field
JFieldTemplate
public JFieldTemplate(Type type,
java.lang.String name,
java.lang.String initValue)
- Creates a new
JFieldTemplate
instance.
The field is private, non-final and non-static by default.
- Parameters:
type
- the type of the fieldname
- the name of the fieldinitValue
- the initial value of the field
JFieldTemplate
public JFieldTemplate(Modifier modifier,
Type type,
java.lang.String name,
java.lang.String initValue)
getInitValue
public java.lang.String getInitValue()
- Description copied from interface:
FieldTemplate
- Sets the code the field should be initialized with.
- Specified by:
getInitValue
in interface FieldTemplate
setInitValue
public void setInitValue(java.lang.String init)
- Description copied from interface:
FieldTemplate
- Sets the code the field should be initialized with.
- Specified by:
setInitValue
in interface FieldTemplate
setType
public void setType(Type t)
- Specified by:
setType
in interface FieldTemplate
getType
public Type getType()
- Specified by:
getType
in interface FieldTemplate
getCode
public java.lang.String getCode()
- Description copied from interface:
FieldTemplate
- Returns the code for the field.
- Specified by:
getCode
in interface FieldTemplate