public class RubyDateFormatter
extends java.lang.Object
| Modifier and Type | Class and Description |
|---|---|
static class |
RubyDateFormatter.Format |
static class |
RubyDateFormatter.Token |
| Modifier and Type | Field and Description |
|---|---|
static RubyDateFormatter.Token |
COLON_TOKEN |
static RubyDateFormatter.Token |
DASH_TOKEN |
static RubyDateFormatter.Token |
DOT_TOKEN |
static RubyDateFormatter.Token |
SLASH_TOKEN |
| Constructor and Description |
|---|
RubyDateFormatter(ThreadContext context)
Constructor for RubyDateFormatter.
|
| Modifier and Type | Method and Description |
|---|---|
RubyString |
compileAndFormat(RubyString pattern,
boolean dateLibrary,
org.joda.time.DateTime dt,
long nsec,
RubyNumeric sub_millis)
Convenience method when using no pattern caching
|
void |
compilePattern(ByteList pattern,
boolean dateLibrary) |
void |
compilePattern(RubyString format,
boolean dateLibrary) |
RubyString |
format(RubyDateFormatter.Token[] compiledPattern,
org.joda.time.DateTime dt,
long nsec,
RubyNumeric sub_millis) |
java.util.Date |
parse(java.lang.String source,
java.text.ParsePosition pos) |
public static RubyDateFormatter.Token COLON_TOKEN
public static RubyDateFormatter.Token DASH_TOKEN
public static RubyDateFormatter.Token DOT_TOKEN
public static RubyDateFormatter.Token SLASH_TOKEN
public RubyDateFormatter(ThreadContext context)
public void compilePattern(RubyString format, boolean dateLibrary)
public void compilePattern(ByteList pattern, boolean dateLibrary)
public RubyString compileAndFormat(RubyString pattern, boolean dateLibrary, org.joda.time.DateTime dt, long nsec, RubyNumeric sub_millis)
public RubyString format(RubyDateFormatter.Token[] compiledPattern, org.joda.time.DateTime dt, long nsec, RubyNumeric sub_millis)
public java.util.Date parse(java.lang.String source,
java.text.ParsePosition pos)
DateFormat.parse(String, ParsePosition)Copyright © 2001-2022 JRuby. All Rights Reserved.