INumberBase<TSelf> Interface

Definição

Define a base de outros tipos de número.

generic <typename TSelf>
 where TSelf : INumberBase<TSelf>public interface class INumberBase : IEquatable<TSelf>, IParsable<TSelf>, ISpanFormattable, ISpanParsable<TSelf>, System::Numerics::IAdditionOperators<TSelf, TSelf, TSelf>, System::Numerics::IAdditiveIdentity<TSelf, TSelf>, System::Numerics::IDecrementOperators<TSelf>, System::Numerics::IDivisionOperators<TSelf, TSelf, TSelf>, System::Numerics::IEqualityOperators<TSelf, TSelf, bool>, System::Numerics::IIncrementOperators<TSelf>, System::Numerics::IMultiplicativeIdentity<TSelf, TSelf>, System::Numerics::IMultiplyOperators<TSelf, TSelf, TSelf>, System::Numerics::ISubtractionOperators<TSelf, TSelf, TSelf>, System::Numerics::IUnaryNegationOperators<TSelf, TSelf>, System::Numerics::IUnaryPlusOperators<TSelf, TSelf>
generic <typename TSelf>
 where TSelf : INumberBase<TSelf>public interface class INumberBase : IEquatable<TSelf>, IParsable<TSelf>, ISpanFormattable, ISpanParsable<TSelf>, IUtf8SpanFormattable, IUtf8SpanParsable<TSelf>, System::Numerics::IAdditionOperators<TSelf, TSelf, TSelf>, System::Numerics::IAdditiveIdentity<TSelf, TSelf>, System::Numerics::IDecrementOperators<TSelf>, System::Numerics::IDivisionOperators<TSelf, TSelf, TSelf>, System::Numerics::IEqualityOperators<TSelf, TSelf, bool>, System::Numerics::IIncrementOperators<TSelf>, System::Numerics::IMultiplicativeIdentity<TSelf, TSelf>, System::Numerics::IMultiplyOperators<TSelf, TSelf, TSelf>, System::Numerics::ISubtractionOperators<TSelf, TSelf, TSelf>, System::Numerics::IUnaryNegationOperators<TSelf, TSelf>, System::Numerics::IUnaryPlusOperators<TSelf, TSelf>
