Interface IVersion

Namespace
ESRI.ArcGIS.Geodatabase
Assembly
ESRI.Server.Geodatabase.dll

Provides access to members for managing a version.

[Guid("1A945841-B381-11D1-9CE6-0000F8780619")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
public interface IVersion

Properties

Access

The version's access permission.

esriVersionAccess Access { get; set; }

Property Value

esriVersionAccess

Remarks

The Access property is used to retrieve or set a version's access property. Version access can be private, public or protected. Private versions are only accessible by the version's owner, public versions can be viewed and edited by any user, and protected versions can be viewed by any user but only edited by the owner. Only the owner of a version can change its properties, such as the access.

Description

The version's description.

string Description { get; set; }

Property Value

string

Remarks

The Description method is used to retreive or set a version's description. Version descriptions are not required and are limited to 64 characters. Only the owner of a version can change its properties, such as the description.

IsRedefined

Determines whether the state of the version corresponding to this version object has been redefined in the database.

bool IsRedefined { get; }

Property Value

bool

Owner

string Owner { get; set; }

Property Value

string

VersionInfo

This version's information.

IVersionInfo VersionInfo { get; }

Property Value

IVersionInfo

Remarks

The VersionInfo method provides a reference to the IVersionInfo interface. The IVersionInfo interface contains methods which describe the properties of the version. The interface is beneficial for obtaining a version's ancestory, for example its parent version.

VersionInfo will only return versions in which the connected user has the appropriate privileges.

VersionLocks

This version's locks.

IEnumLockInfo VersionLocks { get; }

Property Value

IEnumLockInfo

Remarks

The VersionLocks method returns the enumeration IEnumLockInfo. Using the enumeration you can detect what users are currently editing the version or currently reconciling the version. This information can be used to determine if the version is available for editing, to be reconciled or to be reconciled against.

See ILockInfo and esriLockType constants for additional information regarding locking descriptions.

VersionName

The name of the version.

string VersionName { get; set; }

Property Value

string

Remarks

The VersionName method is used to retrieve or set a version's name. Version names are case sensitive and limited to 64 characters. Only the owner of a version can change its properties, such as the name.

The DEFAULT version cannot be renamed.

Methods

AlterVersion(string, string, esriVersionAccess)

void AlterVersion(string VersionName, string Description, esriVersionAccess Access)

Parameters

VersionName string
Description string
Access esriVersionAccess

CreateChild(string, IVersion)

Creates a new child version of this version whose initial state is the current state of pInitialStateVersion.

IVersion CreateChild(string Name, IVersion initialStateVersion)

Parameters

Name string
initialStateVersion IVersion

Returns

IVersion

CreateVersion(string)

Creates a new version equivalent to this version.

IVersion CreateVersion(string newName)

Parameters

newName string

Returns

IVersion

Remarks

The CreateVersion method allows you to create new version from the existing IVersion. The new version is a child of the current version and is owned by the connected user. The version name is limited to 64 characters and is private by default.

Creating a new version requires an existing version to be the parent of the new version. When the new version is created, the parent and child versions are identical.

CreateVersionEx(string, string, esriVersionAccess)

IVersion CreateVersionEx(string VersionName, string Description, esriVersionAccess Access)

Parameters

VersionName string
Description string
Access esriVersionAccess

Returns

IVersion

Delete()

Permanently deletes the version from the database.

void Delete()

Remarks

The Delete method is used to permanently delete a version. Only the owner of the version or the ArcSDE administrator can delete the version.

DeleteWithChildren()

Permanently deletes the version and all it's children from the database.

void DeleteWithChildren()

GetCommonAncestor(IVersion)

Finds common ancestor version.

IVersion GetCommonAncestor(IVersion otherVersion)

Parameters

otherVersion IVersion

Returns

IVersion

HasParent()

True if this version have a parent version.

bool HasParent()

Returns

bool

Remarks

All versions, except the default version have parent versions.

RefreshVersion()

Refreshes the version with the corresponding database state.

void RefreshVersion()

Remarks

The RefreshVersion method refreshes the version to correspond with the database state the version references. For example, if a second application is editing the verison and saves their changes, you need to call the RefreshVersion method to see the latest representation of the version.