# HG changeset patch # User Sascha L. Teichmann # Date 1298995645 0 # Node ID c030895edfcb3bfe05c82d3ba3bf7736bf806910 # Parent 3bb121d5b0b734da2abcfdcac7251e89e17c48e9 Added method to figure out TTL of a collection. artifacts/trunk@1343 c6561f87-3c4e-4783-a992-168aeb5c3f6f diff -r 3bb121d5b0b7 -r c030895edfcb ChangeLog --- a/ChangeLog Tue Mar 01 15:58:09 2011 +0000 +++ b/ChangeLog Tue Mar 01 16:07:25 2011 +0000 @@ -1,3 +1,11 @@ +2011-03-01 Sascha L. Teichmann + + * artifacts/src/main/java/de/intevation/artifacts/ArtifactFactory.java: + Typo fix. + + * artifacts/src/main/java/de/intevation/artifacts/ArtifactCollectionFactory.java: + Added method to figure out TTL of a collection. + 2011-03-01 Ingo Weinzierl * artifact-database/src/main/java/de/intevation/artifactdatabase/DefaultArtifactCollection.java: diff -r 3bb121d5b0b7 -r c030895edfcb artifacts/src/main/java/de/intevation/artifacts/ArtifactCollectionFactory.java --- 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 : diff -r 3bb121d5b0b7 -r c030895edfcb artifacts/src/main/java/de/intevation/artifacts/ArtifactFactory.java --- a/artifacts/src/main/java/de/intevation/artifacts/ArtifactFactory.java Tue Mar 01 15:58:09 2011 +0000 +++ b/artifacts/src/main/java/de/intevation/artifacts/ArtifactFactory.java Tue Mar 01 16:07:25 2011 +0000 @@ -52,7 +52,7 @@ /** * Tells how long an artifact should survive if it is * not touched. This is put in the factory because - * life time is nothing a artifact should handle it self. + * life time is nothing an artifact should handle it self. * This method is only called once directly after the * artifact is created. * @param artifact The artifact to be rated.