public class SFSBuddyList extends java.lang.Object implements BuddyList
BuddyLists are managed by a SFSBuddyListManager
which is a component of the SFSZone
Constructor and Description |
---|
SFSBuddyList(java.lang.String ownerName) |
SFSBuddyList(java.lang.String ownerName,
BuddyListManager buddyListManager) |
Modifier and Type | Method and Description |
---|---|
Buddy |
addBuddy(Buddy buddy)
Used by the BuddyManager only.
|
void |
clearAll() |
boolean |
containsBuddy(java.lang.String buddyName)
Checks if a Buddy is contained in the BuddyList
|
java.util.List<Buddy> |
getBuddies()
Get a list of all Buddies in the BuddyList
|
Buddy |
getBuddy(java.lang.String buddyName)
Get a Buddy from the BuddyList by name
|
BuddyListManager |
getBuddyListManager()
Get a reference to the BuddyManager managing this BuddyList
|
User |
getOwner()
Get the User that owns this BuddyList
|
java.lang.String |
getOwnerName()
Get the name of the owner of this BuddyList
|
int |
getRuntimeSize()
Obtain the size of the BuddyList, including the temp buddies
|
int |
getSize()
Obtain the size of the BuddyList.
|
boolean |
isBuddyBlocked(java.lang.String buddyName)
Checks whether the specified Buddy is blocked in this BuddyList
|
boolean |
isEmpty()
Checks if the BuddyList is empty
|
boolean |
isFull()
Checks if the BuddyList is full
|
Buddy |
removeBuddy(java.lang.String buddyName)
Used by the BuddyManager only.
|
void |
setBuddyListManager(BuddyListManager buddyListManager) |
ISFSArray |
toSFSArray() |
java.lang.String |
toString() |
public SFSBuddyList(java.lang.String ownerName)
public SFSBuddyList(java.lang.String ownerName, BuddyListManager buddyListManager)
public Buddy addBuddy(Buddy buddy) throws SFSBuddyListException
BuddyList
addBuddy
in interface BuddyList
SFSBuddyListException
SFSBuddyApi.addBuddy(User, String, boolean, boolean, boolean)
public Buddy removeBuddy(java.lang.String buddyName)
BuddyList
removeBuddy
in interface BuddyList
SFSBuddyApi.removeBuddy(User, String, boolean, boolean)
public boolean containsBuddy(java.lang.String buddyName)
BuddyList
containsBuddy
in interface BuddyList
buddyName
- the Buddy namepublic boolean isBuddyBlocked(java.lang.String buddyName)
BuddyList
isBuddyBlocked
in interface BuddyList
buddyName
- the name of the Buddypublic int getSize()
BuddyList
public int getRuntimeSize()
BuddyList
getRuntimeSize
in interface BuddyList
public boolean isEmpty()
BuddyList
public boolean isFull()
BuddyList
public Buddy getBuddy(java.lang.String buddyName)
BuddyList
public java.util.List<Buddy> getBuddies()
BuddyList
getBuddies
in interface BuddyList
public BuddyListManager getBuddyListManager()
BuddyList
getBuddyListManager
in interface BuddyList
public void setBuddyListManager(BuddyListManager buddyListManager)
setBuddyListManager
in interface BuddyList
public java.lang.String getOwnerName()
BuddyList
getOwnerName
in interface BuddyList
public User getOwner()
BuddyList
public ISFSArray toSFSArray()
toSFSArray
in interface BuddyList
public java.lang.String toString()
toString
in class java.lang.Object