Show / Hide Table of Contents

    Class BlockUpgradeState

    Fields relating to a protocol upgrade.

    Inheritance
    System.Object
    BlockUpgradeState
    Implements
    System.IEquatable<BlockUpgradeState>
    System.ComponentModel.DataAnnotations.IValidatableObject
    Inherited Members
    System.Object.Equals(System.Object, System.Object)
    System.Object.GetType()
    System.Object.MemberwiseClone()
    System.Object.ReferenceEquals(System.Object, System.Object)
    Namespace: Algorand.V2.Model
    Assembly: Algorand.dll
    Syntax
    [DataContract]
    public class BlockUpgradeState : IEquatable<BlockUpgradeState>, IValidatableObject

    Constructors

    | Improve this Doc View Source

    BlockUpgradeState(String, String, Nullable<Int64>, Nullable<Int64>, Nullable<Int64>)

    Initializes a new instance of the BlockUpgradeState class.

    Declaration
    public BlockUpgradeState(string currentProtocol = null, string nextProtocol = null, long? nextProtocolApprovals = default(long? ), long? nextProtocolSwitchOn = default(long? ), long? nextProtocolVoteBefore = default(long? ))
    Parameters
    Type Name Description
    System.String currentProtocol

    \[proto\] The current protocol version. (required).

    System.String nextProtocol

    \[nextproto\] The next proposed protocol version..

    System.Nullable<System.Int64> nextProtocolApprovals

    \[nextyes\] Number of blocks which approved the protocol upgrade..

    System.Nullable<System.Int64> nextProtocolSwitchOn

    \[nextswitch\] Round on which the protocol upgrade will take effect..

    System.Nullable<System.Int64> nextProtocolVoteBefore

    \[nextbefore\] Deadline round for this protocol upgrade (No votes will be consider after this round)..

    Properties

    | Improve this Doc View Source

    CurrentProtocol

    \[proto\] The current protocol version.

    Declaration
    [DataMember(Name = "current-protocol", EmitDefaultValue = false)]
    public string CurrentProtocol { get; set; }
    Property Value
    Type Description
    System.String

    \[proto\] The current protocol version.

    | Improve this Doc View Source

    NextProtocol

    \[nextproto\] The next proposed protocol version.

    Declaration
    [DataMember(Name = "next-protocol", EmitDefaultValue = false)]
    public string NextProtocol { get; set; }
    Property Value
    Type Description
    System.String

    \[nextproto\] The next proposed protocol version.

    | Improve this Doc View Source

    NextProtocolApprovals

    \[nextyes\] Number of blocks which approved the protocol upgrade.

    Declaration
    [DataMember(Name = "next-protocol-approvals", EmitDefaultValue = false)]
    public long? NextProtocolApprovals { get; set; }
    Property Value
    Type Description
    System.Nullable<System.Int64>

    \[nextyes\] Number of blocks which approved the protocol upgrade.

    | Improve this Doc View Source

    NextProtocolSwitchOn

    \[nextswitch\] Round on which the protocol upgrade will take effect.

    Declaration
    [DataMember(Name = "next-protocol-switch-on", EmitDefaultValue = false)]
    public long? NextProtocolSwitchOn { get; set; }
    Property Value
    Type Description
    System.Nullable<System.Int64>

    \[nextswitch\] Round on which the protocol upgrade will take effect.

    | Improve this Doc View Source

    NextProtocolVoteBefore

    \[nextbefore\] Deadline round for this protocol upgrade (No votes will be consider after this round).

    Declaration
    [DataMember(Name = "next-protocol-vote-before", EmitDefaultValue = false)]
    public long? NextProtocolVoteBefore { get; set; }
    Property Value
    Type Description
    System.Nullable<System.Int64>

    \[nextbefore\] Deadline round for this protocol upgrade (No votes will be consider after this round).

    Methods

    | Improve this Doc View Source

    Equals(BlockUpgradeState)

    Returns true if BlockUpgradeState instances are equal

    Declaration
    public bool Equals(BlockUpgradeState input)
    Parameters
    Type Name Description
    BlockUpgradeState input

    Instance of BlockUpgradeState to be compared

    Returns
    Type Description
    System.Boolean

    Boolean

    | Improve this Doc View Source

    Equals(Object)

    Returns true if objects are equal

    Declaration
    public override bool Equals(object input)
    Parameters
    Type Name Description
    System.Object input

    Object to be compared

    Returns
    Type Description
    System.Boolean

    Boolean

    Overrides
    System.Object.Equals(System.Object)
    | Improve this Doc View Source

    GetHashCode()

    Gets the hash code

    Declaration
    public override int GetHashCode()
    Returns
    Type Description
    System.Int32

    Hash code

    Overrides
    System.Object.GetHashCode()
    | Improve this Doc View Source

    ToJson()

    Returns the JSON string presentation of the object

    Declaration
    public virtual string ToJson()
    Returns
    Type Description
    System.String

    JSON string presentation of the object

    | Improve this Doc View Source

    ToString()

    Returns the string presentation of the object

    Declaration
    public override string ToString()
    Returns
    Type Description
    System.String

    String presentation of the object

    Overrides
    System.Object.ToString()

    Explicit Interface Implementations

    | Improve this Doc View Source

    IValidatableObject.Validate(ValidationContext)

    To validate all properties of the instance

    Declaration
    IEnumerable<ValidationResult> IValidatableObject.Validate(ValidationContext validationContext)
    Parameters
    Type Name Description
    System.ComponentModel.DataAnnotations.ValidationContext validationContext

    Validation context

    Returns
    Type Description
    System.Collections.Generic.IEnumerable<System.ComponentModel.DataAnnotations.ValidationResult>

    Validation Result

    Implements

    System.IEquatable<T>
    System.ComponentModel.DataAnnotations.IValidatableObject
    • Improve this Doc
    • View Source
    Back to top Generated by DocFX