Project Wonder 5.0

er.rest.format
Class ERXRestFormat

java.lang.Object
  extended by er.rest.format.ERXRestFormat

public class ERXRestFormat
extends java.lang.Object


Nested Class Summary
static interface ERXRestFormat.Delegate
           
static class ERXRestFormat.NoOpDelegate
           
 
Field Summary
static ERXRestFormat GIANDUIA_JSON
           
static ERXRestFormat GIANDUIA_PERSISTENT_STORE
           
static ERXRestFormat HTML
           
static ERXRestFormat JS
           
static ERXRestFormat JSON
           
static ERXRestFormat PLIST
           
static ERXRestFormat RAILS
           
static ERXRestFormat SPROUTCORE
           
static ERXRestFormat XML
           
 
Constructor Summary
ERXRestFormat(java.lang.String name, IERXRestParser parser, IERXRestWriter writer, ERXRestFormat.Delegate delegate)
           
 
Method Summary
 ERXRestFormat.Delegate delegate()
           
static ERXRestFormat formatNamed(java.lang.String name)
           
 java.lang.String name()
          Returns the name of this format.
 ERXRestRequestNode parse(java.lang.String str)
          Returns a parsed ERXRestRequestNode using this format's parser.
 IERXRestParser parser()
           
static ERXRestFormat registerFormatNamed(ERXRestFormat format, java.lang.String name)
           
static ERXRestFormat registerFormatNamed(IERXRestParser parser, IERXRestWriter writer, ERXRestFormat.Delegate delegate, java.lang.String... names)
           
 java.lang.String toString()
           
 java.lang.String toString(com.webobjects.eocontrol.EOClassDescription classDescription, java.util.List<?> list, ERXKeyFilter filter, IERXRestDelegate delegate)
          Returns the formatted version of the given list.
 java.lang.String toString(java.lang.Object obj)
          Returns the formatted version of the given object using a recursive "All" filter and the default rest delegate.
 java.lang.String toString(java.lang.Object obj, ERXKeyFilter filter, IERXRestDelegate delegate)
          Returns the formatted version of the given object.
 java.lang.String toString(java.lang.Object obj, IERXRestDelegate delegate)
          Returns the formatted version of the given object using a recursive "All" filter.
 IERXRestWriter writer()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

JSON

public static ERXRestFormat JSON

JS

public static ERXRestFormat JS

PLIST

public static ERXRestFormat PLIST

RAILS

public static ERXRestFormat RAILS

XML

public static ERXRestFormat XML

HTML

public static ERXRestFormat HTML

GIANDUIA_JSON

public static ERXRestFormat GIANDUIA_JSON

GIANDUIA_PERSISTENT_STORE

public static ERXRestFormat GIANDUIA_PERSISTENT_STORE

SPROUTCORE

public static ERXRestFormat SPROUTCORE
Constructor Detail

ERXRestFormat

public ERXRestFormat(java.lang.String name,
                     IERXRestParser parser,
                     IERXRestWriter writer,
                     ERXRestFormat.Delegate delegate)
Method Detail

name

public java.lang.String name()
Returns the name of this format.

Returns:
the name of this format

parser

public IERXRestParser parser()

writer

public IERXRestWriter writer()

delegate

public ERXRestFormat.Delegate delegate()

parse

public ERXRestRequestNode parse(java.lang.String str)
Returns a parsed ERXRestRequestNode using this format's parser.

Parameters:
str - the string to parse
Returns:
the parsed request node

toString

public java.lang.String toString(java.lang.Object obj)
Returns the formatted version of the given object using a recursive "All" filter and the default rest delegate.

Parameters:
obj - the object to render
Returns:
obj rendered using this format

toString

public java.lang.String toString(java.lang.Object obj,
                                 IERXRestDelegate delegate)
Returns the formatted version of the given object using a recursive "All" filter.

Parameters:
obj - the object to render
delegate - the rest delegate to use
Returns:
obj rendered using this format

toString

public java.lang.String toString(java.lang.Object obj,
                                 ERXKeyFilter filter,
                                 IERXRestDelegate delegate)
Returns the formatted version of the given object.

Parameters:
obj - the object to render
filter - the filter to apply to the object
delegate - the rest delegate to use
Returns:
obj rendered using this format

toString

public java.lang.String toString(com.webobjects.eocontrol.EOClassDescription classDescription,
                                 java.util.List<?> list,
                                 ERXKeyFilter filter,
                                 IERXRestDelegate delegate)
Returns the formatted version of the given list.

Parameters:
classDescription - the class description for the elements of the list
list - the list
filter - the filter
delegate - the rest delegate to use
Returns:
list rendered using this format

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

formatNamed

public static ERXRestFormat formatNamed(java.lang.String name)

registerFormatNamed

public static ERXRestFormat registerFormatNamed(IERXRestParser parser,
                                                IERXRestWriter writer,
                                                ERXRestFormat.Delegate delegate,
                                                java.lang.String... names)

registerFormatNamed

public static ERXRestFormat registerFormatNamed(ERXRestFormat format,
                                                java.lang.String name)

Last updated: Tue, Feb 21, 2017 • 05:45 PM CET

Copyright © 2002 – 2007 Project Wonder.