diff --git a/src/fr/devinsy/xidyn/presenters/DomPresenterCore.java b/src/fr/devinsy/xidyn/presenters/DomPresenterCore.java index a239b73..1614517 100644 --- a/src/fr/devinsy/xidyn/presenters/DomPresenterCore.java +++ b/src/fr/devinsy/xidyn/presenters/DomPresenterCore.java @@ -171,59 +171,6 @@ public class DomPresenterCore return result; } - /** - * Merge attributes. - * - * @param target - * the target - * @param source - * the source - * @return the tag attributes - */ - private static TagAttributes mergeAttributes(final TagAttributes target, final TagAttributes source) - { - TagAttributes result; - - // - if (target == null) - { - result = source; - } - else if (source == null) - { - result = target; - } - else - { - result = new TagAttributes(target); - - Iterator> iterator = source.entrySet().iterator(); - - while (iterator.hasNext()) - { - Map.Entry attribute = iterator.next(); - - String currentValue = target.get(attribute.getKey()); - - if (currentValue == null) - { - result.put(attribute.getKey(), attribute.getValue()); - } - else if (attribute.getKey().equals("style")) - { - result.put(attribute.getKey(), currentValue + attribute.getValue()); - } - else - { - result.put(attribute.getKey(), attribute.getValue()); - } - } - } - - // - return result; - } - /** * Process. * @@ -373,42 +320,6 @@ public class DomPresenterCore logger.debug("process - ended"); } - /** - * Process attributes. - * - * @param attrs - * the attrs - * @return the string buffer - */ - private static StringBuffer processAttributes(final NamedNodeMap attrs) - { - StringBuffer result; - - result = processAttributes(attrs, null, null, ""); - - // - return result; - } - - /** - * Process attributes. - * - * @param attrs - * the attrs - * @param dataAttributes - * the data attributes - * @return the string buffer - */ - private static StringBuffer processAttributes(final NamedNodeMap attrs, final TagAttributes dataAttributes) - { - StringBuffer result; - - result = processAttributes(attrs, dataAttributes, ""); - - // - return result; - } - /** * Process attributes. * @@ -482,46 +393,6 @@ public class DomPresenterCore return result; } - /** - * Process attributes. - * - * @param attrs - * the attrs - * @param dataAttributes - * the data attributes - * @param namedDataAttributes - * the named data attributes - * @param suffix - * the suffix - * @return the string buffer - */ - private static StringBuffer processAttributes(final NamedNodeMap attrs, final TagAttributes dataAttributes, final TagAttributes namedDataAttributes, final String suffix) - { - StringBuffer result; - - result = processAttributes(attrs, mergeAttributes(dataAttributes, namedDataAttributes), suffix); - - // - return result; - } - - /** - * Process children. - * - * @param result - * the result - * @param node - * the node - * @param datas - * the datas - * @throws IOException - * the exception - */ - private static void processChildren(final Appendable result, final Node node, final TagDataListById datas) throws IOException - { - processChildren(result, node, datas, ""); - } - /** * Process children. * @@ -664,23 +535,6 @@ public class DomPresenterCore } } - /** - * TODO remove?. - * - * @param result - * the result - * @param node - * the node - * @param datas - * the datas - * @throws IOException - * the exception - */ - private static void processElementBasically(final Appendable result, final Node node, final TagDataListById datas) throws IOException - { - processElementBasically(result, node, datas, ""); - } - /** * Process element basically. * @@ -727,28 +581,6 @@ public class DomPresenterCore logger.debug("processElementBasically - ended"); } - /** - * Processes a node that has dynamic content. Calls the appropriate code - * generator method, depending on the tag. - * - * @param result - * the result - * @param node - * Current node. - * @param attrs - * The tag attributes. - * @param idAttr - * The ID. - * @param datas - * the datas - * @throws IOException - * the exception - */ - private static void processElementWithId(final Appendable result, final Node node, final NamedNodeMap attrs, final Node idAttr, final TagDataListById datas) throws IOException - { - processElementWithId(result, node, attrs, idAttr, datas, ""); - } - /** * Processes a node that has dynamic content. Calls the appropriate code * generator method, depending on the tag.