JsonElement.GetDouble Método

Definição

Obtém o número JSON atual como um Double.Gets the current JSON number as a Double.

public:
 double GetDouble();
public double GetDouble ();
member this.GetDouble : unit -> double
Public Function GetDouble () As Double

Retornos

Double

O número JSON atual como um Double.The current JSON number as a Double.

Exceções

O ValueKind desse valor não é Number.This value's ValueKind is not Number.

O valor não pode ser representado como um Double.The value cannot be represented as a Double.

O JsonDocument pai foi descartado.The parent JsonDocument has been disposed.

Comentários

Esse método não analisa o conteúdo de um valor de cadeia de caracteres JSON.This method does not parse the contents of a JSON string value.

No .NET Core, esse método retorna Double.PositiveInfinity para valores maiores que Double.MaxValue e retorna Double.NegativeInfinity para valores menores que Double.MinValue .On .NET Core, this method returns Double.PositiveInfinity for values larger than Double.MaxValue, and it returns Double.NegativeInfinity for values smaller than Double.MinValue.

Aplica-se a