com.esri.arcgis.geodatabasedistributed
Class CheckIn

java.lang.Object
  extended by com.esri.arcgis.geodatabasedistributed.CheckIn
All Implemented Interfaces:
ICheckIn, ICheckIn2, com.esri.arcgis.interop.RemoteObjRef, Serializable

public class CheckIn
extends Object
implements com.esri.arcgis.interop.RemoteObjRef, ICheckIn, ICheckIn2

Checks in changes from a check-out geodatabase or a delta database to a master geodatabase.

Remarks

The Checkin coclass provides methods for checking changes back into the master geodatabase. The changes can exist in a check-out geodatabase or a delta file.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

See Also:
DataChangesImporter, DeltaDataChanges, Serialized Form

Constructor Summary
CheckIn()
          Constructs a CheckIn using ArcGIS Engine.
CheckIn(Object obj)
          Deprecated. As of ArcGIS 9.2, replaced by normal Java casts.
CheckIn theCheckIn = (CheckIn) obj;
 
Method Summary
 void addIFeatureProgressListener(IFeatureProgress theListener)
          addIFeatureProgressListener.
 void addIReplicaProgressListener(IReplicaProgress theListener)
          addIReplicaProgressListener.
 boolean checkInFromDeltaFile(IWorkspaceName parentDB, String checkoutName, String fileName, int dcOption, boolean reconcileCheckout, boolean createOIDMappingTable)
          Checks in changes from a delta database.
 boolean checkInFromDeltaFile2(IWorkspaceName parentDB, String checkoutName, String fileName, int dcOption, boolean reconcileCheckout, int childReconcilePolicy, boolean columnLevel, boolean createOIDMappingTable)
          Checks in changes from a delta database.
 boolean checkInFromGDB(IWorkspaceName parentDB, String checkoutName, IWorkspaceName checkOutDB, boolean reconcileCheckout, boolean createOIDMappingTable)
          Checks in changes from a check-out database.
 boolean checkInFromGDB2(IWorkspaceName parentDB, String checkoutName, IWorkspaceName checkOutDB, boolean reconcileCheckout, int childReconcilePolicy, boolean columnLevel, boolean createOIDMappingTable)
          Checks in changes from a check-out database.
 boolean equals(Object o)
          Compare this object with another
static String getClsid()
          getClsid.
 int hashCode()
          the hashcode for this object
 void removeIFeatureProgressListener(IFeatureProgress theListener)
          removeIFeatureProgressListener.
 void removeIReplicaProgressListener(IReplicaProgress theListener)
          removeIReplicaProgressListener.
 
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

CheckIn

public CheckIn()
        throws IOException,
               UnknownHostException
Constructs a CheckIn using ArcGIS Engine.

Throws:
IOException - if there are interop problems
UnknownHostException - if there are interop problems

CheckIn

public CheckIn(Object obj)
        throws IOException
Deprecated. As of ArcGIS 9.2, replaced by normal Java casts.
CheckIn theCheckIn = (CheckIn) obj;

Construct a CheckIn using a reference to such an object returned from ArcGIS Engine or Server. This is semantically equivalent to casting obj to CheckIn.

Parameters:
obj - an object returned from ArcGIS Engine or Server
Throws:
IOException - if there are interop problems
Method Detail

getClsid

public static String getClsid()
getClsid.


equals

public boolean equals(Object o)
Compare this object with another

Overrides:
equals in class Object

hashCode

public int hashCode()
the hashcode for this object

Overrides:
hashCode in class Object

addIFeatureProgressListener

public void addIFeatureProgressListener(IFeatureProgress theListener)
                                 throws IOException
addIFeatureProgressListener. Listen to events generated by this class.

Parameters:
theListener - An object that implements the com.esri.arcgis.geodatabase.IFeatureProgress interface.
Throws:
IOException - If there are communications problems.

removeIFeatureProgressListener

public void removeIFeatureProgressListener(IFeatureProgress theListener)
                                    throws IOException
removeIFeatureProgressListener. Stop listening to events generated by this class.

Parameters:
theListener - An object that implements the com.esri.arcgis.geodatabase.IFeatureProgress interface.
Throws:
IOException - If there are communications problems.

addIReplicaProgressListener

public void addIReplicaProgressListener(IReplicaProgress theListener)
                                 throws IOException
addIReplicaProgressListener. Listen to events generated by this class.

