Class CraftingFacility

Hierarchy

  • CraftingFacility

Implements

  • Account

Constructors

  • Parameters

    • _data: AnchorTypeDef<Object, AnchorDefined<CraftingIDL, Record<string, never>>>
    • _key: PublicKey
    • _recipeCategories: PublicKey[]

    Returns CraftingFacility

Properties

ACCOUNT_NAME: "craftableItem" | "craftingFacility" | "craftingProcess" | "domain" | "recipe" | "recipeCategory" = 'craftingFacility'
MIN_DATA_SIZE: number = CRAFTING_FACILITY_MIN_DATA_SIZE

Accessors

  • get data(): Readonly<AnchorTypeDef<Object, AnchorDefined<CraftingIDL, Record<string, never>>>>
  • Returns Readonly<AnchorTypeDef<Object, AnchorDefined<CraftingIDL, Record<string, never>>>>

  • get key(): PublicKey
  • Returns PublicKey

  • get recipeCategories(): readonly PublicKey[]
  • Returns readonly PublicKey[]

Methods

  • Updates a Crafting Facility's Recipe Category

    Returns

    InstructionReturn

    Parameters

    • program: CraftingIDLProgram

      Crafting IDL program

    • craftingFacility: PublicKey

      Crafting Facility Account key

    • key: AsyncSigner<unknown>

      Key authorized to use this instruction

    • profile: PublicKey

      Profile with required Crafting Permissions

    • domain: PublicKey

      Domain Account key

    • recipeCategory: PublicKey

      New Recipe Category Account key

    • input: KeyIndexInput

      Key index

    Returns InstructionReturn

  • Deregisters and Closes a Crafting Facility

    Returns

    InstructionReturn

    Parameters

    • program: CraftingIDLProgram

      Crafting IDL program

    • craftingFacility: PublicKey

      Crafting Facility to close

    • key: AsyncSigner<unknown>

      Key authorized to use this instruction

    • profile: PublicKey

      Profile with required Crafting Permission

    • fundsTo: PublicKey | "funder"

      Account where rent fees are debited

    • domain: PublicKey

      Domain Account

    • input: KeyIndexInput

      Key index

    Returns InstructionReturn

  • Registers new Crafting Facility

    Returns

    InstructionReturn

    Parameters

    • program: CraftingIDLProgram

      Crafting IDL program

    • craftingFacility: AsyncSigner<unknown>

      The new Crafting Facility Account

    • key: AsyncSigner<unknown>

      Key authorized to use this instruction

    • profile: PublicKey

      Profile Account with required Crafting Permissions

    • domain: PublicKey

      Domain Account key

    • location: PublicKey

      Location Address key

    • input: RegisterCraftingFacilityInput

      input params

    Returns InstructionReturn

  • Removes a Crafting Facility's Recipe Category

    Returns

    InstructionReturn

    Parameters

    • program: CraftingIDLProgram

      Crafting IDL program

    • craftingFacility: PublicKey

      Crafting Facility key

    • key: AsyncSigner<unknown>

      Key authorized to use this instruction

    • profile: PublicKey

      Profile with the required Crafting permissions

    • domain: PublicKey

      Domain Account key

    • recipeCategory: PublicKey

      Recipe Category to be removed

    • input: RemoveCraftingFacilityRecipeCategoryInput

      Input struct for removeCraftingFacilityRecipeCategory instruction

    Returns InstructionReturn

  • Updates existing Crafting Facility Account

    Returns

    InstructionReturn

    Parameters

    • program: CraftingIDLProgram

      Crafting IDL program

    • craftingFacility: PublicKey

      Crafting Facility Account key

    • key: AsyncSigner<unknown>

      Key authorized to use this instruction

    • profile: PublicKey

      Profile Account with the required Crafting Permissions

    • domain: PublicKey

      Domain Account key

    • input: UpdateCraftingFacilityInput

      input params

    Returns InstructionReturn

Generated using TypeDoc