Package biz.source_code.miniTemplator

Examples of biz.source_code.miniTemplator.MiniTemplator.addBlock()


         int dayOfMonth = (weekOfYear*7 + dayOfWeek) - 98;
         if (dayOfMonth >= 1 && dayOfMonth <= 30)
            t.setVariable("dayOfMonth", Integer.toString(dayOfMonth));
          else
            t.setVariable("dayOfMonth", "&nbsp;");
         t.addBlock("day"); }
      t.setVariable("weekOfYear", Integer.toString(weekOfYear));
      t.addBlock("week"); }
   t.generateOutput(outputFileName); }

} // end class Example2
View Full Code Here


            t.setVariable("dayOfMonth", Integer.toString(dayOfMonth));
          else
            t.setVariable("dayOfMonth", "&nbsp;");
         t.addBlock("day"); }
      t.setVariable("weekOfYear", Integer.toString(weekOfYear));
      t.addBlock("week"); }
   t.generateOutput(outputFileName); }

} // end class Example2
View Full Code Here

public static void main (String args[]) throws Exception {
   MiniTemplator t = new MiniTemplator(templateFileName);
   t.setVariable("animal1", "fox");
   t.setVariable("animal2", "dog");
   t.addBlock("block1");
   t.setVariable("animal1", "horse");
   t.setVariable("animal2", "cow");
   t.addBlock("block1");
   t.generateOutput(outputFileName); }
View Full Code Here

   t.setVariable("animal1", "fox");
   t.setVariable("animal2", "dog");
   t.addBlock("block1");
   t.setVariable("animal1", "horse");
   t.setVariable("animal2", "cow");
   t.addBlock("block1");
   t.generateOutput(outputFileName); }

} // end class Example1
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.