com.ptc.windchill.uwgm.common.conflict
Class UwgmConflictHelper

java.lang.Object
  extended bycom.ptc.windchill.uwgm.common.conflict.UwgmConflictHelper

public class UwgmConflictHelper
extends Object


Nested Class Summary
static interface UwgmConflictHelper.OverridableConflict
          public interface for overridable conflict templates
private static class UwgmConflictHelper.OverridableConflictImpl
          internal OverridableConflict implementation
 
Field Summary
static UwgmConflictHelper.OverridableConflict CHECKOUT_TO_PROJECT
           
static UwgmConflictHelper.OverridableConflict CONVERT_SHARE_TO_CHECKOUT
           
private static Log log
          logging
private static ResolutionType[] resolutions
           
static UwgmConflictHelper.OverridableConflict SHARE_TO_PROJECT
           
private static ResolutionType[] shareToCheckoutResolutions
           
static UwgmConflictHelper.OverridableConflict STALE_SEC_CONTENT
           
static UwgmConflictHelper.OverridableConflict UWGM_TEST_CONFLICT
           
 
Constructor Summary
UwgmConflictHelper()
           
 
Method Summary
static void addResolutionOption(ConflictType conflictType, ResolutionType resolutionType)
          Allows to add a resolution option to the "method context".
static ConflictResolution createConflictResolution(String conflictType, String resolutionType, WTCollection objects)
          creates a conflict resolution
static WTCollection getUnresolved(ConflictType conflictType, ResolutionType[] resolutions, WTCollection objects)
          returns unresolved object for this conflict and resolution
private static boolean isResolutionSpecified(ResolutionType[] resolutions, ResolutionType specifiedResolution)
          internal helper method for getUnresolved
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CHECKOUT_TO_PROJECT

public static final UwgmConflictHelper.OverridableConflict CHECKOUT_TO_PROJECT

shareToCheckoutResolutions

private static ResolutionType[] shareToCheckoutResolutions

CONVERT_SHARE_TO_CHECKOUT

public static final UwgmConflictHelper.OverridableConflict CONVERT_SHARE_TO_CHECKOUT

SHARE_TO_PROJECT

public static final UwgmConflictHelper.OverridableConflict SHARE_TO_PROJECT

resolutions

private static ResolutionType[] resolutions

STALE_SEC_CONTENT

public static final UwgmConflictHelper.OverridableConflict STALE_SEC_CONTENT

UWGM_TEST_CONFLICT

public static final UwgmConflictHelper.OverridableConflict UWGM_TEST_CONFLICT

log

private static Log log
logging

Constructor Detail

UwgmConflictHelper

public UwgmConflictHelper()
Method Detail

createConflictResolution

public static ConflictResolution createConflictResolution(String conflictType,
                                                          String resolutionType,
                                                          WTCollection objects)
                                                   throws UwgmErrorException
creates a conflict resolution

Parameters:
conflictType - String
resolutionType - String
objects - WTCollection
Returns:
ConflictResolution
Throws:
UwgmErrorException

getUnresolved

public static WTCollection getUnresolved(ConflictType conflictType,
                                         ResolutionType[] resolutions,
                                         WTCollection objects)
                                  throws WTException
returns unresolved object for this conflict and resolution

Parameters:
conflictType - ConflictType
resolutions - ResolutionType[]
objects - WTCollection
Returns:
WTCollection
Throws:
WTException

isResolutionSpecified

private static boolean isResolutionSpecified(ResolutionType[] resolutions,
                                             ResolutionType specifiedResolution)
internal helper method for getUnresolved

Parameters:
resolutions - ResolutionType[]
specifiedResolution - ResolutionType
Returns:
boolean

addResolutionOption

public static void addResolutionOption(ConflictType conflictType,
                                       ResolutionType resolutionType)
Allows to add a resolution option to the "method context". This method is actually a hack, because it is based on the knowledge of the ConflictServerHelper's implementation details. ConflictServerHelper misses this functionality: its setInputConflictResolutions() method overwrites all previousely set resolution options.

Parameters:
conflictType - ConflictType
resolutionType - ResolutionType