Returns the key columns for the specific input, if all keys are preserved
by this node. Null, otherwise.

@param input
@return
501601
protected int[] getConstantKeySet(int input) {
		Operator<?> contract = getPactContract();
		if (contract instanceof AbstractUdfOperator<?, ?>) {
			AbstractUdfOperator<?, ?> abstractPact = (AbstractUdfOperator<?, ?>) contract;
			int[] keyColumns = abstractPact.getKeyColumns(input);
			if (keyColumns != null) {
				if (keyColumns.length == 0) {
					return null;
				}
				for (int keyColumn : keyColumns) {
					if (!isFieldConstant(input, keyColumn)) {
						return null;	
					}
				}
				return keyColumns;
			}
		}
		return null;
	}
213764
public static String encrypt(String input) {
        try {
            return encrypt(input, null);
        } catch (GeneralSecurityException e) {
            e.printStackTrace();
            return null;
        }
    }
992970
public Registration readClass (Input input) {
		if (input == null) throw new IllegalArgumentException("input cannot be null.");
		try {
			return classResolver.readClass(input);
		} finally {
			if (depth == 0 && autoReset) reset();
		}
	}
1183888
@Override
    public Object map(Object input) {
        Number n = (Number) input;
        return doOp(n.longValue());
    }
123520
public CacheKeyBuilder appendStringsIgnoringOrder(Collection<String> input)
  {
    appendItem(STRING_LIST_KEY, stringCollectionToByteArray(input, false));
    return this;
  }
198153
public static String[] nullifyBadInput(String[] input)
    {
        if (input != null)
        {
            if (input.length > 0)
            {
                return input;
            }
        }
        return null;
    }
277271
public static DTree getDTreeFromCoNLLXString(final String input) {
        if (input == null || input.trim().isEmpty()) {
            return null;
        }

        Map<Integer, Map<Integer, String>> semanticHeadsMap = new HashMap<>();
        String[] dNodesString = input.split(System.lineSeparator());
        DTree tree = new DTree();

        Arrays.stream(dNodesString)
                .map(s -> s.split("\t"))
                .forEachOrdered(fields -> {
                    int currentIndex = 0;
                    int id = Integer.parseInt(fields[currentIndex++]);
                    String form = fields[currentIndex++];
                    String lemma = fields[currentIndex++];
                    String cPOSTag = fields[currentIndex++];
                    String pos = fields[currentIndex++];
                    String feats = fields[currentIndex++];
                    Map<String, String> featsMap = null;
                    if (!feats.equals("_")) {
                        featsMap = Arrays.stream(feats.split("\\|"))
                                .map(entry -> entry.split("="))
                                .collect(Collectors.toMap(e -> e[0], e -> e.length > 1 ? e[1] : StringUtils.EMPTY));
                    } else {
                        featsMap = new HashMap<>();
                    }

                    String headIndex = fields[currentIndex++];
                    String depLabel = fields[currentIndex++];

                    String dump1 = fields[currentIndex++];
                    String dump2 = fields[currentIndex++];

                    String semanticHeadsString = currentIndex >= fields.length ? "_" : fields[currentIndex];

                    if (!semanticHeadsString.equals("_")) {
                        Map<Integer, String> semanticHeads = Arrays.stream(semanticHeadsString.split("\\|"))
                                .map(entry -> entry.split(":"))
                                .collect(Collectors.toMap(e -> Integer.parseInt(e[0]), e -> (e.length > 1) ? e[1] : StringUtils.EMPTY));
                        semanticHeadsMap.put(id, semanticHeads);
                    }

                    DNode node = id == 0 ? tree.getPaddingNode() : new DNode(id, form, lemma, cPOSTag, pos, depLabel);
                    if (id == 0 && !featsMap.containsKey("uuid")) {
                        featsMap.put("uuid", tree.getUUID().toString());
                    }
                    node.setFeats(featsMap);
                    node.addFeature("head", headIndex); // by the time head might not be generated!
                    if (node.getId() == 0) {
                        tree.getPaddingNode().setFeats(node.getFeats());// Substitute padding with actual 0 node from CoNLLX
                    } else {
                        tree.add(node);
                    }
                });

        tree.getPaddingNode().getFeats().remove("head");
        for (int i = 1; i < tree.size(); i++) {
            DNode node = tree.get(i);
            int headIndex = Integer.parseInt(node.getFeature("head"));
            DNode head = tree.get(headIndex);
            head.addChild(node);
            node.getFeats().remove("head");
            node.setHead(head);
        }


        // Recover semantic heads.
        semanticHeadsMap.entrySet().parallelStream().map(e -> {
            DNode node = tree.get(e.getKey());
            Map<Integer, String> nodeSemanticInfo = e.getValue();
            for (Integer id : nodeSemanticInfo.keySet()) {
                node.addSemanticHead(tree.get(id), nodeSemanticInfo.get(id));
                tree.get(id).getSemanticChildren().add(node);
            }
            return null;
        }).collect(Collectors.toList());
        return tree;
    }
