forked from Botts-Innovative-Research/OSHConnect-Python
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsml.py
More file actions
51 lines (47 loc) · 2.07 KB
/
sml.py
File metadata and controls
51 lines (47 loc) · 2.07 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
from pydantic import BaseModel, HttpUrl, Field
class TypeOf(BaseModel):
"""
TypeOf is a resolvable reference to some other general process (that can be any type inheriting from AbstractProcess)
:param href: The URL of the referenced process
:param relationship: The relationship of the referenced process to the current process
:param media_type: The media type of the referenced process
:param href_lang: The language of the referenced process
:param title: The title of the referenced process
:param uid: The unique identifier of the referenced process
:param target_resource: The target resource of the referenced process
:param interface: The interface of the referenced process
"""
href: HttpUrl
relationship: str = Field(..., serialization_alias='rel')
media_type: str = Field(None, serialization_alias='type')
href_lang: str = Field(None, serialization_alias='hreflang')
title: str = Field(None)
uid: str = Field(None)
target_resource: str = Field(None, serialization_alias='rt')
interface: str = Field(None, serialization_alias='if')
class SMLAbstractProcess(BaseModel):
description: str = None
unique_id: str = Field(None, serialization_alias='uniqueID')
label: str = None
lang: str = None
keywords: list = None
identifiers: list = None
classifiers: list = None
valid_time: list = Field(None, serialization_alias='validTime')
security_constraints: list = Field(None, serialization_alias='securityConstraints')
legal_constraints: list = Field(None, serialization_alias='legalConstraints')
characteristics: list = None
capabilities: list = None
contacts: list = None
documents: list = None
history: list = None
definition: HttpUrl = None
type_of: TypeOf = Field(None, serialization_alias='typeOf')
configuration: HttpUrl = None
features_of_interest: list = Field(None, serialization_alias='featuresOfInterest')
inputs: list = None
outputs: list = None
parameters: list = None
modes: list = None
method: str = None
position: list = None