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

## com.sun.syndication.feed.impl
Class ToStringBean

    java.lang.Object
      com.sun.syndication.feed.impl.ToStringBean

All Implemented Interfaces:
  Serializable

    public class ToStringBean

extends Object
implements Serializable

Provides deep Bean toString support.

It works on all read/write properties, recursively. It support all primitive types, Strings, Collections, ToString objects and multi-dimensional arrays of any of them.

Author:
  Alejandro Abdelnur
See Also:
  Serialized Form

Constructor Summary
`protected` | `ToStringBean(Class beanClass)` Default constructor.
`` | `ToStringBean(Class beanClass, Object obj)` Creates a ToStringBean to be used in a delegation pattern.

Method Summary
`String` | `toString()` Returns the String representation of the bean given in the constructor.

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

Constructor Detail

### ToStringBean

    protected ToStringBean(Class beanClass)

  Default constructor.

  To be used by classes extending ToStringBean only.

  Parameters:
    `beanClass` - indicates the class to scan for properties, normally an interface class.

### ToStringBean

    public ToStringBean(Class beanClass,
                        Object obj)

  Creates a ToStringBean to be used in a delegation pattern.

  For example:

  `public class Foo implements ToString { public String toString(String prefix) { ToStringBean tsb = new ToStringBean(this); return tsb.toString(prefix); } public String toString() { return toString("Foo"); } }`

  Parameters:
    `beanClass` - indicates the class to scan for properties, normally an interface class.
    `obj` - object bean to create String representation.

Method Detail

### toString

    public String toString()

  Returns the String representation of the bean given in the constructor.

  It uses the Class name as the prefix.

  Overrides:
    `toString` in class `Object`
  Returns:
    bean object String representation.

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

Copyright © 2004-2013 ROME Project. All Rights Reserved.