Skip to content

Commit

Permalink
Fill in docs for date
Browse files Browse the repository at this point in the history
  • Loading branch information
Whiteknight committed Jan 14, 2012
1 parent b04f8cf commit 6dd6c24
Showing 1 changed file with 32 additions and 0 deletions.
32 changes: 32 additions & 0 deletions libraries/date.md
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -15,18 +15,50 @@ objects as well.


### Rosella.Date ### Rosella.Date


The `Rosella.Date` namespace contains a number of utility functions for working
with Date objects.

var d = Rosella.Date.now();
var m = Rosella.Date.min();
var m = Rosella.Date.max();
string day = Rosella.Date.get_day_of_week_name(2012, 1, 14);
int y = Rosella.Date.is_leap_year(2012);

## Classes ## Classes


### Rosella.Date ### Rosella.Date


`Rosella.Date` objects are the default class for working with dates and times.

### Rosella.Date.DateFormatter ### Rosella.Date.DateFormatter


`Rosella.Date.DateFormatter` is a StringFormatter type specially designed for
Date objects. It takes a format string with identifiers such as "yyyy" (year),
"MM" (month), "dd" (day), "hh" (hour), "mm" (minute), "ss" (second) and
replaces those values in the string with the corresponding values from the
Date object.

You can use this type directly or you can call the `.format_string()` method
on the Date object.

### Rosella.Date.SpecialDate ### Rosella.Date.SpecialDate


`Rosella.Date.SpecialDate` are special date objects which represent values which
aren't necessarily real dates. This is an abstract parent type and should not
be used directly.

### Rosella.Date.SpecialDate.Minimum ### Rosella.Date.SpecialDate.Minimum


`Rosella.Date.SpecialDate.Minimum` is a special singleton value which represents
a guaranteed minimum date. Minimum dates are always guaranteed to be compared
less than all other dates, and is equal only to itself.

### Rosella.Date.SpecialDate.Maximum ### Rosella.Date.SpecialDate.Maximum


`Rosella.Date.SpecialDate.Maximum` is a special singleton value which represents
a guaranteed maximum date. Maximum dates are always guaranteed to be compared
greater than all other dates, and is equal only to itself.

## Examples ## Examples


### Winxed ### Winxed
Expand Down

0 comments on commit 6dd6c24

Please sign in to comment.