All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.jamon.html.TextInputImpl Maven / Gradle / Ivy

There is a newer version: 2.4.1
Show newest version
// Autogenerated Jamon implementation
// /Users/jay/jamon/jamon-stdlib/src/main/templates/org/jamon/html/TextInput.jamon

package org.jamon.html;


// 20, 1
@Deprecated @SuppressWarnings("deprecation")
public class TextInputImpl
  extends org.jamon.AbstractTemplateImpl
  implements org.jamon.html.TextInput.Intf

{
  private final org.jamon.render.html.TextInput input;
  private final int size;
  private final String type;
  protected static org.jamon.html.TextInput.ImplData __jamon_setOptionalArguments(org.jamon.html.TextInput.ImplData p_implData)
  {
    if(! p_implData.getSize__IsNotDefault())
    {
      p_implData.setSize(-1);
    }
    if(! p_implData.getType__IsNotDefault())
    {
      p_implData.setType("text");
    }
    return p_implData;
  }
  public TextInputImpl(org.jamon.TemplateManager p_templateManager, org.jamon.html.TextInput.ImplData p_implData)
  {
    super(p_templateManager, __jamon_setOptionalArguments(p_implData));
    input = p_implData.getInput();
    size = p_implData.getSize();
    type = p_implData.getType();
  }
  
  public void renderNoFlush(@SuppressWarnings({"unused","hiding"}) final java.io.Writer jamonWriter)
    throws java.io.IOException
  {
    // 28, 1
    jamonWriter.write(" 0) { displaySize = max; }

    // 34, 1
     if (displaySize > 0) {

    // 35, 1
    jamonWriter.write("       size='");
    // 35, 14
    org.jamon.escaping.Escaping.HTML.write(org.jamon.emit.StandardEmitter.valueOf(displaySize), jamonWriter);
    // 35, 31
    jamonWriter.write("'\n");
    // 36, 1
     }

    // 37, 1
     if (max > 0) {

    // 38, 1
    jamonWriter.write("       maxlength='");
    // 38, 19
    org.jamon.escaping.Escaping.HTML.write(org.jamon.emit.StandardEmitter.valueOf(max), jamonWriter);
    // 38, 28
    jamonWriter.write("'\n");
    // 39, 1
     }

    // 40, 1
     if (input.isUpperCaseOnly()) {

    // 41, 1
    jamonWriter.write("    onChange=\"capitalize(this)\"\n");
    // 42, 1
     }

    // 43, 1
    jamonWriter.write("/>");
  }
  
  
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy