54 |
public ByteBufferImpl (int cap, int off, int lim) |
public ByteBufferImpl (int cap, int off, int lim) |
55 |
{ |
{ |
56 |
this.cap = cap; |
this.cap = cap; |
|
position (off); |
|
57 |
limit (lim); |
limit (lim); |
58 |
|
position (off); |
59 |
this.backing_buffer = new byte[cap]; |
this.backing_buffer = new byte[cap]; |
60 |
} |
} |
61 |
|
|
62 |
public ByteBufferImpl (byte[] array, int off, int lim) |
public ByteBufferImpl (byte[] array, int off, int lim) |
63 |
{ |
{ |
64 |
this.cap = array.length; |
this.cap = array.length; |
|
position (off); |
|
65 |
limit (lim); |
limit (lim); |
66 |
|
position (off); |
67 |
this.backing_buffer = array; |
this.backing_buffer = array; |
68 |
} |
} |
69 |
|
|
70 |
public ByteBufferImpl (ByteBufferImpl copy) |
public ByteBufferImpl (ByteBufferImpl copy) |
71 |
{ |
{ |
72 |
this.cap = copy.capacity (); |
this.cap = copy.capacity (); |
|
position (copy.position ()); |
|
73 |
limit (copy.limit ()); |
limit (copy.limit ()); |
74 |
|
position (copy.position ()); |
75 |
ro = copy.ro; |
ro = copy.ro; |
76 |
backing_buffer = copy.backing_buffer; |
backing_buffer = copy.backing_buffer; |
77 |
} |
} |