Clearspace API (1.10.16) Web Services Client Javadocs

com.jivesoftware.community.webservices
Class Community

java.lang.Object
  extended by com.jivesoftware.community.webservices.JiveObject
      extended by com.jivesoftware.community.webservices.Community

public class Community
extends JiveObject

A container for threads and a hierarchy of other communities. In other words, the community structure is a tree, with lists of communities for every community node. There is always a "root" community (ID of 1), of which all other communities are children.


Field Summary
 
Fields inherited from class com.jivesoftware.community.webservices.JiveObject
id, objectType
 
Constructor Summary
Community()
           
 
Method Summary
 int getCommunityCount()
          Returns the number of community in the community.
 int getCommunityDepth()
          Returns the depth of a this community relative to the root.
 java.lang.String[] getContentTypes()
           
 java.util.Date getCreationDate()
          Returns the Date that the community was created.
 java.lang.String getDescription()
          Returns the description of the community.
 java.lang.String getDisplayName()
          Returns the displayName of the community.
 Locale getFinalLocale()
          Returns the locale for this community.
 long getLatestMessageID()
          Returns the most recently created or edited message in this community (including all sub-communities).
 Locale getLocale()
          Returns the locale for this community.
 int getMessageCount()
          Returns the number of messages in the community.
 java.util.Date getModificationDate()
          Returns the Date this community was last modified.
 java.lang.String getName()
          Returns the name of the community.
 long getParentCommunityID()
          Returns ID of the parent community of this community.
 int getRecursiveCommunityCount()
          Returns the number of communities in the community and all sub-communities.
 int getThreadCount()
          Returns number of thread in the community and all sub-communities
 void setCommunityCount(int communityCount)
           
 void setCommunityDepth(int communityDepth)
           
 void setContentTypes(java.lang.String... contentTypes)
           
 void setCreationDate(java.util.Date creationDate)
          Sets the creation date of the community.
 void setDescription(java.lang.String description)
          Sets the description of the community.
 void setDisplayName(java.lang.String displayName)
          Sets the displayName of the community.
 void setFinalLocale(Locale finalLocale)
           
 void setLatestMessageID(long latestMessageID)
           
 void setLocale(Locale locale)
          Sets the locale for this community.
 void setMessageCount(int messageCount)
           
 void setModificationDate(java.util.Date modificationDate)
          Sets the date the community was last modified.
 void setName(java.lang.String name)
          Sets the name of the community.
 void setParentCommunityID(long parentCommunityID)
           
 void setRecursiveCommunityCount(int recursiveCommunityCount)
           
 void setThreadCount(int threadCount)
           
 
Methods inherited from class com.jivesoftware.community.webservices.JiveObject
equals, getID, getObjectType, hashCode, setID, setObjectType, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Community

public Community()
Method Detail

getName

public java.lang.String getName()
Returns the name of the community.

Returns:
the name of the community.

setName

public void setName(java.lang.String name)
Sets the name of the community.

Parameters:
name - the name of the community.

getDisplayName

public java.lang.String getDisplayName()
Returns the displayName of the community.

Returns:
the displayName of the community.

setDisplayName

public void setDisplayName(java.lang.String displayName)
Sets the displayName of the community.

Parameters:
displayName - the displayName of the community.

getDescription

public java.lang.String getDescription()
Returns the description of the community.

Returns:
the description of the community.

setDescription

public void setDescription(java.lang.String description)
Sets the description of the community.

Parameters:
description - the description of the community.

getCreationDate

public java.util.Date getCreationDate()
Returns the Date that the community was created.

Returns:
the Date the community was created.

setCreationDate

public void setCreationDate(java.util.Date creationDate)
Sets the creation date of the community. In most cases, the creation date will default to when the community was entered into the system. However, the creation date needs to be set manually when importing data. In other words, skin authors should ignore this method since it only intended for system maintenance.

Parameters:
creationDate - the date the community was created.

getModificationDate

public java.util.Date getModificationDate()
Returns the Date this community was last modified. In other words, the date of the most recent community update in this community.

By default, this feature is

Returns:
the Date the community was last modified.

setModificationDate

public void setModificationDate(java.util.Date modificationDate)
Sets the date the community was last modified. In most cases, last modifed will default to when the community data was last changed. However, the last modified date needs to be set manually when importing data. In other words, skin authors should ignore this method since it only intended for system maintenance.

Parameters:
modificationDate - the date the community was modified.

getLocale

public Locale getLocale()
Returns the locale for this community. A locale specifies language and country codes, and is used for internationalization. If a locale has not been specified for this community, this method will return 0. If you want to get the inherited locale for this community, you should call getFinalLocale().

Returns:
the locale for this community.

setLocale

public void setLocale(Locale locale)
Sets the locale for this community. A locale specifies language and country codes, and is used for internationalization.

Parameters:
locale - the locale of this community.

getFinalLocale

public Locale getFinalLocale()
Returns the locale for this community. A locale specifies language and country codes, and is used for internationalization. If a locale has not been specified for this community, this method will return an inherited locale. A community will inherit the locale from it's chain of parent communities, if one exists. Otherwise it will inherit the default locale used by Jive. If you want to get the explicit locale for this community, you should call getLocale().

Returns:
the final locale for this community.

setFinalLocale

public void setFinalLocale(Locale finalLocale)

getCommunityCount

public int getCommunityCount()
Returns the number of community in the community.

Returns:
the number of community in the community.

setCommunityCount

public void setCommunityCount(int communityCount)

getRecursiveCommunityCount

public int getRecursiveCommunityCount()
Returns the number of communities in the community and all sub-communities.

Returns:
the number of communities in the community and sub-communities.

setRecursiveCommunityCount

public void setRecursiveCommunityCount(int recursiveCommunityCount)

getThreadCount

public int getThreadCount()
Returns number of thread in the community and all sub-communities.

Returns:
the number of threads in the community.

setThreadCount

public void setThreadCount(int threadCount)

getMessageCount

public int getMessageCount()
Returns the number of messages in the community.

Returns:
the number of messages in the community.

setMessageCount

public void setMessageCount(int messageCount)

getLatestMessageID

public long getLatestMessageID()
Returns the most recently created or edited message in this community (including all sub-communities). If there are no messages in this community, this method will return 0. This information could also be determined using a ThreadResultFilter, but this method offers a simpler, more optimized way to access the data.

Returns:
the most recently created or edited message in this community.

setLatestMessageID

public void setLatestMessageID(long latestMessageID)

getParentCommunityID

public long getParentCommunityID()
Returns ID of the parent community of this community. This method will return 0 if the current community is the root community.

Returns:
the parent community of this community.

setParentCommunityID

public void setParentCommunityID(long parentCommunityID)

getCommunityDepth

public int getCommunityDepth()
Returns the depth of a this community relative to the root. For example, consider the following tree (where 1 is the root community):
   1
   |-- 3
   |-- |-- 4
   |-- |-- |-- 7
 
The depth of message 4 is 2, the depth of community 7 is 3, etc.

Returns:
the depth of the community in the community tree.

setCommunityDepth

public void setCommunityDepth(int communityDepth)

getContentTypes

public java.lang.String[] getContentTypes()

setContentTypes

public void setContentTypes(java.lang.String... contentTypes)

Clearspace Project Page

Copyright © 1999-2007 Jive Software.