View Source Radixir.StitchPlan (radixir v0.0.3)

Generates stitch plans for maps that are used in requests.

Link to this section Summary

Functions

Generates stitch plan for account_identifier map.

Generates stitch plan for amount map.

Generates stitch plan for at_state_identifier map.

Generates stitch plan for cursor map.

Generates stitch plan for disable_token_mint_and_burn map.

Generates stitch plan for entity_identifier map.

Generates stitch plan for epoch map.

Generates stitch plan for fee map.

Generates stitch plan for fee_payer map.

Generates stitch plan for from map.

Generates stitch plan for from_account map.

Generates stitch plan for limit map.

Generates stitch plan for message map.

Generates stitch plan for name map.

Generates stitch plan for network_identifier map.

Generates stitch plan for owner map.

Generates stitch plan for public_key map.

Generates stitch plan for registered map.

Generates stitch plan for signature map.

Generates stitch plan for signed map.

Generates stitch plan for signed_transaction map.

Generates stitch plan for state_identifier map.

Generates stitch plan for sub_entity map.

Generates stitch plan for submit map.

Generates stitch plan for symbol map.

Generates stitch plan for to map.

Generates stitch plan for to_account map.

Generates stitch plan for token_identifier map.

Generates stitch plan for transaction map.

Generates stitch plan for transaction_identifier map.

Generates stitch plan for type map.

Generates stitch plan for unsigned_transaction map.

Generates stitch plan for url map.

Generates stitch plan for validator map.

Generates stitch plan for validator_identifier map.

Link to this section Types

Specs

params() :: keyword()

Specs

prefix_keys() :: [atom()]

Specs

stitch_plans() :: [keyword()]

Link to this section Functions

Link to this function

account_identifier(stitch_plans, params)

View Source

Specs

account_identifier(stitch_plans(), params()) :: stitch_plans()

Generates stitch plan for account_identifier map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • address (required, string): Radix address.

Examples

iex> Radixir.StitchPlan.account_identifier([], [address: "rdx1qspxpjejcn3przwrf7lvaaftm84ufrmf9yccd6xxnaj96kwykr59hvgnv42z7"])
[
  [
    keys: [:account_identifier, :address],
    value: "rdx1qspxpjejcn3przwrf7lvaaftm84ufrmf9yccd6xxnaj96kwykr59hvgnv42z7"
  ]
]
Link to this function

amount(stitch_plans, params, prefix_keys \\ [])

View Source

Specs

Generates stitch plan for amount map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • value (required, string): Amount value.
  • prefix_keys: List of atoms that will be prefixed to keys list.

Examples

iex> Radixir.StitchPlan.amount([], [value: "10"])
[
  [
    keys: [:amount, :value],
    value: "10"
  ]
]
Link to this function

at_state_identifier(stitch_plans, params)

View Source

Specs

at_state_identifier(stitch_plans(), params()) :: stitch_plans()

Generates stitch plan for at_state_identifier map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • version (optional, integer): Version.
    • timestamp (optional, string): Timestamp.
    • epoch (optional, integer): Epoch.
    • round (optional, integer): Round.

Examples

iex> Radixir.StitchPlan.at_state_identifier([], [version: 9000, round: 90])
[
  [keys: [:at_state_identifier, :version], value: 9000],
  [keys: [:at_state_identifier, :round], value: 90]
]
Link to this function

cursor(stitch_plans, params)

View Source

Specs

cursor(stitch_plans(), params()) :: stitch_plans()

Generates stitch plan for cursor map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • cursor (required, string): Cursor.

Examples

iex> Radixir.StitchPlan.cursor([], [cursor: "asdfasdf"])
[
  [
    keys: [:cursor],
    value: "asdfasdf"
  ]
]
Link to this function

disable_token_mint_and_burn(stitch_plans, params)

View Source

Specs

disable_token_mint_and_burn(stitch_plans(), params()) :: stitch_plans()

Generates stitch plan for disable_token_mint_and_burn map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • disable_token_mint_and_burn (required, boolean): Disable Token Mint and Burn.

Examples

iex> Radixir.StitchPlan.disable_token_mint_and_burn([], [disable_token_mint_and_burn: true])
[
  [
    keys: [:disable_token_mint_and_burn],
    value: true
  ]
]
Link to this function

