1local specification = {
2
3
4
5 name = "apa",
6 version = "1.00",
7 comment = "APA specification",
8 author = "Alan Braslau and Hans Hagen",
9 copyright = "ConTeXt development team",
10
11
12
13 virtual = {
14 "authoryear",
15 "authoryears",
16 "authornum",
17 "num",
18 "suffix",
19 },
20
21
22
23 types = {
24
25
26
27
28
29
30
31
32
33 author = "author",
34 withauthor = "author",
35 editor = "author",
36 translator = "author",
37 artist = "author",
38 composer = "author",
39 producer = "author",
40 director = "author",
41 doi = "url",
42 url = "url",
43 page = "pagenumber",
44 pages = "pagenumber",
45 volume = "range",
46 number = "range",
47 keywords = "keyword",
48 year = "number",
49 },
50
51
52
53 categories = {
54
55
56
57 },
58}
59
60local generic = {
61
62
63
64
65
66
67 doi = { "doi", "url" },
68 editionset = { "edition", "volume", "number", "pages" },
69}
70
71
72
73
74
75
76
77
78
79
80
81local categories = specification.categories
82
83
84
85categories.article = {
86 sets = {
87 author = { "author", "organization", "editor", "title" },
88 doi = generic.doi,
89 },
90 required = {
91 "author",
92 },
93 optional = {
94 "withauthor", "translator",
95 "year",
96 "subtitle", "type", "file",
97 "journal", "volume", "number", "pages",
98 "doi", "note",
99
100
101
102
103
104
105
106 },
107}
108
109
110
111categories.magazine = {
112 sets = categories.article.sets,
113 required = {
114 "author",
115 "year",
116 "journal",
117 },
118 optional = {
119 "withauthor", "translator",
120 "subtitle", "type", "file",
121 "number",
122 "month", "day",
123 "doi", "note",
124 },
125}
126
127categories.newspaper = categories.magazine
128
129
130
131categories.periodical = {
132 sets = {
133 author = { "editor", "publisher", "organization", },
134 doi = generic.doi,
135 },
136 required = {
137 "title",
138 "year",
139 },
140 optional = {
141 "author", "withauthor", "translator",
142 "subtitle", "file",
143 "series", "volume", "number", "month",
144 "organization",
145 "doi", "note",
146 },
147}
148
149
150
151categories.standard = {
152 sets = {
153 author = { "author", "institution", "organization" },
154 doi = generic.doi,
155 },
156 required = {
157 "author",
158 "year",
159 "title", "subtitle",
160 "doi", "note",
161 },
162 optional = {
163 "withauthor", "translator",
164 },
165}
166
167
168
169categories.book = {
170 sets = {
171 author = { "author", "editor", "publisher", "title" },
172 ineditor = { "editor" },
173 editionset = generic.editionset,
174 doi = generic.doi,
175 },
176 required = { "author" },
177 optional = {
178 "ineditor",
179 "withauthor", "translator",
180 "year", "month", "day",
181 "subtitle", "type", "file",
182 "editionset", "series",
183 "address",
184 "doi", "note",
185 "abstract",
186 },
187}
188
189
190
191categories.inbook = {
192 sets = {
193 author = { "author", "organization", "editor", "publisher", "title", },
194 ineditor = { "editor" },
195 editionset = generic.editionset,
196 doi = generic.doi,
197 },
198 required = {
199 "author",
200 "year" ,
201 },
202 optional = {
203 "ineditor",
204 "withauthor", "translator",
205 "subtitle", "type", "file",
206 "booktitle", "subbooktitle",
207
208 "editionset", "series",
209 "month",
210 "address",
211 "doi", "note",
212 },
213}
214
215
216
217
218categories.incollection = {
219 sets = {
220 author = { "author", "editor", "publisher", "title", },
221 ineditor = { "editor" },
222 editionset = generic.editionset,
223 doi = generic.doi,
224 },
225 required = {
226 "author",
227 "booktitle",
228 "year",
229 },
230 optional = {
231 "ineditor",
232 "withauthor", "translator",
233 "subtitle", "type", "file",
234 "subbooktitle",
235 "editionset", "series",
236
237 "month",
238 "address",
239 "doi", "note",
240 },
241}
242
243
244
245categories.booklet = {
246 sets = {
247 author = { "author", "title", },
248 publisher = { "howpublished" },
249 doi = generic.doi,
250 },
251 required = {
252 "author"
253 },
254 optional = {
255 "withauthor", "translator",
256 "publisher",
257 "year", "month",
258 "subtitle", "type", "file",
259 "address",
260 "doi", "note",
261 },
262}
263
264
265
266categories.proceedings = {
267 sets = {
268 author = { "editor", "organization", "publisher", "title" },
269 publisher = { "publisher", "organization" },
270 editionset = generic.editionset,
271 doi = generic.doi,
272 },
273 required = {
274 "author",
275 "year"
276 },
277 optional = {
278 "withauthor", "translator",
279 "publisher",
280 "subtitle", "file",
281 "editionset", "series",
282 "month",
283 "address",
284 "doi", "note",
285 },
286}
287
288
289
290categories.inproceedings = {
291 sets = categories.incollection.sets,
292 required = categories.incollection.required,
293 optional = {
294 "withauthor", "translator",
295 "subtitle", "type", "file",
296 "month",
297 "edition", "series",
298 "address", "organization",
299 "doi", "note",
300 },
301}
302
303categories.conference = categories.inproceedings
304
305
306
307categories.thesis = {
308 sets = {
309 doi = generic.doi,
310 },
311 required = {
312 "author",
313 "title",
314 "school",
315 "year",
316 "type"
317 },
318 optional = {
319 "withauthor", "translator",
320 "subtitle", "file",
321 "month",
322 "address",
323 "doi", "note",
324 },
325}
326
327categories.mastersthesis = {
328 sets = categories.thesis.sets,
329 required = {
330 "author",
331 "title",
332 "school",
333 "year"
334 },
335 optional = {
336 "withauthor", "translator",
337 "type",
338 "subtitle", "file",
339 "month",
340 "address",
341 "doi", "note",
342 },
343}
344categories.phdthesis = categories.mastersthesis
345
346
347
348categories.techreport = {
349 sets = {
350 author = { "author", "institution", "publisher", "title" },
351 publisher = { "publisher", "institution", },
352 editionset = { "type", "volume", "number", "pages" },
353 doi = generic.doi,
354 },
355 required = {
356 "author",
357 "title",
358 "institution",
359 "year"
360 },
361 optional = {
362 "withauthor", "translator",
363 "publisher",
364 "address",
365 "subtitle", "file",
366 "editionset",
367 "month",
368 "doi", "note",
369 },
370}
371
372
373
374categories.manual = {
375 sets = {
376 author = { "author", "organization", "publisher", "title" },
377 publisher = { "publisher", "organization", },
378 editionset = generic.editionset,
379 doi = generic.doi,
380 },
381 required = {
382 "title"
383 },
384 optional = {
385 "author", "publisher",
386 "withauthor", "translator",
387 "address",
388 "subtitle", "file",
389 "editionset", "month", "year",
390 "doi", "note",
391
392 },
393}
394
395
396
397categories.patent = {
398 sets = {
399 author = { "author", "assignee", },
400 publisher = { "publisher", "assignee", },
401 year = { "year", "yearfiled", },
402 month = { "month", "monthfiled", },
403 day = { "day", "dayfiled", },
404 doi = generic.doi,
405 },
406 required = {
407 "nationality",
408 "number",
409 "year",
410 },
411 optional = {
412 "type",
413
414 "author", "publisher",
415 "withauthor", "translator",
416 "title", "subtitle", "file",
417 "address",
418 "day", "month",
419 "doi", "note"
420 },
421}
422
423
424
425categories.unpublished = {
426 sets = {
427 doi = generic.doi,
428 },
429 required = {
430 "author",
431 "title",
432 "note"
433 },
434 optional = {
435 "withauthor", "translator",
436 "subtitle", "file",
437 "year", "month",
438 "doi"
439 },
440}
441
442
443
444categories.electronic = {
445 sets = {
446 doi = generic.doi,
447 author = { "author", "organization", },
448 },
449 required = {
450 "title"
451 },
452 optional = {
453 "subtitle", "type", "file",
454 "year", "month",
455 "author", "withauthor", "translator",
456 "address",
457 "organization",
458 "howpublished",
459 "doi", "note"
460 },
461}
462
463
464
465categories.film = {
466 sets = {
467 doi = generic.doi,
468 author = { "author", "producer", "director", },
469 },
470 required = {
471 "author",
472 "title",
473 "year",
474 "address", "publisher",
475 },
476 optional = {
477 "withauthor", "translator",
478 "type",
479 "note",
480 "doi",
481 },
482}
483
484categories.music = {
485 sets = {
486 doi = generic.doi,
487 author = { "composer", "artist", "title", "album" },
488 title = { "title", "album", },
489 },
490 required = {
491 "author",
492 "title",
493 "year",
494 "address", "publisher",
495 },
496 optional = {
497 "withauthor", "translator",
498 "type",
499 "note",
500 "doi",
501 },
502}
503
504
505
506categories.misc = {
507 sets = {
508 doi = generic.doi,
509 },
510 required = {
511
512 },
513 optional = {
514 "author", "withauthor", "translator",
515 "title", "subtitle", "file",
516 "year", "month",
517 "howpublished",
518 "doi", "note",
519 },
520}
521
522
523
524categories.other = {
525 sets = {
526 doi = generic.doi,
527 },
528 required = {
529 "author",
530 "title",
531 "year"
532 },
533 optional = {
534 "withauthor", "translator",
535 "subtitle", "file",
536 "doi", "note",
537 },
538}
539
540
541
542categories.literal = {
543 sets = {
544 author = { "key" },
545 doi = generic.doi,
546 },
547 required = {
548 "author",
549 "text"
550 },
551 optional = {
552 "withauthor", "translator",
553 "doi", "note"
554 },
555 virtual = false,
556}
557
558
559
560return specification
561 |