src/util/SunPosition.js
function (date) {
                if (date instanceof Date === false) {
                    throw new ArgumentError(
                        Logger.logMessage(Logger.LEVEL_SEVERE, "SunPosition", "getAsGeographicLocation",
                            "missingDate"));
                }

                var celestialLocation = this.getAsCelestialLocation(date);
                return this.celestialToGeographic(celestialLocation, date);
            }
function (date) {
                if (date instanceof Date === false) {
                    throw new ArgumentError(
                        Logger.logMessage(Logger.LEVEL_SEVERE, "SunPosition", "getAsGeographicLocation",
                            "missingDate"));
                }

                var celestialLocation = this.getAsCelestialLocation(date);
                return this.celestialToGeographic(celestialLocation, date);
            }
function ( date ) { if ( date instanceof Date === false ) { throw new ArgumentError ( Logger . logMessage ( Logger . LEVEL_SEVERE , "SunPosition" , "getAsGeographicLocation" , "missingDate" ) ) ; } var celestialLocation = this . getAsCelestialLocation ( date ) ; return this . celestialToGeographic ( celestialLocation , date ) ; }
Computes the geographic location of the sun for a given date
@param {Date} date
@throws {ArgumentError} if the date is missing
@return {{latitude: Number, longitude: Number}} the geographic location
Computes the geographic location of the sun for a given date