com.esri.arcgis.geodatabase
Interface IDomain

All Superinterfaces:
java.io.Serializable
All Known Implementing Classes:
CodedValueDomain, IDomainProxy, RangeDomain

public interface IDomain
extends java.io.Serializable

Provides access to members that return and modify domains and their merge and split policies.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Description

IDomain interface maintains information about a specific domain in the specified workspace CoClass. It provides functionality for determining whether a value is a member of this domain and properties for setting attributes about this domain. When creating and assigning a Domain to a particular field, the client is required to set the Name and FieldType properties.

When To Use

The IDomain interface is the interface used for creating new and modiying existing attribute domains in a geodatabase. With IDomain , you can create new domains, specify what field type they apply to, create a description, and assign a split and merge policy.

Remarks

An IDomain interface to one of the above objects can be accessed through the following methods:

ISubtypes::Domain
ISubtypesDescription::Domain
IWorkspaceDomains::DomainByName
IAttributeRule::DomainByName
IEnumDomain::Next


Method Summary
 java.lang.String getDescription()
          The description of the domain.
 int getDomainID()
          The ID of the domain.
 int getFieldType()
          The field type of the field.
 int getMergePolicy()
          The merge policy.
 java.lang.String getName()
          The name of the domain.
 java.lang.String getOwner()
          The owner of the domain.
 int getSplitPolicy()
          The split policy.
 int getType()
          The domain type.
 boolean memberOf(java.lang.Object value)
          Indicates whether the value is a valid member of the domain.
 void setDescription(java.lang.String description)
          The description of the domain.
 void setDomainID(int iD)
          The ID of the domain.
 void setFieldType(int fieldType)
          The field type of the field.
 void setMergePolicy(int policy)
          The merge policy.
 void setName(java.lang.String name)
          The name of the domain.
 void setOwner(java.lang.String owner)
          The owner of the domain.
 void setSplitPolicy(int policy)
          The split policy.
 

Method Detail

getDomainID

public int getDomainID()
                throws java.io.IOException,
                       AutomationException
The ID of the domain.

Supported Platforms

Windows, Solaris, Linux

Description

DomainID property returns the ID for the specified domain.

Remarks

This property returns the internal ID of the domain as a Long .

Returns:
The iD
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setDomainID

public void setDomainID(int iD)
                 throws java.io.IOException,
                        AutomationException
The ID of the domain.

Supported Platforms

Windows, Solaris, Linux

Description

DomainID property sets the ID for the current domain.

Parameters:
iD - The iD (in)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getDescription

public java.lang.String getDescription()
                                throws java.io.IOException,
                                       AutomationException
The description of the domain.

Supported Platforms

Windows, Solaris, Linux

Description

Description property returns the description for the specified domain.

Remarks

This property returns the description for the domain object. Descriptions are strings that can be up to 32 characters long.

Returns:
The description
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setDescription

public void setDescription(java.lang.String description)
                    throws java.io.IOException,
                           AutomationException
The description of the domain.

Supported Platforms

Windows, Solaris, Linux

Description

Description property sets the description for the specified domain.

Remarks

This property sets the description for the domain object. The description is a string that can be up to 32 characters long.

Parameters:
description - The description (in)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getFieldType

public int getFieldType()
                 throws java.io.IOException,
                        AutomationException
The field type of the field.

Supported Platforms

Windows, Solaris, Linux

Description

FieldType returns the esriFieldType that the specified domain applies to.

Returns:
A com.esri.arcgis.geodatabase.esriFieldType constant
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setFieldType

public void setFieldType(int fieldType)
                  throws java.io.IOException,
                         AutomationException
The field type of the field.

Supported Platforms

Windows, Solaris, Linux

Description

FieldType sets the esriFieldType that the specified domain applies to.

Remarks

This property sets the type of field that the domain applies to, and therefore what fields for a subtype that you can associate the domain to. The field type is an esriFieldType enumeration. 
 


Parameters:
fieldType - A com.esri.arcgis.geodatabase.esriFieldType constant (in)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getMergePolicy

public int getMergePolicy()
                   throws java.io.IOException,
                          AutomationException
The merge policy.

Supported Platforms

Windows, Solaris, Linux

Description

