|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object
|
+--com.jniwrapper.Parameter
|
+--com.jniwrapper.DelegatingParameter
|
+--com.jniwrapper.PlatformInteger
|
+--com.jniwrapper.LongInt
C-like long value.
| Constructor Summary | |
LongInt()
Constructs a new long parameter. |
|
LongInt(IntegerParameter t)
Constructs a new long parameter. |
|
LongInt(long val)
Constructs a new long parameter. |
|
| Method Summary | |
protected void |
acceptIOPerformer(IOPerformer performer,
DataBuffer source,
int initialOffset,
boolean isReadOperation,
boolean invokedByCallback)
Realization of a Visitor pattern for parameter IO. |
java.lang.Object |
clone()
|
boolean |
equals(java.lang.Object obj)
Compares this Parameter object to a given object. |
protected DataBuffer |
getDataBuffer()
Returns current data storage. |
protected int |
getDataBufferOffset()
Returns current offset within data storage. |
int |
getLength()
Returns a length of the parameter in memory. |
long |
getValue()
Returns integer value converted to long |
void |
pop(DataBuffer stackBuffer,
int offset,
boolean invokedByCallback)
Default implementation, which does nothing as most primitive types do nothing on pop. |
void |
push(DataBuffer stackBuffer,
int offset,
boolean invokedByCallback)
Writes a parameter to a function stacks |
void |
read(DataBuffer stackBuffer,
int offset,
boolean invokedByCallback)
Reads this parameter from a specified data source. |
protected void |
setDataBuffer(DataBuffer newSource,
int newOffset)
Sets the data buffer this parameter should use to store data and an offset in bytes within that buffer. |
void |
setValue(long val)
Sets integer value |
java.lang.Long |
toLong()
|
java.lang.String |
toString()
|
void |
write(DataBuffer stackBuffer,
int offset,
boolean invokedByCallback)
Writes this parameter to a specified data source. |
| Methods inherited from class com.jniwrapper.Parameter |
asReturnValue, getAlignedLength, getAlignmentRequirement, indent, read, toByteArray, write |
| Methods inherited from class java.lang.Object |
finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public LongInt()
long parameter.
public LongInt(long val)
long parameter.
val - initial value.public LongInt(IntegerParameter t)
long parameter.
t - parameter to take initial value from.| Method Detail |
public java.lang.Object clone()
clone in class com.jniwrapper.PlatformIntegerpublic long getValue()
IntegerParameterlong
getValue in interface IntegerParameterpublic void setValue(long val)
IntegerParameter
setValue in interface IntegerParameterpublic boolean equals(java.lang.Object obj)
ParameterParameter object to a given object.
Two Parameter objects are considered equal if their
byte representations are equal and they are of the same type.
Subclasses may override this method as appropriate.
equals in class Parameterobj - value to compare this object to
true if two objects are equal.public java.lang.String toString()
toString in class java.lang.Objectpublic java.lang.Long toLong()
protected void acceptIOPerformer(IOPerformer performer,
DataBuffer source,
int initialOffset,
boolean isReadOperation,
boolean invokedByCallback)
Parameterperformer is responsible for I/Oing the
parameter. Users implementing a complex parameter from scratch (i.e. not by extending a pre-existing class
such as Structure or Pointer) may wish to override this method to make a performer
visit object internal parts.
acceptIOPerformer in class Parameterperformer - visitor responsible for I/Oing the parametersource - data buffer for I/O operationinitialOffset - I/O operation offset of this parameter in the buffer
protected void setDataBuffer(DataBuffer newSource,
int newOffset)
Parameter
setDataBuffer in class Parameterprotected DataBuffer getDataBuffer()
Parameter
getDataBuffer in class Parameterprotected int getDataBufferOffset()
Parameter
getDataBufferOffset in class Parameterpublic int getLength()
Parametersizeof() operator.
getLength in class Parameter
public void write(DataBuffer stackBuffer,
int offset,
boolean invokedByCallback)
throws MemoryAccessViolationException
Parameter
write in class ParameterMemoryAccessViolationException
public void read(DataBuffer stackBuffer,
int offset,
boolean invokedByCallback)
throws MemoryAccessViolationException
Parameter
read in class ParameterMemoryAccessViolationException
public void push(DataBuffer stackBuffer,
int offset,
boolean invokedByCallback)
throws MemoryAccessViolationException
Parameter
push in class ParameterMemoryAccessViolationException
public void pop(DataBuffer stackBuffer,
int offset,
boolean invokedByCallback)
throws MemoryAccessViolationException
Parameter
pop in class ParameterMemoryAccessViolationException
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||