MCPcopy Create free account
hub / github.com/DeNA/PacketProxy / getDefaultCache

Method getDefaultCache

src/main/java/core/org/xbill/DNS/Lookup.java:124–133  ·  view source on GitHub ↗

Gets the Cache that will be used as the default for the specified class by future Lookups. @param dclass The class whose cache is being retrieved. @return The default cache for the specified class.

(int dclass)

Source from the content-addressed store, hash-verified

122 * @return The default cache for the specified class.
123 */
124public static synchronized Cache
125getDefaultCache(int dclass) {
126 DClass.check(dclass);
127 Cache c = (Cache) defaultCaches.get(Mnemonic.toInteger(dclass));
128 if (c == null) {
129 c = new Cache(dclass);
130 defaultCaches.put(Mnemonic.toInteger(dclass), c);
131 }
132 return c;
133}
134
135/**
136 * Sets the Cache to be used as the default for the specified class by future

Callers 1

LookupMethod · 0.95

Calls 4

checkMethod · 0.95
toIntegerMethod · 0.95
getMethod · 0.45
putMethod · 0.45

Tested by

no test coverage detected