[DOC] Move Time#xmlschema docs to the core (#12403)
This commit is contained in:
parent
efe671f9d3
commit
78f55ccd9b
Notes:
git
2024-12-21 18:07:07 +00:00
Merged-By: zverok <zverok.offline@gmail.com>
21
time.c
21
time.c
@ -5242,6 +5242,27 @@ time_strftime(VALUE time, VALUE format)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* call-seq:
|
||||||
|
* xmlschema(fraction_digits=0) -> string
|
||||||
|
*
|
||||||
|
* Returns a string which represents the time as a dateTime defined by XML
|
||||||
|
* Schema:
|
||||||
|
*
|
||||||
|
* CCYY-MM-DDThh:mm:ssTZD
|
||||||
|
* CCYY-MM-DDThh:mm:ss.sssTZD
|
||||||
|
*
|
||||||
|
* where TZD is Z or [+-]hh:mm.
|
||||||
|
*
|
||||||
|
* If self is a UTC time, Z is used as TZD. [+-]hh:mm is used otherwise.
|
||||||
|
*
|
||||||
|
* +fraction_digits+ specifies a number of digits to use for fractional
|
||||||
|
* seconds. Its default value is 0.
|
||||||
|
*
|
||||||
|
* t = Time.now
|
||||||
|
* t.xmlschema # => "2011-10-05T22:26:12-04:00"
|
||||||
|
*/
|
||||||
|
|
||||||
static VALUE
|
static VALUE
|
||||||
time_xmlschema(int argc, VALUE *argv, VALUE time)
|
time_xmlschema(int argc, VALUE *argv, VALUE time)
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user