com.infoengine.connector
Class Collection

java.lang.Object
  extended bycom.infoengine.connector.Data
      extended bycom.infoengine.connector.Collection
All Implemented Interfaces:
Serializable

public class Collection
extends Data

represents Info*Engine collection data.
Collections contain Groups.

See Also:
Serialized Form

Field Summary
private  Vector _groups
           
private  String name
           
 
Fields inherited from class com.infoengine.connector.Data
_meta
 
Constructor Summary
Collection()
          create a new unnamed Collection
Collection(String name)
          create a new named Collection
 
Method Summary
 void addGroup(Group g)
          add a group to the collection
 Group getGroup(String name)
          get a group by name
 int getGroupCount()
          get the number of groups in this collection
 Enumeration getGroups()
          get a enumeration of all groups in this collection
 String getName()
          get this collection's name
 void removeGroup(String name)
          remove a group from the collection by name
 void setName(String name)
          set this collection's name
 String toString()
           
 
Methods inherited from class com.infoengine.connector.Data
addMetaValue, equals, getMetaNames, getMetaValue, getMetaValues, hashCode, removeMetaValues, setMetaValue
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

name

private String name

_groups

private Vector _groups
Constructor Detail

Collection

public Collection()
create a new unnamed Collection


Collection

public Collection(String name)
create a new named Collection

Method Detail

setName

public void setName(String name)
set this collection's name

Parameters:
name - - new collection name

getName

public String getName()
get this collection's name


getGroup

public Group getGroup(String name)
get a group by name

Parameters:
name - - the group name
Returns:
the group corresponding to name or null if not found

addGroup

public void addGroup(Group g)
add a group to the collection

Parameters:
g - the group to add (does nothing if null)

removeGroup

public void removeGroup(String name)
remove a group from the collection by name

Parameters:
name - - the name of the group to remove

getGroups

public Enumeration getGroups()
get a enumeration of all groups in this collection

Returns:
group Enumeration

getGroupCount

public int getGroupCount()
get the number of groups in this collection

Returns:
The number of groups.

toString

public String toString()