// Copyright (c) Microsoft Corporation. // Licensed under the MIT License. using UnityEngine.EventSystems; namespace Microsoft.MixedReality.Toolkit.Experimental.InteractiveElement { /// /// Base class for event receivers. /// public abstract class BaseEventReceiver { /// /// Constructor for an event receiver. /// /// The associated serialized event configuration for an event receiver. public BaseEventReceiver(BaseInteractionEventConfiguration eventConfiguration) { EventConfiguration = eventConfiguration; StateName = EventConfiguration.StateName; } /// /// The event configuration for this event receiver. /// public IStateEventConfig EventConfiguration { get; protected set; } = null; /// /// The name of the state this event receiver is watching. /// public string StateName { get; protected set; } = null; /// /// Update an event receiver. /// public abstract void OnUpdate(StateManager stateManager, BaseEventData eventData); } }