IBinaryNumber<TSelf> Interfejs
Definicja
Ważny
Niektóre informacje dotyczą produktów przedpremierowych, które mogą zostać znacznie zmodyfikowane przed premierą. Microsoft nie udziela żadnych gwarancji, ani wyraźnych, ani domniemanych, dotyczących informacji podanych tutaj.
Definiuje liczbę reprezentowaną w formacie base-2.
generic <typename TSelf>
where TSelf : IBinaryNumber<TSelf>public interface class IBinaryNumber : IComparable<TSelf>, IEquatable<TSelf>, IParsable<TSelf>, ISpanParsable<TSelf>, IUtf8SpanParsable<TSelf>, System::Numerics::IAdditionOperators<TSelf, TSelf, TSelf>, System::Numerics::IAdditiveIdentity<TSelf, TSelf>, System::Numerics::IBitwiseOperators<TSelf, TSelf, TSelf>, System::Numerics::IComparisonOperators<TSelf, TSelf, bool>, System::Numerics::IDecrementOperators<TSelf>, System::Numerics::IDivisionOperators<TSelf, TSelf, TSelf>, System::Numerics::IEqualityOperators<TSelf, TSelf, bool>, System::Numerics::IIncrementOperators<TSelf>, System::Numerics::IModulusOperators<TSelf, TSelf, TSelf>, System::Numerics::IMultiplicativeIdentity<TSelf, TSelf>, System::Numerics::IMultiplyOperators<TSelf, TSelf, TSelf>, System::Numerics::INumber<TSelf>, System::Numerics::INumberBase<TSelf>, System::Numerics::ISubtractionOperators<TSelf, TSelf, TSelf>, System::Numerics::IUnaryNegationOperators<TSelf, TSelf>, System::Numerics::IUnaryPlusOperators<TSelf, TSelf>
generic <typename TSelf>
where TSelf : IBinaryNumber<TSelf>public interface class IBinaryNumber : IComparable<TSelf>, IEquatable<TSelf>, IParsable<TSelf>, ISpanParsable<TSelf>, System::Numerics::IAdditionOperators<TSelf, TSelf, TSelf>, System::Numerics::IAdditiveIdentity<TSelf, TSelf>, System::Numerics::IBitwiseOperators<TSelf, TSelf, TSelf>, System::Numerics::IComparisonOperators<TSelf, TSelf, bool>, System::Numerics::IDecrementOperators<TSelf>, System::Numerics::IDivisionOperators<TSelf, TSelf, TSelf>, System::Numerics::IEqualityOperators<TSelf, TSelf, bool>, System::Numerics::IIncrementOperators<TSelf>, System::Numerics::IModulusOperators<TSelf, TSelf, TSelf>, System::Numerics::IMultiplicativeIdentity<TSelf, TSelf>, System::Numerics::IMultiplyOperators<TSelf, TSelf, TSelf>, System::Numerics::INumber<TSelf>, System::Numerics::INumberBase<TSelf>, System::Numerics::ISubtractionOperators<TSelf, TSelf, TSelf>, System::Numerics::IUnaryNegationOperators<TSelf, TSelf>, System::Numerics::IUnaryPlusOperators<TSelf, TSelf>
public interface IBinaryNumber<TSelf> : IComparable<TSelf>, IEquatable<TSelf>, IParsable<TSelf>, ISpanParsable<TSelf>, IUtf8SpanParsable<TSelf>, System.Numerics.IAdditionOperators<TSelf,TSelf,TSelf>, System.Numerics.IAdditiveIdentity<TSelf,TSelf>, System.Numerics.IBitwiseOperators<TSelf,TSelf,TSelf>, System.Numerics.IComparisonOperators<TSelf,TSelf,bool>, System.Numerics.IDecrementOperators<TSelf>, System.Numerics.IDivisionOperators<TSelf,TSelf,TSelf>, System.Numerics.IEqualityOperators<TSelf,TSelf,bool>, System.Numerics.IIncrementOperators<TSelf>, System.Numerics.IModulusOperators<TSelf,TSelf,TSelf>, System.Numerics.IMultiplicativeIdentity<TSelf,TSelf>, System.Numerics.IMultiplyOperators<TSelf,TSelf,TSelf>, System.Numerics.INumber<TSelf>, System.Numerics.INumberBase<TSelf>, System.Numerics.ISubtractionOperators<TSelf,TSelf,TSelf>, System.Numerics.IUnaryNegationOperators<TSelf,TSelf>, System.Numerics.IUnaryPlusOperators<TSelf,TSelf> where TSelf : IBinaryNumber<TSelf>
public interface IBinaryNumber<TSelf> : IComparable<TSelf>, IEquatable<TSelf>, IParsable<TSelf>, ISpanParsable<TSelf>, System.Numerics.IAdditionOperators<TSelf,TSelf,TSelf>, System.Numerics.IAdditiveIdentity<TSelf,TSelf>, System.Numerics.IBitwiseOperators<TSelf,TSelf,TSelf>, System.Numerics.IComparisonOperators<TSelf,TSelf,bool>, System.Numerics.IDecrementOperators<TSelf>, System.Numerics.IDivisionOperators<TSelf,TSelf,TSelf>, System.Numerics.IEqualityOperators<TSelf,TSelf,bool>, System.Numerics.IIncrementOperators<TSelf>, System.Numerics.IModulusOperators<TSelf,TSelf,TSelf>, System.Numerics.IMultiplicativeIdentity<TSelf,TSelf>, System.Numerics.IMultiplyOperators<TSelf,TSelf,TSelf>, System.Numerics.INumber<TSelf>, System.Numerics.INumberBase<TSelf>, System.Numerics.ISubtractionOperators<TSelf,TSelf,TSelf>, System.Numerics.IUnaryNegationOperators<TSelf,TSelf>, System.Numerics.IUnaryPlusOperators<TSelf,TSelf> where TSelf : IBinaryNumber<TSelf>
type IBinaryNumber<'Self (requires 'Self :> IBinaryNumber<'Self>)> = interface
interface IComparable
interface IComparable<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface IEquatable<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface IFormattable
interface IParsable<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface ISpanFormattable
interface ISpanParsable<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface IAdditionOperators<'Self, 'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IAdditiveIdentity<'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IBitwiseOperators<'Self, 'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IComparisonOperators<'Self, 'Self, bool (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IEqualityOperators<'Self, 'Self, bool (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IDecrementOperators<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface IDivisionOperators<'Self, 'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IIncrementOperators<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface IModulusOperators<'Self, 'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IMultiplicativeIdentity<'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IMultiplyOperators<'Self, 'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface INumber<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface INumberBase<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface IUtf8SpanFormattable
interface IUtf8SpanParsable<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface ISubtractionOperators<'Self, 'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IUnaryNegationOperators<'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IUnaryPlusOperators<'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
type IBinaryNumber<'Self (requires 'Self :> IBinaryNumber<'Self>)> = interface
interface IComparable
interface IComparable<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface IEquatable<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface IFormattable
interface IParsable<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface ISpanFormattable
interface ISpanParsable<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface IAdditionOperators<'Self, 'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IAdditiveIdentity<'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IBitwiseOperators<'Self, 'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IComparisonOperators<'Self, 'Self, bool (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IEqualityOperators<'Self, 'Self, bool (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IDecrementOperators<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface IDivisionOperators<'Self, 'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IIncrementOperators<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface IModulusOperators<'Self, 'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IMultiplicativeIdentity<'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IMultiplyOperators<'Self, 'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface INumber<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface INumberBase<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface ISubtractionOperators<'Self, 'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IUnaryNegationOperators<'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IUnaryPlusOperators<'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
type IBinaryNumber<'Self (requires 'Self :> IBinaryNumber<'Self>)> = interface
interface IComparable
interface IComparable<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface IEquatable<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface IFormattable
interface IParsable<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface ISpanFormattable
interface ISpanParsable<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface IAdditionOperators<'Self, 'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IAdditiveIdentity<'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IBitwiseOperators<'Self, 'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IComparisonOperators<'Self, 'Self, bool (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IEqualityOperators<'Self, 'Self, bool (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IDecrementOperators<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface IDivisionOperators<'Self, 'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IIncrementOperators<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface IModulusOperators<'Self, 'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IMultiplicativeIdentity<'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IMultiplyOperators<'Self, 'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface INumber<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface INumberBase<'Self (requires 'Self :> IBinaryNumber<'Self>)>
interface ISubtractionOperators<'Self, 'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IUnaryNegationOperators<'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IUnaryPlusOperators<'Self, 'Self (requires 'Self :> IBinaryNumber<'Self> and 'Self :> IBinaryNumber<'Self>)>
interface IUtf8SpanFormattable
interface IUtf8SpanParsable<'Self (requires 'Self :> IBinaryNumber<'Self>)>
Public Interface IBinaryNumber(Of TSelf)
Implements IAdditionOperators(Of TSelf, TSelf, TSelf), IAdditiveIdentity(Of TSelf, TSelf), IBitwiseOperators(Of TSelf, TSelf, TSelf), IComparable(Of TSelf), IComparisonOperators(Of TSelf, TSelf, Boolean), IDecrementOperators(Of TSelf), IDivisionOperators(Of TSelf, TSelf, TSelf), IEqualityOperators(Of TSelf, TSelf, Boolean), IEquatable(Of TSelf), IIncrementOperators(Of TSelf), IModulusOperators(Of TSelf, TSelf, TSelf), IMultiplicativeIdentity(Of TSelf, TSelf), IMultiplyOperators(Of TSelf, TSelf, TSelf), INumber(Of TSelf), INumberBase(Of TSelf), IParsable(Of TSelf), ISpanParsable(Of TSelf), ISubtractionOperators(Of TSelf, TSelf, TSelf), IUnaryNegationOperators(Of TSelf, TSelf), IUnaryPlusOperators(Of TSelf, TSelf), IUtf8SpanParsable(Of TSelf)
Public Interface IBinaryNumber(Of TSelf)
Implements IAdditionOperators(Of TSelf, TSelf, TSelf), IAdditiveIdentity(Of TSelf, TSelf), IBitwiseOperators(Of TSelf, TSelf, TSelf), IComparable(Of TSelf), IComparisonOperators(Of TSelf, TSelf, Boolean), IDecrementOperators(Of TSelf), IDivisionOperators(Of TSelf, TSelf, TSelf), IEqualityOperators(Of TSelf, TSelf, Boolean), IEquatable(Of TSelf), IIncrementOperators(Of TSelf), IModulusOperators(Of TSelf, TSelf, TSelf), IMultiplicativeIdentity(Of TSelf, TSelf), IMultiplyOperators(Of TSelf, TSelf, TSelf), INumber(Of TSelf), INumberBase(Of TSelf), IParsable(Of TSelf), ISpanParsable(Of TSelf), ISubtractionOperators(Of TSelf, TSelf, TSelf), IUnaryNegationOperators(Of TSelf, TSelf), IUnaryPlusOperators(Of TSelf, TSelf)
Parametry typu
- TSelf
Typ implementujący interfejs.
- Pochodny
- Implementuje
-
IComparable IComparable<TSelf> IEquatable<TSelf> IFormattable IParsable<TSelf> ISpanFormattable ISpanParsable<TSelf> IUtf8SpanFormattable IUtf8SpanParsable<TSelf> IAdditionOperators<TSelf,TSelf,TSelf> IAdditiveIdentity<TSelf,TSelf> IBitwiseOperators<TSelf,TSelf,TSelf> IComparisonOperators<TSelf,TSelf,Boolean> IDecrementOperators<TSelf> IDivisionOperators<TSelf,TSelf,TSelf> IEqualityOperators<TSelf,TOther,TResult> IEqualityOperators<TSelf,TSelf,Boolean> IIncrementOperators<TSelf> IModulusOperators<TSelf,TSelf,TSelf> IMultiplicativeIdentity<TSelf,TSelf> IMultiplyOperators<TSelf,TSelf,TSelf> INumber<TSelf> INumberBase<TSelf> ISubtractionOperators<TSelf,TSelf,TSelf> IUnaryNegationOperators<TSelf,TSelf> IUnaryPlusOperators<TSelf,TSelf>
Właściwości
| Nazwa | Opis |
|---|---|
| AllBitsSet |
Pobiera wystąpienie typu binarnego, w którym są ustawione wszystkie bity. |
Metody
| Nazwa | Opis |
|---|---|
| CompareTo(Object) |
Porównuje bieżące wystąpienie z innym obiektem tego samego typu i zwraca liczbę całkowitą wskazującą, czy bieżące wystąpienie poprzedza, następuje, czy występuje w tej samej pozycji w kolejności sortowania co drugi obiekt. (Dziedziczone od IComparable) |
| CompareTo(T) |
Porównuje bieżące wystąpienie z innym obiektem tego samego typu i zwraca liczbę całkowitą wskazującą, czy bieżące wystąpienie poprzedza, następuje, czy występuje w tej samej pozycji w kolejności sortowania co drugi obiekt. (Dziedziczone od IComparable<T>) |
| Equals(T) |
Wskazuje, czy bieżący obiekt jest równy innemu obiektowi tego samego typu. (Dziedziczone od IEquatable<T>) |
| IsPow2(TSelf) |
Określa, czy wartość jest potęgą dwóch. |
| Log2(TSelf) |
Oblicza dziennik2 wartości. |
| ToString(String, IFormatProvider) |
Formatuje wartość bieżącego wystąpienia przy użyciu określonego formatu. (Dziedziczone od IFormattable) |
| TryFormat(Span<Byte>, Int32, ReadOnlySpan<Char>, IFormatProvider) |
Próbuje sformatować wartość bieżącego wystąpienia jako UTF-8 w podanym zakresie bajtów. (Dziedziczone od IUtf8SpanFormattable) |
| TryFormat(Span<Char>, Int32, ReadOnlySpan<Char>, IFormatProvider) |
Próbuje sformatować wartość bieżącego wystąpienia w podanym zakresie znaków. (Dziedziczone od ISpanFormattable) |
Implementacje interfejsów jawnych
| Nazwa | Opis |
|---|---|
| IUtf8SpanFormattable.TryFormat(Span<Byte>, Int32, ReadOnlySpan<Char>, IFormatProvider) |
Próbuje sformatować wartość bieżącego wystąpienia jako UTF-8 w podanym zakresie bajtów. (Dziedziczone od INumberBase<TSelf>) |
| IUtf8SpanParsable<TSelf>.Parse(ReadOnlySpan<Byte>, IFormatProvider) |
Analizuje zakres znaków UTF-8 w wartość. (Dziedziczone od INumberBase<TSelf>) |
| IUtf8SpanParsable<TSelf>.TryParse(ReadOnlySpan<Byte>, IFormatProvider, TSelf) |
Próbuje przeanalizować zakres znaków UTF-8 w wartość. (Dziedziczone od INumberBase<TSelf>) |