com.ptc.windchill.uwgm.common.content
Class ContentHelper

java.lang.Object
  extended bycom.ptc.windchill.uwgm.common.content.ContentHelper

public class ContentHelper
extends Object


Field Summary
static String[] DEFAULT_PREFERRED_LOCATIONS
           
private static String FILE_URL
           
private static String HTTP_URL
           
private static Log log
           
 
Constructor Summary
ContentHelper()
           
 
Method Summary
private static void getApplicationDataURLs(WTKeyedMap holdersMap, WTKeyedMap ilInfoMap, WTKeyedMap urlsMap, boolean isFilePreferred)
           
private static WTKeyedMap getContent(WTCollection holders, Object group, ContentRoleType roleType)
           
static WTKeyedMap getContentItems(WTCollection holders)
          retrievs the content items for the given collection of content holders
static WTKeyedMap getContentItems(WTCollection holders, EPMWorkspace workspace)
          retrievs the content items for the given collection of content holders
static WTKeyedMap getContentItems(WTCollection holders, Folder folder)
          retrievs the content items for the given WTCollection of content holders
static WTKeyedMap getContentItemsByRole(WTCollection holders, EPMWorkspace workspace, ContentRoleType roleType)
          retrievs the content items of the given role for the given collection of content holders
static WTKeyedMap getContentURLs(WTKeyedMap holdersMap, WTKeyedMap ilInfoMap)
          retrievs the content item URLs
static WTKeyedMap getContentURLs(WTKeyedMap holdersMap, WTKeyedMap ilInfoMap, String[] locations)
          retrievs the preferred content item URLs
static WTKeyedMap getGatewayPublishedData(WTCollection holders)
          Retrieves getGatewayPublishedData
private static void getURLDataURLs(WTKeyedMap holdersMap, WTKeyedMap ilInfoMap, WTKeyedMap urlsMap)
           
static boolean isWCObjPublishedFromIL(EPMDocument obj)
          Checks whether the object published from Intralink
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

log

private static Log log

HTTP_URL

private static final String HTTP_URL
See Also:
Constant Field Values

FILE_URL

private static final String FILE_URL
See Also:
Constant Field Values

DEFAULT_PREFERRED_LOCATIONS

public static final String[] DEFAULT_PREFERRED_LOCATIONS
Constructor Detail

ContentHelper

public ContentHelper()
Method Detail

getContentItems

public static WTKeyedMap getContentItems(WTCollection holders)
                                  throws WTException
retrievs the content items for the given collection of content holders

Returns:
WTKeyedMap where a key is holder, a value is WTCollection of content items. Holders without content items are not presented in the returned map.
Throws:
WTException

getContentItems

public static WTKeyedMap getContentItems(WTCollection holders,
                                         Folder folder)
                                  throws WTException
retrievs the content items for the given WTCollection of content holders

Parameters:
folder - Folder where the given holders are located
Returns:
WTKeyedMap where a key is holder, a value is a collection of content items. Holders without content items are not presented in the returned map.
Throws:
WTException

getContentItems

public static WTKeyedMap getContentItems(WTCollection holders,
                                         EPMWorkspace workspace)
                                  throws WTException
retrievs the content items for the given collection of content holders

Parameters:
holders - WTCollection
workspace - EPMWorkspace where the given holders are located
Returns:
WTKeyedMap where a key is holder, a value is WTCollection of content items. Holders without content items are not presented in the returned map.
Throws:
WTException

getContentItemsByRole

public static WTKeyedMap getContentItemsByRole(WTCollection holders,
                                               EPMWorkspace workspace,
                                               ContentRoleType roleType)
                                        throws WTException
retrievs the content items of the given role for the given collection of content holders

Parameters:
holders - WTCollection
workspace - EPMWorkspace where the given holders are located
Returns:
WTKeyedMap where a key is holder, a value is WTCollection of content items. Holders without content items are not presented in the returned map.
Throws:
WTException

getContentURLs

public static WTKeyedMap getContentURLs(WTKeyedMap holdersMap,
                                        WTKeyedMap ilInfoMap)
                                 throws WTException
retrievs the content item URLs

Returns:
WTKeyedMap where a key is contentItem, a value is a String[] of URLs.
Throws:
WTException

getContentURLs

public static WTKeyedMap getContentURLs(WTKeyedMap holdersMap,
                                        WTKeyedMap ilInfoMap,
                                        String[] locations)
                                 throws WTException
retrievs the preferred content item URLs

Parameters:
locations - String[]
Returns:
WTKeyedMap where a key is contentItem, a value is a String[] of URLs.
Throws:
WTException

isWCObjPublishedFromIL

public static boolean isWCObjPublishedFromIL(EPMDocument obj)
Checks whether the object published from Intralink

Parameters:
obj - EPMDocument

getGatewayPublishedData

public static WTKeyedMap getGatewayPublishedData(WTCollection holders)
Retrieves getGatewayPublishedData

Parameters:
holders - Collection
Returns:
WTKeyedMap where a key is holder, a value is a ILInfo object.

getContent

private static WTKeyedMap getContent(WTCollection holders,
                                     Object group,
                                     ContentRoleType roleType)
                              throws WTException
Throws:
WTException

getApplicationDataURLs

private static void getApplicationDataURLs(WTKeyedMap holdersMap,
                                           WTKeyedMap ilInfoMap,
                                           WTKeyedMap urlsMap,
                                           boolean isFilePreferred)
                                    throws WTException
Throws:
WTException

getURLDataURLs

private static void getURLDataURLs(WTKeyedMap holdersMap,
                                   WTKeyedMap ilInfoMap,
                                   WTKeyedMap urlsMap)
                            throws WTException
Throws:
WTException