|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.torque.generator.outlet.OutletImpl org.apache.torque.generator.outlet.java.ModifySourcenameOutlet
public class ModifySourcenameOutlet
Creates a target filename from a source filename.
Constructor Summary | |
---|---|
ModifySourcenameOutlet(QualifiedName qualifiedName)
Constructor. |
Method Summary | |
---|---|
OutletResult |
execute(ControllerState controllerState)
Generates the output for this template into the Generated object. |
String |
getDiscardFrom()
Returns the character sequence which separates the discarded beginning of the source filename from the returned end. |
String |
getDiscardTo()
The character sequence from the beginning of the source filename to and including the last occurrence of the returned string is discarded for the result. |
String |
getPrefix()
Returns the prefix which is added in front of the modified source filename. |
String |
getSuffix()
Returns the suffix which is added after the modified source filename. |
void |
setDiscardFrom(String discardFrom)
Sets the character sequence which separates the discarded beginning of the source filename from the returned end. |
void |
setDiscardTo(String discardTo)
Sets the character sequence after which last occurrence the source filename is returned. |
void |
setPrefix(String prefix)
Sets the prefix which is added in front of the modified source filename. |
void |
setSuffix(String suffix)
Sets the suffix which is added after the modified source filename. |
Methods inherited from class org.apache.torque.generator.outlet.OutletImpl |
---|
addMergepointMapping, afterExecute, beforeExecute, getInputElementName, getMergepointMapping, getMergepointMappings, getName, getVariable, mergepoint, setInputElementName, setMergepointMapping, setVariable, setVariable, toString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public ModifySourcenameOutlet(QualifiedName qualifiedName)
qualifiedName
- the qualified name of the outlet, not null.Method Detail |
---|
public OutletResult execute(ControllerState controllerState) throws GeneratorException
Outlet
execute
in interface Outlet
execute
in class OutletImpl
controllerState
- the current controller state, not null.
GeneratorException
- if generation fails.public String getPrefix()
public void setPrefix(String prefix)
prefix
- the prefix, not null.
NullPointerException
- if prefix is null.public String getSuffix()
public void setSuffix(String suffix)
suffix
- the suffix, not null
NullPointerException
- if suffix is null.public String getDiscardFrom()
Example: if the source filename is "xyz.a.b.c", and discardFrom is ".", then "xyz" will be returned.
public void setDiscardFrom(String discardFrom)
Example: if the source filename is "xyz.a.b.c", and discardFrom is ".", then "xyz" will be returned.
discardFrom
- the character sequence from whose first occurrence the
source filename is discarded.public String getDiscardTo()
Example: if the source filename is "xyz.a.b.c", and discardTo is ".", then "c" will be returned.
public void setDiscardTo(String discardTo)
Example: if the source filename is "xyz.a.b.c", and discardTo is ".", then "c" will be returned.
discardTo
- the character sequence up to whose last occurrence the
source filename is discarded.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |