Package org.infinispan.util
Class ByteString
java.lang.Object
org.infinispan.util.ByteString
- All Implemented Interfaces:
Comparable<ByteString>
A simple class which encapsulates a byte[] representation of a String using a predefined encoding (currently UTF-8).
This avoids repeated invocation of the expensive
DataOutput.writeUTF(String)
on marshalling- Since:
- 9.0
- Author:
- Tristan Tarrant
-
Method Summary
Modifier and TypeMethodDescriptionint
static ByteString
boolean
static ByteString
fromString
(String s) int
hashCode()
static boolean
static ByteString
readObject
(ObjectInput input) toString()
static void
writeObject
(ObjectOutput output, ByteString object)
-
Method Details
-
fromString
-
isValid
-
emptyString
-
hashCode
public int hashCode() -
equals
-
toString
-
writeObject
- Throws:
IOException
-
readObject
- Throws:
IOException
-
compareTo
- Specified by:
compareTo
in interfaceComparable<ByteString>
-