building a windows client

26
© 2014 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office. Building a Windows Client Brian Postlethwaite Phoenix, AZ - May 2014

Upload: fayre

Post on 13-Jan-2016

45 views

Category:

Documents


0 download

DESCRIPTION

Building a Windows Client. Brian Postlethwaite Phoenix, AZ - May 2014. Who am I?. Name: Brian Postlethwaite Company: DCA eHealth Solutions, Australia Background: HL7 Patient Administration team OMG Healthcare DTF: ServD Standard Solutions Architect Contact: [email protected]. - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: Building a Windows Client

© 2014 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

Building a Windows Client

Brian Postlethwaite

Phoenix, AZ - May 2014

Page 2: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

Who am I?

Name: Brian Postlethwaite Company: DCA eHealth Solutions,

Australia Background:

HL7 Patient Administration team OMG Healthcare DTF: ServD Standard Solutions Architect

Contact: [email protected]

2

Page 3: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

Introductions

Who is building with .NET?

Who is using the fhir API?

Who grabs it from Github/NuGet?

Which Platform(s) are you targeting?

3

Page 4: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

Contents…

4

fhir .NET Model / API Where to get them Building your own API

And contribute!

MVVM quick overview Make a View Model Sharing Code “Tweaking” code

Page 5: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

What is the fhir Model/API?

Object Model Validation Cardinality Contained Objects Extensions

API Parsers/Serialization Utilities Validators Simplified Common

Operations

5

Page 6: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

Why not native?

Own code – Must maintain it Need to consider both formats (json/xml) Handle extensions cleanly Both formats have their own “specifics” XML and json are best represented on the

wire in different ways The fhir client has been extensively tested,

and continues to grow6

Page 7: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

Where can nuGet It?

NuGet! Directly from within Visual Studio

7

Page 8: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

Where else can I Git It?

GitHub! https://github.com/ewoutkramer/fhir-net-api

Location of the API Source Mirror of the HL7 Forge c# model code

Which can be downloaded from the fhir site Easier to see the history and change

Build and Contribute! Contains .NET 4.0/4.5/PCL 4.5 projects

8

Page 9: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

Documentation

http://ewoutkramer.github.io/fhir-net-api/

11

Page 10: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

MVVM Review

12

Page 11: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

Data-Binding

Properties in object INotifyPropertyChanged Events Observable Collections Converters IValueConverter

INotifyPropertyChanged was recently added to the basic Model objects

13

Page 12: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

Commands

For use with Data-binding functionality Class that derives from ICommand Supports enabling/disabling

Example Commands Search Clear Save

14

Page 13: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

Test Data

Create some test data (patient-test-data.xaml)

Create “test data in code” Use in the design surface Issues:

The fhir model uses nested classes(Not supported by the test data xaml stuff)

To overcome this, for the properties that you intend to data-bind, create simple properties that encapsulate nested classes

15

Page 14: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

My App Project Structure

fhir place Solution dca.fhir.Model (PCL) fhir-place-wpf (net 4.0) fhir-place-win8 (Net 4.5) fhir-place-Phone8 (Silverlight 8) fhir-place (univeral app) *new*

fhir-place.Windows (Windows 8.1) fhir-place.WindowsPhone (Windows Phone 8.1) fhir-place.Shared

16

Page 15: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

Design Your Model / View Model

What is your app trying to display? What user interactions are planned? What form factors are you covering? What is your navigation model? What are the connectivity issues? Error handling/reporting? User Interface control requirements? Security?

18

Page 16: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

Demo App

Server textbox Search for Name textbox Search Button Total Results counter Search Command Patient List results Patient Item User Control

19

Page 17: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

DEMONSTRATIONFull Search Patient App

20

Page 18: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

My Apps

Simple Patient Viewers Wrapped Model Cached Reference Items Recent Viewed List Patient Demographics, Allergies, Conditions,

Medication Statements, Observations (with Charts)

Aggregates results from multiple servers To be published in the Microsoft App Stores

21

Page 19: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

My Apps

Simple Patient Viewer Concept Doctor Viewing Patient Records in

the field (well golf course!)

22

Page 20: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

23

Page 21: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

My Apps

Concept Emergency Room App(Bed End or Nurse’s Mobile Device)

24

Page 22: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

25

Page 23: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

26

Page 24: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

Try it yourself!

Repeat my live demonstration app!

Do it for a different resource type

Point it at your own fhir server!

27

Page 25: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

Questions?

28

Page 26: Building a Windows Client

© 2013 HL7 ® International. Licensed under Creative Commons. HL7 & Health Level Seven are registered trademarks of Health Level Seven International. Reg. U.S. TM Office.

Thank you

29