Show / Hide Table of Contents

Class LatLng

An object representing a latitude/longitude pair. This is expressed as a pair of doubles representing degrees latitude and degrees longitude. Unless specified otherwise, this must conform to the <a href="http://www.unoosa.org/pdf/icg/2012/template/WGS_84.pdf">WGS84 standard</a>. Values must be within normalized ranges.

Inheritance
System.Object
LatLng
Implements
IMessage<LatLng>
IMessage
System.IEquatable<LatLng>
IDeepCloneable<LatLng>
Inherited Members
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Google.Type
Assembly: Google.Api.CommonProtos.dll
Syntax
public sealed class LatLng : IMessage<LatLng>, IMessage, IEquatable<LatLng>, IDeepCloneable<LatLng>

Constructors

LatLng()

Declaration
public LatLng()

LatLng(LatLng)

Declaration
public LatLng(LatLng other)
Parameters
Type Name Description
LatLng other

Fields

LatitudeFieldNumber

Field number for the "latitude" field.

Declaration
public const int LatitudeFieldNumber = 1
Field Value
Type Description
System.Int32

LongitudeFieldNumber

Field number for the "longitude" field.

Declaration
public const int LongitudeFieldNumber = 2
Field Value
Type Description
System.Int32

Properties

Descriptor

Declaration
public static MessageDescriptor Descriptor { get; }
Property Value
Type Description
MessageDescriptor

Latitude

The latitude in degrees. It must be in the range [-90.0, +90.0].

Declaration
public double Latitude { get; set; }
Property Value
Type Description
System.Double

Longitude

The longitude in degrees. It must be in the range [-180.0, +180.0].

Declaration
public double Longitude { get; set; }
Property Value
Type Description
System.Double

Parser

Declaration
public static MessageParser<LatLng> Parser { get; }
Property Value
Type Description
MessageParser<LatLng>

Methods

CalculateSize()

Declaration
public int CalculateSize()
Returns
Type Description
System.Int32
Implements
IMessage.CalculateSize()

Clone()

Declaration
public LatLng Clone()
Returns
Type Description
LatLng
Implements
IDeepCloneable<T>.Clone()

Equals(LatLng)

Declaration
public bool Equals(LatLng other)
Parameters
Type Name Description
LatLng other
Returns
Type Description
System.Boolean
Implements
System.IEquatable<T>.Equals(T)

Equals(Object)

Declaration
public override bool Equals(object other)
Parameters
Type Name Description
System.Object other
Returns
Type Description
System.Boolean
Overrides
System.Object.Equals(System.Object)

GetHashCode()

Declaration
public override int GetHashCode()
Returns
Type Description
System.Int32
Overrides
System.Object.GetHashCode()

MergeFrom(CodedInputStream)

Declaration
public void MergeFrom(CodedInputStream input)
Parameters
Type Name Description
CodedInputStream input
Implements
IMessage.MergeFrom(CodedInputStream)

MergeFrom(LatLng)

Declaration
public void MergeFrom(LatLng other)
Parameters
Type Name Description
LatLng other
Implements
IMessage<T>.MergeFrom(T)

ToString()

Declaration
public override string ToString()
Returns
Type Description
System.String
Overrides
System.Object.ToString()

WriteTo(CodedOutputStream)

Declaration
public void WriteTo(CodedOutputStream output)
Parameters
Type Name Description
CodedOutputStream output
Implements
IMessage.WriteTo(CodedOutputStream)

Explicit Interface Implementations

IMessage.Descriptor

Declaration
MessageDescriptor IMessage.Descriptor { get; }
Returns
Type Description
MessageDescriptor
Implements
IMessage.Descriptor
Back to top