Package com.semedy.reasoner.edb.ramstore
Class TupleBufferGrounds
java.lang.Object
com.semedy.reasoner.edb.ramstore.TupleBufferGrounds
- All Implemented Interfaces:
TupleBuffer
-
Constructor Summary
ConstructorDescriptionTupleBufferGrounds
(long[] grounds, int arity, long[] basebuffer) TupleBufferGrounds
(long[] grounds, int arity, TupleBuffer buffer) -
Method Summary
Modifier and TypeMethodDescriptionfinal long[]
array()
returns the array of values (no copy)final Object
clone()
void
copyTo
(long[] target) void
copyTo
(long[] target, int atIndex, int length) copy buffer to target array at indexfinal long
get
(int index) get the value at the indexint
length()
get the length of the tuplevoid
length
(int len) set the length of the tuplefinal int
limit()
the right borderfinal int
position()
´the current position of the tuple in the array of valuesfinal void
position
(int pos) set the position inside the array of valuesfinal void
put
(int index, long v) set a value at a certain indexfinal void
put
(long[] v) set a new array of valuesvoid
setBaseBuffer
(TupleBuffer buffer) toString()
-
Constructor Details
-
TupleBufferGrounds
-
TupleBufferGrounds
public TupleBufferGrounds(long[] grounds, int arity, long[] basebuffer)
-
-
Method Details
-
limit
public final int limit()Description copied from interface:TupleBuffer
the right border- Specified by:
limit
in interfaceTupleBuffer
- Returns:
-
setBaseBuffer
-
length
public int length()Description copied from interface:TupleBuffer
get the length of the tuple- Specified by:
length
in interfaceTupleBuffer
- Returns:
-
length
public void length(int len) Description copied from interface:TupleBuffer
set the length of the tuple- Specified by:
length
in interfaceTupleBuffer
-
array
public final long[] array()Description copied from interface:TupleBuffer
returns the array of values (no copy)- Specified by:
array
in interfaceTupleBuffer
- Returns:
-
position
public final int position()Description copied from interface:TupleBuffer
´the current position of the tuple in the array of values- Specified by:
position
in interfaceTupleBuffer
- Returns:
-
put
public final void put(int index, long v) Description copied from interface:TupleBuffer
set a value at a certain index- Specified by:
put
in interfaceTupleBuffer
-
get
public final long get(int index) Description copied from interface:TupleBuffer
get the value at the index- Specified by:
get
in interfaceTupleBuffer
- Returns:
-
put
public final void put(long[] v) Description copied from interface:TupleBuffer
set a new array of values- Specified by:
put
in interfaceTupleBuffer
-
position
public final void position(int pos) Description copied from interface:TupleBuffer
set the position inside the array of values- Specified by:
position
in interfaceTupleBuffer
-
clone
-
toString
-
copyTo
public void copyTo(long[] target, int atIndex, int length) Description copied from interface:TupleBuffer
copy buffer to target array at index- Specified by:
copyTo
in interfaceTupleBuffer
-
copyTo
public void copyTo(long[] target)
-