dépôts
/
lhc
/
web
/
wiklou.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge "API: Add ApiResult::META_KVP_MERGE"
[lhc/web/wiklou.git]
/
includes
/
parser
/
DateFormatter.php
diff --git
a/includes/parser/DateFormatter.php
b/includes/parser/DateFormatter.php
index
82f0e9d
..
ef295ab
100644
(file)
--- a/
includes/parser/DateFormatter.php
+++ b/
includes/parser/DateFormatter.php
@@
-33,7
+33,7
@@
class DateFormatter {
public $regexes, $pDays, $pMonths, $pYears;
public $rules, $xMonths, $preferences;
public $regexes, $pDays, $pMonths, $pYears;
public $rules, $xMonths, $preferences;
- protected $lang;
+ protected $lang
, $mLinked
;
const ALL = -1;
const NONE = 0;
const ALL = -1;
const NONE = 0;
@@
-315,8
+315,8
@@
class DateFormatter {
}
/**
}
/**
- *
@todo document
- * @return string
+ *
Return a regex that can be used to find month names in string
+ * @return string
regex to find the months with
*/
public function getMonthRegex() {
$names = array();
*/
public function getMonthRegex() {
$names = array();
@@
-338,7
+338,7
@@
class DateFormatter {
}
/**
}
/**
- *
@todo document
+ *
Make an ISO year from a year name, for instance: '-1199' from '1200 BC'
* @param string $year Year name
* @return string ISO year name
*/
* @param string $year Year name
* @return string ISO year name
*/
@@
-356,9
+356,10
@@
class DateFormatter {
}
/**
}
/**
- * @todo document
- * @param string $iso
- * @return int|string
+ * Make a year one from an ISO year, for instance: '400 BC' from '-0399'.
+ * @param string $iso ISO year
+ * @return int|string int representing year number in case of AD dates, or string containing
+ * year number and 'BC' at the end otherwise.
*/
public function makeNormalYear( $iso ) {
if ( $iso[0] == '-' ) {
*/
public function makeNormalYear( $iso ) {
if ( $iso[0] == '-' ) {