0
Creating Web Parts with Connections
Agenda <ul><li>Previous Technology </li></ul><ul><li>Web Part Connections Concept </li></ul><ul><li>Connection Framework <...
Previous Technology <ul><li>Hardwired solutions </li></ul><ul><li>Parts need intimate knowledge of each other </li></ul><u...
Web Part Connections Concept
Connections Framework <ul><li>Allows Web Parts to send & receive basic types of data; e.g., Cell, Row, List, etc. </li></u...
Scenarios <ul><li>Master/Detail </li></ul><ul><li>Parent/Child </li></ul><ul><li>Data Entry and Filter </li></ul><ul><li>C...
Scenarios Master Detail
Scenarios Parent/Child
Scenarios Data Entry and Filtering
Scenarios Calculations
Scenarios Alternate Views
Scenarios Data Enhancement
Connecting Parts
Supported Interfaces <ul><li>ICellProvider, ICellConsumer  </li></ul><ul><li>IRowProvider, IRowConsumer  </li></ul><ul><li...
Interface Details Cell Scenario
Interface Details Cell Interfaces <ul><li>ICellProvider </li></ul><ul><ul><li>Events </li></ul></ul><ul><ul><ul><li>CellPr...
Interface Details Row Scenario
Interface Details Row Interfaces <ul><li>IRowProvider </li></ul><ul><ul><li>Events </li></ul></ul><ul><ul><ul><li>RowProvi...
Interface Details  List Scenario
Interface Details  List Interfaces <ul><li>IListProvider </li></ul><ul><ul><li>Events </li></ul></ul><ul><ul><ul><li>ListP...
Interface Details Filter Scenario
Interface Details Filter Interfaces <ul><li>IFilterProvider </li></ul><ul><ul><li>Events </li></ul></ul><ul><ul><ul><li>Se...
Interface Details ParamsOut Scenario
Interface Details ParamsOut Interfaces <ul><li>IParmetersOutProvider </li></ul><ul><ul><li>Events </li></ul></ul><ul><ul><...
Interface Details ParamsIn Scenario IParametersOutProvider IParametersInConsumer Transformer
Interface Details ParamsIn Interfaces <ul><li>IParmetersInProvider </li></ul><ul><ul><li>Events </li></ul></ul><ul><ul><ul...
Transformers Transformers allow different interfaces to be connected to one another. * Not supported for cross page connec...
Compatibility Interfaces Web Parts
Compatibility Rules   <ul><li>Reciprocal pairs or transformer exist </li></ul><ul><li>MaxConnections not exceeded </li></u...
Cross Page Connections Features <ul><li>Allow connecting parts on different pages </li></ul><ul><li>Can only be created in...
Cross Page Connections Supported Interfaces Supported cross page connections.  In some cases, a transformer is used. Sourc...
Connectable Microsoft Parts
Code Flow <ul><li>EnsureInterfaces() </li></ul><ul><ul><li>RegisterInterface() </li></ul></ul><ul><li>CanRunAt() </li></ul...
Creating Connectable Parts Code Walk Through
Questions?
Upcoming SlideShare
Loading in...5
×

Creating Web Parts With Connections Scott Ruble

908

Published on

