com.esri.arcgis.geodatabase
Interface IReplica

All Superinterfaces:
Serializable
All Known Subinterfaces:
IReplica2, IReplica3
All Known Implementing Classes:
IReplica2Proxy, IReplica3Proxy, IReplicaProxy, Replica

public interface IReplica
extends Serializable

Provides access to members that get information about a replica.

Superseded By

IReplica2

Remarks

The properties of the IReplica interface returns information about a check-out. The properties of the IReplica interface return information about a check-out. The Description property only applies to the master geodatatbase, while the ParentID and ConnectionInfo properties apply only to the check-out database. The other properties apply to both the master and check-out geodatabases.

See the IWorkspaceReplicas interface to find how to get a replica.

Product Availability

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

See Also:
ICheckOut, IReplicaValidation, ICheckIn.checkInFromGDB(com.esri.arcgis.geodatabase.IWorkspaceName, String, com.esri.arcgis.geodatabase.IWorkspaceName, boolean, boolean), ICheckOut.checkOutData(com.esri.arcgis.geodatabase.IReplicaDescription, boolean, String), ICheckIn, CheckOut, CheckIn

Method Summary
 IWorkspaceName getConnectionInfo()
          The WorkspaceName object for the master geodatabase.
 IReplicaDescription getDescription()
          The ReplicaDescription associated with the replica.
 String getName()
          The name of the replica.
 String getOwner()
          The database user that owns the replica in the workspace.
 int getParentID()
          The ID of the replica reference in the master geodatabase.
 IEnumReplicaDataset getReplicaDatasets()
          The replica datasets for this replica.
 double getReplicaDate()
          The date that the data was checked out.
 String getReplicaGuid()
          The guid of the replica.
 int getReplicaID()
          The ID of the replica.
 int getReplicaRole()
          Determines if the workspace is the replica geodatabase or the master geodatabase for the replica.
 String getVersion()
          The name of the replica version.
 

Method Detail

getReplicaID

int getReplicaID()
                 throws IOException,
                        AutomationException
The ID of the replica.

Description

This ReplicaID identifies a check-out in a geodatabase. It is unique only within the geodatabase and not across the master and the check-out geodatabases. For example, the master can have a ReplicaID of 1806 while the check-out geodatabase has a ReplicaID of 1 for the same check-out.

The ParentID property can be used in the check-out geodatabase to find the corresponding ReplicaID in the master geodatabase.

The master geodatabase of a check-out returns -1 for ParentID property. An alternative is to use the ReplicaGuid property, which uniquely identifies the check-out and has the same value in the master and check-out geodatabases.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getName

String getName()
               throws IOException,
                      AutomationException
The name of the replica.

Remarks

The Name is taken from the string set in the checkoutname parameter of ICheckout::CheckoutData and ICheckout::CheckoutSchema methods.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getOwner

String getOwner()
                throws IOException,
                       AutomationException
The database user that owns the replica in the workspace.

Remarks

For two way or one way replicas this property returns the owner of the data in the replica database.

For check-out replicas, if the check-out database is a personal or File geodatabase this property returns a blank string. Otherwise it returns the owner of the checked out data in the check-out geodatabase.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getVersion

String getVersion()
                  throws IOException,
                         AutomationException
The name of the replica version.

Remarks

For check-out replicas, the name of the version is the same as the name of the checkout; see IReplica::Name. If the check-out database is a personal geodatabase or a File geodatabase, this property is set to the version name on the master geodatabase (parent database).

For two way or one way replicas, this property is set to the version on the replica geodatabase. The child replica will always return the Default version. The parent replica will return the version the replica was created from.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getParentID

int getParentID()
                throws IOException,
                       AutomationException
The ID of the replica reference in the master geodatabase.

Remarks

Returns the ID of the parent replica. For two way, one way and check-out replicas, this property is only valid for the child replica geodatabase. The parent replica geodatabase returns -1 for this property.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getReplicaDate

double getReplicaDate()
                      throws IOException,
                             AutomationException
The date that the data was checked out.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getReplicaGuid

String getReplicaGuid()
                      throws IOException,
                             AutomationException
The guid of the replica.

Remarks

The ReplicaGuid property uniquely identifies the replica and has the same value in the parent and child replica geodatabases. Unlike the ReplicaID property, it is unique across geodatabases.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getDescription

IReplicaDescription getDescription()
                                   throws IOException,
                                          AutomationException
The ReplicaDescription associated with the replica.

Remarks

For check-out replicas this property is only set in the master geodatabase. Nothing is returned for a check-out in a check-out geodatabase.

This property is set on both the parent and child replica geodatabases for two way and one way replicas.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Returns:
A reference to a com.esri.arcgis.geodatabase.IReplicaDescription
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getConnectionInfo

IWorkspaceName getConnectionInfo()
                                 throws IOException,
                                        AutomationException
The WorkspaceName object for the master geodatabase.

Remarks

For a check-out geodatabase, this property returns a WorkspaceName object for the master geodatabase. This allows you to perform a checkin from the check-out geodatabase without already knowing the connection information for the master. The user name and password are not returned and must be set before connecting.

For master geodatabase, this property returns nothing.


Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Returns:
A reference to a com.esri.arcgis.geodatabase.IWorkspaceName
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getReplicaRole

int getReplicaRole()
                   throws IOException,
                          AutomationException
Determines if the workspace is the replica geodatabase or the master geodatabase for the replica.

Remarks

If a geodatabase acts as the master for the Replica, this property returns esriCheckoutTypeParent. If the geodatabase is the check-out geodatabase, esriCheckoutTypeChild is returned. The other enumerations are never returned for valid check-outs.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getReplicaDatasets

IEnumReplicaDataset getReplicaDatasets()
                                       throws IOException,
                                              AutomationException
The replica datasets for this replica.

Remarks

The ReplicaDataset that is returned can be used to get information about the checked-out datasets.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Returns:
A reference to a com.esri.arcgis.geodatabase.IEnumReplicaDataset
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.