Creates a static prototype of the Feature Collector, which includes any
specific settings or configuration required for the use of this
collector, including settings for connecting to any source systems.

@return A configured Feature Collector prototype
970614
public static FeatureCollector prototype(JiraMode mode) {
		FeatureCollector protoType = new FeatureCollector();

		protoType.setName(FeatureCollectorConstants.JIRA);
		protoType.setOnline(true);
        protoType.setEnabled(true);
		protoType.setCollectorType(CollectorType.AgileTool);

		Map<String, Object> allOptions = new HashMap<>();
		allOptions.put(FeatureBoard.TOOL_TYPE, "");
		allOptions.put(FeatureBoard.PROJECT_NAME, "");
		allOptions.put(FeatureBoard.PROJECT_ID, "");
		allOptions.put(FeatureBoard.TEAM_NAME, "");
		allOptions.put(FeatureBoard.TEAM_ID, "");
		allOptions.put(FeatureBoard.ESTIMATE_METRIC_TYPE, "");
		allOptions.put(FeatureBoard.SPRINT_TYPE, "");
		allOptions.put(FeatureBoard.LIST_TYPE, "");
		allOptions.put(FeatureBoard.SHOW_STATUS, "");
		protoType.setAllFields(allOptions);

		Map<String, Object> uniqueOptions = new HashMap<>();
		uniqueOptions.put(FeatureBoard.TOOL_TYPE, "");
		uniqueOptions.put(FeatureBoard.PROJECT_NAME, "");
		uniqueOptions.put(FeatureBoard.PROJECT_ID, "");
		uniqueOptions.put(FeatureBoard.TEAM_NAME, "");
		uniqueOptions.put(FeatureBoard.TEAM_ID, "");

		protoType.setUniqueFields(uniqueOptions);

		Map<String, Object> properties = new HashMap<>();
		properties.put("mode", mode);
		protoType.setProperties(properties);

		return protoType;
	}
1360089
public static JADT standardConfigDriver() {
    	logger.fine("Using standard configuration.");
        final SourceFactory sourceFactory = new FileSourceFactory();
        final ClassBodyEmitter classBodyEmitter = new StandardClassBodyEmitter();
        final ConstructorEmitter constructorEmitter = new StandardConstructorEmitter(classBodyEmitter);
        final DataTypeEmitter dataTypeEmitter = new StandardDataTypeEmitter(classBodyEmitter, constructorEmitter);
        final DocEmitter docEmitter = new StandardDocEmitter(dataTypeEmitter);      
        final Parser parser = new StandardParser(new JavaCCParserImplFactory());
        final Checker checker = new StandardChecker();
        final SinkFactoryFactory factoryFactory = new FileSinkFactoryFactory();
        
        return new JADT(sourceFactory, parser, checker, docEmitter, factoryFactory);
    }
753682
public FacesConfigBehaviorType<FacesConfigType<T>> getOrCreateBehavior()
   {
      List<Node> nodeList = childNode.get("behavior");
      if (nodeList != null &&  nodeList.size() > 0)
      {
         return new FacesConfigBehaviorTypeImpl<FacesConfigType<T>>(this, "behavior", childNode, nodeList.get(0));
      }
      return createBehavior();
   }
1328983
protected function createFeature()
    {
        $feature = new Feature($this, $this->getId());
        $feature->setProperty('type', lcfirst(static::getType()));
        $feature->setProperty('options', $this->getOptions());

        return $feature;
    }
227479
public static IbanLengthMapSharedConstants create() {
    if (ibanLengthMapConstants == null) { // NOPMD it's thread save!
      synchronized (IbanLengthMapConstantsClient.class) {
        if (ibanLengthMapConstants == null) {
          final IbanLengthMapConstants ibanLengthMap = GWT.create(IbanLengthMapConstants.class);
          ibanLengthMapConstants = new IbanLengthMapConstantsClient(ibanLengthMap.ibanLengths());
        }
      }
    }
    return ibanLengthMapConstants;
  }
1317319
public static FeatureCollection fromFeature(@NonNull Feature feature) {
    List<Feature> featureList = Arrays.asList(feature);
    return new FeatureCollection(TYPE, null, featureList);
  }
1056869
private <O extends Featurable> O createFeaturable(Class<O> type, Setup setup) throws NoSuchMethodException
    {
        final O featurable = UtilReflection.createReduce(type, services, setup);
        addFeatures(featurable, services, setup);
        for (final Feature feature : featurable.getFeatures())
        {
            featurable.checkListener(feature);
            for (final Feature other : featurable.getFeatures())
            {
                if (feature != other)
                {
                    other.checkListener(feature);
                }
            }
        }
        return featurable;
    }
495761
public FacesConfigConverterType<WebFacesConfigDescriptor> getOrCreateConverter()
   {
      List<Node> nodeList = model.get("converter");
      if (nodeList != null &&  nodeList.size() > 0)
      {
         return new FacesConfigConverterTypeImpl<WebFacesConfigDescriptor>(this, "converter", model, nodeList.get(0));
      }
      return createConverter();
   }
278137
public FacesConfigAttributeType<FacesConfigConverterType<T>> getOrCreateAttribute()
   {
      List<Node> nodeList = childNode.get("attribute");
      if (nodeList != null &&  nodeList.size() > 0)
      {
         return new FacesConfigAttributeTypeImpl<FacesConfigConverterType<T>>(this, "attribute", childNode, nodeList.get(0));
      }
      return createAttribute();
   }
792034
public static Factory newInstance() {
        ScheduledExecutorService scheduler = newSingleThreadScheduledExecutor(new ThreadFactory() {
            public Thread newThread(Runnable r) {
                Thread result = new Thread(r);
                result.setDaemon(true);
                return result;
            }
        });
        Properties props = new Properties();
        return new DefaultFactory(scheduler, props);
    }
177877
public static Configuration createBasicConfiguration()
    {
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.entry(tc, "createBasicConfiguration()");

        Configuration config = new Configuration();

        try
        {
            config.loadFromPropertyFile();
        }
        catch (IOException ioe)
        {
            //No FFDC Code Needed.
            config.datasourceClassname = "org.apache.derby.jdbc.EmbeddedConnectionPoolDataSource";
            config.datasourceProperties.setProperty("databaseName",System.getProperty("js.test.dbname","msdb"));
            config.datasourceProperties.setProperty("createDatabase","create");
        }

        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.exit(tc, "createBasicConfiguration()", config);

        return(config);
    }
535321
public ConfigProperty<Resourceadapter<T>> getOrCreateConfigProperty()
   {
      List<Node> nodeList = childNode.get("config-property");
      if (nodeList != null &&  nodeList.size() > 0)
      {
         return new ConfigPropertyImpl<Resourceadapter<T>>(this, "config-property", childNode, nodeList.get(0));
      }
      return createConfigProperty();
   }
1003276
public static ConfigBuilder configBuilder() {
    return new ConfigBuilder(new StringReader(""), new StringWriter(),
        EMPTY_CONNECTION_FACTORY, EMPTY_COMMAND_HANDLER,
        EMPTY_PROPERTY_HANDLER, EMPTY_ENV, DEFAULT_MAX_STACK_LENGTH);
  }
421025
protected static function create()
    {
        $config = new static();

        $config->config = (new ConfigFactory())->create($config->getProjectPath(), $config->CONFIG_FILE);

        return $config;
    }
1246119
public static AppdynamicsCollector prototype(AppdynamicsSettings settings) {
        AppdynamicsCollector protoType = new AppdynamicsCollector();
        protoType.setName("Appdynamics");
        protoType.setCollectorType(CollectorType.AppPerformance);
        protoType.setOnline(true);
        protoType.setEnabled(true);
        protoType.setLastExecuted(System.currentTimeMillis());
        protoType.setInstanceUrl(settings.getInstanceUrlList());

        Map<String, Object> allOptions = new HashMap<>();
        allOptions.put(AppdynamicsApplication.APP_DASHBOARD_URL,"");
        allOptions.put(AppdynamicsApplication.APP_NAME,"");
        allOptions.put(AppdynamicsApplication.APP_DESC, "");
        allOptions.put(AppdynamicsApplication.APP_INSTANCE_ID, "");
        protoType.setAllFields(allOptions);

        Map<String, Object> uniqueOptions = new HashMap<>();
        uniqueOptions.put(AppdynamicsApplication.APP_DASHBOARD_URL,"");
        uniqueOptions.put(AppdynamicsApplication.APP_NAME,"");
        protoType.setUniqueFields(uniqueOptions);
        return protoType;
    }
695395
protected T createInstance() {
        try {
            Constructor<T> ctor = clazz.getDeclaredConstructor();
            ctor.setAccessible(true);
            return ctor.newInstance();
        } catch (InstantiationException e) {
            throw new RuntimeException(e);
        } catch (IllegalAccessException e) {
            throw new RuntimeException(e);
        } catch (SecurityException e) {
            throw new RuntimeException(e);
        } catch (NoSuchMethodException e) {
            throw new RuntimeException(e);
        } catch (IllegalArgumentException e) {
            throw new RuntimeException(e);
        } catch (InvocationTargetException e) {
            throw new RuntimeException(e);
        }
    }
144470
public static Builder newParserConfigBuilder() {
        return new Builder() {
            boolean used = false;
            CollectionBuilder.Factory listFactory = DEFAULT_LIST_FACTORY;
            CollectionBuilder.Factory vectorFactory = DEFAULT_VECTOR_FACTORY;
            CollectionBuilder.Factory setFactory = DEFAULT_SET_FACTORY;
            CollectionBuilder.Factory mapFactory = DEFAULT_MAP_FACTORY;
            Map<Tag, TagHandler> tagHandlers = defaultTagHandlers();

            public Builder setListFactory(CollectionBuilder.Factory listFactory) {
                checkState();
                this.listFactory = listFactory;
                return this;
            }

            public Builder setVectorFactory(CollectionBuilder.Factory vectorFactory) {
                checkState();
                this.vectorFactory = vectorFactory;
                return this;
            }

            public Builder setSetFactory(CollectionBuilder.Factory setFactory) {
                checkState();
                this.setFactory = setFactory;
                return this;
            }

            public Builder setMapFactory(CollectionBuilder.Factory mapFactory) {
                checkState();
                this.mapFactory = mapFactory;
                return this;
            }

            public Builder putTagHandler(Tag tag, TagHandler handler) {
                checkState();
                this.tagHandlers.put(tag, handler);
                return this;
            }

            public Config build() {
                checkState();
                used = true;
                return new Config() {
                    public Factory getListFactory() {
                        return listFactory;
                    }

                    public Factory getVectorFactory() {
                        return vectorFactory;
                    }

                    public Factory getSetFactory() {
                        return setFactory;
                    }

                    public Factory getMapFactory() {
                        return mapFactory;
                    }

                    public TagHandler getTagHandler(Tag tag) {
                        return tagHandlers.get(tag);
                    }
                };
            }

            private void checkState() {
                if (used) {
                    throw new IllegalStateException(
                            "Builder is single-use. Not usable after build()");
                }
            }
        };
    }