Link.ModuleSpec (Apache Ant API)
Description: declaration: package: org.apache.tools.ant.taskdefs.modules, class: Link, class: ModuleSpec

# Class Link.ModuleSpec

java.lang.Object
org.apache.tools.ant.taskdefs.modules.Link.ModuleSpec

Enclosing class:
  `Link`

public class Link.ModuleSpec extends Object
Child element that explicitly names a Java module.

Since:
  1.10.6

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `ModuleSpec()`
  Creates an unconfigured element.
  `ModuleSpec(String name)`
  Creates an element with the given module name.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `String`
  `getName()`
  Attribute containing name of module this element represents.
  `void`
  `setName(String name)`
  Sets attribute representing the name of this module this element represents.
  `void`
  `validate()`
  Verifies this element's state.

  ### Methods inherited from class Object

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

- ## Constructor Details

  - ### ModuleSpec

    public ModuleSpec()
    Creates an unconfigured element.

  - ### ModuleSpec

    public ModuleSpec(String name)
    Creates an element with the given module name.
    Parameters:
      `name` - module's name

- ## Method Details

  - ### getName

    public String getName()
    Attribute containing name of module this element represents.
    Returns:
      name of module

  - ### setName

    public void setName(String name)
    Sets attribute representing the name of this module this element represents.
    Parameters:
      `name` - module's name

  - ### validate

    public void validate()
    Verifies this element's state.
    Throws:
      `BuildException` - if name is not set