Changeset 30532 in osm for applications/editors/josm/plugins/imagerycache
- Timestamp:
- 2014-07-14T04:18:06+02:00 (11 years ago)
- Location:
- applications/editors/josm/plugins/imagerycache
- Files:
-
- 12 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/imagerycache/.settings/org.eclipse.jdt.core.prefs
r30416 r30532 1 1 eclipse.preferences.version=1 2 org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=disabled 3 org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore 4 org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull 5 org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault 6 org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable 7 org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled 2 8 org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled 3 9 org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7 4 10 org.eclipse.jdt.core.compiler.compliance=1.7 11 org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning 5 12 org.eclipse.jdt.core.compiler.problem.assertIdentifier=error 13 org.eclipse.jdt.core.compiler.problem.autoboxing=ignore 14 org.eclipse.jdt.core.compiler.problem.comparingIdentical=warning 15 org.eclipse.jdt.core.compiler.problem.deadCode=warning 16 org.eclipse.jdt.core.compiler.problem.deprecation=warning 17 org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled 18 org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled 19 org.eclipse.jdt.core.compiler.problem.discouragedReference=warning 20 org.eclipse.jdt.core.compiler.problem.emptyStatement=warning 6 21 org.eclipse.jdt.core.compiler.problem.enumIdentifier=error 22 org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=ignore 23 org.eclipse.jdt.core.compiler.problem.fallthroughCase=ignore 24 org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled 25 org.eclipse.jdt.core.compiler.problem.fieldHiding=warning 26 org.eclipse.jdt.core.compiler.problem.finalParameterBound=warning 27 org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=warning 28 org.eclipse.jdt.core.compiler.problem.forbiddenReference=error 29 org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=warning 30 org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled 31 org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=warning 32 org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=warning 33 org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=ignore 34 org.eclipse.jdt.core.compiler.problem.localVariableHiding=ignore 35 org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=warning 36 org.eclipse.jdt.core.compiler.problem.missingDefaultCase=ignore 37 org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=ignore 38 org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=disabled 39 org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=ignore 40 org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=ignore 41 org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled 42 org.eclipse.jdt.core.compiler.problem.missingSerialVersion=ignore 43 org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=ignore 44 org.eclipse.jdt.core.compiler.problem.noEffectAssignment=warning 45 org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=warning 46 org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore 47 org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning 48 org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=error 49 org.eclipse.jdt.core.compiler.problem.nullReference=warning 50 org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error 51 org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning 52 org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning 53 org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore 54 org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=ignore 55 org.eclipse.jdt.core.compiler.problem.potentialNullReference=ignore 56 org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=ignore 57 org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning 58 org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning 59 org.eclipse.jdt.core.compiler.problem.redundantNullCheck=ignore 60 org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=ignore 61 org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=ignore 62 org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore 63 org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore 64 org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled 65 org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning 66 org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled 67 org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled 68 org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=disabled 69 org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore 70 org.eclipse.jdt.core.compiler.problem.typeParameterHiding=warning 71 org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=enabled 72 org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning 73 org.eclipse.jdt.core.compiler.problem.unclosedCloseable=warning 74 org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore 75 org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=warning 76 org.eclipse.jdt.core.compiler.problem.unnecessaryElse=ignore 77 org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=ignore 78 org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore 79 org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=ignore 80 org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=enabled 81 org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=enabled 82 org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled 83 org.eclipse.jdt.core.compiler.problem.unusedImport=warning 84 org.eclipse.jdt.core.compiler.problem.unusedLabel=warning 85 org.eclipse.jdt.core.compiler.problem.unusedLocal=warning 86 org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=warning 87 org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore 88 org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled 89 org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled 90 org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled 91 org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=warning 92 org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore 93 org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning 94 org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning 7 95 org.eclipse.jdt.core.compiler.source=1.7 -
applications/editors/josm/plugins/imagerycache/src/org/mapdb/AsyncWriteEngine.java
r29484 r30532 49 49 protected Throwable writerFailedException = null; 50 50 51 52 protected final LongConcurrentHashMap<Fun.Tuple2<Object,Serializer>> items = new LongConcurrentHashMap<Fun.Tuple2<Object, Serializer>>(); 51 protected final LongConcurrentHashMap<Fun.Tuple2<Object,Serializer<Object>>> items = new LongConcurrentHashMap<>(); 53 52 54 53 protected final Thread newRecidsThread = new Thread("MapDB prealloc #"+threadNum){ … … 73 72 74 73 for(;;){ 75 LongMap.LongMapIterator<Fun.Tuple2<Object,Serializer>> iter = items.longMapIterator(); 74 LongMap.LongMapIterator<Fun.Tuple2<Object,Serializer<Object>>> iter = items.longMapIterator(); 76 75 77 76 if(!iter.moveToNext()){ … … 87 86 while(iter.moveToNext()){ 88 87 long recid = iter.key(); 89 Fun.Tuple2<Object,Serializer> value = iter.value(); 88 Fun.Tuple2<Object,Serializer<Object>> value = iter.value(); 90 89 if(value.a==DELETED){ 91 90 AsyncWriteEngine.super.delete(recid, value.b); … … 107 106 Utils.lock(writeLocks,recid); 108 107 try{ 109 Fun.Tuple2<Object,Serializer> value = iter.value(); 108 Fun.Tuple2<Object,Serializer<Object>> value = iter.value(); 110 109 if(value.a==DELETED){ 111 110 AsyncWriteEngine.super.delete(recid, value.b); … … 165 164 } 166 165 166 @SuppressWarnings("unchecked") 167 167 @Override 168 168 public <A> A get(long recid, Serializer<A> serializer) { … … 172 172 try{ 173 173 checkState(); 174 Fun.Tuple2<Object,Serializer> item = items.get(recid); 174 Fun.Tuple2<Object,Serializer<Object>> item = items.get(recid); 175 175 if(item!=null){ 176 176 if(item.a == DELETED) return null; … … 187 187 } 188 188 189 @SuppressWarnings({ "rawtypes", "unchecked" }) 189 190 @Override 190 191 public <A> void update(long recid, A value, Serializer<A> serializer) { … … 206 207 } 207 208 209 @SuppressWarnings({ "unchecked", "rawtypes" }) 208 210 @Override 209 211 public <A> boolean compareAndSwap(long recid, A expectedOldValue, A newValue, Serializer<A> serializer) { … … 212 214 try{ 213 215 checkState(); 214 Fun.Tuple2<Object, Serializer> existing = items.get(recid); 216 Fun.Tuple2<Object, Serializer<Object>> existing = items.get(recid); 215 217 A oldValue = existing!=null? (A) existing.a : super.get(recid, serializer); 216 218 if(oldValue == expectedOldValue || (oldValue!=null && oldValue.equals(expectedOldValue))){ … … 226 228 } 227 229 230 @SuppressWarnings("unchecked") 228 231 @Override 229 232 public <A> void delete(long recid, Serializer<A> serializer) { … … 245 248 shutdownCondition.await(); 246 249 247 248 250 super.close(); 249 251 } catch (InterruptedException e) { … … 251 253 } 252 254 } 253 254 255 255 256 256 protected WeakReference<Engine> parentEngineWeakRef = null; … … 302 302 } 303 303 } 304 305 304 } -
applications/editors/josm/plugins/imagerycache/src/org/mapdb/BTreeKeySerializer.java
r29484 r30532 18 18 static final class BasicKeySerializer extends BTreeKeySerializer<Object> { 19 19 20 protected final Serializer defaultSerializer; 20 protected final Serializer<Object> defaultSerializer; 21 21 22 BasicKeySerializer(Serializer defaultSerializer) { 22 BasicKeySerializer(Serializer<Object> defaultSerializer) { 23 23 this.defaultSerializer = defaultSerializer; 24 24 } -
applications/editors/josm/plugins/imagerycache/src/org/mapdb/BTreeMap.java
r29484 r30532 275 275 } 276 276 277 278 277 protected final Serializer<BNode> nodeSerializer = new Serializer<BNode>() { 279 278 @Override … … 298 297 } 299 298 } 300 301 } 302 299 } 303 300 304 301 final boolean left = value.keys()[0] == null; 305 302 final boolean right = value.keys()[value.keys().length-1] == null; 306 307 303 308 304 final int header; … … 334 330 } 335 331 336 337 338 332 out.write(header); 339 333 out.write(value.keys().length); … … 346 340 Utils.packLong(out, child); 347 341 } 348 349 350 342 351 343 keySerializer.serialize(out,left?1:0, -
applications/editors/josm/plugins/imagerycache/src/org/mapdb/Bind.java
r29363 r30532 4 4 import java.util.Map; 5 5 import java.util.NavigableSet; 6 import java.util.Set;7 6 import java.util.concurrent.ConcurrentMap; 8 7 … … 21 20 public Iterator<K1> iterator() { 22 21 //use range query to get all values 22 @SuppressWarnings("unchecked") 23 23 final Iterator<Fun.Tuple2<K2,K1>> iter = 24 ((NavigableSet)secondaryKeys) //cast is workaround for generics24 secondaryKeys 25 25 .subSet( 26 Fun.t2(secondaryKey,null), //NULL represents lower bound, everything is larger than null 27 Fun.t2(secondaryKey,Fun.HI) // HI is upper bound everything is smaller then HI 26 Fun.t2(secondaryKey,(K1)null), //NULL represents lower bound, everything is larger than null 27 Fun.t2(secondaryKey,(K1)Fun.HI) // HI is upper bound everything is smaller then HI 28 28 ).iterator(); 29 29 … … 59 59 } 60 60 61 public static void size(MapWithModificationListener map, final Atomic.Long size){ 61 public static <K,V> void size(MapWithModificationListener<K, V> map, final Atomic.Long size){ 62 62 //set initial value first if necessary 63 63 if(size.get() == 0 && map.isEmpty()) 64 64 size.set(map.size()); //TODO long overflow? 65 65 66 map.addModificationListener(new MapListener() { 66 map.addModificationListener(new MapListener<K, V>() { 67 67 @Override 68 68 public void update(Object key, Object oldVal, Object newVal) { -
applications/editors/josm/plugins/imagerycache/src/org/mapdb/CacheLRU.java
r29484 r30532 78 78 Utils.lock(locks,recid); 79 79 Engine engine = getWrappedEngine(); 80 LongMap cache2 = checkClosed(cache); 80 LongMap<Object> cache2 = checkClosed(cache); 81 81 Object oldValue = cache.get(recid); 82 82 if(oldValue == expectedOldValue || oldValue.equals(expectedOldValue)){ … … 94 94 } 95 95 } 96 97 96 98 97 @SuppressWarnings("rawtypes") -
applications/editors/josm/plugins/imagerycache/src/org/mapdb/EngineWrapper.java
r29484 r30532 14 14 * limitations under the License. 15 15 */ 16 17 16 package org.mapdb; 18 19 17 20 18 import java.io.IOError; … … 26 24 import java.util.concurrent.ConcurrentLinkedQueue; 27 25 28 29 26 /** 30 27 * EngineWrapper adapter. It implements all methods on Engine interface. … … 293 290 } 294 291 295 296 292 /** 297 293 * check if Record Instances were not modified while in cache. 298 294 * Usuful to diagnose strange problems with Instance Cache. 299 295 */ 300 public static class ImmutabilityCheckEngine extends EngineWrapper{ 301 302 protected static class Item { 303 final Serializer serializer; 304 final Objectitem;296 public static class ImmutabilityCheckEngine extends EngineWrapper { 297 298 protected static class Item<E> { 299 final Serializer<E> serializer; 300 final E item; 305 301 final int oldChecksum; 306 302 307 public Item(Serializer serializer, Objectitem) {303 public Item(Serializer<E> serializer, E item) { 308 304 if(item==null || serializer==null) throw new AssertionError("null"); 309 305 this.serializer = serializer; … … 313 309 } 314 310 315 private int checksum(){ 311 private int checksum() { 316 312 try { 317 313 DataOutput2 out = new DataOutput2(); … … 324 320 } 325 321 326 void check(){ 322 void check() { 327 323 int newChecksum = checksum(); 328 324 if(oldChecksum!=newChecksum) throw new AssertionError("Record instance was modified: \n "+item+"\n "+serializer); … … 330 326 } 331 327 332 protected LongConcurrentHashMap<Item> items = new LongConcurrentHashMap< Item>();328 protected LongConcurrentHashMap<Item<?>> items = new LongConcurrentHashMap<>(); 333 329 334 330 protected ImmutabilityCheckEngine(Engine engine) { … … 338 334 @Override 339 335 public <A> A get(long recid, Serializer<A> serializer) { 340 Item item = items.get(recid); 336 Item<?> item = items.get(recid); 341 337 if(item!=null) item.check(); 342 338 A ret = super.get(recid, serializer); 343 if(ret!=null) items.put(recid, new Item(serializer,ret)); 339 if(ret!=null) items.put(recid, new Item<A>(serializer,ret)); 344 340 return ret; 345 341 } … … 348 344 public <A> long put(A value, Serializer<A> serializer) { 349 345 long ret = super.put(value, serializer); 350 if(value!=null) items.put(ret, new Item(serializer,value)); 346 if(value!=null) items.put(ret, new Item<A>(serializer,value)); 351 347 return ret; 352 348 } … … 354 350 @Override 355 351 public <A> void update(long recid, A value, Serializer<A> serializer) { 356 Item item = items.get(recid); 352 Item<?> item = items.get(recid); 357 353 if(item!=null) item.check(); 358 354 super.update(recid, value, serializer); 359 if(value!=null) items.put(recid, new Item(serializer,value)); 360 } 361 355 if(value!=null) items.put(recid, new Item<A>(serializer,value)); 356 } 357 358 @SuppressWarnings({ "unchecked", "rawtypes" }) 362 359 @Override 363 360 public <A> boolean compareAndSwap(long recid, A expectedOldValue, A newValue, Serializer<A> serializer) { 364 Item item = items.get(recid); 361 Item<?> item = items.get(recid); 365 362 if(item!=null) item.check(); 366 363 boolean ret = super.compareAndSwap(recid, expectedOldValue, newValue, serializer); … … 372 369 public void close() { 373 370 super.close(); 374 for(Iterator<Item> iter = items.valuesIterator(); iter.hasNext();){ 371 for(Iterator<Item<?>> iter = items.valuesIterator(); iter.hasNext();){ 375 372 iter.next().check(); 376 373 } … … 378 375 } 379 376 } 380 381 377 382 378 /** Engine wrapper with all methods synchronized on global lock, useful to diagnose concurrency issues.*/ … … 442 438 } 443 439 } 444 445 440 } -
applications/editors/josm/plugins/imagerycache/src/org/mapdb/Queues.java
r29484 r30532 40 40 } 41 41 42 @SuppressWarnings("unchecked") 42 43 @Override 43 44 public Node<E> deserialize(DataInput in, int available) throws IOException { … … 71 72 protected static final class Node<E>{ 72 73 74 @SuppressWarnings({ "unchecked", "rawtypes" }) 73 75 protected static final Node EMPTY = new Node(0L, null); 74 76 … … 302 304 } 303 305 306 @SuppressWarnings("unchecked") 304 307 static <E> Stack<E> getStack(Engine engine, Serializer<Serializer> serializerSerializer, long rootRecid){ 305 308 StackRoot root = engine.get(rootRecid, new StackRootSerializer(serializerSerializer)); … … 323 326 } 324 327 328 @SuppressWarnings("unchecked") 325 329 @Override 326 330 public boolean add(E item){ … … 337 341 } 338 342 343 @SuppressWarnings("unchecked") 339 344 @Override 340 345 public E poll(){ … … 416 421 } 417 422 423 @SuppressWarnings("unchecked") 418 424 static <E> long createQueue(Engine engine, Serializer<Serializer> serializerSerializer, Serializer<E> serializer){ 419 425 long headerRecid = engine.put(0L, Serializer.LONG_SERIALIZER); … … 426 432 } 427 433 428 434 @SuppressWarnings("unchecked") 429 435 static <E> Queue<E> getQueue(Engine engine, Serializer<Serializer> serializerSerializer, long rootRecid){ 430 436 QueueRoot root = engine.get(rootRecid, new QueueRootSerializer(serializerSerializer)); … … 439 445 protected final long size; 440 446 447 @SuppressWarnings("unchecked") 441 448 public CircularQueue(Engine engine, Serializer serializer, long headRecid, long headInsertRecid, long size) { 442 449 super(engine, serializer, headRecid); … … 445 452 } 446 453 454 @SuppressWarnings("unchecked") 447 455 @Override 448 456 public boolean add(Object o) { … … 545 553 } 546 554 555 @SuppressWarnings({ "rawtypes", "unchecked" }) 547 556 static <E> long createCircularQueue(Engine engine, Serializer<Serializer> serializerSerializer, Serializer<E> serializer, long size){ 548 557 if(size<2) throw new IllegalArgumentException(); -
applications/editors/josm/plugins/imagerycache/src/org/mapdb/SerializerBase.java
r29484 r30532 354 354 /** classes bellow need object stack, so initialize it if not alredy initialized*/ 355 355 if (objectStack == null) { 356 objectStack = new FastArrayList(); 356 objectStack = new FastArrayList<>(); 357 357 objectStack.add(obj); 358 358 } … … 1065 1065 1066 1066 if (objectStack == null) 1067 objectStack = new FastArrayList(); 1067 objectStack = new FastArrayList<>(); 1068 1068 int oldObjectStackSize = objectStack.size(); 1069 1069 … … 1112 1112 break; 1113 1113 case SERIALIZER_COMPRESSION_WRAPPER: 1114 ret = CompressLZF.CompressionWrapper((Serializer) deserialize(is, objectStack)); 1114 ret = CompressLZF.CompressionWrapper((Serializer<?>) deserialize(is, objectStack)); 1115 1115 break; 1116 1116 default: -
applications/editors/josm/plugins/imagerycache/src/org/mapdb/SerializerPojo.java
r29363 r30532 542 542 static{ 543 543 try{ 544 Class clazz = Class.forName("sun.reflect.ReflectionFactory"); 544 Class<?> clazz = Class.forName("sun.reflect.ReflectionFactory"); 545 545 if(clazz!=null){ 546 546 Method getReflectionFactory = clazz.getMethod("getReflectionFactory"); … … 582 582 * If non of these works we fallback into usual reflection which requires an no-arg constructor 583 583 */ 584 @SuppressWarnings("restriction") 584 @SuppressWarnings({ "restriction", "unchecked" }) 585 585 protected <T> T createInstanceSkippinkConstructor(Class<T> clazz) 586 586 throws NoSuchMethodException, InvocationTargetException, IllegalAccessException, InstantiationException { -
applications/editors/josm/plugins/imagerycache/src/org/mapdb/SnapshotEngine.java
r29484 r30532 36 36 protected final ReentrantReadWriteLock snapshotsLock = new ReentrantReadWriteLock(); 37 37 38 @SuppressWarnings("unchecked") 38 39 @Override 39 40 public <A> long put(A value, Serializer<A> serializer) { … … 50 51 } 51 52 53 @SuppressWarnings("unchecked") 52 54 @Override 53 55 public <A> boolean compareAndSwap(long recid, A expectedOldValue, A newValue, Serializer<A> serializer) { … … 66 68 } 67 69 70 @SuppressWarnings("unchecked") 68 71 @Override 69 72 public <A> void update(long recid, A value, Serializer<A> serializer) { … … 85 88 } 86 89 90 @SuppressWarnings("unchecked") 87 91 @Override 88 92 public <A> void delete(long recid, Serializer<A> serializer) { … … 130 134 131 135 136 @SuppressWarnings("unchecked") 132 137 @Override 133 138 public <A> A get(long recid, Serializer<A> serializer) { -
applications/editors/josm/plugins/imagerycache/src/org/mapdb/TxMaker.java
r29363 r30532 11 11 public class TxMaker { 12 12 13 @SuppressWarnings("unchecked") 13 14 protected static final Fun.Tuple2<Object, Serializer> DELETED = new Fun.Tuple2(null, Serializer.STRING_SERIALIZER); 14 15 … … 62 63 protected Set<Long> newItems = new LinkedHashSet<Long>(); 63 64 64 65 65 protected TxEngine(Engine engine) { 66 66 super(engine); … … 79 79 } 80 80 81 @SuppressWarnings("unchecked") 81 82 @Override 82 83 public <A> A get(long recid, Serializer<A> serializer) { … … 93 94 } 94 95 96 @SuppressWarnings({ "rawtypes", "unchecked" }) 95 97 @Override 96 98 public <A> void update(long recid, A value, Serializer<A> serializer) { … … 128 130 } 129 131 132 @SuppressWarnings({ "unchecked", "rawtypes" }) 130 133 @Override 131 134 public void commit() { … … 144 147 engine.commit(); 145 148 } 146 147 149 } 148 150 … … 163 165 newItems = null; 164 166 } 165 166 167 } 167 168 … … 171 172 } 172 173 } 173 174 175 174 }
Note:
See TracChangeset
for help on using the changeset viewer.