BencodeInteger Class
A bencode integer. Bencode does not bound integers, so a value can be larger than a Int64.
public sealed class BencodeInteger : BencodeValue, IEquatable<BencodeInteger>- Inheritance
BencodeValueBencodeInteger- Implements
Constructors
| Name | Description |
|---|---|
| BencodeInteger(long) | |
| BencodeInteger(BigInteger) |
BencodeInteger overloads
BencodeInteger(long)
BencodeInteger.csBencodeInteger(BigInteger)
BencodeInteger.csProperties
| Name | Description |
|---|---|
| BigIntegerValue | Gets the value, whatever its size. |
| IsInt64 | Gets a value indicating whether the value fits in a Int64. |
| Kind | |
| Value | Gets the value as a Int64. |
BigIntegerValue
BencodeInteger.csIsInt64
BencodeInteger.csValue
BencodeInteger.csGets the value as a Int64.
public long Value { get; }Property value
Exceptions
InvalidOperationException- The value does not fit in a
Int64. UseBencodeInteger.BigIntegerValueorBencodeInteger.TryGetInt64.
Methods
| Name | Description |
|---|---|
| Equals(BencodeInteger?) | |
| Equals(object?) | |
| GetHashCode() | |
| ToString() | |
| TryGetInt64(long) | Gets the value as a Int64 when it fits in one. |
| WriteTo(BencodeWriter, bool) |
Equals overloads
Equals(BencodeInteger?)
BencodeInteger.cspublic bool Equals(BencodeInteger? other)No documentation is available.
Equals(object?)
BencodeInteger.csGetHashCode()
BencodeInteger.csToString()
BencodeInteger.csTryGetInt64(long)
BencodeInteger.csWriteTo(BencodeWriter, bool)
BencodeInteger.cspublic override void WriteTo(BencodeWriter writer, bool canonical)Parameters
writerBencodeWritercanonicalbool
No documentation is available.