|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.jniwrapper.Parameter com.jniwrapper.win32.automation.types.Variant
The Variant class corresponds to VARIANT
native structure.
Field Summary | |
static int |
LENGTH
|
static int |
UNSUPPORTED_TYPE
|
Fields inherited from class com.jniwrapper.Parameter |
LICENSE_TYPE, V |
Constructor Summary | |
Variant()
Creates the new empty instance with VarType.VT_EMPTY type by default. |
|
Variant(boolean value)
|
|
Variant(double value)
|
|
Variant(float value)
|
|
Variant(int value)
|
|
Variant(long value)
|
|
Variant(java.lang.Object value)
|
|
Variant(SafeArray array)
|
|
Variant(Variant that)
|
|
Variant(VarType type)
|
Method Summary | |
void |
acceptIOPerformer(IOPerformer performer,
DataBuffer buffer,
int initialOffset,
boolean isReadOperation,
boolean invokedByCallback)
|
java.lang.Object |
clone()
|
static Variant |
createUnspecifiedParameter()
Creates value for unspecified parameter in dispinterface interface method call. |
Parameter |
getActiveMember()
|
int |
getAlignmentRequirement()
|
VariantBool |
getBoolVal()
|
BStr |
getBstrVal()
|
UInt8 |
getBVal()
|
Pointer.Void |
getByref()
|
CY |
getCiVal()
|
Int8 |
getCVal()
|
Date |
getDate()
|
DoubleFloat |
getDblVal()
|
java.lang.String |
getDebugInfo()
|
Decimal |
getDecVal()
|
static java.lang.Class |
getElementType(VarType varType)
Returns one of JNIWrapper types (classes) that corresponds to the specified VarType |
int |
getFirstMemberSize()
|
SingleFloat |
getFltVal()
|
HResult |
getHResultVal()
|
Int |
getIntVal()
|
Int16 |
getIVal()
|
int |
getLength()
|
Int64 |
getLlVal()
|
Int32 |
getLVal()
|
Parameter[] |
getMembers()
|
Pointer.Void |
getParray()
Deprecated. use getSafeArray() instead. |
SafeArray |
getParray(VarType vt)
|
SafeArray |
getParray(VarType vt,
java.lang.Class parameterClass)
|
Pointer |
getPboolVal()
|
Pointer |
getPbstrVal()
|
Pointer |
getPbVal()
|
Pointer |
getPcVal()
|
Pointer |
getPcyVal()
|
Pointer |
getPdate()
|
Pointer |
getPdblVal()
|
Pointer |
getPdecVal()
|
IDispatch |
getPdispVal()
|
Pointer |
getPfltVal()
|
Pointer |
getPHResultVal()
|
Pointer |
getPintVal()
|
Pointer |
getPiVal()
|
Pointer |
getPllVal()
|
Pointer |
getPlVal()
|
Pointer |
getPparray()
|
Pointer |
getPparray(VarType vt)
|
Pointer |
getPparray(VarType vt,
java.lang.Class parameterClass)
|
Pointer |
getPpdispVal()
|
Pointer |
getPpunkVal()
|
IRecordInfo |
getPRecInfo()
|
static java.lang.Class |
getPrimitiveElementType(VarType varType)
Returns one of JNIWrapper types (classes) that corresponds to the specified VarType |
Pointer |
getPscode()
|
Pointer |
getPuintVal()
|
Pointer |
getPuiVal()
|
Pointer |
getPullVal()
|
Pointer |
getPulVal()
|
IUnknown |
getPunkVal()
|
Pointer |
getPvarVal()
|
Pointer.Void |
getPvRecord()
|
SafeArray |
getSafeArray()
Returns an instance of the SafeArray , which is stored in this variant. |
SafeArray |
getSafeArray(java.lang.Class parameterClass)
Returns an instance of the SafeArray , which is stored in this variant. |
SCode |
getScode()
|
UInt |
getUintVal()
|
UInt16 |
getUiVal()
|
UInt64 |
getUllVal()
|
UInt32 |
getUlVal()
|
java.lang.Object |
getValue()
Gets a value from the variant as instance of JNIWrapper type. |
static int |
getVariantType(java.lang.Class type)
Returns variant type ID that corresponds to the passed class. |
VarType |
getVt()
|
void |
initBy(Variant that)
|
boolean |
isAutoDelete()
|
void |
pop(DataBuffer stackBuffer,
int offset,
boolean invokedByCallback)
|
void |
push(DataBuffer stackBuffer,
int offset,
boolean invokedByCallback)
|
void |
read(DataBuffer stackBuffer,
int offset,
boolean invokedByCallback)
|
protected void |
readPerformed()
|
void |
release()
Deprecated. This method is not used any more |
void |
setActiveMember(Parameter active)
|
void |
setActiveMember(Parameter active,
boolean read)
|
void |
setAutoDelete(boolean autoDelete)
|
void |
setBStr(BStr bstr)
|
void |
setBStrVal(BStr bstr)
Deprecated. use setValue(java.lang.Object, int) |
void |
setSafeArray(SafeArray safeArray)
Sets the new safe array to this variant. |
void |
setValue(boolean value)
|
void |
setValue(double value)
|
void |
setValue(float value)
|
void |
setValue(int value)
|
void |
setValue(long value)
|
void |
setValue(java.lang.Object value)
Sets a variant value without specifying its type. |
void |
setValue(java.lang.Object val,
int vt)
Sets new value for the variant. |
java.lang.Object |
toObject(java.lang.Class type)
Converts this variant value to a object of specified type. |
void |
write(DataBuffer stackBuffer,
int offset,
boolean invokedByCallback)
|
Methods inherited from class com.jniwrapper.Parameter |
|
Methods inherited from class java.lang.Object |
finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final int UNSUPPORTED_TYPE
public static final int LENGTH
Constructor Detail |
public Variant()
VarType.VT_EMPTY
type by default.
public Variant(Variant that)
public Variant(long value)
public Variant(int value)
public Variant(double value)
public Variant(float value)
public Variant(boolean value)
public Variant(java.lang.Object value)
public Variant(SafeArray array)
public Variant(VarType type)
Method Detail |
public int getAlignmentRequirement()
public Int64 getLlVal()
public Int32 getLVal()
public UInt8 getBVal()
public Int16 getIVal()
public SingleFloat getFltVal()
public DoubleFloat getDblVal()
public VariantBool getBoolVal()
public SCode getScode()
public CY getCiVal()
public HResult getHResultVal()
public Date getDate()
public BStr getBstrVal()
public void setBStrVal(BStr bstr)
setValue(java.lang.Object, int)
public IUnknown getPunkVal()
public IDispatch getPdispVal()
public SafeArray getParray(VarType vt)
public SafeArray getParray(VarType vt, java.lang.Class parameterClass)
public Pointer getPbVal()
public Pointer getPiVal()
public Pointer getPlVal()
public Pointer getPllVal()
public Pointer getPfltVal()
public Pointer getPdblVal()
public Pointer getPboolVal()
public Pointer getPscode()
public Pointer getPcyVal()
public Pointer getPHResultVal()
public Pointer getPdate()
public Pointer getPbstrVal()
public Pointer getPpunkVal()
public Pointer getPpdispVal()
public Pointer getPparray(VarType vt)
public Pointer getPparray(VarType vt, java.lang.Class parameterClass)
public Pointer getPvarVal()
public Pointer.Void getByref()
public Int8 getCVal()
public UInt16 getUiVal()
public UInt32 getUlVal()
public UInt64 getUllVal()
public Int getIntVal()
public UInt getUintVal()
public Pointer getPdecVal()
public Pointer getPcVal()
public Pointer getPuiVal()
public Pointer getPulVal()
public Pointer getPullVal()
public Pointer getPintVal()
public Pointer getPuintVal()
public Pointer.Void getPvRecord()
public IRecordInfo getPRecInfo()
public int getLength()
public void push(DataBuffer stackBuffer, int offset, boolean invokedByCallback) throws MemoryAccessViolationException
MemoryAccessViolationException
public void pop(DataBuffer stackBuffer, int offset, boolean invokedByCallback) throws MemoryAccessViolationException
MemoryAccessViolationException
public void write(DataBuffer stackBuffer, int offset, boolean invokedByCallback) throws MemoryAccessViolationException
MemoryAccessViolationException
public void read(DataBuffer stackBuffer, int offset, boolean invokedByCallback) throws MemoryAccessViolationException
MemoryAccessViolationException
public void acceptIOPerformer(IOPerformer performer, DataBuffer buffer, int initialOffset, boolean isReadOperation, boolean invokedByCallback)
public void setActiveMember(Parameter active)
public void setActiveMember(Parameter active, boolean read)
public Parameter getActiveMember()
public Parameter[] getMembers()
public static Variant createUnspecifiedParameter()
VarType.VT_ERROR
.public void initBy(Variant that)
public java.lang.Object clone()
public VarType getVt()
public Pointer.Void getParray()
getSafeArray()
instead.
public Pointer getPparray()
public Decimal getDecVal()
public void setValue(java.lang.Object val, int vt)
val
- new value.vt
- variant type that the passed object represents.
java.lang.IllegalArgumentException
- if the specified value parameter is not of allowed or specified variant type is not supported.public void setValue(long value)
public void setValue(int value)
public void setValue(double value)
public void setValue(float value)
public void setValue(boolean value)
public void setValue(java.lang.Object value)
value
- value to be assigned to variantpublic java.lang.Object getValue()
public static int getVariantType(java.lang.Class type)
type
- Object class to get variant type for.
VarType
class or UNSUPPORTED_TYPE
if no
corresponding type found.public static java.lang.Class getElementType(VarType varType)
VarType.
- Parameters:
varType
- specifies type for which to find JNIWrapper's type
- Returns:
- one of JNIWrapper types (classes) that corresponds to the specified
VarType
public static java.lang.Class getPrimitiveElementType(VarType varType)
VarType.
Removes VT_ARRAY, VT_VECTOR and VT_BYREF flags if they are present
- Parameters:
varType
- specifies type for which to find JNIWrapper's type
- Returns:
- one of JNIWrapper types (classes) that corresponds to the specified
VarType
public void setSafeArray(SafeArray safeArray)
safeArray
- new safe arraypublic void setBStr(BStr bstr)
public SafeArray getSafeArray()
SafeArray
, which is stored in this variant.
SafeArray
public SafeArray getSafeArray(java.lang.Class parameterClass)
SafeArray
, which is stored in this variant.
parameterClass
- specifies the class of parameters, stored in the variant
SafeArray
protected void readPerformed()
public java.lang.String getDebugInfo()
public void release()
public void setAutoDelete(boolean autoDelete)
setAutoDelete
in interface AutoDeleteParameter
public boolean isAutoDelete()
isAutoDelete
in interface AutoDeleteParameter
public int getFirstMemberSize()
getFirstMemberSize
in interface AlignmentAwareParameter
public java.lang.Object toObject(java.lang.Class type)
type
- expected parameter type
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |