public class

CustomVariable

extends ExtensionPoint
java.lang.Object
   ↳ com.google.gdata.data.AbstractExtension
     ↳ com.google.gdata.data.ExtensionPoint
       ↳ com.google.gdata.data.analytics.CustomVariable

Class Overview

Data about a user-defined custom variable.

Summary

Nested Classes
class CustomVariable.Scope Scope. 
Constants
String INDEX XML "index" attribute name
String NAME XML "name" attribute name
String SCOPE XML "scope" attribute name
String XML_NAME XML element name
Fields
private Integer index Index
private String name Name
private String scope Scope
[Expand]
Inherited Fields
From class com.google.gdata.data.ExtensionPoint
From class com.google.gdata.data.AbstractExtension
Public Constructors
CustomVariable()
Default mutable constructor.
CustomVariable(Integer index, String name, String scope)
Immutable constructor.
Public Methods
boolean equals(Object obj)
static ExtensionDescription getDefaultDescription(boolean required, boolean repeatable)
Returns the extension description, specifying whether it is required, and whether it is repeatable.
Integer getIndex()
Returns the index.
String getName()
Returns the name.
String getScope()
Returns the scope.
boolean hasIndex()
Returns whether it has the index.
boolean hasName()
Returns whether it has the name.
boolean hasScope()
Returns whether it has the scope.
int hashCode()
void setIndex(Integer index)
Sets the index.
void setName(String name)
Sets the name.
void setScope(String scope)
Sets the scope.
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 INDEX

XML "index" attribute name

Constant Value: "index"

private static final String NAME

XML "name" attribute name

Constant Value: "name"

private static final String SCOPE

XML "scope" attribute name

Constant Value: "scope"

static final String XML_NAME

XML element name

Constant Value: "customVariable"

Fields

private Integer index

Index

private String name

Name

private String scope

Scope

Public Constructors

public CustomVariable ()

Default mutable constructor.

public CustomVariable (Integer index, String name, String scope)

Immutable constructor.

Parameters
index Index.
name Name.
scope Scope.

Public Methods

public boolean equals (Object obj)

Parameters
obj

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 Integer getIndex ()

Returns the index.

Returns
  • index

public String getName ()

Returns the name.

Returns
  • name

public String getScope ()

Returns the scope.

Returns
  • scope

public boolean hasIndex ()

Returns whether it has the index.

Returns
  • whether it has the index

public boolean hasName ()

Returns whether it has the name.

Returns
  • whether it has the name

public boolean hasScope ()

Returns whether it has the scope.

Returns
  • whether it has the scope

public int hashCode ()

public void setIndex (Integer index)

Sets the index.

Parameters
index Index or null to reset

public void setName (String name)

Sets the name.

Parameters
name Name or null to reset

public void setScope (String scope)

Sets the scope.

Parameters
scope Scope 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.