Interface PlanningSolutionMetaModel<Solution_>
- Type Parameters:
Solution_- the type of the solution
- All Known Implementing Classes:
DefaultPlanningSolutionMetaModel
public interface PlanningSolutionMetaModel<Solution_>
Represents the meta-model of a
PlanningSolution.
Allows access to information about all the entities and variables.
This package and all of its contents are part of the Move Streams API, which is under development and is only offered as a preview feature. There are no guarantees for backward compatibility; any class, method or field may change or be removed without prior notice, although we will strive to avoid this as much as possible.
We encourage you to try the API and give us feedback on your experience with it, before we finalize the API. Please direct your feedback to Timefold Solver Github.
-
Method Summary
Modifier and TypeMethodDescription@NonNull List<PlanningEntityMetaModel<Solution_,?>> entities()Returns the meta-models of @planning entitiesknown to the solution, genuine or shadow.default <Entity_> @NonNull PlanningEntityMetaModel<Solution_,Entity_> Returns the meta-model of the @planning entitywith the given class.default @NonNull List<PlanningEntityMetaModel<Solution_,?>> Returns the meta-models of genuine @planning entitiesknown to the solution.type()Returns the class of the solution.
-
Method Details
-
type
Returns the class of the solution.- Returns:
- never null, the type of the solution
-
entities
@NonNull List<PlanningEntityMetaModel<Solution_,?>> entities()Returns the meta-models of @planning entitiesknown to the solution, genuine or shadow.- Returns:
- Entities declared by the solution.
-
genuineEntities
Returns the meta-models of genuine @planning entitiesknown to the solution.- Returns:
- Entities declared by the solution, which declare some genuine variables.
-
entity
default <Entity_> @NonNull PlanningEntityMetaModel<Solution_,Entity_> entity(@NonNull Class<Entity_> entityClass) Returns the meta-model of the @planning entitywith the given class.- Parameters:
entityClass- Expected class of the entity.- Returns:
- An entity declared by the solution.
- Throws:
IllegalArgumentException- if the entity class is not known to the solution
-