Skip to content

Commit

Permalink
adapter.http: rename occurances of AASReference to ModelReference
Browse files Browse the repository at this point in the history
  • Loading branch information
jkhsjdhjs committed Dec 11, 2023
1 parent 1581065 commit 53d79a5
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions basyx/aas/adapter/http.py
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ def json_list(cls, data: Union[str, bytes], expect_type: Type[T], stripped: bool
raise UnprocessableEntity(f"Expected a single object of type {expect_type.__name__}, got {parsed!r}!")
# TODO: the following is ugly, but necessary because references aren't self-identified objects
# in the json schema
# TODO: json deserialization will always create an AASReference[Submodel], xml deserialization determines
# TODO: json deserialization will always create an ModelReference[Submodel], xml deserialization determines
# that automatically
constructor: Optional[Callable[..., T]] = None
args = []
Expand Down Expand Up @@ -345,7 +345,7 @@ class Base64UrlJsonConverter(werkzeug.routing.UnicodeConverter):
def __init__(self, url_map, t: str):
super().__init__(url_map)
self.type: type
if t == "AASReference":
if t == "ModelReference":
self.type = model.ModelReference
else:
raise ValueError(f"invalid value t={t}")
Expand Down Expand Up @@ -430,7 +430,7 @@ def __init__(self, object_store: model.AbstractObjectStore):
Submount("/submodels", [
Rule("/", methods=["GET"], endpoint=self.get_aas_submodel_refs),
Rule("/", methods=["POST"], endpoint=self.post_aas_submodel_refs),
Rule("/<base64url_json(t=AASReference):submodel_ref>/", methods=["DELETE"],
Rule("/<base64url_json(t=ModelReference):submodel_ref>/", methods=["DELETE"],
endpoint=self.delete_aas_submodel_refs_specific)
])
])
Expand Down

0 comments on commit 53d79a5

Please sign in to comment.