## org.das2.datum.format.FormatStringFormatter

This is based on the C-style format strings introduced in Java 5 that we can now use. When used with times, the format should be specified using URI_Templates like $Y$m$dT$H:$M:$S. TODO: See Autoplot's DataSetUtil.toString, which shows use with Calendar objects. Here is a table showing some examples:

%9.2f | decimal with two fractional places
%9.2e | decimal in scientific notation
%.2f | decimal with two fractional places, and some number of total spaces
%5d | integer in five spaces.
$Y$m$dZ | time specification.

## FormatStringFormatter( String formatStr, boolean units )

create a new instance based on the Java format string.

## format

format( Datum datum ) → String

### Parameters

datum - a Datum

### Returns:

java.lang.String
[search for examples] [view on GitHub] [view on old javadoc] [view source]
format( Datum datum, Units units ) → String [view source]

## toString

toString( ) → String

### Returns:

java.lang.String
[search for examples] [view on GitHub] [view on old javadoc] [view source]