Class ConfigComponent<T>

java.lang.Object
com.csse3200.game.components.Component
com.csse3200.game.components.ConfigComponent<T>
Type Parameters:
T - The type of the configuration object.

public class ConfigComponent<T> extends Component
A component that holds and manages configuration data for an entity. This component can store a configuration object of a specific type directly.
  • Constructor Details

    • ConfigComponent

      public ConfigComponent(T config)
      Constructs a new ConfigComponent with the specified configuration object.
      Parameters:
      config - The configuration object associated with this component.
  • Method Details

    • getConfig

      public T getConfig()
      Retrieves the configuration object associated with this component.
      Returns:
      The configuration object.