SMACS

smacs.xngr.browser.properties
Class CategoryPropertiesXml

java.lang.Object
  extended bysmacs.xngr.browser.properties.CategoryPropertiesXml
All Implemented Interfaces:
CategoryProperties

public class CategoryPropertiesXml
extends Object
implements CategoryProperties

The base class for the category properties.

Author:
Edwin Dankert

Constructor Summary
CategoryPropertiesXml(Element element)
          Constructor for the category properties.
CategoryPropertiesXml(String name)
          Constructor for the category properties.
 
Method Summary
 void addCategory(CategoryProperties properties)
          Adds the category properties.
 void addDocument(DocumentProperties properties)
          Adds the document properties to the category.
 Vector getCategories()
          Returns the properties for the child categories.
 Vector getDocuments()
          Returns the properties for the documents in this category.
 Element getElement()
          Returns the dom4j Element representation of this category.
 String getName()
          Returns the name of the category.
 CategoryProperties newCategoryProperties(Element element)
          Constructor for the category properties.
 CategoryProperties newCategoryProperties(String name)
          Constructor for the category properties.
 DocumentProperties newDocumentProperties(Element element)
           
 void removeCategory(CategoryProperties properties)
          Removes a category from the parent property.
 void removeDocument(DocumentProperties properties)
          Removes a document from the category.
 void setName(String name)
          Sets the name of the category.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CategoryPropertiesXml

public CategoryPropertiesXml(Element element)
Constructor for the category properties.


CategoryPropertiesXml

public CategoryPropertiesXml(String name)
Constructor for the category properties.

Parameters:
name - the name of the category.
Method Detail

newCategoryProperties

public CategoryProperties newCategoryProperties(Element element)
Description copied from interface: CategoryProperties
Constructor for the category properties.

Specified by:
newCategoryProperties in interface CategoryProperties

newCategoryProperties

public CategoryProperties newCategoryProperties(String name)
Description copied from interface: CategoryProperties
Constructor for the category properties.

Specified by:
newCategoryProperties in interface CategoryProperties
Parameters:
name - the name of the category.

newDocumentProperties

public DocumentProperties newDocumentProperties(Element element)

getName

public String getName()
Returns the name of the category.

Specified by:
getName in interface CategoryProperties
Returns:
the name.

setName

public void setName(String name)
Sets the name of the category.

Specified by:
setName in interface CategoryProperties

addCategory

public void addCategory(CategoryProperties properties)
Adds the category properties.

Specified by:
addCategory in interface CategoryProperties
Parameters:
properties - the category properties.

removeCategory

public void removeCategory(CategoryProperties properties)
Removes a category from the parent property.

Specified by:
removeCategory in interface CategoryProperties
Parameters:
properties - the category properties.

getCategories

public Vector getCategories()
Returns the properties for the child categories.

Specified by:
getCategories in interface CategoryProperties
Returns:
a list of Category Properties.

addDocument

public void addDocument(DocumentProperties properties)
Adds the document properties to the category.

Specified by:
addDocument in interface CategoryProperties
Parameters:
properties - the document properties.

removeDocument

public void removeDocument(DocumentProperties properties)
Removes a document from the category.

Specified by:
removeDocument in interface CategoryProperties
Parameters:
properties - the document properties.

getDocuments

public Vector getDocuments()
Returns the properties for the documents in this category.

Specified by:
getDocuments in interface CategoryProperties
Returns:
a list of Document Properties.

getElement

public Element getElement()
Returns the dom4j Element representation of this category.

Specified by:
getElement in interface CategoryProperties
Returns:
the element.

SMACS