|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.plumtree.taskapi.portalui.TaskAPIUIDirectoryService
public class TaskAPIUIDirectoryService
This class manages instances of the ITaskAPIUIDirectory interface for both production and testing purposes. It is a replacement for the TaskAPIUIDirectory class, since that class uses static methods and cannot be mocked for testing.
Method Summary | |
---|---|
IXPList |
AddUploadData(AActivitySpace owner,
IXPList _sources)
Adds the upload data for the Web Services associated with the Data Sources used for submitting documents to the Knowledge Directory. |
IPTURL |
CreateCommonOpenerDirectoryFolderURL(AActivitySpace owner,
java.lang.String strTitle,
int nDirMode,
int nFolderID)
Gets an URL to open a specified Knowledge Directory folder in the selected mode. |
IPTURL |
CreateCommonOpenerDirectoryFolderURL(AActivitySpace owner,
java.lang.String strTitle,
int nDirMode,
int nFolderID,
java.lang.String strFolderName)
Gets an URL to open a specified Knowledge Directory folder in the selected mode. |
IPTURL |
CreateCommonOpenerDocumentURL(AActivitySpace owner,
java.lang.String strTitle,
int nDocumentID)
Gets an URL to open a specified Document in the Knowledge Directory. |
IPTURL |
CreateCommonOpenerDocumentURL(AActivitySpace owner,
java.lang.String strTitle,
int nDocumentID,
java.lang.String strDocumentName)
Gets an URL to open a specified Document in the Knowledge Directory. |
static ITaskAPIUIDirectory |
GetInstance()
|
IXPList |
GetSubmitDataSources(AActivitySpace owner)
Gets the Data Sources used for submitting documents to the Knowledge Directory. |
IPTURL |
GetURLForBrowseDirectory(AActivitySpace owner,
int nFolderID)
Gets the URL to the specified Knowledge Directory in Browse Mode. |
IPTURL |
GetURLForEditDirectory(AActivitySpace owner,
int nFolderID)
Gets the URL to the specified Knowledge Directory in Edit Mode. |
boolean |
IsCurrentPageDirectoryPage(AActivitySpace owner)
Checks if the current page is a Knowledge Directory page. |
boolean |
IsDirectoryFeaturedEnabledInSubPortal(AActivitySpace owner)
Checks if the Knowledge Directory feature is enabled in the current Experience Definition. |
boolean |
IsWebDataSource(IPTDataSource _dataSource,
IPTSession _session)
Check if the provider for this data source supports web paths. |
static void |
SetMockInstanceForDebug(ITaskAPIUIDirectory _instance)
This method sets the debug instance of the ITaskAPIUIDirectory interface for use as a mock object. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static ITaskAPIUIDirectory GetInstance()
public static void SetMockInstanceForDebug(ITaskAPIUIDirectory _instance)
_instance
- The mock instance of the ITaskAPIUIDirectory interface.
When the mock instance is done being used it should be reset to null by
calling this method again with a null argument.public IPTURL CreateCommonOpenerDirectoryFolderURL(AActivitySpace owner, java.lang.String strTitle, int nDirMode, int nFolderID)
ITaskAPIUIDirectory
CreateCommonOpenerDirectoryFolderURL
in interface ITaskAPIUIDirectory
owner
- Current Activityspace.strTitle
- Title of the URL, normally the name of the folder to open.nDirMode
- DirConstants.BROWSE_MODE or DirConstants.EDIT_MODEnFolderID
- Object ID of the Knowledge Directory Folder to get an URL to.
IPTURL
to a folder in the Knowledge Directory - no image is assigned to the URL.DirConstants
public IPTURL CreateCommonOpenerDirectoryFolderURL(AActivitySpace owner, java.lang.String strTitle, int nDirMode, int nFolderID, java.lang.String strFolderName)
ITaskAPIUIDirectory
CreateCommonOpenerDirectoryFolderURL
in interface ITaskAPIUIDirectory
owner
- Current Activityspace.strTitle
- Title of the URL, normally the name of the folder to open.nDirMode
- DirConstants.BROWSE_MODE or DirConstants.EDIT_MODEnFolderID
- Object ID of the Knowledge Directory Folder to get an URL to.
IPTURL
to a folder in the Knowledge Directory - no image is assigned to the URL.DirConstants
public IPTURL CreateCommonOpenerDocumentURL(AActivitySpace owner, java.lang.String strTitle, int nDocumentID)
ITaskAPIUIDirectory
CreateCommonOpenerDocumentURL
in interface ITaskAPIUIDirectory
owner
- Current Activityspace.strTitle
- Title of the URL, normally the name of the Document to open.nDocumentID
- Object ID of the Document to get an URL to.
public IPTURL CreateCommonOpenerDocumentURL(AActivitySpace owner, java.lang.String strTitle, int nDocumentID, java.lang.String strDocumentName)
ITaskAPIUIDirectory
CreateCommonOpenerDocumentURL
in interface ITaskAPIUIDirectory
owner
- Current Activityspace.strTitle
- Title of the URL, normally the name of the Document to open.nDocumentID
- Object ID of the Document to get an URL to.strDocumentName
- Name of the document.
public IPTURL GetURLForBrowseDirectory(AActivitySpace owner, int nFolderID)
ITaskAPIUIDirectory
GetURLForBrowseDirectory
in interface ITaskAPIUIDirectory
owner
- Current Activityspace.nFolderID
- Object ID of a Knowledge Directory folder to create an URL to.
IPTURL
with the URL to the specified folder in Knowledge Directory Browse Mode,
or null
if the URL is not valid in the current context.public IPTURL GetURLForEditDirectory(AActivitySpace owner, int nFolderID)
ITaskAPIUIDirectory
GetURLForEditDirectory
in interface ITaskAPIUIDirectory
owner
- Current Activityspace.nFolderID
- Object ID of a Knowledge Directory folder to create an URL to.
IPTURL
with the URL to the specified folder in Knowledge Directory Edit Mode,
or null
if the URL is not valid in the current context.public boolean IsCurrentPageDirectoryPage(AActivitySpace owner)
ITaskAPIUIDirectory
IsCurrentPageDirectoryPage
in interface ITaskAPIUIDirectory
owner
- Current Activityspace.
true
if the current page us a Knowledge Directory page, false
otherwise.public boolean IsDirectoryFeaturedEnabledInSubPortal(AActivitySpace owner)
ITaskAPIUIDirectory
IsDirectoryFeaturedEnabledInSubPortal
in interface ITaskAPIUIDirectory
owner
- Current Activityspace.
true
Knowledge Directory feature is enabled, false
otherwise.public IXPList GetSubmitDataSources(AActivitySpace owner)
ITaskAPIUIDirectory
GetSubmitDataSources
in interface ITaskAPIUIDirectory
owner
- Current Activityspace.
public IXPList AddUploadData(AActivitySpace owner, IXPList _sources)
ITaskAPIUIDirectory
AddUploadData
in interface ITaskAPIUIDirectory
owner
- Current Activityspace._sources
- List of HashtableDataObjects of the Data Sources to lookup.
This is of the same format as the result of the GetSubmitDataSources method.
public boolean IsWebDataSource(IPTDataSource _dataSource, IPTSession _session)
ITaskAPIUIDirectory
IsWebDataSource
in interface ITaskAPIUIDirectory
_dataSource
- The data source to check._session
- the current user session
|
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |