Set up the keystroke mapper.
Add a map entry
9719
def []=(indexes, value)
      indexes = [indexes] unless indexes.is_a?(Range)

      indexes.each do |index|
        process_non_terminals(index)

        if @map.has_key?(index)
          fail MiniTermKME, "Duplicate entry #{index.inspect}"
        end

        @map[index] = [value, index]
      end
    end
36596
def _enter(self):
        """"""
        command = self.command
        logger.log(5, "Snippet keystroke `Enter`.")
        # NOTE: we need to set back the actions (mode_off) before running
        # the command.
        self.mode_off()
        self.run(command)
238851
public void setupInMapper() {
        inputLabels = context.getConfiguration().getStrings(SimpleJob.FILETER_OUTPUT_LABELS);
        if (inputLabels == null) {
            inputLabels = context.getConfiguration().getStrings(SimpleJob.BEFORE_SUMMARIZER_OUTPUT_LABELS);
        }
        boolean label =
                context.getConfiguration().getStrings(SimpleJob.SUMMARIZER_OUTPUT_LABELS) == null ?
                        true : false;
        writer = new BasicWriter(label);
    }
321531
public void setupKeys()
    {
        KeyAreaInfo keyArea = null;
        keyArea = new KeyAreaInfo(this, Constants.UNIQUE, ID_KEY);
        keyArea.addKeyField(ID, Constants.ASCENDING);
        keyArea = new KeyAreaInfo(this, Constants.NOT_UNIQUE, PARENT_FOLDER_ID_KEY);
        keyArea.addKeyField(PARENT_FOLDER_ID, Constants.ASCENDING);
        keyArea.addKeyField(SEQUENCE, Constants.ASCENDING);
        keyArea.addKeyField(TYPE, Constants.ASCENDING);
        keyArea.addKeyField(NAME, Constants.ASCENDING);
        keyArea = new KeyAreaInfo(this, Constants.SECONDARY_KEY, CODE_KEY);
        keyArea.addKeyField(CODE, Constants.ASCENDING);
        keyArea = new KeyAreaInfo(this, Constants.NOT_UNIQUE, TYPE_KEY);
        keyArea.addKeyField(TYPE, Constants.ASCENDING);
        keyArea.addKeyField(PROGRAM, Constants.ASCENDING);
    }
1151623
def add_keyup(self, actions, **kwargs):
        """"""
        return self.add_handler(pygame.KEYUP, actions, **kwargs)
680493
def _on_enter(self, *args):
        """"""
        self.config(foreground=self._hover_color, cursor=self._cursor)
1008180
public void setupKeys()
    {
        KeyAreaInfo keyArea = null;
        keyArea = new KeyAreaInfo(this, Constants.UNIQUE, ID_KEY);
        keyArea.addKeyField(ID, Constants.ASCENDING);
        keyArea = new KeyAreaInfo(this, Constants.NOT_UNIQUE, PARENT_PROJECT_TASK_ID_KEY);
        keyArea.addKeyField(PARENT_PROJECT_TASK_ID, Constants.ASCENDING);
        keyArea.addKeyField(START_DATE_TIME, Constants.ASCENDING);
        keyArea.addKeyField(SEQUENCE, Constants.ASCENDING);
        keyArea.addKeyField(NAME, Constants.ASCENDING);
    }
647742
def add_entry(self, **kw):
        
        self.data.setdefault('entries', []).append(
            {'{}_entry'.format(self.typeof): kw})
1122239
public void setupKeys()
    {
        KeyAreaInfo keyArea = null;
        keyArea = new KeyAreaInfo(this, Constants.UNIQUE, ID_KEY);
        keyArea.addKeyField(ID, Constants.ASCENDING);
        keyArea = new KeyAreaInfo(this, Constants.SECONDARY_KEY, USER_NAME_KEY);
        keyArea.addKeyField(USER_NAME, Constants.ASCENDING);
    }
55515
public static Map.Entry<String, Map<String, ?>> pressKeyCodeCommand(int key) {
        return new AbstractMap.SimpleEntry<>(
                PRESS_KEY_CODE, prepareArguments("keycode", key));
    }
1247945
def update_entry_line(self, key=None):
        

        if key is None:
            key = self.actions.cursor

        cell_code = self.GetTable().GetValue(*key)

        post_command_event(self, self.EntryLineMsg, text=cell_code)
1293672
public void setupKeys()
    {
        KeyArea keyArea = null;
        for (int iKeyArea = DBConstants.MAIN_KEY_FIELD; iKeyArea < 64; iKeyArea++)
        {
            keyArea = this.setupKey(iKeyArea);      // Allocate this Key (overidden in file class)
            if (keyArea == null)
                break;                              // End of Keys
        }
    }
1019349
def set_key(self, key, modifiers: typing.List[Key]=None):
        """"""
        if modifiers is None:
            modifiers = []  # type: typing.List[Key]
        if key in self.KEY_MAP:
            key = self.KEY_MAP[key]
        self._setKeyLabel(key)
        self.key = key
        self.controlButton.setChecked(Key.CONTROL in modifiers)
        self.altButton.setChecked(Key.ALT in modifiers)
        self.shiftButton.setChecked(Key.SHIFT in modifiers)
        self.superButton.setChecked(Key.SUPER in modifiers)
        self.hyperButton.setChecked(Key.HYPER in modifiers)
        self.metaButton.setChecked(Key.META in modifiers)
        self.recording_finished.emit(True)
159397
def setKey(self, key):
		""""""
		key = self._guardAgainstUnicode(key)
		self.__key = key
1149055
private void addDeviceKeyboard()
    {
        final KeyboardHeadless keyboard = new KeyboardHeadless();
        devices.put(Keyboard.class, keyboard);
        devices.put(InputDeviceDirectional.class, keyboard);
    }
161075
def keypair_add(name, pubfile=None, pubkey=None, profile=None, **kwargs):
    '''
    
    '''
    conn = _auth(profile, **kwargs)
    return conn.keypair_add(
        name,
        pubfile,
        pubkey
    )
711903
def add_entry(e)
      @entries.push(e)
      if @md5_to_entries.has_key?(e.md5)
        @md5_to_entries[e.md5].push(e)
      else
        @md5_to_entries[e.md5] = [e]
      end
    end