UpdateSourceSelectionModule
     (Type newType,
     ComplexSelectionEditorModule <CordCircuit> SelectionModule)
 {
     if (!SelectionModule.IsInitialised)
     {
         SelectionModule.Initialise(OnCordCircuitSourceEntryUpdate);
     }
     SelectionModule.ProvideTypeForMethodsToBeInvokedUpon(newType);
 }
 UpdateTargetSelectionModule
     (UnityEngine.Object newObject,
     ComplexSelectionEditorModule <CordCircuit> SelectionModule)
 {
     if (!SelectionModule.IsInitialised)
     {
         SelectionModule.Initialise(OnCordCircuitTargetEntryUpdate);
     }
     SelectionModule.ProvideObjectForMethodsToBeInvokedUpon(newObject);
 }
        RenderComplexSelectionAndGenerateNewSelectionName
            (CordCircuit circuit,
            ComplexSelectionEditorModule <CordCircuit> selectionModule,
            string previousSelectionName,
            string labelString,
            Rect position)
        {
            // RetrieveEntrysMemberSelection rebuilds SelectionNames
            // as a side-effect, so must be done first
            int Selection
                = selectionModule.RetrieveEntrysMemberSelection(
                      circuit,
                      previousSelectionName
                      );


            string[] MemberNames = selectionModule.SelectionNames.ToArray();
            int      NewSelection
                = EditorGUI.Popup(
                      position,
                      labelString,
                      Selection,
                      MemberNames
                      );

            if (Selection != NewSelection)
            {
                //Debug.Log("Selection changed to " + NewSelection
                //        + " from " + Selection);
                selectionModule.SetMemberSelection(circuit, NewSelection);
            }

            if (selectionModule.SelectionNames != null &&
                selectionModule.SelectionNames.Count > 0)
            {
                return(selectionModule.SelectionNames[NewSelection]);
            }
            else
            {
                return(null);
            }
        }