com.ibm.websphere.ant.tasks
Class NLSEcho
- java.lang.Object
-
- org.apache.tools.ant.ProjectComponent
-
- org.apache.tools.ant.Task
-
- org.apache.tools.ant.taskdefs.Echo
-
- com.ibm.websphere.ant.tasks.NLSEcho
-
- All Implemented Interfaces:
- java.lang.Cloneable
public class NLSEcho extends org.apache.tools.ant.taskdefs.Echo
wsNLSEcho Task: This is a echo extension task to display translated messages. Also provides variable substitution in the message. Attributes: key Key to look for in resource bundle --- Not required bundle Resource bundle from where resource for key to be loaded - Not required message Default message - Required replace substitution arguments seperated by ";;" - Not required Usage:- Version:
- 1.0
- See Also:
Copyright IBM Corp. 2002 Source File: NLSEcho.java Creation Date: August 13, 2002
-
-
Field Summary
Fields Modifier and Type Field and Description protected java.lang.String
bundle
protected java.lang.String
key
protected java.lang.Object[]
tokens
-
Constructor Summary
Constructors Constructor and Description NLSEcho()
-
Method Summary
Methods Modifier and Type Method and Description protected void
doTranslation()
Get translated messagevoid
execute()
Execute the taskprotected java.lang.String
getBundle()
Returns the fileName.protected java.lang.String
getKey()
Returns the key.void
setBundle(java.lang.String bundle)
Set the file name to be used as resource bundlevoid
setKey(java.lang.String key)
key to be translatedvoid
setReplace(java.lang.String str)
Replaces {x} with values specified-
Methods inherited from class org.apache.tools.ant.taskdefs.Echo
addText, setAppend, setEncoding, setFile, setForce, setLevel, setMessage, setOutput
-
Methods inherited from class org.apache.tools.ant.Task
bindToOwner, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, init, isInvalid, log, log, log, log, maybeConfigure, perform, reconfigure, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskType
-
-
-
-
Field Detail
-
bundle
protected java.lang.String bundle
-
key
protected java.lang.String key
-
tokens
protected java.lang.Object[] tokens
-
-
Method Detail
-
setBundle
public void setBundle(java.lang.String bundle)
Set the file name to be used as resource bundle
-
execute
public void execute()
Execute the task- Overrides:
execute
in classorg.apache.tools.ant.taskdefs.Echo
-
setKey
public void setKey(java.lang.String key)
key to be translated
-
doTranslation
protected void doTranslation()
Get translated message
-
getBundle
protected java.lang.String getBundle()
Returns the fileName.- Returns:
- String
-
getKey
protected java.lang.String getKey()
Returns the key.- Returns:
- String
-
setReplace
public void setReplace(java.lang.String str)
Replaces {x} with values specified
-
-