public final class StringUtils extends Object
Modifier and Type | Field and Description |
---|---|
static String |
BLANK_LINE |
static char |
ESCAPE_CHAR |
static Pattern |
INDENTATION |
static Pattern |
LIST_INDEX |
static Pattern |
NEW_LINE |
Constructor and Description |
---|
StringUtils() |
Modifier and Type | Method and Description |
---|---|
static String |
afterNewLine(String s) |
static boolean |
allLinesArePrefixed(String comment,
String prefix) |
static boolean |
allLinesArePrefixedOrBlank(String comment,
String prefix) |
static String |
escape(String s) |
static int |
firstSeparatorIndex(String path,
char sep) |
static int |
firstSeparatorIndex(String path,
char sep,
int fromIndex) |
static String |
indentation(int n) |
static int |
lastSeparatorIndex(String path,
char sep) |
static int |
lastSeparatorIndex(String path,
char sep,
int fromIndex) |
static String[] |
lines(String content) |
static String[] |
lines(String content,
boolean stripTrailingNewLines) |
static String |
padding(int n,
char pad) |
static String |
quoteNewLines(String s) |
static void |
setSeparator(char separator) |
static String[] |
splitNewLines(String s,
int limit) |
static String[] |
splitTrailingNewLines(String s) |
static String |
stripCarriage(String s) |
static String |
stripIndentation(String s) |
static String |
stripPrefix(String s,
String prefix) |
static String |
stripPrefix(String s,
String prefix,
String defaultPrefix) |
static String |
wrap(String value) |
public static final String BLANK_LINE
public static final Pattern NEW_LINE
public static final Pattern INDENTATION
public static final Pattern LIST_INDEX
public static final char ESCAPE_CHAR
public static String indentation(int n)
public static String padding(int n, char pad)
public static int lastSeparatorIndex(String path, char sep, int fromIndex)
public static int lastSeparatorIndex(String path, char sep)
public static int firstSeparatorIndex(String path, char sep, int fromIndex)
public static int firstSeparatorIndex(String path, char sep)
public static boolean allLinesArePrefixedOrBlank(String comment, String prefix)
public static void setSeparator(char separator)
Copyright © 2023. All rights reserved.