diff artifact-database/src/main/java/de/intevation/artifactdatabase/Backend.java @ 281:942a54670a72

Made the TTL of a Collection retrievable via getter method. artifacts/trunk@2174 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Ingo Weinzierl <ingo.weinzierl@intevation.de>
date Tue, 21 Jun 2011 10:57:03 +0000
parents e92d5944fe4b
children b0a949d3fe09
line wrap: on
line diff
--- a/artifact-database/src/main/java/de/intevation/artifactdatabase/Backend.java	Fri Jun 17 07:40:20 2011 +0000
+++ b/artifact-database/src/main/java/de/intevation/artifactdatabase/Backend.java	Tue Jun 21 10:57:03 2011 +0000
@@ -1036,7 +1036,7 @@
                 }
 
                 collection[0] = factory.createCollection(
-                    identifier, name, creationTime, attribute, context);
+                    identifier, name, creationTime, ttl, attribute, context);
 
                 return true;
             }
@@ -1078,12 +1078,14 @@
                     new Date(result.getTimestamp(5).getTime());
                 Document attr         =
                     XMLUtils.fromByteArray(result.getBytes(6), true);
+                long ttl              = result.getLong(7);
 
                 ArtifactCollection collection =
                     collectionFactory.createCollection(
                         collectionId,
                         collectionName,
                         creationTime,
+                        ttl,
                         attr,
                         context);
 
@@ -1140,12 +1142,14 @@
                     Date   creationTime         =
                         new Date(result.getTimestamp(3).getTime());
                     String userIdentifier       = result.getString(4);
+                    long   ttl                  = result.getLong(5);
 
                     ArtifactCollection collection =
                         collectionFactory.createCollection(
                             collectionIdentifier,
                             collectionName,
                             creationTime,
+                            ttl,
                             data,
                             context);
 

http://dive4elements.wald.intevation.org