Package org.zkoss.zk.ui.metainfo
Class ResponseHeaderInfo
- java.lang.Object
-
- org.zkoss.zk.ui.metainfo.ResponseHeaderInfo
-
public class ResponseHeaderInfo extends java.lang.ObjectRepresents a setting of a response header. The setting specified here will become the response's header.It is a bit confusing that
ResponseHeaderInforepresents a setting of the response's header.HeaderInforepresents a tag located in the header of the generated content of a page. For example, if the client is a HTTP browser, thenResponseHeaderInfois equivalent to invokeExecution.setResponseHeader(java.lang.String, java.lang.String)andExecution.addResponseHeader(java.lang.String, java.lang.String). And,HeaderInforepresents the <link>, <meta> and <script> HTML tagsIt is not serializable.
- Since:
- 5.0.2
- Author:
- tomyeh
-
-
Constructor Summary
Constructors Constructor Description ResponseHeaderInfo(java.lang.String name, java.lang.String value, java.lang.String append, ConditionImpl cond)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetName()Returns the response header's name.java.lang.ObjectgetValue(PageDefinition pgdef, Page page)Returns the value of the response header.booleanshallAppend(PageDefinition pgdef, Page page)Returns whether to append the response header, rather than replace.
-
-
-
Constructor Detail
-
ResponseHeaderInfo
public ResponseHeaderInfo(java.lang.String name, java.lang.String value, java.lang.String append, ConditionImpl cond)Constructor.- Parameters:
name- the header's name, such as Refresh.value- the header's value. It could contain EL expressions. It could be evaluated to a string, or a date (Date).append- whether to append the header, or to set the header. It could contain EL expressions.
-
-
Method Detail
-
getName
public java.lang.String getName()
Returns the response header's name.
-
getValue
public java.lang.Object getValue(PageDefinition pgdef, Page page)
Returns the value of the response header.- Returns:
- the value which is an instance of
DateorString(and never null).
-
shallAppend
public boolean shallAppend(PageDefinition pgdef, Page page)
Returns whether to append the response header, rather than replace.
-
-