com.sapportals.wcm.repository.service.comment

Interface IComment


public interface IComment

The interface represents a service for handling comments on resources. Comments are assigned to resources and can be viewed by all users.

The comments service can be configured. It offers a method to determine the current configuration.


Method Summary
 boolean addComment(IResource resource, String Text)
          Adds a comment to a given resource.
 boolean delComment(IResource resource, IResource commentres)
          Deletes a comment for a resource.
 IResourceList getComment(IResource resource)
          Gets all comments for a given resource sorted by creation date.
 int getCommentCount(IResource resource)
          Returns the number of comments given for a resource.
 Properties getProperties()
          Gets all configuration data for this service.
 boolean isSecure()
          Checks if service is set to be a secure service.
 

Method Detail

addComment

boolean addComment(IResource resource,
                   String Text)
                   throws com.sapportals.wcm.WcmException
Adds a comment to a given resource. The author of the comment is identified by the resource context.

Parameters:
resource - the resource for which the comment is given
Text - text of the comment
Returns:
Boolean that indicates whether storage of comment was successful or failed
Throws:
com.sapportals.wcm.WcmException

getComment

IResourceList getComment(IResource resource)
Gets all comments for a given resource sorted by creation date.

Parameters:
resource - the resource for which the comments were given
Returns:
list of resources that store comments

getProperties

Properties getProperties()
Gets all configuration data for this service.

Returns:
all configuration data as properties

delComment

boolean delComment(IResource resource,
                   IResource commentres)
Deletes a comment for a resource.

Parameters:
resource - resource for which the comment was saved
commentres - resource that stores the comment to be deleted
Returns:
Boolean indicating whether the deletion was succesful or failed

getCommentCount

int getCommentCount(IResource resource)
Returns the number of comments given for a resource.

Parameters:
resource - resource for which comments exist
Returns:
the number of comments that exist for the resource

isSecure

boolean isSecure()
Checks if service is set to be a secure service. It is possible to configure the service so that no htmlb editor is used.

Returns:
true, if the service is set to be secure, otherwise false
Access Rights

This class can be accessed from:


SC DC Public Part ACH
[sap.com] KMC-CM [sap.com] tc/km/frwk api EP-KM-CM
[sap.com] KMC-WPC [sap.com] tc/kmc/wpc/wpcfacade api EP-PIN-WPC-WCM


Copyright 2011 SAP AG Complete Copyright Notice