• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint

Summary

This chapter showed several ways in which server-side Java can be used to generate SVG. First, we used JSP as a scripting language to generate simple fractal images. This approach is perfectly good, but the real benefits of server-side Java really start only when we start building Java classes behind the scenes. One range of possibilities is offered by JavaBeans, like this chapter's example which finds where a line intersects a rectangle. We can build all manner of JavaBean components, which we can call directly with JSP to provide information that can be represented in SVG.

By using the SVG DOM, as we did in the simple example in which we drew a circle and then in the Squirrel application, we get a degree of control over the SVG that goes beyond text-based manipulation. SVG DOM is, of course, available on the client-side too, but its sophistication is soon appreciated in the server-side environment.


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint