Creates a new instance of the [[StateMachineInstance]] class.
@param name The optional name of the [[StateMachineInstance]].
542176
function StateMachineInstance(name) {
        if (name === void 0) { name = "unnamed"; }
        this.name = name;
        /** The last known [[Vertex]] of any [[Region]] within the state machine instance. */
        /** @internal */ this.current = {};
        /** The last known [[State]] of any [[Region]] within the state machine instance. */
        /** @internal */ this.last = {};
        /** Indicates that the [[StateMachine]] instance reached was terminated by reaching a [[Terminate]] [[PseudoState]]. */
        this.isTerminated = false;
        this.name = name;
    }
394215
private T createOrThrow(String name) {
        T constant = constants.get(name);
        if (constant == null) {
            final T tempConstant = newConstant(nextId(), name);
            constant = constants.putIfAbsent(name, tempConstant);
            if (constant == null) {
                return tempConstant;
            }
        }

        throw new IllegalArgumentException(String.format("'%s' is already in use", name));
    }
1130089
public function addStateMachineName(string $state_machine_name): self
    {
        $builder = clone $this;
        $builder->state_machine_name = $state_machine_name;
        return $builder;
    }
480002
public static EnvironmentType newInstance(String name)
    {
    	EnvironmentType env = new EnvironmentType();
    	env.setName(name);
        return env;
    }
328393
public static synchronized RenderEngine getInstance(String name) {
    if (null == availableEngines) {
      availableEngines = new HashMap();
    }

    //Logger.debug("Engines: " + availableEngines);
    return (RenderEngine) availableEngines.get(name);
  }
1261352
public void addState(String name, S state)
    {
        AbstractState old = states.put(name, new StateWrapper(name, state));
        if (old != null)
        {
            throw new IllegalArgumentException("state "+name+" exists already");
        }
    }
725100
public void start(String name) {
        stopLastTimeInstrument();
        StopWatch childSW = new StopWatch(name);
        childTimeInstrumentList.add(childSW);
    }
901981
public static <T> T newInstance(String className, Object... initargs) 
	throws SetupException
	{
		return newInstance(toClass(className),initargs);		
	}
77796
public void createStateModelBinding(final TransitionableState state, final String modelName, final Class modelType) {
        state.getAttributes().put("model", createExpression(modelName, modelType));
    }
1007395
public synchronized void add(String name, Class<?> cls) {

		if (locked) {
			throw new IllegalStateException(
					"Component factory is locked. Components cannot be added");
		}
		supported.put(name, cls);
		// add name to end of order vector
		if (!order.contains(name))
			order.addElement(name);
	}
852287
function StateMachine(name) {
        var _this = _super.call(this, name, undefined) || this;
        /** Internal flag: false if the state machine model requires recompilation. */
        /** @internal */ _this.clean = false;
        return _this;
    }
531958
public KieSessionModel newKieSessionModel(String name) {
        KieSessionModel kieSessionModel = new KieSessionModelImpl( this, name );
        Map<String, KieSessionModel> newMap = new HashMap<String, KieSessionModel>();
        newMap.putAll( this.kSessions );
        newMap.put( kieSessionModel.getName(), kieSessionModel );
        setKSessions( newMap );

        return kieSessionModel;
    }
337036
SimonConfiguration getConfig(String name) {
		SimonState state = null;

		for (SimonPattern pattern : configs.keySet()) {
			if (pattern.matches(name)) {
				SimonConfiguration config = configs.get(pattern);
				if (config.getState() != null) {
					state = config.getState();
				}
			}
		}
		return new SimonConfiguration(state);
	}
1136119
public KieBaseModel newKieBaseModel(String name) {
        KieBaseModel kbase = new KieBaseModelImpl(this, name);
        Map<String, KieBaseModel> newMap = new HashMap<String, KieBaseModel>();
        newMap.putAll( this.kBases );        
        newMap.put( kbase.getName(), kbase );
        setKBases( newMap );   
        
        return kbase;
    }
284391
public static <T> T newInstance(String name) {
        try {
            return (T) getClass(name).newInstance();
        } catch (InstantiationException | ClassNotFoundException | IllegalAccessException e) {
            throw new IllegalStateException(e.getMessage(), e);
        }
    }
286810
public Object newInstance( String name, Object... params ) throws ClassLoaderException {
        return newInstance( name, params, null );
    }
670384
public void setName(String name)
    {
        super.setName(name);
        m_tf.setName(name);
        if (m_button != null)
            m_button.setName(name);
        if (m_buttonTime != null)
            m_buttonTime.setName(name);
    }