# HG changeset patch # User Felix Wolfsteller # Date 1328267709 0 # Node ID f34bbb5fb6d28591825505217d823753bd64e1a2 # Parent 8ab010967f7869c9d0aec67abe0f4daf73a611ba Added TODO and handle dynamic data of unknown type. flys-client/trunk@3892 c6561f87-3c4e-4783-a992-168aeb5c3f6f diff -r 8ab010967f78 -r f34bbb5fb6d2 flys-client/ChangeLog --- a/flys-client/ChangeLog Fri Feb 03 08:30:58 2012 +0000 +++ b/flys-client/ChangeLog Fri Feb 03 11:15:09 2012 +0000 @@ -1,3 +1,8 @@ +2012-02-03 Felix Wolfsteller + + * src/main/java/de/intevation/flys/client/server/ArtifactDescriptionFactory.java: + Added TODO and create defaultdata for unknown typed dynamic data. + 2012-02-03 Felix Wolfsteller * src/main/java/de/intevation/flys/client/client/ui/AbstractUIProvider.java diff -r 8ab010967f78 -r f34bbb5fb6d2 flys-client/src/main/java/de/intevation/flys/client/server/ArtifactDescriptionFactory.java --- a/flys-client/src/main/java/de/intevation/flys/client/server/ArtifactDescriptionFactory.java Fri Feb 03 08:30:58 2012 +0000 +++ b/flys-client/src/main/java/de/intevation/flys/client/server/ArtifactDescriptionFactory.java Fri Feb 03 11:15:09 2012 +0000 @@ -136,6 +136,8 @@ logger.debug("Create new IntegerRangeData object for: " + name); logger.debug("New Data is from type: " + type); + // TODO replace with DataFactory. + if (type == null || type.length() == 0) { NodeList choices = ClientProtocolUtils.getItemNodes(d); DataItem[] dataItems = extractCurrentDataItems(choices); @@ -179,6 +181,15 @@ list.add(new IntegerOptionsData(name, label, opts)); } + else { + logger.warn("Unrecognized Dynamic data type."); + NodeList choices = ClientProtocolUtils.getItemNodes(d); + DataItem[] dataItems = extractCurrentDataItems(choices); + DataItem def = extractDefaultDataItem(d); + + list.add(new DefaultData(name, label, null, dataItems, def)); + } + } return list;