tamaya-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From anat...@apache.org
Subject incubator-tamaya-site git commit: Improved docs.
Date Sat, 11 Feb 2017 22:43:36 GMT
Repository: incubator-tamaya-site
Updated Branches:
  refs/heads/master 7708b830f -> 76ae9629c


Improved docs.


Project: http://git-wip-us.apache.org/repos/asf/incubator-tamaya-site/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-tamaya-site/commit/76ae9629
Tree: http://git-wip-us.apache.org/repos/asf/incubator-tamaya-site/tree/76ae9629
Diff: http://git-wip-us.apache.org/repos/asf/incubator-tamaya-site/diff/76ae9629

Branch: refs/heads/master
Commit: 76ae9629c92df179f0879658456ab2783f73b52e
Parents: 7708b83
Author: anatole <anatole@apache.org>
Authored: Sat Feb 11 23:43:28 2017 +0100
Committer: anatole <anatole@apache.org>
Committed: Sat Feb 11 23:43:28 2017 +0100

----------------------------------------------------------------------
 .../documentation/extensions/mod_jodatime.adoc  | 52 +++++++++++++++++---
 1 file changed, 44 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-tamaya-site/blob/76ae9629/content/documentation/extensions/mod_jodatime.adoc
----------------------------------------------------------------------
diff --git a/content/documentation/extensions/mod_jodatime.adoc b/content/documentation/extensions/mod_jodatime.adoc
index f384157..0445c27 100644
--- a/content/documentation/extensions/mod_jodatime.adoc
+++ b/content/documentation/extensions/mod_jodatime.adoc
@@ -13,10 +13,13 @@ Tamaya _JodaTime_ is an extension module. Refer to the link:../extensions.html[e
 
 Tamaya _JodaTime_ is an extension module to support the usage of http://www.joda.org/joda-time/[Joda-Time]
 in conjunction with Tamaya. Tamaya JodaTime defines some additional property
-converters to retrieve Joda-Time types from a given configuration.
+converters to use Joda-Time types when accessing configuration.
 
-tools to locate resources in your classpath or file system based on descriptive
-ant-styled resource patterns. To use this module add the following dependency:
+
+=== Installation
+
+To support Joda-Time types as configuration values, you only have to add the following
+maven dependency to your project:
 
 [source, listing]
 -----------------------------------------------
@@ -27,7 +30,10 @@ ant-styled resource patterns. To use this module add the following dependency:
 </dependency>
 -----------------------------------------------
 
-After adding this dependency to your project you can retrieve
+
+=== Usage
+
+After adding this module to your project you can retrieve
 Joda-Time based values directly from a given configuration.
 
 [source,java]
@@ -37,10 +43,40 @@ Configuration configuration = ConfigurationProvider.getConfiguration();
 DateTime pit = configuration.get("pointInTime", DateTime.class)
 -----------------------------------------------
 
-=== Specifying date and time values
+Currently the following types are supported:
+
 
-To be written.
+[width="80%",options=header]
+|================================================================
+| Joda-Time target type              | Supported Input Formats
+.12+^.<| +org.joda.time.DateTime+ +org.joda.time.Instant+  | `yyyy-MM-dd'T'HH:mm:ss.SSSZ`
+           | `yyyy-MM-dd'T'HH:mm:ss.SSSz`
+                                     | `yyyy-MM-dd'T'HH:mm:ss.SSS z`
+                                     | `yyyy-MM-dd'T'HH:mm:ssZ`
+                                     | `yyyy-MM-dd'T'HH:mm:ssz`
+                                     | `yyyy-MM-dd'T'HH:mm:ss z`
+                                     | `yyyy-MM-dd'T'HH:mmZ`
+                                     | `yyyy-MM-dd'T'HH:mmz`
+                                     | `yyyy-MM-dd'T'HH:mm z`
+                                     | `yyyy-MM-dd'T'HHZ`
+                                     | `yyyy-MM-dd'T'HHz`
+                                     | `yyyy-MM-dd'T'HH z`
+.2+^.<| +org.joda.time.DateTimeZone+ | `[+-]hh:mm` (reg.ex.)
+                                     | all _timezone ids_ known by Joda-Time.
+.3+^.<| +org.joda.time.Duration+     | `PTa.bS`
+                                     | `PdDThHmMsS`
+                                     | `ddThh:mm:ss`
+.2+^.<| +org.joda.time.Period+       | `PyYmMwWdDThHmMsS`
+                                     | `Pyyyy-mm-ddThh:mm:ss`
+.4+^.<| +org.joda.time.LocalDate+    | `yyyy ['-' MM ['-' dd]]`
+                                     | `yyyy ['-' DDD]`
+                                     | `LocalDateConverter`
+                                     | `yyyy ['-' dd ['-' MM]]`
+.4+^.<| +org.joda.time.LocalTime+    | `['T']` _time-element_
+                                     |  _time-element_ = HH [_minute-element_] _or_ [_fraction_]
+                                     |  _minute-element_ = ':' mm [_second-element_] _or_
[_fraction_]
+                                     |  _second-element_ = ':' ss [_fraction_]
+                                     |  _fraction_       = ('.' _or_ ',') digit+`
+|================================================================
 
-=== Specifing periods and durations
 
-To be written.


Mime
View raw message