FileDocCategorySizeDatePackage
SmileyResources.javaAPI DocAndroid 1.5 API2102Wed May 06 22:41:56 BST 2009com.google.android.util

SmileyResources

public class SmileyResources extends Object implements AbstractMessageParser.Resources
Resources for smiley parser.

Fields Summary
private HashMap
mSmileyToRes
private final com.google.android.util.AbstractMessageParser.TrieNode
smileys
Constructors Summary
public SmileyResources(String[] smilies, int[] smileyResIds)

param
smilies Smiley text, e.g. ":)", "8-)"
param
smileyResIds Resource IDs associated with the smileys.


                         
         
        for (int i = 0; i < smilies.length; i++) {
            TrieNode.addToTrie(smileys, smilies[i], "");
            mSmileyToRes.put(smilies[i], smileyResIds[i]);
        }
    
Methods Summary
public com.google.android.util.AbstractMessageParser.TrieNodegetAcronyms()

        return null;
    
public com.google.android.util.AbstractMessageParser.TrieNodegetDomainSuffixes()

        return null;
    
public java.util.SetgetSchemes()


       
        return null;
    
public intgetSmileyRes(java.lang.String smiley)
Looks up the resource id of a given smiley.

param
smiley The smiley to look up.
return
the resource id of the specified smiley, or -1 if no resource id is associated with it.

        Integer i = mSmileyToRes.get(smiley);
        if (i == null) {
            return -1;
        }
        return i.intValue();
    
public com.google.android.util.AbstractMessageParser.TrieNodegetSmileys()

        return smileys;