#NEWLINE# def _get_explicit_connections( self ) : #NEWLINE# #INDENT# '\n        Returns\n        -------\n        dict\n            Explicit connections in this `Group`, represented as a mapping\n            from the pathname of the target to the pathname of the source.\n        ' #NEWLINE# connections = { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } #NEWLINE# for sub in self . subgroups ( ) : #NEWLINE# #INDENT# connections . update ( sub . _get_explicit_connections ( ) ) #NEWLINE# #UNINDENT# to_abs_uname = self . _sysdata . to_abs_uname #NEWLINE# to_abs_pnames = self . _sysdata . to_abs_pnames #NEWLINE# for ( tgt , srcs ) in iteritems ( self . _src ) : #NEWLINE# #INDENT# for ( src , idxs ) in srcs : #NEWLINE# #INDENT# try : #NEWLINE# #INDENT# src_pathnames = [ to_abs_uname [ src ] ] #NEWLINE# #UNINDENT# except KeyError as error : #NEWLINE# #INDENT# try : #NEWLINE# #INDENT# src_pathnames = to_abs_pnames [ src ] #NEWLINE# #UNINDENT# except KeyError as error : #NEWLINE# #INDENT# raise NameError ( ( "Source '%s' cannot be connected to target '%s': '%s' does not exist." % ( src , tgt , src ) ) ) #NEWLINE# #UNINDENT# #UNINDENT# try : #NEWLINE# #INDENT# for tgt_pathname in to_abs_pnames [ tgt ] : #NEWLINE# #INDENT# for src_pathname in src_pathnames : #NEWLINE# #INDENT# connections . setdefault ( tgt_pathname , [ ] ) . append ( ( tgt_pathname , idxs ) ) #NEWLINE# #UNINDENT# #UNINDENT# #UNINDENT# except KeyError as error : #NEWLINE# #INDENT# try : #NEWLINE# #INDENT# to_abs_uname [ tgt ] #NEWLINE# #UNINDENT# except KeyError as error : #NEWLINE# #INDENT# raise NameError ( ( "Source '%s' cannot be connected to target '%s': '%s' does not exist." % ( src , tgt , tgt ) ) ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# raise NameError ( ( "Source '%s' cannot be connected to target '%s': Target must be a parameter but '%s' is an unknown." % ( src , tgt , tgt ) ) ) #NEWLINE# #UNINDENT# #UNINDENT# #UNINDENT# #UNINDENT# return connections