Jostraca Example: Hello World
example index
www.jostraca.org
info@jostraca.org

Description:

A simple "hello world" template. This template shows how to embed a text message into the template. The message can be changed in the template script.

Generate Command:

> jostraca HelloWorld.jtm
(you can also use generate.bat or generate.sh)

Generated Files:

HelloWorld.txt
.jostraca/HelloWorldWriter.java
.jostraca/HelloWorldWriter.class

Experiments:

Try changing the message.
Try changing the generated file name.

Template Contents:

<% @conf 
main.JostracaVersion = 0.4
main.TemplateScript  = java
%>

<% init! 
_setFullFileName( "HelloWorld.txt" );
String who = "World";
%>

Hello <%=who%>!
 

Generated File Contents:

Note: only one generated file is shown



Hello World!
 

   example index
   Copyright © 2000-2002 Richard Rodger License.