Package org.eclipse.lemminx.extensions.xsd.contentmodel

## Class CMXSDAttributeDeclaration

- java.lang.Object
- - org.eclipse.lemminx.extensions.xsd.contentmodel.CMXSDAttributeDeclaration

All Implemented Interfaces:
  `CMAttributeDeclaration`

    public class CMXSDAttributeDeclaration
    extends Object
    implements CMAttributeDeclaration

XSD attribute declaration implementation.

### Constructor Summary

Constructors
`CMXSDAttributeDeclaration​(CMXSDElementDeclaration cmElement, org.apache.xerces.xs.XSAttributeUse attributeUse)`

### Method Summary

All Methods Instance Methods Concrete Methods
`String` `getAttributeNameDocumentation​(ISharedSettingsRequest request)` Returns formatted documentation of the declared attribute according to settings defined in `request`
`String` `getAttributeValueDocumentation​(String value, ISharedSettingsRequest request)` Returns formatted documentation about `value`, according to settings defined in `request`
`String` `getDefaultValue()` Returns the default value of the declared attribute and null otherwise.
`Collection<String>` `getEnumerationValues()` Returns enumeration values of the declared attribute and empty collection otherwise.
`String` `getLocalName()` Returns the declared attribute local name.
`String` `getNamespace()` Returns the target namespace and null otherwise.
`CMElementDeclaration` `getOwnerElementDeclaration()` Returns the owner element declaration.
`String` `getPrefix()`
`boolean` `isRequired()` Returns true if the attribute is required and false otherwise.

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

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

### Methods inherited from interface org.eclipse.lemminx.extensions.contentmodel.model.CMAttributeDeclaration

`getName, getName`

### Constructor Detail

#### CMXSDAttributeDeclaration

    public CMXSDAttributeDeclaration​(CMXSDElementDeclaration cmElement,
                                     org.apache.xerces.xs.XSAttributeUse attributeUse)

### Method Detail

#### getPrefix

    public String getPrefix()

Specified by:
  `getPrefix` in interface `CMAttributeDeclaration`

#### getLocalName

    public String getLocalName()

Description copied from interface: `CMAttributeDeclaration`
Returns the declared attribute local name.

Specified by:
  `getLocalName` in interface `CMAttributeDeclaration`
Returns:
  the declared attribute local name.

#### getNamespace

    public String getNamespace()

Description copied from interface: `CMAttributeDeclaration`
Returns the target namespace and null otherwise.

Specified by:
  `getNamespace` in interface `CMAttributeDeclaration`
Returns:
  the target namespace and null otherwise.

#### getOwnerElementDeclaration

    public CMElementDeclaration getOwnerElementDeclaration()

Description copied from interface: `CMAttributeDeclaration`
Returns the owner element declaration.

Specified by:
  `getOwnerElementDeclaration` in interface `CMAttributeDeclaration`
Returns:
  the owner element declaration.

#### getDefaultValue

    public String getDefaultValue()

Description copied from interface: `CMAttributeDeclaration`
Returns the default value of the declared attribute and null otherwise.

Specified by:
  `getDefaultValue` in interface `CMAttributeDeclaration`
Returns:
  the default value of the declared attribute and null otherwise.

#### getAttributeNameDocumentation

    public String getAttributeNameDocumentation​(ISharedSettingsRequest request)

Description copied from interface: `CMAttributeDeclaration`
Returns formatted documentation of the declared attribute according to settings defined in `request`

Specified by:
  `getAttributeNameDocumentation` in interface `CMAttributeDeclaration`
Parameters:
  `request` - the request that contains settings
Returns:
  formatted documentation of the declared attribute according to settings defined in `request`

#### getAttributeValueDocumentation

    public String getAttributeValueDocumentation​(String value,
                                                 ISharedSettingsRequest request)

Description copied from interface: `CMAttributeDeclaration`
Returns formatted documentation about `value`, according to settings defined in `request`

Specified by:
  `getAttributeValueDocumentation` in interface `CMAttributeDeclaration`
Parameters:
  `value` - the attribute value to find documentation for
  `request` - the request containing settings
Returns:
  formatted documentation about `value`, according to settings defined in `request`

#### isRequired

    public boolean isRequired()

Description copied from interface: `CMAttributeDeclaration`
Returns true if the attribute is required and false otherwise.

Specified by:
  `isRequired` in interface `CMAttributeDeclaration`
Returns:
  true if the attribute is required and false otherwise.

#### getEnumerationValues

    public Collection<String> getEnumerationValues()

Description copied from interface: `CMAttributeDeclaration`
Returns enumeration values of the declared attribute and empty collection otherwise.

Specified by:
  `getEnumerationValues` in interface `CMAttributeDeclaration`
Returns:
  enumeration values of the declared attribute and empty collection otherwise.