First implementation of Debugger for SyaNodeParser
This commit is contained in:
@@ -565,3 +565,24 @@ class ToListConcept(Concept):
|
||||
self.set_value("recurse_on", recurse_on) # which sub items should we display
|
||||
self.set_value("tab", tab) # customise tab (content and length)
|
||||
self._metadata.is_evaluated = True
|
||||
|
||||
|
||||
class NewConceptConcept(Concept):
|
||||
ALL_ATTRIBUTES = ["concept"]
|
||||
|
||||
def __init__(self, concept=None):
|
||||
Concept.__init__(self,
|
||||
BuiltinConcepts.NEW_CONCEPT,
|
||||
True,
|
||||
False,
|
||||
BuiltinConcepts.NEW_CONCEPT,
|
||||
bound_body="concept")
|
||||
|
||||
self.set_value("concept", concept)
|
||||
self._metadata.is_evaluated = True
|
||||
|
||||
def __repr__(self):
|
||||
if self.concept:
|
||||
return f"NewConcept(concept={self.concept}, key='{self.concept.key}')"
|
||||
else:
|
||||
return super().__repr__()
|
||||
|
||||
Reference in New Issue
Block a user