1096058
private int keyColumnEnd()
  {
    int offset = 0;
    
    for (int i = 0; i < _columns.length; i++) {
      if (offset == _keyStart + _keyLength) {
        return i;
      }
      
      offset += _columns[i].length();
    }
    
    if (offset == _keyStart + _keyLength) {
      return _columns.length;
    }
    
    throw new IllegalStateException();
  }
17470
public Token[] tokenize(String input) 
    {
        List tokens = new ArrayList();
        int cursor = 0;
        while (cursor<input.length()) {
	    char ch = input.charAt(cursor);
	    if (Character.isWhitespace(ch)) {
                cursor++;
	    } else if (Character.isLetter(ch)) {
                StringBuffer buf = new StringBuffer("");
                while (cursor<input.length() && Character.isLetter(input.charAt(cursor))) {
                    buf.append(input.charAt(cursor));
                    cursor++;
                }
                tokens.add(internSomething(buf.toString()));
	    } else if (Character.isDigit(ch)) {
                StringBuffer buf = new StringBuffer("");
                while (cursor<input.length() && Character.isDigit(input.charAt(cursor))) {
                    buf.append(input.charAt(cursor));
                    cursor++;
                }
                tokens.add(internSomething(buf.toString()));
	    } else {
                if (!ignorePunctuation) {
                    StringBuffer buf = new StringBuffer("");
                    buf.append(ch);
                    String str = buf.toString();
                    tokens.add(internSomething(str));
                }
                cursor++;
	    }
        }
        return (Token[]) tokens.toArray(new BasicToken[tokens.size()]);
    }
194779
public static List<String> toList(String[] input) {
        List<String> ret = new ArrayList<>();
        for (int i = 0; i < input.length; i++)
            ret.add(input[i]);
        return ret;
    }
364447
@Override
    public Object map(Object input) {
        Number n = (Number) input;
        if (inputSchema.getMetaData(columnNumber).isValid(new IntWritable(n.intValue()))) {
            return input;
        } else {
            return value;
        }
    }
1312128
public static String decodeParameter(String input) {

        String result = CmsStringUtil.substitute(input, ENTITY_REPLACEMENT, ENTITY_PREFIX);
        return CmsEncoder.decodeHtmlEntities(result, OpenCms.getSystemInfo().getDefaultEncoding());
    }
721622
private int keyColumnStart()
  {
    int offset = 0;
    
    for (int i = 0; i < _columns.length; i++) {
      if (offset == _keyStart) {
        return i;
      }
      
      offset += _columns[i].length();
    }
    
    throw new IllegalStateException();
  }
615899
public <K, V> Map<K, V> unmodifiable(Map<K, V> input)
    {
        if (input == null) {
            return null;
        }
        return Collections.unmodifiableMap(input);
    }
1361046
@Override
    public Map<String, String> mapToColumns(Tuple tuple) {
        Fields fields = tuple.getFields();
        Map<String, String> columns = new HashMap<String, String>();
        for (int i = 0; i < fields.size(); i++) {
            String name = fields.get(i);
            Boolean isRowField = Arrays.asList(this.rowKeyFields).contains(name);
            if (!isRowField) {
                Object value = tuple.getValueByField(name);
                columns.put(name, (value != null ? value.toString() : ""));
            }
        }
        return columns;
    }
1336295
@Override
    public Object map(Object input) {
        String value = input.toString();
        //Do conversion
        Integer classIdx = statesMap.get(value);
        if (classIdx == null) {
            throw new IllegalStateException("Cannot convert categorical value to integer value: input value (\"" + value
                    + "\") is not in the list of known categories (state names/categories: " + stateNames + ")");
        }
        return classIdx;
    }
1134616
protected List<String> getNonPrimaryKeyColumns(String tableName) {
        List<String> columns = getAllColumns(tableName);
        columns.removeAll(getPrimaryKeys(tableName));
        return columns;
    }