Cernunnos Manual


<echo>

Description:

Prints the specified MESSAGE to the PrintStream specified by STREAM. You may optionally provide a PREFIX and/or SUFFIX.

Reagents:

Name XPath Description Reagent Type Expected Type Required
STREAM @stream Optional PrintStream to which the message should be written. If omitted, this task will use either: (1) the value of the 'Attributes.STREAM' request attribute if present; or (2) System.out. PHRASE java.io.PrintStream No
PREFIX @prefix Characters that preceed the main message. The default is an empty string. PHRASE java.lang.String No
MESSAGE text() Message to write to the specified PrintStream. The default is an empty string. PHRASE java.lang.Object No
SUFFIX @suffix Characters that follow the main message. The default is an empty string. PHRASE java.lang.String No

Examples:

Reads database connection information from a properties file, makes a connection, writes each name from the 'users' table to the screen:

 
       
        <properties location="build/WEB-INF/classes/properties/rdbm.properties"> 
          <sql-connection driver="${req(jdbcDriver)}" password="${req(jdbcPassword)}" url="${req(jdbcUrl)}" username="${req(jdbcUser)}"> 
            <sql-query> 
              <sql>SELECT user_name FROM users</sql>  
              <subtasks> 
                <echo>${req(1)},</echo> 
              </subtasks> 
            </sql-query> 
          </sql-connection> 
        </properties>