public class

StructuredPostalAddress

extends ExtensionPoint
java.lang.Object
   ↳ com.google.gdata.data.AbstractExtension
     ↳ com.google.gdata.data.ExtensionPoint
       ↳ com.google.gdata.data.extensions.StructuredPostalAddress

Class Overview

Describes a structured postal address.

Summary

Nested Classes
class StructuredPostalAddress.MailClass The mail class. 
class StructuredPostalAddress.Rel The postal address type. 
class StructuredPostalAddress.Usage The context for the address use. 
Constants
String LABEL XML "label" attribute name
String MAILCLASS XML "mailClass" attribute name
String PRIMARY XML "primary" attribute name
String REL XML "rel" attribute name
String USAGE XML "usage" attribute name
String XML_NAME XML element name
Fields
private String label Simple string value used to name this address
private String mailClass The mail class
private Boolean primary Whether this is the primary postal address
private String rel The postal address type
private String usage The context for the address use
[Expand]
Inherited Fields
From class com.google.gdata.data.ExtensionPoint
From class com.google.gdata.data.AbstractExtension
Public Constructors
StructuredPostalAddress()
Default mutable constructor.
StructuredPostalAddress(String label, String mailClass, Boolean primary, String rel, String usage)
Immutable constructor.
Public Methods
void declareExtensions(ExtensionProfile extProfile)
Declares the set of expected Extension types for an ExtensionPoint within the target extension profile.
Agent getAgent()
Returns the Used in work addresses.
City getCity()
Returns the Can be city, village, town, borough, etc.
Country getCountry()
Returns the The country name.
static ExtensionDescription getDefaultDescription(boolean required, boolean repeatable)
Returns the extension description, specifying whether it is required, and whether it is repeatable.
FormattedAddress getFormattedAddress()
Returns the The full, unstructured address.
HouseName getHousename()
Returns the Used in places where houses or buildings have names.
String getLabel()
Returns the Simple string value used to name this address.
String getMailClass()
Returns the The mail class.
Neighborhood getNeighborhood()
Returns the Neighborhood.
PoBox getPobox()
Returns the P.O.
PostCode getPostcode()
Returns the Postal code.
Boolean getPrimary()
Returns the whether this is the primary postal address.
Region getRegion()
Returns the Region is state, province, county (in Ireland), Land (in Germany), departement (in France), etc.
String getRel()
Returns the the postal address type.
Street getStreet()
Returns the Can be street, avenue, road, etc.
Subregion getSubregion()
Returns the Subregion is county (US), province (in Italy), etc.
String getUsage()
Returns the The context for the address use.
boolean hasAgent()
Returns whether it has the Used in work addresses.
boolean hasCity()
Returns whether it has the Can be city, village, town, borough, etc.
boolean hasCountry()
Returns whether it has the The country name.
boolean hasFormattedAddress()
Returns whether it has the The full, unstructured address.
boolean hasHousename()
Returns whether it has the Used in places where houses or buildings have names.
boolean hasLabel()
Returns whether it has the Simple string value used to name this address.
boolean hasMailClass()
Returns whether it has the The mail class.
boolean hasNeighborhood()
Returns whether it has the Neighborhood.
boolean hasPobox()
Returns whether it has the P.O.
boolean hasPostcode()
Returns whether it has the Postal code.
boolean hasPrimary()
Returns whether it has the whether this is the primary postal address.
boolean hasRegion()
Returns whether it has the Region is state, province, county (in Ireland), Land (in Germany), departement (in France), etc.
boolean hasRel()
Returns whether it has the the postal address type.
boolean hasStreet()
Returns whether it has the Can be street, avenue, road, etc.
boolean hasSubregion()
Returns whether it has the Subregion is county (US), province (in Italy), etc.
boolean hasUsage()
Returns whether it has the The context for the address use.
void setAgent(Agent agent)
Sets the Used in work addresses.
void setCity(City city)
Sets the Can be city, village, town, borough, etc.
void setCountry(Country country)
Sets the The country name.
void setFormattedAddress(FormattedAddress formattedAddress)
Sets the The full, unstructured address.
void setHousename(HouseName housename)
Sets the Used in places where houses or buildings have names.
void setLabel(String label)
Sets the Simple string value used to name this address.
void setMailClass(String mailClass)
Sets the The mail class.
void setNeighborhood(Neighborhood neighborhood)
Sets the Neighborhood.
void setPobox(PoBox pobox)
Sets the P.O.
void setPostcode(PostCode postcode)
Sets the Postal code.
void setPrimary(Boolean primary)
Sets the whether this is the primary postal address.
void setRegion(Region region)
Sets the Region is state, province, county (in Ireland), Land (in Germany), departement (in France), etc.
void setRel(String rel)
Sets the the postal address type.
void setStreet(Street street)
Sets the Can be street, avenue, road, etc.
void setSubregion(Subregion subregion)
Sets the Subregion is county (US), province (in Italy), etc.
void setUsage(String usage)
Sets the The context for the address use.
String toString()
Protected Methods
void consumeAttributes(AttributeHelper helper)
Consumes attributes from the attribute helper.
void putAttributes(AttributeGenerator generator)
Puts attributes into the attribute generator.
void validate()
Checks the attributes to see if there are any problems.
[Expand]
Inherited Methods
From class com.google.gdata.data.ExtensionPoint
From class com.google.gdata.data.AbstractExtension
From class java.lang.Object
From interface com.google.gdata.data.Extension

