Package org.eclipse.lemminx.extensions.generators

## Class ElementDeclaration

- java.lang.Object
- - org.eclipse.lemminx.extensions.generators.ContainerDeclaration
  - - org.eclipse.lemminx.extensions.generators.ElementDeclaration

    public class ElementDeclaration
    extends ContainerDeclaration

Element information.

### Constructor Summary

Constructors
`ElementDeclaration​(String name)`

### Method Summary

All Methods Instance Methods Concrete Methods
`void` `addChildHierarchy​(List<String> tags)`
`void` `addElement​(ElementDeclaration element)`
`AttributeDeclaration` `getAttribute​(String name)` Returns the attribute information for the given name and create it if not found.
`Collection<AttributeDeclaration>` `getAttributes()`
`ChildrenProperties` `getChildrenProperties()`
`String` `getName()` Returns the element name.
`int` `getOccurrences()` Returns the occurrences of DOM element.
`ElementDeclaration` `getParent()`
`boolean` `hasAttributeId()` Returns true if the element have an attribute ID and false otherwise.
`boolean` `hasCharacterContent()` Returns true if element has character content and false otherwise.
`void` `incrementOccurrences()` Increment the DOM element occurrence.

### Methods inherited from class org.eclipse.lemminx.extensions.generators.ContainerDeclaration

`getElement, getElements`

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

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### ElementDeclaration

    public ElementDeclaration​(String name)

### Method Detail

#### getName

    public String getName()

Returns the element name.

Returns:
  the element name.

#### getAttribute

    public AttributeDeclaration getAttribute​(String name)

Returns the attribute information for the given name and create it if not found.

Parameters:
  `name` - the attribute name
Returns:
  the attribute information for the given name and create it if not found.

#### getAttributes

    public Collection<AttributeDeclaration> getAttributes()

#### hasCharacterContent

    public boolean hasCharacterContent()

Returns true if element has character content and false otherwise.

Returns:
  true if element has character content and false otherwise.

#### addElement

    public void addElement​(ElementDeclaration element)

Overrides:
  `addElement` in class `ContainerDeclaration`

#### getParent

    public ElementDeclaration getParent()

#### addChildHierarchy

    public void addChildHierarchy​(List<String> tags)

#### getChildrenProperties

    public ChildrenProperties getChildrenProperties()

#### incrementOccurrences

    public void incrementOccurrences()

Increment the DOM element occurrence.

#### getOccurrences

    public int getOccurrences()

Returns the occurrences of DOM element.

Returns:
  the occurrences of DOM element.

#### hasAttributeId

    public boolean hasAttributeId()

Returns true if the element have an attribute ID and false otherwise.

Returns:
  true if the element have an attribute ID and false otherwise.