Class SunlightModel.Builder

java.lang.Object
com.luciad.maps.effects.SunlightModel.Builder
All Implemented Interfaces:
AutoCloseable
Enclosing class:
SunlightModel

public static final class SunlightModel.Builder extends Object implements AutoCloseable
Since:
2026.1
  • Constructor Details

    • Builder

      public Builder(@NotNull SunlightModel.Builder other)
      Copy constructor.
      Parameters:
      other - the builder to copy.
  • Method Details

    • finalize

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

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

      @NotNull public SunlightModel.Builder ambientColor(@NotNull android.graphics.Color color)
      Sets the ambient color of the light.

      The default is a dark gray (64, 64, 64).

      Parameters:
      color - the ambient color of the light.
      Returns:
      this builder.
    • diffuseColor

      @NotNull public SunlightModel.Builder diffuseColor(@NotNull android.graphics.Color color)
      Sets the diffuse color of the light.

      The default is white.

      Parameters:
      color - the diffuse color of the light.
      Returns:
      this builder.
    • time

      @NotNull public SunlightModel.Builder time(long epochTimeMilliseconds)
      Sets the time in milliseconds since midnight 01 January, 1970.

      This is mandatory.

      Parameters:
      epochTimeMilliseconds - Time in milliseconds since midnight GMT+0 (UTC), 01 January 1970.
      Returns:
      this builder.
    • build

      @NotNull public SunlightModel build() throws IllegalStateException
      Builds the sunlight.
      Returns:
      the built sunlight.
      Throws:
      IllegalStateException - when the time was not set.