entity_identifier(stitch_plans, params)

View Source

Specs

entity_identifier(stitch_plans(), params()) :: stitch_plans()

Generates stitch plan for entity_identifier map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • address (required, string): Radix address.

Examples

iex> Radixir.StitchPlan.entity_identifier([], [address: "rdx1qspxpjejcn3przwrf7lvaaftm84ufrmf9yccd6xxnaj96kwykr59hvgnv42z7"])
[
  [
    keys: [:entity_identifier, :address],
    value: "rdx1qspxpjejcn3przwrf7lvaaftm84ufrmf9yccd6xxnaj96kwykr59hvgnv42z7"
  ]
]
Link to this function

epoch(stitch_plans, params, prefix_keys \\ [])

View Source

Specs

Generates stitch plan for epoch map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • epoch (required, integer): Epoch.
  • prefix_keys: List of atoms that will be prefixed to keys list.

Examples

iex> Radixir.StitchPlan.epoch([], [epoch: 8])
[
  [
    keys: [:epoch],
    value: 8
  ]
]
Link to this function

fee(stitch_plans, params, prefix_keys \\ [])

View Source

Specs

Generates stitch plan for fee map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • fee (required, integer): Fee.
  • prefix_keys: List of atoms that will be prefixed to keys list.

Examples

iex> Radixir.StitchPlan.fee([], [fee: 2000000])
[
  [
    keys: [:fee],
    value: 2000000
  ]
]
Link to this function

fee_payer(stitch_plans, params)

View Source

Specs

fee_payer(stitch_plans(), params()) :: stitch_plans()

Generates stitch plan for fee_payer map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • address (required, string): Radix address.

Examples

iex> Radixir.StitchPlan.fee_payer([], [address: "rdx1qspxpjejcn3przwrf7lvaaftm84ufrmf9yccd6xxnaj96kwykr59hvgnv42z7"])
[
  [
    keys: [:fee_payer, :address],
    value: "rdx1qspxpjejcn3przwrf7lvaaftm84ufrmf9yccd6xxnaj96kwykr59hvgnv42z7"
  ]
]
Link to this function

from(stitch_plans, params, prefix_keys \\ [])

View Source

Generates stitch plan for from map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • from (required, string): Radix address.

Examples

iex> Radixir.StitchPlan.from([], [from: "rdx1qspxpjejcn3przwrf7lvaaftm84ufrmf9yccd6xxnaj96kwykr59hvgnv42z7"])
[
  [
    keys: [:from],
    value: "rdx1qspxpjejcn3przwrf7lvaaftm84ufrmf9yccd6xxnaj96kwykr59hvgnv42z7"
  ]
]
Link to this function

from_account(stitch_plans, params)

View Source

Specs

from_account(stitch_plans(), params()) :: stitch_plans()

Generates stitch plan for from_account map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • address (required, string): Radix address.

Examples

iex> Radixir.StitchPlan.from_account([], [address: "rdx1qspxpjejcn3przwrf7lvaaftm84ufrmf9yccd6xxnaj96kwykr59hvgnv42z7"])
[
  [
    keys: [:from_account, :address],
    value: "rdx1qspxpjejcn3przwrf7lvaaftm84ufrmf9yccd6xxnaj96kwykr59hvgnv42z7"
  ]
]
Link to this function

limit(stitch_plans, params)

View Source

Specs

limit(stitch_plans(), params()) :: stitch_plans()

Generates stitch plan for limit map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • limit (required, integer): Limit.

Examples

iex> Radixir.StitchPlan.limit([], [limit: 3])
[
  [
    keys: [:limit],
    value: 3
  ]
]
Link to this function

message(stitch_plans, params)

View Source

Specs

message(stitch_plans(), params()) :: stitch_plans()

Generates stitch plan for message map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • message (required, string): Message.

Examples

iex> Radixir.StitchPlan.message([], [message: "hello"])
[
  [
    keys: [:message],
    value: "hello"
  ]
]
Link to this function

name(stitch_plans, params, prefix_keys \\ [])

View Source

Specs

Generates stitch plan for name map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • name (required, string): Name.
  • prefix_keys: List of atoms that will be prefixed to keys list.

