alvinalexander.com | career | drupal | java | mac | mysql | perl | scala | uml | unix  

Groovy example source code file (zoo.groovy)

This example Groovy source code file (zoo.groovy) is included in the DevDaily.com "Java Source Code Warehouse" project. The intent of this project is to help you "Learn Java by Example" TM.

Java - Groovy tags/keywords

animal, animal, example, example, here, here, return, servlet, servlet, there, visiting, where

The Groovy zoo.groovy source code

println """
<html>
    <head>
        <title>Groovy Servlet Example - Visiting the zoo
    </head>
    <body>
    <a href="../">Return
    <p>
"""

Animal shark = new zoo.fish.Shark()
Animal trout = new zoo.fish.Trout()
Animal forelle = new zoo.HommingbergerGepardenforelle()

println """
     <p>Shark
${shark.saySomething("\"Where is the trout?\"")} <p>Trout
${trout.saySomething("Here is the trout!")} <p>Forelle
${forelle.saySomething("\"<a href=\"http://www.hommingberger-forelle.de\">There is no spoon.\"")} <!-- http://en.wikipedia.org/wiki/Nigritude_ultramarine --> """ println """ </body> </html> """

Other Groovy examples (source code examples)

Here is a short list of links related to this Groovy zoo.groovy source code file:

... this post is sponsored by my books ...

#1 New Release!

FP Best Seller

 

new blog posts

 

Copyright 1998-2021 Alvin Alexander, alvinalexander.com
All Rights Reserved.

A percentage of advertising revenue from
pages under the /java/jwarehouse URI on this website is
paid back to open source projects.