Parameters:
theListener - An object that implements the com.esri.arcgis.geodatabasedistributed.IReplicaProgress interface.
Throws:
IOException - If there are communications problems.

removeIReplicaProgressListener

public void removeIReplicaProgressListener(IReplicaProgress theListener)
                                    throws IOException
removeIReplicaProgressListener. Stop listening to events generated by this class.

Parameters:
theListener - An object that implements the com.esri.arcgis.geodatabasedistributed.IReplicaProgress interface.
Throws:
IOException - If there are communications problems.

checkInFromGDB

public boolean checkInFromGDB(IWorkspaceName parentDB,
                              String checkoutName,
                              IWorkspaceName checkOutDB,
                              boolean reconcileCheckout,
                              boolean createOIDMappingTable)
                       throws IOException,
                              AutomationException
Checks in changes from a check-out database.

Remarks

The CheckinfromGDB method applies the changes made in the checkOutDB (check-out geodatabase) to the parentDB (master geodatabase or parent replica) workspace.

The checkoutName is needed to identify the check-out that is being checked in.

If createOIDMappingTable is True, tables are created in the parent replica geodatabase that describe the changes that are checked in. These tables are named <check-out name>_OM and <check-out name>_RC. If tables with these names already exist, they are deleted and replaced with a new pair of tables for the check in. If the check in process fails, these tables are not recovered.

The <check-out name>_OM table records the pre- and post- check-in ObjectID values for new features/rows that have been added. The <check-out name>_RC table records all the changes made to the checked out data which include inserts (0), updates (1) and deletes (2).

Conflicts

If reconcileCheckout is TRUE, the changes are applied to the check-out version and this version is reconciled with its parent version. If reconcileCheckout is FALSE, the changes are applied to the check-out version, but no reconcile is performed.
If reconcileCheckout is TRUE and there are no conflicts during reconcile, a FALSE is returned, otherwise TRUE is returned. Conflicts can occur if a feature is edited in the check-out database and in the parent version of the parent database.

You should never edit the check-out version prior to check in. During check in, any coincidental changes are over-written with changes from the check-out database without notification of a conflict.

If you set reconcileCheckout to TRUE and there are conflicts or if reconcileCheckout is set to FALSE, the check-out version is updated and remains on the parent database. This allows you to manually reconcile at a later time. If you set reconcileCheckout to TRUE and there are no conflicts, the check-out version is removed.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
checkInFromGDB in interface ICheckIn
Parameters:
parentDB - A reference to a com.esri.arcgis.geodatabase.IWorkspaceName (in)
checkoutName - The checkoutName (in)
checkOutDB - A reference to a com.esri.arcgis.geodatabase.IWorkspaceName (in)
reconcileCheckout - The reconcileCheckout (in)
createOIDMappingTable - The createOIDMappingTable (in)
Returns:
The conflicts_detected
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
ICheckIn.checkInFromGDB(com.esri.arcgis.geodatabase.IWorkspaceName, String, com.esri.arcgis.geodatabase.IWorkspaceName, boolean, boolean), ICheckIn, CheckIn

checkInFromDeltaFile

public boolean checkInFromDeltaFile(IWorkspaceName parentDB,
                                    String checkoutName,
                                    String fileName,
                                    int dcOption,
                                    boolean reconcileCheckout,
                                    boolean createOIDMappingTable)
                             throws IOException,
                                    AutomationException
Checks in changes from a delta database.

Remarks

The CheckinfromDeltaFile method applies the changes from a delta database (dcOption = esriExporttoAccess) or a delta XML file (dcOption = esriExporttoXML). See the DataChangesExporter for more information on delta files.

The checkoutName is needed to identify the check-out that is being checked in.

If createOIDMappingTable is True, tables are created in the parent replica geodatabase that describe the changes that are checked in. These tables are named <check-out name>_OM and <check-out name>_RC. If tables with these names already exist, they are over-written.

The <check-out name>_OM table records the pre- and post- check-in ObjectID values for new features/rows that have been added. The <check-out name>_RC table records all the changes made to the checked out data which include inserts (0), updates (1) and deletes (2).

Conflicts

If reconcileCheckout is TRUE, the changes are applied to the check-out version and this version is reconciled with its parent version. If reconcileCheckout is FALSE, the changes are applied to the check-out version, but no reconcile is performed.

If reconcileCheckout is TRUE and there are no conflicts during reconcile, a FALSE is returned, otherwise TRUE is returned. Conflicts can occur if a feature is edited in the check-out database and in the parent version of the parent database.

