com.esri.arcgis.geodatabase
Interface IVersionEdit3

All Superinterfaces:
IVersionEdit, IVersionEdit2, Serializable
All Known Subinterfaces:
IVersionEdit4
All Known Implementing Classes:
IVersionEdit3Proxy, IVersionEdit4Proxy, VersionedWorkspace

public interface IVersionEdit3
extends IVersionEdit2, Serializable

Provides access to members that return information about versions and posting of versions.

Superseded By

IVersionEdit4

Description

The IVersionEdit3 interface is used to reconcile a version with a target version and optionally not obtain version locks during the process and abort the reconcile process if conflicts are detected. An application would consume this interface when the intention is to abort the reconcile process when any conflicts are detected. An example of such an application would be a type of "batch" program that performed reconcile and post. Since a user cannot resolve conflicts at the end of the process, it simply saves resources and time to abort the process once conflicts are detected.

If the Boolean argument to abort conflicts is set to true and conflicts are detected, the application should immediately stop the edit session and not save the changes.

Note: If the lock is not obtained, the version can still be posted, but there will be no guarantee that the target version has not been modified and saved since the reconcile completed. In this case, an FDO_E_VERSION_REDEFINED error will be raised informing you that the version has been redefined. This error implies that you will need to re-execute the reconcile. If the intent is to post following a successful reconcile it is recommended that version locks are obtained.

Product Availability

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


Method Summary
 boolean reconcile3(String versionName, boolean acquireLock, boolean abortIfConflicts)
          Reconciles the current version with a target version.
 
Methods inherited from interface com.esri.arcgis.geodatabase.IVersionEdit2
reconcile2
 
Methods inherited from interface com.esri.arcgis.geodatabase.IVersionEdit
canPost, getCommonAncestorVersion, getConflictClasses, getModifiedClasses, getPreReconcileVersion, getReconcileVersion, getStartEditingVersion, post, reconcile
 

Method Detail

reconcile3

boolean reconcile3(String versionName,
                   boolean acquireLock,
                   boolean abortIfConflicts)
                   throws IOException,
                          AutomationException
Reconciles the current version with a target version.

Remarks

The Reconcile3 function reconciles the current edit version with the specified target version. The target version must be an ancestor of the current version or an error will be returned. The target version name passed in is case-sensitive and should take the form {owner}.{version_name} for example, SDE.DEFAULT. The first Boolean argument acquireLock specifies if locks should be obtained or not - true acquires the lock, false does not acquire the locks. The second Boolean argument abortIfConflicts specifies if the reconcile process should abort the reconcile if conflicts are detected for any class. Ideally, abortIfConflicts is only set to true when performing a reconcile in a automated batch type environment where a user does not have the ability to interactively resolve conflicts.

If the returned Boolean value from Reconcile3 is TRUE, then conflicts were detected. Otherwise no conflicts were detected.

A reconcile can only be performed if no other users are currently editing the version. As well, the target version cannot concurrently be reconciling by a second application. See IVersion::IVersionLocks for additional information on detecting version locks.

The Reconcile3 method provides the ability to either acquire or not acquire the version locks during the reconcile process. If the locks are not acquired the version is able to be reconciled in parallel when other versions are currently being reconciled. One may desire this functionality when there is no intention of posting the version after the reconcile process. If the intention is to "post" the version after performing the reconcile, it is strongly recommended that the locks are acquired.

If one does attempt to post after performing the reconcile, there is a chance that the target version might have been modified since the reconcile - in this case, the version will have to be re-reconciled. Therefore, the first reconcile is a waste of server and client system resources.

Calling Reconcile will abort the current edit operation therefore any edits made within an open edit operation when reconcile is called will be lost. If there is an open edit operation it is good practice to call StopEditOperation prior to calling Reconcile

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Parameters:
versionName - The versionName (in)
acquireLock - The acquireLock (in)
abortIfConflicts - The abortIfConflicts (in)
Returns:
The foundConflicts
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.