MergePolicy returns the merge policy for the specified domain.

Remarks

This property sets or returns the merge policy for the domain object. The merge policy describes what happens to the values of the field that the domain is applied to when two objects are merged into a single object. The merge policy is an esriMergePolicyType enumeration.

Returns:
A com.esri.arcgis.geodatabase.esriMergePolicyType constant
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setMergePolicy

public void setMergePolicy(int policy)
                    throws java.io.IOException,
                           AutomationException
The merge policy.

Supported Platforms

Windows, Solaris, Linux

Description

MergePolicy sets the merge policy for the specified domain.

Remarks

This property sets the merge policy for the domain object. The merge policy describes what happens to the values of the field that the domain is applied to when two objects are merged into a single object.
 

 


Parameters:
policy - A com.esri.arcgis.geodatabase.esriMergePolicyType constant (in)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getSplitPolicy

public int getSplitPolicy()
                   throws java.io.IOException,
                          AutomationException
The split policy.

Supported Platforms

Windows, Solaris, Linux

Description

SplitPolicy returns the split policy set for the specified domain.

Remarks

This property returns the split policy for the domain object. The split policy describes what happens to the values of the field that the domain is applied to when an object is split into two objects. The split policy is an esriSplitPolicyType enumeration.

Returns:
A com.esri.arcgis.geodatabase.esriSplitPolicyType constant
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setSplitPolicy

public void setSplitPolicy(int policy)
                    throws java.io.IOException,
                           AutomationException
The split policy.

Supported Platforms

Windows, Solaris, Linux

Description

SplitPolicy sets the split policy set for the specified domain.

Remarks

This property sets the split policy for the domain object. The split policy describes what happens to the values of the field that the domain is applied to when an object is split into two objects. The split policy is an esriSplitPolicyType enumeration. 
  


Parameters:
policy - A com.esri.arcgis.geodatabase.esriSplitPolicyType constant (in)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getName

public java.lang.String getName()
                         throws java.io.IOException,
                                AutomationException
The name of the domain.

Supported Platforms

Windows, Solaris, Linux

Description

Name property returns the name of the specified domain.

Remarks

This property returns the name of the domain object. The domain name is a String the length of which is dependent on the underlying DBMS.
 

Returns:
The name
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setName

public void setName(java.lang.String name)
             throws java.io.IOException,
                    AutomationException
The name of the domain.

Supported Platforms

Windows, Solaris, Linux

Description

Name property sets the name of the specified domain.

Remarks

This property sets the name of the domain object. The domain name is a String the length of which is dependent on the underlying DBMS.
  


Parameters:
name - The name (in)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getOwner

public java.lang.String getOwner()
                          throws java.io.IOException,
                                 AutomationException
The owner of the domain.

Supported Platforms

Windows, Solaris, Linux

Description

Owner returns the owner of the specified domain.

Remarks

This property returns the owner of the domain as a String . The owner is the DBMS user who created the domain. The domain owner is the only user who can succesfully delete a domain from the database.

Returns:
The owner
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setOwner

public void setOwner(java.lang.String owner)
              throws java.io.IOException,
                     AutomationException
The owner of the domain.

Supported Platforms

Windows, Solaris, Linux

Description

Owner property sets the owner for the specified domain.

Parameters:
owner - The owner (in)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getType

public int getType()
            throws java.io.IOException,
                   AutomationException
The domain type.

Supported Platforms

Windows, Solaris, Linux

Description

Type property returns the esriDomainType of the specified domain.

Remarks


Returns:
A com.esri.arcgis.geodatabase.esriDomainType constant
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

memberOf

public boolean memberOf(java.lang.Object value)
                 throws java.io.IOException,
                        AutomationException
Indicates whether the value is a valid member of the domain.

Supported Platforms

Windows, Solaris, Linux

Description

MemberOf function returns a boolean TRUE if the specified value is a member of this domain or FALSE if it is not.

Remarks

The MemberOf method will tell you if some value is a valid member of an attribute domain. Use this function to determine if some value is valid based on a domain. MemberOf returns a Boolean . If the value is not in the domain, it returns False . If the value is in the domain, it returns True .


Parameters:
value - A Variant (in)
Returns:
The isMember
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.