Mercurial > dive4elements > framework
comparison artifact-database/src/main/java/de/intevation/artifactdatabase/ArtifactCallContext.java @ 330:3168af23aec5
Added a CallContext.isInBackground() method to determine if an Artifact or a Collection has started a background thread and is currently locked.
artifacts/trunk@2666 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Ingo Weinzierl <ingo.weinzierl@intevation.de> |
---|---|
date | Wed, 07 Sep 2011 13:51:02 +0000 |
parents | a8a06bbe306c |
children | 089c6f7794b5 |
comparison
equal
deleted
inserted
replaced
329:666417d5781c | 330:3168af23aec5 |
---|---|
71 } | 71 } |
72 database.fromBackground(artifact, action); | 72 database.fromBackground(artifact, action); |
73 } | 73 } |
74 | 74 |
75 | 75 |
76 public boolean isInBackground() { | |
77 return database.getLockedIds().contains(artifact.getId()); | |
78 } | |
79 | |
80 | |
76 public Long getTimeToLive() { | 81 public Long getTimeToLive() { |
77 return artifact.getTTL(); | 82 return artifact.getTTL(); |
78 } | 83 } |
79 | 84 |
80 | 85 |