tigase.xml.db

## Class DBElement

- java.lang.Object
- - tigase.xml.Element
  - - tigase.xml.db.DBElement

- All Implemented Interfaces:
    Cloneable, Comparable<Element>, XMLNodeIfc<Element>

      public class DBElement
      extends Element

  `DBElement` class extends `tigase.xml.Element`. It adds some extra functionality useful for data base operations like searching for some specific nodes, add data entries, remove data, and all other common operations not directly related to pure XML processing. Pure XML processing is of course implemented in `tigase.xml.Element`. The are also some methods which make it easier to save XML tree from memory to disk file in a form which is easier to read by a human.

  Created: Tue Oct 26 22:01:47 2004

  Version:
    $Rev$
  Author:
    Artur Hefczyc

- - ### Nested Class Summary

    - ### Nested classes/interfaces inherited from class tigase.xml.Element

      `Element.Matcher<T>, Element.XMLIdentityHashMap<K,V>`

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static String` | `ENTRY` Field description
    `static String` | `KEY` Field description
    `static String` | `MAP` Field description
    `static String` | `NAME` Field description
    `static String` | `NODE` Field description
    `boolean` | `removed` Field description
    `static String` | `TYPE` Field description
    `static String` | `VALUE` Field description

    - ### Fields inherited from class tigase.xml.Element

      `attributes, children, defxmlns, name, xmlns`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `DBElement(String argName)` Constructs ...
    `DBElement(String argName, String attname, String attvalue)` Constructs ...
    `DBElement(String argName, String argCData, StringBuilder[] att_names, StringBuilder[] att_values)` Constructs ...

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `DBElement` | `buildNodesTree(String nodePath)` Method description
    `String` | `childrenFormatedString(int indent, int step)` Method description
    `DBElement` | `findEntry(String key)` Method description
    `DBElement` | `findNode(String nodePath)` Method description
    `String` | `formatedString(int indent, int step)` Method description
    `DBElement` | `getEntry(String key)` Method description
    `double[]` | `getEntryDoubleArrValue(String key, double[] def)` Method description
    `double` | `getEntryDoubleValue(String key, double def)` Method description
    `int[]` | `getEntryIntArrValue(String key, int[] def)` Method description
    `int` | `getEntryIntValue(String key, int def)` Method description
    `String[]` | `getEntryKeys()` Method description
    `String[]` | `getEntryStringArrValue(String key, String[] def)` Method description
    `String` | `getEntryStringValue(String key, String def)` Method description
    `Object` | `getEntryValue(String key, Object def)` Method description
    `DBElement` | `getSubnode(String name)` Method description
    `DBElement` | `getSubnodePath(String nodePath)` Method description
    `String[]` | `getSubnodes()` Method description
    `DBElement` | `newSubnode(String name)` Method description
    `void` | `removeEntry(String key)` Method description
    `void` | `removeNode(String nodePath)` Method description
    `void` | `setEntry(String key, Object value)` Method description

    - ### Methods inherited from class tigase.xml.Element

      `addAttribute, addAttributes, addCData, addChild, addChildren, cdataToString, childrenToString, childrenToString, childrenToStringPretty, childrenToStringSecure, childrenToStringSecure, clone, compareTo, equals, findChild, findChild, findChild, findChildren, findChildStaticStr, flatMapChildren, forEachChild, getAttribute, getAttribute, getAttribute, getAttributes, getAttributeStaticStr, getAttributeStaticStr, getCData, getCData, getCData, getCDataStaticStr, getChild, getChild, getChildAttribute, getChildAttributeStaticStr, getChildCData, getChildCData, getChildCData, getChildCDataStaticStr, getChildren, getChildren, getChildren, getChildren, getChildrenStaticStr, getChildStaticStr, getChildStaticStr, getName, getXMLNS, getXMLNS, getXMLNS, getXMLNSStaticStr, hashCode, main, map, mapChildren, mapChildren, matches, removeAttribute, removeChild, setAttribute, setAttributes, setAttributes, setAttributes, setAttributeStaticStr, setCData, setChildren, setDefXMLNS, setName, setXMLNS, toString, toString, toStringNoChildren, toStringPretty, toStringSecure, toStringSecure`

    - ### Methods inherited from class java.lang.Object

      `finalize, getClass, notify, notifyAll, wait, wait, wait`

- - ### Field Detail

    - #### ENTRY

          public static final String ENTRY

      Field description
      See Also:
        Constant Field Values

    - #### KEY

          public static final String KEY

      Field description
      See Also:
        Constant Field Values

    - #### MAP

          public static final String MAP

      Field description
      See Also:
        Constant Field Values

    - #### NAME

          public static final String NAME

      Field description
      See Also:
        Constant Field Values

    - #### NODE

          public static final String NODE

      Field description
      See Also:
        Constant Field Values

    - #### TYPE

          public static final String TYPE

      Field description
      See Also:
        Constant Field Values

    - #### VALUE

          public static final String VALUE

      Field description
      See Also:
        Constant Field Values

    - #### removed

          public boolean removed

      Field description

  - ### Constructor Detail

    - #### DBElement

          public DBElement(String argName)

      Constructs ...
      Parameters:
        `argName` -

    - #### DBElement

          public DBElement(String argName,
                           String attname,
                           String attvalue)

      Constructs ...
      Parameters:
        `argName` -
        `attname` -
        `attvalue` -

    - #### DBElement

          public DBElement(String argName,
                           String argCData,
                           StringBuilder[] att_names,
                           StringBuilder[] att_values)

      Constructs ...
      Parameters:
        `argName` -
        `argCData` -
        `att_names` -
        `att_values` -

  - ### Method Detail

    - #### formatedString

          public final String formatedString(int indent,
                                             int step)

      Method description
      Parameters:
        `indent` -
        `step` -
      Returns:

    - #### childrenFormatedString

          public final String childrenFormatedString(int indent,
                                                     int step)

      Method description
      Parameters:
        `indent` -
        `step` -
      Returns:

    - #### getSubnode

          public final DBElement getSubnode(String name)

      Method description
      Parameters:
        `name` -
      Returns:

    - #### getSubnodes

          public final String[] getSubnodes()

      Method description
      Returns:

    - #### findNode

          public final DBElement findNode(String nodePath)

      Method description
      Parameters:
        `nodePath` -
      Returns:

    - #### removeNode

          public final void removeNode(String nodePath)

      Method description
      Parameters:
        `nodePath` -

    - #### getSubnodePath

          public final DBElement getSubnodePath(String nodePath)

      Method description
      Parameters:
        `nodePath` -
      Returns:

    - #### buildNodesTree

          public final DBElement buildNodesTree(String nodePath)

      Method description
      Parameters:
        `nodePath` -
      Returns:

    - #### newSubnode

          public final DBElement newSubnode(String name)

      Method description
      Parameters:
        `name` -
      Returns:

    - #### findEntry

          public final DBElement findEntry(String key)

      Method description
      Parameters:
        `key` -
      Returns:

    - #### removeEntry

          public final void removeEntry(String key)

      Method description
      Parameters:
        `key` -

    - #### getEntryKeys

          public final String[] getEntryKeys()

      Method description
      Returns:

    - #### getEntry

          public final DBElement getEntry(String key)

      Method description
      Parameters:
        `key` -
      Returns:

    - #### setEntry

          public final void setEntry(String key,
                                     Object value)

      Method description
      Parameters:
        `key` -
        `value` -

    - #### getEntryStringValue

          public final String getEntryStringValue(String key,
                                                  String def)

      Method description
      Parameters:
        `key` -
        `def` -
      Returns:

    - #### getEntryStringArrValue

          public final String[] getEntryStringArrValue(String key,
                                                       String[] def)

      Method description
      Parameters:
        `key` -
        `def` -
      Returns:

    - #### getEntryIntValue

          public final int getEntryIntValue(String key,
                                            int def)

      Method description
      Parameters:
        `key` -
        `def` -
      Returns:

    - #### getEntryIntArrValue

          public final int[] getEntryIntArrValue(String key,
                                                 int[] def)

      Method description
      Parameters:
        `key` -
        `def` -
      Returns:

    - #### getEntryDoubleValue

          public final double getEntryDoubleValue(String key,
                                                  double def)

      Method description
      Parameters:
        `key` -
        `def` -
      Returns:

    - #### getEntryDoubleArrValue

          public final double[] getEntryDoubleArrValue(String key,
                                                       double[] def)

      Method description
      Parameters:
        `key` -
        `def` -
      Returns:

    - #### getEntryValue

          public final Object getEntryValue(String key,
                                            Object def)

      Method description
      Parameters:
        `key` -
        `def` -
      Returns:

Copyright © 2018 "Tigase, Inc.". All rights reserved.