Examples

iex> Radixir.StitchPlan.name([], [name: "doug"])
[
  [
    keys: [:name],
    value: "doug"
  ]
]
Link to this function

network_identifier(stitch_plans, params \\ [])

View Source

Specs

network_identifier(stitch_plans(), params()) :: stitch_plans()

Generates stitch plan for network_identifier map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • network (optional, string): If network is not in params it will default to what is returned from Radixir.Config.network().

Examples

iex> Radixir.StitchPlan.network_identifier([], [network: "mainnet"])
[
  [
    keys: [:network_identifier, :network],
    value: "mainnet"
  ]
]
Link to this function

owner(stitch_plans, params, prefix_keys \\ [])

View Source

Specs

Generates stitch plan for owner map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • address (required, string): Owner address.
  • prefix_keys: List of atoms that will be prefixed to keys list.

Examples

iex> Radixir.StitchPlan.owner([], [address: "rdx1qspxpjejcn3przwrf7lvaaftm84ufrmf9yccd6xxnaj96kwykr59hvgnv42z7"])
[
  [
    keys: [:owner, :address],
    value: "rdx1qspxpjejcn3przwrf7lvaaftm84ufrmf9yccd6xxnaj96kwykr59hvgnv42z7"
  ]
]
Link to this function

public_key(stitch_plans, params)

View Source

Specs

public_key(stitch_plans(), params()) :: stitch_plans()

Generates stitch plan for public_key map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • hex (required, integer): Public key hex.

Examples

iex> Radixir.StitchPlan.public_key([], [hex: "027fb52f10ba5bded8c0eecee189eaecb9592353bfe8380989e2223447cfd0f2f8"])
[
  [
    keys: [:public_key, :hex],
    value: "027fb52f10ba5bded8c0eecee189eaecb9592353bfe8380989e2223447cfd0f2f8"
  ]
]
Link to this function

registered(stitch_plans, params, prefix_keys \\ [])

View Source

Specs

registered(stitch_plans(), params(), prefix_keys()) :: stitch_plans()

Generates stitch plan for registered map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • registered (required, boolean): Registered.
  • prefix_keys: List of atoms that will be prefixed to keys list.

Examples

iex> Radixir.StitchPlan.registered([], [registered: true])
[
  [
    keys: [:registered],
    value: true
  ]
]
Link to this function

signature(stitch_plans, params)

View Source

Specs

signature(stitch_plans(), params()) :: stitch_plans()

Generates stitch plan for signature map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • bytes (required, string): Signature bytes.
    • hex (required, string): Signature public key hex.

Examples

iex> Radixir.StitchPlan.signature([], [hex: "027fb52f10ba5bded8c0eecee189eaecb9592353bfe8380989e2223447cfd0f2f8", bytes: "klsdjklsdljksdfdlskfj"])
[
  [keys: [:signature, :bytes], value: "klsdjklsdljksdfdlskfj"],
  [
    keys: [:signature, :public_key, :hex],
    value: "027fb52f10ba5bded8c0eecee189eaecb9592353bfe8380989e2223447cfd0f2f8"
  ]
]
Link to this function

signed(stitch_plans, params)

View Source

Specs

signed(stitch_plans(), params()) :: stitch_plans()

Generates stitch plan for signed map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • signed (required, boolean): Signed.

Examples

iex> Radixir.StitchPlan.signed([], [signed: true])
[
  [
    keys: [:signed],
    value: true
  ]
]
Link to this function

signed_transaction(stitch_plans, params)

View Source

Specs

signed_transaction(stitch_plans(), params()) :: stitch_plans()

Generates stitch plan for signed_transaction map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • signed_transaction (required, string): Signed Transaction.

Examples

iex> Radixir.StitchPlan.signed_transaction([], [signed_transaction: "ef71a9d6c63444fce6abd2df8fab2755cfb51f6794e578f60d99337193811842ef71a9d6c63444fce6abd2df8fab2755cfb51f6794e578f60d99337193811842"])
[
  [
    keys: [:signed_transaction],
    value: "ef71a9d6c63444fce6abd2df8fab2755cfb51f6794e578f60d99337193811842ef71a9d6c63444fce6abd2df8fab2755cfb51f6794e578f60d99337193811842"
  ]
]
Link to this function

