44 $objects = preg_split(
"/\\@([\\w]*)/uix", $subject, null, PREG_SPLIT_DELIM_CAPTURE
45 | PREG_SPLIT_NO_EMPTY);
47 if (in_array($objects[0], self::$ignored_keywords)) {
48 $objects = array_splice($objects, 2);
51 if (strlen($objects[0]) <= 3) {
52 $objects = array_splice($objects, 1);
56 foreach ($objects as
$key => $object) {
57 if ((
int)
$key % 2 == 0 || (
int)
$key == 0) {
59 $entry[
'entryType'] = strtolower($object);
62 preg_match(
"/^{(?<cite>.*),\\n/um", $object, $cite_matches);
63 if ($cite_matches[
'cite']) {
64 $entry[
'cite'] = $cite_matches[
'cite'];
68 $re =
"/(?<attr>[\\w]*)\\s*=\\s*[{\"]*(?<content>(.*?))\\s*[}\"]*?\\s*[,]*?\\s*\\n/";
70 preg_match_all($re, $object, $matches, PREG_SET_ORDER);
72 foreach ($matches as $match) {
73 $clean = $match[
'content'];
74 $clean = preg_replace(
"/[\", \\t\\s]*\\n/u",
"\n", $clean);
76 $entry[strtolower($match[
'attr'])] = $clean;
120 $bibtex_special_chars[
'ä'] =
'{\"a}';
121 $bibtex_special_chars[
'ë'] =
'{\"e}';
122 $bibtex_special_chars[
'ï'] =
'{\"i}';
123 $bibtex_special_chars[
'ö'] =
'{\"o}';
124 $bibtex_special_chars[
'ü'] =
'{\"u}';
125 $bibtex_special_chars[
'Ä'] =
'{\"A}';
126 $bibtex_special_chars[
'Ë'] =
'{\"E}';
127 $bibtex_special_chars[
'Ï'] =
'{\"I}';
128 $bibtex_special_chars[
'Ö'] =
'{\"O}';
129 $bibtex_special_chars[
'Ü'] =
'{\"U}';
130 $bibtex_special_chars[
'â'] =
'{\^a}';
131 $bibtex_special_chars[
'ê'] =
'{\^e}';
132 $bibtex_special_chars[
'î'] =
'{\^i}';
133 $bibtex_special_chars[
'ô'] =
'{\^o}';
134 $bibtex_special_chars[
'û'] =
'{\^u}';
135 $bibtex_special_chars[
'Â'] =
'{\^A}';
136 $bibtex_special_chars[
'Ê'] =
'{\^E}';
137 $bibtex_special_chars[
'Î'] =
'{\^I}';
138 $bibtex_special_chars[
'Ô'] =
'{\^O}';
139 $bibtex_special_chars[
'Û'] =
'{\^U}';
140 $bibtex_special_chars[
'à'] =
'{\`a}';
141 $bibtex_special_chars[
'è'] =
'{\`e}';
142 $bibtex_special_chars[
'ì'] =
'{\`i}';
143 $bibtex_special_chars[
'ò'] =
'{\`o}';
144 $bibtex_special_chars[
'ù'] =
'{\`u}';
145 $bibtex_special_chars[
'À'] =
'{\`A}';
146 $bibtex_special_chars[
'È'] =
'{\`E}';
147 $bibtex_special_chars[
'Ì'] =
'{\`I}';
148 $bibtex_special_chars[
'Ò'] =
'{\`O}';
149 $bibtex_special_chars[
'Ù'] =
'{\`U}';
150 $bibtex_special_chars[
'á'] =
'{\\\'a}';
151 $bibtex_special_chars[
'é'] =
'{\\\'e}';
152 $bibtex_special_chars[
'í'] =
'{\\\'i}';
153 $bibtex_special_chars[
'ó'] =
'{\\\'o}';
154 $bibtex_special_chars[
'ú'] =
'{\\\'u}';
155 $bibtex_special_chars[
'Á'] =
'{\\\'A}';
156 $bibtex_special_chars[
'É'] =
'{\\\'E}';
157 $bibtex_special_chars[
'Í'] =
'{\\\'I}';
158 $bibtex_special_chars[
'Ó'] =
'{\\\'O}';
159 $bibtex_special_chars[
'Ú'] =
'{\\\'U}';
160 $bibtex_special_chars[
'à'] =
'{\`a}';
161 $bibtex_special_chars[
'è'] =
'{\`e}';
162 $bibtex_special_chars[
'ì'] =
'{\`i}';
163 $bibtex_special_chars[
'ò'] =
'{\`o}';
164 $bibtex_special_chars[
'ù'] =
'{\`u}';
165 $bibtex_special_chars[
'À'] =
'{\`A}';
166 $bibtex_special_chars[
'È'] =
'{\`E}';
167 $bibtex_special_chars[
'Ì'] =
'{\`I}';
168 $bibtex_special_chars[
'Ò'] =
'{\`O}';
169 $bibtex_special_chars[
'Ù'] =
'{\`U}';
170 $bibtex_special_chars[
'ç'] =
'{\c c}';
171 $bibtex_special_chars[
'ß'] =
'{\ss}';
172 $bibtex_special_chars[
'ñ'] =
'{\~n}';
173 $bibtex_special_chars[
'Ñ'] =
'{\~N}';
174 $bibtex_special_chars[
'ń'] =
"{\\'n}";
175 $bibtex_special_chars[
'l'] =
"{\\'n}";
176 $bibtex_special_chars[
'&'] =
"{\&}";
177 $bibtex_special_chars[
'@'] =
"{\@}";
242 return in_array($field_name, self::$standard_fields);
253 return in_array($entry_ype, self::$entry_types);
264 if (substr(
$s, 0, 3) == chr(hexdec(
'EF')) . chr(hexdec(
'BB')) . chr(hexdec(
'BF'))) {
265 return substr(
$s, 3);
static isStandardField($field_name)
setFileContent($file_content)
Create styles array
The data for the language used.
parseContent()
should return
Interface ilBibliograficFileReader.
Class ilBibliograficFileReaderBase.
static isEntryType($entry_ype)