- Forward


Content Handlers
An Introduction with Examples in Java


Prof. David Bernstein
James Madison University

Computer Science Department
bernstdh@jmu.edu

Print

Motivation
Back SMYC Forward
  • An Observation:
    • Stream-oriented protocols are often used to request content (e.g., HTTP)
    • The ways in which the content are requested are often very similar
  • Implications:
    • We can think in the abstract about a content handler
Content Handlers in Java
Back SMYC Forward

The Relevant Classes

custom_content-handlers_java
An Example
Back SMYC Forward

ImageContentHandler

javaexamples/contenthandlers/ImageContentHandler.java
 
An Example (cont.)
Back SMYC Forward

ImageContentHandlerFactory

javaexamples/contenthandlers/ImageContentHandlerFactory.java
 
An Example (cont.)
Back SMYC Forward

ImageViewer

javaexamples/contenthandlers/ImageViewer.java (Fragment: 0)
 
There's Always More to Learn
Back -