Mercurial > dive4elements > framework
diff artifacts/src/main/java/de/intevation/artifacts/ArtifactCollectionFactory.java @ 120:c030895edfcb
Added method to figure out TTL of a collection.
artifacts/trunk@1343 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Sascha L. Teichmann <sascha.teichmann@intevation.de> |
---|---|
date | Tue, 01 Mar 2011 16:07:25 +0000 |
parents | a1200c6ed048 |
children | db0d20440b92 |
line wrap: on
line diff
--- a/artifacts/src/main/java/de/intevation/artifacts/ArtifactCollectionFactory.java Tue Mar 01 15:58:09 2011 +0000 +++ b/artifacts/src/main/java/de/intevation/artifacts/ArtifactCollectionFactory.java Tue Mar 01 16:07:25 2011 +0000 @@ -40,6 +40,18 @@ * @param factoryNode the ConfigurationNode of this Factory */ void setup(Document config, Node factoryNode); + + /** + * Tells how long a collection should survive if it is + * not touched. This is put in the factory because + * life time is nothing a collection should handle it self. + * This method is only called once directly after the + * artifact is created. + * @param artifact The artifact to be rated. + * @param context The global context. + * @return time to live in ms. null means eternal. + */ + Long timeToLiveUntouched(ArtifactCollection collection, Object context); } // vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8 :