DaylightViewModel

AMD: require(["esri/widgets/Daylight/DaylightViewModel"], (DaylightViewModel) => { /* code goes here */ });
ESM: import DaylightViewModel from "@arcgis/core/widgets/Daylight/DaylightViewModel";
Class: esri/widgets/Daylight/DaylightViewModel
Inheritance: DaylightViewModel Accessor
Since: ArcGIS API for JavaScript 4.14

Provides the logic for the Daylight widget.

See also:

Constructors

new DaylightViewModel(properties)
Parameter:
properties Object
optional

See the properties for a list of all the properties that may be passed into the constructor.

Property Overview

Any properties can be set, retrieved or listened to. See the Working with Properties topic.
Show inherited properties Hide inherited properties
Name Type Summary Class
Stringmore details

A season can be set instead of a date.

more detailsDaylightViewModel
Booleanmore details

Starts or pauses the daytime animation cycling through the minutes of the day.

more detailsDaylightViewModel
Stringmore details

The name of the class.

more detailsAccessor
Booleanmore details

Indicates whether to show shadows cast by the sun.

more detailsDaylightViewModel
Datemore details

The calendar date in the timezone given by utcOffset.

more detailsDaylightViewModel
Numbermore details

Controls the daytime and date animation speed.

more detailsDaylightViewModel
Booleanmore details

Indicates whether date and time are used to determine position of the light source.

more detailsDaylightViewModel
Numbermore details

Slider position for the time of day in the timezone given by utcOffset.

more detailsDaylightViewModel
Numbermore details

The difference in hours between UTC time and the time displayed in the widget.

more detailsDaylightViewModel
SceneViewmore details

The view from which the widget will operate.

more detailsDaylightViewModel
Booleanmore details

Starts or pauses the date animation cycling through the months of the year.

more detailsDaylightViewModel

Property Details

currentSeason String

A season can be set instead of a date. Each season uses a fixed date corresponding to the seasonsal equinoxes and solstices.

Possible Values:"spring"|"summer"|"fall"|"winter"

dayPlaying Boolean

Starts or pauses the daytime animation cycling through the minutes of the day. Set to true to start the animation and to false to pause it.

Default Value:false
declaredClass Stringreadonly inherited

The name of the class. The declared class name is formatted as esri.folder.className.

directShadowsEnabled Boolean

Indicates whether to show shadows cast by the sun. For more details on this property see SceneView.environment.lighting.directShadowsEnabled.

localDate Date

The calendar date in the timezone given by utcOffset.

playSpeedMultiplier Number

Controls the daytime and date animation speed.

Default Value:1.0
Example:
// Plays the daylight animation at half of the default speed
daylightWidget.playSpeedMultiplier = 0.5;
sunLightingEnabled Boolean

Indicates whether date and time are used to determine position of the light source. When false, the light source is positioned relative to the camera, using VirtualLighting.

timeSliderPosition Number

Slider position for the time of day in the timezone given by utcOffset. The position represents the time of the day in minutes. Possible values range between 0 and 1440.

utcOffset Number

The difference in hours between UTC time and the time displayed in the widget.

view SceneView

The view from which the widget will operate.

yearPlaying Boolean

Starts or pauses the date animation cycling through the months of the year. Set to true to start the animation and to false to pause it.

Default Value:false

Method Overview

Name Return Type Summary Class
more details

The current lighting used in the environment.

more detailsDaylightViewModel
more details

The current type of lighting.

more detailsDaylightViewModel
more details

Lighting date in display time zone

more detailsDaylightViewModel

Method Details

get()inner

The current lighting used in the environment.

get()inner

The current type of lighting.

get()inner

Lighting date in display time zone

Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.