Java Code Examples for android.provider.ContactsContract.CommonDataKinds.Im#PROTOCOL_ICQ

The following examples show how to use android.provider.ContactsContract.CommonDataKinds.Im#PROTOCOL_ICQ . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: ImMetadata.java    From ContactMerger with Apache License 2.0 6 votes vote down vote up
/**
 * Retrieve the Protocol instance for a given raw database value.
 * @param id The raw database value.
 * @return The corresponding Protocol instance, or null.
 */
public static Protocol byProtocolId(int id) {
    switch(id) {
    case Im.PROTOCOL_CUSTOM: return CUSTOM;
    case Im.PROTOCOL_AIM: return AIM;
    case Im.PROTOCOL_MSN: return MSN;
    case Im.PROTOCOL_YAHOO: return YAHOO;
    case Im.PROTOCOL_SKYPE: return SKYPE;
    case Im.PROTOCOL_QQ: return QQ;
    case Im.PROTOCOL_GOOGLE_TALK: return GOOGLE_TALK;
    case Im.PROTOCOL_ICQ: return ICQ;
    case Im.PROTOCOL_JABBER: return JABBER;
    case Im.PROTOCOL_NETMEETING: return NETMEETING;
    }
    return null;
}
 
Example 2
Source File: InstantMessagingAddress.java    From react-native-paged-contacts with MIT License 5 votes vote down vote up
private String getProtocolName(String protocolId, String customProtocol) {
    if (protocolId == null) {
        throw new InvalidCursorTypeException();
    }
    switch (Integer.valueOf(protocolId)) {
        case Im.PROTOCOL_AIM:
            return "AIM";
        case Im.PROTOCOL_MSN:
            return "MSN";
        case Im.PROTOCOL_YAHOO:
            return "Yahoo";
        case Im.PROTOCOL_SKYPE:
            return "Skype";
        case Im.PROTOCOL_QQ:
            return "QQ";
        case Im.PROTOCOL_GOOGLE_TALK:
            return "Google Talk";
        case Im.PROTOCOL_ICQ:
            return "ICQ";
        case Im.PROTOCOL_JABBER:
            return "Jabber";
        case Im.PROTOCOL_NETMEETING:
            return "NetMeeting";
        case Im.PROTOCOL_CUSTOM:
            return customProtocol;
        default:
            return "Other";

    }
}