diff --git a/sbol_factory/sbol_factory.py b/sbol_factory/sbol_factory.py index f99cbfc..05db052 100644 --- a/sbol_factory/sbol_factory.py +++ b/sbol_factory/sbol_factory.py @@ -161,9 +161,14 @@ def __init__(self, *args, **kwargs): # print(kw, val, type(self.__dict__[kw])) # raise + def accept(self, visitor): + visitor_method = f'visit_{CLASS_NAME}'.lower() + getattr(visitor, visitor_method)(self) + # Instantiate metaclass attribute_dict = {} attribute_dict['__init__'] = __init__ + attribute_dict['accept'] = accept Class = type(CLASS_NAME, (globals()[SUPERCLASS_NAME],), attribute_dict) globals()[CLASS_NAME] = Class self.symbol_table[CLASS_NAME] = Class diff --git a/setup.py b/setup.py index 1b4ab34..29b49d0 100644 --- a/setup.py +++ b/setup.py @@ -6,9 +6,9 @@ setup(name='sbol_factory', description='Ontology-driven data modeling', - version='1.0a3', + version='1.0a4', install_requires=[ - 'sbol3==1.0a8', + 'sbol3==1.0a9', 'rdflib>=5.0.0', 'rdflib-jsonld>=0.5.0', 'sparqlwrapper>=1.8.5',