Constants

private static final String LABEL

XML "label" attribute name

Constant Value: "label"

private static final String MAILCLASS

XML "mailClass" attribute name

Constant Value: "mailClass"

private static final String PRIMARY

XML "primary" attribute name

Constant Value: "primary"

private static final String REL

XML "rel" attribute name

Constant Value: "rel"

private static final String USAGE

XML "usage" attribute name

Constant Value: "usage"

static final String XML_NAME

XML element name

Constant Value: "structuredPostalAddress"

Fields

private String label

Simple string value used to name this address

private String mailClass

The mail class

private Boolean primary

Whether this is the primary postal address

private String rel

The postal address type

private String usage

The context for the address use

Public Constructors

public StructuredPostalAddress ()

Default mutable constructor.

public StructuredPostalAddress (String label, String mailClass, Boolean primary, String rel, String usage)

Immutable constructor.

Parameters
label Simple string value used to name this address.
mailClass The mail class.
primary Whether this is the primary postal address.
rel The postal address type.
usage The context for the address use.

Public Methods

public void declareExtensions (ExtensionProfile extProfile)

Declares the set of expected Extension types for an ExtensionPoint within the target extension profile. The base implementation does not declare any extensions, but can be overridden by specific types of ExtensionPoints that always contain a well-defined set of extensions.

Parameters
extProfile The ExtensionProfile to initialize.

public Agent getAgent ()

Returns the Used in work addresses. Also for 'in care of' or 'c/o'.

Returns
  • Used in work addresses. Also for 'in care of' or 'c/o'

public City getCity ()

Returns the Can be city, village, town, borough, etc.

Returns
  • Can be city, village, town, borough, etc

public Country getCountry ()

Returns the The country name.

Returns
  • The country name

public static ExtensionDescription getDefaultDescription (boolean required, boolean repeatable)

Returns the extension description, specifying whether it is required, and whether it is repeatable.

Parameters
required Whether it is required
repeatable Whether it is repeatable
Returns
  • extension description

public FormattedAddress getFormattedAddress ()

Returns the The full, unstructured address.

Returns
  • The full, unstructured address

public HouseName getHousename ()

Returns the Used in places where houses or buildings have names.

Returns
  • Used in places where houses or buildings have names

public String getLabel ()

Returns the Simple string value used to name this address.

Returns
  • Simple string value used to name this address

public String getMailClass ()

Returns the The mail class.

Returns
  • The mail class

public Neighborhood getNeighborhood ()

Returns the Neighborhood. Used to disambiguate a street.

Returns
  • Neighborhood. Used to disambiguate a street

public PoBox getPobox ()

Returns the P.O. box.

Returns
  • P.O. box

public PostCode getPostcode ()

Returns the Postal code.

Returns
  • Postal code

public Boolean getPrimary ()

Returns the whether this is the primary postal address.

Returns
  • whether this is the primary postal address

public Region getRegion ()

Returns the Region is state, province, county (in Ireland), Land (in Germany), departement (in France), etc.

Returns
  • Region is state, province, county (in Ireland), Land (in Germany), departement (in France), etc

public String getRel ()

Returns the the postal address type.

Returns
  • the postal address type

public Street getStreet ()

Returns the Can be street, avenue, road, etc. This element also includes the house number and room/apartment/flat/floor number.

Returns
  • Can be street, avenue, road, etc. This element also includes the house number and room/apartment/flat/floor number

public Subregion getSubregion ()

Returns the Subregion is county (US), province (in Italy), etc.

Returns
  • Subregion is county (US), province (in Italy), etc

public String getUsage ()

Returns the The context for the address use.

Returns
  • The context for the address use

public boolean hasAgent ()

Returns whether it has the Used in work addresses. Also for 'in care of' or 'c/o'.

Returns
  • whether it has the Used in work addresses. Also for 'in care of' or 'c/o'

public boolean hasCity ()

Returns whether it has the Can be city, village, town, borough, etc.

Returns
  • whether it has the Can be city, village, town, borough, etc

public boolean hasCountry ()

Returns whether it has the The country name.

Returns
  • whether it has the The country name

public boolean hasFormattedAddress ()

Returns whether it has the The full, unstructured address.

Returns
  • whether it has the The full, unstructured address

public boolean hasHousename ()

Returns whether it has the Used in places where houses or buildings have names.

Returns
  • whether it has the Used in places where houses or buildings have names

public boolean hasLabel ()

Returns whether it has the Simple string value used to name this address.

Returns
  • whether it has the Simple string value used to name this address

public boolean hasMailClass ()

Returns whether it has the The mail class.

Returns
  • whether it has the The mail class

public boolean hasNeighborhood ()

Returns whether it has the Neighborhood. Used to disambiguate a street.

Returns
  • whether it has the Neighborhood. Used to disambiguate a street

public boolean hasPobox ()

Returns whether it has the P.O. box.

Returns
  • whether it has the P.O. box

public boolean hasPostcode ()

Returns whether it has the Postal code.

Returns
  • whether it has the Postal code

public boolean hasPrimary ()

Returns whether it has the whether this is the primary postal address.

Returns
  • whether it has the whether this is the primary postal address

public boolean hasRegion ()

Returns whether it has the Region is state, province, county (in Ireland), Land (in Germany), departement (in France), etc.

Returns
  • whether it has the Region is state, province, county (in Ireland), Land (in Germany), departement (in France), etc

public boolean hasRel ()

Returns whether it has the the postal address type.

Returns
  • whether it has the the postal address type

public boolean hasStreet ()

Returns whether it has the Can be street, avenue, road, etc. This element also includes the house number and room/apartment/flat/floor number.

Returns
  • whether it has the Can be street, avenue, road, etc. This element also includes the house number and room/apartment/flat/floor number

public boolean hasSubregion ()

Returns whether it has the Subregion is county (US), province (in Italy), etc.

Returns
  • whether it has the Subregion is county (US), province (in Italy), etc

public boolean hasUsage ()

Returns whether it has the The context for the address use.

Returns
  • whether it has the The context for the address use

public void setAgent (Agent agent)

Sets the Used in work addresses. Also for 'in care of' or 'c/o'.

Parameters
agent Used in work addresses. Also for 'in care of' or 'c/o' or null to reset

public void setCity (City city)

Sets the Can be city, village, town, borough, etc.

Parameters
city Can be city, village, town, borough, etc or null to reset

public void setCountry (Country country)

Sets the The country name.

Parameters
country The country name or null to reset

public void setFormattedAddress (FormattedAddress formattedAddress)

Sets the The full, unstructured address.

Parameters
formattedAddress The full, unstructured address or null to reset

public void setHousename (HouseName housename)

Sets the Used in places where houses or buildings have names.

Parameters
housename Used in places where houses or buildings have names or null to reset

public void setLabel (String label)

Sets the Simple string value used to name this address.

Parameters
label Simple string value used to name this address or null to reset

public void setMailClass (String mailClass)

Sets the The mail class.

Parameters
mailClass The mail class or null to reset

public void setNeighborhood (Neighborhood neighborhood)

Sets the Neighborhood. Used to disambiguate a street.

Parameters
neighborhood Neighborhood. Used to disambiguate a street or null to reset

public void setPobox (PoBox pobox)

Sets the P.O. box.

Parameters
pobox P.O. box or null to reset

public void setPostcode (PostCode postcode)

Sets the Postal code.

Parameters
postcode Postal code or null to reset

public void setPrimary (Boolean primary)

Sets the whether this is the primary postal address.

Parameters
primary Whether this is the primary postal address or null to reset

public void setRegion (Region region)

Sets the Region is state, province, county (in Ireland), Land (in Germany), departement (in France), etc.

Parameters
region Region is state, province, county (in Ireland), Land (in Germany), departement (in France), etc or null to reset

public void setRel (String rel)

Sets the the postal address type.

Parameters
rel The postal address type or null to reset

public void setStreet (Street street)

Sets the Can be street, avenue, road, etc. This element also includes the house number and room/apartment/flat/floor number.

Parameters
street Can be street, avenue, road, etc. This element also includes the house number and room/apartment/flat/floor number or null to reset

public void setSubregion (Subregion subregion)

Sets the Subregion is county (US), province (in Italy), etc.

Parameters
subregion Subregion is county (US), province (in Italy), etc or null to reset

public void setUsage (String usage)

Sets the The context for the address use.

Parameters
usage The context for the address use or null to reset

public String toString ()

Protected Methods

protected void consumeAttributes (AttributeHelper helper)

Consumes attributes from the attribute helper. May also use consumeContent(boolean) to consume the element's text content. Called from getHandler(ExtensionProfile, String, String, Attributes). Default implementation does nothing, though generally this is discouraged unless there really are no attributes.

Parameters
helper Attribute helper

protected void putAttributes (AttributeGenerator generator)

Puts attributes into the attribute generator. Called from generate(XmlWriter, ExtensionProfile). Default implementation does nothing, though generally this is discouraged unless there really are no attributes.

Parameters
generator Attribute generator

protected void validate ()

Checks the attributes to see if there are any problems. Default implementation does nothing, though generally this is discouraged unless there really are no restrictions.