MCPcopy Create free account
hub / github.com/boxbeam/RedLib / update

Method update

src/redempt/redlib/sql/SQLCache.java:114–123  ·  view source on GitHub ↗

Updates the cached value for a row @param value The value to cache @param primaryKeys The primary keys used to mutate the row

(Object value, Object... primaryKeys)

Source from the content-addressed store, hash-verified

112 * @param primaryKeys The primary keys used to mutate the row
113 */
114 public synchronized void update(Object value, Object... primaryKeys) {
115 checkKeys(primaryKeys);
116 SQLCacheEntry entry = new SQLCacheEntry(primaryKeys);
117 if (!cache.containsKey(entry)) {
118 return;
119 }
120 cache.remove(entry);
121 modified.add(entry);
122 cache.put(entry, value);
123 }
124
125 /**
126 * Gets the cached value for a row, or queries it if it has not been cached yet

Callers 2

setBlockMethod · 0.45
restoreMethod · 0.45

Calls 3

checkKeysMethod · 0.95
removeMethod · 0.65
addMethod · 0.45

Tested by

no test coverage detected