Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.struts.taglib.template.util
Class Content

    java.lang.Object
      |
      +--org.apache.struts.taglib.template.util.Content

All Implemented Interfaces:
  java.io.Serializable

public class Content
extends java.lang.Object
implements java.io.Serializable

A utility file for templates.

This represents template content, which is included by templates. Templates can also treat content as plain text and print it to the implicit out variable. This simple class maintain two properties:

- content: A string representing either a URI or text.
- direct: If true, content is printed; otherwise content is included (default is false).

Author:
  David Geary
See Also:
  Serialized Form

Field Summary
`private java.lang.String` | `content` Templates regard this as content to be either included or printed directly. This is a blank final that is set at construction.
`private java.lang.String` | `direct` Represents a boolean; if true, content is included, otherwise content is printed. This is a blank final that is set at construction. This is a string instead of a boolean as a convenience for the tags, whose corresponding attribute is a string.

Constructor Summary
`Content(java.lang.String content, java.lang.String direct)` The only constructor.

Method Summary
`java.lang.String` | `getContent()` Return content
`boolean` | `isDirect()` Is content to be printed directly (isDirect() == true) instead of included (isDirect() == false)?
`java.lang.String` | `toString()` Returns a string representation of the content

Methods inherited from class java.lang.Object
`, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, wait, wait, wait`

Field Detail

### content

    private final java.lang.String content

  Templates regard this as content to be either included or printed directly.
  This is a blank final that is set at construction.

### direct

    private final java.lang.String direct

  Represents a boolean; if true, content is included, otherwise content is printed.
  This is a blank final that is set at construction.
  This is a string instead of a boolean as a convenience for the tags, whose corresponding attribute is a string.

Constructor Detail

### Content

    public Content(java.lang.String content,
                   java.lang.String direct)

  The only constructor.
  Parameters:
    `content` - The content's URI
    `direct` - Is content printed directly (true) or included (false)?

Method Detail

### getContent

    public java.lang.String getContent()

  Return content

### isDirect

    public boolean isDirect()

  Is content to be printed directly (isDirect() == true)
  instead of included (isDirect() == false)?

### toString

    public java.lang.String toString()

  Returns a string representation of the content
  Overrides:
    `toString` in class `java.lang.Object`

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2000-2001 - Apache Software Foundation