t oday ’ s a genda what is inetwork? how to install it networking in a nutshell basic code +...

41

Upload: kelley-harmon

Post on 21-Jan-2016

222 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples
Page 2: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

TODAY’S AGENDAWhat is iNetwork?

How to Install itNetworking in a NutshellBasic Code + Templates

Examples

Page 3: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

What is iNetwork?1

Page 4: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

WHAT IS INETWORK?Message-Based Networking LibraryCreated by Sebastian BoringCross Platform and Cross Device

Page 5: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

WHAT IS INETWORK?Message-Based Networking LibraryCreated by Sebastian BoringCross Platform and Cross Device–WPF and C#–Windows Phone 7– iOS (iPhone, iPad)–More to come (Java, etc.)

Page 6: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

Installation2

Page 7: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

Google: iLab

Cookbook

Page 8: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples
Page 9: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples
Page 10: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples
Page 11: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

Networking in a Nutshell3

Page 12: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples
Page 13: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples
Page 14: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples
Page 15: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

Server

ClientClient

Page 16: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

Send Message

Page 17: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

Receive Message

Page 18: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

Relay Message

Page 19: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

Modify Message

Page 20: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

Any Questions?

Page 21: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

It’ll make more sense soon,

I promise.

Page 22: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

Basic Code + Templates4

Page 23: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

BASIC CODEOnce you downloaded iNetwork, you will have access to the basic templates.

Page 24: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

BASIC CODEYou will (often) have more than one project in your solution:

One for the server

One (or more) for the clients

Page 25: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

Show Templates in Visual Studio

Page 26: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

Examples5

Page 27: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

Basic Chat Program

Page 28: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

Synchronized Sliders

Page 29: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

WHY SYNC SLIDERS?It’s a simple example that illustrates communication between both client and server

Instead of using slider values, this could be some phidget sensor information!

Page 30: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples
Page 31: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

Synchronized Sliders:Phone Demo

Page 32: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

Things to Note6

Page 33: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

THINGS TO NOTE1. You can run more than one

program within the same instance of Visual Studio.

– Run server program– While server runs, go back to

Visual Studio– Select View -> Solution

Explorer– Now you can start a new

instance of the cl ient(s)

Page 34: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples
Page 35: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

THINGS TO NOTEDrawback to running the same instance of Visual Studio:

Shared console, harder to debug through write line statements!

Page 36: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

THINGS TO NOTE2. Network messages run on

a separate thread from the UI. If you want to change the UI, remember to invoke the dispatcher!

Page 37: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

THINGS TO NOTEOn WPF

Page 38: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

THINGS TO NOTEOn Silverlight (Windows Phone)

Page 39: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

THINGS TO NOTE3. You will likely have to

change your IP Address in the code when you do your demos!

Page 40: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples

YOU SHOULD NOW KNOW

What is iNetworkHow to Install it + ResourcesA Bit on NetworkingiNetwork TemplatesIntermediate iNetwork Programming

Page 41: T ODAY ’ S A GENDA What is iNetwork? How to Install it Networking in a Nutshell Basic Code + Templates Examples