docs.unity3d.com
    Show / Hide Table of Contents

    Class EconomyReference

    A reference to another resource definition from within a purchase.

    Inheritance
    Object
    EconomyReference
    Inherited Members
    Object.ToString()
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Namespace: Unity.Services.Economy.Model
    Syntax
    [Preserve]
    public class EconomyReference

    Constructors

    EconomyReference(ConfigurationItemDefinition)

    Declaration
    [Preserve]
    public EconomyReference(ConfigurationItemDefinition configItem)
    Parameters
    Type Name Description
    ConfigurationItemDefinition configItem

    Methods

    GetReferencedConfigurationItem()

    Gets the referenced configuration item, which will automatically be deserialized to its target type.

    You can cast to this type by checking the Type parameter of the returned ConfigurationItemDefinition, and then casting to either InventoryItemDefinition or CurrencyDefinition as appropriate.

    Declaration
    [Preserve]
    public ConfigurationItemDefinition GetReferencedConfigurationItem()
    Returns
    Type Description
    ConfigurationItemDefinition

    Either a CurrencyDefinition or an InventoryItemDefinition, depending on the underlying item Type.

    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023