org.axiondb.functions
Class ReplaceFunction

java.lang.Object
  extended byorg.axiondb.BaseSelectable
      extended byorg.axiondb.functions.BaseFunction
          extended byorg.axiondb.functions.ReplaceFunction
All Implemented Interfaces:
ConcreteFunction, Function, FunctionFactory, ScalarFunction, Selectable, Serializable

public class ReplaceFunction
extends BaseFunction
implements ScalarFunction, FunctionFactory

Version:
$Revision: 1.3 $ $Date: 2004/09/09 23:47:44 $
See Also:
Serialized Form

Constructor Summary
ReplaceFunction()
          Creates a new instance of Class
 
Method Summary
 Object evaluate(RowDecorator row)
           
 DataType getDataType()
          StringType
 boolean isValid()
           
 ConcreteFunction makeNewInstance()
           
 String replacedString(String s1, String s2, int i2)
           
 String replacedString(String s1, String s2, String s3, int i2)
           
 
Methods inherited from class org.axiondb.functions.BaseFunction
addArgument, getAlias, getArgument, getArgumentCount, getLabel, getName, setAlias, setArgument, setName, setVariableContext, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.axiondb.Function
addArgument, getAlias, getArgument, getArgumentCount, getName, setAlias, setArgument
 
Methods inherited from interface org.axiondb.Selectable
getLabel, setVariableContext
 

Constructor Detail

ReplaceFunction

public ReplaceFunction()
Creates a new instance of Class

Method Detail

makeNewInstance

public ConcreteFunction makeNewInstance()
Specified by:
makeNewInstance in interface FunctionFactory

getDataType

public DataType getDataType()
StringType

Specified by:
getDataType in interface Selectable
Specified by:
getDataType in class BaseFunction

evaluate

public Object evaluate(RowDecorator row)
                throws AxionException
Specified by:
evaluate in interface ScalarFunction
Throws:
AxionException

replacedString

public String replacedString(String s1,
                             String s2,
                             int i2)

replacedString

public String replacedString(String s1,
                             String s2,
                             String s3,
                             int i2)

isValid

public boolean isValid()
Specified by:
isValid in interface ConcreteFunction
Specified by:
isValid in class BaseFunction