Class ByteArrayByteSequence
- java.lang.Object
-
- net.officefloor.server.stream.impl.ByteArrayByteSequence
-
- All Implemented Interfaces:
java.io.Serializable
,ByteSequence
public class ByteArrayByteSequence extends java.lang.Object implements ByteSequence, java.io.Serializable
byte
arrayByteSequence
.- Author:
- Daniel Sagenschneider
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from interface net.officefloor.server.stream.impl.ByteSequence
EMPTY
-
-
Constructor Summary
Constructors Constructor Description ByteArrayByteSequence(byte[] bytes)
Instantiate.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description byte
byteAt(int index)
Obtains thebyte
at the index.int
length()
Obtains the number ofbyte
values in theByteSequence
.
-
-
-
Constructor Detail
-
ByteArrayByteSequence
public ByteArrayByteSequence(byte[] bytes)
Instantiate.- Parameters:
bytes
- Bytes backing thisByteSequence
.
-
-
Method Detail
-
byteAt
public byte byteAt(int index)
Description copied from interface:ByteSequence
Obtains thebyte
at the index.- Specified by:
byteAt
in interfaceByteSequence
- Parameters:
index
- Index of thebyte
.- Returns:
byte
at the index.
-
length
public int length()
Description copied from interface:ByteSequence
Obtains the number ofbyte
values in theByteSequence
.- Specified by:
length
in interfaceByteSequence
- Returns:
- Number of
byte
values in theByteSequence
.
-
-