Lines Matching defs:doc
106 * @param $doc
108 public static function addEolCharacterIfNotPresent(&$doc)
110 $strlen = strlen($doc);
114 if ($doc[$strlen - 1] != DOKU_LF) {
115 $doc .= DOKU_LF;
122 * @param $doc
125 public static function rtrim(&$doc, $string)
131 $doc = trim($doc);
133 $length = strlen($doc) - strlen($string);
134 if (substr($doc, $length) === $string) {
135 $doc = substr($doc, 0, $length);
143 * @param $doc
146 public static function ltrim(&$doc, $string)
149 $doc = trim($doc);
152 if (substr($doc, 0, $length) === $string) {
153 $doc = substr($doc, $length);