com.lightdev.tree.data
Interface HierarchicalItem


public interface HierarchicalItem

HierarchicalItem.java

Classes wishing to be treated as part of a hierarchical data structure need to implement this interface

Version:
1, 01.08.2005
Author:
Ulrich Hilger, Light Development, http://www.lightdev.com, info@lightdev.com, published under the terms and conditions of the BSD License, for details see file license.txt in the distribution package of this software

Method Summary
 Object getData()
          get the data of this item
 Object getId()
          get the id of this item
 Object getParentId()
          get the id of the parent of this item
 boolean isRoot()
          determine if this item is a root item, i.e. has no parent items
 void setData(Object data)
          set the data of this item
 void setId(Object id)
          set the id of this item
 void setParentId(Object parentId)
          set the id of the parent of this item
 

Method Detail

setData


void setData(Object data)
set the data of this item

Parameters:
data - the item's data

getData


Object getData()
get the data of this item

Returns:
the data of this item

setId


void setId(Object id)
set the id of this item

Parameters:
id - the id of this item

getId


Object getId()
get the id of this item

Returns:
the id of this item

getParentId


Object getParentId()
get the id of the parent of this item

Returns:
the id of the parent of this item

setParentId


void setParentId(Object parentId)
set the id of the parent of this item

Parameters:
parentId - the parent id of this item

isRoot


boolean isRoot()
determine if this item is a root item, i.e. has no parent items

Returns:
true if this item is a root item, false otherwise