Package: org.codehaus.groovy.grails.web.pages

## [Java] Class GroovyPageMetaInfo

- org.codehaus.groovy.grails.web.pages.GroovyPageMetaInfo

- All Implemented Interfaces and Traits:
    GrailsApplicationAware

      public class GroovyPageMetaInfo
      extends java.lang.Object

  Encapsulates the information necessary to describe a GSP.

  Authors:
    Graeme Rocher
    Lari Hotari
  Since:
    0.5

- - ### Field Summary

    Fields
    Modifiers | Name | Description
    --- | --- | ---
    `static java.lang.String` | `DEFAULT_PLUGIN_PATH` |
    `static java.lang.String` | `HTML_DATA_POSTFIX` |
    `static long` | `LASTMODIFIED_CHECK_INTERVAL` |
    `static java.lang.String` | `LINENUMBERS_DATA_POSTFIX` |

  - ### Constructor Summary

    Constructors
    Constructor and description
    `GroovyPageMetaInfo ()`
    `GroovyPageMetaInfo (java.lang.Class<?> pageClass)`

  - ### Methods Summary

    Methods
    Type | Name and description
    --- | ---
    `void` | `applyLastModifiedFromResource(org.springframework.core.io.Resource resource)`
    `org.springframework.core.io.Resource` | `checkIfReloadableResourceHasChanged(java.security.PrivilegedAction<org.springframework.core.io.Resource> resourceCallable)`
    `GroovyPagesException` | `getCompilationException()`
    `java.lang.String` | `getContentType()`
    `Encoder` | `getExpressionEncoder()`
    `GrailsApplication` | `getGrailsApplication()`
    `java.io.InputStream` | `getGroovySource()`
    `java.lang.String[]` | `getHtmlParts()`
    `TagLibraryResolver` | `getJspTagLibraryResolver()`
    `java.util.Map` | `getJspTags()`
    `long` | `getLastModified()`
    `int[]` | `getLineNumbers()`
    `Encoder` | `getOutEncoder()`
    `java.lang.Class<?>` | `getPageClass()`
    `GrailsPlugin` | `getPagePlugin()`
    `java.lang.String` | `getPluginPath()`
    `Encoder` | `getStaticEncoder()`
    `TagLibraryLookup` | `getTagLibraryLookup()`
    `Encoder` | `getTaglibEncoder()`
    `void` | `initialize()`
    `boolean` | `isPrecompiledMode()`
    `void` | `removePageMetaClass()`
    `void` | `setCompilationException(GroovyPagesException e)`
    `void` | `setContentType(java.lang.String contentType)`
    `void` | `setExpressionCodecName(java.lang.String expressionCodecName)`
    `void` | `setGrailsApplication(GrailsApplication grailsApplication)`
    `void` | `setGroovySource(java.io.InputStream groovySource)`
    `void` | `setHtmlParts(java.lang.String[] htmlParts)`
    `void` | `setJspTagLibraryResolver(TagLibraryResolver jspTagLibraryResolver)`
    `void` | `setJspTags(java.util.Map jspTags)`
    `void` | `setLastModified(long lastModified)`
    `void` | `setLineNumbers(int[] lineNumbers)`
    `void` | `setOutCodecName(java.lang.String pageCodecName)`
    `void` | `setPageClass(java.lang.Class<?> pageClass)`
    `void` | `setStaticCodecName(java.lang.String staticCodecName)`
    `void` | `setTagLibraryLookup(TagLibraryLookup tagLibraryLookup)`
    `void` | `setTaglibCodecName(java.lang.String taglibCodecName)`
    `boolean` | `shouldReload(java.security.PrivilegedAction<org.springframework.core.io.Resource> resourceCallable)` Checks if this GSP has expired and should be reloaded (there is a newer source gsp available) PrivilegedAction is used so that locating the Resource is lazily evaluated.
    `void` | `writeToFinished(java.io.Writer out)`

  - ### Inherited Methods Summary

    Inherited Methods
    Methods inherited from class | Name
    --- | ---
    `class java.lang.Object` | `java.lang.Object#wait(long, int), java.lang.Object#wait(long), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll()`

