J2EEOnline J2EE 






Java Streams  «Prev  Next»
Lesson 1

Introduction to Java Streams

This module introduces streams, the foundation of input and output in Java. Anytime you read data
  1. from a file,
  2. a network connection,
  3. System.in
you are using streams. Similarly, anytime you write data to a file, a network connection, or System.out, you will use streams.
In this module, you will learn the following:
  1. What streams are
  2. Where streams come from
  3. When you should use streams
A stream is an ordered sequence of bytes of undetermined length. Input streams move bytes of data into a Java program from an external source. Output streams move bytes of data from Java to an external target. (In special cases streams can also move bytes from one part of a Java program to another.)


Sequence, Piped, Object, File, Filter, ByteArray InputStream
Sequence, Piped, Object, File, Filter, ByteArray InputStream
JRMP, or Java Remote Method Protocol is the Java technology-specific protocol for looking up and referencing remote objects. It is a wire level protocol running at the level under Remote Method Invocation (RMI) and over TCP/IP. JRMP is a Java-specific, stream-based protocol.
RMI-IIOP which exposes Java objects to CORBA ORBs is an alternative for JRMP. However, many application server vendors have developed their own protocols for use with RMI which claim to offer advantages over both IIOP and JRMP.
JRMP is a Java-specific, stream-based protocol similar to RMI-IIOP. The RMI-IIOP which exposes Java objects to CORBA ORBs is an alternative to JRMP. In contrast to the RMI-IIOP, the JRMP is a protocol for Java-to-Java remote calls, which makes it language dependent and means that both client and server must use java objects. However, many application server vendors have developed their own protocols for use with RMI which claim to offer advantages over both IIOP and JRMP.