Package org.ametys.cms.form
Class BinaryField
- java.lang.Object
-
- org.ametys.cms.form.AbstractField
-
- org.ametys.cms.form.SimpleField<String>
-
- org.ametys.cms.form.BinaryField
-
public class BinaryField extends SimpleField<String>
A field managingBinaryMetadata
.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.ametys.cms.form.AbstractField
AbstractField.MODE
-
-
Field Summary
Fields Modifier and Type Field Description private BinaryMetadata
_binary
-
Constructor Summary
Constructors Constructor Description BinaryField(String[] values)
Creates aBinaryField
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description BinaryMetadata
getBinaryValue()
Get the binary content.boolean
hasBinaryValue()
Test if a source binary metadata is present.void
setBinaryValue(BinaryMetadata meta)
Set the source binary metadata.String
toString()
-
Methods inherited from class org.ametys.cms.form.SimpleField
getValues
-
Methods inherited from class org.ametys.cms.form.AbstractField
getMode, setMode, setMode
-
-
-
-
Field Detail
-
_binary
private BinaryMetadata _binary
-
-
Constructor Detail
-
BinaryField
public BinaryField(String[] values)
Creates aBinaryField
.- Parameters:
values
- the values.
-
-
Method Detail
-
getBinaryValue
public BinaryMetadata getBinaryValue()
Get the binary content.- Returns:
- the binary content.
-
setBinaryValue
public void setBinaryValue(BinaryMetadata meta)
Set the source binary metadata.- Parameters:
meta
- the source binary metadata.
-
hasBinaryValue
public boolean hasBinaryValue()
Test if a source binary metadata is present.- Returns:
- true if a source binary metadata is present.
-
toString
public String toString()
- Overrides:
toString
in classSimpleField<String>
-
-