# HG changeset patch # User Ingo Weinzierl # Date 1310113578 0 # Node ID 9ff7e06bcb771820a619c6f04527e5cf6383ef24 # Parent 057cc0bf4aef18201976efcdadec23f6e894fe0c Artifacts and Collections now support the 'type' member of Outputs. flys-artifacts/trunk@2311 c6561f87-3c4e-4783-a992-168aeb5c3f6f diff -r 057cc0bf4aef -r 9ff7e06bcb77 flys-artifacts/ChangeLog --- a/flys-artifacts/ChangeLog Wed Jul 06 13:41:36 2011 +0000 +++ b/flys-artifacts/ChangeLog Fri Jul 08 08:26:18 2011 +0000 @@ -1,3 +1,12 @@ +2011-07-08 Ingo Weinzierl + + * src/main/java/de/intevation/flys/artifacts/WINFOArtifact.java: The + Outputs created while generating the DESCRIBE document will now have the + 'type' member set. + + * src/main/java/de/intevation/flys/collections/OutputParser.java: Read the + 'type' member from DESCRIBE document. + 2011-07-06 Ingo Weinzierl * doc/conf/artifacts/winfo.xml: Removed a typo. diff -r 057cc0bf4aef -r 9ff7e06bcb77 flys-artifacts/src/main/java/de/intevation/flys/artifacts/WINFOArtifact.java --- a/flys-artifacts/src/main/java/de/intevation/flys/artifacts/WINFOArtifact.java Wed Jul 06 13:41:36 2011 +0000 +++ b/flys-artifacts/src/main/java/de/intevation/flys/artifacts/WINFOArtifact.java Fri Jul 08 08:26:18 2011 +0000 @@ -240,7 +240,8 @@ Output o = new DefaultOutput( out.getName(), out.getDescription(), - out.getMimeType()); + out.getMimeType(), + out.getType()); Set outTypes = new HashSet(); diff -r 057cc0bf4aef -r 9ff7e06bcb77 flys-artifacts/src/main/java/de/intevation/flys/collections/OutputParser.java --- a/flys-artifacts/src/main/java/de/intevation/flys/collections/OutputParser.java Wed Jul 06 13:41:36 2011 +0000 +++ b/flys-artifacts/src/main/java/de/intevation/flys/collections/OutputParser.java Fri Jul 08 08:26:18 2011 +0000 @@ -112,8 +112,9 @@ String desc = out.getAttributeNS(uri, "description"); String mimetype = out.getAttributeNS(uri, "mime-type"); + String type = out.getAttributeNS(uri, "type"); - Output o = new DefaultOutput(name, desc, mimetype); + Output o = new DefaultOutput(name, desc, mimetype, type); outs.put(name, o); }