/** * Constructs a tokenizer splitting on the specified delimiter string. * * @param input the string which is to be parsed * @param delim the field delimiter string */ public StrTokenizer(String input, String delim) { this(input); setDelimiterString(delim); }
/** * Constructs a tokenizer splitting on the specified string. * <p> * The input character array is not cloned, and must not be altered after * passing in to this method. * * @param input the string which is to be parsed, not cloned * @param delim the field delimiter string */ public StrTokenizer(char[] input, String delim) { this(input); setDelimiterString(delim); }
/** * Constructs a tokenizer splitting on the specified delimiter string. * * @param input the string which is to be parsed * @param delim the field delimiter string */ public StrTokenizer(String input, String delim) { this(input); setDelimiterString(delim); }
/** * Constructs a tokenizer splitting on the specified string. * <p> * The input character array is not cloned, and must not be altered after * passing in to this method. * * @param input the string which is to be parsed, not cloned * @param delim the field delimiter string */ public StrTokenizer(char[] input, String delim) { this(input); setDelimiterString(delim); }
/** * Constructs a tokenizer splitting on the specified string. * <p> * The input character array is not cloned, and must not be altered after * passing in to this method. * * @param input the string which is to be parsed, not cloned * @param delim the field delimiter string */ public StrTokenizer(char[] input, String delim) { this(input); setDelimiterString(delim); }
/** * Constructs a tokenizer splitting on the specified delimiter string. * * @param input the string which is to be parsed * @param delim the field delimiter string */ public StrTokenizer(String input, String delim) { this(input); setDelimiterString(delim); }
/** * Constructs a tokenizer splitting on the specified string. * <p> * The input character array is not cloned, and must not be altered after * passing in to this method. * * @param input the string which is to be parsed, not cloned * @param delim the field delimiter string */ public StrTokenizer(char[] input, String delim) { this(input); setDelimiterString(delim); }
/** * Constructs a tokenizer splitting on the specified delimiter string. * * @param input the string which is to be parsed * @param delim the field delimiter string */ public StrTokenizer(String input, String delim) { this(input); setDelimiterString(delim); }
/** * Constructs a tokenizer splitting on the specified delimiter string. * * @param input the string which is to be parsed * @param delim the field delimiter string */ public StrTokenizer(String input, String delim) { this(input); setDelimiterString(delim); }
/** * Constructs a tokenizer splitting on the specified delimiter string. * * @param input the string which is to be parsed * @param delim the field delimiter string */ public StrTokenizer(String input, String delim) { this(input); setDelimiterString(delim); }
/** * Constructs a tokenizer splitting on the specified string. * <p> * The input character array is not cloned, and must not be altered after * passing in to this method. * * @param input the string which is to be parsed, not cloned * @param delim the field delimiter string */ public StrTokenizer(char[] input, String delim) { this(input); setDelimiterString(delim); }
/** * Constructs a tokenizer splitting on the specified string. * <p> * The input character array is not cloned, and must not be altered after * passing in to this method. * * @param input the string which is to be parsed, not cloned * @param delim the field delimiter string */ public StrTokenizer(char[] input, String delim) { this(input); setDelimiterString(delim); }
/** Creates a new StrTokenizer based on the configuration. */ private StrTokenizer createTokenizer() { final StrTokenizer tokenizer; if (csvHelper.getSeparator().equals(",")) { tokenizer = StrTokenizer.getCSVInstance(); } else if (csvHelper.getSeparator().equals("\\t")) { tokenizer = StrTokenizer.getTSVInstance(); } else { tokenizer = new StrTokenizer(); tokenizer.setDelimiterString(csvHelper.getSeparator()); } tokenizer.setIgnoreEmptyTokens(false); tokenizer.setEmptyTokenAsNull(true); return tokenizer; }