Package org.eolang
Interface Bytes
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.eolang.Data
Data.Once<T>, Data.ToPhi, Data.Value<T>
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description Bytesand(Bytes other)AND operation.<T extends Number>
TasNumber(Class<T> type)Convert to number.Bytesnot()NOT operation.Bytesor(Bytes other)OR operation.Bytesshift(int bits)Big-endian unsigned shift.Bytessshift(int bits)Big-endian signed right shift.Bytesxor(Bytes other)XOR operation.
-
-
-
Method Detail
-
not
Bytes not()
NOT operation.- Returns:
- Bytes.
-
shift
Bytes shift(int bits)
Big-endian unsigned shift. Shifts left if value is positive, or right otherwise. Does not perform sign extension.- Parameters:
bits- Bits to shift, negative to shift left.- Returns:
- Bytes.
-
sshift
Bytes sshift(int bits)
Big-endian signed right shift. Performs sign extension, i.e. it will fill the top bits with 1 if the first bit is 1 and with 0 otherwise.- Parameters:
bits- Bits to shift, negative value causes exception.- Returns:
- Bytes.
-
-