#NEWLINE# def locatorOf( self , dereferencedObject ) : #NEWLINE# #INDENT# '(ModelLocator) -- Value of locator surrogate of relationship target, if any' #NEWLINE# fromLocator = self . fromLocator #NEWLINE# if ( ( fromLocator is not None ) and ( fromLocator . dereference ( ) == dereferencedObject ) ) : #NEWLINE# #INDENT# return fromLocator #NEWLINE# #UNINDENT# toLocator = self . toLocator #NEWLINE# if ( ( toLocator is not None ) and ( toLocator . dereference ( ) == dereferencedObject ) ) : #NEWLINE# #INDENT# return dereferencedObject #NEWLINE# #UNINDENT# return None