|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.skype.ipc.SidObject
com.skype.api.ContactGroup
public final class ContactGroup
Collects and manages Contacts related by type, status, or some other arbitrary criteria. SkypeKit recognizes two distinct ContactGroup flavors - "hardwired" and "custom". SkypeKit both defines the criteria for and dynamically manages all "hardwired" ContactGroups. Individual users explicitly create and manage all "custom" ContactGroups. "Hardwired" groups are primarily organizational tools, for example, they enable you to display a list of all Contacts awaiting authorization by you. "Custom" groups are also organizational tools, for example, they enable you to display a list of all Contacts in a particular geographical area or belonging to a particular professional association, social clubs, and so forth. Primarily, though, "custom" groups are functional tools that enable you to establish conference calls, group chats, and so forth. "Hardwired" ContactGroups are defined for and available to all users. SkypeKit determines membership in a particular "hardwired" group dynamically whenever a user invokes Skype.GetHardwiredContactGroup for that group. Subsequent changes to a Contact's status might result in its being added to (for example, the Contact is now authorized) or removed from (for example, the Contact is now removed or blocked) one or more "hardwired" groups. SkypeKit fires OnChange events for all affected ContractGroup instances. Essentially all ContactGroup methods related to explicitly adding and removing members and conversations from the group return false, and CanAdd and CanRemove additionally return a false result. "Custom" ContactGroups can be defined by a particular Skype user through the UI. Your UI should implement Creation, deletion and filtering contact list by custom contact groups, as well as adding and removing contacts in those groups. A Contact can belong to multiple non-mutually exclusive "hardwired" groups at the same time, for example, an authorized contact is typically in your "buddy" group, but a Contact cannot belong to CONTACTS_AUTHORIZED_BY_ME if they are awaiting authorization. Similarly, a Contact can belong to multiple "custom" groups and mutual exclusivity is typically not an issue.
| Nested Class Summary | |
|---|---|
static class |
ContactGroup.Property
Properties of the ContactGroup class |
static class |
ContactGroup.Type
The list of all possible ContactGroup types. |
| Field Summary | |
|---|---|
int |
mContactCount
|
int |
mCustomGroupId
|
java.lang.String |
mGivenDisplayName
|
int |
mOnlineContactCount
|
ContactGroup.Type |
mType
|
| Fields inherited from class com.skype.ipc.SidObject |
|---|
mSidCached, mSidOid, mSidRoot, mSidTimestamp |
| Constructor Summary | |
|---|---|
ContactGroup(int oid,
SidRoot root)
|
|
| Method Summary | |
|---|---|
void |
addContact(Contact contact)
Adds contact to a contact group. |
void |
addConversation(Conversation conversation)
Adds given conversation to the ContactGroup. |
boolean |
canAddContact(Contact contact)
Checks if the current user can add given contact to the ContactGroup. |
boolean |
canAddConversation(Conversation conversation)
Checks if the current user can add given conversation to the ContactGroup. |
boolean |
canRemoveContact()
Checks if the current user can remove given contact from the ContactGroup. |
boolean |
canRemoveConversation()
Checks if the current user can remove given conversation from the ContactGroup. |
boolean |
delete()
Removes the contact group. |
int |
getContactCount()
Number of contacts in the group. |
Contact[] |
getContacts()
Retrieves contact list. |
Conversation[] |
getConversations()
Returns list of conversations in the ContactGroup. |
int |
getCustomGroupId()
unique 32-bit ID for custom groups |
java.lang.String |
getGivenDisplayName()
change via ContactGroup.GiveDisplayname() |
int |
getOnlineContactCount()
number of contacts online in the group |
java.lang.String |
getPropertyAsString(ContactGroup.Property prop)
|
java.lang.String |
getPropertyAsString(int prop)
|
ContactGroup.Type |
getType()
ContactGroup.TYPE |
void |
giveDisplayName(java.lang.String name)
Setter for ContactGroup class GIVEN_DISPLAYNAME property. |
int |
moduleId()
|
void |
removeContact(Contact contact)
Removes contact from the ContactGroup. |
void |
removeConversation(Conversation conversation)
Removes given conversation from the ContactGroup. |
EnumConverting |
sidGetEnumProperty(PropertyEnumConverting prop)
|
int |
sidGetIntProperty(PropertyEnumConverting prop)
|
java.lang.String |
sidGetStringProperty(PropertyEnumConverting prop)
|
SidGetResponding |
sidMultiGet(ContactGroup.Property[] requested)
generic multiget of a list of Property |
static SidGetResponding[] |
sidMultiGet(ContactGroup.Property[] requested,
ContactGroup[] objects)
generic multiget of list of Property for a list of ContactGroup |
protected void |
sidOnChangedProperty(int propertyId,
int value,
java.lang.String svalue)
|
void |
sidSetProperty(PropertyEnumConverting prop,
int newValue)
|
void |
sidSetProperty(PropertyEnumConverting prop,
java.lang.String newValue)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public ContactGroup.Type mType
public int mCustomGroupId
public java.lang.String mGivenDisplayName
public int mContactCount
public int mOnlineContactCount
| Constructor Detail |
|---|
public ContactGroup(int oid,
SidRoot root)
| Method Detail |
|---|
public void giveDisplayName(java.lang.String name)
public boolean delete()
public Conversation[] getConversations()
public boolean canAddConversation(Conversation conversation)
public void addConversation(Conversation conversation)
public boolean canRemoveConversation()
public void removeConversation(Conversation conversation)
public Contact[] getContacts()
public boolean canAddContact(Contact contact)
public void addContact(Contact contact)
public boolean canRemoveContact()
public void removeContact(Contact contact)
public SidGetResponding sidMultiGet(ContactGroup.Property[] requested)
requested - the list of requested properties of ContactGroup
public static SidGetResponding[] sidMultiGet(ContactGroup.Property[] requested,
ContactGroup[] objects)
requested - the list of requested properties
public ContactGroup.Type getType()
public int getCustomGroupId()
public java.lang.String getGivenDisplayName()
public int getContactCount()
public int getOnlineContactCount()
public java.lang.String sidGetStringProperty(PropertyEnumConverting prop)
sidGetStringProperty in interface SidGetRespondingsidGetStringProperty in class SidObjectpublic int sidGetIntProperty(PropertyEnumConverting prop)
sidGetIntProperty in interface SidGetRespondingsidGetIntProperty in class SidObjectpublic EnumConverting sidGetEnumProperty(PropertyEnumConverting prop)
sidGetEnumProperty in interface SidGetRespondingsidGetEnumProperty in class SidObjectpublic java.lang.String getPropertyAsString(int prop)
public java.lang.String getPropertyAsString(ContactGroup.Property prop)
protected void sidOnChangedProperty(int propertyId,
int value,
java.lang.String svalue)
sidOnChangedProperty in class SidObject
public void sidSetProperty(PropertyEnumConverting prop,
java.lang.String newValue)
sidSetProperty in interface SidGetRespondingsidSetProperty in class SidObject
public void sidSetProperty(PropertyEnumConverting prop,
int newValue)
sidSetProperty in interface SidGetRespondingsidSetProperty in class SidObjectpublic int moduleId()
moduleId in class SidObject
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||