4141import ai .timefold .solver .core .config .score .director .ScoreDirectorFactoryConfig ;
4242import ai .timefold .solver .core .config .solver .monitoring .MonitoringConfig ;
4343import ai .timefold .solver .core .config .solver .monitoring .SolverMetric ;
44- import ai .timefold .solver .core .config .solver .random .RandomType ;
4544import ai .timefold .solver .core .config .solver .termination .TerminationConfig ;
4645import ai .timefold .solver .core .config .util .ConfigUtils ;
4746import ai .timefold .solver .core .impl .domain .common .accessor .MemberAccessor ;
4847import ai .timefold .solver .core .impl .heuristic .selector .common .nearby .NearbyDistanceMeter ;
4948import ai .timefold .solver .core .impl .io .jaxb .SolverConfigIO ;
5049import ai .timefold .solver .core .impl .io .jaxb .TimefoldXmlSerializationException ;
5150import ai .timefold .solver .core .impl .phase .PhaseFactory ;
52- import ai .timefold .solver .core .impl .solver .random .RandomFactory ;
5351
5452import org .jspecify .annotations .NonNull ;
5553import org .jspecify .annotations .Nullable ;
6361 "enablePreviewFeatureSet" ,
6462 "environmentMode" ,
6563 "daemon" ,
66- "randomType" ,
6764 "randomSeed" ,
68- "randomFactoryClass" ,
6965 "moveThreadCount" ,
7066 "moveThreadBufferSize" ,
7167 "threadFactoryClass" ,
@@ -215,9 +211,7 @@ public final class SolverConfig extends AbstractConfig<SolverConfig> {
215211 private Set <PreviewFeature > enablePreviewFeatureSet = null ;
216212 private EnvironmentMode environmentMode = null ;
217213 private Boolean daemon = null ;
218- private RandomType randomType = null ;
219214 private Long randomSeed = null ;
220- private Class <? extends RandomFactory > randomFactoryClass = null ;
221215 private String moveThreadCount = null ;
222216 private Integer moveThreadBufferSize = null ;
223217 private Class <? extends ThreadFactory > threadFactoryClass = null ;
@@ -332,14 +326,6 @@ public void setDaemon(@Nullable Boolean daemon) {
332326 this .daemon = daemon ;
333327 }
334328
335- public @ Nullable RandomType getRandomType () {
336- return randomType ;
337- }
338-
339- public void setRandomType (@ Nullable RandomType randomType ) {
340- this .randomType = randomType ;
341- }
342-
343329 public @ Nullable Long getRandomSeed () {
344330 return randomSeed ;
345331 }
@@ -348,14 +334,6 @@ public void setRandomSeed(@Nullable Long randomSeed) {
348334 this .randomSeed = randomSeed ;
349335 }
350336
351- public @ Nullable Class <? extends RandomFactory > getRandomFactoryClass () {
352- return randomFactoryClass ;
353- }
354-
355- public void setRandomFactoryClass (@ Nullable Class <? extends RandomFactory > randomFactoryClass ) {
356- this .randomFactoryClass = randomFactoryClass ;
357- }
358-
359337 public @ Nullable String getMoveThreadCount () {
360338 return moveThreadCount ;
361339 }
@@ -471,21 +449,11 @@ public void setMonitoringConfig(@Nullable MonitoringConfig monitoringConfig) {
471449 return this ;
472450 }
473451
474- public @ NonNull SolverConfig withRandomType (@ NonNull RandomType randomType ) {
475- this .randomType = randomType ;
476- return this ;
477- }
478-
479452 public @ NonNull SolverConfig withRandomSeed (@ NonNull Long randomSeed ) {
480453 this .randomSeed = randomSeed ;
481454 return this ;
482455 }
483456
484- public @ NonNull SolverConfig withRandomFactoryClass (@ NonNull Class <? extends RandomFactory > randomFactoryClass ) {
485- this .randomFactoryClass = randomFactoryClass ;
486- return this ;
487- }
488-
489457 public @ NonNull SolverConfig withMoveThreadCount (@ NonNull String moveThreadCount ) {
490458 this .moveThreadCount = moveThreadCount ;
491459 return this ;
@@ -648,7 +616,7 @@ public boolean canTerminate() {
648616 // ************************************************************************
649617
650618 public void offerRandomSeedFromSubSingleIndex (long subSingleIndex ) {
651- if ((environmentMode == null || environmentMode .isReproducible ()) && randomFactoryClass == null && randomSeed == null ) {
619+ if ((environmentMode == null || environmentMode .isReproducible ()) && randomSeed == null ) {
652620 randomSeed = subSingleIndex ;
653621 }
654622 }
@@ -665,10 +633,7 @@ public void offerRandomSeedFromSubSingleIndex(long subSingleIndex) {
665633 inheritedConfig .getEnablePreviewFeatureSet ());
666634 environmentMode = ConfigUtils .inheritOverwritableProperty (environmentMode , inheritedConfig .getEnvironmentMode ());
667635 daemon = ConfigUtils .inheritOverwritableProperty (daemon , inheritedConfig .getDaemon ());
668- randomType = ConfigUtils .inheritOverwritableProperty (randomType , inheritedConfig .getRandomType ());
669636 randomSeed = ConfigUtils .inheritOverwritableProperty (randomSeed , inheritedConfig .getRandomSeed ());
670- randomFactoryClass = ConfigUtils .inheritOverwritableProperty (randomFactoryClass ,
671- inheritedConfig .getRandomFactoryClass ());
672637 moveThreadCount = ConfigUtils .inheritOverwritableProperty (moveThreadCount ,
673638 inheritedConfig .getMoveThreadCount ());
674639 moveThreadBufferSize = ConfigUtils .inheritOverwritableProperty (moveThreadBufferSize ,
@@ -700,7 +665,6 @@ public void offerRandomSeedFromSubSingleIndex(long subSingleIndex) {
700665
701666 @ Override
702667 public void visitReferencedClasses (@ NonNull Consumer <Class <?>> classVisitor ) {
703- classVisitor .accept (randomFactoryClass );
704668 classVisitor .accept (threadFactoryClass );
705669 classVisitor .accept (solutionClass );
706670 if (entityClassList != null ) {
0 commit comments