001 package railo.runtime.tag; 002 003 import railo.runtime.exp.ExpressionException; 004 import railo.runtime.ext.tag.TagImpl; 005 006 /** 007 * Executes a Java servlet on a JRun engine. This tag is used in conjunction with the 008 * cfserletparam tag, which passes data to the servlet. 009 * 010 * 011 * 012 **/ 013 public final class Servlet extends TagImpl { 014 015 private boolean debug; 016 private String code; 017 private boolean writeoutput; 018 private double timeout; 019 private String jrunproxy; 020 021 022 /** 023 * constructor for the tag class 024 * @throws ExpressionException 025 **/ 026 public Servlet() throws ExpressionException { 027 throw new ExpressionException("tag cfservlet is deprecated"); 028 } 029 030 /** set the value debug 031 * Boolean specifying whether additional information about the JRun connection status and 032 * activity is to be written to the JRun error log 033 * @param debug value to set 034 **/ 035 public void setDebug(boolean debug) { 036 this.debug=debug; 037 } 038 039 /** set the value code 040 * The class name of the Java servlet to execute. 041 * @param code value to set 042 **/ 043 public void setCode(String code) { 044 this.code=code; 045 } 046 047 /** set the value writeoutput 048 * @param writeoutput value to set 049 **/ 050 public void setWriteoutput(boolean writeoutput) { 051 this.writeoutput=writeoutput; 052 } 053 054 /** set the value timeout 055 * Specifies how many seconds JRun waits for the servlet to complete before timing out. 056 * @param timeout value to set 057 **/ 058 public void setTimeout(double timeout) { 059 this.timeout=timeout; 060 } 061 062 /** set the value jrunproxy 063 * @param jrunproxy value to set 064 **/ 065 public void setJrunproxy(String jrunproxy) { 066 this.jrunproxy=jrunproxy; 067 } 068 069 070 /** 071 * @see javax.servlet.jsp.tagext.Tag#doStartTag() 072 */ 073 public int doStartTag() { 074 return SKIP_BODY; 075 } 076 077 /** 078 * @see javax.servlet.jsp.tagext.Tag#doEndTag() 079 */ 080 public int doEndTag() { 081 return EVAL_PAGE; 082 } 083 084 /** 085 * @see javax.servlet.jsp.tagext.Tag#release() 086 */ 087 public void release() { 088 super.release(); 089 debug=false; 090 code=""; 091 writeoutput=false; 092 timeout=0d; 093 jrunproxy=""; 094 } 095 }