@@ -146,7 +146,7 @@ def _getValue(self):
146146 Return the value of the attribute or the linked attribute value.
147147 """
148148 if self .isLink :
149- return self ._getDirectInputLink ().value
149+ return self ._getInputLink ().value
150150 return self ._value
151151
152152 def _setValue (self , value ):
@@ -234,7 +234,7 @@ def getSerializedValue(self):
234234 Get the attribute value serialized.
235235 """
236236 if self .isLink :
237- return self ._getDirectInputLink ().asLinkExpr ()
237+ return self ._getInputLink ().asLinkExpr ()
238238 if self .isOutput and self ._desc .isExpression :
239239 return self .getDefaultValue ()
240240 return self .value
@@ -327,7 +327,7 @@ def uid(self) -> str:
327327 strippedInvalidationValue = self ._invalidationValue .rstrip ("/" )
328328 return hashValue (strippedInvalidationValue )
329329 if self .isLink :
330- linkRootAttribute = self ._getDirectInputLink (recursive = True )
330+ linkRootAttribute = self ._getInputLink (recursive = True )
331331 return linkRootAttribute .uid ()
332332 if isinstance (self ._value , (list , tuple , set ,)):
333333 # non-exclusive choice param
@@ -364,7 +364,7 @@ def _isLink(self) -> bool:
364364 return self .node .graph and self .isInput and self .node .graph ._edges and \
365365 self in self .node .graph ._edges .keys ()
366366
367- def _getDirectInputLink (self , recursive = False ) -> "Attribute" :
367+ def _getInputLink (self , recursive = False ) -> "Attribute" :
368368 """
369369 Return the direct upstream connected attribute.
370370 :param recursive: recursive call, return the root attribute
@@ -373,7 +373,7 @@ def _getDirectInputLink(self, recursive=False) -> "Attribute":
373373 return None
374374 linkAttribute = self .node .graph .edge (self ).src
375375 if recursive and linkAttribute .isLink :
376- return linkAttribute ._getDirectInputLink (recursive )
376+ return linkAttribute ._getInputLink (recursive )
377377 return linkAttribute
378378
379379 def _getDirectOutputLinks (self ) -> list ["Attribute" ]:
@@ -389,7 +389,7 @@ def _getAllInputLinks(self) -> list["Attribute"]:
389389 """
390390 Return the list of upstream connected attributes for the attribute or any of its elements.
391391 """
392- inputLink = self ._getDirectInputLink ()
392+ inputLink = self ._getInputLink ()
393393 if inputLink is None :
394394 return []
395395 return [inputLink ]
@@ -481,9 +481,9 @@ def matchText(self, text: str) -> bool:
481481 # Whether the attribute is a direct link to another attribute.
482482 isLink = Property (bool , _isLink , notify = inputLinksChanged )
483483 # The direct upstream connected root attribute.
484- inputRootLink = Property (Variant , lambda self : self ._getDirectInputLink (recursive = True ), notify = inputLinksChanged )
484+ inputRootLink = Property (Variant , lambda self : self ._getInputLink (recursive = True ), notify = inputLinksChanged )
485485 # The direct upstream connected attribute.
486- inputLink = Property (BaseObject , _getDirectInputLink , notify = inputLinksChanged )
486+ inputLink = Property (BaseObject , _getInputLink , notify = inputLinksChanged )
487487 # The list of direct downstream connected attributes.
488488 outputLinks = Property (Variant , _getDirectOutputLinks , notify = outputLinksChanged )
489489 # The list of upstream connected attributes for the attribute or any of its elements.
@@ -528,7 +528,7 @@ def __len__(self):
528528 return len (self .getValues ())
529529
530530 def getValues (self ):
531- if (linkParam := self ._getDirectInputLink ()) is not None :
531+ if (linkParam := self ._getInputLink ()) is not None :
532532 return linkParam .getValues ()
533533 return self ._values if self ._values is not None else self ._desc ._values
534534
@@ -685,7 +685,7 @@ def getDefaultValue(self) -> list:
685685 # Override
686686 def getSerializedValue (self ):
687687 if self .isLink :
688- return self ._getDirectInputLink ().asLinkExpr ()
688+ return self ._getInputLink ().asLinkExpr ()
689689 return [attr .getSerializedValue () for attr in self ._value ]
690690
691691 # Override
0 commit comments