shardingsphere-infra/shardingsphere-infra-optimize/src/main/java/org/apache/shardingsphere/infra/optimize/context/OptimizerContextFactory.java
/**
     * Create optimize context.
     *
     * @param metaDataMap meta data map
     * @return created optimizer context
     */
Create optimize context.
@param metaDataMap meta data map
@return created optimizer context
Create optimize context . @param metaDataMap meta data map @return created optimizer context
public static OptimizerContext create(final Map<String, ShardingSphereMetaData> metaDataMap) {
        FederationMetaData federationMetaData = new FederationMetaData(metaDataMap);
        Map<String, OptimizerParserContext> parserContexts = OptimizerParserContextFactory.create(metaDataMap);
        Map<String, OptimizerPlannerContext> plannerContexts = OptimizerPlannerContextFactory.create(federationMetaData);
        return new OptimizerContext(federationMetaData, parserContexts, plannerContexts);
    }
public static OptimizerContext create ( final Map < String , ShardingSphereMetaData > metaDataMap ) { FederationMetaData federationMetaData = new FederationMetaData ( metaDataMap ) ; Map < String , OptimizerParserContext > parserContexts = OptimizerParserContextFactory . create ( metaDataMap ) ; Map < String , OptimizerPlannerContext > plannerContexts = OptimizerPlannerContextFactory . create ( federationMetaData ) ; return new OptimizerContext ( federationMetaData , parserContexts , plannerContexts ) ; }
Create optimize context.
Create optimize context .