com.google.api.client.googleapis.xml.atom
Class GoogleAtom

java.lang.Object
  extended by com.google.api.client.googleapis.xml.atom.GoogleAtom

public class GoogleAtom
extends Object

Utilities for working with the Atom XML of Google Data APIs.

Since:
1.0
Author:
Yaniv Inbar

Field Summary
static String ERROR_CONTENT_TYPE
          Content type used on an error formatted in XML.
static String GD_NAMESPACE
          GData namespace.
 
Method Summary
static Map<String,Object> computePatch(Object patched, Object original)
          Compute the patch object of key/value pairs from the given original and patched objects, adding a @gd:fields key for the fields mask.
static String getFeedFields(Class<?> feedClass, Class<?> entryClass)
          Returns the fields mask to use for the given data class of key/value pairs for the feed class and for the entry class.
static String getFieldsFor(Class<?> dataClass)
          Returns the fields mask to use for the given data class of key/value pairs.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

GD_NAMESPACE

public static final String GD_NAMESPACE
GData namespace.

Since:
1.0
See Also:
Constant Field Values

ERROR_CONTENT_TYPE

public static final String ERROR_CONTENT_TYPE
Content type used on an error formatted in XML.

Since:
1.5
See Also:
Constant Field Values
Method Detail

getFieldsFor

public static String getFieldsFor(Class<?> dataClass)
Returns the fields mask to use for the given data class of key/value pairs. It cannot be a Map, GenericData or a Collection.

Parameters:
dataClass - data class of key/value pairs

getFeedFields

public static String getFeedFields(Class<?> feedClass,
                                   Class<?> entryClass)
Returns the fields mask to use for the given data class of key/value pairs for the feed class and for the entry class. This should only be used if the feed class does not contain the entry class as a field. The data classes cannot be a Map, GenericData or a Collection.

Parameters:
feedClass - feed data class
entryClass - entry data class

computePatch

public static Map<String,Object> computePatch(Object patched,
                                              Object original)
Compute the patch object of key/value pairs from the given original and patched objects, adding a @gd:fields key for the fields mask.

Parameters:
patched - patched object
original - original object
Returns:
patch object of key/value pairs


Copyright © 2010-2012 Google. All Rights Reserved.