cardano-ledger-babbage-1.8.0.0: Cardano ledger introducing refrence scripts and inline datums
Safe HaskellSafe-Inferred
LanguageHaskell2010

Cardano.Ledger.Babbage.TxInfo

Synopsis

Documentation

data BabbageContextError era Source #

Instances

Instances details
ToJSON (PlutusPurpose AsIx era) ⇒ ToJSON (BabbageContextError era) Source # 
Instance details

Defined in Cardano.Ledger.Babbage.TxInfo

Generic (BabbageContextError era) Source # 
Instance details

Defined in Cardano.Ledger.Babbage.TxInfo

Associated Types

type Rep (BabbageContextError era) ∷ TypeType Source #

(Show (AlonzoContextError era), Show (PlutusPurpose AsIx era)) ⇒ Show (BabbageContextError era) Source # 
Instance details

Defined in Cardano.Ledger.Babbage.TxInfo

(Era era, DecCBOR (PlutusPurpose AsIx era)) ⇒ DecCBOR (BabbageContextError era) Source # 
Instance details

Defined in Cardano.Ledger.Babbage.TxInfo

(Era era, EncCBOR (PlutusPurpose AsIx era)) ⇒ EncCBOR (BabbageContextError era) Source # 
Instance details

Defined in Cardano.Ledger.Babbage.TxInfo

(Era era, NFData (PlutusPurpose AsIx era)) ⇒ NFData (BabbageContextError era) Source # 
Instance details

Defined in Cardano.Ledger.Babbage.TxInfo

Methods

rnfBabbageContextError era → () Source #

(Eq (AlonzoContextError era), Eq (PlutusPurpose AsIx era)) ⇒ Eq (BabbageContextError era) Source # 
Instance details

Defined in Cardano.Ledger.Babbage.TxInfo

NoThunks (PlutusPurpose AsIx era) ⇒ NoThunks (BabbageContextError era) Source # 
Instance details

Defined in Cardano.Ledger.Babbage.TxInfo

Inject (AlonzoContextError era) (BabbageContextError era) Source # 
Instance details

Defined in Cardano.Ledger.Babbage.TxInfo

Inject (BabbageContextError era) (BabbageContextError era) Source # 
Instance details

Defined in Cardano.Ledger.Babbage.TxInfo

type Rep (BabbageContextError era) Source # 
Instance details

Defined in Cardano.Ledger.Babbage.TxInfo

type Rep (BabbageContextError era) = D1 ('MetaData "BabbageContextError" "Cardano.Ledger.Babbage.TxInfo" "cardano-ledger-babbage-1.8.0.0-inplace" 'False) ((C1 ('MetaCons "AlonzoContextError" 'PrefixI 'False) (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (AlonzoContextError era))) :+: (C1 ('MetaCons "ByronTxOutInContext" 'PrefixI 'False) (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (TxOutSource (EraCrypto era)))) :+: C1 ('MetaCons "RedeemerPointerPointsToNothing" 'PrefixI 'False) (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (PlutusPurpose AsIx era))))) :+: (C1 ('MetaCons "InlineDatumsNotSupported" 'PrefixI 'False) (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (TxOutSource (EraCrypto era)))) :+: (C1 ('MetaCons "ReferenceScriptsNotSupported" 'PrefixI 'False) (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (TxOutSource (EraCrypto era)))) :+: C1 ('MetaCons "ReferenceInputsNotSupported" 'PrefixI 'False) (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (Set (TxIn (EraCrypto era))))))))

transTxOutV1 ∷ ∀ era. (Inject (BabbageContextError era) (ContextError era), Value era ~ MaryValue (EraCrypto era), BabbageEraTxOut era) ⇒ TxOutSource (EraCrypto era) → TxOut era → Either (ContextError era) TxOut Source #

Given a TxOut, translate it for V2 and return (Right transalation). If the transaction contains any Byron addresses or Babbage features, return Left.

transTxOutV2 ∷ ∀ era. (Inject (BabbageContextError era) (ContextError era), Value era ~ MaryValue (EraCrypto era), BabbageEraTxOut era) ⇒ TxOutSource (EraCrypto era) → TxOut era → Either (ContextError era) TxOut Source #

Given a TxOut, translate it for V2 and return (Right transalation). It is possible the address part is a Bootstrap Address, in that case return Left.

transTxInInfoV1 ∷ ∀ era. (Inject (BabbageContextError era) (ContextError era), Value era ~ MaryValue (EraCrypto era), BabbageEraTxOut era) ⇒ UTxO era → TxIn (EraCrypto era) → Either (ContextError era) TxInInfo Source #

Given a TxIn, look it up in the UTxO. If it exists, translate it to the V1 context

transTxInInfoV2 ∷ ∀ era. (Inject (BabbageContextError era) (ContextError era), Value era ~ MaryValue (EraCrypto era), BabbageEraTxOut era) ⇒ UTxO era → TxIn (EraCrypto era) → Either (ContextError era) TxInInfo Source #

Given a TxIn, look it up in the UTxO. If it exists, translate it to the V2 context

transTxRedeemers ∷ (EraPlutusTxInfo l era, AlonzoEraTxBody era, EraTx era, AlonzoEraTxWits era, Inject (BabbageContextError era) (ContextError era)) ⇒ proxy l → Tx era → Either (ContextError era) (Map (PlutusScriptPurpose l) Redeemer) Source #

Translate all Redeemers from within a Tx into a Map from a PlutusScriptPurpose to a Redeemer

Orphan instances

Crypto c ⇒ EraPlutusTxInfo 'PlutusV1 (BabbageEra c) Source # 
Instance details

Crypto c ⇒ EraPlutusTxInfo 'PlutusV2 (BabbageEra c) Source # 
Instance details

Crypto c ⇒ EraPlutusContext (BabbageEra c) Source # 
Instance details

Associated Types

type ContextError (BabbageEra c) = (r ∷ Type) Source #