|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.codehaus.groovy.grails.web.taglib.GroovySyntaxTag
public abstract class GroovySyntaxTag
A tag type that gets translated directly into Groovy syntax by the GSP parser.
This is used for Java-implemented internal tags that the Parse class uses to directly inject code into the generated GSP source. These tags can do more than custom taglibs as the operate at the code level, rather than at the runtime view rendering level
Field Summary | |
---|---|
protected static String |
ATTRIBUTE_IN
|
protected static String |
ATTRIBUTE_VAR
|
protected Map |
attributes
|
protected static String |
ATTRIBUTES_STATUS
|
protected PrintWriter |
out
|
protected GroovyPageParser |
parser
|
protected Map |
tagContext
|
Constructor Summary | |
---|---|
GroovySyntaxTag()
|
Method Summary | |
---|---|
protected String |
calculateExpression(String expr)
|
protected void |
doEachMethod(String in)
|
void |
init(Map tagContext)
|
abstract boolean |
isAllowPrecedingContent()
Tags must return the correct value to indicate whether or not non-whitespace content is permitted before this tag. |
abstract boolean |
isKeepPrecedingWhiteSpace()
Tags must return the correct value to indicate whether or not whitespace before this tag should be kept in the output. |
void |
setAttribute(String name,
Object value)
Sets an attribute of the tag |
void |
setAttributes(Map attributes)
Sets the attributes of the tag |
void |
setWriter(Writer w)
Sets the writer that processes the tag |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.codehaus.groovy.grails.web.taglib.GrailsTag |
---|
doEndTag, doStartTag, getName |
Field Detail |
---|
protected static final String ATTRIBUTE_IN
protected static final String ATTRIBUTE_VAR
protected static final String ATTRIBUTES_STATUS
protected Map tagContext
protected PrintWriter out
protected Map attributes
protected GroovyPageParser parser
Constructor Detail |
---|
public GroovySyntaxTag()
Method Detail |
---|
public void init(Map tagContext)
init
in interface GrailsTag
public void setWriter(Writer w)
GrailsTag
setWriter
in interface GrailsTag
public void setAttributes(Map attributes)
GrailsTag
setAttributes
in interface GrailsTag
public void setAttribute(String name, Object value)
GrailsTag
setAttribute
in interface GrailsTag
public abstract boolean isKeepPrecedingWhiteSpace()
Tags must return the correct value to indicate whether or not whitespace before this tag should be kept in the output.
This is for tags that must follow other tags, such as g:else or g:elseif that do not allow content between them and the previous tag, and need to swallow the whitespace between them.
public abstract boolean isAllowPrecedingContent()
Tags must return the correct value to indicate whether or not non-whitespace content is permitted before this tag.
This is for tags that must follow other tags, such as g:else or g:elseif that do not allow content between them and the previous tag. It is simply used as a safety mechanism to trap incorrect usage of tags.
protected String calculateExpression(String expr)
protected void doEachMethod(String in)
in
-
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |