ReSharper Web Help

With ReSharper, you can quickly delegate execution to members provided by fields or properties - in other words, publish the whole interface of a field or property, or a part of it, through containing type interface.

To generate delegating members
  1. In the editor, position the caret within a class where you'd like to generate delegating members.
  2. On the main menu, choose ReSharper | Edit | Generate Code, or press Alt+Insert.
  3. From the Generate pop-up menu, select Delegating members.
  4. On the Delegate to fields' members page of the Generate wizard, there's a list of private properties and fields in the current class, and members of types that they belong to. Select some or all of these type members, and ReSharper will generate wrappers in the current class that delegate execution to selected type members.
    Generate Delegating Members
  5. As an option, select Copy XML documentation to copy documentation from all members that execution is being delegated to.
  6. Do one of the following:
    • To configure XML documentation options individually for specific members, click Advanced. After finishing this step, click Next.
    • Click Finish to complete the wizard. For example, if the set of members shown above is selected, ReSharper generates the following wrappers:
      Generate Delegating Members

See Also