Interface PlanningSolutionMetaModel<Solution_>
- Type Parameters:
Solution_- the type of the solution
- All Known Implementing Classes:
DefaultPlanningSolutionMetaModel
@NullMarked
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 TypeMethodDescriptionentities()Returns the meta-models of @planning entitiesknown to the solution, genuine or shadow.default <Entity_> PlanningEntityMetaModel<Solution_,Entity_> Returns the meta-model of the @planning entitywith the given class.default List<PlanningEntityMetaModel<Solution_,?>> Returns the meta-models of genuine @planning entitiesknown to the solution.default booleanChecks whether anPlanningEntity-annotated class is known by 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
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
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- wherehasEntity(Class)would have returned false.
-
hasEntity
Checks whether anPlanningEntity-annotated class is known by the solution.- Returns:
- True if known, false otherwise.
- See Also:
-