1 5 package org.exoplatform.text.template.xhtml; 6 7 import java.io.IOException ; 8 import java.io.Writer ; 9 import java.util.ResourceBundle ; 10 import org.exoplatform.text.template.DataHandler; 11 import org.exoplatform.text.template.DataHandlerManager; 12 13 18 public class Span extends Text { 19 public Span(String value) { 20 super(value); 21 } 22 23 public void render(DataHandlerManager manager, 24 ResourceBundle res, Writer w) throws IOException { 25 if(cssClass_ == null) { 26 w.write("<span>") ; 27 } else { 28 w.write("<span class='") ; w.write(cssClass_); w.write("'>") ; 29 } 30 DataHandler dh = manager.getDataHandler(dataHandlerType_); 31 w.write(resolveValueAsString(data_ ,dh, res)) ; 32 w.write("</span>") ; 33 } 34 } | Popular Tags |