Package: groovy.lang

## [Java] Class MetaArrayLengthProperty

- groovy.lang.MetaArrayLengthProperty

- Represents the length property of an array

- - ### Constructor Summary

    Constructors
    Constructor and description
    `MetaArrayLengthProperty ()` Sole constructor setting name to "length" and type to int

  - ### Methods Summary

    Methods
    Type Params | Return Type | Name and description
    --- | --- | ---
    `` | `Object` | `getProperty(Object object)` Get this property from the given object.
    `` | `void` | `setProperty(Object object, Object newValue)` Sets the property on the given object to the new value

- - ### Constructor Detail

    - #### public MetaArrayLengthProperty()

      Sole constructor setting name to "length" and type to int

  - ### Method Detail

    - #### public Object getProperty(Object object)

      Get this property from the given object.

      throws:
        IllegalArgumentException if object is not an array
      Parameters:
        `object` - an array
      Returns:
        the length of the array object

    - #### public void setProperty(Object object, Object newValue)

      Sets the property on the given object to the new value

      throws:
        RuntimeException if the property could not be set
      Parameters:
        `object` - on which to set the property
        `newValue` - the new value of the property