public enum StringHelpers extends Enum<StringHelpers> implements com.github.jknack.handlebars.Helper<Object>
| Enum Constant and Description |
|---|
startsWith
Indicates the string starts with the defined value.
|
| Modifier and Type | Method and Description |
|---|---|
static StringHelpers |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static StringHelpers[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final StringHelpers startsWith
{{startsWith a b ["insensitive"]}}
{{startsWith a text='b' [insensitive=true]}}
Render 'yes' or 'no':
{{#startsWith a b}}
yes
{{else}}
no
{{/startsWith}}
Render 'true' or 'false':
{{startsWith a b}}
Render 'y' or 'n':
{{startsWith a b yes='y' no='n'}}
If value is "handlebars.java", the output will be "Handlebars.java".public static StringHelpers[] values()
for (StringHelpers c : StringHelpers.values()) System.out.println(c);
public static StringHelpers valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant with the specified nameNullPointerException - if the argument is nullCopyright © 2020. All rights reserved.