OntologyClass
What it is
- A thin subclass of
naas_abi.ontologies.modules.NexusPlatformOntology.OntologyClass. - Provides an
actions()hook intended to be implemented with custom logic.
Public API
class OntologyClass(_OntologyClass)- Inherits all behavior from the base
OntologyClassinNexusPlatformOntology. actions(self)- Placeholder method for action logic.
- Currently does nothing (
pass).
- Inherits all behavior from the base
Configuration/Dependencies
- Depends on:
naas_abi.ontologies.modules.NexusPlatformOntology.OntologyClass(imported as_OntologyClass).
Usage
from naas_abi.ontologies.classes.ontology_naas_ai.nexus.OntologyClass import OntologyClass
class MyOntologyClass(OntologyClass):
def actions(self):
# implement your logic here
return "ok"
obj = MyOntologyClass()
print(obj.actions())
Caveats
actions()is not implemented in this class and will returnNoneunless overridden.