|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface LibraryContentManager
This interface provides the means of managing theCategory
,Content
, andVersion
objects that are created as a result of the ReportCaster Distribution Server sending reports to the Report Library. Once reports are scheduled for distribution to the library, you can access or delete content, category, and version objects from the underlying report library database. Objects can be accessed in several ways such as by using contentId, versionId or category methods. The sample code below shows the instantiation of a LibraryContentManager object. ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + Copyright (c) 2004 Information Builders, Inc. All Rights Reserved. + + + + Information Builders offers sample API programs as a heuristic device. + + They are not intended, as is, for production use. Licensed users are + + welcome to alter and extend these samples and deploy them in other + + environments, or alternate configurations, as they see fit. + + Information Builders will support the documented functionality of + + its API classes and methods. However, Information Builders is not + + responsible for functionality or behavior of products built with + + its API unless the documented behavior of its discrete classes and + + methods is different than the actual results. + + + + Redistributions of IBI source code and documentation must be within + + the scope of the Information Builders Software License Agreement. + + + + ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ CasterManagedConnectionFactory managedConnectionFactory = new CasterManagedConnectionFactory(); managedConnectionFactory.setServerName(host);//the name of the server running the distribution server managedConnectionFactory.setPortNumber(port);//the port the distribution server is listening CasterConnectionFactory connectionFactory = (CasterConnectionFactory)managedConnectionFactory.createConnectionFactory(); ConnectionSpec credential = new PasswordCredential(user, password.toCharArray()); //This can be any of the credential objects. It is assumed here the user String has been assigned earlier // and that password, also assigned earlier, is a String that needs to be converted to a character Array. CasterConnection connectionObject = ((CasterConnection)connectionFactory.getConnection(credential)); LibraryContentManager manager = connectionObject.getLibraryContentManager();
Method Summary | |
---|---|
void |
addWatchItem(WatchItem watchItem)
|
void |
deleteContent(java.lang.String contentId)
Deletes the content description and all associated report versions from the ReportCaster Repository. |
void |
deleteContentByScheduleId(java.lang.String scheduleId,
java.lang.String burstValue)
|
void |
deleteVersion(java.lang.String versionId)
Deletes the version of this report from the underlying report library database. |
void |
deleteWatchItem(WatchItem watchItem)
|
Category[] |
getAccessibleCategoryInfoList(java.lang.String owner)
Returns a Category list which can be accessible by the user owner. |
Category[] |
getAccessibleCategoryInfoList(java.lang.String owner,
java.lang.String domainId,
java.lang.String reportId)
|
Category[] |
getAccessibleCategoryInfoListByCaller()
Retrieves an array of Category objects that are accessible
to the authenticated user. |
Content |
getAccessibleContentInfo(java.lang.String contentId)
Retrieves a Content object as identified by the contentId. |
Content[] |
getAccessibleContentInfoList(java.lang.String owner,
Category category)
Retrieves value of the designated category as a Content[] object without versionList . |
Content[] |
getAccessibleContentInfoList(java.lang.String owner,
Category category,
boolean isVersionList)
|
Content[] |
getAccessibleContentInfoList(java.lang.String domainId,
java.lang.String reportId)
Retrieves value of the designated report as a Content[] object without versionList . |
Content[] |
getAccessibleContentInfoList(java.lang.String domainId,
java.lang.String reportId,
boolean isVersionList)
|
Content[] |
getAccessibleContentInfoList(java.lang.String domainId,
java.lang.String reportId,
java.lang.String categoryName,
boolean isVersionList)
|
Content[] |
getAccessibleContentInfoListByCaller(Category category)
Retrieves an array of all Content objects accessible by the
authenticated user and associated with the given
Category . |
java.lang.String[] |
getAccessibleReportList(java.lang.String domainId,
java.lang.String folderId)
Returns all accessible Standard Report and My Report file names in ReportLibrary with the given Managed Reporting Domain HREF and Folder HREF for the authenticated user. |
java.io.InputStream |
getAccessibleVersion(java.lang.String versionId)
Returns an InputStream containing the report identified by the versionId. |
Version |
getAccessibleVersionInfo(java.lang.String versionId)
Retrieves a Version object as identified by the versionId. |
Category[] |
getCategoryInfoList()
Retrieves an array of Category objects. |
Category[] |
getCategoryInfoListByOwner(java.lang.String owner)
Retrieves an array of Category objects associated with a given
ReportCaster user. |
Content |
getContent(java.lang.String contentId)
Retrieves the Content object as identified by the contentId key
field. |
java.lang.String |
getContentId(java.lang.String owner,
java.lang.String contentDescription)
Obtains the content identifier associated with a designated owner and a given content description string. |
Content[] |
getContentInfoList(Category category)
Retrieves an array of Content objects associated with the given
Category . |
Content[] |
getContentInfoList(Category category,
boolean isVersionList)
|
Content[] |
getContentInfoListByCaller(Category category)
Retrieves an array of Content objects identified with the given
Category and owned by the current authenticated user. |
Content[] |
getContentInfoListByOwner(java.lang.String owner,
Category category)
Retrieves an array of Content objects owned by the specified
ReportCaster userid within the specified Category . |
Content |
getLatestAccessibleContent(Schedule schedule)
Obtains the Content object that has latest version data
and is accessible to the authenticated user and associated with the
given Schedule object. |
java.lang.String[] |
getOwnerList()
Returns a list of library report owners. |
Version |
getVersion(java.lang.String versionId)
Retrieves the Version object as identified by the versionId key
field. |
Content[] |
getWatchContentInfoList(java.lang.String user)
|
WatchItem[] |
getWatchList(java.lang.String userId,
java.lang.String contentId)
|
java.lang.String[] |
getWatchOwnerList()
|
boolean |
isContentAccessible(java.lang.String userId,
java.lang.String contentId)
Returns the IDs for which a schedule is accessible. |
Method Detail |
---|
void deleteVersion(java.lang.String versionId) throws CasterException
versionId
- The unique identifier of the report version in the repository.
CasterException
- if a database access error occurs, or
Version
with versionId
doesn't exist, or
there is no permission to access this version.void deleteContent(java.lang.String contentId) throws CasterException
contentId
- The unique identifier of the content in the repository.
CasterException
- If a database access error occurs or
Content
with contentId
doesn't exist or
there is no permission to access this content.void deleteContentByScheduleId(java.lang.String scheduleId, java.lang.String burstValue) throws CasterException
CasterException
Version getVersion(java.lang.String versionId) throws CasterException
Version
object as identified by the versionId key
field. Since only information about this version is needed, the actual
report associated with this version is not retrieved.
However, the authenticated user must have access to this report version otherwise there
will be a CasterException thrown.
The getVersionId method can only be used by the administrator and the owner.
versionId
- The unique identifier of this version.
Version
object only containng information about the version.
CasterException
- if a database access error occurs or
Version
with versionId
doesn't exist or
there is no permission to access this version.Content getContent(java.lang.String contentId) throws CasterException
Content
object as identified by the contentId key
field. Because only information about this content is needed, the actual
report associated with this content is not retrieved.
However the authenticated user must have access to this content otherwise there
will be a CasterException thrown. This method can only be used by the administrator and the owner.
contentId
- The unique identifier of the content.
Content
object only containing information about the Content.
CasterException
- If a database access error occurs or
Content
with contentId
doesn't exist or
there is no permission to access this content.Content[] getContentInfoList(Category category) throws CasterException
Content
objects associated with the given
Category
.
Because only information about this content is needed, the actual
report associated with this content is not retrieved.
This method can only be used by the administrator and the owner.
category
- Reference to the Category
object
Content[]
)only containing information
about the content.
CasterException
- If a database access error occurs or
there is no permission to access this method.Content[] getContentInfoList(Category category, boolean isVersionList) throws CasterException
CasterException
Content[] getContentInfoListByCaller(Category category) throws CasterException
Content
objects identified with the given
Category
and owned by the current authenticated user. Because only information
about this content is needed, the actual report associated with this content is
not retrieved. This method can only be used by the administrator.
category
- Reference to the Category
object
content[]
) containing only
information about the content.
CasterException
- If a database access error occurs or
there is no permission to access this method.Content[] getContentInfoListByOwner(java.lang.String owner, Category category) throws CasterException
Content
objects owned by the specified
ReportCaster userid within the specified Category
. Because only information
about this content is needed, the actual report associated with this content is not retrieved.
This method can only be used by the administrator and the owner.
category
- Category object that is parent to the returned Content.
Content[]
).
CasterException
- If a database access error occurs or
there is no permission to access this method.Category[] getCategoryInfoList() throws CasterException
Category
objects. Because no user or owner
is designated either implicitly or explicitly, this method will retrieve all
categories in the system. Because only information about this report category is
needed, the actual report associated with this Content is not retrieved.
This method can only be used by the administrator and the owner.
Category[]
).
CasterException
- If a database access error occurs or
there is no permission to access this method.Category[] getCategoryInfoListByOwner(java.lang.String owner) throws CasterException
Category
objects associated with a given
ReportCaster user. Only those categories accessible by the designated user
are listed. Because only information about this report category is needed, the actual reports
associated with the Categories are not retrieved.
This method can only be used by the administrator.
owner
- ReportCaster username of the user who can view the categories.
Category[]
).
CasterException
- If a database access error occurs or
there is no permission to access this method.Category[] getAccessibleCategoryInfoList(java.lang.String owner) throws CasterException
Category
list which can be accessible by the user owner.
owner
- name of the owner.
Category
list which can be accessible by the user owner.
CasterException
- if a database access error occurs or
no permission to access this function.Category[] getAccessibleCategoryInfoList(java.lang.String owner, java.lang.String domainId, java.lang.String reportId) throws CasterException
CasterException
java.lang.String[] getOwnerList() throws CasterException
CasterException
- If a database access error occurs or there is no
permission to access this method.java.lang.String[] getWatchOwnerList() throws CasterException
CasterException
java.io.InputStream getAccessibleVersion(java.lang.String versionId) throws CasterException
versionId
- Unique identifier for the version.
CasterException
- If a database access error occurs or
Version
with versionId
doesn't exist or
there is no permission to access this version from the Report Library.Version getAccessibleVersionInfo(java.lang.String versionId) throws CasterException
Version
object as identified by the versionId.
As each version ID is unique, this method obtains only the designated
version of content from the Report Library data source. However, the
authenticated user must have access to this report version or a
CasterException is thrown. Because only information about this report
version is needed, the actual report is not accessible using the object
returned by this method. This method is accessible only to the authenticated user.
versionId
- Unique identifier for the version.
Version
object without access to the actual report.
CasterException
- If a database access error occurs or
Version
with versionId
doesn't exist or
there is no permission to access this version from the Report Library.Content getAccessibleContentInfo(java.lang.String contentId) throws CasterException
Content
object as identified by the contentId.
As each content ID is unique, this method obtains only designated content
from the Report Library data source. However, the authenticated user must have
access to this report version or a CasterException is thrown. Because only
information about this report content is needed, the actual report is not
accessible using the object returned by this method. This method is
accessible only to the authenticated user.
contentId
- Unique identifier for the content.
CasterException
- If a database access error occurs or
Content
with contentId
doesn't exist or
there is no permission to access this content from the Report Library.Content[] getAccessibleContentInfoListByCaller(Category category) throws CasterException
Content
objects accessible by the
authenticated user and associated with the given
Category
. Because only information about this report content is
designated via this method, the actual report is not accessible via the
object returned by this method.
This method is accessible only to the authenticated user.
category
- A Category
object containing references to the
content.
CasterException
- If a database access error occurs or
there is no permission to access this category from the Report Library.Content[] getAccessibleContentInfoList(java.lang.String owner, Category category) throws CasterException
Content[]
object without versionList
.
owner
- The name of the owner.category
- A Category
object containing references to the
content.
Content[]
CasterException
- If a database access error occurs or
there is no permission to access this Content[] from the Report Library.Content[] getAccessibleContentInfoList(java.lang.String owner, Category category, boolean isVersionList) throws CasterException
CasterException
Content[] getAccessibleContentInfoList(java.lang.String domainId, java.lang.String reportId) throws CasterException
Content[]
object without versionList
.
domainId
- reportId
-
Content[]
CasterException
- If a database access error occurs or
there is no permission to access this Content[] from the Report Library.Content[] getAccessibleContentInfoList(java.lang.String domainId, java.lang.String reportId, boolean isVersionList) throws CasterException
CasterException
Content[] getAccessibleContentInfoList(java.lang.String domainId, java.lang.String reportId, java.lang.String categoryName, boolean isVersionList) throws CasterException
CasterException
java.lang.String[] getAccessibleReportList(java.lang.String domainId, java.lang.String folderId) throws CasterException
CasterException
- If a database access error occurs or
there is no permission to access this method.Category[] getAccessibleCategoryInfoListByCaller() throws CasterException
Category
objects that are accessible
to the authenticated user. Because only information about this report
category is needed, the actual reports are not retrieved.
This method is accessible only to the authenticated user.
CasterException
- If a database access error occurs or
there is no permission to access this method.java.lang.String getContentId(java.lang.String owner, java.lang.String contentDescription) throws CasterException
owner
- ReportCaster username of the content owner.contentDescription
- A description of the content as a String.
CasterException
- If a database access error occurs.Content getLatestAccessibleContent(Schedule schedule) throws CasterException
Content
object that has latest version data
and is accessible to the authenticated user and associated with the
given Schedule
object. Because only information about the latest
report version is needed, the actual report is not accessible via the object
returned by this method. For a Standard Report or My Report, the Schedule
object must have execId, procedureName, domainHREF and folderHREF.
For WebFOCUS Server Procedure, procedureName, execId and serverName are required.
If parameterList is specified in the Task
object, this method will
match all parameters in this parameterList. There is no order restriction
for the parameters in the parameterList.
schedule
-
CasterException
- If a database access error occurs.boolean isContentAccessible(java.lang.String userId, java.lang.String contentId) throws CasterException
CasterException
Content[] getWatchContentInfoList(java.lang.String user) throws CasterException
CasterException
WatchItem[] getWatchList(java.lang.String userId, java.lang.String contentId) throws CasterException
CasterException
void deleteWatchItem(WatchItem watchItem) throws CasterException
CasterException
void addWatchItem(WatchItem watchItem) throws CasterException
CasterException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |