# Google Data APIs Client Library (1.43.0)

## com.google.gdata.data
Class Person

    java.lang.Object
      com.google.gdata.data.AbstractExtension
          com.google.gdata.data.ExtensionPoint
              com.google.gdata.data.Person

All Implemented Interfaces:
  Extension, IPerson

Direct Known Subclasses:
  CommentAuthor, LastModifiedBy, SidewikiAuthor

    public class Person

extends ExtensionPoint
implements IPerson

Person type used for feed and entry authors and contributors. It may also be used by services' custom elements.

Nested Class Summary
`class` `Person.AtomHandler` Parses XML in the Atom format.

Nested classes/interfaces inherited from class com.google.gdata.data.ExtensionPoint
`ExtensionPoint.CumulativeBlobHandler, ExtensionPoint.ExtensionHandler`

Nested classes/interfaces inherited from class com.google.gdata.data.AbstractExtension
`AbstractExtension.AttributesHandler`

Field Summary
`protected java.lang.String` `email` Email address.
`protected java.lang.String` `name` Human-readable name.
`protected java.lang.String` `nameLang` Language of name.
`protected java.lang.String` `uri` URI associated with the person.

Fields inherited from class com.google.gdata.data.ExtensionPoint
`xmlBlob`

Fields inherited from class com.google.gdata.data.AbstractExtension
`localName, namespace`

Constructor Summary
`Person()` Class constructor.
`Person(java.lang.String name)` Constructs a new Person instance with the specified name.
`Person(java.lang.String name, java.lang.String uri, java.lang.String email)` Constructs a new Person instance with the specified name, URI, and email address.

Method Summary
`void` `generate(ExtensionProfile extProfile, com.google.gdata.util.common.xml.XmlWriter w, com.google.gdata.util.common.xml.XmlNamespace elementNamespace, java.lang.String elementName, java.util.Collection<com.google.gdata.util.common.xml.XmlWriter.Attribute> attributes)` Generates XML.
`protected void` `generate(com.google.gdata.util.common.xml.XmlWriter w, ExtensionProfile p, com.google.gdata.util.common.xml.XmlNamespace namespace, java.lang.String localName, java.util.List<com.google.gdata.util.common.xml.XmlWriter.Attribute> attrs, AttributeGenerator generator)` Generates XML.
`void` `generateAtom(ExtensionProfile extProfile, com.google.gdata.util.common.xml.XmlWriter w, java.lang.String elementName)` Generates XML in the Atom format.
`void` `generateRss(com.google.gdata.util.common.xml.XmlWriter w, java.lang.String elementName)` Generates XML in the RSS format.
`java.lang.String` `getEmail()` Email address.
`XmlParser.ElementHandler` `getHandler(ExtensionProfile extProfile, java.lang.String namespace, java.lang.String localName, org.xml.sax.Attributes attrs)` The default implementation uses the `AbstractExtension.AttributesHandler` to handle parsing the extension.
`java.lang.String` `getName()` Human-readable name.
`java.lang.String` `getNameLang()` Language of name
`java.lang.String` `getUri()` Uri associated with the person
`void` `setEmail(java.lang.String v)`
`void` `setName(java.lang.String v)`
`void` `setNameLang(java.lang.String v)`
`void` `setUri(java.lang.String v)`

Methods inherited from class com.google.gdata.data.ExtensionPoint

`addExtension, addExtension, addRepeatingExtension, addRepeatingExtension, checkRequiredExtensions, createExtensionInstance, declareExtensions, generateCumulativeXmlBlob, generateExtensions, generateStartElement, getExtension, getExtensionDescription, getExtensionHandler, getExtensions, getManifest, getRepeatingExtension, getRepeatingExtensions, getXmlBlob, hasExtension, hasRepeatingExtension, initializeArbitraryXml, parseCumulativeXmlBlob, removeExtension, removeExtension, removeRepeatingExtension, setExtension, setXmlBlob, visit, visitChild, visitChildren`

Methods inherited from class com.google.gdata.data.AbstractExtension
`consumeAttributes, disableStrictValidation, enableStrictValidation, eq, generate, generateAttributes, getExtensionLocalName, getExtensionNamespace, isImmutable, isStrictValidation, putAttributes, sameClassAs, setImmutable, throwExceptionForMissingAttribute, throwExceptionIfImmutable, validate`

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

Field Detail

### name

    protected java.lang.String name

  Human-readable name.

### nameLang

    protected java.lang.String nameLang

  Language of name. Derived from the current state of `xml:lang`.

### uri

    protected java.lang.String uri

  URI associated with the person.

### email

    protected java.lang.String email

  Email address.

Constructor Detail

### Person

    public Person()

  Class constructor.

### Person

    public Person(java.lang.String name)

  Constructs a new Person instance with the specified name.

### Person

    public Person(java.lang.String name,
                  java.lang.String uri,
                  java.lang.String email)

  Constructs a new Person instance with the specified name, URI, and email address.

Method Detail

### getName

    public java.lang.String getName()

  Description copied from interface: `IPerson`
  Human-readable name.

  Specified by:
    `getName` in interface `IPerson`

### setName

    public void setName(java.lang.String v)

### getNameLang

    public java.lang.String getNameLang()

  Description copied from interface: `IPerson`
  Language of name

  Specified by:
    `getNameLang` in interface `IPerson`

### setNameLang

    public void setNameLang(java.lang.String v)

### getUri

    public java.lang.String getUri()

  Description copied from interface: `IPerson`
  Uri associated with the person

  Specified by:
    `getUri` in interface `IPerson`

### setUri

    public void setUri(java.lang.String v)

### getEmail

    public java.lang.String getEmail()

  Description copied from interface: `IPerson`
  Email address.

  Specified by:
    `getEmail` in interface `IPerson`

### setEmail

    public void setEmail(java.lang.String v)

### generate

    public void generate(ExtensionProfile extProfile,
                         com.google.gdata.util.common.xml.XmlWriter w,
                         com.google.gdata.util.common.xml.XmlNamespace elementNamespace,
                         java.lang.String elementName,
                         java.util.Collection<com.google.gdata.util.common.xml.XmlWriter.Attribute> attributes)
                  throws java.io.IOException

  Generates XML.

  Designed to be used by types that reuse the standard Atom person type.

  Parameters:
    `extProfile` - extension profile
    `w` - output writer
    `elementNamespace` - namespace for XML element
    `elementName` - name of XML element
    `attributes` - additional attributes
  Throws:
    `java.io.IOException`

### generate

    protected void generate(com.google.gdata.util.common.xml.XmlWriter w,
                            ExtensionProfile p,
                            com.google.gdata.util.common.xml.XmlNamespace namespace,
                            java.lang.String localName,
                            java.util.List<com.google.gdata.util.common.xml.XmlWriter.Attribute> attrs,
                            AttributeGenerator generator)
                     throws java.io.IOException

  Generates XML.

  Designed to be used by `ExtensionPoint` types that reuse Person.

  Overrides:
    `generate` in class `ExtensionPoint`
  Parameters:
    `w` - XML writer
    `p` - extension profile
    `namespace` - XML namespace for this extension
    `localName` - XML local name for this extension
    `attrs` - list of XML attributes
    `generator` - attribute generator
  Throws:
    `java.io.IOException` - any I/O exception

### generateAtom

    public void generateAtom(ExtensionProfile extProfile,
                             com.google.gdata.util.common.xml.XmlWriter w,
                             java.lang.String elementName)
                      throws java.io.IOException

  Generates XML in the Atom format.

  Parameters:
    `extProfile` - extension profile
    `w` - output writer
    `elementName` - Atom element name
  Throws:
    `java.io.IOException`

### generateRss

    public void generateRss(com.google.gdata.util.common.xml.XmlWriter w,
                            java.lang.String elementName)
                     throws java.io.IOException

  Generates XML in the RSS format.

  Parameters:
    `w` - output writer
    `elementName` - RSS element name
  Throws:
    `java.io.IOException`

### getHandler

    public XmlParser.ElementHandler getHandler(ExtensionProfile extProfile,
                                               java.lang.String namespace,
                                               java.lang.String localName,
                                               org.xml.sax.Attributes attrs)

  Description copied from class: `AbstractExtension`
  The default implementation uses the `AbstractExtension.AttributesHandler` to handle parsing the extension.

  Specified by:
    `getHandler` in interface `Extension`
  Overrides:
    `getHandler` in class `ExtensionPoint`
  Parameters:
    `extProfile` - extension profile
    `namespace` - extension namespace
    `localName` - tag name, without the namespace prefix
    `attrs` - tag attributes
  Returns:
    an element handler