state_identifier(stitch_plans, params)

View Source

Specs

state_identifier(stitch_plans(), params()) :: stitch_plans()

Generates stitch plan for state_identifier map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • state_version (required, integer): State Version.
    • transaction_accumulator (optional, string): Transaction Accumulator.

Examples

iex> Radixir.StitchPlan.state_identifier([], [state_version: 9000])
[
  [
    keys: [:state_identifier, :state_version],
    value: 9000
  ]
]
Link to this function

sub_entity(stitch_plans, params, prefix_keys \\ [])

View Source

Specs

sub_entity(stitch_plans(), params(), prefix_keys()) :: stitch_plans()

Generates stitch plan for sub_entity map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • address (required, string): Sub Entity address.
    • validator_address (optional, string): Validator address.
    • epoch_unlock (optional, integer): Epoch unlock.
  • prefix_keys: List of atoms that will be prefixed to keys list.

Examples

iex> Radixir.StitchPlan.sub_entity([], [address: "rdx1qspxpjejcn3przwrf7lvaaftm84ufrmf9yccd6xxnaj96kwykr59hvgnv42z7"])
[
  [
    keys: [:sub_entity, :address],
    value: "rdx1qspxpjejcn3przwrf7lvaaftm84ufrmf9yccd6xxnaj96kwykr59hvgnv42z7"
  ]
]
Link to this function

submit(stitch_plans, params)

View Source

Specs

submit(stitch_plans(), params()) :: stitch_plans()

Generates stitch plan for submit map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • submit (required, boolean): Submit.

Examples

iex> Radixir.StitchPlan.submit([], [submit: false])
[
  [
    keys: [:submit],
    value: false
  ]
]
Link to this function

symbol(stitch_plans, params, prefix_keys \\ [])

View Source

Specs

Generates stitch plan for symbol map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • symbol (required, string): Symbol.
  • prefix_keys: List of atoms that will be prefixed to keys list.

Examples

iex> Radixir.StitchPlan.symbol([], [symbol: "veg"])
[
  [
    keys: [:symbol],
    value: "veg"
  ]
]
Link to this function

to(stitch_plans, params, prefix_keys \\ [])

View Source

Generates stitch plan for to map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • to (required, string): Radix address.

Examples

iex> Radixir.StitchPlan.to([], [to: "rdx1qspxpjejcn3przwrf7lvaaftm84ufrmf9yccd6xxnaj96kwykr59hvgnv42z7"])
[
  [
    keys: [:to],
    value: "rdx1qspxpjejcn3przwrf7lvaaftm84ufrmf9yccd6xxnaj96kwykr59hvgnv42z7"
  ]
]
Link to this function

to_account(stitch_plans, params)

View Source

Specs

to_account(stitch_plans(), params()) :: stitch_plans()

Generates stitch plan for to_account map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • address (required, string): Radix address.

Examples

iex> Radixir.StitchPlan.to_account([], [address: "rdx1qspxpjejcn3przwrf7lvaaftm84ufrmf9yccd6xxnaj96kwykr59hvgnv42z7"])
[
  [
    keys: [:to_account, :address],
    value: "rdx1qspxpjejcn3przwrf7lvaaftm84ufrmf9yccd6xxnaj96kwykr59hvgnv42z7"
  ]
]
Link to this function

token_identifier(stitch_plans, params, prefix_keys \\ [])

View Source

Specs

token_identifier(stitch_plans(), params(), prefix_keys()) :: stitch_plans()

Generates stitch plan for token_identifier map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • rri (required, string): Radix Resource Identifier.
  • prefix_keys: List of atoms that will be prefixed to keys list.

Examples

iex> Radixir.StitchPlan.token_identifier([], [rri: "xrd_tr1qyf0x76s"], [:hello, :there])
[
  [
    keys: [:hello, :there, :token_identifier, :rri],
    value: "xrd_tr1qyf0x76s"
  ]
]
Link to this function

transaction(stitch_plans, params)

View Source

Specs

transaction(stitch_plans(), params()) :: stitch_plans()

Generates stitch plan for transaction map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • transaction (required, string): Transaction.

Examples

