All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.cuberact.tools.bytes.Bytes Maven / Gradle / Ivy

package org.cuberact.tools.bytes;

import java.io.OutputStream;
import java.nio.charset.Charset;
import java.util.List;
import java.util.function.Function;

public interface Bytes {

    Bytes EMPTY = new ByteData(0);

    byte get(int index);

    int size();

    byte[] toArray();

    byte[] toArray(ByteToken token);

    void writeTo(OutputStream stream);

    boolean endWith(byte[] bytes);

    boolean containsOnly(byte[] bytes);

    boolean containsOnlyLineBreak();

    String toString(Charset charset);

    String toString(ByteToken token, Charset charset);

    List scan(Function tokenDetector);
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy