org.yaml.snakeyaml
Class JavaBeanParser

java.lang.Object
  extended by org.yaml.snakeyaml.JavaBeanParser

Deprecated. use JavaBeanLoader instead

public class JavaBeanParser
extends Object

Convenience utility to parse JavaBeans. The returned instance is enforced to be of the same class as the provided argument. All the methods are Thread safe. When the YAML document contains a global tag with the class definition like '!!com.package.MyBean' it is ignored in favour of the runtime class.


Method Summary
static
<T> T
load(InputStream io, Class<T> javabean)
          Deprecated. Parse the first YAML document in a stream and produce the corresponding JavaBean.
static
<T> T
load(Reader io, Class<T> javabean)
          Deprecated. Parse the first YAML document in a stream and produce the corresponding Java object.
static
<T> T
load(String yaml, Class<T> javabean)
          Deprecated. Parse the first YAML document in a stream and produce the corresponding JavaBean.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

load

public static <T> T load(String yaml,
                         Class<T> javabean)
Deprecated. 
Parse the first YAML document in a stream and produce the corresponding JavaBean.

Parameters:
yaml - YAML document
javabean - JavaBean class to be parsed
Returns:
parsed JavaBean

load

public static <T> T load(InputStream io,
                         Class<T> javabean)
Deprecated. 
Parse the first YAML document in a stream and produce the corresponding JavaBean.

Parameters:
io - data to load from (BOM is respected and removed)
javabean - JavaBean class to be parsed
Returns:
parsed JavaBean

load

public static <T> T load(Reader io,
                         Class<T> javabean)
Deprecated. 
Parse the first YAML document in a stream and produce the corresponding Java object.

Parameters:
io - data to load from (BOM must not be present)
javabean - JavaBean class to be parsed
Returns:
parsed JavaBean


Copyright © 2008-2010. All Rights Reserved.