[Type text] ECET465
Project 2Project Assignment 2: Building a Multi-Threaded Web Server
This project assignment is due at the end of the seventh week of the course and is worth 7% of your total grade.
In this project, we will develop a Web server in two steps. In the end, you will have built a multi-threaded Web server that is capable of processing multiple simultaneous service requests in parallel. Section 2.7 of your text may offer you some insight and help. You should be able to demonstrate that your Web server is capable of delivering your home page to a Web browser.
We are going to implement Version 1.0 of HTTP, as defined in RFC 1945, where separate HTTP requests are sent for each component of the Web page. The server will be able to handle multiple simultaneous service requests in parallel. This means that the Web server is multi-threaded. In the main thread, the server listens to a fixed port. When it receives a TCP connection request, it sets up a TCP connection through another port and services the request in a separate thread. To simplify this programming task, we will develop the code in two stages. In the first stage, you will write a multi-threaded server that simply displays the contents of the HTTP request message that it receives. After this program is running properly, you will add the code required to generate an appropriate response.
As you are developing the code, you can test your server from a Web browser. Just remember that you are not serving through the standard port 80, so you need to specify the port number within the URL that you give to your browser. For example, if your machine's name is host.someschool.edu, your server is listening to port 6789, and you want to retrieve the file index.html, then you would specify the following URL within the browser: http://host.someschool.edu:6789/index.html
If you omit ":6789," the browser will assume port 80, which most likely will not have a server listening on it.
When the server encounters an error, it sends a response message with the appropriate HTML source so that the error information is displayed in the browser window.
Web Server in Java: Part A
In the following steps, we will go through the code for the first implementation of our Web server. Wherever you see "?," you will need to supply a missing detail.
Our first implementation of the Web server will be multi-threaded, where the processing of each incoming request will take place inside a separate thread of execution. This allows the server to service multiple clients in parallel, or to perform multiple file transfers to a single client in parallel. When we create a new thread of execution, we need to pass to the Thread's constructor an instance of some class that implements the Runnable interface. This is the reason why we define a separate class called HttpRequest. The structure of the Web server is shown below: import java.io.* ;import java.net.* ;import java.util.* ;public final class WebServer{ public.
Project Assignment 2 Building a Multi-Threaded Web ServerThis pro.docxkacie8xcheco
Project Assignment 2: Building a Multi-Threaded Web Server
This project assignment is due at the end of the seventh week of the course and is worth 7% of your total grade.
In this project, we will develop a Web server in two steps. In the end, you will have built a multi-threaded Web server that is capable of processing multiple simultaneous service requests in parallel. Section 2.7 of your text may offer you some insight and help. You should be able to demonstrate that your Web server is capable of delivering your home page to a Web browser.
We are going to implement Version 1.0 of HTTP, as defined in
RFC 1945
, where separate HTTP requests are sent for each component of the Web page. The server will be able to handle multiple simultaneous service requests in parallel. This means that the Web server is multi-threaded. In the main thread, the server listens to a fixed port. When it receives a TCP connection request, it sets up a TCP connection through another port and services the request in a separate thread. To simplify this programming task, we will develop the code in two stages. In the first stage, you will write a multi-threaded server that simply displays the contents of the HTTP request message that it receives. After this program is running properly, you will add the code required to generate an appropriate response.
As you are developing the code, you can test your server from a Web browser. Just remember that you are not serving through the standard port 80, so you need to specify the port number within the URL that you give to your browser. For example, if your machine's name is
host.someschool.edu
, your server is listening to port 6789, and you want to retrieve the file
index.html
, then you would specify the following URL within the browser:
http://host.someschool.edu:6789/index.html
If you omit ":6789," the browser will assume port 80, which most likely will not have a server listening on it.
When the server encounters an error, it sends a response message with the appropriate HTML source so that the error information is displayed in the browser window.
Web Server in Java: Part A
In the following steps, we will go through the code for the first implementation of our Web server. Wherever you see "?," you will need to supply a missing detail.
Our first implementation of the Web server will be multi-threaded, where the processing of each incoming request will take place inside a separate thread of execution. This allows the server to service multiple clients in parallel, or to perform multiple file transfers to a single client in parallel. When we create a new thread of execution, we need to pass to the Thread's constructor an instance of some class that implements the
Runnable
interface. This is the reason why we define a separate class called
HttpRequest
. The structure of the Web server is shown below:
import java.io.* ;
import java.net.* ;
import java.util.* ;
public final class WebServer
{
public static void main(S.
692015 programming assignment 1 building a multithreaded wsmile790243
The document describes the steps to build a multi-threaded web server in Java that can process multiple HTTP requests simultaneously in separate threads. It provides code snippets to create a basic server that displays request headers, and then extends it to analyze requests and send appropriate response messages containing status lines and file contents or error messages.
1)Building a MultiThreaded Web ServerIn this lab we will develAgripinaBeaulieuyw
1)Building a MultiThreaded Web Server
In this lab we will develop a Web server in two steps. In the end, you will have built a multithreaded
Web server that is capable of processing multiple simultaneous service requests in parallel. You should be able to demonstrate
that your Web server is capable of delivering your home page to a Web browser.
We are going to implement version 1.0 of HTTP, as defined in RFC 1945, where separate HTTP requests are sent
for each component of the Web page. The server will be able to handle multiple simultaneous service requests in
parallel. This means that the Web server is multithreaded.
In the main thread, the server listens to a fixed port.
When it receives a TCP connection request, it sets up a TCP connection through another port and services the
request in a separate thread. To simplify this programming task, we will develop the code in two stages. In the first
stage, you will write a multithreaded
server that simply displays the contents of the HTTP request message that it
receives. After this program is running properly, you will add the code required to generate an appropriate response.
As you are developing the code, you can test your server from a Web browser. But remember that you are not
serving through the standard port 80, so you need to specify the port number within the URL that you give to your
browser. For example, if your machine's name is host.someschool.edu, your server is listening to port 6789, and
you want to retrieve the file index.html, then you would specify the following URL within the browser:
http://host.someschool.edu:6789/index.html
If you omit ":6789", the browser will assume port 80 which most likely will not have a server listening on it.
When the server encounters an error, it sends a response message with the appropriate HTML source so that the
error information is displayed in the browser window.
Web Server in Java: Part A
In the following steps, we will go through the code for the first implementation of our Web Server. Wherever you see
"?", you will need to supply a missing detail.
Our first implementation of the Web server will be multithreaded,
where the processing of each incoming request
will take place inside a separate thread of execution. This allows the server to service multiple clients in parallel, or
to perform multiple file transfers to a single client in parallel. When we create a new thread of execution, we need to
pass to the Thread's constructor an instance of some class that implements the Runnable interface. This is the
reason that we define a separate class called HttpRequest. The structure of the Web server is shown below:
import java.io.* ;
import java.net.* ;
import java.util.* ;
public final class WebServer
{
public static void main(String argv[]) throws Exception
{
. . .
}
}
final class HttpRequest implements Runnable
{
. . .
}
Normally, Web servers process service requests that they receive thr ...
MCIS 6163 Assignment 1/MCIS 6163 Assignment 1.pdf
Assignment 1 – MCIS 6163
Building a Simple Web Client and a Multithreaded Web Server
Objectives
To understand client-server communication via sockets.
To gain exposure to the basic operations of a Web server and client.
To explore basic structures of HTTP messages.
Due: April 14, 2020 11:59pm
Project Description
In this project, you will be developing a multithreaded Web server and a simple web client. The Web
server and Web client communicate using a text-based protocol called HTTP (Hypertext Transfer
Protocol).
Requirements for the Web server
The server is able to handle multiple requests concurrently. This means the implementation is
multithreaded. In the main thread, the server listens to a specified port, e.g., 8080. Upon receiving an
HTTP request, the server sets up a TCP connection to the requesting client and serves the request in a
separate thread. After sending the response back to the client, it closes the connection.
The server is assumed to work with HTTP GET messages. If the requested file exists, the server
responds with “HTTP/1.1 200 OK” together with the requested page to the client, otherwise it sends a
corresponding error message, e.g., “HTTP/1.1 404 Not Found” or “HTTP/1.1 400 Bad Request”.
If running the server program using command line, the syntax should be:
server_code_name [<port_number>]
where the optional <port_number> is the port on which the server is listening to connections from
clients. If the port number is not entered, the default port 8080 is used.
You can test your Web server implementation on your local machine using a Web browser, e.g.,
Internet Explorer, Firefox, or Chrome. You need to specify the used port number within the URL, for
example,
http://localhost:8080/index.htm
If omitting the port number portion, i.e., 8080, the browser will use the default port 80.
The server should response with a default page when users do not enter a specific page in the URL,
for example,
http://localhost:8080/
It should also work when the request includes a path to the requested file, for example,
http://localhost:8080/path/to/file/example.htm
You should display/log the request and header lines of request messages on the server for the purpose
of debugging.
Requirements for the simple Web client
The client is able to connect to the server via a socket and to request a page on the server.
Upon receipt of the response message from the server, the client extracts and displays/logs the
message status, and then retrieves the page content from the message body.
If running the client program using command line, the syntax should be:
client_code_name <server_IPaddress/name> [<port_number>] [<requested_file_name>]
where the <server_IPaddress/name> is the IP address or name of the Web server, e.g., 127.0.0.1 or
localhost for the server running on the local machine. The optional < ...
MCIS 6163 Assignment 1/MCIS 6163 Assignment 1.pdf
Assignment 1 – MCIS 6163
Building a Simple Web Client and a Multithreaded Web Server
Objectives
To understand client-server communication via sockets.
To gain exposure to the basic operations of a Web server and client.
To explore basic structures of HTTP messages.
Due: April 14, 2020 11:59pm
Project Description
In this project, you will be developing a multithreaded Web server and a simple web client. The Web
server and Web client communicate using a text-based protocol called HTTP (Hypertext Transfer
Protocol).
Requirements for the Web server
The server is able to handle multiple requests concurrently. This means the implementation is
multithreaded. In the main thread, the server listens to a specified port, e.g., 8080. Upon receiving an
HTTP request, the server sets up a TCP connection to the requesting client and serves the request in a
separate thread. After sending the response back to the client, it closes the connection.
The server is assumed to work with HTTP GET messages. If the requested file exists, the server
responds with “HTTP/1.1 200 OK” together with the requested page to the client, otherwise it sends a
corresponding error message, e.g., “HTTP/1.1 404 Not Found” or “HTTP/1.1 400 Bad Request”.
If running the server program using command line, the syntax should be:
server_code_name [<port_number>]
where the optional <port_number> is the port on which the server is listening to connections from
clients. If the port number is not entered, the default port 8080 is used.
You can test your Web server implementation on your local machine using a Web browser, e.g.,
Internet Explorer, Firefox, or Chrome. You need to specify the used port number within the URL, for
example,
http://localhost:8080/index.htm
If omitting the port number portion, i.e., 8080, the browser will use the default port 80.
The server should response with a default page when users do not enter a specific page in the URL,
for example,
http://localhost:8080/
It should also work when the request includes a path to the requested file, for example,
http://localhost:8080/path/to/file/example.htm
You should display/log the request and header lines of request messages on the server for the purpose
of debugging.
Requirements for the simple Web client
The client is able to connect to the server via a socket and to request a page on the server.
Upon receipt of the response message from the server, the client extracts and displays/logs the
message status, and then retrieves the page content from the message body.
If running the client program using command line, the syntax should be:
client_code_name <server_IPaddress/name> [<port_number>] [<requested_file_name>]
where the <server_IPaddress/name> is the IP address or name of the Web server, e.g., 127.0.0.1 or
localhost for the server running on the local machine. The optional <.
This document discusses Java networking and client/server communication. A client machine makes requests to a server machine over a network using protocols like TCP and UDP. TCP provides reliable data transmission while UDP sends independent data packets. Port numbers map incoming data to running processes. Sockets provide an interface for programming networks, with ServerSocket and Socket classes in Java. A server program listens on a port for client connections and exchanges data through input/output streams. Servlets extend web server functionality by executing Java programs in response to client requests.
The document discusses network programming and Java sockets. It introduces elements of client-server computing including networking basics like TCP, UDP and ports. It then covers Java sockets, explaining how to implement both a server and client using Java sockets. Code examples are provided of a simple server and client. The conclusion emphasizes that Java makes socket programming easier than other languages like C.
This document discusses network programming and Java sockets. It begins with an introduction to client-server computing and networking basics like TCP, UDP, and ports. It then covers Java sockets in detail, including how to implement a server that can accept multiple clients by creating a new thread for each, and how to implement a client. Sample code is provided for a simple single-threaded server and client. The document concludes that programming client-server applications in Java using sockets is easier than in other languages like C.
Project Assignment 2 Building a Multi-Threaded Web ServerThis pro.docxkacie8xcheco
Project Assignment 2: Building a Multi-Threaded Web Server
This project assignment is due at the end of the seventh week of the course and is worth 7% of your total grade.
In this project, we will develop a Web server in two steps. In the end, you will have built a multi-threaded Web server that is capable of processing multiple simultaneous service requests in parallel. Section 2.7 of your text may offer you some insight and help. You should be able to demonstrate that your Web server is capable of delivering your home page to a Web browser.
We are going to implement Version 1.0 of HTTP, as defined in
RFC 1945
, where separate HTTP requests are sent for each component of the Web page. The server will be able to handle multiple simultaneous service requests in parallel. This means that the Web server is multi-threaded. In the main thread, the server listens to a fixed port. When it receives a TCP connection request, it sets up a TCP connection through another port and services the request in a separate thread. To simplify this programming task, we will develop the code in two stages. In the first stage, you will write a multi-threaded server that simply displays the contents of the HTTP request message that it receives. After this program is running properly, you will add the code required to generate an appropriate response.
As you are developing the code, you can test your server from a Web browser. Just remember that you are not serving through the standard port 80, so you need to specify the port number within the URL that you give to your browser. For example, if your machine's name is
host.someschool.edu
, your server is listening to port 6789, and you want to retrieve the file
index.html
, then you would specify the following URL within the browser:
http://host.someschool.edu:6789/index.html
If you omit ":6789," the browser will assume port 80, which most likely will not have a server listening on it.
When the server encounters an error, it sends a response message with the appropriate HTML source so that the error information is displayed in the browser window.
Web Server in Java: Part A
In the following steps, we will go through the code for the first implementation of our Web server. Wherever you see "?," you will need to supply a missing detail.
Our first implementation of the Web server will be multi-threaded, where the processing of each incoming request will take place inside a separate thread of execution. This allows the server to service multiple clients in parallel, or to perform multiple file transfers to a single client in parallel. When we create a new thread of execution, we need to pass to the Thread's constructor an instance of some class that implements the
Runnable
interface. This is the reason why we define a separate class called
HttpRequest
. The structure of the Web server is shown below:
import java.io.* ;
import java.net.* ;
import java.util.* ;
public final class WebServer
{
public static void main(S.
692015 programming assignment 1 building a multithreaded wsmile790243
The document describes the steps to build a multi-threaded web server in Java that can process multiple HTTP requests simultaneously in separate threads. It provides code snippets to create a basic server that displays request headers, and then extends it to analyze requests and send appropriate response messages containing status lines and file contents or error messages.
1)Building a MultiThreaded Web ServerIn this lab we will develAgripinaBeaulieuyw
1)Building a MultiThreaded Web Server
In this lab we will develop a Web server in two steps. In the end, you will have built a multithreaded
Web server that is capable of processing multiple simultaneous service requests in parallel. You should be able to demonstrate
that your Web server is capable of delivering your home page to a Web browser.
We are going to implement version 1.0 of HTTP, as defined in RFC 1945, where separate HTTP requests are sent
for each component of the Web page. The server will be able to handle multiple simultaneous service requests in
parallel. This means that the Web server is multithreaded.
In the main thread, the server listens to a fixed port.
When it receives a TCP connection request, it sets up a TCP connection through another port and services the
request in a separate thread. To simplify this programming task, we will develop the code in two stages. In the first
stage, you will write a multithreaded
server that simply displays the contents of the HTTP request message that it
receives. After this program is running properly, you will add the code required to generate an appropriate response.
As you are developing the code, you can test your server from a Web browser. But remember that you are not
serving through the standard port 80, so you need to specify the port number within the URL that you give to your
browser. For example, if your machine's name is host.someschool.edu, your server is listening to port 6789, and
you want to retrieve the file index.html, then you would specify the following URL within the browser:
http://host.someschool.edu:6789/index.html
If you omit ":6789", the browser will assume port 80 which most likely will not have a server listening on it.
When the server encounters an error, it sends a response message with the appropriate HTML source so that the
error information is displayed in the browser window.
Web Server in Java: Part A
In the following steps, we will go through the code for the first implementation of our Web Server. Wherever you see
"?", you will need to supply a missing detail.
Our first implementation of the Web server will be multithreaded,
where the processing of each incoming request
will take place inside a separate thread of execution. This allows the server to service multiple clients in parallel, or
to perform multiple file transfers to a single client in parallel. When we create a new thread of execution, we need to
pass to the Thread's constructor an instance of some class that implements the Runnable interface. This is the
reason that we define a separate class called HttpRequest. The structure of the Web server is shown below:
import java.io.* ;
import java.net.* ;
import java.util.* ;
public final class WebServer
{
public static void main(String argv[]) throws Exception
{
. . .
}
}
final class HttpRequest implements Runnable
{
. . .
}
Normally, Web servers process service requests that they receive thr ...
MCIS 6163 Assignment 1/MCIS 6163 Assignment 1.pdf
Assignment 1 – MCIS 6163
Building a Simple Web Client and a Multithreaded Web Server
Objectives
To understand client-server communication via sockets.
To gain exposure to the basic operations of a Web server and client.
To explore basic structures of HTTP messages.
Due: April 14, 2020 11:59pm
Project Description
In this project, you will be developing a multithreaded Web server and a simple web client. The Web
server and Web client communicate using a text-based protocol called HTTP (Hypertext Transfer
Protocol).
Requirements for the Web server
The server is able to handle multiple requests concurrently. This means the implementation is
multithreaded. In the main thread, the server listens to a specified port, e.g., 8080. Upon receiving an
HTTP request, the server sets up a TCP connection to the requesting client and serves the request in a
separate thread. After sending the response back to the client, it closes the connection.
The server is assumed to work with HTTP GET messages. If the requested file exists, the server
responds with “HTTP/1.1 200 OK” together with the requested page to the client, otherwise it sends a
corresponding error message, e.g., “HTTP/1.1 404 Not Found” or “HTTP/1.1 400 Bad Request”.
If running the server program using command line, the syntax should be:
server_code_name [<port_number>]
where the optional <port_number> is the port on which the server is listening to connections from
clients. If the port number is not entered, the default port 8080 is used.
You can test your Web server implementation on your local machine using a Web browser, e.g.,
Internet Explorer, Firefox, or Chrome. You need to specify the used port number within the URL, for
example,
http://localhost:8080/index.htm
If omitting the port number portion, i.e., 8080, the browser will use the default port 80.
The server should response with a default page when users do not enter a specific page in the URL,
for example,
http://localhost:8080/
It should also work when the request includes a path to the requested file, for example,
http://localhost:8080/path/to/file/example.htm
You should display/log the request and header lines of request messages on the server for the purpose
of debugging.
Requirements for the simple Web client
The client is able to connect to the server via a socket and to request a page on the server.
Upon receipt of the response message from the server, the client extracts and displays/logs the
message status, and then retrieves the page content from the message body.
If running the client program using command line, the syntax should be:
client_code_name <server_IPaddress/name> [<port_number>] [<requested_file_name>]
where the <server_IPaddress/name> is the IP address or name of the Web server, e.g., 127.0.0.1 or
localhost for the server running on the local machine. The optional < ...
MCIS 6163 Assignment 1/MCIS 6163 Assignment 1.pdf
Assignment 1 – MCIS 6163
Building a Simple Web Client and a Multithreaded Web Server
Objectives
To understand client-server communication via sockets.
To gain exposure to the basic operations of a Web server and client.
To explore basic structures of HTTP messages.
Due: April 14, 2020 11:59pm
Project Description
In this project, you will be developing a multithreaded Web server and a simple web client. The Web
server and Web client communicate using a text-based protocol called HTTP (Hypertext Transfer
Protocol).
Requirements for the Web server
The server is able to handle multiple requests concurrently. This means the implementation is
multithreaded. In the main thread, the server listens to a specified port, e.g., 8080. Upon receiving an
HTTP request, the server sets up a TCP connection to the requesting client and serves the request in a
separate thread. After sending the response back to the client, it closes the connection.
The server is assumed to work with HTTP GET messages. If the requested file exists, the server
responds with “HTTP/1.1 200 OK” together with the requested page to the client, otherwise it sends a
corresponding error message, e.g., “HTTP/1.1 404 Not Found” or “HTTP/1.1 400 Bad Request”.
If running the server program using command line, the syntax should be:
server_code_name [<port_number>]
where the optional <port_number> is the port on which the server is listening to connections from
clients. If the port number is not entered, the default port 8080 is used.
You can test your Web server implementation on your local machine using a Web browser, e.g.,
Internet Explorer, Firefox, or Chrome. You need to specify the used port number within the URL, for
example,
http://localhost:8080/index.htm
If omitting the port number portion, i.e., 8080, the browser will use the default port 80.
The server should response with a default page when users do not enter a specific page in the URL,
for example,
http://localhost:8080/
It should also work when the request includes a path to the requested file, for example,
http://localhost:8080/path/to/file/example.htm
You should display/log the request and header lines of request messages on the server for the purpose
of debugging.
Requirements for the simple Web client
The client is able to connect to the server via a socket and to request a page on the server.
Upon receipt of the response message from the server, the client extracts and displays/logs the
message status, and then retrieves the page content from the message body.
If running the client program using command line, the syntax should be:
client_code_name <server_IPaddress/name> [<port_number>] [<requested_file_name>]
where the <server_IPaddress/name> is the IP address or name of the Web server, e.g., 127.0.0.1 or
localhost for the server running on the local machine. The optional <.
This document discusses Java networking and client/server communication. A client machine makes requests to a server machine over a network using protocols like TCP and UDP. TCP provides reliable data transmission while UDP sends independent data packets. Port numbers map incoming data to running processes. Sockets provide an interface for programming networks, with ServerSocket and Socket classes in Java. A server program listens on a port for client connections and exchanges data through input/output streams. Servlets extend web server functionality by executing Java programs in response to client requests.
The document discusses network programming and Java sockets. It introduces elements of client-server computing including networking basics like TCP, UDP and ports. It then covers Java sockets, explaining how to implement both a server and client using Java sockets. Code examples are provided of a simple server and client. The conclusion emphasizes that Java makes socket programming easier than other languages like C.
This document discusses network programming and Java sockets. It begins with an introduction to client-server computing and networking basics like TCP, UDP, and ports. It then covers Java sockets in detail, including how to implement a server that can accept multiple clients by creating a new thread for each, and how to implement a client. Sample code is provided for a simple single-threaded server and client. The document concludes that programming client-server applications in Java using sockets is easier than in other languages like C.
1. Sockets provide a connection between client and server programs that allows them to communicate over a network. A socket is bound to each end of the connection.
2. The Socket class implements client sockets and allows a client program to connect to a server, send and receive data, and close the connection. The ServerSocket class allows a server program to listen for connections on a port and accept sockets from clients.
3. When a client connects to a server, the server accepts the connection using ServerSocket and returns a Socket. The client and server can then communicate by getting input and output streams from the socket to send data over the connection according to the network protocol.
The Java Mail Server project allows clients to connect to a mail server to send and receive emails and attachments. The project is divided into three modules: a server module that uses server sockets to accept client connections, a client module that uses sockets to connect to the server, and an email inbox module that handles mail functions like forwarding, viewing attachments, and saving emails. The server stores details of client connections, mail sending and receiving. Clients can connect when the server is active to exchange emails with other clients. Usernames and passwords are stored in data files rather than a SQL server. The project provides automatic threading to handle socket connections and includes features for reliable TCP communication between clients.
The Presentation given at Guru Gobind Singh Polytechnic, Nashik for Third Year Information Technology and Computer Engineering Students on 08/02/2011.
Topic: Java Network Programming
Old Java lectures by my teacher Karim Zebari at Software Department College of Engineering University of Salahaddin-Erbil. The topics are:
- Multithreading
- Security in Java
- Java Beans
- Internationalization
- Java Servlets
- Java Server Pages
- Database access in Java
- More GUI Components & Printing
- Remote Method Invocation (RMI)
- Java Collections Framework
This document provides an overview of networking concepts in Java including:
1) It outlines topics on networking basics like IP addresses, ports, protocols and client-server interactions.
2) It describes how to write networking clients and servers using sockets.
3) It provides an example of writing a simple ICQ client-server application to demonstrate sockets.
4) It discusses communicating with web servers by retrieving and sending information using URLs and URLConnections.
This document provides an overview of networking concepts in Java including TCP/IP and UDP protocols, internet addressing, sockets, URLs, and how to implement client-server communication using TCP and UDP sockets. Key topics covered include the difference between TCP and UDP, how sockets connect applications to networks, internet addressing with IPv4 and IPv6, and examples of writing basic TCP and UDP client-server programs in Java.
This document provides a tutorial on network programming in Java. It introduces Java network programming and the HTTP protocol. It discusses how Java uses sockets to establish connections between clients and servers. It also describes the Java URL class, which makes it easier to work with HTTP connections by abstracting away the low-level socket implementation. The tutorial provides examples of both an HTTP client and server implemented in Java using sockets and the URL class.
This document describes how to create a simple chat room using Python sockets and threading. It involves running a server script that initializes a socket to listen for client connections on a specified port. When a client connects, the server creates a thread to handle communication with that client. The client script connects to the server socket and allows sending and receiving messages that are broadcast to all connected clients. The chat room can be used locally on a private network or accessed remotely over the internet using port forwarding.
The document provides an overview of object oriented programming and network programming concepts. It discusses topics like IP addresses, ports, sockets, client-server programming, and the java.net and java.util packages. The java.net package contains classes for network programming in Java like Socket, ServerSocket, URL, and InetAddress. The java.util package contains general-purpose utility classes like ArrayList, HashMap, Properties and Date.
The document discusses network programming and the client-server model. It covers:
- The client-server exchange involves a client sending a request, the server handling the request and sending a response, and the client handling the response.
- Sockets provide a programming interface that allows network I/O to appear as file I/O. Clients and servers communicate by reading from and writing to socket file descriptors.
- Servers run as long-running daemon processes, listening on well-known ports for connection requests from clients. When a request is received, the server accepts the connection to form a connected socket for bidirectional data exchange.
How a network connection is created A network connection is initi.pdfarccreation001
How a network connection is created ?
A network connection is initiated by a client program when it creates a socket for the
communication with the server. To create the socket in Java, the client calls the Socket
constructor and passes the server address and the the specific server port number to it. At this
stage the server must be started on the machine having the specified address and listening for
connections on its specific port number.
The server uses a specific port dedicated only to listening for connection requests from clients. It
can not use this specific port for data communication with the clients because the server must be
able to accept the client connection at any instant. So, its specific port is dedicated only to
listening for new connection requests. The server side socket associated with specific port is
called server socket. When a connection request arrives on this socket from the client side, the
client and the server establish a connection. This connection is established as follows:
The java.net package in the Java development environment provides the class Socket that
implements the client side and the class serverSocket class that implements the server side
sockets.
The client and the server must agree on a protocol. They must agree on the language of the
information transferred back and forth through the socket. There are two communication
protocols :
The stream communication protocol is known as TCP (transfer control protocol). TCP is a
connection-oriented protocol. It works as described in this document. In order to communicate
over the TCP protocol, a connection must first be established between two sockets. While one of
the sockets listens for a connection request (server), the other asks for a connection (client). Once
the two sockets are connected, they can be used to transmit and/or to receive data. When we say
\"two sockets are connected\" we mean the fact that the server accepted a connection. As it was
explained above the server creates a new local socket for the new connection. The process of the
new local socket creation, however, is transparent for the client.
The datagram communication protocol, known as UDP (user datagram protocol), is a
connectionless protocol. No connection is established before sending the data. The data are sent
in a packet called datagram. The datagram is sent like a request for establishing a connection.
However, the datagram contains not only the addresses, it contains the user data also. Once it
arrives to the destination the user data are read by the remote application and no connection is
established. This protocol requires that each time a datagram is sent, the local socket and the
remote socket addresses must also be sent in the datagram. These addresses are sent in each
datagram.
The java.net package in the Java development environment provides the class DatagramSocket
for programming datagram communications.
UDP is an unreliable protocol. There is no guarantee that the .
This document discusses network programming clients. It begins by defining clients and servers, explaining that clients initiate connections by specifying a host and port, while servers listen on a port without specifying a host. It then provides the basic steps for implementing a generic network client in Java: creating a socket, input and output streams, performing I/O, and closing the socket. Additional topics covered include parsing strings with StringTokenizer, an example client that verifies email addresses, and a MailAddress class to parse email addresses.
This document discusses creating network clients in Java. It covers creating sockets, implementing a generic network client, parsing data with StringTokenizer, retrieving files from HTTP servers and documents using URL class. It provides code for a generic network client, parsing strings with StringTokenizer, an address verifier client, and classes to retrieve URIs and URLs. It also briefly discusses talking to servers interactively and using the URL class to write a basic web browser.
The document discusses different types of sockets in Java network programming:
- TCP/IP client socket and TCP/IP server socket are used for reliable, bidirectional stream-based connections between hosts using TCP/IP. The client socket connects to the server socket.
- A Java DatagramSocket class represents a connectionless socket for sending and receiving datagram packets without reliability or sequencing. Commonly used DatagramSocket constructors are described.
- An example program is provided to demonstrate passing a message from a server to a client using sockets, showing the client and server code.
A socket is an endpoint for communication between two programs over a network. It represents a connection between a client program and a server program. The server runs on a specific machine and port, listening for connection requests from clients. Clients know the server's hostname and port number to request a connection. If accepted, the server gets a new socket to communicate with that client while listening for new connections, and the client can use its socket to communicate with the server. Sockets are identified by their paired IP addresses and port numbers to allow multiple connections. The Java Socket class implements sockets to allow platform-independent network communication between Java programs.
The document provides an overview of using Swift to connect to networked APIs. It defines what a networked API is and describes two common API styles: RPC and REST. It then discusses REST APIs in more detail, covering the Richardson Maturity Model, HATEOAS, and Fielding's requirements for REST. The document demonstrates making HTTP requests in Swift, including preparing URLs and requests, performing requests, and handling authorization. It also briefly discusses Protocol Buffers and building gRPC services in Swift.
Networking in java, Advanced programmingGera Paulos
This document provides an overview of networking concepts in Java. It discusses how Java makes network programming easier than C/C++. The java.net package contains classes and interfaces that handle low-level communication details. It supports both TCP and UDP network protocols. The document demonstrates how to create servers and sockets in Java to establish connections between clients and servers for communication. It also shows how to manipulate URLs to access resources on the web and process URL components.
This document provides an overview of network programming in Python. It discusses how Python allows both low-level socket access for building clients and servers as well as higher-level access to application protocols like FTP and HTTP. It then describes socket programming concepts like domains, types, protocols and functions for binding, listening, accepting, connecting, sending and receiving data. Simple client and server code examples are provided to demonstrate creating a basic socket connection between two programs. Finally, commonly used Python network modules for protocols like HTTP, FTP, SMTP and more are listed.
Explain how firms can benefit from forecastingexchange rates .docxhanneloremccaffery
Explain how firms can benefit from forecasting
exchange rates
Describe the common techniques used for
forecasting
Explain how forecasting performance can be
evaluated
explain how interval forecasts can be applied
APA format, minimum 3 sources
Paper will be a minimum of 650 and a maximum of 900 words.
(This includes title section, content, and references…in other
words the entire paper)
.
•POL201 •Discussions •Week 5 - DiscussionVoter and Voter Tu.docxhanneloremccaffery
• POL201 • Discussions • Week 5 - Discussion
Voter and Voter Turnout
Prepare: Prior to completing this discussion question, review Chapters 10, 11, and 12 in American Government and review Week Five Instructor Guidance. Also read the following articles: How Voter ID Laws Are Being Used to Disenfranchise Minorities and the Poor (Links to an external site.)Links to an external site., Fraught with Fraud (Links to an external site.)Links to an external site., and Proof at the Polls (Links to an external site.)Links to an external site.
Reflect: The U.S. has one of the lowest voter turnout rates among modern democratic political systems. One study ranks the U.S. 120th on a list of 169 nations compared on voter turnout (Pintor, Gratschew, & Sullivan, 2002). During the last decade, many initiatives have been undertaken to increase voter participation, yet concerns about the possibility of election fraud have also increased. Additionally, some political interests feel threatened by the increase in turnout among some traditionally low-turnout ethnic minorities. Several states have recently passed legislation imposing new registration and identification requirements. This has sparked debate about whether these are tactics intended to suppress turnout or to prevent fraud. Think about the media’s role in the election process and how both mass media and social media can impact the election process.
Write: In your initial post, summarize recent developments in several states enacting voter ID laws. Analyze and describe the pros and cons on both sides of the debate about these laws. Is voter fraud a major problem for our democracy or are some groups trying to make it harder for some segments of society to vote? What impact has the media (mass and social) had in influencing public opinion regarding voter ID laws? Draw your own conclusion about the debate over voter ID laws and justify your conclusions with facts and persuasive reasoning. Fully respond to all parts of the prompt and write your response in your own words. Your initial post must be at least 300 words. Support your position with at least two of the assigned resources required for this discussion, and/or peer reviewed scholarly sources obtained through the AU Library databases. Include APA in-text citations (Links to an external site.)Links to an external site. in the body of your post and full citations on the references list (Links to an external site.)Links to an external site. at the end. Support your position with APA citations from two or more of the assigned resources required for this discussion. Please be sure that you demonstrate understanding of these resources, integrate them into your argument, and cite them properly.
.
More Related Content
Similar to [Type text]ECET465Project 2Project Assignment 2 Building a Mul.docx
1. Sockets provide a connection between client and server programs that allows them to communicate over a network. A socket is bound to each end of the connection.
2. The Socket class implements client sockets and allows a client program to connect to a server, send and receive data, and close the connection. The ServerSocket class allows a server program to listen for connections on a port and accept sockets from clients.
3. When a client connects to a server, the server accepts the connection using ServerSocket and returns a Socket. The client and server can then communicate by getting input and output streams from the socket to send data over the connection according to the network protocol.
The Java Mail Server project allows clients to connect to a mail server to send and receive emails and attachments. The project is divided into three modules: a server module that uses server sockets to accept client connections, a client module that uses sockets to connect to the server, and an email inbox module that handles mail functions like forwarding, viewing attachments, and saving emails. The server stores details of client connections, mail sending and receiving. Clients can connect when the server is active to exchange emails with other clients. Usernames and passwords are stored in data files rather than a SQL server. The project provides automatic threading to handle socket connections and includes features for reliable TCP communication between clients.
The Presentation given at Guru Gobind Singh Polytechnic, Nashik for Third Year Information Technology and Computer Engineering Students on 08/02/2011.
Topic: Java Network Programming
Old Java lectures by my teacher Karim Zebari at Software Department College of Engineering University of Salahaddin-Erbil. The topics are:
- Multithreading
- Security in Java
- Java Beans
- Internationalization
- Java Servlets
- Java Server Pages
- Database access in Java
- More GUI Components & Printing
- Remote Method Invocation (RMI)
- Java Collections Framework
This document provides an overview of networking concepts in Java including:
1) It outlines topics on networking basics like IP addresses, ports, protocols and client-server interactions.
2) It describes how to write networking clients and servers using sockets.
3) It provides an example of writing a simple ICQ client-server application to demonstrate sockets.
4) It discusses communicating with web servers by retrieving and sending information using URLs and URLConnections.
This document provides an overview of networking concepts in Java including TCP/IP and UDP protocols, internet addressing, sockets, URLs, and how to implement client-server communication using TCP and UDP sockets. Key topics covered include the difference between TCP and UDP, how sockets connect applications to networks, internet addressing with IPv4 and IPv6, and examples of writing basic TCP and UDP client-server programs in Java.
This document provides a tutorial on network programming in Java. It introduces Java network programming and the HTTP protocol. It discusses how Java uses sockets to establish connections between clients and servers. It also describes the Java URL class, which makes it easier to work with HTTP connections by abstracting away the low-level socket implementation. The tutorial provides examples of both an HTTP client and server implemented in Java using sockets and the URL class.
This document describes how to create a simple chat room using Python sockets and threading. It involves running a server script that initializes a socket to listen for client connections on a specified port. When a client connects, the server creates a thread to handle communication with that client. The client script connects to the server socket and allows sending and receiving messages that are broadcast to all connected clients. The chat room can be used locally on a private network or accessed remotely over the internet using port forwarding.
The document provides an overview of object oriented programming and network programming concepts. It discusses topics like IP addresses, ports, sockets, client-server programming, and the java.net and java.util packages. The java.net package contains classes for network programming in Java like Socket, ServerSocket, URL, and InetAddress. The java.util package contains general-purpose utility classes like ArrayList, HashMap, Properties and Date.
The document discusses network programming and the client-server model. It covers:
- The client-server exchange involves a client sending a request, the server handling the request and sending a response, and the client handling the response.
- Sockets provide a programming interface that allows network I/O to appear as file I/O. Clients and servers communicate by reading from and writing to socket file descriptors.
- Servers run as long-running daemon processes, listening on well-known ports for connection requests from clients. When a request is received, the server accepts the connection to form a connected socket for bidirectional data exchange.
How a network connection is created A network connection is initi.pdfarccreation001
How a network connection is created ?
A network connection is initiated by a client program when it creates a socket for the
communication with the server. To create the socket in Java, the client calls the Socket
constructor and passes the server address and the the specific server port number to it. At this
stage the server must be started on the machine having the specified address and listening for
connections on its specific port number.
The server uses a specific port dedicated only to listening for connection requests from clients. It
can not use this specific port for data communication with the clients because the server must be
able to accept the client connection at any instant. So, its specific port is dedicated only to
listening for new connection requests. The server side socket associated with specific port is
called server socket. When a connection request arrives on this socket from the client side, the
client and the server establish a connection. This connection is established as follows:
The java.net package in the Java development environment provides the class Socket that
implements the client side and the class serverSocket class that implements the server side
sockets.
The client and the server must agree on a protocol. They must agree on the language of the
information transferred back and forth through the socket. There are two communication
protocols :
The stream communication protocol is known as TCP (transfer control protocol). TCP is a
connection-oriented protocol. It works as described in this document. In order to communicate
over the TCP protocol, a connection must first be established between two sockets. While one of
the sockets listens for a connection request (server), the other asks for a connection (client). Once
the two sockets are connected, they can be used to transmit and/or to receive data. When we say
\"two sockets are connected\" we mean the fact that the server accepted a connection. As it was
explained above the server creates a new local socket for the new connection. The process of the
new local socket creation, however, is transparent for the client.
The datagram communication protocol, known as UDP (user datagram protocol), is a
connectionless protocol. No connection is established before sending the data. The data are sent
in a packet called datagram. The datagram is sent like a request for establishing a connection.
However, the datagram contains not only the addresses, it contains the user data also. Once it
arrives to the destination the user data are read by the remote application and no connection is
established. This protocol requires that each time a datagram is sent, the local socket and the
remote socket addresses must also be sent in the datagram. These addresses are sent in each
datagram.
The java.net package in the Java development environment provides the class DatagramSocket
for programming datagram communications.
UDP is an unreliable protocol. There is no guarantee that the .
This document discusses network programming clients. It begins by defining clients and servers, explaining that clients initiate connections by specifying a host and port, while servers listen on a port without specifying a host. It then provides the basic steps for implementing a generic network client in Java: creating a socket, input and output streams, performing I/O, and closing the socket. Additional topics covered include parsing strings with StringTokenizer, an example client that verifies email addresses, and a MailAddress class to parse email addresses.
This document discusses creating network clients in Java. It covers creating sockets, implementing a generic network client, parsing data with StringTokenizer, retrieving files from HTTP servers and documents using URL class. It provides code for a generic network client, parsing strings with StringTokenizer, an address verifier client, and classes to retrieve URIs and URLs. It also briefly discusses talking to servers interactively and using the URL class to write a basic web browser.
The document discusses different types of sockets in Java network programming:
- TCP/IP client socket and TCP/IP server socket are used for reliable, bidirectional stream-based connections between hosts using TCP/IP. The client socket connects to the server socket.
- A Java DatagramSocket class represents a connectionless socket for sending and receiving datagram packets without reliability or sequencing. Commonly used DatagramSocket constructors are described.
- An example program is provided to demonstrate passing a message from a server to a client using sockets, showing the client and server code.
A socket is an endpoint for communication between two programs over a network. It represents a connection between a client program and a server program. The server runs on a specific machine and port, listening for connection requests from clients. Clients know the server's hostname and port number to request a connection. If accepted, the server gets a new socket to communicate with that client while listening for new connections, and the client can use its socket to communicate with the server. Sockets are identified by their paired IP addresses and port numbers to allow multiple connections. The Java Socket class implements sockets to allow platform-independent network communication between Java programs.
The document provides an overview of using Swift to connect to networked APIs. It defines what a networked API is and describes two common API styles: RPC and REST. It then discusses REST APIs in more detail, covering the Richardson Maturity Model, HATEOAS, and Fielding's requirements for REST. The document demonstrates making HTTP requests in Swift, including preparing URLs and requests, performing requests, and handling authorization. It also briefly discusses Protocol Buffers and building gRPC services in Swift.
Networking in java, Advanced programmingGera Paulos
This document provides an overview of networking concepts in Java. It discusses how Java makes network programming easier than C/C++. The java.net package contains classes and interfaces that handle low-level communication details. It supports both TCP and UDP network protocols. The document demonstrates how to create servers and sockets in Java to establish connections between clients and servers for communication. It also shows how to manipulate URLs to access resources on the web and process URL components.
This document provides an overview of network programming in Python. It discusses how Python allows both low-level socket access for building clients and servers as well as higher-level access to application protocols like FTP and HTTP. It then describes socket programming concepts like domains, types, protocols and functions for binding, listening, accepting, connecting, sending and receiving data. Simple client and server code examples are provided to demonstrate creating a basic socket connection between two programs. Finally, commonly used Python network modules for protocols like HTTP, FTP, SMTP and more are listed.
Similar to [Type text]ECET465Project 2Project Assignment 2 Building a Mul.docx (20)
Explain how firms can benefit from forecastingexchange rates .docxhanneloremccaffery
Explain how firms can benefit from forecasting
exchange rates
Describe the common techniques used for
forecasting
Explain how forecasting performance can be
evaluated
explain how interval forecasts can be applied
APA format, minimum 3 sources
Paper will be a minimum of 650 and a maximum of 900 words.
(This includes title section, content, and references…in other
words the entire paper)
.
•POL201 •Discussions •Week 5 - DiscussionVoter and Voter Tu.docxhanneloremccaffery
• POL201 • Discussions • Week 5 - Discussion
Voter and Voter Turnout
Prepare: Prior to completing this discussion question, review Chapters 10, 11, and 12 in American Government and review Week Five Instructor Guidance. Also read the following articles: How Voter ID Laws Are Being Used to Disenfranchise Minorities and the Poor (Links to an external site.)Links to an external site., Fraught with Fraud (Links to an external site.)Links to an external site., and Proof at the Polls (Links to an external site.)Links to an external site.
Reflect: The U.S. has one of the lowest voter turnout rates among modern democratic political systems. One study ranks the U.S. 120th on a list of 169 nations compared on voter turnout (Pintor, Gratschew, & Sullivan, 2002). During the last decade, many initiatives have been undertaken to increase voter participation, yet concerns about the possibility of election fraud have also increased. Additionally, some political interests feel threatened by the increase in turnout among some traditionally low-turnout ethnic minorities. Several states have recently passed legislation imposing new registration and identification requirements. This has sparked debate about whether these are tactics intended to suppress turnout or to prevent fraud. Think about the media’s role in the election process and how both mass media and social media can impact the election process.
Write: In your initial post, summarize recent developments in several states enacting voter ID laws. Analyze and describe the pros and cons on both sides of the debate about these laws. Is voter fraud a major problem for our democracy or are some groups trying to make it harder for some segments of society to vote? What impact has the media (mass and social) had in influencing public opinion regarding voter ID laws? Draw your own conclusion about the debate over voter ID laws and justify your conclusions with facts and persuasive reasoning. Fully respond to all parts of the prompt and write your response in your own words. Your initial post must be at least 300 words. Support your position with at least two of the assigned resources required for this discussion, and/or peer reviewed scholarly sources obtained through the AU Library databases. Include APA in-text citations (Links to an external site.)Links to an external site. in the body of your post and full citations on the references list (Links to an external site.)Links to an external site. at the end. Support your position with APA citations from two or more of the assigned resources required for this discussion. Please be sure that you demonstrate understanding of these resources, integrate them into your argument, and cite them properly.
.
•No less than 4 pages causal argument researched essay •In.docxhanneloremccaffery
•
No less than 4 pages causal argument researched essay
•
Includes an interview with an expert from a university
•
Includes survey question with students concerning the topic
•
Includes arguments from official sources from the library
.
•Focus on two or three things in the Mesopotamian andor Ovids ac.docxhanneloremccaffery
•Focus on two or three things in the Mesopotamian and/or Ovid's account of creation that differ from Genesis. How do they differ? What is the significance of these differences?
•Focus on two or three things in the Mesopotamian and/or
Ovid's account of the flood that differ from Genesis. How do they differ? What is the significance of these differences
.
•Langbein, L. (2012). Public program evaluation A statistical guide.docxhanneloremccaffery
•Langbein, L. (2012). Public program evaluation: A statistical guide (2nd ed.). Armonk, NY: ME Sharpe. ◦Chapter 7, “Designing Useful Surveys for Evaluation” (pp. 209–238)
•McDavid, J. C., Huse, I., & Hawthorn, L. R. L. (2013). Program evaluation and performance measurement: An introduction to practice (2nd ed.). Thousand Oaks, CA: Sage. ◦Chapter 4, “Measurement for Program Evaluation and Performance Monitoring” (pp. 145–185)
•Geddes, B. (1990). How the cases you choose affect the answers you get: Selection bias in comparative politics. Political Analysis, 2(1), 131–150. Retrieved from http://www.uky.edu/~clthyn2/PS671/Geddes_1990PA.pdf
•Levitt, S., & List, J. (2009). Was there really a Hawthorne effect at the Hawthorne plant? An analysis of the original illumination experiments. Retrieved from http://www.nber.org/papers/w15016.pdf
•Urban Institute. (2014). Outcome indicators project. Retrieved from http://www.urban.org/center/cnp/projects/outcomeindicators.cfm
•Bamberger, M. (2010). Reconstructuring baseline data for impact evaluation and results measurement. Retrieved from http://siteresources.worldbank.org/INTPOVERTY/Resources/335642-1276521901256/premnoteME4.pdf
•Parnaby, P. (2006). Evaluation through surveys [Blog post]. Retrieved from http://www.idea.org/blog/2006/04/01/evaluation-through-surveys/
•Rutgers, New Jersey Agricultural Experiment Station. (2014). Developing a survey instrument. Retrieved from http://njaes.rutgers.edu/evaluation/resources/survey-instrument.asp
•MEASURE Evaluation. (n.d.). Secondary analysis of data. Retrieved February 24, 2015, from http://www.cpc.unc.edu/measure/our-work/secondary-analysis/secondary-analysis-of-data
•Zeitlin, A. (2014). Sampling and sample size [PowerPoint slides]. Retrieved from http://www.povertyactionlab.org/sites/default/files/2.%20Sampling%20and%20Sample%20Size_AFZ3.pdf
Now that you have thought through a logical model or framework for your Final Project, it is time to develop preliminary input, output, and outcome indicators. For this Assignment, use the guidelines from the Urban Institute resource and consult relevant Optional Resources from this week.
Submit a 2- to 3-page paper which describes your input, output, and outcome program indicators, including the following:
•Describe the variables and the data you will be using.
•Provide a realistic discussion of the availability of research data.
•Provide an analysis of intended data collection strategies.
◦If a sample or sample survey will be used, discuss the sampling frame or the sampling strategy you intend to use.
.
•Chapter 10 Do you think it is possible for an outsider to accura.docxhanneloremccaffery
•Chapter 10: Do you think it is possible for an outsider to accurately discern about the underlying cultural values of an organization by analyzing symbols, ceremonies, dress, or other observable aspects of culture in comparison to an insider with several years of work experience? Select a percentage (e.g., 10%, 70%, etc.) and explain your reasoning.
•Chapter 11: A noted organization theorist once said, "Pressure for change originates in the environment. Pressure for stability originates within the organization." Do you agree?
•Chapter 12: If managers frequently use experience and intuition to make complex, non-programmed decisions, how do they apply evidence-based management (which seems to suggest that managers should rely on facts and data)?
•Chapter 13: In a rapidly changing organization, are decisions more likely to be made using the rational or political model of organization?
•What biblical implications should be included/addressed?
•How can/should a biblical worldview be applied?
Group Discussion Board Forum Thread Grading Rubric
Criteria
Points Possible
Points Earned
Thread
0 to 30 points
All questions associated with Part 1 are provided in a thread.
At least 4 peer-reviewed references are included in the thread.
The thread is 1200 words.
The thread is posted by the stated deadline.
Spelling and grammar are correct.
Sentences are complete, clear, and concise.
Total
.
· Bakit Di gaanong kaganda ang pagturo sa UST sa panahon.docxhanneloremccaffery
·
Bakit
Di gaanong kaganda ang pagturo sa UST sa panahon ni Jose Rizal
·
bakit
Merong diskriminasyon; minamaliit ang mga Pilipinosa panahon ni Jose Rizal
·
bakit
Galit sa kay Jose Rizal ang mga Dominikano dahil sa pagtatatag ng Companerismo (Fraternity)
·
bakit
Gustong gamutin ni Jose Rizal ang ina niya
.
·YOUR INDIVIDUAL PAPER IS ARGUMENTATIVE OR POSITIONAL(Heal.docxhanneloremccaffery
·
YOUR INDIVIDUAL PAPER IS ARGUMENTATIVE OR POSITIONAL
(Healthcare Information Technology)
THIS is NOT and information paper so please read this carefully
Individual Writing Assignment
This Individual Writing Assignment is worth 20 points, and it is due at the end of Week 5.
The purposes of this assignment are to a) help you effectively use research resources through library data bases and search engines to complete course requirements; b) improve your critical thinking skills, and c) develop your effectiveness in writing about topics relevant to course objectives and healthcare information systems. The paper explores, in greater detail than the required readings and class discussion, any healthcare information system topic identified in the course text or syllabus. Your job is to select a current issue in healthcare information systems, provide the necessary background and your position, along with a conclusion and future direction. I encourage you to select a subject in which you have interest and approach this assignment as a potential publishable work.
Position Paper
Your final paper is 15 pages double-spaced (excluding the executive summary, footnotes, and references) with a 10 or 12 point font. Tables, graphics, and diagrams must be placed in the paper as attachments. They do not count in the page length. This is a guide to help you organize your content and what is expected in each section. The page counts are suggested, however, where they have a limit, that must be adhered to.
·
Cover Page:
APA Style (1 Page, not included in page count)
·
Table of Contents:
(not included in page count)
·
Executive Summary:
Bottom line up front (1 page, no more)
·
Introduction
: (1/2 to 1 page)
·
Background
: Information on the topic that provides context so readers can understand the background leading into your statement and analysis of the issue (up to 2 pages, no more)
·
Analysis of the issue
: This is the problem you see with the current state of your topic supported by evidence and literature that brings validity to the issue or problem you are stating exists. Then describe the factors contributing to the issue /problem broken down by (2-3 pages)
People
Processes
Technology
·
Position
: Now that the reader understands the problem broken down by people, process, and technology, provide a clear statement of what your position is on the issue and why. (1/2 to 1 page)
·
Rationale
: Now that the reader clearly understands your position and why you will detail your position with supporting evidence and literature to persuade the reader your position is the most valid. You should address opposing views with counter arguments here also. Your position should have evidence directly addressing the issues you stated above broken down by the same (3-4 pages)
People
Process
Technology
·
Recommendation
: Now that you have convinced the reader on your position being the best way forward, you need to provide 3-5 discrete recommen.
·Write a 750- to 1,Write a 750- to 1,200-word paper that.docxhanneloremccaffery
·
Write
a 750- to 1,
Write
a 750- to 1,200-word paper that addresses the following:
Define religion.
Describe the theory of animism.
Explain the influence of religion on cultures.
Identify the seven major religions of the world.
Describe any four types of theism.
Format
your paper consistent with APA guidelines.
Include
a minimum of five references.
Limit
direct quotes to less than 10% of the total manuscript.
Criteria for grading
·
Introduction provides sufficient background on the topic and previews major points
·
Define religion
·
Describe the theory of animism
·
Explain the influence of religion on cultures (e.g., architecture, art, politics, social norms, etc.)
·
Identify the seven major religions of the world and provide one or two sentences about each
·
Describe any four types of theism (e.g., atheism, monotheism, ditheism, polytheism, pantheism, etc.) and provide an example of each
·
Conclusion
.
[Type here]Ok. This school makes me confused. The summary of t.docxhanneloremccaffery
[Type here]
Ok. This school makes me confused. The summary of this week they posted like this:
SUMMARY:
This week introduced you to grand theories and middle-range theories that serve to articulate the voice of nursing within healthcare.
Here are the key points covered:
Grand theories are comparatively more abstract than middle-range theories since they are at a higher level of abstraction. Compared to grand theories, middle-range theories are made up of limited number of concepts that lend themselves to empirical testing. All theories help to explain human health behavior.
· Sister Callista Royï's adaptive model theory is built on the conceptual foundation of adaptation. It identifies the positive role that nursing plays in the promotion and enhancement of client adaptation to environments that facilitate the healing process.
· Leiningerï's culture care theory is pertinent in the current multicultural healthcare environment where nurses are exposed to diverse cultures.
· Penderï's health promotion and disease prevention theory can be called as a "direction setting exercise" for nursing professionals. It believes in fostering the spirit of health promotion and disease and risk reduction.
From the chapter, Models and Theories Focused on Nursing Goals and Functions, read the following:The Health Promotion Model: Nola J. Pender
From the chapter, Models and Theories Focused on a Systems Approach, read the following:
The Roy Adaptation Model
From the chapter, Models and Theories Focused on Culture, read the following:
Leininger's Cultural Care Diversity and Universality Theory and Model
SO, THAT IS WHY I ASSUMED THAT HAS TO BE ONE OF THEM (Pender, Roy Adaptaion or Leininger)
ANYWAY, I AM PUTTING INFORMATION TOGETHER.
Week 4 Chapter 17
Models and Theories Focused on Nursing Goals and Functions
The Health Promotion Model: Nola J. Pender
Background
Nola J. Pender was born in 1941 in Lansing, Michigan. She graduated in 1962 with a diploma in nursing. In 1964, Pender completed a bachelor’s of science in nursing at Michigan State University. By 1969, she had completed a doctor of philosophy in psychology and education. During this time in her career, Pender began looking at health and nursing in a broad way, including defining the goal of nursing care as optimal health.
In 1975, Pender published a model for preventive health behavior; her health promotion model first appeared in the first edition of the text Health Promotion in Nursing Practice in 1982. Pender’s health promotion model has its foundation in Albert Bandura’s (1977) social learning theory (which postulates that cognitive processes affect behavior change) and is influenced by Fishbein’s (1967) theory of reasoned action (which asserts that personal attitudes and social norms affect behavior).
Pender’s Health Promotion Model
McCullagh (2009) labeled Pender’s health promotion model as a middle-range integrative theory, and rightly so. Fawcett (2005) decisively presented the differenc.
{
Discrimination
*
GENERAL DISCRIMINATION
+
RACIAL DISCRIMINATION
RELIGIOUS DISCRIMINATION
(on freedom of religion)
DISCRIMINATION ON SEXUAL ORIENTATION
(still weak protection)
GENDER DISCRIMINATION
(CEDAW)
TYPES OF DISCRIMINATION
NON-DISCRIMINATION in INT’L LAW
A. GENERAL DISCRIMINATION
Arts 1 & 2 Universal Declaration on Human Rights
Arts. 2 & 26 ICCPR
Art. 14 ECHR & Add. Protocol 12
B. RACIAL DISCRIMINATION
Int’l Convention against All Forms of Racial Discrimination (ICERD)
Art . 2: (1). Each State Party to the present Covenant undertakes to respect and to ensure to all individuals within its territory and subject to its jurisdiction the rights recognized in the present Covenant, without distinction of any kind, such as race, colour, sex, language, religion, political or other opinion, national or social origin, property, birth or other status.
(2). States to take the necessary steps to adopt laws and measures to give effect to art. 2;
(3). States to ensure effective remedy, determined by competent judicial, administrative or legislative authorities, or by any other competent authority and enforce such remedies.
Art. 26: non-discrimination before the law and equal protection by the law
ICCPR
*
Justification for differential treatment
General Comment 18 HRC
Not every differentiation of treatment will constitute discrimination:
if the criteria are reasonable and objective
and the aim is to achieve the purpose which is legitimate
ICCPR cont.
*
“Racial discrimination" shall mean any distinction, exclusion, restriction or preference based on race, colour, descent, or national or ethnic origin which has the purpose or effect of nullifying or impairing the recognition, enjoyment or exercise, on an equal footing, of human rights and fundamental freedoms in the political, economic, social, cultural or any other field of public life (art. 1)
States Parties particularly condemn racial segregation and apartheid and undertake to prevent, prohibit and eradicate all practices of this nature in territories under their jurisdiction (art. 3)
RACIAL DISCRIMINATION-
International Convention on the Elimination of All Forms of Racial Discrimination
Direct discrimination: Indirect discrimination
Formal equality: Substantive equality
Discrimination in law: Discrimination in practice
Non-discrimination: negative protection
Equality: positive obligations -> special measures
Is there a hierarchy in the protection of discrimination?
Racial Discrimination (prohibition Jus Cogens);
gender based discrimination?
Religious-based discrimination??
Discrimination based on sexual orientation???
Discrimination (forms & grounds)
= Affirmative action/ positive action
Article 1.4 of ICERD:
Special measures taken for the sole purpose of securing adequate advancement of certain racial or ethnic groups or individuals requiring such protection as may be necessary in order to ensure such groups or in.
`HISTORY 252AEarly Modern Europe from 1500 to 1815Dr. Burton .docxhanneloremccaffery
`HISTORY 252A
Early Modern Europe from 1500 to 1815
Dr. Burton Van Name Edwards (Van)
Tuesday – Thursday 3:30-4:45
Unistructure 247
Third Paper Assignment
Due Tuesday, December 13th
The third paper will be based on a book in the list at the end of the syllabus. These works are generally works of literature, with some concerned with philosophy or politics. The student’s task will be to show how the chosen work reflects or shows the influence of conditions and events in Europe that were operating at the time of the writing of the work. This is not a book report. I am not interested in plots or descriptions of the general argument of a given work. Instead, I am looking for an analysis of specific sections of the chosen work that may illuminate social and economic attitudes or contemporaneous conditions.
The paper should be 7-8 pages long.
You will be expected to give a 5-10 minute oral report based on your finding in the third paper. This oral report will be a significant part of your class participation grade.
.
^ Acadumy of Management Journal2001. Vol. 44. No. 2. 219-237.docxhanneloremccaffery
^ Acadumy of Management Journal
2001. Vol. 44. No. 2. 219-237.
A SOCIAL CAPITAL THEORY OF CAREER SUCCESS
SCOTT E. SEIBERT
MARIA L. KRAIMER
•̂ ' ' ' Cleveland State University
ROBERT C. LIDEN
University of Illinois at Chicago
A model integrating competing theories of social capital with research on career
success was developed and tested in a sample of 448 employees with various occupa-
tions and organizations. Social capital was conceptualized in terms of network struc-
ture and social resources. Results of structural equation modeling showed that net-
work structure was related to social resources and that the effects of social resources
on career success were hilly mediated by three network benelits: access to information,
access to resources, and career sponsorship.
Organizational researchers have begun to de-
velop increasingly comprehensive models of career
success using demographic, human capital, work-
family, motivational, organizational, and industry
variables (e.g., Dreher & Ash, 1990; Judge & Bretz,
1994: Judge, Cable. Boudreau, & Bretz. 1995; Kirch-
meyer, 1998). Although this work has provided
considerable evidence regarding the determinants
of career outcomes, the roles of informal interper-
sonal behaviors have not been fully explored (Judge
& Bretz, 1994; Pfeffer, 1989). Popular advice for
getting ahead in one's career rarely fails to mention
the importance of networking for the achievement
of career goals (e.g., Bolles, 1992; Kanter, 1977).
Indeed, Luthans, Hodgetts, and Rosenkrantz (1988)
found that the most successful managers in their
study spent 70 percent more time engaged in net-
working activities and 10 percent more time en-
gaged in routine communication activities than
their less successful counterparts. Recent advances
in social capital theory (Coleman, 1990) have begun
to provide a finer-grained analysis of the ways in-
dividuals' social networks affect their careers in
organizations (Burt, 1992, 1997; Ibarra, 1995;
Podolny & Baron, 1997; Sparrowe & Popielarz,
1995). This theoretical perspective has the poten-
Data were collected and the manuscript was submitted
and processed while Scott E. Seibert was in the Manage-
ment Department at the University of Notre Dame and
Maria L. Kraimer was a graduate student at the Univer-
sity of Illinois at Chicago. Support for this project was
provided by the Management Department at the Univer-
sity of Notre Dame and the Alumni Office of the Univer-
sity of Notre Dame. The current investigation is part of a
larger study of career success.
tial to considerably enhance scholars' knowledge of
the role of social processes in career success.
The first purpose of the current study was to
integrate the current conceptualizations of social
capital as they pertain to career success. Tbree dif-
ferent theoretical approaches—weak tie theory
(Granovetter, 1973), structural hole theory (Burt,
1992), and social resource theory (Lin, 1990)—
focus on different network properties as r.
`
Inclusiveness. The main difference that can distinguish a happy employee from disgruntled employee. As with all decisions that are made, there is always an audience that the decision will affect. When employees are privy and organizational decisions are inclusive to employees this can greatly increase their level of fulfillment. Whether or not the end user of the decision will be content with the outcome or not, there will always be critics. Which leads us to discuss key characteristics and the importance of involving employees in relative organizational decision making.
It is not uncommon to find that during strategic organizational planning that top-level management will include their employees to engage and provide their input on complex processes. Human capital, whether the organization is large or small, corporate ran or small business managed is key to an organization’s success. Employee satisfaction level drives productivity and is what increases revenue for the company. Happy employees equal happy customers.
What does it take to keep employees motivated? A critical and important element for employers to keep their employees happy and content is clear communication. It is critical that an organization’s objective and vision for future growth is communicated clearly throughout all levels. Top-level management must be skilled at delivering the company’s mission and values to every tier within their organization. Each tier within the organization with healthy communication should be able to open-mindedly accept the message and freely provide any feedback positive or negative without fear of repercussion. Keeping an open line of communication within an organization is key to building the foundation for success.
As we move away from the golden days of traditional office operations consisting of fax machines, telephones, paper, pencils, etc. and move towards a more technologically repertoire, we lose the personable face to face interaction with one another. We spend most of the day behind our computer screen at our desk. The need to sustain job satisfaction amongst employees could not be ever more present than now. To maintain the morale amongst employees, organizations should be able to keep them challenged and motivated. Take technology for example. If the increase of new technology isn’t daunting enough, consider the challenge to remain current with technology all the while maintaining a competitive advantage in the industry? Reach internally to our internal resource, human capital. Employees must be given the opportunity to share their knowledge, skills, and abilities. When empowered to provide input concerning highly visible organizational decisions, employee morale is boosted. Not only is this beneficial for employees but also the employer as they receive ideas and input that could possibly lead to the solution. Employee engagement boosts the overall welfare of the organization.
According to.
__MACOSX/Sujan Poster/._CNA320 Poster Presentation rubric.pdf
__MACOSX/Sujan Poster/._CNA320+Poster+Template (1).ppt
__MACOSX/Sujan Poster/._Helpful Hints for the Poster Presentation.docx
Sujan Poster/Poster Abstract - Aspiration pneumonia (1).docx
Title: Aspiration pneumonia: Best practice to avoid complications
Background
Aspiration pneumonia is a lung infection due to inhaled contents; this is a relevant topic because aspiration pneumonia is prevalent and accounts for up to 15% of all pneumonia cases and is particularly common in older people, and thus it is important for nurses to be aware of how to manage the condition particularly as the population is ageing so this will be of more concern (Kwong, Howden & Charles 2011).
Target Audience
The target audience for this presentation is experienced Registered Nurses and thus the presentation has been designed for this group.
Main Findings
Aspiration pneumonia is an infection within the lungs that occurs after a person aspirates either liquid, vomit or food into the larynx and lower respiratory tract; this can occur when an individual inhales their gastric or oral contents. Patients at risk include individuals who are elderly or those who have a marked disturbance of consciousness such as that resulting from a drug overdose, seizures, a massive cerebrospinal accident, dysphagia or dysphasia (Kwong, Howden & Charles 2011). Aspiration pneumonia can quickly develop into respiratory failure, abscess and empyema and this requires supportive care, which is the main form of therapy, however prophylactic antimicrobial therapy is also often prescribed (Joundi, Wong & Leis 2015). Best practice suggests suctioning, supplemental oxygen to keep O2 above 90%, septic shock therapy, management of hypotension and antibiotic therapy for 7-10 days. Sputum cultures should be taken so that antibiotics can be tailored appropriately (McAdams-Jones & Sundar 2012).
Implications for Practice
These findings are important for registered nurses to be aware of so that aspiration pneumonia can be managed appropriately and complications can be avoided, which could cause increased hospital stay and costs. Nurses need to be aware of the best practice recommendations such as oxygen supplementation, sit up while eating, provide thickened foods and drinks, dental care and about taking sputum cultures when managing aspiration pneumonia so that treatment can be tailored appropriately and recovery can occur quickly.
Feedback from marker (Teacher)
Thank you for your abstract.
You have just managed a pass grade, your work is very basic and you will need to engage with the basic practice literature to ensure you have a comprehensive understanding of this topic in your poster.
I am also unclear on your focus, is this about prevention of aspiration or management once it has occurred or both?
Kind regards Andrea
Sources of Evidence
Joundi, R, Wong, B & Leis, J 2015, "Antibiotics “Just-In-Ca.
A workshop hosted by the South African Journal of Science aimed at postgraduate students and early career researchers with little or no experience in writing and publishing journal articles.
Assessment and Planning in Educational technology.pptxKavitha Krishnan
In an education system, it is understood that assessment is only for the students, but on the other hand, the Assessment of teachers is also an important aspect of the education system that ensures teachers are providing high-quality instruction to students. The assessment process can be used to provide feedback and support for professional development, to inform decisions about teacher retention or promotion, or to evaluate teacher effectiveness for accountability purposes.
বাংলাদেশের অর্থনৈতিক সমীক্ষা ২০২৪ [Bangladesh Economic Review 2024 Bangla.pdf] কম্পিউটার , ট্যাব ও স্মার্ট ফোন ভার্সন সহ সম্পূর্ণ বাংলা ই-বুক বা pdf বই " সুচিপত্র ...বুকমার্ক মেনু 🔖 ও হাইপার লিংক মেনু 📝👆 যুক্ত ..
আমাদের সবার জন্য খুব খুব গুরুত্বপূর্ণ একটি বই ..বিসিএস, ব্যাংক, ইউনিভার্সিটি ভর্তি ও যে কোন প্রতিযোগিতা মূলক পরীক্ষার জন্য এর খুব ইম্পরট্যান্ট একটি বিষয় ...তাছাড়া বাংলাদেশের সাম্প্রতিক যে কোন ডাটা বা তথ্য এই বইতে পাবেন ...
তাই একজন নাগরিক হিসাবে এই তথ্য গুলো আপনার জানা প্রয়োজন ...।
বিসিএস ও ব্যাংক এর লিখিত পরীক্ষা ...+এছাড়া মাধ্যমিক ও উচ্চমাধ্যমিকের স্টুডেন্টদের জন্য অনেক কাজে আসবে ...
This slide is special for master students (MIBS & MIFB) in UUM. Also useful for readers who are interested in the topic of contemporary Islamic banking.
Thinking of getting a dog? Be aware that breeds like Pit Bulls, Rottweilers, and German Shepherds can be loyal and dangerous. Proper training and socialization are crucial to preventing aggressive behaviors. Ensure safety by understanding their needs and always supervising interactions. Stay safe, and enjoy your furry friends!
Physiology and chemistry of skin and pigmentation, hairs, scalp, lips and nail, Cleansing cream, Lotions, Face powders, Face packs, Lipsticks, Bath products, soaps and baby product,
Preparation and standardization of the following : Tonic, Bleaches, Dentifrices and Mouth washes & Tooth Pastes, Cosmetics for Nails.
Main Java[All of the Base Concepts}.docxadhitya5119
This is part 1 of my Java Learning Journey. This Contains Custom methods, classes, constructors, packages, multithreading , try- catch block, finally block and more.
हिंदी वर्णमाला पीपीटी, hindi alphabet PPT presentation, hindi varnamala PPT, Hindi Varnamala pdf, हिंदी स्वर, हिंदी व्यंजन, sikhiye hindi varnmala, dr. mulla adam ali, hindi language and literature, hindi alphabet with drawing, hindi alphabet pdf, hindi varnamala for childrens, hindi language, hindi varnamala practice for kids, https://www.drmullaadamali.com
Macroeconomics- Movie Location
This will be used as part of your Personal Professional Portfolio once graded.
Objective:
Prepare a presentation or a paper using research, basic comparative analysis, data organization and application of economic information. You will make an informed assessment of an economic climate outside of the United States to accomplish an entertainment industry objective.
Introduction to AI for Nonprofits with Tapp NetworkTechSoup
Dive into the world of AI! Experts Jon Hill and Tareq Monaur will guide you through AI's role in enhancing nonprofit websites and basic marketing strategies, making it easy to understand and apply.
How to Add Chatter in the odoo 17 ERP ModuleCeline George
In Odoo, the chatter is like a chat tool that helps you work together on records. You can leave notes and track things, making it easier to talk with your team and partners. Inside chatter, all communication history, activity, and changes will be displayed.
How to Manage Your Lost Opportunities in Odoo 17 CRMCeline George
Odoo 17 CRM allows us to track why we lose sales opportunities with "Lost Reasons." This helps analyze our sales process and identify areas for improvement. Here's how to configure lost reasons in Odoo 17 CRM
[Type text]ECET465Project 2Project Assignment 2 Building a Mul.docx
1. [Type text] ECET465
Project 2Project Assignment 2: Building a Multi-Threaded Web
Server
This project assignment is due at the end of the seventh week of
the course and is worth 7% of your total grade.
In this project, we will develop a Web server in two steps. In
the end, you will have built a multi-threaded Web server that is
capable of processing multiple simultaneous service requests in
parallel. Section 2.7 of your text may offer you some insight
and help. You should be able to demonstrate that your Web
server is capable of delivering your home page to a Web
browser.
We are going to implement Version 1.0 of HTTP, as defined in
RFC 1945, where separate HTTP requests are sent for each
component of the Web page. The server will be able to handle
multiple simultaneous service requests in parallel. This means
that the Web server is multi-threaded. In the main thread, the
server listens to a fixed port. When it receives a TCP
connection request, it sets up a TCP connection through another
port and services the request in a separate thread. To simplify
this programming task, we will develop the code in two stages.
In the first stage, you will write a multi-threaded server that
simply displays the contents of the HTTP request message that
it receives. After this program is running properly, you will add
the code required to generate an appropriate response.
As you are developing the code, you can test your server from a
Web browser. Just remember that you are not serving through
the standard port 80, so you need to specify the port number
within the URL that you give to your browser. For example, if
your machine's name is host.someschool.edu, your server is
listening to port 6789, and you want to retrieve the file
index.html, then you would specify the following URL within
the browser: http://host.someschool.edu:6789/index.html
If you omit ":6789," the browser will assume port 80, which
2. most likely will not have a server listening on it.
When the server encounters an error, it sends a response
message with the appropriate HTML source so that the error
information is displayed in the browser window.
Web Server in Java: Part A
In the following steps, we will go through the code for the first
implementation of our Web server. Wherever you see "?," you
will need to supply a missing detail.
Our first implementation of the Web server will be multi-
threaded, where the processing of each incoming request will
take place inside a separate thread of execution. This allows the
server to service multiple clients in parallel, or to perform
multiple file transfers to a single client in parallel. When we
create a new thread of execution, we need to pass to the
Thread's constructor an instance of some class that implements
the Runnable interface. This is the reason why we define a
separate class called HttpRequest. The structure of the Web
server is shown below: import java.io.* ;import java.net.*
;import java.util.* ;public final class WebServer{ public static
void main(String argv[]) throws Exception { . . .
}}final class HttpRequest implements Runnable{ . . .}
Normally, Web servers process service requests that they
receive through well-known Port #80. You can choose any port
higher than 1024, but remember to use the same port number
when making requests to your Web server from your browser.
public static void main(String argv[]) throws Exception{ //
Set the port number. int port = 6789; . . .}
Next, we open a socket and wait for a TCP connection request.
Since we will be servicing request messages indefinitely, we
place the listen operation inside of an infinite loop. This means
that we will have to terminate the Web server by pressing ^C on
the keyboard. // Establish the listen socket. ?// Process
HTTP service requests in an infinite loop.while (true) { //
Listen for a TCP connection request. ? . . .}
When a connection request is received, we create an
3. HttpRequest object, passing to its constructor a reference to the
Socket object that represents our established connection with
the client. // Construct an object to process the HTTP request
message.HttpRequest request = new HttpRequest( ? );// Create a
new thread to process the request.Thread thread = new
Thread(request);// Start the thread.thread.start();
In order to have the HttpRequest object handle the incoming
HTTP service request in a separate thread, we first create a new
Thread object, passing to its constructor a reference to the
HttpRequest object, and then call the thread's start() method.
After the new thread has been created and started, execution in
the main thread returns to the top of the message processing
loop. The main thread will then block, waiting for another TCP
connection request, while the new thread continues running.
When another TCP connection request is received, the main
thread goes through the same process of thread creation
regardless of whether the previous thread has finished execution
or is still running.
This completes the code in main(). For the remainder of the lab,
it remains to develop the HttpRequest class.
We declare two variables for the HttpRequest class: CRLF and
socket. According to the HTTP specification, we need to
terminate each line of the server's response message with a
carriage return (CR) and a line feed (LF), so we have defined
CRLF as a convenience. The variable socket will be used to
store a reference to the connection socket, which is passed to
the constructor of this class. The structure of the HttpRequest
class is shown below: final class HttpRequest implements
Runnable{ final static String CRLF = "rn"; Socket
socket; // Constructor public HttpRequest(Socket socket)
throws Exception { this.socket = socket;} //
Implement the run() method of the Runnable interface. public
void run() { . . . } private void processRequest()
throws Exception { . . . }}
In order to pass an instance of the HttpRequest class to the
Thread's constructor, HttpRequest must implement the Runnable
4. interface, which simply means that we must define a public
method called run() that returns void. Most of the processing
will take place within processRequest(), which is called from
within run().
Up until this point, we have been throwing exceptions, rather
than catching them. However, we cannot throw exceptions from
run(), because we must strictly adhere to the declaration of
run() in the Runnable interface, which does not throw any
exceptions. We will place all of the processing code in
processRequest(), and from there, throw exceptions to run().
Within run(), we explicitly catch and handle exceptions with a
try/catch block. // Implement the run() method of the Runnable
interface.public void run(){ try { processRequest(); }
catch (Exception e) { System.out.println(e); }}
Now, let's develop the code within processRequest(). We first
obtain references to the socket's input and output streams. Then
we wrap InputStreamReader and BufferedReader filters around
the input stream. However, we won't wrap any filters around the
output stream, because we will be writing bytes directly into the
output stream. private void processRequest() throws Exception{
// Get a reference to the socket's input and output streams.
InputStream is = ?; DataOutputStream os = ?; // Set
up input stream filters. ? BufferedReader br = ?; . . .}
Now we are prepared to get the client's request message, which
we do by reading from the socket's input stream. The readLine()
method of the BufferedReader class will extract characters from
the input stream until it reaches an end-of-line character, or in
our case, the end-of-line character sequence, CRLF.
The first item available in the input stream will be the HTTP
request line. (See Section 2.2 of the textbook for a description
of this and the following fields). // Get the request line of the
HTTP request message.String requestLine = ?;// Display the
request
line.System.out.println();System.out.println(requestLine);
After obtaining the request line of the message header, we
obtain the header lines. Since we don't know ahead of time how
5. many header lines the client will send, we must get these lines
within a looping operation. // Get and display the header
lines.String headerLine = null;while ((headerLine =
br.readLine()).length() != 0) { System.out.println(headerLine);}
We don't need the header lines, other than to print them to the
screen, so we use a temporary String variable, headerLine, to
hold a reference to their values. The loop terminates when the
expression (headerLine = br.readLine()).length()
evaluates to zero, which will occur when headerLine has zero
length. This will happen when the empty line terminating the
header lines is read. (See the HTTP Request Message diagram
in Section 2.2 of the textbook).
In the next step of this lab, we will add code to analyze the
client's request message and send a response. Before we do this,
let's try compiling our program and testing it with a browser.
Add the following lines of code to close the streams and socket
connection. // Close streams and
socket.os.close();br.close();socket.close();
After your program successfully compiles, run it with an
available port number, and try contacting it from a browser. To
do this, you should enter into the browser's address text box the
IP address of your running server. For example, if your machine
name is host.someschool.edu, and you ran the server with Port
#6789, then you would specify the following URL:
http://host.someschool.edu:6789/
The server should display the contents of the HTTP request
message. Check that it matches the message format shown in the
HTTP Request Message diagram in Section 2.2 of the textbook.
Web Server in Java: Part B
Instead of simply terminating the thread after displaying the
browser's HTTP request message, we will analyze the request
and send an appropriate response. We are going to ignore the
information in the header lines, and use only the file name
contained in the request line. In fact, we are going to assume
that the request line always specifies the GET method, and
6. ignore the fact that the client may be sending some other type of
request, such as HEAD or POST.
We extract the file name from the request line with the aid of
the StringTokenizer class. First, we create a StringTokenizer
object that contains the string of characters from the request
line. Second, we skip over the method specification, which we
have assumed to be "GET". Third, we extract the file name. //
Extract the filename from the request line.StringTokenizer
tokens = new StringTokenizer(requestLine);tokens.nextToken();
// skip over the method, which should be "GET"String fileName
= tokens.nextToken();// Prepend a "." so that file request is
within the current directory.fileName = "." + fileName;
Because the browser precedes the filename with a slash, we
prefix a dot so that the resulting pathname starts within the
current directory.
Now that we have the file name, we can open the file as the first
step in sending it to the client. If the file does not exist, the
FileInputStream() constructor will throw the
FileNotFoundException. Instead of throwing this possible
exception and terminating the thread, we will use a try/catch
construction to set the boolean variable fileExists to false. Later
in the code, we will use this flag to construct an error response
message, rather than try to send a nonexistent file. // Open the
requested file.FileInputStream fis = null;boolean fileExists =
true;try { fis = new FileInputStream(fileName);} catch
(FileNotFoundException e) { fileExists = false;}
There are three parts to the response message: the status line,
the response headers, and the entity body. The status line and
response headers are terminated by the character sequence,
CRLF. We are going to respond with a status line, which we
store in the variable statusLine, and a single response header,
which we store in the variable contentTypeLine. In the case of a
request for a nonexistent file, we return 404 Not Found in the
status line of the response message, and include an error
message in the form of an HTML document in the entity body.
// Construct the response message.String statusLine =
7. null;String contentTypeLine = null;String entityBody = null;if
(fileExists) { statusLine = ?; contentTypeLine = "Content-
type: " + contentType( fileName ) + CRLF;} else {
statusLine = ?; contentTypeLine = ?; entityBody =
"<HTML>" + "<HEAD><TITLE>Not
Found</TITLE></HEAD>" + "<BODY>Not
Found</BODY></HTML>";}
When the file exists, we need to determine the file's MIME type
and send the appropriate MIME-type specifier. We make this
determination in a separate private method called
contentType(), which returns a string that we can include in the
content type line that we are constructing.
Now we can send the status line and our single header line to
the browser by writing into the socket's output stream. // Send
the status line.os.writeBytes(statusLine);// Send the content
type line.os.writeBytes(?);// Send a blank line to indicate the
end of the header lines.os.writeBytes(CRLF);
Now that the status line and header line with delimiting CRLF
have been placed into the output stream on their way to the
browser, it is time to do the same with the entity body. If the
requested file exists, we call a separate method to send the file.
If the requested file does not exist, we send the HTML-encoded
error message that we have prepared. // Send the entity body.if
(fileExists) { sendBytes(fis, os); fis.close();} else {
os.writeBytes(?);}
After sending the entity body, the work in this thread has
finished, so we close the streams and socket before terminating.
We still need to code the two methods that we have referenced
in the above code, namely, the method that determines the
MIME type, contentType(), and the method that writes the
requested file onto the socket's output stream. Let's first take a
look at the code for sending the file to the client. private static
void sendBytes(FileInputStream fis, OutputStream os) throws
Exception{ // Construct a 1K buffer to hold bytes on their way
to the socket. byte[] buffer = new byte[1024]; int bytes = 0;
// Copy requested file into the socket's output stream.
8. while((bytes = fis.read(buffer)) != -1 ) { os.write(buffer, 0,
bytes); }}
Both read() and write() throw exceptions. Instead of catching
these exceptions and handling them in our code, we throw them
to be handled by the calling method.
The variable, buffer, is our intermediate storage space for bytes
on their way from the file to the output stream. When we read
the bytes from the FileInputStream, we check to see if read()
returns minus one, indicating that the end of the file has been
reached. If the end of the file has not been reached, read()
returns the number of bytes that have been placed into buffer.
We use the write() method of the OutputStream class to place
these bytes into the output stream, passing to it the name of the
byte array, buffer, the starting point in the array, 0, and the
number of bytes in the array to write, bytes.
The final piece of code needed to complete the Web server is a
method that will examine the extension of a file name and
return a string that represents its MIME type. If the file
extension is unknown, we return the type application/octet-
stream. private static String contentType(String fileName){
if(fileName.endsWith(".htm") ||
fileName.endsWith(".html")) { return "text/html"; }
if(?) { ?; } if(?) { ?; } return
"application/octet-stream;"}
There is a lot missing from this method. For instance, nothing is
returned for .gif or .jpeg files. Add the missing file types
yourself, so that the components of your home page are sent
with the content type correctly specified in the content type
header line. For GIFs, the MIME type is image/gif, and for
JPEGs, it is image/jpeg.
This completes the code for the second phase of development of
your Web server. Try running the server from the directory
where your home page is located, and try viewing your home
page files with a browser. Remember to include a port specifier
in the URL of your home page, so that your browser doesn't try
to connect to the default Port 80. When you connect to the
9. running Web server with the browser, examine the GET
message requests that the Web server receives from the browser.
Deliverables:
1. Captured screenshots demonstrating that your system works
with explanation,
2. Copy of your completed code used in your server system,
3. Provide a summary of your experiences in working this
project and include what you learned as a part of this exercise,
and
4. Include a Wireshark printout with the message sequences.
Response Papers
Assignment 3.5 - Response Paper #1 Due
Compose your response paper adhering to the guidelines set
forth under the Instructions & Information page. Review the
response paper rubric for grading criteria. Submit it to
turnitin.com and to Drop Box 3.5 upon completion.
Information/Instructions
These papers are not book reviews. They are based on what you
learned from each of the three books, the articles, discussions,
lecture materials, SkillSoft materials, videos, and classmate
interactions. The length required for each response paper is
three to five pages (double-spaced, APA style, including proper
grammar and correct spelling). Click here to view the grading
rubric that is used for scoring your written papers. Your
response papers are to be turned in through turnitin.com and the
corresponding drop box.
These papers are not book reviews. They include reading
materials, discussions, web assignments, lecture materials, and
interactions between classmates. Criteria for the response
papers include:
· You must be in the paper. You have been trained your entire
academic career to present, critique, analyze ideas and issues.
This paper moves away from ideas and issues to focus on you
(not just your ideas either). You may find this process difficult
10. and your resistance strong.
· Your response should include the impact of the course
material addressed prior to the paper due date or all material
addressed between paper due dates including reading
assignments, discussion assignments, web assignments, and
lecture assignments, as well as interaction between classmates.
· The impact means describing the impact the course material is
having on you. If you tell the instructor how wrong you think
someone’s ideas, discussion, or opinions are, then you are
reflecting on the impact of your thinking on the material.
RATHER: Tell your instructor the material’s impact on your
thinking.
· If you tell the instructor about the issues, the arguments, the
facts then you are reflecting on things outside of you. RATHER:
Tell your instructor the issues, the arguments, the facts impacts
upon you.
· You have been trained to learn from the professors and give
back information. The information these papers require from
you (for an “A) is information an instructor cannot give to
you… Nor is it information you already have. What is required
in the response paper is the information that arises in and
through the process of interaction with the course material.
· If this course material has no impact on you, then either you
are not participating in the class or you do not know how to
reflect on yourself. In any case, your resistance to the material
is greater than your ability to be open, vulnerable or self-aware.
Resistance to or lack of openness or vulnerability or lack of
self-awareness will stand in the way of being the best negotiator
possible for you. This usually indicates some form of
protection.
· There is a lot about negotiation that provokes self-protection.
Your instructor must see progression of growth through various
levels. Grading will also take into consideration movement into
deeper levels, as well as thoroughness within levels.
· Consider how you are different, what changes have been made
on the surface, what does having this information feel like, how
11. have you been permanently changed, how have your
relationships changed?
· Go beyond the assigned textbook reading in your response
papers. Include discussion assignments, reading assignments,
lecture assignments, web assignments, personal encounters
outside the class, professional situations, comments from
classmates, interests and positions of others in the negotiations,
and comments from your instructor.
Late reports may be accepted, at the discretion of the instructor.
If accepted, late reports will be subject to a 50 point deduction.
After 7 calendar days from the original due date, a grade of zero
will be recorded.
Response Paper Rubric
Points Possible 100
Criteria
Achievement Level
Achievement Level 1
Achievement Level 2
Achievement Level 3
Achievement Level 4
Achievement Level 5
“You” are in the paper
0 points
No attempt to include self-reflection in the paper
16.75 points
Discusses facts from the book, but does not reflect upon the
impact the course material has had on the student’s thinking and
behavior
19.25 points
Discusses facts from the course materials, but seldom reflects
upon the impact the course material has had on the student’s
thinking and behavior
21.75 points
12. Reflects upon the impact of the material, but makes frequent
references to the facts presented in the course materials
25 points
Reflects upon the impact the material has on the student’s
thinking and behaviors, and links course materials to the
changes in thinking and behavior
Inclusion of all course materials for the timeframe
0 points
No attempt made include pertinent course materials
16.75 points
Does not incorporate many of the course materials for the
timeframe into the response
19.25 points
Incorporates some of the course materials for the timeframe into
the response
21.75 points
Incorporates most of the course material for the timeframe into
the response, but misses some of the materials
25 points
Incorporates all course materials for the timeframe into the
response
Communication of Ideas
0 points
No attempt made to communicate ideas
16.75 points
Lacks focus, demonstrates confused or simplistic thinking, or
fails to communicate ideas
19.25 points
May treat the topic simplistically or repetitively; doesn’t
demonstrate sufficient comprehension of the text
21.75 points
Shows some depth and complexity of thought
25 points
Explores the issues showing thorough comprehension of the
text; goes beyond the obvious or class discussion
Organization of Paper
13. 0 points
Incoherent and no organization
10.05 points
Poorly organized and/or undeveloped; lacks support from the
text
11.55 points
Adequately organized and developed; generally supports ideas
with reasons and examples
13.05 points
Well organized and developed with appropriate reasons and
examples
15 points
Coherently organized with ideas supported by apt reasons
Mechanics
0 points
Unreadable due to the severity of mechanical errors
6.7 points
Contains serious and persistent errors in word choice,
mechanics, usage, and sentence structure
7.7 points
Contains some errors, but generally demonstrates control of
mechanics, usage, and sentence structure
8.7 points
Contains minimal errors in mechanics, usage, and sentence
structure
10 points
Well written and concise; generally free from errors in
mechanics, usage, and sentence structure
Master of Science in Conflict Management – Graduate
SchoolCMM 550 - Negotiation in Conflict Management
Required Text(s) and Resources:
Kritek, Phyllis Beck. (2002). Negotiating at an Uneven Table
(2nd ed.). San Francisco: Jossey-Bass.
Lum, Grande. (2011). The Negotiation Fieldbook (2nd ed.).
New York: McGraw-Hill. ISBN:
14. Reardon, Kathleen. (2005). Becoming a Skilled Negotiator (1st
ed.). Hoboken: John Wiley & Sons, Inc.
Week 2-Required Readings/Viewings:
· From The Negotiation Fieldbook text: Chapters 5-7
· From Course Material: The Seven Elements
· From Article: Negotiation Is Not A Competitive Sport
From Article: BATNA Basics - Boost Your Power at the
Bargaining Table (Note: This link wil require that you enter
your email address to "Claim Your Free Copy". You will be
able to download the article to read, once you have entered your
email address.)
Week 3- Required Readings/Viewings
· From The Negotiation Fieldbook text: Chapters 8-10
· From Article at Sullivan University Library on the EbscoHost
Database: Negotiation Preparation Differences in Selling
Situations: Collaborative Versus Competitive Expectations.
Peterson, R.M. & Shepherd, C. (2011) Marketing Management
Journal 21 (2) 103–114.
· From Article: Focusing On Interests Rather Than Positions
Conflict Resolution Key
· From Article: Fundamentals of Negotiation By Roger Clarke,
Principal, Xamax Consultancy Pty Ltd, Canberra. Visiting
Fellow, Department of Computer Science, Australian National
University.
Negotiation in Conflict Management Presentation: LUM's ICON
Model, BANTAs and Motivational Styles