JTS Topology Suite version 1.13

## com.vividsolutions.jts.geom.impl
Class CoordinateArraySequenceFactory

    java.lang.Object
      com.vividsolutions.jts.geom.impl.CoordinateArraySequenceFactory

All Implemented Interfaces:
  CoordinateSequenceFactory, java.io.Serializable

    public final class CoordinateArraySequenceFactory

extends java.lang.Object
implements CoordinateSequenceFactory, java.io.Serializable

Creates `CoordinateSequence`s represented as an array of `Coordinate`s.

Version:
  1.7
See Also:
  Serialized Form

Method Summary
`CoordinateSequence` `create(Coordinate[] coordinates)` Returns a `CoordinateArraySequence` based on the given array (the array is not copied).
`CoordinateSequence` `create(CoordinateSequence coordSeq)` Creates a `CoordinateSequence` which is a copy of the given `CoordinateSequence`.
`CoordinateSequence` `create(int size, int dimension)` Creates a `CoordinateSequence` of the specified size and dimension.
`static CoordinateArraySequenceFactory` `instance()` Returns the singleton instance of `CoordinateArraySequenceFactory`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Method Detail

### instance

    public static CoordinateArraySequenceFactory instance()

  Returns the singleton instance of `CoordinateArraySequenceFactory`

### create

    public CoordinateSequence create(Coordinate[] coordinates)

  Returns a `CoordinateArraySequence` based on the given array (the array is not copied).

  Specified by:
    `create` in interface `CoordinateSequenceFactory`
  Parameters:
    `coordinates` - the coordinates, which may not be null nor contain null elements

### create

    public CoordinateSequence create(CoordinateSequence coordSeq)

  Description copied from interface: `CoordinateSequenceFactory`
  Creates a `CoordinateSequence` which is a copy of the given `CoordinateSequence`. This method must handle null arguments by creating an empty sequence.

  Specified by:
    `create` in interface `CoordinateSequenceFactory`
  Parameters:
    `coordSeq` - the coordinate sequence to copy
  See Also:
    `CoordinateSequenceFactory.create(com.vividsolutions.jts.geom.CoordinateSequence)`

### create

    public CoordinateSequence create(int size,
                                     int dimension)

  Description copied from interface: `CoordinateSequenceFactory`
  Creates a `CoordinateSequence` of the specified size and dimension. For this to be useful, the `CoordinateSequence` implementation must be mutable.

  Specified by:
    `create` in interface `CoordinateSequenceFactory`
  Parameters:
    `size` - the number of coordinates in the sequence
    `dimension` - the dimension of the coordinates in the sequence (if user-specifiable, otherwise ignored)
  Throws:
    `java.lang.IllegalArgumentException` - if the dimension is > 3
  See Also:
    `CoordinateSequenceFactory.create(int, int)`

JTS Topology Suite version 1.13