Enum Class JodaHelper
- All Implemented Interfaces:
com.github.jknack.handlebars.Helper<org.joda.time.ReadableInstant>,Serializable,Comparable<JodaHelper>,Constable
public enum JodaHelper
extends Enum<JodaHelper>
implements com.github.jknack.handlebars.Helper<org.joda.time.ReadableInstant>
Handlebars Helper for JodaTime ReadableInstance objects.
- Author:
- mrhanlon
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionA Helper for ISO-formattedReadableInstant.A Helper for pattern-formattedReadableInstance.A Helper for style-formattedReadableInstant. -
Method Summary
Modifier and TypeMethodDescriptionapply(org.joda.time.ReadableInstant time, com.github.jknack.handlebars.Options options) static JodaHelperReturns the enum constant of this class with the specified name.static JodaHelper[]values()Returns an array containing the constants of this enum class, in the order they are declared.Methods inherited from class java.lang.Enum
compareTo, describeConstable, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
-
Enum Constant Details
-
jodaPattern
A Helper for pattern-formattedReadableInstance. Pattern usage is as specified inDateTimeFormat. Defaults toM d y, H:m:s z, for example11 15 1995, 14:32:10 CST. -
jodaStyle
A Helper for style-formattedReadableInstant. Style usage is as specified inDateTimeFormat. Defaults toMM, for example -
jodaISO
A Helper for ISO-formattedReadableInstant. Usages is detailed inISODateTimeFormat.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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 class has no constant with the specified nameNullPointerException- if the argument is null
-
apply
public Object apply(org.joda.time.ReadableInstant time, com.github.jknack.handlebars.Options options) throws IOException - Specified by:
applyin interfacecom.github.jknack.handlebars.Helper<org.joda.time.ReadableInstant>- Throws:
IOException
-