Table of Contents

Open all
Close all
Introduction
21
1 Getting Started
29
1.1 Foundations for Web Dynpro
30
1.1.1 HTTP and the World Wide Web
30
1.1.2 Evolution of Web Programming Models
33
1.2 A Model-Based Approach to UI Development
41
1.2.1 Understanding the Web Dynpro Framework
42
1.2.2 The Benefits of a Model-Driven Architecture
44
1.3 Technical Integration Concepts
47
1.3.1 Legacy Web and UI Technologies
47
1.3.2 Internet Communication Manager
50
1.3.3 Internet Communication Framework
52
1.3.4 The Web Dynpro Runtime Environment
57
1.3.5 System Requirements
59
1.4 Summary
59
2 The Anatomy of WDA Applications
61
2.1 Component-Based Software Development Concepts
61
2.1.1 Componentization Overview
62
2.1.2 Characteristics of Software Components
63
2.1.3 Understanding the Positioning of Web Dynpro Components
64
2.2 Web Dynpro Components
65
2.2.1 Architectural Overview
65
2.2.2 Views
67
2.2.3 Windows
69
2.2.4 Controllers
73
2.2.5 Context and Binding Concepts
77
2.3 Web Dynpro Applications
85
2.4 Summary
88
3 Developing Your First WDA Application
89
3.1 Requirements Overview
89
3.2 Getting Started with the Web Dynpro Explorer
91
3.2.1 Working with the ABAP Repository
92
3.2.2 Package Organization Concepts
93
3.3 Creating a WDA Component
97
3.3.1 Defining the Component
97
3.3.2 Modeling the Application Data
99
3.3.3 Implementing the Lookup Method
102
3.3.4 Laying Out the Selection View
105
3.3.5 Laying Out the Details View
110
3.3.6 Window Organization and Navigation Links
113
3.3.7 Defining Actions and Event Handler Methods
116
3.3.8 Input Validation and Messaging
119
3.4 Creating and Testing the WDA Application
121
3.5 Summary
126
4 Controller Development
127
4.1 Controller Element Overview
127
4.1.1 Methods
128
4.1.2 Attributes
132
4.1.3 Contexts
134
4.1.4 Events
134
4.1.5 Actions
140
4.2 Working with Specific Controller Types
144
4.2.1 The Component Controller
144
4.2.2 Custom Controllers
149
4.2.3 View Controllers
152
4.2.4 Window Controllers
154
4.3 Controller Usages
157
4.3.1 Creating Controller Usages
158
4.3.2 Leveraging Used Controllers
159
4.3.3 Restrictions for Creating Controller Usages
159
4.4 Understanding the Web Dynpro Phase Model
160
4.4.1 Case Study: Tracing through the Web Dynpro Phase Model
161
4.4.2 Handling Actions and Events
163
4.5 Web Dynpro Programming Interface Overview
165
4.5.1 The Web Dynpro Runtime API
165
4.5.2 Service Classes and Interfaces
167
4.6 Assistance Classes
168
4.6.1 Creating an Assistance Class
168
4.6.2 Maintaining Assistance Classes
168
4.6.3 What Should Assistance Classes Be Used For?
170
4.7 Tool Support for Controller Development
171
4.7.1 Web Dynpro Code Wizard
172
4.7.2 Screen Design Time Conversion
173
4.7.3 Service Calls
176
4.7.4 Refactoring Assistant
177
4.8 Summary
178
5 Working with Contexts
179
5.1 Contexts: Revisited
179
5.1.1 What Is a Context?
180
5.1.2 Context Data Flow Concepts
180
5.1.3 The Building Blocks of a Context
182
5.1.4 Contexts at Runtime
183
5.2 Context Nodes and Context Attributes: Up Close
184
5.2.1 Properties of Context Nodes
184
5.2.2 Properties of Context Attributes
187
5.2.3 Understanding the Lead Selection Concept
188
5.2.4 Understanding the Singleton Property
189
5.3 Defining a Context
191
5.3.1 Defining Context Nodes
191
5.3.2 Defining Context Attributes
195
5.3.3 Recursion Nodes
197
5.4 Context Programming
202
5.4.1 Getting Started
202
5.4.2 Maneuvering within a Context
205
5.4.3 Filling a Context
212
5.4.4 Working with Context Attributes
217
5.4.5 Performing Housekeeping Duties within a Context
223
5.4.6 Working with the Context Change Log
225
5.4.7 Tool Support for Context Programming
227
5.5 Supply Functions
228
5.5.1 Creating a Supply Function
228
5.5.2 Implementing Supply Functions
229
5.5.3 Understanding How Supply Functions Are Invoked
230
5.5.4 Supply Functions and Singleton Nodes
231
5.6 Context Mapping and Data Binding: Up Close
232
5.6.1 How Context Mapping Works
232
5.6.2 How Data Binding Works
233
5.7 Summary
235
6 Windows and Views
237
6.1 Windows
238
6.1.1 Windows as a View Container
238
6.1.2 Interface Views
247
6.1.3 Dialog Boxes and Popup Windows
252
6.2 Views
259
6.2.1 Views: Revisited
259
6.2.2 Working with Layout Elements
262
6.2.3 Working with Container Layouts
272
6.3 Navigation Concepts
281
6.3.1 Navigation between Views
281
6.3.2 Working with Window Plugs
289
6.3.3 Case Study: Dynamically Selecting the Initial View for a Window
292
6.3.4 Case Study: Closing WDA Applications
297
6.3.5 Case Study: Suspend and Resume Calls
299
6.4 Summary
306
7 Basic UI Elements
307
7.1 Introduction to UI Elements
307
7.1.1 Basic Concepts
308
7.1.2 Runtime Classes
310
7.1.3 UI Element Categories
312
7.2 UI Elements from the Text Category
313
7.2.1 UI Element Overview
313
7.2.2 Building Input Forms Using Label and InputField
315
7.2.3 Displaying Plain Text Using TextView
323
7.2.4 Editing Plain Text with TextEdit
323
7.2.5 Displaying Formatted Text using FormattedTextView
325
7.2.6 Editing Formatted Text with FormattedTextEdit
328
7.3 UI Elements from the Action Category
329
7.3.1 UI Element Overview
330
7.3.2 Basic Concepts
331
7.3.3 Working with Menus
332
7.3.4 Grouping Action Elements with the ToolBar Element
335
7.4 UI Elements from the Selection Category
336
7.4.1 UI Element Overview
337
7.4.2 Working with Dropdown Lists
340
7.4.3 Working with Radio Buttons
345
7.5 Summary
346
8 Advanced UI Elements
347
8.1 UI Elements from the Graphic Category
347
8.1.1 UI Element Overview
348
8.1.2 Displaying Images with the Image Element
350
8.1.3 Working with the ThresholdSlider Element
355
8.2 UI Elements from the Integration Category
358
8.2.1 UI Element Overview
358
8.2.2 Uploading and Downloading Files
360
8.2.3 Integrating PDF Forms with the InteractiveForm Element
364
8.3 UI Elements from the Complex Category
366
8.3.1 UI Element Overview
366
8.3.2 Displaying Tabluar Data with the Table Element
374
8.3.3 Visualizing Hierarchical Data with the Tree Element
392
8.3.4 Working with the RoadMap Element
404
8.4 Drag and Drop
409
8.4.1 Conceptual Overview
409
8.4.2 The Mechanics of Drag and Drop
412
8.4.3 Case Study: Defining a Drag-and-Drop Scenario
415
8.5 Summary
420
9 Component-Based Development Concepts
421
9.1 Web Dynpro Component Interfaces: Revisited
422
9.1.1 Component Interface Overview
423
9.1.2 Defining the Interface Controller
424
9.1.3 Configuring Interface Views
428
9.1.4 Defining Standalone Web Dynpro Component Interfaces
430
9.2 Component Usage Concepts
434
9.2.1 Defining Component Usages
434
9.2.2 Instantiating Used Components
436
9.2.3 Accessing Services of the Interface Controller
439
9.2.4 Cross-Component Context Mapping
441
9.2.5 Defining Cross-Component Navigation Scenarios
446
9.3 Case Study: Working with Faceless Components
449
9.4 Case Study: Working with the SAP List Viewer
452
9.4.1 Integrating ALV Content into the View Layout
452
9.4.2 Accessing the ALV Configuration Model
455
9.4.3 Event Handling Concepts
458
9.5 Guidelines for Applying Multi-Component Designs
462
9.6 Summary
465
10 User Interaction
467
10.1 Defining Input Helps
467
10.1.1 ABAP Dictionary Search Helps
468
10.1.2 OVS Value Helps
477
10.1.3 Freely Programmed Input Helps
482
10.1.4 Select Options
487
10.1.5 Suggested Values for Input Fields
497
10.2 Providing Help Texts
498
10.2.1 Working with the Explanation UI Element
498
10.2.2 Explanation Property for UI Elements
500
10.2.3 Integrating Classic F1 Help from the ABAP Dictionary
501
10.3 Confirmation Dialog Boxes
503
10.4 Displaying Messages
505
10.4.1 Creating Messages with the Message Manager
506
10.4.2 Automatic Message Generation
513
10.4.3 Customizing the Message Area
515
10.5 Summary
518
11 Dynamic Programming
519
11.1 Manipulating the Context
519
11.1.1 Working with the IF_WD_CONTEXT_NODE_INFO Interface
520
11.1.2 Adding Context Nodes to the Node Hierarchy
522
11.1.3 Adding Context Attributes to a Context Node
527
11.1.4 Dynamic Context Programming Dos and Don’ts
528
11.2 Modifying the View Layout at Runtime
528
11.2.1 Getting Started with the WDDOMODIFYVIEW( ) Hook Method
529
11.2.2 Navigating the Class Hierarchy for UI Elements
531
11.2.3 Adding UI Elements to the UI Element Hierarchy
533
11.2.4 Manipulating UI Elements Programmatically
536
11.2.5 Declarative Alternatives
538
11.3 Working with Dynamic Component Usages
539
11.3.1 Dynamically Creating Component Usages
539
11.3.2 Dynamically Embedding Interface Views
542
11.3.3 Calling Methods of the Interface Controller
546
11.3.4 Registering Event Handler Methods
547
11.3.5 Programming against Component Interfaces
548
11.4 Case Study: Creating a Data Browser Tool
552
11.4.1 Requirements Overview
552
11.4.2 Generating a Selection Screen Using Selection Options
554
11.4.3 Dynamic Context Manipulation
557
11.4.4 Generating the Results Screen
561
11.5 Summary
564
12 Configuration and Adaptation
565
12.1 The Adaptation Concept
566
12.1.1 Adaptation Layers
566
12.1.2 Adaptation Multiplicity and Processing
567
12.2 Component Configuration with the Configuration Editor
568
12.2.1 Accessing the Configuration Editor
568
12.2.2 Accessing the Customization Editor
569
12.2.3 Creating a Component Configuration
570
12.2.4 Configuring Component-Defined Properties
571
12.2.5 Configuring Built-In Properties
572
12.3 Application Configuration
572
12.3.1 Accessing the Application Configurator
573
12.3.2 Creating an Application Configuration
574
12.3.3 Assigning Component Configurations
574
12.3.4 Specifying Application Parameters
574
12.3.5 Assigning Application Configurations
575
12.4 Personalization and Customization
575
12.4.1 Personalizing Applications
576
12.4.2 Embedding Built-In Configuration Options in a Custom Personalization Dialog
576
12.4.3 Customizing Applications
577
12.4.4 Deactivating Customization and Personalization
578
12.4.5 Managing Personalization and Customization Data
579
12.5 Component-Defined Adaptation
579
12.5.1 Configuration Controllers
580
12.5.2 Component-Defined Adaptation Data
581
12.5.3 Mandating and Deactivating Component-Defined Configuration Data
582
12.6 Parameterization
583
12.6.1 Setting Parameters
583
12.6.2 Processing Parameters
584
12.6.3 Parameter Security
585
12.7 Accessibility
585
12.8 Style Sheets
586
12.8.1 WDA Integration with Themes
587
12.8.2 Integrating a Custom Theme into WDA
588
12.8.3 Setting a Global Theme for WDA
588
12.9 Internationalization and Translation
588
12.9.1 Static Texts
589
12.9.2 Dynamic Texts
590
12.9.3 Long Texts
591
12.10 Summary
591
13 Modifications and Enhancements
593
13.1 WDA Integration with the Enhancement Framework
593
13.1.1 Enhancement Spots
594
13.1.2 Enhancement Implementations
595
13.1.3 Creating an Enhancement Implementation
595
13.1.4 Switch Framework Integration
597
13.2 Enhancing Web Dynpro Components
597
13.2.1 Creating New Views
597
13.2.2 Enhancing Existing Views
598
13.2.3 Enhancing Controllers
600
13.2.4 Adding New Windows
602
13.2.5 Enhancing Existing Windows
602
13.2.6 Enhancing Components
603
13.3 Explicit Enhancements in Web Dynpro
603
13.3.1 Working with BAdIs
603
13.3.2 Working with Enhancement Options
604
13.4 Adjustments after an Upgrade
605
13.4.1 Types of Web Dynpro Conflicts
605
13.4.2 Making Adjustments to Your Enhancements
605
13.5 Summary
606
14 Working with the Floorplan Manager
607
14.1 Floorplan Architecture
608
14.1.1 Design of a Floorplan Manager Application
608
14.1.2 Implementation Architecture of a Floorplan Manager Application
609
14.1.3 Floorplan Components
610
14.1.4 User Interface Building Blocks
613
14.1.5 Floorplan Configuration Objects
614
14.2 Getting Started with Floorplans
615
14.2.1 Implementing a UIBB
615
14.2.2 Creating a Floorplan Application
615
14.2.3 Configuring a Floorplan Application
617
14.3 Working with the Configuration Editor
618
14.3.1 Accessing the Configuration Editor
619
14.3.2 Features of the Configuration Editor
620
14.3.3 Assigning a UIBB to the Page
621
14.4 Working with GUIBBs
622
14.5 Configuring Wires
623
14.6 Working with Dialog Boxes
624
14.6.1 Creating an FPM Dialog Box
624
14.6.2 Assigning a Dialog Box to a Toolbar Button
625
14.6.3 Calling Dialog Boxes Programmatically
626
14.7 Web Dynpro Page Builder
626
14.7.1 Creating Pages
627
14.7.2 Accessing the Page Builder
628
14.7.3 Creating Web Dynpro CHIPs
628
14.7.4 Adding a Side Panel to WDA Applications
630
14.8 Summary
632
15 WDA Integration
633
15.1 RIA Integration with Web Dynpro Islands
634
15.1.1 View Concepts in the Islands Framework
634
15.1.2 Data Transfer Concepts in the Islands Framework
635
15.1.3 Eventing Concepts in the Islands Framework
637
15.2 Adobe Flash Islands Integration
638
15.2.1 Preparing Adobe Flash Builder to Work with Web Dynpro
638
15.2.2 Integrating Flash Islands in Web Dynpro
639
15.2.3 Data Transfer
640
15.2.4 Event Integration
641
15.2.5 Theme Integration
641
15.2.6 Drag and Drop Integration
642
15.3 Microsoft Silverlight Islands Integration
642
15.3.1 Preparing Microsoft Visual Studio to Work with Web Dynpro
642
15.3.2 Integrating Silverlight Islands in Web Dynpro
643
15.3.3 Data Transfer
643
15.4 SAP Interactive Forms by Adobe Integration
644
15.4.1 Creating a New Form from Web Dynpro
645
15.4.2 Integrating Existing Forms
646
15.5 SAP NetWeaver Portal Integration
647
15.5.1 Preparing SAP NetWeaver Portal to Work with WDA
647
15.5.2 Creating Web Dynpro ABAP iViews
649
15.5.3 Portal Event Integration
650
15.5.4 Portal Navigation
650
15.6 Consuming Web Services in WDA
651
15.7 Summary
651
16 Security Concepts
653
16.1 System Logon
654
16.1.1 Customizing the Logon Screen for Your Applications
654
16.1.2 Logon Using SSO Tickets
656
16.1.3 Establishing a Single Sign-On Between Systems Using SSO Tickets
657
16.1.4 Logon Using an Identity Provider (IdP)
659
16.2 System Logoff and Error Pages
660
16.2.1 Application Logoff Page
660
16.2.2 Application Error Page
661
16.2.3 External Aliases
662
16.3 Authorizations
663
16.4 Application Data Security
665
16.5 Security of Context Data in a View
666
16.6 File Upload Security
666
16.7 Whitelist Infrastructure
667
16.8 Summary
668
17 Performance Tuning
669
17.1 Formulating an Approach
670
17.2 Best Practices and Design Tips
672
17.2.1 Separation of Concerns
672
17.2.2 Context Management
673
17.2.3 Managing Resources
674
17.2.4 Frontend Delegation
679
17.2.5 Compressing HTTP Transmissions
683
17.3 Performance Analysis Tools
684
17.3.1 Web Dynpro–Specific Monitoring Tools
685
17.3.2 ABAP Monitoring Tools
691
17.3.3 HTTP Monitoring Tools
695
17.4 Performance Tuning Checklist
700
17.5 Summary
700
Development Workbooks
701
W1 Displaying Basic Contact Information for a User
703
W1.1 Requirements Overview
703
W1.2 Design Approach
704
W1.2.1 Modeling the Application Data
704
W1.2.2 Defining the User Interface
705
W1.2.3 Event Handling
706
W1.3 Solution
707
W2 Creating a Fully Functional User Maintenance Application
709
W2.1 Requirements Overview
709
W2.2 Design Approach
713
W2.2.1 Building an Application Model
713
W2.2.2 Defining the Context
714
W2.2.3 Designing the User Interface
715
W2.2.4 Application Mode Handling
716
W2.3 Solution
717
W3 Showing User Role Assignments
719
W3.1 Requirements Overview
719
W3.2 Design Approach
719
W3.2.1 Defining the Context
720
W3.2.2 Configuring the Table Element
722
W3.2.3 Turning on Sorting and Filtering
722
W3.2.4 Defining the TablePopin
723
W3.3 Solution
723
W4 Developing a Custom User Report
725
W4.1 Requirements Overview
725
W4.2 Design Approach
727
W4.2.1 Defining the Component Architecture
727
W4.2.2 Constructing a Reusable Query Model
728
W4.2.3 Designing the User Interface
731
W4.2.4 Coordinating the Event Flow
731
W4.3 Solution
733
W5 Implementing Special Features
735
W5.1 Requirements Overview
735
W5.2 Design Approach
736
W5.2.1 Providing Input Help Support
736
W5.2.2 Defining Field-Level Validations
738
W5.2.3 Tracking Changes to User Records
740
W5.3 Solution
741
W6 Using Component-Based Development Techniques
743
W6.1 Requirements Overview
743
W6.2 Design Approach
744
W6.2.1 Designing an Airport Lookup Input Help
744
W6.2.2 Integrating the Used Components
746
W6.3 Solution
748
W7 Configuring an FPM Application
749
W7.1 Requirements Overview
749
W7.2 Design Approach
750
W7.2.1 Implementing a Feeder Class for the Search GUIBB
750
W7.2.2 Configuring the FPM Application
752
W7.2.3 Configuring the Search GUIBB Component
753
W7.2.4 Configuring the IDR Component
756
W7.3 Solution
756
W8 Integrating WDA with Flash
757
W8.1 Requirements Overview
757
W8.2 Design Approach
758
W8.2.1 Calling the WDA Event from the Flash Application
759
W8.2.2 Creating the FlashIsland View
759
W8.2.3 Handling the SUBMIT_FORM Event
760
W8.3 Solution
761
Appendices
763
A Debugging WDA Applications
765
A.1 Activating the ABAP Debugger Tool
765
A.2 Working with the Web Dynpro Debugger Tool
770
B The Authors
773
Index
775