Java 7 SE, (Part 2 of 4): IO, New IO, and Network Protocols
Interactive

Java 7 SE, (Part 2 of 4): IO, New IO, and Network Protocols

BizLibrary
Updated Feb 04, 2020

Java SE 7 platform gave us a brand new file based I/O architecture, NIO2. This new architecture solved most of the problems we saw in the original stream based I/O. You’ll see how the NIO2 Path class is used to represent the underlying file system syntax, in a manner that is transparent to the application. Next you’ll see how the NIO2 Files class works with the Path class. Then we’ll cover the new NIO2 asynchronous channels, to let us monitor and control the completion of our asynchronous events. NIO2 also gives us a new asynchronousChannelGroup to group these channels, and supply them with a pool of threads for resource sharing. And we’ll take a look at the new WatchService file change notification API, which lets you register to be notified when files or directories change on the file system. After our tour of NIO2, we’ll move to the new networking features provided by Java SE 7. We’ll experiment with the URLClassLoader, which now implements the Closable I/F and its close() method. Then we’ll take a look at the new protocols we can now access. One is the Stream Control Transmission Protocol, or SCTP, and another new protocol is Sockets Direct Protocol, or SDP.


Lesson 1:

  • Java File I/O Issues
  • Java SE 6 File I/O and NIO
  • NIO2: Non-Blocking IO 2
  • NIO Path and Path Classes
  • Demo: Paths
  • Demo: NIO.

Lesson 2:

  • NIO File Class
  • NIO File Operations
  • Demo: Create Directories & Files
  • Demo: Managing Metadata
  • Windows ACL File Attributes
  • Demo: ACL File Attributes
  • Demo: New Directory ACL.

Lesson 3:

  • NIO File System Operations
  • Demo: File System Operations
  • Demo: DeleteIfExists.

Lesson 4:

  • NIO Walking the Dir Tree
  • Demo: Walk Tree
  • Demo: Copy Tree.

Lesson 5:

  • Finding Files with NIO2
  • NIO File Glob Arguments
  • Demo: Pattern Matching
  • Demo: Glob Patterns.

Lesson 6:

  • NIO Architecture
  • NIO2 Asynchronous Channels
  • Demo: Asynchronous Operations.

Lesson 7:

  • NIO Async Channel Group
  • Demo: Async Channel Group.

Lesson 8:

  • NIO File Change Notification
  • Demo: WatchService
  • Demo: WatchEvent.

Lesson 9:

  • Java SE 7: New Networking
  • URLClassLoader.close() Method
  • Demo: URLClassLoader.

Lesson 10:

  • SCTP
  • SCTP NIO Channels
  • SCTP Server Open Channel
  • SCTP Server Accept Client Msg
  • SCTP Server Respond to Client
  • SCTP Client, Connect to Server
  • SCTP Client, Send Message.

Lesson 11:

  • SDP (Sockets Direct Protocol)
  • Using SDP
  • Invoking an SDP Application.
;