Home > Net >  C # plug-in architecture development
C # plug-in architecture development

Time:09-19

Assume that there are five ways of my main program (return value), the open several method to the plugin, what should the plug-in call?
Main function through interfaces can invoke the plug-in interface function, the assignment can be defined?

CodePudding user response:

In general are the main program interface, plug-in inherited and implementation, call interface methods of the main program, you can call the plug-in method
Or commissioned by the main program interface definition, commissioned by the main program calls, plug-in inherited the main program interface, realize this delegate, commissioned by the main program calls will enter plug-in method

CodePudding user response:

refer to kill matt, bull reply: 3/f
in general are the main program interface, plug-in inherited and implementation, call interface methods of the main program, you can call the plug-in method
Or commissioned by the main program interface definition, commissioned by the main program calls, plug-in inherited the main program interface, realize this delegate, commissioned by the main program calls into plug-in method when the


Yes, as you said has done is really in the interface defines a delegate event in the main program after binding realized the function of this
thank you
  •  Tags:  
  • C #
  • Related