Package com.jackmeng.core.util
Class use_Buffer.buffer_Circular
java.lang.Object
com.jackmeng.core.util.use_Buffer.buffer_Circular
- Enclosing class:
- use_Buffer
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate static intcalc_offset(int len_0, int sz, int buff_len) voiddrop(int elementsCount) intfree(int n) intfree_sz()voidinit()voidnext(int n) intoffset()voidopush(byte[] data, int i, int len) booleanoverflows(int n) intpeek(byte[] data, int i, int len) voidintpop(byte[] bytes, int i, int len) intpush(byte[] data, int i, int len) inttotal_sz()intused_sz()
-
Field Details
-
buffer
private final byte[] buffer -
start
private int start -
sz
private int sz
-
-
Constructor Details
-
buffer_Circular
public buffer_Circular(int init_Size) -
buffer_Circular
public buffer_Circular()
-
-
Method Details
-
used_sz
public int used_sz() -
total_sz
public int total_sz() -
free_sz
public int free_sz() -
drop
public void drop(int elementsCount) -
push
public int push(byte[] data, int i, int len) -
opush
public void opush(byte[] data, int i, int len) -
init
public void init() -
calc_offset
private static int calc_offset(int len_0, int sz, int buff_len) -
offset
public int offset() -
peek
-
peek
public int peek(byte[] data, int i, int len) -
pop
public int pop(byte[] bytes, int i, int len) -
overflows
public boolean overflows(int n) -
next
public void next(int n) -
free
public int free(int n)
-