com.ithit.webdav.server.deltav
Enum AutoVersion

java.lang.Object
  extended by java.lang.Enum<AutoVersion>
      extended by com.ithit.webdav.server.deltav.AutoVersion
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable<AutoVersion>

public enum AutoVersion
extends java.lang.Enum<AutoVersion>

Auto versioning modes supported by item to be used with versioning unaware clients.

This enumeration determines how engine responds to WebDAV client requests that attempt to modify checked-in items content or properties. Each item that support versioning can function in one of the following auto-versioning modes:

NoAutoVersioning Mode. In this mode item must be checked-out before modifications. Clients that does not support DeltaV will not be able to modify checked-in items.

CheckOutCheckIn Mode. In this mode any WebDAV client applications will be able to modify checked-in items on server. Potentially many versions may be created. Workflow for versioning-unaware WebDAV client:

  1. Lock request (optional).
  2. Modification request:
  3. Unlock request (optional).

CheckOutUnlockedCheckIn Mode. In this mode any WebDAV client applications will be able to modify checked-in items on server. If WebDAV client locks the item prior to update, the item will be checked in during unlock. This mode reduces the number of versions created by versioning unaware clients. The item is never left checked-out. This mode is recommended if you need to support both Class 1 and Class 2 WebDAV clients. Workflow for versioning-unaware WebDAV client:

  1. Lock request (optional).
  2. Modification request:
  3. Unlock request (optional).

CheckOut Mode. In this mode any WebDAV client applications will be able to modify checked-in items on server. If the item was not locked before the update it will be left in checked-out state after modifications. Workflow for versioning-unaware WebDAV client:

  1. Lock request (optional).
  2. Modification request:
  3. Unlock request (optional).

LockedCheckOut Mode. Only WebDAV client applications that lock item before the update will be able to modify checked-in item. This mode minimizes amount of versions created by versioning unaware clients. Class 1 WebDAV applications will not be able to modify checked-in items. Workflow for versioning-unaware WebDAV client:

  1. Lock request (required).
  2. Modification request:
  3. Unlock request (required).


Enum Constant Summary
CheckOut
          If client tries to modify checked-in item, engine will automatically call VersionableItem.checkOut().
CheckOutCheckIn
          Before any item modification (such as changing content or properties) by versioning unaware client engine will call VersionableItem.checkOut().
CheckOutUnlockedCheckIn
          If client tries to modify checked-in item, engine will automatically call VersionableItem.checkOut().
LockedCheckOut
          If client tries to modify locked checked-in item, engine will automatically call <@link VersionableItem#checkOut}.
NoAutoVersioning
          Auto versioning is not supported for checked-in items.
 
Method Summary
static AutoVersion valueOf(java.lang.String name)
          Returns the enum constant of this type with the specified name.
static AutoVersion[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

NoAutoVersioning

public static final AutoVersion NoAutoVersioning
Auto versioning is not supported for checked-in items. Modification requests of versioning unaware clients will fail if item was not checked-out.


CheckOutCheckIn

public static final AutoVersion CheckOutCheckIn
Before any item modification (such as changing content or properties) by versioning unaware client engine will call VersionableItem.checkOut(). After the item is modified VersionableItem.checkIn() will be called.

This potentially can create a lot of versions.


CheckOutUnlockedCheckIn

public static final AutoVersion CheckOutUnlockedCheckIn
If client tries to modify checked-in item, engine will automatically call VersionableItem.checkOut(). If item is not locked engine will call @checkIn when modification completes.

If item is locked, VersionableItem.checkIn() will be called before the Lock.unlock(java.lang.String). If lock expires you must check-in item manually.


CheckOut

public static final AutoVersion CheckOut
If client tries to modify checked-in item, engine will automatically call VersionableItem.checkOut(). The VersionableItem.checkIn() will not be called.

If item is locked, @checkIn will be called before the Lock.unlock(java.lang.String). If lock expires you must check-in item manually.


LockedCheckOut

public static final AutoVersion LockedCheckOut
If client tries to modify locked checked-in item, engine will automatically call <@link VersionableItem#checkOut}.

VersionableItem.checkIn() will be called before the Lock.unlock(java.lang.String)/>. If lock expires you must check-in item manually.

If item is not locked - update request will fail.

Method Detail

values

public static AutoVersion[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (AutoVersion c : AutoVersion.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static AutoVersion valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
java.lang.NullPointerException - if the argument is null


Copyright © 2009 ITHit. All Rights Reserved.