Class LineOfSightLayer.Builder

java.lang.Object
com.luciad.layers.los.LineOfSightLayer.Builder
All Implemented Interfaces:
AutoCloseable
Enclosing class:
LineOfSightLayer

public static final class LineOfSightLayer.Builder extends Object implements AutoCloseable
Builder for creating a LineOfSightLayer for a IFeatureModel with line-of-sight features.
Since:
2025.0
  • Constructor Details

  • Method Details

    • finalize

      protected void finalize()
      Overrides:
      finalize in class Object
    • close

      public void close()
      Specified by:
      close in interface AutoCloseable
    • build

      @NotNull public LineOfSightLayer build() throws IllegalStateException
      Returns a new layer, based on the properties set on this builder.
      Returns:
      a new layer, based on the properties set on this builder.
      Throws:
      IllegalStateException - If not all mandatory parameters are set.
    • title

      @NotNull public LineOfSightLayer.Builder title(@NotNull String title)
      Sets the title to use for the layer.

      If not set, the title from the ModelMetadata is used.

      Parameters:
      title - the title for the layer.
      Returns:
      this builder.
    • visible

      @NotNull public LineOfSightLayer.Builder visible(boolean visible)
      Sets whether the layer should be visible initially.

      Default is true.

      Parameters:
      visible - the visibility.
      Returns:
      this builder.
    • model

      @NotNull public LineOfSightLayer.Builder model(@NotNull IFeatureModel model) throws NullPointerException
      Sets the model of the layer.

      This model provides the line-of-sight features to be presented. Such a feature represents an observer with some additional properties which together define a line-of-sight coverage. They can be created using LineOfSightFeature#newBuilder and related functions.

      Calling this function is mandatory.

      Parameters:
      model - the model of the layer.
      Returns:
      this builder.
      Throws:
      NullPointerException - if model is null.
      See Also:
    • lineOfSightStyle

      @NotNull public LineOfSightLayer.Builder lineOfSightStyle(@NotNull LineOfSightStyle losStyle)
      Sets the style for this layer.
      Parameters:
      losStyle - the line-of-sight style to apply.
      Returns:
      this builder.