Published in: Technology, Design
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
908
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
10
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide
  • Transcript of "Creating Web Parts With Connections Scott Ruble"

    1. 1. Creating Web Parts with Connections
    2. 2. Agenda <ul><li>Previous Technology </li></ul><ul><li>Web Part Connections Concept </li></ul><ul><li>Connection Framework </li></ul><ul><li>Scenarios </li></ul><ul><li>Connecting Parts Demo </li></ul><ul><li>Supported Interfaces </li></ul><ul><li>Interface Details </li></ul><ul><li>Compatibility </li></ul><ul><li>Cross Page Connections </li></ul><ul><li>Connectable Microsoft Web Parts </li></ul><ul><li>Code Flow </li></ul><ul><li>Code Walk Through Demo/Lab </li></ul>
    3. 3. Previous Technology <ul><li>Hardwired solutions </li></ul><ul><li>Parts need intimate knowledge of each other </li></ul><ul><ul><li>DDSC.RegisterForEvent, DDSC.RaiseEvent </li></ul></ul><ul><ul><li>Parameterized Hyperlinks </li></ul></ul><ul><li>Lack of flexibility </li></ul><ul><li>Developer-driven </li></ul>
    4. 4. Web Part Connections Concept
    5. 5. Connections Framework <ul><li>Allows Web Parts to send & receive basic types of data; e.g., Cell, Row, List, etc. </li></ul><ul><li>Uses standardized set of interfaces </li></ul><ul><li>Allows completely independent parts to connect </li></ul><ul><li>Enables end users to form connections </li></ul><ul><ul><li>Browser </li></ul></ul><ul><ul><li>FrontPage </li></ul></ul>
    6. 6. Scenarios <ul><li>Master/Detail </li></ul><ul><li>Parent/Child </li></ul><ul><li>Data Entry and Filter </li></ul><ul><li>Calculations </li></ul><ul><li>Alternate Views </li></ul><ul><li>Data Enhancement </li></ul>
    7. 7. Scenarios Master Detail
    8. 8. Scenarios Parent/Child
    9. 9. Scenarios Data Entry and Filtering
    10. 10. Scenarios Calculations
    11. 11. Scenarios Alternate Views
    12. 12. Scenarios Data Enhancement
    13. 13. Connecting Parts
    14. 14. Supported Interfaces <ul><li>ICellProvider, ICellConsumer </li></ul><ul><li>IRowProvider, IRowConsumer </li></ul><ul><li>IListProvider, IListConsumer </li></ul><ul><li>IFilterProvider, IFilterConsumer </li></ul><ul><li>IParametersOutProvider, IParametersOutConsumer </li></ul><ul><li>IParametersInProvider, IParametersInConsumer </li></ul>
    15. 15. Interface Details Cell Scenario
    16. 16. Interface Details Cell Interfaces <ul><li>ICellProvider </li></ul><ul><ul><li>Events </li></ul></ul><ul><ul><ul><li>CellProviderInit() </li></ul></ul></ul><ul><ul><ul><li>CellReady() </li></ul></ul></ul><ul><ul><li>Event Handlers </li></ul></ul><ul><ul><ul><li>CellConsumerInit() </li></ul></ul></ul><ul><li>ICellConsumer </li></ul><ul><ul><li>Events </li></ul></ul><ul><ul><ul><li>CellConsumerInit() </li></ul></ul></ul><ul><ul><li>Event Handlers </li></ul></ul><ul><ul><ul><li>CellProviderInit() </li></ul></ul></ul><ul><ul><ul><li>CellReady() </li></ul></ul></ul>
    17. 17. Interface Details Row Scenario
    18. 18. Interface Details Row Interfaces <ul><li>IRowProvider </li></ul><ul><ul><li>Events </li></ul></ul><ul><ul><ul><li>RowProviderInit() </li></ul></ul></ul><ul><ul><ul><li>RowReady() </li></ul></ul></ul><ul><ul><li>Event Handlers </li></ul></ul><ul><ul><ul><li>None </li></ul></ul></ul><ul><li>IRowConsumer </li></ul><ul><ul><li>Events </li></ul></ul><ul><ul><ul><li>None </li></ul></ul></ul><ul><ul><li>Event Handlers </li></ul></ul><ul><ul><ul><li>RowProviderInit() </li></ul></ul></ul><ul><ul><ul><li>RowReady() </li></ul></ul></ul>
    19. 19. Interface Details List Scenario
    20. 20. Interface Details List Interfaces <ul><li>IListProvider </li></ul><ul><ul><li>Events </li></ul></ul><ul><ul><ul><li>ListProviderInit() </li></ul></ul></ul><ul><ul><ul><li>ListReady() </li></ul></ul></ul><ul><ul><ul><li>PartialListReady() </li></ul></ul></ul><ul><ul><li>Event Handlers </li></ul></ul><ul><ul><ul><li>None </li></ul></ul></ul><ul><li>IListConsumer </li></ul><ul><ul><li>Events </li></ul></ul><ul><ul><ul><li>None </li></ul></ul></ul><ul><ul><li>Event Handlers </li></ul></ul><ul><ul><ul><li>ListProviderInit() </li></ul></ul></ul><ul><ul><ul><li>ListReady() </li></ul></ul></ul><ul><ul><ul><li>PartialListReady() </li></ul></ul></ul>
    21. 21. Interface Details Filter Scenario
    22. 22. Interface Details Filter Interfaces <ul><li>IFilterProvider </li></ul><ul><ul><li>Events </li></ul></ul><ul><ul><ul><li>SetFilter() </li></ul></ul></ul><ul><ul><ul><li>ClearFilter() </li></ul></ul></ul><ul><ul><ul><li>NoFilter() </li></ul></ul></ul><ul><ul><li>Event Handlers </li></ul></ul><ul><ul><ul><li>FilterConsumerInit() </li></ul></ul></ul><ul><li>IFilterConsumer </li></ul><ul><ul><li>Events </li></ul></ul><ul><ul><ul><li>FilterConsumerInit() </li></ul></ul></ul><ul><ul><li>Event Handlers </li></ul></ul><ul><ul><ul><li>SetFilter() </li></ul></ul></ul><ul><ul><ul><li>ClearFilter() </li></ul></ul></ul><ul><ul><ul><li>NoFilter() </li></ul></ul></ul>
    23. 23. Interface Details ParamsOut Scenario
    24. 24. Interface Details ParamsOut Interfaces <ul><li>IParmetersOutProvider </li></ul><ul><ul><li>Events </li></ul></ul><ul><ul><ul><li>ParametersOutProviderInit() </li></ul></ul></ul><ul><ul><ul><li>ParametersOutReady() </li></ul></ul></ul><ul><ul><li>Event Handlers </li></ul></ul><ul><ul><ul><li>None </li></ul></ul></ul><ul><li>IParametersOutConsumer </li></ul><ul><ul><li>Events </li></ul></ul><ul><ul><ul><li>None </li></ul></ul></ul><ul><ul><li>Event Handlers </li></ul></ul><ul><ul><ul><li>ParametersOutProviderInit() </li></ul></ul></ul><ul><ul><ul><li>ParametersOutReady() </li></ul></ul></ul>
    25. 25. Interface Details ParamsIn Scenario IParametersOutProvider IParametersInConsumer Transformer
    26. 26. Interface Details ParamsIn Interfaces <ul><li>IParmetersInProvider </li></ul><ul><ul><li>Events </li></ul></ul><ul><ul><ul><li>ParametersInReady() </li></ul></ul></ul><ul><ul><li>Event Handlers </li></ul></ul><ul><ul><ul><li>ParametersInConsumerInit() </li></ul></ul></ul><ul><li>IParametersInConsumer </li></ul><ul><ul><li>Events </li></ul></ul><ul><ul><ul><li>ParametersInConsumerInit() </li></ul></ul></ul><ul><ul><li>Event Handlers </li></ul></ul><ul><ul><ul><li>ParametersInReady() </li></ul></ul></ul>
    27. 27. Transformers Transformers allow different interfaces to be connected to one another. * Not supported for cross page connections. Transformer Connectable in Browser Connectable in FrontPage IRowProvider to ICellConsumer * Yes Yes IRowProvider to IFilterConsumer Yes Yes IParametersOutProvider to IParametersInConsumer No Yes IRowProvider to IParametersInConsumer No Yes
    28. 28. Compatibility Interfaces Web Parts
    29. 29. Compatibility Rules <ul><li>Reciprocal pairs or transformer exist </li></ul><ul><li>MaxConnections not exceeded </li></ul><ul><li>RunAt matches </li></ul><ul><li>Connect over only one interface </li></ul><ul><li>No circular connections </li></ul>
    30. 30. Cross Page Connections Features <ul><li>Allow connecting parts on different pages </li></ul><ul><li>Can only be created in FrontPage </li></ul><ul><li>Certain interfaces supported </li></ul>Page 1 (Source) Page 2 (Target)
    31. 31. Cross Page Connections Supported Interfaces Supported cross page connections. In some cases, a transformer is used. Source Page Interface Target Page Interface IRowProvider IFilterConsumer IRowProvider IParametersInConsumer IFilterProvider IFilterConsumer IParametersOutProvider IParametersInConsumer IParametersInProvider IParametersInConsumer
    32. 32. Connectable Microsoft Parts
    33. 33. Code Flow <ul><li>EnsureInterfaces() </li></ul><ul><ul><li>RegisterInterface() </li></ul></ul><ul><li>CanRunAt() </li></ul><ul><li>PartCommunicationConnect() </li></ul><ul><li>PartCommunicationInit() </li></ul><ul><ul><li>Fire Init Events; e.g., CellProviderInit() </li></ul></ul><ul><li>PartCommunicationMain() </li></ul><ul><ul><li>Fire Remaining Events; e.g., CellReady() </li></ul></ul><ul><li>GetInitEventArgs()* </li></ul>*Only needed for interfaces that require transformers.
    34. 34. Creating Connectable Parts Code Walk Through
    35. 35. Questions?
    1. A particular slide catching your eye?

      Clipping is a handy way to collect important slides you want to go back to later.

    ×