Class FileValueSerializer
java.lang.Object
org.camunda.bpm.engine.impl.variable.serializer.AbstractTypedValueSerializer<FileValue>
org.camunda.bpm.engine.impl.variable.serializer.FileValueSerializer
- All Implemented Interfaces:
TypedValueSerializer<FileValue>
- Since:
- 7.4
- Author:
- Ronny Bräunlich
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected static final StringThe separator to be able to store encoding and mimetype inside the same text field.protected static final intThe numbers values we encoded in textfield two.Fields inherited from class org.camunda.bpm.engine.impl.variable.serializer.AbstractTypedValueSerializer
BINARY_VALUE_TYPES, valueType -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected booleancanWriteValue(TypedValue value) convertToTypedValue(UntypedValueImpl untypedValue) Returns a typed value for the provided untyped value.getName()The name of this serializer.readValue(ValueFields valueFields, boolean deserializeValue, boolean asTransientValue) Retrieve aTypedValuefrom the providedValueFields.protected StringvoidwriteValue(FileValue value, ValueFields valueFields) Serialize aTypedValueto theValueFields.Methods inherited from class org.camunda.bpm.engine.impl.variable.serializer.AbstractTypedValueSerializer
canHandle, getSerializationDataformat, getType, isMutableValue
-
Field Details
-
NR_OF_VALUES_IN_TEXTFIELD2
protected static final int NR_OF_VALUES_IN_TEXTFIELD2The numbers values we encoded in textfield two.- See Also:
-
MIMETYPE_ENCODING_SEPARATOR
The separator to be able to store encoding and mimetype inside the same text field. Please be aware that the separator only works when it is a character that is not allowed in the first component.- See Also:
-
-
Constructor Details
-
FileValueSerializer
public FileValueSerializer()
-
-
Method Details
-
writeValue
Description copied from interface:TypedValueSerializerSerialize aTypedValueto theValueFields.- Parameters:
value- theTypedValueto persistvalueFields- theValueFieldsto which the value should be persisted
-
convertToTypedValue
Description copied from interface:TypedValueSerializerReturns a typed value for the provided untyped value. This is used on cases where the user sets an untyped value which is then detected to be handled by thisTypedValueSerializer(by invocation ofTypedValueSerializer.canHandle(TypedValue)).- Parameters:
untypedValue- the untyped value- Returns:
- the corresponding typed value
-
readValue
public FileValue readValue(ValueFields valueFields, boolean deserializeValue, boolean asTransientValue) Description copied from interface:TypedValueSerializerRetrieve aTypedValuefrom the providedValueFields.- Parameters:
valueFields- theValueFieldsto retrieve the value fromdeserializeValue- indicates whether aSerializableValueshould be deserialized.- Returns:
- the
TypedValue
-
returnNullIfEmptyString
-
getName
Description copied from interface:TypedValueSerializerThe name of this serializer. The name is used when persisting the ValueFields populated by this serializer.- Returns:
- the name of this serializer.
-
canWriteValue
- Specified by:
canWriteValuein classAbstractTypedValueSerializer<FileValue>
-