Adds a new state
495789
def add_state(self):
        """"""
        sid = len(self.states)
        self.states.append(DFAState(sid))
        return sid
765883
def transition_to_add(self):
        """"""
        assert self.state in [AQStateMachineStates.init, AQStateMachineStates.add]
        self.state = AQStateMachineStates.add
472968
def PushState(self, **_):
    """"""
    if self.verbose:
      logging.debug("Storing state %r", self.state)
    self.state_stack.append(self.state)
1023030
public boolean addToSet(State<S, EP> state) {
        boolean first = list.isEmpty();
        if (first || !setContents.get(state.getId())) {
            list.add(state);
            setContents.set(state.getId());
        }
        return first;
    }
964542
public void addConstructState(Constructs construct, ConstructState constructState) {
    addConstructState(construct, constructState, Optional.<String>absent());
  }
296499
public int add(Object label) {
        ensureCapacity(used);
        states[used] = new State(label);
        return used++;
    }
1012810
def add_object(self, obj):
        ''''''
        state = self.state
        if not obj.layer in state.layers:
            # its a new layer
            state.layers[obj.layer] = {}
        state.layers[obj.layer][obj.key] = obj
        state.need_redraw = True
10227
public void appendBranchState(int start, int end, BranchCoverageState state) {
		this.passed.put(new Range(start, end), state);
	}
698494
private void pushState(int indentation) {
        states.push(state);
        state = new StreamStatus();
        state.setIndentationLevel(indentation);
    }
682851
function createTodo(state: State, text: ?string): State {
  if (!text) {
    return state;
  }
  var newTodo = new Todo(text);
  return state.set(newTodo.id, newTodo);
}
1285910
function add (state, prefix, properties) {
  return Array.isArray(properties)
    ? addMany(state, properties, prefix)
    : addOne(state, properties, prefix)
}
437207
private void setState(State newState) {
        m_logger.debug("Entering state: {}", newState.toString());
        synchronized (m_stateChangeLock) {
            m_state = newState;
            m_stateChangeLock.notifyAll();
        }
    }
1096113
def push_state(self):
        

        new = dict(self.states[-1])
        self.states.append(new)
        return self.state
1243852
private void pushState(boolean isStatic) {
        stateStack.add(new StateStackElement());
        currentScope = new VariableScope(currentScope);
        currentScope.setInStaticContext(isStatic);
    }
403298
def set_state(self, new_state):
        
        # Make sure it's a valid state
        if new_state not in self.STATES:
            raise ValueError('Invalid state value: %r' % new_state)

        # Set the state
        LOGGER.debug('State changing from %s to %s', self.STATES[self.state],
                     self.STATES[new_state])
        self.state = new_state
        self.state_start = time.time()
290738
def _push_new_state(self):
        
        try:
            base = self._states[-1]
        except IndexError:
            graph = DirectedGraph()
            graph.add(None)     # Sentinel as root dependencies' parent.
            state = State(mapping={}, graph=graph)
        else:
            state = State(
                mapping=base.mapping.copy(),
                graph=base.graph.copy(),
            )
        self._states.append(state)
846035
def state(self, new_state: bool):
    
    self._lutron.send(Lutron.OP_EXECUTE, Keypad._CMD_TYPE, self._keypad.id,
                      self.component_number, Led._ACTION_LED_STATE,
                      int(new_state))
    self._state = new_state