Example usage for com.google.common.collect HashMultimap create

List of usage examples for com.google.common.collect HashMultimap create

Introduction

In this page you can find the example usage for com.google.common.collect HashMultimap create.

Prototype

public static <K, V> HashMultimap<K, V> create() 

Source Link

Document

Creates a new, empty HashMultimap with the default initial capacities.

Usage

From source file:crawler.HTTPRequest.java

public HTTPRequest(URL url) {

    this.url = url;
    this.headers = HashMultimap.create();
    this.requestBody = "";

}

From source file:com.metabroadcast.common.intl.Countries.java

private static Multimap<Country, String> aliases() {
    Multimap<Country, String> map = HashMultimap.create();
    map.put(GB, "UK");
    return map;// w w w  .j  av  a2s. c  om
}

From source file:android.security.cts.SELinuxPolicyRule.java

public static SELinuxPolicyRule readRule(XmlPullParser xpp) throws IOException, XmlPullParserException {
    List<String> source_types = new ArrayList<String>();
    List<String> target_types = new ArrayList<String>();
    Multimap<String, String> obj_classes = HashMultimap.create();
    xpp.require(XmlPullParser.START_TAG, null, "avc_rule");
    String ruleName = xpp.getAttributeValue(null, "name");
    String ruleType = xpp.getAttributeValue(null, "type");
    while (xpp.next() != XmlPullParser.END_TAG) {
        if (xpp.getEventType() != XmlPullParser.START_TAG) {
            continue;
        }/*from w w w  . j  av a  2 s  .  c o m*/
        String name = xpp.getName();
        if (name.equals("type")) {
            if (xpp.getAttributeValue(null, "type").equals("source")) {
                source_types.add(readType(xpp));
            } else if (xpp.getAttributeValue(null, "type").equals("target")) {
                target_types.add(readType(xpp));
            } else {
                skip(xpp);
            }
        } else if (name.equals("obj_class")) {
            String obj_name = xpp.getAttributeValue(null, "name");
            List<String> perms = readObjClass(xpp);
            obj_classes.putAll(obj_name, perms);
        } else {
            skip(xpp);
        }
    }
    return new SELinuxPolicyRule(source_types, target_types, obj_classes, ruleName, ruleType);
}

From source file:com.ironiacorp.network.tool.nf.ArpDatabase.java

public ArpDatabase() {
    ypIM = HashMultimap.create();
    ypMI = HashMultimap.create();
}

From source file:org.janusgraph.graphdb.transaction.indexcache.ConcurrentIndexCache.java

public ConcurrentIndexCache() {
    this.map = HashMultimap.create();
}

From source file:org.linqs.psl.utils.dataloading.graph.Subgraph.java

public Subgraph() {
    entities = HashMultimap.create();
    relations = HashMultimap.create();
}

From source file:org.slc.sli.bulk.extract.lea.EntityToEdOrgCache.java

/**
 * Simple constructor that creates the internal cache.
 *//*from  w ww  .  j a  v  a2  s .  c om*/
public EntityToEdOrgCache() {
    cache = new HashMap<String, Set<String>>();
    inverse = HashMultimap.create();
}

From source file:prm4j.spec.finite.FSMVisitor.java

public FSMVisitor(Set<BaseEvent> baseEvents) {
    this.baseEvents = baseEvents;
    state2inducedEventSets = HashMultimap.create();
}

From source file:org.janusgraph.graphdb.transaction.indexcache.SimpleIndexCache.java

public SimpleIndexCache() {
    this.map = HashMultimap.create();
}

From source file:dbseer.comp.data.TransactionMap.java

public TransactionMap() {
    map = HashMultimap.create();
    syslogMap = new HashMap<Long, String>();
    minEndTime = Long.MAX_VALUE;//  www. j a v  a 2 s  . c o m
    maxEndTime = Long.MIN_VALUE;
    minSysLogTime = Long.MAX_VALUE;
    lastSysLogTime = 0;
}