Aracılığıyla paylaş


INumberBase<TSelf> Arabirim

Tanım

Diğer sayı türlerinin tabanını tanımlar.

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)

Tür Parametreleri

TSelf

Arabirimi uygulayan tür.

Türetilmiş
Uygulamalar

Özellikler

One

Türün 1 değerini alır.

Radix

Türün radiksini veya tabanını alır.

Zero

Türün 0 değerini alır.

Yöntemler

Abs(TSelf)

Bir değerin mutlak değerini hesaplar.

CreateChecked<TOther>(TOther)

Geçerli türün bir örneğini bir değerden oluşturur ve geçerli türün temsil edilebilir aralığının dışında kalan değerler için taşma özel durumu oluşturur.

CreateSaturating<TOther>(TOther)

Bir değerden geçerli türün bir örneğini oluşturur ve geçerli türün temsil edilebilir aralığının dışında kalan tüm değerleri doygun hale getirir.

CreateTruncating<TOther>(TOther)

Geçerli türün bir örneğini bir değerden oluşturur ve geçerli türün temsil edilebilir aralığının dışında kalan değerleri kesebilir.

Equals(T)

Geçerli nesnenin aynı türdeki başka bir nesneye eşit olup olmadığını gösterir.

(Devralındığı yer: IEquatable<T>)
IsCanonical(TSelf)

Bir değerin kurallı gösteriminde olup olmadığını belirler.

IsComplexNumber(TSelf)

Bir değerin karmaşık bir sayıyı temsil ediyor olup olmadığını belirler.

IsEvenInteger(TSelf)

Bir değerin çift tamsayı sayıyı temsil eder olup olmadığını belirler.

IsFinite(TSelf)

Bir değerin sonlu olup olmadığını belirler.

IsImaginaryNumber(TSelf)

Bir değerin saf bir sanal sayıyı temsil ediyor olup olmadığını belirler.

IsInfinity(TSelf)

Bir değerin sonsuz olup olmadığını belirler.

IsInteger(TSelf)

Bir değerin tam sayı olup olmadığını belirler.

IsNaN(TSelf)

Bir değerin NaN olup olmadığını belirler.

IsNegative(TSelf)

Bir değerin negatif bir gerçek sayıyı temsilip temsil etmediğini belirler.

IsNegativeInfinity(TSelf)

Bir değerin negatif sonsuz olup olmadığını belirler.

IsNormal(TSelf)

Bir değerin normal olup olmadığını belirler.

IsOddInteger(TSelf)

Bir değerin tek bir tamsayı sayısını temsil ediyor olup olmadığını belirler.

IsPositive(TSelf)

Bir değerin sıfırı mı yoksa pozitif bir gerçek sayıyı mı temsildiğini belirler.

IsPositiveInfinity(TSelf)

Bir değerin pozitif sonsuz olup olmadığını belirler.

IsRealNumber(TSelf)

Bir değerin gerçek bir sayıyı temsil ediyor olup olmadığını belirler.

IsSubnormal(TSelf)

Bir değerin normalin altında olup olmadığını belirler.

IsZero(TSelf)

Değerin sıfır olup olmadığını belirler.

MaxMagnitude(TSelf, TSelf)

daha büyük bir büyüklüğe sahip olan iki değeri işlemle karşılaştırır.

MaxMagnitudeNumber(TSelf, TSelf)

daha büyük bir büyüklüğe sahip olan ve giriş NaNdiğer değeri döndüren iki değeri işlemle karşılaştırır.

MinMagnitude(TSelf, TSelf)

daha az büyüklüğe sahip olan iki değeri işlemle karşılaştırır.

MinMagnitudeNumber(TSelf, TSelf)

daha az büyüklüğe sahip olan ve giriş NaNdiğer değeri döndüren iki değeri işlemle karşılaştırır.

MultiplyAddEstimate(TSelf, TSelf, TSelf)

(left * right) + addendtahminini hesaplar.

Parse(ReadOnlySpan<Byte>, NumberStyles, IFormatProvider)

UTF-8 karakterlik bir aralığı bir değere ayrıştırıyor.

Parse(ReadOnlySpan<Char>, NumberStyles, IFormatProvider)

Bir karakter aralığını bir değere ayrıştırıyor.

Parse(String, NumberStyles, IFormatProvider)

Bir dizeyi bir değere ayrıştırıyor.

ToString(String, IFormatProvider)

Belirtilen biçimi kullanarak geçerli örneğin değerini biçimlendirin.

(Devralındığı yer: IFormattable)
TryConvertFromChecked<TOther>(TOther, TSelf)

Geçerli türün temsil edilebilir aralığının dışında kalan değerler için taşma özel durumu oluşturarak bir değeri geçerli türün bir örneğine dönüştürmeye çalışır.

TryConvertFromSaturating<TOther>(TOther, TSelf)

Bir değeri geçerli türün bir örneğine dönüştürmeyi dener ve geçerli türün temsil edilebilir aralığının dışında kalan değerleri doygunluğa getirir.

TryConvertFromTruncating<TOther>(TOther, TSelf)

Geçerli türün temsil edilebilir aralığının dışında kalan değerleri keserek bir değeri geçerli türün bir örneğine dönüştürmeye çalışır.

TryConvertToChecked<TOther>(TSelf, TOther)

Geçerli türün bir örneğini başka bir türe dönüştürmeyi dener ve geçerli türün temsil edilebilir aralığının dışında kalan değerler için bir taşma özel durumu oluşturur.

TryConvertToSaturating<TOther>(TSelf, TOther)

Geçerli türün bir örneğini başka bir türe dönüştürmeyi dener ve geçerli türün temsil edilebilir aralığının dışında kalan değerleri doygunluğa getirir.

TryConvertToTruncating<TOther>(TSelf, TOther)

Geçerli türün bir örneğini başka bir türe dönüştürmeye çalışır ve geçerli türün temsil edilebilir aralığının dışında kalan tüm değerleri kısaltır.

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

Geçerli örneğin değerini UTF-8 olarak sağlanan bayt aralığına biçimlendirmeye çalışır.

(Devralındığı yer: IUtf8SpanFormattable)
TryFormat(Span<Char>, Int32, ReadOnlySpan<Char>, IFormatProvider)

Geçerli örneğin değerini sağlanan karakter aralığına biçimlendirmeye çalışır.

(Devralındığı yer: ISpanFormattable)
TryParse(ReadOnlySpan<Byte>, NumberStyles, IFormatProvider, TSelf)

UTF-8 karakterlik bir aralığı bir değere ayrıştırmaya çalışır.

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

Bir karakter aralığını bir değere ayrıştırmaya çalışır.

TryParse(String, NumberStyles, IFormatProvider, TSelf)

Bir dizeyi bir değere ayrıştırmaya çalışır.

Belirtik Arabirim Kullanımları

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

Geçerli örneğin değerini UTF-8 olarak sağlanan bayt aralığına biçimlendirmeye çalışır.

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

UTF-8 karakterlik bir aralığı bir değere ayrıştırıyor.

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

UTF-8 karakterlik bir aralığı bir değere ayrıştırmaya çalışır.

Şunlara uygulanır