You should never edit the check-out version prior to check in. During check in, any coincidental changes are over-written with changes from the check-out database without notification of a conflict.

If you set reconcileCheckout to TRUE and there are conflicts or if reconcileCheckout is set to FALSE, the check-out version is updated and remains on the parent geodatabase. This allows you to manually reconcile at a later time. If you set reconcileCheckout to TRUE and there are no conflicts, the check-out version is removed.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
checkInFromDeltaFile in interface ICheckIn
Parameters:
parentDB - A reference to a com.esri.arcgis.geodatabase.IWorkspaceName (in)
checkoutName - The checkoutName (in)
fileName - The fileName (in)
dcOption - A com.esri.arcgis.geodatabasedistributed.esriExportDataChangesOption constant (in)
reconcileCheckout - The reconcileCheckout (in)
createOIDMappingTable - The createOIDMappingTable (in)
Returns:
The conflicts_detected
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

checkInFromGDB2

public boolean checkInFromGDB2(IWorkspaceName parentDB,
                               String checkoutName,
                               IWorkspaceName checkOutDB,
                               boolean reconcileCheckout,
                               int childReconcilePolicy,
                               boolean columnLevel,
                               boolean createOIDMappingTable)
                        throws IOException,
                               AutomationException
Checks in changes from a check-out database.

Remarks

The CheckinfromGDB2 method applies the changes made in the checkOutDB (check-out geodatabase) to the parentDB (master geodatabase or parent replica) workspace. Unlike the CheckinfromGDB method available off the ICheckin interface, CheckinfromGDB2 enables you to specify how conflicts are defined, detected and applied during check in.

The checkoutName is needed to identify the check-out that is being checked in.

If createOIDMappingTable is True, tables are created in the parent replica geodatabase that describe the changes that are checked in. These tables are named <check-out name>_OM and <check-out name>_RC. If tables with these names already exist, they are deleted and replaced with a new pair of tables for the check in. If the check in process fails, these tables are not recovered.

The <check-out name>_OM table records the pre- and post- check-in ObjectID values for new features/rows that have been added. The <check-out name>_RC table records all the changes made to the checked out data which include inserts (0), updates (1) and deletes (2).

Conflicts

If reconcileCheckout is TRUE, the changes are applied to the check-out version and this version is reconciled with its parent version. If reconcileCheckout is FALSE, the changes are applied to the check-out version, but no reconcile is performed.
If reconcileCheckout is TRUE and there are no conflicts during reconcile, a FALSE is returned, otherwise TRUE is returned. Conflicts can occur if a feature is edited in the check-out database and in the parent version of the parent database.

You should never edit the check-out version prior to check in. During check in, any coincidental changes are over-written with changes from the check-out database without notification of a conflict.

If you set reconcileCheckout to TRUE and there are conflicts or if reconcileCheckout is set to FALSE, the check-out version is updated and remains on the parent database. This allows you to manually reconcile at a later time. If you set reconcileCheckout to TRUE and there are no conflicts, the check-out version is removed.

The childReconcilePolicy parameter takes an esriReplicaReconilePolicyType enumeration to determine how conflicts will be handled during reconcile. The following describes the meaning of each enumeration:


esriReplicaDetectConflicts -If conflicts occur, the reconcile process is aborted and you must reconcile and post manually after sycnhronization is completed.

esriReplicaResolveConflictsInFavorOfImportedChanges - The representation in the check-out geodatabase is automatically applied if conflicts arrise.

esriReplicaResolveConflictsInFavorOfDatabaseChanges - The representation from the parent replica importing is automatically applied if conflicts arrise.

esriReplicaResolveConflictsNone - This enumeration has meaning for check-out replicas only. It indicates that a reconcile and post should not be applied during synchronization.

If columnLevel is TRUE, conflicts are detected only when the same attribute is updated in both the check-out and the parent replica. For example, if the check-out has modified the parcel's owner attribute and the parent replica has modified the parcel's street address attribute the feature will not be in conflict. It is only when each version modifies the same attribute that the object will be in conflict.

The CheckInFromGDB2 method returns TRUE if conflicts were detected. It returns FALSE if no conflicts were detected.

Product Availability

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

