VoteRegistrationDelegationCert
- class cometa.certificates.vote_registration_delegation_cert.VoteRegistrationDelegationCert(ptr)[source]
Bases:
objectRepresents a combined vote registration and delegation certificate.
This certificate allows registering a stake credential and delegating voting power to a DRep in a single certificate.
- classmethod new(credential, deposit, drep)[source]
Creates a new vote registration and delegation certificate.
- Parameters:
credential (Credential) – The stake credential to register.
deposit (int) – The deposit amount in lovelace.
drep (DRep) – The DRep to delegate voting power to.
- Returns:
A new VoteRegistrationDelegationCert instance.
- Raises:
CardanoError – If creation fails.
- Return type:
- classmethod from_cbor(reader)[source]
Deserializes a VoteRegistrationDelegationCert from CBOR data.
- Parameters:
reader (CborReader) – A CborReader positioned at the certificate data.
- Returns:
A new VoteRegistrationDelegationCert deserialized from the CBOR data.
- Raises:
CardanoError – If deserialization fails.
- Return type:
- to_cbor(writer)[source]
Serializes the certificate to CBOR format.
- Parameters:
writer (CborWriter) – A CborWriter to write the serialized data to.
- Raises:
CardanoError – If serialization fails.
- Return type:
None
- to_cip116_json(writer)[source]
Serializes this certificate to CIP-116 compliant JSON.
- Parameters:
writer (JsonWriter) – The JsonWriter to write the JSON to.
- Raises:
CardanoError – If serialization fails.
- Return type:
None
- property credential: Credential
The stake credential being registered.
- Returns:
The Credential associated with this certificate.
- property deposit: int
The deposit amount in lovelace.
- Returns:
The deposit amount.