예제 #1
0
    public EndpointDefaults(EndpointConfig endpointConfig) {
      this.endpointConfig = endpointConfig;

      if (!endpointConfig.isSetMode()) {
        endpointConfig.setMode(EndpointConfig.Mode.COMPLEMENT);
      }
    }
예제 #2
0
  private void initConfig() {
    ProjectConfig projectConfig = this.project.getConfig();

    if (!projectConfig.isSetEndpointStrategy()) {
      projectConfig.addNewEndpointStrategy();
    }

    config =
        (DefaultEndpointStrategyConfig)
            projectConfig.getEndpointStrategy().changeType(DefaultEndpointStrategyConfig.type);

    for (EndpointConfig endpointConfig : config.getEndpointList()) {
      if (!endpointConfig.isSetMode()) {
        endpointConfig.setMode(EndpointConfig.Mode.COMPLEMENT);
      }

      defaults.put(endpointConfig.getStringValue(), new EndpointDefaults(endpointConfig));
    }
  }