Package org.odftoolkit.odfdom.type
Class Base64Binary
- java.lang.Object
-
- org.odftoolkit.odfdom.type.Base64Binary
-
- All Implemented Interfaces:
OdfDataType
public class Base64Binary extends Object implements OdfDataType
This class represents the in OpenDocument format used data type base64Binary
-
-
Constructor Summary
Constructors Constructor Description Base64Binary(byte[] bytes)
Construct an newly Base64Binary object that represents the specified byte[] value
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description byte[]
getBytes()
get byte[] from Base64Binarystatic boolean
isValid(String stringValue)
check if the specified String is a valid base64Binary data typeString
toString()
Returns a String Object representing this Base64Binary's valuestatic Base64Binary
valueOf(String stringValue)
Returns a Base64Binary instance representing the specified String value
-
-
-
Constructor Detail
-
Base64Binary
public Base64Binary(byte[] bytes) throws NumberFormatException
Construct an newly Base64Binary object that represents the specified byte[] value- Parameters:
bytes
- the value to be represented by the Base64Binary Object- Throws:
NumberFormatException
- If the parameter is not a valid Base64Binary.
-
-
Method Detail
-
toString
public String toString()
Returns a String Object representing this Base64Binary's value
-
valueOf
public static Base64Binary valueOf(String stringValue) throws NumberFormatException
Returns a Base64Binary instance representing the specified String value- Parameters:
stringValue
- a String value- Returns:
- return a Base64Binary instance representing stringValue
- Throws:
NumberFormatException
- If the parameter is not a valid Base64Binary.
-
getBytes
public byte[] getBytes()
get byte[] from Base64Binary- Returns:
- byte[] returned from this Base64Binary instance
-
isValid
public static boolean isValid(String stringValue)
check if the specified String is a valid base64Binary data type- Parameters:
stringValue
- the value to be tested- Returns:
- true if the value of argument is valid for base64Binary data type false otherwise
-
-