Guid.CLSID, Guid.CLSID.ByReference, Guid.GUID.ByReference, Guid.GUID.ByValue, Guid.IIDpublic static class Guid.GUID extends Structure
| Modifier and Type | Class | Description |
|---|---|---|
static class |
Guid.GUID.ByReference |
The Class ByReference.
|
static class |
Guid.GUID.ByValue |
Structure.StructField| Modifier and Type | Field | Description |
|---|---|---|
int |
Data1 |
The Data1.
|
short |
Data2 |
The Data2.
|
short |
Data3 |
The Data3.
|
byte[] |
Data4 |
The Data4.
|
static List<String> |
FIELDS |
ALIGN_DEFAULT, ALIGN_GNUC, ALIGN_MSVC, ALIGN_NONE, CALCULATE_SIZE| Constructor | Description |
|---|---|
GUID() |
Instantiates a new guid.
|
GUID(byte[] data) |
Instantiates a new guid.
|
GUID(Guid.GUID guid) |
Instantiates a new guid.
|
GUID(Pointer memory) |
Instantiates a new guid.
|
GUID(String guid) |
Instantiates a new guid.
|
| Modifier and Type | Method | Description |
|---|---|---|
boolean |
equals(Object o) |
|
static Guid.GUID |
fromBinary(byte[] data) |
From binary.
|
static Guid.GUID |
fromString(String guid) |
From string.
|
protected List<String> |
getFieldOrder() |
Return this Structure's field names in their proper order.
|
int |
hashCode() |
|
static Guid.GUID |
newGuid() |
Generates a new guid.
|
byte[] |
toByteArray() |
To byte array.
|
String |
toGuidString() |
The value of this Guid, formatted as follows:
xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx.
|
protected void |
writeFieldsToMemory() |
Write fields to backing memory.
|
clone, finalize, getClass, notify, notifyAll, wait, wait, waitallocateMemory, allocateMemory, autoAllocate, autoRead, autoRead, autoWrite, autoWrite, cacheTypeInfo, calculateSize, clear, createFieldsOrder, createFieldsOrder, createFieldsOrder, createFieldsOrder, dataEquals, dataEquals, ensureAllocated, fieldOffset, getAutoRead, getAutoWrite, getFieldList, getFields, getNativeAlignment, getNativeSize, getNativeSize, getPointer, getStringEncoding, getStructAlignment, newInstance, newInstance, read, readField, readField, setAlignType, setAutoRead, setAutoSynch, setAutoWrite, setFieldOrder, setStringEncoding, size, sortFields, toArray, toArray, toString, toString, useMemory, useMemory, write, writeField, writeField, writeFieldpublic int Data1
public short Data2
public short Data3
public byte[] Data4
public GUID()
public GUID(Guid.GUID guid)
guid - the guidpublic GUID(String guid)
guid - the guidpublic GUID(byte[] data)
data - the datapublic GUID(Pointer memory)
memory - the memorypublic boolean equals(Object o)
public int hashCode()
public static Guid.GUID fromBinary(byte[] data)
data - the datapublic static Guid.GUID fromString(String guid)
guid - the guidpublic static Guid.GUID newGuid()
public byte[] toByteArray()
public String toGuidString()
protected void writeFieldsToMemory()
protected List<String> getFieldOrder()
Structure
protected List getFieldOrder() {
return Arrays.asList(new String[] { ... });
}
IMPORTANT
When deriving from an existing Structure subclass, ensure that
you augment the list provided by the superclass, e.g.
protected List getFieldOrder() {
List fields = new ArrayList(super.getFieldOrder());
fields.addAll(Arrays.asList(new String[] { ... }));
return fields;
}
Field order must be explicitly indicated, since the
field order as returned by Class.getFields() is not
guaranteed to be predictable.getFieldOrder in class Structure