Enum StringHelpers
- java.lang.Object
-
- java.lang.Enum<StringHelpers>
-
- org.openapitools.codegen.templating.handlebars.StringHelpers
-
- All Implemented Interfaces:
com.github.jknack.handlebars.Helper<Object>
,Serializable
,Comparable<StringHelpers>
public enum StringHelpers extends Enum<StringHelpers> implements com.github.jknack.handlebars.Helper<Object>
-
-
Enum Constant Summary
Enum Constants Enum Constant Description endsWith
Indicates whether the string ends with the given value.startsWith
Indicates whether the string starts with the given value.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method 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.
-
-
-
Enum Constant Detail
-
startsWith
public static final StringHelpers startsWith
Indicates whether the string starts with the given value. For example:{{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'}}
-
endsWith
public static final StringHelpers endsWith
Indicates whether the string ends with the given value. For example:{{endsWith a b ["insensitive"]}}
{{endsWith a text='b' [insensitive=true]}}
Render 'yes' or 'no':{{#endsWith a b}} yes {{else}} no {{/endsWith}}
Render 'true' or 'false':{{endsWith a b}}
Render 'y' or 'n':{{endsWith a b yes='y' no='n'}}
-
-
Method Detail
-
values
public static StringHelpers[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (StringHelpers c : StringHelpers.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static StringHelpers valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
-