Software Engineering for Internet Applications

Slides:



Advertisements
Similar presentations
Bruce Scharlau, University of Aberdeen, 2010 Android UI, and Networking Mobile Computing Based on android-sdk_2.2 Unless otherwise stated, images are from.
Advertisements

Socket Programming. Basics Socket is an interface between application and network – Application creates a socket – Socket type dictates the style of communication.
@2011 Mihail L. Sichitiu1 Android Introduction Hello Socket Programming TCP and UDP.
CHATROOM PROJECT Supervised by DAN WITZNER HANSEN Group Members ESWAR EMMADI SURESH KUMAR DONTHA.
1 Creating a network app Write programs that  run on different end systems and  communicate over a network.  e.g., Web: Web server software communicates.
A CHAT CLIENT-SERVER MODULE IN JAVA BY MAHTAB M HUSSAIN MAYANK MOHAN ISE 582 FALL 2003 PROJECT.
1 L53 Networking (2). 2 OBJECTIVES In this chapter you will learn:  To understand Java networking with URLs, sockets and datagrams.  To implement Java.
The Transport Layer Chapter 6. The Transport Service Services Provided to the Upper Layers Transport Service Primitives Berkeley Sockets An Example of.
Client Server Model The client machine (or the client process) makes the request for some resource or service, and the server machine (the server process)
A Chat Server DBI – Representation and Management of Data on the Internet.
Liang, Introduction to Java Programming, Sixth Edition, (c) 2007 Pearson Education, Inc. All rights reserved L22 (Chapter 25) Networking.
Chat Room Project (IM- E2003) Supervised by : Dan Witzner Hansen Group Member: Xijie Lu Vu Pham To IT University of Copenhagen 23rd Jan.2004.
Client-server interactions in Mobile Applications.
Julia Ljunbjörk and Anita Mugenyi. What is a socket? Like a house Between the layers.
Web Proxy Server. Proxy Server Introduction Returns status and error messages. Handles http CGI requests. –For more information about CGI please refer.
TCP Sockets Reliable Communication. TCP As mentioned before, TCP sits on top of other layers (IP, hardware) and implements Reliability In-order delivery.
Android Application Development 2013 PClassic Chris Murphy 1.
19-Aug-15 About the Chat program. 2 Constraints You can't have two programs (or two copies of the same program) listen to the same port on the same machine.
Android UI, and Networking. Can do most networking on Android Bluetooth only on 2.0, Not supported with version 1.6.
By: Joel Rodriguez.  International student from Mexico  Delicias, Chihuahua Mexico  Spanish  Sports and Music.
Socket Lab Info. Computer Network. Requirement Use TCP socket to implement a pair of programs, containing a server and a client. The server program shall.
School of Engineering and Computer Science Victoria University of Wellington Copyright: Peter Andreae, VUW Networking COMP # 21.
Lab 6: Introduction to Sockets (Web Programming – Part 1) Reference: Head First Java (2 nd Edition) by Kathy Sierra & Bert Bates.
Outline Overview Video Format Conversion Connection with An authentication Streaming media Transferring media.
Vassil Roussev 2 A socket is the basic remote communication abstraction provided by the OS to processes. controlled by operating system.
ICOM 6115©Manuel Rodriguez-Martinez ICOM 6115 – Computer Networks and the WWW Manuel Rodriguez-Martinez, Ph.D. Lecture 26.
Android Boot Camp for Developers Using Java, 3E
L 2 - 1 3( 1/ 20) : Java Network Programming. The Socket API The previous contents describe client-server interaction that application programs use when.
MAKANI ANDROID APPLICATION Prepared by: Asma’ Hamayel Alaa Shaheen.
Texas Forty-Two By: Nate Normandin CS 470. What is Texas Forty-Two? A Domino Game A way for people to learn the game A way for people to play others A.
2: Application Layer1 Chapter 2: Application layer r 2.1 Principles of network applications r 2.2 Web and HTTP r 2.3 FTP r 2.4 Electronic Mail  SMTP,
CS 158A1 1.4 Implementing Network Software Phenomenal success of the Internet: – Computer # connected doubled every year since 1981, now approaching 200.
Gwynn Fewell. Build off of Brice Higlemann’s work from 2010 Mobile app becomes the CAB to control one train at a time App can switch between trains CAB.
@2010 Mihail L. Sichitiu1 Android Introduction Hello Threads.
Field Trip #25 Creating a Client/Server By Keith Lynn.
Socket Programming.
HW#9 Clues CSCI 571 Fall, HW#9 Prototype
Networking OSI (Open Systems Interconnection) model of computer networking, seven layers (the Application, Presentation, Session, Transport, Network, Data.
Socket programming in C. Socket programming Socket API introduced in BSD4.1 UNIX, 1981 explicitly created, used, released by apps client/server paradigm.
Java Networking I IS Outline  Quiz #3  Network architecture  Protocols  Sockets  Server Sockets  Multi-threaded Servers.
A Local Area Network Chat Client ITTC LAN CHAT John Vincent Cecogo Jerikho Daguno Ardee Santos Elaine Mendoza Anjomar Pat Del Mindo Philip John Sales Philip.
Li Tak Sing COMPS311F. Case study: a multithreaded chat server The source contains 3 files: ChatServer //the chat server ChatThread //the thread on the.
SOCKET PROGRAMMING WITH JAVA By Collin Donaldson.
Java’s networking capabilities are declared by the classes and interfaces of package java.net, through which Java offers stream-based communications that.
Remote Access Using a Netgear DG834 Router 1http://
1 K. Salah Application Layer Module K. Salah Network layer duties.
CLIENT (Browser) socket accept C1 C2 recv C2 recv send C2 send end_thread recv C3 send bind connect Web Server Proxy recv close C3 close C2 end_thread.
The Echo Server Problem. Contents  Basic Networking Concepts  The Echo Server Problem.
The Echo Server Problem. Contents  Basic Networking Concepts  The Echo Server Problem.
What does LinkConnect do?
Internet Socket Programing
Backdoor Attacks.
CSC410: Distributed System
Networking COMP
Beyond HTTP Up to this point we have been dealing with software tools that run on browsers and communicate to a server that generates files that can be.
Socket Programming Cal Poly Pomona Young CS380.
Android SDK & App Development
Hello Socket Programming TCP and UDP
Android Introduction Hello Threads.
Implementation CAN Communication Engine
Time Gathering Systems Secure Data Collection for IBM System i Server
Starting TCP Connection – A High Level View
CS323 Android Topics Network Basics for an Android App
Configuration Of A Pull Network.
TA: Donghyun (David) Kim
Chapter 5 멀티스레드 u-Network Design Lab 4.
Snippet Engine as a Database Server
Software Engineering and Architecture
CS18000: Problem Solving and Object-Oriented Programming
Presentation transcript:

Software Engineering for Internet Applications Mobile Apps Programming - Android Socket ADF 1/11/2019

Java Socket Remember Socket Programming? Multi-client chat via TCP Socket Build Android Socket for Client 1/11/2019

Server Chat Use the same Server.java Modify ServerThread.java Remove buffered reader as the input is no longer from string stream, change to Data Input Stream Create new Android Project for Client 1/11/2019

Server Thread ServerThread.java 1/11/2019

Server Thread ServerThread.java 1/11/2019

Android Client Create an Empty Project 1/11/2019

Android Manifest As the application will try to connect the network, add permission in the manifest file 1/11/2019

UI Layout 2 views Login panel view (vertical linear layout) Username input text Server address input text Connect button Chatting panel view(vertical linear layout) Chatting input text Send button Disconnect button Scroll view chat log 1/11/2019

UI Layout 1/11/2019

UI Layout View Chat Panel only when the connection is established Set chat panel visibility “gone” Give hint to input text username, server address, input chat Best practice to set all text value in string.xml 1/11/2019

UI Layout 1/11/2019

UI Layout 1/11/2019

UI Layout – Login Panel 1/11/2019

UI Layout – Chat Panel 1/11/2019

Client Thread Class Create client thread class 1/11/2019

Client Thread Class 1/11/2019

Client Thread Class 1/11/2019

Client Thread Class 1/11/2019

Client Thread Class 1/11/2019

Client Thread Class 1/11/2019

Main Activity Set server port number Add all element 1/11/2019

Main Activity Initialize resource activity in onCreate() method 1/11/2019

Main Activity Create Listener for each button 1/11/2019

Main Activity 1/11/2019

Main Activity Set onClickListener in onCreate() method 1/11/2019

Run Application Run Server Run Android Client Connect to IP Server 1/11/2019

1/11/2019