Specified by:
checkInFromGDB2 in interface ICheckIn2
Parameters:
parentDB - A reference to a com.esri.arcgis.geodatabase.IWorkspaceName (in)
checkoutName - The checkoutName (in)
checkOutDB - A reference to a com.esri.arcgis.geodatabase.IWorkspaceName (in)
reconcileCheckout - The reconcileCheckout (in)
childReconcilePolicy - A com.esri.arcgis.geodatabase.esriReplicaReconcilePolicyType constant (in)
columnLevel - The columnLevel (in)
createOIDMappingTable - The createOIDMappingTable (in)
Returns:
The conflicts_detected
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

checkInFromDeltaFile2

public boolean checkInFromDeltaFile2(IWorkspaceName parentDB,
                                     String checkoutName,
                                     String fileName,
                                     int dcOption,
                                     boolean reconcileCheckout,
                                     int childReconcilePolicy,
                                     boolean columnLevel,
                                     boolean createOIDMappingTable)
                              throws IOException,
                                     AutomationException
Checks in changes from a delta database.

Remarks

The CheckinfromDeltaFile2 method applies the changes from a delta database (dcOption = esriExporttoAccess) or a delta XML file (dcOption = esriExporttoXML). See the DataChangesExporter for more information on delta files. Unlike the ICheckin::CheckinfromDeltaFile method , ICheckin2::CheckinfromDeltaFile2 enables you to specify how conflicts are defined, detected and applied during check in.

The checkoutName is needed to identify the check-out that is being checked in.

If createOIDMappingTable is True, tables are created in the parent replica geodatabase that describe the changes that are checked in. These tables are named <check-out name>_OM and <check-out name>_RC. If tables with these names already exist, they are over-written.

The <check-out name>_OM table records the pre- and post- check-in ObjectID values for new features/rows that have been added. The <check-out name>_RC table records all the changes made to the checked out data which include inserts (0), updates (1) and deletes (2).

Conflicts

If reconcileCheckout is TRUE, the changes are applied to the check-out version and this version is reconciled with its parent version. If reconcileCheckout is FALSE, the changes are applied to the check-out version, but no reconcile is performed.

If reconcileCheckout is TRUE and there are no conflicts during reconcile, a FALSE is returned, otherwise TRUE is returned. Conflicts can occur if a feature is edited in the check-out database and in the parent version of the parent database.

You should never edit the check-out version prior to check in. During check in, any coincidental changes are over-written with changes from the check-out database without notification of a conflict.

If you set reconcileCheckout to TRUE and there are conflicts or if reconcileCheckout is set to FALSE, the check-out version is updated and remains on the parent geodatabase. This allows you to manually reconcile at a later time. If you set reconcileCheckout to TRUE and there are no conflicts, the check-out version is removed.

The childReconcilePolicy parameter takes an esriReplicaReconilePolicyType enumeration to determine how conflicts will be handled during reconcile. The following describes the meaning of each enumeration:

esriReplicaDetectConflicts -If conflicts occur, the reconcile process is aborted and you must reconcile and post manually after sycnhronization is completed.

esriReplicaResolveConflictsInFavorOfImportedChanges - The representation in the check-out geodatabase is automatically applied if conflicts arrise.

esriReplicaResolveConflictsInFavorOfDatabaseChanges - The representation from the parent replica importing is automatically applied if conflicts arrise.

esriReplicaResolveConflictsNone - It indicates that a reconcile and post should not be applied during synchronization.

If columnLevel is TRUE, conflicts are detected only when the same attribute is updated in both the check-out and the parent replica. For example, if the check-out has modified the parcel's owner attribute and the parent replica has modified the parcel's street address attribute the feature will not be in conflict. It is only when each version modifies the same attribute that the object will be in conflict.

The CheckinfromDeltaFile2 method returns TRUE if conflicts were detected. It returns FALSE if no conflicts were detected.

Product Availability

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

Specified by:
checkInFromDeltaFile2 in interface ICheckIn2
Parameters:
parentDB - A reference to a com.esri.arcgis.geodatabase.IWorkspaceName (in)
checkoutName - The checkoutName (in)
fileName - The fileName (in)
dcOption - A com.esri.arcgis.geodatabasedistributed.esriExportDataChangesOption constant (in)
reconcileCheckout - The reconcileCheckout (in)
childReconcilePolicy - A com.esri.arcgis.geodatabase.esriReplicaReconcilePolicyType constant (in)
columnLevel - The columnLevel (in)
createOIDMappingTable - The createOIDMappingTable (in)
Returns:
The conflicts_detected
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.