Interface Flattener

All Known Implementing Classes:
Flattener.MaxAngle, Flattener.MaxDeviation, Flattener.MaxDeviationAndAngle, Flattener.NumSegments
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public interface Flattener
Flattens a continuous line in to a polyline.

Copyright (c) 2023-2024 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.

Author:
Alexander Verbraeck, Peter Knoppers, Wouter Schakel
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static class 
    Flattener based on maximum angle.
    static class 
    Flattener based on maximum deviation.
    static class 
    Flattener based on maximum deviation and maximum angle.
    static class 
    Flattener based on number of segments.
  • Method Summary

    Modifier and Type
    Method
    Description
    org.djutils.draw.line.PolyLine2d
    Flatten continuous line in to a polyline.
  • Method Details

    • flatten

      org.djutils.draw.line.PolyLine2d flatten(FlattableLine line)
      Flatten continuous line in to a polyline.
      Parameters:
      line - FlattableLine; line function.
      Returns:
      PolyLine2d; flattened line.