Interface Rebaser
- All Known Implementing Classes:
MoveDirector
public interface Rebaser
Allows to transfer an entity or fact instance (often from another
Thread)
to another ScoreDirector's internal working instance.
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<T> @Nullable Trebase(@Nullable T problemFactOrPlanningEntity) Translates an entity or fact instance (often from anotherThread) to anotherScoreDirector's internal working instance.
-
Method Details
-
rebase
<T> @Nullable T rebase(@Nullable T problemFactOrPlanningEntity) Translates an entity or fact instance (often from anotherThread) to anotherScoreDirector's internal working instance. Useful for move rebasing and in aProblemChangeand for multi-threaded solving.Matching is determined by the
LookUpStrategyTypeonPlanningSolution. Matching uses aPlanningIdby default.- Type Parameters:
T-- Parameters:
problemFactOrPlanningEntity- The fact or entity to rebase.- Returns:
- null if problemFactOrPlanningEntity is null
- Throws:
IllegalArgumentException- if there is no working object for the fact or entity, if it cannot be looked up, or if its class is not supported.IllegalStateException- if it cannot be looked up
-