com.io7m.jpra.model.type_declarations

## Class PackedFieldDeclValue<I,T>

- java.lang.Object
- - com.io7m.jpra.model.type_declarations.PackedFieldDeclValue<I,T>

- Type Parameters:
    `I` - The type of identifiers
    `T` - The type of type information
  All Implemented Interfaces:
    ModelElementType, PackedFieldDeclType<I,T>

      @Immutable
      public final class PackedFieldDeclValue<I,T>
      extends Object
      implements PackedFieldDeclType<I,T>

  A `field` declaration in a `packed` type.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `PackedFieldDeclValue(I in_identifier, FieldName in_name, TypeExprType<I,T> in_type)` Construct a `field` declaration.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `I` | `getIdentifier()`
    `Optional<com.io7m.jlexing.core.ImmutableLexicalPositionType<Path>>` | `getLexicalInformation()` Fetch the lexical information for the element.
    `FieldName` | `getName()`
    `TypeExprType<I,T>` | `getType()`
    `<A,E extends Exception> A` | `matchPackedFieldDeclaration(PackedFieldDeclMatcherType<I,T,A,E> m)` Accept a matcher.

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

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

- - ### Constructor Detail

    - #### PackedFieldDeclValue

          public PackedFieldDeclValue(I in_identifier,
                                      FieldName in_name,
                                      TypeExprType<I,T> in_type)

      Construct a `field` declaration.
      Parameters:
        `in_identifier` - The identifier
        `in_name` - The name of the field
        `in_type` - The type of the field

  - ### Method Detail

    - #### getIdentifier

          public I getIdentifier()

      Returns:
        The identifier

    - #### getName

          public FieldName getName()

      Returns:
        The field name

    - #### getType

          public TypeExprType<I,T> getType()

      Returns:
        The field type

    - #### matchPackedFieldDeclaration

          public <A,E extends Exception> A matchPackedFieldDeclaration(PackedFieldDeclMatcherType<I,T,A,E> m)
                                                                throws E extends Exception

      Description copied from interface: `PackedFieldDeclType`
      Accept a matcher.
      Specified by:
        `matchPackedFieldDeclaration` in interface `PackedFieldDeclType<I,T>`
      Type Parameters:
        `A` - The type of returned values
        `E` - The type of raised exceptions
      Parameters:
        `m` - The matcher
      Returns:
        The value returned by `m`
      Throws:
        `E` - If `m` raises `E`
        `E extends Exception`

    - #### getLexicalInformation

          public Optional<com.io7m.jlexing.core.ImmutableLexicalPositionType<Path>> getLexicalInformation()

      Description copied from interface: `ModelElementType`
      Fetch the lexical information for the element. This is used to localize error messages to a position in a file when referring to specific elements.
      Specified by:
        `getLexicalInformation` in interface `ModelElementType`
      Returns:
        The original lexical information, if any

Copyright © 2015 <code@io7m.com> http://io7m.com