Coverage for /usr/local/lib/python3.11/site-packages/tgclients/databinding/textgrid_metadata_2010.py: 100%
210 statements
« prev ^ index » next coverage.py v7.4.4, created at 2024-04-02 16:49 +0000
« prev ^ index » next coverage.py v7.4.4, created at 2024-04-02 16:49 +0000
1# SPDX-FileCopyrightText: 2022 Georg-August-Universität Göttingen
2#
3# SPDX-License-Identifier: CC0-1.0
5from dataclasses import dataclass, field
6from enum import Enum
7from typing import List, Optional, Union
8from xsdata.models.datatype import XmlDate, XmlDateTime, XmlPeriod
9from tgclients.databinding.rdf import Rdf
10from tgclients.databinding.textgrid_metadata_agent_2010 import (
11 AgentType,
12 PersonType,
13)
14from tgclients.databinding.textgrid_metadata_script_2010 import FormOfNotationType
16__NAMESPACE__ = "http://textgrid.info/namespaces/metadata/core/2010"
19@dataclass
20class AuthorityType:
21 """
22 references to authority files like thesauri etc.
23 """
24 class Meta:
25 name = "authorityType"
27 id: List["AuthorityType.Id"] = field(
28 default_factory=list,
29 metadata={
30 "type": "Element",
31 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
32 }
33 )
34 value: Optional[str] = field(
35 default=None,
36 metadata={
37 "type": "Element",
38 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
39 "required": True,
40 }
41 )
43 @dataclass
44 class Id:
45 """
46 Attributes
47 value:
48 type: The type of the ID in a non-textgrid context
49 """
50 value: str = field(
51 default="",
52 metadata={
53 "required": True,
54 }
55 )
56 type: Optional[str] = field(
57 default=None,
58 metadata={
59 "type": "Attribute",
60 }
61 )
64@dataclass
65class DateType:
66 """
67 same function as our old sub-schema.
68 """
69 class Meta:
70 name = "dateType"
72 value: str = field(
73 default="",
74 metadata={
75 "required": True,
76 }
77 )
78 date: Optional[Union[XmlDate, XmlPeriod]] = field(
79 default=None,
80 metadata={
81 "type": "Attribute",
82 }
83 )
84 not_before: Optional[Union[XmlDate, XmlPeriod]] = field(
85 default=None,
86 metadata={
87 "name": "notBefore",
88 "type": "Attribute",
89 }
90 )
91 not_after: Optional[Union[XmlDate, XmlPeriod]] = field(
92 default=None,
93 metadata={
94 "name": "notAfter",
95 "type": "Attribute",
96 }
97 )
100class GeneratedTypeAvailability(Enum):
101 """
102 possible values.
103 """
104 DEFAULT = "default"
105 PUBLIC = "public"
106 STABLE = "stable"
109@dataclass
110class IdentifierType:
111 """An unambiguous reference to the resource within a given context.
113 Same
114 as: http://purl.org/dc/terms/identifier
116 Attributes
117 value:
118 type: The type of the URI in a non-TextGrid context (e.g., a
119 ISBN or ISSN, a shelfmark, a registration or inventary
120 number)
121 """
122 class Meta:
123 name = "identifierType"
125 value: str = field(
126 default="",
127 metadata={
128 "required": True,
129 }
130 )
131 type: Optional[str] = field(
132 default=None,
133 metadata={
134 "type": "Attribute",
135 "required": True,
136 }
137 )
140class PidPidType(Enum):
141 HANDLE = "handle"
142 URN = "urn"
143 DOI = "doi"
144 ARK = "ark"
145 PURL = "purl"
146 OTHER = "other"
149class WorkTypeGenre(Enum):
150 """The genre of the work. Same as:
152 http://purl.org/dc/terms/type - Hier natürlich englische Bezeichnungen,
153 wenn wir mal die Liste finalisiert haben. Siehe
154 http://www.textgrid.de/intern/wiki1/wiki/Genres.html
155 """
156 DRAMA = "drama"
157 PROSE = "prose"
158 VERSE = "verse"
159 REFERENCE_WORK = "reference work"
160 NON_FICTION = "non-fiction"
161 NON_TEXT = "non-text"
162 OTHER = "other"
165@dataclass
166class BibliographicCitationType:
167 """
168 Attributes
169 author: A person or organization chiefly responsible for the
170 intellectual or artistic content of the source, usually
171 printed text. Same as:
172 http://id.loc.gov/vocabulary/relators/aut.html. For a
173 detailed description of the author the "agent" element in
174 the "workType" has to be used.
175 editor: A person or organization who prepares for publication a
176 work not primarily his/her own, such as by elucidating text,
177 adding introductory or other critical matter, or technically
178 directing an editorial staff. Same as:
179 http://id.loc.gov/vocabulary/relators/edt.htmln
180 edition_title: Name of the source (e.g., the titel of a book or
181 a journal).
182 place_of_publication: Place where the source was published.
183 publisher: A person or organization that makes the source
184 available to the public. Same as:
185 http://id.loc.gov/vocabulary/relators/pbl.html
186 date_of_publication: TG dateType.
187 edition_no: Statement of the edition of the source - usually a
188 phrase with or without numbers (e.g., first edition, 4th
189 ed., etc.)
190 series: Titel of a series in which the source was issued.
191 volume: Volume designation - is usually expressed as a number
192 but could be roman numerals or non-numeric (e.g., 124, VI,
193 etc.)
194 issue: Designation of the issue of a journal the source was
195 published. While usually numeric, it could be non-numeric
196 (e.g. Spring)
197 spage: Designates the page the source starts in a volume or
198 issue. Pages are not always numeric.
199 epage: Designates the page the source ends in a volume or issue.
200 Page are not always numeric.
201 bib_identifier:
202 """
203 class Meta:
204 name = "bibliographicCitationType"
206 author: List[PersonType] = field(
207 default_factory=list,
208 metadata={
209 "type": "Element",
210 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
211 }
212 )
213 editor: List[PersonType] = field(
214 default_factory=list,
215 metadata={
216 "type": "Element",
217 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
218 }
219 )
220 edition_title: List[str] = field(
221 default_factory=list,
222 metadata={
223 "name": "editionTitle",
224 "type": "Element",
225 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
226 "min_occurs": 1,
227 }
228 )
229 place_of_publication: List[AuthorityType] = field(
230 default_factory=list,
231 metadata={
232 "name": "placeOfPublication",
233 "type": "Element",
234 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
235 }
236 )
237 publisher: List[PersonType] = field(
238 default_factory=list,
239 metadata={
240 "type": "Element",
241 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
242 }
243 )
244 date_of_publication: Optional[DateType] = field(
245 default=None,
246 metadata={
247 "name": "dateOfPublication",
248 "type": "Element",
249 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
250 }
251 )
252 edition_no: Optional[str] = field(
253 default=None,
254 metadata={
255 "name": "editionNo",
256 "type": "Element",
257 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
258 }
259 )
260 series: List[str] = field(
261 default_factory=list,
262 metadata={
263 "type": "Element",
264 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
265 }
266 )
267 volume: Optional[str] = field(
268 default=None,
269 metadata={
270 "type": "Element",
271 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
272 }
273 )
274 issue: Optional[str] = field(
275 default=None,
276 metadata={
277 "type": "Element",
278 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
279 }
280 )
281 spage: Optional[str] = field(
282 default=None,
283 metadata={
284 "type": "Element",
285 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
286 }
287 )
288 epage: Optional[str] = field(
289 default=None,
290 metadata={
291 "type": "Element",
292 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
293 }
294 )
295 bib_identifier: Optional[IdentifierType] = field(
296 default=None,
297 metadata={
298 "name": "bibIdentifier",
299 "type": "Element",
300 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
301 }
302 )
305@dataclass
306class CollectionType:
307 """
308 TODO.
310 Attributes
311 collector: Person or corporate body creating a collection. Same
312 as: http://id.loc.gov/vocabulary/relators/col.html
313 abstract: A summary of the collection. Same as:
314 http://purl.org/dc/terms/abstract
315 collection_description: URL of a description of this collection
316 (e.g., project description on the website of a funding
317 agency) FIXME is this still the Same as:
318 http://purl.org/dc/terms/description
319 spatial: Spatial characteristics of the collection. Same as:
320 http://purl.org/dc/terms/spatial
321 temporal: Temporal characteristics of the collection. Same as:
322 http://purl.org/dc/terms/temporal
323 subject: The topic of the collection. Same as:
324 http://purl.org/dc/terms/subject.
325 """
326 class Meta:
327 name = "collectionType"
329 collector: List[PersonType] = field(
330 default_factory=list,
331 metadata={
332 "type": "Element",
333 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
334 "min_occurs": 1,
335 }
336 )
337 abstract: Optional[str] = field(
338 default=None,
339 metadata={
340 "type": "Element",
341 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
342 }
343 )
344 collection_description: List[str] = field(
345 default_factory=list,
346 metadata={
347 "name": "collectionDescription",
348 "type": "Element",
349 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
350 }
351 )
352 spatial: List[AuthorityType] = field(
353 default_factory=list,
354 metadata={
355 "type": "Element",
356 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
357 }
358 )
359 temporal: List[AuthorityType] = field(
360 default_factory=list,
361 metadata={
362 "type": "Element",
363 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
364 }
365 )
366 subject: List[AuthorityType] = field(
367 default_factory=list,
368 metadata={
369 "type": "Element",
370 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
371 }
372 )
375@dataclass
376class GeneratedType:
377 """The generatedType is cerated by the middleware (TG-crud), and is
378 delivered with every T-crud call, that delivers back the metadata
379 ObjectType.
381 With every #UPDATE or #UPDATEMETADATA call this generatedType must
382 also be sent in the request parameter's objectType, to be able to
383 handle concurrent modification of TextGrid objects.
385 Attributes
386 created: Date of creation of the resource. Same as:
387 http://purl.org/dc/terms/created. TODO Datentyp
388 spezifizieren
389 last_modified: Date on which the resource was changed. Same as:
390 http://purl.org/dc/terms/modified. TODO Datentyp
391 spezifizieren
392 issued: Date of formal issuance (e.g., publication) of the
393 resource. Same as: http://purl.org/dc/terms/issued. TODO
394 Datentyp (oder xs:date?) spezifizieren
395 textgrid_uri: Subproperty of identifier. An unambiguous
396 reference to the resource within the textgrid context.
397 Subproperty of identifier:
398 http://purl.org/dc/elements/1.1/identifier. Hier in jedem
399 Falle die TextGrid-URI (NOID). FIXME für die Fälle (1)
400 veröffentlicht (PID – oder kommt der in
401 ../provided/identifier?), (2) externe Datenquelle (oder auch
402 der nicht hier?) noch weitere Identifier hier? Sonst
403 Kardinalität auf 1..1 setzen.
404 revision: revision number
405 pid: persistent identifier
406 extent: The size of the resource in bytes. Same as:
407 http://purl.org/dc/terms/extent.
408 fixity: "Information used to verify whether an object has been
409 altered in an undocumented or unauthorized way." - stolen
410 from the PREMIS Object Entity sub-schema, see
411 http://www.loc.gov/standards/premis/v1/Object-v1-1.xsd. For
412 detailed documentation see the PREMIS Data Dictionary
413 (http://www.loc.gov/standards/premis/v2/premis-dd-2-0.pdf)
414 section 1.5.2
415 data_contributor: Use for a person that submits data in
416 textgrid. Same as:
417 http://lcweb2.loc.gov/diglib/loc.terms/relators/DTC.
418 project: Project name and id.
419 warning: Error report provided by the middleware when an
420 incorrect textgrid object has been stored.
421 permissions: Same as accessRights ("Information about who can
422 access the resource or an indication of its security status"
423 http://purl.org/dc/terms/accessRights) in textgrid? In
424 TextGrid, this is dependent on the role of the person that
425 accesses the resource.
426 availability: information whether the TG object is subject of
427 the (role based) rights management or isPublic or isStable
428 any_element: Reserved for future additions
429 """
430 class Meta:
431 name = "generatedType"
433 created: Optional[XmlDateTime] = field(
434 default=None,
435 metadata={
436 "type": "Element",
437 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
438 "required": True,
439 }
440 )
441 last_modified: Optional[XmlDateTime] = field(
442 default=None,
443 metadata={
444 "name": "lastModified",
445 "type": "Element",
446 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
447 "required": True,
448 }
449 )
450 issued: Optional[XmlDateTime] = field(
451 default=None,
452 metadata={
453 "type": "Element",
454 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
455 }
456 )
457 textgrid_uri: Optional["GeneratedType.TextgridUri"] = field(
458 default=None,
459 metadata={
460 "name": "textgridUri",
461 "type": "Element",
462 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
463 "required": True,
464 }
465 )
466 revision: Optional[int] = field(
467 default=None,
468 metadata={
469 "type": "Element",
470 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
471 "required": True,
472 }
473 )
474 pid: List["GeneratedType.Pid"] = field(
475 default_factory=list,
476 metadata={
477 "type": "Element",
478 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
479 }
480 )
481 extent: Optional[int] = field(
482 default=None,
483 metadata={
484 "type": "Element",
485 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
486 "required": True,
487 }
488 )
489 fixity: List["GeneratedType.Fixity"] = field(
490 default_factory=list,
491 metadata={
492 "type": "Element",
493 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
494 }
495 )
496 data_contributor: Optional[str] = field(
497 default=None,
498 metadata={
499 "name": "dataContributor",
500 "type": "Element",
501 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
502 "required": True,
503 }
504 )
505 project: Optional["GeneratedType.Project"] = field(
506 default=None,
507 metadata={
508 "type": "Element",
509 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
510 "required": True,
511 }
512 )
513 warning: List["GeneratedType.Warning"] = field(
514 default_factory=list,
515 metadata={
516 "type": "Element",
517 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
518 }
519 )
520 permissions: Optional[str] = field(
521 default=None,
522 metadata={
523 "type": "Element",
524 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
525 }
526 )
527 availability: Optional[GeneratedTypeAvailability] = field(
528 default=None,
529 metadata={
530 "type": "Element",
531 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
532 "required": True,
533 }
534 )
535 any_element: List[object] = field(
536 default_factory=list,
537 metadata={
538 "type": "Wildcard",
539 "namespace": "##any",
540 }
541 )
543 @dataclass
544 class TextgridUri:
545 """
546 Attributes
547 value:
548 ext_ref: The TG metadata refer to an external object
549 """
550 value: str = field(
551 default="",
552 metadata={
553 "required": True,
554 }
555 )
556 ext_ref: Optional[str] = field(
557 default=None,
558 metadata={
559 "name": "extRef",
560 "type": "Attribute",
561 }
562 )
564 @dataclass
565 class Pid:
566 """
567 Attributes
568 value:
569 pid_type: PID type
570 """
571 value: str = field(
572 default="",
573 metadata={
574 "required": True,
575 }
576 )
577 pid_type: PidPidType = field(
578 default=PidPidType.HANDLE,
579 metadata={
580 "name": "pidType",
581 "type": "Attribute",
582 }
583 )
585 @dataclass
586 class Fixity:
587 """
588 Attributes
589 message_digest_algorithm: The specific algorithm used to
590 construct the message digest for the digital object,
591 e.g. MD5, SHA-1..n etc.
592 message_digest: The output of the message digest algorithm,
593 i.e. the checksum
594 message_digest_originator: The agent that created the
595 original message digest that is compared in a fixity
596 check. In TextGrid: "TG-crud" or Service-endpoint?
597 """
598 message_digest_algorithm: Optional[str] = field(
599 default=None,
600 metadata={
601 "name": "messageDigestAlgorithm",
602 "type": "Element",
603 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
604 "required": True,
605 }
606 )
607 message_digest: Optional[str] = field(
608 default=None,
609 metadata={
610 "name": "messageDigest",
611 "type": "Element",
612 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
613 "required": True,
614 }
615 )
616 message_digest_originator: Optional[str] = field(
617 default=None,
618 metadata={
619 "name": "messageDigestOriginator",
620 "type": "Element",
621 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
622 }
623 )
625 @dataclass
626 class Project:
627 value: str = field(
628 default="",
629 metadata={
630 "required": True,
631 }
632 )
633 id: Optional[str] = field(
634 default=None,
635 metadata={
636 "type": "Attribute",
637 "required": True,
638 }
639 )
641 @dataclass
642 class Warning:
643 """
644 Attributes
645 value:
646 uri: The URI the warning occured.
647 """
648 value: str = field(
649 default="",
650 metadata={
651 "required": True,
652 }
653 )
654 uri: Optional[str] = field(
655 default=None,
656 metadata={
657 "type": "Attribute",
658 }
659 )
662@dataclass
663class ItemType:
664 """
665 Attributes
666 rights_holder: Person or organization with copyright for an
667 item. Same as: http://purl.org/dc/terms/rightsHolder FIXME
668 dcterms-Problem wieder: Damit ist möglicherweise auch die
669 Entscheidung, als Datentyp für die diversen Personenfelder
670 wie rightsHolder etc. dcterms:irgendwas zu nehmen,
671 hinfällig, da damit wohl keine Möglichkeit zur Spezifikation
672 einer ID zusätzlich zum Inhaltsstring (Namen) gegeben ist.
673 """
674 class Meta:
675 name = "itemType"
677 rights_holder: List[PersonType] = field(
678 default_factory=list,
679 metadata={
680 "name": "rightsHolder",
681 "type": "Element",
682 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
683 }
684 )
687@dataclass
688class ObjectCitationType:
689 """
690 Attributes
691 object_title: Name of the source (e.g., the name of a painting,
692 sculpture, furniture, etc. ).
693 object_contributor: A person or organization responsible for the
694 intellectual or artistic content of a work. Same as:
695 http://purl.org/dc/terms/contributor.
696 object_date: Date of an event in the lifecycle of the resource.
697 Same as: http://purl.org/dc/terms/date. For a detailed
698 description of the date of creation the "dateOfCreation" and
699 "timeOfCreation" elements in the "workType" have to be used.
700 object_identifier:
701 """
702 class Meta:
703 name = "objectCitationType"
705 object_title: List[str] = field(
706 default_factory=list,
707 metadata={
708 "name": "objectTitle",
709 "type": "Element",
710 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
711 "min_occurs": 1,
712 }
713 )
714 object_contributor: List[AgentType] = field(
715 default_factory=list,
716 metadata={
717 "name": "objectContributor",
718 "type": "Element",
719 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
720 }
721 )
722 object_date: Optional[DateType] = field(
723 default=None,
724 metadata={
725 "name": "objectDate",
726 "type": "Element",
727 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
728 }
729 )
730 object_identifier: Optional[IdentifierType] = field(
731 default=None,
732 metadata={
733 "name": "objectIdentifier",
734 "type": "Element",
735 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
736 }
737 )
740@dataclass
741class ProvidedType:
742 """
743 Attributes
744 title: A name given to the resource. Same as:
745 http://purl.org/dc/terms/title; FIXME Uniform-Title
746 allerdings ist 1..1 :-(
747 identifier:
748 format: File format of a textgrid object. Same as:
749 http://purl.org/dc/terms/format. TODO Specification of type.
750 notes: Anything that doesn't fit into the other fields.
751 """
752 class Meta:
753 name = "providedType"
755 title: List[str] = field(
756 default_factory=list,
757 metadata={
758 "type": "Element",
759 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
760 "min_occurs": 1,
761 }
762 )
763 identifier: List[IdentifierType] = field(
764 default_factory=list,
765 metadata={
766 "type": "Element",
767 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
768 }
769 )
770 format: Optional[str] = field(
771 default=None,
772 metadata={
773 "type": "Element",
774 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
775 "required": True,
776 }
777 )
778 notes: Optional[str] = field(
779 default=None,
780 metadata={
781 "type": "Element",
782 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
783 }
784 )
787@dataclass
788class RelationType:
789 """
790 Attributes
791 is_derived_from: Link to an object the described textgrid object
792 is derived from.
793 is_alternative_format_of: Link to an object having the same
794 content as the described textgrid object but in another
795 format.
796 has_adaptor: Link to an object which is an adaptor of the
797 described textgrid object.
798 has_schema: Link to an object which is a schema of the described
799 textgrid object.
800 rdf:
801 """
802 class Meta:
803 name = "relationType"
805 is_derived_from: Optional[str] = field(
806 default=None,
807 metadata={
808 "name": "isDerivedFrom",
809 "type": "Element",
810 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
811 }
812 )
813 is_alternative_format_of: Optional[str] = field(
814 default=None,
815 metadata={
816 "name": "isAlternativeFormatOf",
817 "type": "Element",
818 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
819 }
820 )
821 has_adaptor: Optional[str] = field(
822 default=None,
823 metadata={
824 "name": "hasAdaptor",
825 "type": "Element",
826 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
827 }
828 )
829 has_schema: Optional[str] = field(
830 default=None,
831 metadata={
832 "name": "hasSchema",
833 "type": "Element",
834 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
835 }
836 )
837 rdf: Optional[Rdf] = field(
838 default=None,
839 metadata={
840 "name": "RDF",
841 "type": "Element",
842 "namespace": "http://www.w3.org/1999/02/22-rdf-syntax-ns#",
843 }
844 )
847@dataclass
848class WorkType:
849 """
850 FIXME Grobklassifikation.
852 Attributes
853 agent:
854 abstract: A summary of the work. Same as:
855 http://purl.org/dc/terms/abstract
856 date_of_creation: unser (TextGrid) Datumsmodell FIXME: "created"
857 gibts schon in generated
858 spatial: Spatial characteristics of the work. Same as:
859 http://purl.org/dc/terms/spatial
860 temporal: Temporal characteristics of the work. Same as:
861 http://purl.org/dc/terms/temporal
862 subject: The topic of the work. Same as:
863 http://purl.org/dc/terms/subject.
864 genre: Grobklassifikation
865 type: The nature or genre of the work. Same as:
866 http://purl.org/dc/terms/type FIXME Feinklassifikation,
867 editierbare Auswahlliste
868 """
869 class Meta:
870 name = "workType"
872 agent: List[AgentType] = field(
873 default_factory=list,
874 metadata={
875 "type": "Element",
876 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
877 }
878 )
879 abstract: List[str] = field(
880 default_factory=list,
881 metadata={
882 "type": "Element",
883 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
884 }
885 )
886 date_of_creation: Optional[DateType] = field(
887 default=None,
888 metadata={
889 "name": "dateOfCreation",
890 "type": "Element",
891 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
892 "required": True,
893 }
894 )
895 spatial: List[AuthorityType] = field(
896 default_factory=list,
897 metadata={
898 "type": "Element",
899 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
900 }
901 )
902 temporal: List[AuthorityType] = field(
903 default_factory=list,
904 metadata={
905 "type": "Element",
906 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
907 }
908 )
909 subject: List[AuthorityType] = field(
910 default_factory=list,
911 metadata={
912 "type": "Element",
913 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
914 }
915 )
916 genre: List[WorkTypeGenre] = field(
917 default_factory=list,
918 metadata={
919 "type": "Element",
920 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
921 "min_occurs": 1,
922 }
923 )
924 type: List[str] = field(
925 default_factory=list,
926 metadata={
927 "type": "Element",
928 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
929 }
930 )
933@dataclass
934class GenericType:
935 """
936 Attributes
937 provided: Metadata provided by the client.
938 generated: Metadata generated by the middleware components.
939 """
940 class Meta:
941 name = "genericType"
943 provided: Optional[ProvidedType] = field(
944 default=None,
945 metadata={
946 "type": "Element",
947 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
948 "required": True,
949 }
950 )
951 generated: Optional[GeneratedType] = field(
952 default=None,
953 metadata={
954 "type": "Element",
955 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
956 }
957 )
960@dataclass
961class SourceType:
962 """Relation between the textgrid object and the description of the source
963 of this object.
965 Same as: http://purl.org/dc/terms/source
966 """
967 class Meta:
968 name = "sourceType"
970 bibliographic_citation: Optional[BibliographicCitationType] = field(
971 default=None,
972 metadata={
973 "name": "bibliographicCitation",
974 "type": "Element",
975 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
976 }
977 )
978 object_citation: Optional[ObjectCitationType] = field(
979 default=None,
980 metadata={
981 "name": "objectCitation",
982 "type": "Element",
983 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
984 }
985 )
988@dataclass
989class EditionType:
990 """
991 Attributes
992 is_edition_of: Manifestation of which work? Value must be the
993 TextGrid URI of a TextGrid Work object. Field is mandatory
994 on publication. Same as:
995 http://rdvocab.info/RDARelationshipsWEMI/manifestationOfWork
996 agent:
997 source:
998 form_of_notation:
999 language:
1000 license: A legal document giving official permission to do
1001 something with the resource. Same as:
1002 http://purl.org/dc/terms/license.
1003 """
1004 class Meta:
1005 name = "editionType"
1007 is_edition_of: Optional[str] = field(
1008 default=None,
1009 metadata={
1010 "name": "isEditionOf",
1011 "type": "Element",
1012 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
1013 }
1014 )
1015 agent: List[AgentType] = field(
1016 default_factory=list,
1017 metadata={
1018 "type": "Element",
1019 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
1020 "min_occurs": 1,
1021 }
1022 )
1023 source: List[SourceType] = field(
1024 default_factory=list,
1025 metadata={
1026 "type": "Element",
1027 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
1028 }
1029 )
1030 form_of_notation: List[FormOfNotationType] = field(
1031 default_factory=list,
1032 metadata={
1033 "name": "formOfNotation",
1034 "type": "Element",
1035 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
1036 }
1037 )
1038 language: List[str] = field(
1039 default_factory=list,
1040 metadata={
1041 "type": "Element",
1042 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
1043 "pattern": r"[a-z][a-z][a-z]",
1044 }
1045 )
1046 license: Optional["EditionType.License"] = field(
1047 default=None,
1048 metadata={
1049 "type": "Element",
1050 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
1051 }
1052 )
1054 @dataclass
1055 class License:
1056 """
1057 Attributes
1058 value:
1059 license_uri: The context in which a license originates.
1060 Recommendation is to use Creative Commons (see:
1061 http://creativecommons.org/licenses/)
1062 """
1063 value: str = field(
1064 default="",
1065 metadata={
1066 "required": True,
1067 }
1068 )
1069 license_uri: Optional[str] = field(
1070 default=None,
1071 metadata={
1072 "name": "licenseUri",
1073 "type": "Attribute",
1074 }
1075 )
1078@dataclass
1079class Object:
1080 """
1081 The root element should also be used in CRUD arguments and returned by TG-
1082 search whenever TG-search returns complete metadata records.
1084 Attributes
1085 generic: Metadata available in all kinds of TextGrid objects.
1086 item: Item specific metadata.
1087 edition: Metadata specific for editions. - An embodiment of a
1088 work. Broader than:
1089 http://rdvocab.info/uri/schema/FRBRentitiesRDA/Manifestation
1090 work: Metadata specific for works. - A distinct intellectual or
1091 artistic creation. Broader than:
1092 http://rdvocab.info/uri/schema/FRBRentitiesRDA/Work
1093 collection: FIXME - je nach Sammlungs-Konzept und dessen
1094 Umsetzung - public-Bereich
1095 custom: The custom field may contain any additional metadata
1096 records for specific projects or specific applications.
1097 relations: FIXME wir haben ein paar spezifische Relationen,
1098 wollen aber auch beliebige Beziehungen durch die Anwender
1099 erlauben. Die Optionen hier sind vermutlich: (a) wir
1100 erlauben beliebiges RDF/XML und werten bestimmte
1101 bestandteile aus. (b) wir erlauben "unsere" relationen +
1102 beliebiges RDF/XML, also eine Substruktur
1103 """
1104 class Meta:
1105 name = "object"
1106 namespace = "http://textgrid.info/namespaces/metadata/core/2010"
1108 generic: Optional[GenericType] = field(
1109 default=None,
1110 metadata={
1111 "type": "Element",
1112 "required": True,
1113 }
1114 )
1115 item: Optional[ItemType] = field(
1116 default=None,
1117 metadata={
1118 "type": "Element",
1119 }
1120 )
1121 edition: Optional[EditionType] = field(
1122 default=None,
1123 metadata={
1124 "type": "Element",
1125 }
1126 )
1127 work: Optional[WorkType] = field(
1128 default=None,
1129 metadata={
1130 "type": "Element",
1131 }
1132 )
1133 collection: Optional[CollectionType] = field(
1134 default=None,
1135 metadata={
1136 "type": "Element",
1137 }
1138 )
1139 custom: Optional["Object.Custom"] = field(
1140 default=None,
1141 metadata={
1142 "type": "Element",
1143 }
1144 )
1145 relations: Optional[RelationType] = field(
1146 default=None,
1147 metadata={
1148 "type": "Element",
1149 }
1150 )
1152 @dataclass
1153 class Custom:
1154 other_element: List[object] = field(
1155 default_factory=list,
1156 metadata={
1157 "type": "Wildcard",
1158 "namespace": "##other",
1159 }
1160 )
1163@dataclass
1164class MetadataContainerType:
1165 """
1166 Container type that contains exactly one metadata record, complete with
1167 it's root element (tns:object)
1168 """
1169 class Meta:
1170 name = "metadataContainerType"
1172 object_value: Optional[Object] = field(
1173 default=None,
1174 metadata={
1175 "name": "object",
1176 "type": "Element",
1177 "namespace": "http://textgrid.info/namespaces/metadata/core/2010",
1178 "required": True,
1179 }
1180 )
1183@dataclass
1184class TgObjectMetadata(MetadataContainerType):
1185 """
1186 Element for the container type.
1187 """
1188 class Meta:
1189 name = "tgObjectMetadata"
1190 namespace = "http://textgrid.info/namespaces/metadata/core/2010"