public interface INumberBase<TSelf> : IEquatable<TSelf>, IParsable<TSelf>, ISpanFormattable, ISpanParsable<TSelf>, System.Numerics.IAdditionOperators<TSelf,TSelf,TSelf>, System.Numerics.IAdditiveIdentity<TSelf,TSelf>, System.Numerics.IDecrementOperators<TSelf>, System.Numerics.IDivisionOperators<TSelf,TSelf,TSelf>, System.Numerics.IEqualityOperators<TSelf,TSelf,bool>, System.Numerics.IIncrementOperators<TSelf>, System.Numerics.IMultiplicativeIdentity<TSelf,TSelf>, System.Numerics.IMultiplyOperators<TSelf,TSelf,TSelf>, System.Numerics.ISubtractionOperators<TSelf,TSelf,TSelf>, System.Numerics.IUnaryNegationOperators<TSelf,TSelf>, System.Numerics.IUnaryPlusOperators<TSelf,TSelf> where TSelf : INumberBase<TSelf>
public interface INumberBase<TSelf> : IEquatable<TSelf>, IParsable<TSelf>, ISpanFormattable, ISpanParsable<TSelf>, IUtf8SpanFormattable, IUtf8SpanParsable<TSelf>, System.Numerics.IAdditionOperators<TSelf,TSelf,TSelf>, System.Numerics.IAdditiveIdentity<TSelf,TSelf>, System.Numerics.IDecrementOperators<TSelf>, System.Numerics.IDivisionOperators<TSelf,TSelf,TSelf>, System.Numerics.IEqualityOperators<TSelf,TSelf,bool>, System.Numerics.IIncrementOperators<TSelf>, System.Numerics.IMultiplicativeIdentity<TSelf,TSelf>, System.Numerics.IMultiplyOperators<TSelf,TSelf,TSelf>, System.Numerics.ISubtractionOperators<TSelf,TSelf,TSelf>, System.Numerics.IUnaryNegationOperators<TSelf,TSelf>, System.Numerics.IUnaryPlusOperators<TSelf,TSelf> where TSelf : INumberBase<TSelf>
type INumberBase<'Self (requires 'Self :> INumberBase<'Self>)> = interface
    interface IEquatable<'Self (requires 'Self :> INumberBase<'Self>)>
    interface IFormattable
    interface IParsable<'Self (requires 'Self :> INumberBase<'Self>)>
    interface ISpanFormattable
    interface ISpanParsable<'Self (requires 'Self :> INumberBase<'Self>)>
    interface IAdditionOperators<'Self, 'Self, 'Self (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface IAdditiveIdentity<'Self, 'Self (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface IDecrementOperators<'Self (requires 'Self :> INumberBase<'Self>)>
    interface IDivisionOperators<'Self, 'Self, 'Self (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface IEqualityOperators<'Self, 'Self, bool (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface IIncrementOperators<'Self (requires 'Self :> INumberBase<'Self>)>
    interface IMultiplicativeIdentity<'Self, 'Self (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface IMultiplyOperators<'Self, 'Self, 'Self (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface ISubtractionOperators<'Self, 'Self, 'Self (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface IUnaryNegationOperators<'Self, 'Self (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface IUnaryPlusOperators<'Self, 'Self (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
type INumberBase<'Self (requires 'Self :> INumberBase<'Self>)> = interface
    interface IEquatable<'Self (requires 'Self :> INumberBase<'Self>)>
    interface IFormattable
    interface IParsable<'Self (requires 'Self :> INumberBase<'Self>)>
    interface ISpanFormattable
    interface ISpanParsable<'Self (requires 'Self :> INumberBase<'Self>)>
    interface IAdditionOperators<'Self, 'Self, 'Self (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface IAdditiveIdentity<'Self, 'Self (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface IDecrementOperators<'Self (requires 'Self :> INumberBase<'Self>)>
    interface IDivisionOperators<'Self, 'Self, 'Self (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface IEqualityOperators<'Self, 'Self, bool (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface IIncrementOperators<'Self (requires 'Self :> INumberBase<'Self>)>
    interface IMultiplicativeIdentity<'Self, 'Self (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface IMultiplyOperators<'Self, 'Self, 'Self (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface ISubtractionOperators<'Self, 'Self, 'Self (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface IUnaryNegationOperators<'Self, 'Self (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface IUnaryPlusOperators<'Self, 'Self (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface IUtf8SpanFormattable
    interface IUtf8SpanParsable<'Self (requires 'Self :> INumberBase<'Self>)>
type INumberBase<'Self (requires 'Self :> INumberBase<'Self>)> = interface
    interface IEquatable<'Self (requires 'Self :> INumberBase<'Self>)>
    interface IFormattable
    interface IParsable<'Self (requires 'Self :> INumberBase<'Self>)>
    interface ISpanFormattable
    interface ISpanParsable<'Self (requires 'Self :> INumberBase<'Self>)>
    interface IUtf8SpanFormattable
    interface IUtf8SpanParsable<'Self (requires 'Self :> INumberBase<'Self>)>
    interface IAdditionOperators<'Self, 'Self, 'Self (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface IAdditiveIdentity<'Self, 'Self (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface IDecrementOperators<'Self (requires 'Self :> INumberBase<'Self>)>
    interface IDivisionOperators<'Self, 'Self, 'Self (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface IEqualityOperators<'Self, 'Self, bool (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface IIncrementOperators<'Self (requires 'Self :> INumberBase<'Self>)>
    interface IMultiplicativeIdentity<'Self, 'Self (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface IMultiplyOperators<'Self, 'Self, 'Self (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface ISubtractionOperators<'Self, 'Self, 'Self (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface IUnaryNegationOperators<'Self, 'Self (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
    interface IUnaryPlusOperators<'Self, 'Self (requires 'Self :> INumberBase<'Self> and 'Self :> INumberBase<'Self>)>
Public Interface INumberBase(Of TSelf)
Implements IAdditionOperators(Of TSelf, TSelf, TSelf), IAdditiveIdentity(Of TSelf, TSelf), IDecrementOperators(Of TSelf), IDivisionOperators(Of TSelf, TSelf, TSelf), IEqualityOperators(Of TSelf, TSelf, Boolean), IEquatable(Of TSelf), IIncrementOperators(Of TSelf), IMultiplicativeIdentity(Of TSelf, TSelf), IMultiplyOperators(Of TSelf, TSelf, TSelf), IParsable(Of TSelf), ISpanFormattable, ISpanParsable(Of TSelf), ISubtractionOperators(Of TSelf, TSelf, TSelf), IUnaryNegationOperators(Of TSelf, TSelf), IUnaryPlusOperators(Of TSelf, TSelf)
Public Interface INumberBase(Of TSelf)
Implements IAdditionOperators(Of TSelf, TSelf, TSelf), IAdditiveIdentity(Of TSelf, TSelf), IDecrementOperators(Of TSelf), IDivisionOperators(Of TSelf, TSelf, TSelf), IEqualityOperators(Of TSelf, TSelf, Boolean), IEquatable(Of TSelf), IIncrementOperators(Of TSelf), IMultiplicativeIdentity(Of TSelf, TSelf), IMultiplyOperators(Of TSelf, TSelf, TSelf), IParsable(Of TSelf), ISpanFormattable, ISpanParsable(Of TSelf), ISubtractionOperators(Of TSelf, TSelf, TSelf), IUnaryNegationOperators(Of TSelf, TSelf), IUnaryPlusOperators(Of TSelf, TSelf), IUtf8SpanFormattable, IUtf8SpanParsable(Of TSelf)

Parâmetros de tipo

TSelf

O tipo que implementa a interface .

Derivado
Implementações

Propriedades

One

Obtém o valor 1 do tipo.

Radix

Obtém a base para o tipo.

Zero

Obtém o valor 0 do tipo.

Métodos

Abs(TSelf)

Calcula o absoluto de um valor.

CreateChecked<TOther>(TOther)

Cria uma instância do tipo atual de um valor, gerando uma exceção de estouro para todos os valores que ficam fora do intervalo representável do tipo atual.

CreateSaturating<TOther>(TOther)

Cria uma instância do tipo atual de um valor, saturando todos os valores que ficam fora do intervalo representável do tipo atual.

CreateTruncating<TOther>(TOther)

Cria uma instância do tipo atual de um valor, truncando todos os valores que ficam fora do intervalo representável do tipo atual.

Equals(T)

Indica se o objeto atual é igual a outro objeto do mesmo tipo.

(Herdado de IEquatable<T>)
IsCanonical(TSelf)

Determina se um valor está em sua representação canônica.

IsComplexNumber(TSelf)

Determina se um valor representa um número complexo.

IsEvenInteger(TSelf)

Determina se um valor representa um número integral par.

IsFinite(TSelf)

Determina se um valor é finito.

IsImaginaryNumber(TSelf)

Determina se um valor representa um número imaginário puro.

IsInfinity(TSelf)

Determina se um valor é infinito.

IsInteger(TSelf)

Determina se um valor representa um número integral.

IsNaN(TSelf)

Determina se um valor é NaN.

IsNegative(TSelf)

Determina se um valor representa um número real negativo.

IsNegativeInfinity(TSelf)

Determina se um valor é infinito negativo.

IsNormal(TSelf)

Determina se um valor é normal.

IsOddInteger(TSelf)

Determina se um valor representa um número integral ímpar.

IsPositive(TSelf)

Determina se um valor representa zero ou um número real positivo.

IsPositiveInfinity(TSelf)

Determina se um valor é infinito positivo.

IsRealNumber(TSelf)

Determina se um valor representa um número real.

IsSubnormal(TSelf)

Determina se um valor é subnormal.

IsZero(TSelf)

Determina se um valor é zero.

MaxMagnitude(TSelf, TSelf)

Compara dois valores com a computação que tem a magnitude maior.

MaxMagnitudeNumber(TSelf, TSelf)

Compara dois valores com a computação que tem a magnitude maior e retorna o outro valor se uma entrada for NaN.

MinMagnitude(TSelf, TSelf)

Compara dois valores com a computação que tem a magnitude menor.

MinMagnitudeNumber(TSelf, TSelf)

Compara dois valores com a computação que tem a magnitude menor e retorna o outro valor se uma entrada for NaN.

Parse(ReadOnlySpan<Byte>, NumberStyles, IFormatProvider)

Analisa um intervalo de caracteres UTF-8 em um valor.

Parse(ReadOnlySpan<Char>, NumberStyles, IFormatProvider)

Analisa um intervalo de caracteres em um valor.

Parse(String, NumberStyles, IFormatProvider)

Analisa uma cadeia de caracteres em um valor.

ToString(String, IFormatProvider)

Formata o valor da instância atual usando o formato especificado.

(Herdado de IFormattable)
TryConvertFromChecked<TOther>(TOther, TSelf)

Tenta converter um valor em uma instância do tipo atual, gerando uma exceção de estouro para todos os valores que ficam fora do intervalo representável do tipo atual.

TryConvertFromSaturating<TOther>(TOther, TSelf)

Tenta converter um valor em uma instância do tipo atual, saturando todos os valores que estão fora do intervalo representável do tipo atual.

TryConvertFromTruncating<TOther>(TOther, TSelf)

Tenta converter um valor em uma instância do tipo atual, truncando todos os valores que ficam fora do intervalo representável do tipo atual.

TryConvertToChecked<TOther>(TSelf, TOther)

Tenta converter uma instância do tipo atual em outro tipo, gerando uma exceção de estouro para todos os valores que ficam fora do intervalo representável do tipo atual.

TryConvertToSaturating<TOther>(TSelf, TOther)

Tenta converter uma instância do tipo atual em outro tipo, saturando todos os valores que ficam fora do intervalo representável do tipo atual.

TryConvertToTruncating<TOther>(TSelf, TOther)

Tenta converter uma instância do tipo atual em outro tipo, truncando todos os valores que estão fora do intervalo representável do tipo atual.

TryFormat(Span<Byte>, Int32, ReadOnlySpan<Char>, IFormatProvider)

Tenta formatar o valor da instância atual como UTF-8 no intervalo fornecido de bytes.

(Herdado de IUtf8SpanFormattable)
TryFormat(Span<Char>, Int32, ReadOnlySpan<Char>, IFormatProvider)

Tenta formatar o valor da instância atual no intervalo fornecido de caracteres.

(Herdado de ISpanFormattable)
TryParse(ReadOnlySpan<Byte>, NumberStyles, IFormatProvider, TSelf)

Tenta analisar um intervalo de caracteres UTF-8 em um valor.

TryParse(ReadOnlySpan<Char>, NumberStyles, IFormatProvider, TSelf)

Tenta analisar um intervalo de caracteres em um valor.

TryParse(String, NumberStyles, IFormatProvider, TSelf)

Tenta analisar uma cadeia de caracteres em um valor.

Implantações explícitas de interface

IUtf8SpanFormattable.TryFormat(Span<Byte>, Int32, ReadOnlySpan<Char>, IFormatProvider)

Define a base de outros tipos de número.

IUtf8SpanParsable<TSelf>.Parse(ReadOnlySpan<Byte>, IFormatProvider)

Analisa um intervalo de caracteres UTF-8 em um valor.

IUtf8SpanParsable<TSelf>.TryParse(ReadOnlySpan<Byte>, IFormatProvider, TSelf)

Tenta analisar um intervalo de caracteres UTF-8 em um valor.

Aplica-se a