-
public abstract class Model<T extends Model.Data>The base class which provides a common structure for models that collect and expose data structures.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public abstract classModel.DataAn abstract base class for representing model data.
This class provides a common structure for data associated with models. It includes a utility function for converting the data to a map representation.
-
Method Summary
Modifier and Type Method Description Unitinitialize(ModelContext modelContext)Sets up the model with the specified ModelContext. abstract Tget(ModelContext modelContext)Retrieves the data associated with this model. -
-
Method Detail
-
initialize
Unit initialize(ModelContext modelContext)
Sets up the model with the specified ModelContext.
This method can be overridden by subclasses to perform initialization or setup tasks specific to the model.
- Parameters:
modelContext- The context in which the model is being set up.
-
get
abstract T get(ModelContext modelContext)
Retrieves the data associated with this model.
This method must be implemented by subclasses to provide the logic for fetching the model data.
- Parameters:
modelContext- The context in which the data is being retrieved.
-
-
-
-