org.appng.taglib.search

## Class Searchable

- java.lang.Object
- - javax.servlet.jsp.tagext.TagSupport
  - - javax.servlet.jsp.tagext.BodyTagSupport
    - - org.appng.taglib.search.Searchable

- All Implemented Interfaces:
    Serializable, javax.servlet.jsp.tagext.BodyTag, javax.servlet.jsp.tagext.IterationTag, javax.servlet.jsp.tagext.JspTag, javax.servlet.jsp.tagext.Tag

      public class Searchable
      extends javax.servlet.jsp.tagext.BodyTagSupport

  This class represents a Searchable Tag.
  This tag is used to mark areas of a JSP as indexable/searchable. It can also be used to exclude certain areas form indexing/searching, for example the navigation of page. During indexing, a `Document` is being created from each indexed JSP.

  Attributes:
  - index - whether the body content should be indexed
  - visible (true) - whether or not the body content should be displayed
  - field - the name of the field

  Fields: The following fields of a `Document` can be set:
  - "title" - the title
  - "contents" - the content
  - "image" - a preview image
  - "teaser" - a teaser text
  - "date" - the date

  Usage:

       <!-- set the 'title' field for this document -->
       <appNG:searchable index="true" field="title" visible="false">The Hitchhiker's Guide to the Galaxy</appNG:searchable>
       <!-- set the 'contents' field for this document -->
       <appNG:searchable index="true" field="contents" visible="true">
              <div>The Hitchhiker's Guide to the Galaxy is a comedy science fiction series created by Douglas Adams.</div>
              <!-- skip some content -->
              <appNG:searchable index="false">content to be skipped...</appNG:searchable>
       </appNG:searchable>

  Author:
    Matthias Herlitzius
  See Also:
    `Document`, Serialized Form

- - ### Field Summary

    - ### Fields inherited from class javax.servlet.jsp.tagext.BodyTagSupport

      `bodyContent`

    - ### Fields inherited from class javax.servlet.jsp.tagext.TagSupport

      `id, pageContext`

    - ### Fields inherited from interface javax.servlet.jsp.tagext.BodyTag

      `EVAL_BODY_BUFFERED, EVAL_BODY_TAG`

    - ### Fields inherited from interface javax.servlet.jsp.tagext.IterationTag

      `EVAL_BODY_AGAIN`

    - ### Fields inherited from interface javax.servlet.jsp.tagext.Tag

      `EVAL_BODY_INCLUDE, EVAL_PAGE, SKIP_BODY, SKIP_PAGE`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `Searchable()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `int` | `doAfterBody()`
    `String` | `getField()`
    `Boolean` | `getIndex()`
    `Boolean` | `getVisible()`
    `void` | `release()`
    `void` | `setField(String field)`
    `void` | `setIndex(Boolean index)`
    `void` | `setVisible(Boolean visible)`

    - ### Methods inherited from class javax.servlet.jsp.tagext.BodyTagSupport

      `doEndTag, doInitBody, doStartTag, getBodyContent, getPreviousOut, setBodyContent`

    - ### Methods inherited from class javax.servlet.jsp.tagext.TagSupport

      `findAncestorWithClass, getId, getParent, getValue, getValues, removeValue, setId, setPageContext, setParent, setValue`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

    - ### Methods inherited from interface javax.servlet.jsp.tagext.Tag

      `getParent, setPageContext, setParent`

- - ### Constructor Detail

    - #### Searchable

          public Searchable()

  - ### Method Detail

    - #### doAfterBody

          public int doAfterBody()

      Specified by:
        `doAfterBody` in interface `javax.servlet.jsp.tagext.IterationTag`
      Overrides:
        `doAfterBody` in class `javax.servlet.jsp.tagext.BodyTagSupport`

    - #### release

          public void release()

      Specified by:
        `release` in interface `javax.servlet.jsp.tagext.Tag`
      Overrides:
        `release` in class `javax.servlet.jsp.tagext.BodyTagSupport`

    - #### getIndex

          public Boolean getIndex()

    - #### setIndex

          public void setIndex(Boolean index)

    - #### getVisible

          public Boolean getVisible()

    - #### setVisible

          public void setVisible(Boolean visible)

    - #### getField

          public String getField()

    - #### setField

          public void setField(String field)

Copyright © 2011–2023 aiticon GmbH. All rights reserved.