|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.esri.arcgis.system.UID
public class UID
Unique Identifier Object.
COM interfaces and coclasses are identified by a globally unique identifier (GUID). The GUID for an interface is called an interface ID (IID). The GUID for a coclass is called class ID (CLSID). A ProgID is a text alias for a CLSID; the ProgID is a string composed of the project name and the class name of the coclass.
The UID coclass can be used to represent the GUID of an object.
There is built-in module called ArcID in the VBA project for the Normal template in both ArcMap and ArcCatalog. This module is a utility for finding the UID of the built-in commands and toolbars. You pass the name of a command or toolbar in as an argument to ArcID and the UID of that item is returned. The ArcID module is regenerated every time the Normal template is loaded; the registry is read to get the GUIDs of all the commands and toolbars that are currently used by the application.
Java developers can use the UID::setValue(Class class) method to initialize the UID object with the CLSID of an arcobjects coClass, or the IID of an arcobjects interface.
For example -
UID id = new UID();
id.setValue(com.esri.arcgis.geodatabase.IDataset.class);
,
Serialized Form| Constructor Summary | |
|---|---|
UID()
Constructs a UID using ArcGIS Engine. |
|
UID(Object obj)
Deprecated. As of ArcGIS 9.2, replaced by normal Java casts. UID theUID = (UID) obj; |
|
| Method Summary | |
|---|---|
boolean |
compare(IUID otherID)
Indicates if the two UID objects represent the same globally unique identifier. |
void |
deserialize(IXMLSerializeData data)
Deserializes an object from XML. |
boolean |
equals(Object o)
Compare this object with another |
void |
generate()
Creates a new globally unique value for the UID object. |
void |
getClassID(GUID[] pClassID)
getClassID |
static String |
getClsid()
getClsid. |
void |
getSizeMax(_ULARGE_INTEGER[] pcbSize)
getSizeMax |
int |
getSubType()
The subtype of the UID object. |
Object |
getValue()
The value of the UID object. |
int |
hashCode()
the hashcode for this object |
void |
isDirty()
isDirty |
void |
load(IStream pstm)
load |
void |
readExternal(ObjectInput in)
|
void |
save(IStream pstm,
int fClearDirty)
save |
void |
serialize(IXMLSerializeData data)
Serializes an object to XML. |
void |
setSubType(int subType)
The subtype of the UID object. |
void |
setValue(Class clazz)
Sets the value of the UID object to the CLSID or IID of the passed in ArcObjects Class or Interface. |
void |
setValue(Object guidAsString)
The value of the UID object. |
void |
writeExternal(ObjectOutput out)
|
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface com.esri.arcgis.interop.RemoteObjRef |
|---|
getJintegraDispatch, release |
| Constructor Detail |
|---|
public UID()
throws IOException,
UnknownHostException
IOException - if there are interop problems
UnknownHostException - if there are interop problems
public UID(Object obj)
throws IOException
UID theUID = (UID) obj;
obj to UID.
obj - an object returned from ArcGIS Engine or Server
IOException - if there are interop problems| Method Detail |
|---|
public static String getClsid()
public boolean equals(Object o)
equals in class Objectpublic int hashCode()
hashCode in class Object
public Object getValue()
throws IOException,
AutomationException
The Value property is a string representing either the CLSID or ProgID of an interface or coclass.
COM interfaces and coclasses are identified by a globally unique identifier (GUID). The GUID for an interface is called an interface ID (IID). The GUID for a coclass is called class ID (CLSID). A ProgID is a text alias for a CLSID; the ProgID is a string composed of the project name and the class name of the coclass.
ArcGIS for Desktop developers can find the CLSID, ProgID, and subtype of a built-in command, menu, or toolbar in ArcMap or ArcCatalog, in the following technical documents:
ArcGIS Developer Help for Desktop developers > General reference > Names and IDs > ArcMap commands
ArcGIS Developer Help for Desktop developers > Technical General reference > Names and IDs > ArcCatalog commands
getValue in interface IUIDIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setValue(Object guidAsString)
throws IOException,
AutomationException
setValue in interface IUIDguidAsString - A Variant (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void generate()
throws IOException,
AutomationException
Creates a new globally unique value (GUID) for the UID object. This is a 128-bit integer used for CLSIDs and interface identifiers.
generate in interface IUIDIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public int getSubType()
throws IOException,
AutomationException
Use the SubType property when working with classes that implement ICommandSubType that have multiple commands within a single class.
getSubType in interface IUIDIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setSubType(int subType)
throws IOException,
AutomationException
setSubType in interface IUIDsubType - The subType (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public boolean compare(IUID otherID)
throws IOException,
AutomationException
Returns a boolean indicating whether the specified UID object represents the same globally unique value (GUID) as this UID object.
compare in interface IUIDotherID - A reference to a com.esri.arcgis.system.IUID (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void getClassID(GUID[] pClassID)
throws IOException,
AutomationException
IPersist is a Microsoft interface. Please refer to MSDN for information about this interface.
getClassID in interface IPersistpClassID - A Structure: com.esri.arcgis.support.ms.stdole.GUID (out: use single element array)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void isDirty()
throws IOException,
AutomationException
IPersistStream is a Microsoft interface. Please refer to MSDN for information about this interface.
isDirty in interface IPersistStreamIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void load(IStream pstm)
throws IOException,
AutomationException
IPersistStream is a Microsoft interface. Please refer to MSDN for information about this interface.
load in interface IPersistStreampstm - A reference to a com.esri.arcgis.system.IStream (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void save(IStream pstm,
int fClearDirty)
throws IOException,
AutomationException
IPersistStream is a Microsoft interface. Please refer to MSDN for information about this interface.
save in interface IPersistStreampstm - A reference to a com.esri.arcgis.system.IStream (in)fClearDirty - The fClearDirty (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void getSizeMax(_ULARGE_INTEGER[] pcbSize)
throws IOException,
AutomationException
IPersistStream is a Microsoft interface. Please refer to MSDN for information about this interface.
getSizeMax in interface IPersistStreampcbSize - A Structure: com.esri.arcgis.system._ULARGE_INTEGER (out: use single element array)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void serialize(IXMLSerializeData data)
throws IOException,
AutomationException
serialize in interface IXMLSerializedata - A reference to a com.esri.arcgis.system.IXMLSerializeData (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void deserialize(IXMLSerializeData data)
throws IOException,
AutomationException
deserialize in interface IXMLSerializedata - A reference to a com.esri.arcgis.system.IXMLSerializeData (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void writeExternal(ObjectOutput out)
throws IOException
writeExternal in interface ExternalizableIOException
public void readExternal(ObjectInput in)
throws IOException,
ClassNotFoundException
readExternal in interface ExternalizableIOException
ClassNotFoundException
public void setValue(Class clazz)
throws IOException,
AutomationException
clazz - The Class object of an ArcGIS class or interface
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
RuntimeException If the passed in Class does not represent an ArcObjects Class or Interface.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||