src/core/reinforcement/policy/executablepolicy/ExecutablePolicyFactory.java
public static ExecutablePolicy create(ExecutablePolicyType executablePolicyType, String params) throws DynamicParamException {
        return switch (executablePolicyType) {
            case GREEDY -> new GreedyPolicy();
            case EPSILON_GREEDY -> params == null ? new EpsilonGreedyPolicy() : new EpsilonGreedyPolicy(params);
            case NOISY_NEXT_BEST -> params == null ? new NoisyNextBestPolicy() : new NoisyNextBestPolicy(params);
            case SAMPLED -> params == null ? new SampledPolicy() : new SampledPolicy(params);
            case MCTS -> params == null ? new MCTSPolicy() : new MCTSPolicy(params);
        };
    }
/**
     * Creates executable policy instance of given type with defined parameters.
     *
     * @param executablePolicyType type of executable policy.
     * @param params parameters for executable policy.
     * @return constructed executable policy.
     * @throws DynamicParamException throws exception if parameter (params) setting fails.
     */
Creates executable policy instance of given type with defined parameters.

@param executablePolicyType type of executable policy.
@param params parameters for executable policy.
@return constructed executable policy.
@throws DynamicParamException throws exception if parameter (params) setting fails.
Creates executable policy instance of given type with defined parameters . @param executablePolicyType type of executable policy . @param params parameters for executable policy . @return constructed executable policy . @throws DynamicParamException throws exception if parameter ( params ) setting fails .
public static ExecutablePolicy create(ExecutablePolicyType executablePolicyType, String params) throws DynamicParamException {
        return switch (executablePolicyType) {
            case GREEDY -> new GreedyPolicy();
            case EPSILON_GREEDY -> params == null ? new EpsilonGreedyPolicy() : new EpsilonGreedyPolicy(params);
            case NOISY_NEXT_BEST -> params == null ? new NoisyNextBestPolicy() : new NoisyNextBestPolicy(params);
            case SAMPLED -> params == null ? new SampledPolicy() : new SampledPolicy(params);
            case MCTS -> params == null ? new MCTSPolicy() : new MCTSPolicy(params);
        };
    }
public static ExecutablePolicy create ( ExecutablePolicyType executablePolicyType , String params ) throws DynamicParamException { return switch ( executablePolicyType ) { case GREEDY -> new GreedyPolicy ( ) ; case EPSILON_GREEDY -> params == null ? new EpsilonGreedyPolicy ( ) : new EpsilonGreedyPolicy ( params ) ; case NOISY_NEXT_BEST -> params == null ? new NoisyNextBestPolicy ( ) : new NoisyNextBestPolicy ( params ) ; case SAMPLED -> params == null ? new SampledPolicy ( ) : new SampledPolicy ( params ) ; case MCTS -> params == null ? new MCTSPolicy ( ) : new MCTSPolicy ( params ) ; } ; }
Creates executable policy instance of given type with defined parameters.
Creates executable policy instance of given type with defined parameters .