- - ### Field Detail

    - #### public static java.lang.String DEFAULT_PLUGIN_PATH

    - #### public static final java.lang.String HTML_DATA_POSTFIX

    - #### public static final long LASTMODIFIED_CHECK_INTERVAL

    - #### public static final java.lang.String LINENUMBERS_DATA_POSTFIX

  - ### Constructor Detail

    - #### public GroovyPageMetaInfo()

    - #### @java.lang.SuppressWarnings("rawtypes") public GroovyPageMetaInfo(java.lang.Class<?> pageClass)

  - ### Method Detail

    - #### public void applyLastModifiedFromResource(org.springframework.core.io.Resource resource)

    - #### public org.springframework.core.io.Resource checkIfReloadableResourceHasChanged(java.security.PrivilegedAction<org.springframework.core.io.Resource> resourceCallable)

    - #### public GroovyPagesException getCompilationException()

    - #### public java.lang.String getContentType()

    - #### public Encoder getExpressionEncoder()

    - #### public GrailsApplication getGrailsApplication()

    - #### public java.io.InputStream getGroovySource()

    - #### public java.lang.String[] getHtmlParts()

    - #### public TagLibraryResolver getJspTagLibraryResolver()

    - #### @java.lang.SuppressWarnings("rawtypes") public java.util.Map getJspTags()

    - #### public long getLastModified()

    - #### public int[] getLineNumbers()

    - #### public Encoder getOutEncoder()

    - #### public java.lang.Class<?> getPageClass()

    - #### public GrailsPlugin getPagePlugin()

    - #### public java.lang.String getPluginPath()

    - #### public Encoder getStaticEncoder()

    - #### public TagLibraryLookup getTagLibraryLookup()

    - #### public Encoder getTaglibEncoder()

    - #### public void initialize()

    - #### public boolean isPrecompiledMode()

    - #### public void removePageMetaClass()

    - #### public void setCompilationException(GroovyPagesException e)

    - #### public void setContentType(java.lang.String contentType)

    - #### public void setExpressionCodecName(java.lang.String expressionCodecName)

    - #### public void setGrailsApplication(GrailsApplication grailsApplication)

    - #### public void setGroovySource(java.io.InputStream groovySource)

    - #### public void setHtmlParts(java.lang.String[] htmlParts)

    - #### public void setJspTagLibraryResolver(TagLibraryResolver jspTagLibraryResolver)

    - #### @java.lang.SuppressWarnings("rawtypes") public void setJspTags(java.util.Map jspTags)

    - #### public void setLastModified(long lastModified)

    - #### public void setLineNumbers(int[] lineNumbers)

    - #### public void setOutCodecName(java.lang.String pageCodecName)

    - #### public void setPageClass(java.lang.Class<?> pageClass)

    - #### public void setStaticCodecName(java.lang.String staticCodecName)

    - #### public void setTagLibraryLookup(TagLibraryLookup tagLibraryLookup)

    - #### public void setTaglibCodecName(java.lang.String taglibCodecName)

    - #### public boolean shouldReload(java.security.PrivilegedAction<org.springframework.core.io.Resource> resourceCallable)

      Checks if this GSP has expired and should be reloaded (there is a newer source gsp available) PrivilegedAction is used so that locating the Resource is lazily evaluated. lastModified checking is done only when enough time has expired since the last check. This setting is controlled by the grails.gsp.reload.interval System property, by default it's value is 5000 (ms).

      Parameters:
        `resourceCallable` - call back that resolves the source gsp lazily
      Returns:
        true if the available gsp source file is newer than the loaded one.

    - #### public void writeToFinished(java.io.Writer out)