|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcascading.operation.BaseOperation<Tuple>
cascading.operation.text.FieldFormatter
public class FieldFormatter
Class FieldFormatter formats the values in a Tuple with a given format and stuffs the result into a new field.
This function uses theFormatter
class for formatting the argument tuple values into a new string.
Field Summary | |
---|---|
static String |
FIELD_NAME
Field FIELD_NAME |
Fields inherited from class cascading.operation.BaseOperation |
---|
fieldDeclaration, numArgs, trace |
Fields inherited from interface cascading.operation.Operation |
---|
ANY |
Constructor Summary | |
---|---|
FieldFormatter(Fields fieldDeclaration,
String format)
Constructor FieldJoiner creates a new FieldFormatter instance. |
|
FieldFormatter(String format)
Constructor FieldJoiner creates a new FieldFormatter instance using the default field name "formatted". |
Method Summary | |
---|---|
boolean |
equals(Object object)
|
String |
getFormat()
Method getFormat returns the format of this FieldFormatter object. |
int |
hashCode()
|
void |
operate(FlowProcess flowProcess,
FunctionCall<Tuple> functionCall)
Method operate provides the implementation of this Function. |
void |
prepare(FlowProcess flowProcess,
OperationCall<Tuple> operationCall)
Method prepare does nothing, and may safely be overridden. |
Methods inherited from class cascading.operation.BaseOperation |
---|
cleanup, flush, getFieldDeclaration, getNumArgs, getTrace, isSafe, printOperationInternal, toString, toStringInternal |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface cascading.operation.Operation |
---|
cleanup, flush, getFieldDeclaration, getNumArgs, isSafe |
Field Detail |
---|
public static final String FIELD_NAME
Constructor Detail |
---|
@ConstructorProperties(value="format") public FieldFormatter(String format)
format
- of type String@ConstructorProperties(value={"fieldDeclaration","format"}) public FieldFormatter(Fields fieldDeclaration, String format)
fieldDeclaration
- of type Fieldsformat
- of type StringMethod Detail |
---|
public String getFormat()
public void prepare(FlowProcess flowProcess, OperationCall<Tuple> operationCall)
BaseOperation
prepare
in interface Operation<Tuple>
prepare
in class BaseOperation<Tuple>
public void operate(FlowProcess flowProcess, FunctionCall<Tuple> functionCall)
Function
operate
in interface Function<Tuple>
flowProcess
- of type FlowProcessfunctionCall
- of type FunctionCallpublic boolean equals(Object object)
equals
in class BaseOperation<Tuple>
public int hashCode()
hashCode
in class BaseOperation<Tuple>
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |