Java Desktop Client
The SureClinical Java Desktop Client is a Swing-based application that provides offline document access, quality review workflows, and digital signing capabilities for SureDrive and SureETMF content.
Module Overview
| Module | Description |
|---|---|
| suredms-desktop-client | Application shell: BaseLauncher, DesktopClient, ribbon, views, gadgets, wizards, dialogs, actions |
| suredms-desktop-client-connector | Backend bridge: EndPoints factory, XMLParser, Nuxeo transport, NuxeoClientPool |
| suredms-desktop-client-data | Shared domain model: BaseEntity, Archive, Document, User, DocDiscrepancy, and 40+ entity types |
| suredms-desktop-client-quality | Quality module: QualityView, AuditWizardBuilder, GadgetAuditViewer, GadgetDiscrepancyItems, charts |
| suredms-desktop-client-signing | Signing module: ESignServiceProxy, RemoteESignService, ClientCustomSignatureAppearanceProvider |
Architecture Summary
The desktop client is built as five Maven modules with clearly separated responsibilities. The shell module (suredms-desktop-client) is the host process — it owns the Swing frame, all named views (HomeView, ViewView, AcquireView, ShareView), the gadget framework, the wizard framework, and the 30+ ribbon action classes. The connector module (suredms-desktop-client-connector) is the sole transport layer — it selects between local XML archives, remote Nuxeo, and demo endpoints at login time. The data module (suredms-desktop-client-data) defines the entity model that both the connector and UI consume. The quality and signing modules mount specialized views and services into the shell.
BaseLauncher → BaseEntryPoint → DesktopClient (singleton, extends Application)
│
├── RibbonMenu ─────────────── feature-gated menus per archive
│
├── Views (each extends BaseView → GadgetPanel)
│ ├── HomeView — dashboard: 14 gadgets (articles, streams, charts, announce, etc.)
│ ├── ViewView — document navigator + PDF viewer + metadata + workflows
│ ├── AcquireView — acquire queue + document navigator + PDF viewer
│ ├── ShareView — share navigation and preview
│ └── QualityView — audit list, discrepancy viewer, chart panel
│
├── WizardBuilder framework
│ ├── UploadWizardBuilder
│ ├── SignLocalFileWizardBuilder
│ ├── AuditWizardBuilder
│ └── RequiredDocumentWizardBuilder
│
└── EndPoints (connector module)
├── EP_LOCAL → XMLEndPoints → XMLParser
├── EP_REMOTE → NuxeoEndPoints → NuxeoClientImpl
└── EP_DEMO → XmlDemoEndPoints
Gadget Layout System
All views use the Bibliothek DockingFrames docking library to compose gadget panels. Each view extends BaseView, which extends GadgetPanel. Gadgets are arranged via a CGrid and their positions are persisted per-user via PreferencesUtils under keys of the form user.custom.ui.<loginName>.<viewName>.<gadgetName>. The docking system supports minimized, floating, and docked gadget states.
Wizard Framework
All multi-step dialogs in the desktop client extend WizardBuilder. The base class handles:
- Escape-key cancellation via
KeyStroke - Step sequencing via
List<WizardStep> DialogResultListenercallbacks on completion- Leak detection via
LeakDetector - Dependency injection via
Injector
Key Entry Points
| File | Purpose |
|---|---|
SC/suredms-desktop-client/src/main/java/com/sureclinical/suredms/BaseLauncher.java | Static initializers + JVM + OS setup |
SC/suredms-desktop-client/src/main/java/com/sureclinical/suredms/ui/DesktopClient.java | Core application singleton |
SC/suredms-desktop-client-connector/src/main/java/com/sureclinical/suredms/endpoints/EndPoints.java | Endpoint factory |
SC/suredms-desktop-client-connector/src/main/java/com/sureclinical/suredms/xml/XMLParser.java | Local XML archive parser |
SC/suredms-desktop-client-quality/src/main/java/com/sureclinical/suredms/ui/views/QualityView.java | Quality module view |
SC/suredms-desktop-client-signing/src/main/java/com/sureclinical/suredms/esign/ESignServiceProxy.java | Signing service proxy |
Module Dependencies
suredms-desktop-client
├── suredms-desktop-client-connector
│ └── suredms-desktop-client-data
├── suredms-desktop-client-quality
│ └── suredms-desktop-client-data
└── suredms-desktop-client-signing
└── suredms-desktop-client-data
suredms-desktop-client-data has no inter-module dependencies within the desktop family. All other desktop modules depend on it.