net.sourceforge.mflow.impl
Class ContactGroupImpl

java.lang.Object
  extended bynet.sourceforge.mflow.impl.ContactGroupImpl
All Implemented Interfaces:
ContactGroup

public class ContactGroupImpl
extends java.lang.Object
implements ContactGroup

A collection of Contacts, with an optional name

Version:
$Revision: 1.4 $
Author:
David Carr
To Do:
remove extension of arraylist

Method Summary
 boolean add(Contact c)
          Adds the specified contact to the ContactGroup
 boolean add(ContactGroup cg)
          Adds the specified contact group to the ContactGroup
 boolean addAll(java.util.List list)
          Adds the contents of the specified List to the ContactGroup
 Contact[] getContacts()
           
 ContactGroup[] getGroups()
           
 java.lang.String getName()
          Accessor for the name
 void setName(java.lang.String name)
          Mutator for the name
 int size()
           
 java.lang.String toString()
          Converts this ContactGroup into a String form
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

getName

public java.lang.String getName()
Accessor for the name

Specified by:
getName in interface ContactGroup
Returns:
the name

setName

public void setName(java.lang.String name)
Mutator for the name

Specified by:
setName in interface ContactGroup
Parameters:
name - the new name

add

public boolean add(Contact c)
Description copied from interface: ContactGroup
Adds the specified contact to the ContactGroup

Specified by:
add in interface ContactGroup
Parameters:
c - The contact to add.
Returns:
true if the add resulted in a change, false if it did not

add

public boolean add(ContactGroup cg)
Description copied from interface: ContactGroup
Adds the specified contact group to the ContactGroup

Specified by:
add in interface ContactGroup
Parameters:
cg - The contact group to add.
Returns:
true if the add resulted in a change, false if it did not

addAll

public boolean addAll(java.util.List list)
Description copied from interface: ContactGroup
Adds the contents of the specified List to the ContactGroup

Specified by:
addAll in interface ContactGroup
Parameters:
list - the List to add the contents of
Returns:
true if the addAll resulted in a change, false if it did not

toString

public java.lang.String toString()
Converts this ContactGroup into a String form

Overrides:
toString in class java.lang.Object
Returns:
a String representation of this ContactGroup

getContacts

public Contact[] getContacts()
Specified by:
getContacts in interface ContactGroup
Returns:
all of the contacts in the group

getGroups

public ContactGroup[] getGroups()
Specified by:
getGroups in interface ContactGroup
Returns:
all of the contact groups contained within the group

size

public int size()
Specified by:
size in interface ContactGroup
Returns:
the number of conntacts and/or contact groups contained


Copyright © 2002-2004 MFlow Group. All Rights Reserved.