iex> Radixir.StitchPlan.transaction([], [transaction: "ef71a9d6c63444fce6abd2df8fab2755cfb51f6794e57fce6abd2df8fab2755cfb51f6794e578f60d99337193811842"])
[
  [
    keys: [:transaction],
    value: "ef71a9d6c63444fce6abd2df8fab2755cfb51f6794e57fce6abd2df8fab2755cfb51f6794e578f60d99337193811842"
  ]
]
Link to this function

transaction_identifier(stitch_plans, params)

View Source

Specs

transaction_identifier(stitch_plans(), params()) :: stitch_plans()

Generates stitch plan for transaction_identifier map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • hash (required, string): Transaction Identifer hash.

Examples

iex> Radixir.StitchPlan.transaction_identifier([], [hash: "ef71a9d6c63444fce6abd2df8fab2755cfb51f6794e578f60d99337193811842"])
[
  [
    keys: [:transaction_identifier, :hash],
    value: "ef71a9d6c63444fce6abd2df8fab2755cfb51f6794e578f60d99337193811842"
  ]
]
Link to this function

type(stitch_plans, params, prefix_keys \\ [])

View Source

Specs

Generates stitch plan for type map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • type (required, string): Type.
  • prefix_keys: List of atoms that will be prefixed to keys list.

Examples

iex> Radixir.StitchPlan.type([], [type: "TokenTransfer"])
[
  [
    keys: [:type],
    value: "TokenTransfer"
  ]
]
Link to this function

unsigned_transaction(stitch_plans, params)

View Source

Specs

unsigned_transaction(stitch_plans(), params()) :: stitch_plans()

Generates stitch plan for unsigned_transaction map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • unsigned_transaction (required, string): Unsigned Transaction.

Examples

iex> Radixir.StitchPlan.unsigned_transaction([], [unsigned_transaction: "ef71a9d6c63444fce6abd2df8fab2755cfb51f6794e578f60d99337193811842ef71a9d6c63444fce6abd2df8fab2755cfb51f6794e578f60d99337193811842"])
[
  [
    keys: [:unsigned_transaction],
    value: "ef71a9d6c63444fce6abd2df8fab2755cfb51f6794e578f60d99337193811842ef71a9d6c63444fce6abd2df8fab2755cfb51f6794e578f60d99337193811842"
  ]
]
Link to this function

url(stitch_plans, params, prefix_keys \\ [])

View Source

Specs

Generates stitch plan for url map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • url (required, string): Url.
  • prefix_keys: List of atoms that will be prefixed to keys list.

Examples

iex> Radixir.StitchPlan.url([], [url: "https://google.com"])
[
  [
    keys: [:url],
    value: "https://google.com"
  ]
]
Link to this function

validator(stitch_plans, params, prefix_keys \\ [])

View Source

Specs

validator(stitch_plans(), params(), prefix_keys()) :: stitch_plans()

Generates stitch plan for validator map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • address (required, string): Validator address.
  • prefix_keys: List of atoms that will be prefixed to keys list.

Examples

iex> Radixir.StitchPlan.validator([], [address: "rvx1qspxpjejcn3przwrf7lvaaftm84ufrmf9yccd6xxnaj96kwykr59hvgnv42z7"])
[
  [
    keys: [:validator, :address],
    value: "rvx1qspxpjejcn3przwrf7lvaaftm84ufrmf9yccd6xxnaj96kwykr59hvgnv42z7"
  ]
]
Link to this function

validator_identifier(stitch_plans, params)

View Source

Specs

validator_identifier(stitch_plans(), params()) :: stitch_plans()

Generates stitch plan for validator_identifier map.

Parameters

  • stitch_plans: On-going stitch plans that will be stitched into a map.
  • params: Keyword list that contains:
    • address (required, string): Radix address.

Examples

iex> Radixir.StitchPlan.validator_identifier([], [address: "rdx1qspxpjejcn3przwrf7lvaaftm84ufrmf9yccd6xxnaj96kwykr59hvgnv42z7"])
[
  [
    keys: [:validator_identifier, :address],
    value: "rdx1qspxpjejcn3przwrf7lvaaftm84ufrmf9yccd6xxnaj96kwykr59hvgnv42z7"
  ]
]