public Index addCommand(String command) {
        allCommands.add(command);

        if (command.startsWith("type tensor(") || command.startsWith("type tensor<")) { // TODO: Type info can replace numerical, predicate, multivalue
            setTensor(true);
        } else if (command.equals("integer")) {
            setInteger(true);
        } else if ("fullurl".equals(command)) {
            setUriIndex(true);
        } else if ("urlhost".equals(command)) {
            setHostIndex(true);
        } else if (command.startsWith("stem ")) {
            setStemMode(command.substring(5));
        } else if (command.startsWith("stem:")) {
            setStemMode(command.substring(5));
        } else if ("stem".equals(command)) {
            setStemMode(StemMode.SHORTEST);
        } else if ("word".equals(command)) {
            setExact(true, null);
        } else if ("exact".equals(command)) {
            setExact(true, " ");
        } else if ("dynteaser".equals(command)) {
            setDynamicSummary(true);
        } else if ("highlight".equals(command)) {
            setHighlightSummary(true);
        } else if ("lowercase".equals(command)) {
            setLowercase(true);
        } else if (command.startsWith("exact ")) {
            setExact(true, command.substring(6));
        } else if (command.startsWith("ngram ")) {
            setNGram(true, Integer.parseInt(command.substring(6)));
        } else if (command.equals("attribute")) {
            setAttribute(true);
        } else if (command.equals("index")) {
            setIndex(true);
        } else if (command.equals("default-position")) {
            setDefaultPosition(true);
        } else if (command.equals("plain-tokens")) {
            setPlainTokens(true);
        } else if (command.equals("multivalue")) {
            setMultivalue(true);
        } else if (command.equals("fast-search")) {
            setFastSearch(true);
        } else if (command.equals("normalize")) {
            setNormalize(true);
        } else if (command.equals("literal-boost")) {
            setLiteralBoost(true);
        } else if (command.equals("numerical")) {
            setNumerical(true);
        } else if (command.equals("predicate")) {
            setPredicate(true);
        } else if (command.startsWith("predicate-bounds ")) {
            setPredicateBounds(command.substring(17));
        } else if (command.equals("phrase-segmenting")) {
            setPhraseSegmenting(true);
        } else if (command.startsWith("phrase-segmenting ")) {
            setPhraseSegmenting(Boolean.parseBoolean(command.substring("phrase-segmenting ".length())));
        } else if (command.equals(CMD_STRING)) {
            setString(true);
        } else {
            commands.add(command);
        }
        return this;
    }
Adds a type or untyped command string to this
container-search/src/main/java/com/yahoo/prelude/Index.java