Enterprise Client Developer's Guide
Name of layout definitions: .jsp and .xml
Project structure of “Simple project”
Maven / Gradle Project Structure
Maven Spring Boot Project Structure
Project file of the Enterprise Client Toolset
Referencing special Values via Variables
Design time location of resources
Enforce your preferred style inside CaptainCasa toolset
Logging – Where do I find CaptainCasa logs?
Difference “JEE” vs. “Jakarta”
How Objects are created on Server Side
The “.AddressDetailUI.” Fragment
Resolution is done with every Request!
Viewing the Page outside the Toolset
Simple usage: beans are read from dispatcher's package
Combination of ccdispatcherinfo.xml files
Container – Row – Column Arrangement
Rules which apply to all Components
Flush Management (Component Level)
Flush Management (Container/Row Level)
Background Painting (BACKGROUND and BGPAINT)
Focus Management – Setting Focus to dedicated Component
GRIDLAYOUTPANE – Grid Layout Manager
FIXGRID, GRIDCOL, GRIDHEADER, GRIDFOOTER
...some more info about “Server side number of Items” versus “Client Side number of Items”
Column Sequence and Column Sizing
Persistence Management with FIXGRIDs
Definitions to add when using complex column layouts
Directly setting the Sort Status
Influencing the default Sorting
Implementing an own Sort Algorithm
Switching Off Multiple Column Sorting
Setting the Focus into Grid Line
Avoiding Line-Selection on Focus
Using the Columns Sequence Popup
Saving and Restoring a Grid's Runtime State
Interface IFIXGRIDPersistence2
Performance Optimization of Grids
+ Page Navigation / Combining Dialogs
Page Inclusion vs. Page Bean Inclusion
Page Bean Modularization - Example
IPageBean / PageBean Instances
The ROWPAGEBEANINCLUDE Component
The generically usable page bean...
Page Beans with Parent Content Areas
Defining corresponding Page Beans: the PARENTEXIT Component
Multiple PARENTEXIT Components
PARENTEXITDELEGATE - PARENTEXIT across multiple Page Bean levels
Defining own layout definition
Updating the parent's layout definition - IPageModifier
Updating the parent's layout definition - *.mod.xml definition
Value Selection Popup with COMBOFIELD
Event Reaction on MENUITEM Level
Event Reaction on Component Level
Finding the right POPUPMENU...
Dynamic Properties – Dynamic Bean Browser
...with set/get-based properties
Existing property value's class is used
Interface IPropertyTypeResolver
Default implementation for Map implementing IPropertyTypeResolver
Property Binding within Grid Processing
Adapter Binding with Annotations
Base class ComponentAdapterByAnnotation
Base class ComponentAdapterByAnnotationForBeanProperty
Registration of component that uses adapter binding
Using “lazy loading” in Map-implementations
Extending the available “Simple Data Types”
Implementing “ISimpleDataTypeExtension”
Registering your implementation
Additional Functions on top of JSF
Consequences for Implementation
Customizing the Server Side Error Screen
Best Practice: Checking if your whole Application is available
Interface IPropertyResolverAware
Interface IPropertyResolverAware2
Interface IPropertyValueConverter
Interface IValueBindingListener
Class CascadingValueBindingListener
Starting Runnables to be executed in a certain Phase
Controls for defining date/time values
Internal data transfer to/from the controls – Long value + Time zone
Binding to Java date/time values
Not taking care of the time zone – Pay attention! (!!!)
Use LocalDate/LocalDateTime everywhere
Use java.util.Date and tim zone UTC (or equivalent: GMT) everywhere
Use java.util.Date and explicit time-zones which are centrally defined per user session
Way 1: Session Management by URL-encoding
Way 2: Session Management by COOKIEs
Storing data in session context
Accessing the dialog-session - explicit
Accessing dialog-session – the best, recommended way
What information to store in which type of session
Best practices when storing data in http-/dialog-session
Default: Sessions are automatically closed when closing/leaving the dialog
Default: Sessions are timed out
Changing the default – no automatic closing
Changing the default - Control SESSIONCLOSER
Scenarios in which sessions should NOT be timed out when being shown in the user's browser
Reacting on invalidation of session
Reacting on closing of current dialog session
Reacting on closing the session - http-session
Reacting on closing the session – Dispatcher level
For “Way 1” (URL) users – What to do
Especially: check your invalidate() calls!
Check your webcontent/META-INF/context.xml file
Which way should be your standard way?
API Facade “HttpSessionAccess”
Thread assignment during request-/response-processing
CaptainCasa thread synchronization by dialog session
As developer you do not have to care on multi-threading
Separation of one project into sub-projects
Integration within CaptainCasa Toolset
ROWFLEXLINECONTAINER – A Row with Line Breaks
ROWFLEXCOLUMNCONTAINER – the “rotated” ROWFLEXLINECONTAINER
ROWADAPTIVEAREA – One container, multiple ways of arranging its content
Some remarks on passing XML versus passing ComponentNode-instances
Using “concrete Classes” for assembling ComponentNode Instances
Concatenated calling of set-methods
Binding dynamically generated components to Java processing
By expressions - “traditional”
Creating expressions: the pbx() method
By direct binding - “more efficient”
Direct Binding of complex Object Instances
Direct Binding of simple Object Instances
When to use “set...” and when to use “bind...” for simple Attributes
+ Style Management – Outsourcing style information
Two Levels of Style Management
Where the look and feel should be defined...
Editing the style in the style editor
Details on the .xml based CSS definition
Nested style class definitions
Details on Style Definition Files (Component-Attribute Level, style.xml)
Defining Styles that extend other Styles
Defining Tag Variants referring to other Tag Definitions
Expressions as Style Attribute Values
Refreshing the Browser when updating Styles
“style” values in the style definition
“risc” values in the style definition
Image definitions in the Control Variants (style.xml)
Defining and Accessing Style Values
Defining central “Style Values”
Referencing from Page Definition
+ Style Management – Styling Issues
Image sizing as part of the name
Providing images in the webcontent - or in some Java package
Defining image names with reference to style variables
Dynamically sizing and coloring flat SVG icons
Deriving the color (and/or size) from style
Client Locale <==> Server Locale Settings
Client Side Internationalization
Automatic selection of Client Language and Country Settings
Update the Client Settings from Server Side
Where the client looks for languages/countries
Adding own language/country definitions
Server-side (Application-side) Internationalization
Accessing Literal Translations - Basics
The default way: using built in Resource Management
Synchronizing Client Side Locale and Server Side Locale Settings
Scenario: Client Settings dominate Server Settings
The Dispatcher in the Workplace Context
Addressing the correct Dispatcher
Accessing the Workplace Environment from your Bean
Using the Dispatcher as Context – or as bridge to your Context
Special Usage - Starting Functions
Workpage Life Cycle Aspects – Closing of a Workpage
Workpage Lifecycle Aspects – Additional Information
Addon Components in the Workplace Management
Workplace Perspective Management
What the Workplace Perspective Management does
Configuring multiple Perspectives for multiple Users
Switching between different Perspectives
Loading the Workplace Perspective when changing the User
Workplace Perspective – Low Level API
Workplace Functions Management
Creation of Page to hold Function Tree(s)
API-facade “MultiWorkplaceConnector”
Creating a “reduced workplace”
Developing an own work page selector
Macro Definition by Class Implementation
Pay Attention when processing Grid Cells
Macros within the Grid Processing (FIXGRID)
“Default Macros” - Macros that are always applied
Example – Automated generation of CLIENTNAME values
Default macros do not need to be referenced by control definitions!
Basic Idea – One self-containing JAR File
Developing a Page Bean Component – By Example
The Configuration File (optional)
Providing Meta Information (optional)
Providing Meta Information – old way...
Packaging and Delivering a Page Bean Component
Managing Page Bean Components within the Layout Editor
Previous versions: include the package in the dispatcherinfo.xml
Creating the Layout of Page Bean Components
Information for users of version earlier than 20200827
Storing resources in the Java-classes
Automatically saving the “.xml”-layout within the Layout Editor
Including Resources (Images, …)
Adapting the Page Bean Component Management to >= 20200827
Extending Page Bean Components
Changing the literals of a page bean component “from outside”
+ Server-side Events, long Server-side Operations
Default: Request-Response driven Communication
Sending interim status information to client
Requirement for enhanced Communication
Pay Attention – Thread-Complexity, JEE Rules...
Constant Polling – The TIMER way
Long Polling – True, synchronous Event Coupling
Traditional Long Polling – Keeping one connection open
Long Polling – The “Web socket way”
Which LONGPOLLING way to choose?
Traditional Polling or WebSocket based Polling - Use UNIFIEDPOLLING and decide at runtime!
Dialog Message Bus - Usage within one browser instance
Loose coupling vs. tight coupling
Dialog Message Bus - Usage within one client instance
A complex case... - Messaging between browser instances on same client, but distributed in cluster
Hot UI Deployment Framework Details
Details: Configuration of Runtime
Details: Configuration of your Project
Details: What internally happens
Embedding “other” classes/libraries for Hot Deployment
Using environment/system variables
Accessing “Hot deployed classes” from “WEB-INF/classes”
Solution 1 – Move all your logic packages “up”
Solution 2 – Define some interface in between
Triggering Update of Hot Deployment Classloader
Hot Deployment via CaptainCasa Toolset
Hot Deployment from “outside” by updating a file (e.g. via ANT-script)
Hot Deployment from “outside” by URL
Receiving notifications on hot deployment
Using Spring with Hot Deployment
Prepares Maven- / Gradle- project types
Usage of https is mandatory for production systems!
Define the pages that you want to be directly start-able
General protection of “session-id hijacking”
“Session-id hijacking” by man in the middle
“Remote address” based protection of “session-id hijacking”
“Session-id hijacking” by browser access
Protection of session-related data access by post-parameter
Fine-tuning the SecurityFilter
Example for implementing a SecurityFilter.IExtension class
Avoiding the Replaying of http - CLIENTSECID
Embedding as IFRAME into other pages
Resource Access by Class Loader
Controlling values being sent and received – Interface “ICheckInboundAndOutboundValues”
Restricted access via Java API
Restricted access via system.xml
Image Management – Accessing external images
Error information sent to the client – Filter “ErrorAnonymizerFilter”
Cache control – Filter “NoCacheNoStoreFilter” and “CacheFilter”
Filter “HttpHeaderAttributesForPagesFilter”, Security-related response header-parameters
Add logic to initialize your application
Technical configuration of web application
CaptainCasa – Started with web.xml, moved over to API
Possibility to configure filters and servlets in system.xml
Possibility to override CCInitializeServlets
web.xml and API definitions in co-existence
Spring Boot usage? - Extend CCInitializeServlets!
You want to extend the usage of CaptainCasa filter/servlet to new mappings
You want to add some new own filter
Extended information for screen readers
HTML-”title” and HTML-”aria-label” attributes
Start client with extension “ccexttitles=true”
Defining the information – Attribute ACCESSIBLENAME
+ Logging
Server-side logging - Activity log (“log_eclntjsfserver”)
Delegating log information – by Java-API
Server-side logging – Performance log (“log_performance”)
+ Testing
Setting up test environment - UsageWithoutSessionContext
Setting up test environment – Details
getStatusbar(), getPopupOKPopup(), getPopupYESNOPopup(), ...
The HTML-element-id is not stable!
Automated filling of attribute CLIENTNAME
Special information that are passed to client side testing tools
DIV data-riscclientname=“riscform_outest”
data-riscclientcommunicatingtoserver=true/false
+ Influencing the reading of layout definitions
Loading layout definitions from Database/...
Building your Dynamic Page Provider
Registering your Page Provider
Updating layout definitions before they get processed
+ Appendix – Stream Store Persistence
+ Appendix – URL Parameter for RISC Client
+ Appendix – Reading of configuration files
Reading of configuration files
First - Reading it from external configuration location
Second – Reading it from web content
Third – Reading it from the class loader
Same steps – but result is merged
Dynamic definitions inside configuration files
Decoupling the configuration from “.war-delivery”
Environment variables (${env. ... })
Java system variables (${sys. ... })
Configuration parameters (${ccparam. ... }
When to pass configuration parameters
Typical usage scenario with passing configuration parameters by IBootstrap implementation
Special reading of “${env. ...}” and “${sys. ...}” parameters
+ Appendix - Logging Configuration
Providing log directory by API
Using SLF4J to bind other logging frameworks
Log name “org.eclnt.serverlog.VIASLF4J “
Basic information that is logged