Package org.jruby.util
Class RubyTimeOutputFormatter
java.lang.Object
org.jruby.util.RubyDateFormatter.Token
org.jruby.util.RubyTimeOutputFormatter
Support for GNU-C output formatters, see: http://www.gnu.org/software/libc/manual/html_node/Formatting-Calendar-Time.html
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final RubyTimeOutputFormatter(package private) final ByteListprivate static final intprivate static final int(package private) final intFields inherited from class org.jruby.util.RubyDateFormatter.Token
data -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidformat(ByteList out, long value, RubyDateFormatter.FieldType type) voidformat(ByteList out, CharSequence sequence) (package private) static voidformatNumber(ByteList out, long value, int width, char padder) (package private) static voidformatSignedNumber(ByteList out, long value, long second, int width, char padder) chargetPadder(char defaultPadder) intgetWidth(int defaultWidth) (package private) static intlongSize(long number) (package private) static intlongSizeInner(long number) (package private) static voidoutputLong(ByteList out, int length, long value) private static voidtoString()Methods inherited from class org.jruby.util.RubyDateFormatter.Token
format, formatter, getData, getFormat, special, str, zoneOffsetColons
-
Field Details
-
flags
-
width
final int width -
DEFAULT_FORMATTER
-
MAX_DIGITS
private static final int MAX_DIGITS- See Also:
-
SMALLBUF
private static final int SMALLBUF- See Also:
-
-
Constructor Details
-
RubyTimeOutputFormatter
-
-
Method Details
-
getWidth
public int getWidth(int defaultWidth) -
getPadder
public char getPadder(char defaultPadder) -
format
-
format
-
outputLong
-
longSize
static int longSize(long number) -
longSizeInner
static int longSizeInner(long number) -
formatNumber
-
formatSignedNumber
-
padding
-
toString
- Overrides:
toStringin classRubyDateFormatter.Token
-