# Google Data APIs Client Library (1.43.0)

## com.google.gdata.data.youtube
Class SubscriptionEntry

    java.lang.Object
      com.google.gdata.data.AbstractExtension
          com.google.gdata.data.ExtensionPoint
              com.google.gdata.data.BaseEntry<T>
                  com.google.gdata.data.youtube.FeedLinkEntry<SubscriptionEntry>
                      com.google.gdata.data.youtube.SubscriptionEntry

All Implemented Interfaces:
  Extension, IAtom, IEntry, Kind.Adaptable, Kind.Adaptor

    public class SubscriptionEntry

extends FeedLinkEntry<SubscriptionEntry>

Entries that appear on the publisher playlist feed. This entry does not contain a playlist, but a link to a playlist. See `PlaylistFeed` and `PlaylistEntry` for the playlist feed objects.

Nested Class Summary
`static class` `SubscriptionEntry.Type` Subscription types.

Nested classes/interfaces inherited from class com.google.gdata.data.BaseEntry
`BaseEntry.AtomHandler, BaseEntry.EntryState`

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
`static java.lang.String[]` `CATEGORIES` Nonstandard categories that might be found in this entry.

Fields inherited from class com.google.gdata.data.BaseEntry
`state`

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

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

Constructor Summary
`SubscriptionEntry()`
`SubscriptionEntry(BaseEntry<?> base)`

Method Summary
`void` `addSubscriptionType(SubscriptionEntry.Type type)` Adds a type category to this entry.
`void` `declareExtensions(ExtensionProfile extProfile)` Declares the set of expected Extension types for an ExtensionPoint within the target extension profile.
`java.lang.String` `getPlaylistId()` Get the id of the playlist subscribed to.
`java.lang.String` `getPlaylistTitle()` Get the title of the playlist subscribed to.
`java.lang.String` `getQueryString()` Get the query string of the subscription.
`SubscriptionEntry.Type` `getSubscriptionType()` Gets the type of the subscription, if it is of a known type.
`java.lang.String` `getUsername()` Get the value of the optional username
`void` `setPlaylistId(java.lang.String playlistId)` Set the optional id of the playlist subscribed to.
`void` `setPlaylistTitle(java.lang.String playlistTitle)` Set the title of the playlist subscribed to.
`void` `setQueryString(java.lang.String query)` Set the optional query string of a subscription with the type query.
`void` `setSubscriptionType(SubscriptionEntry.Type type)` Sets the type category of this entry.
`void` `setUsername(java.lang.String username)` Set the optional username.

Methods inherited from class com.google.gdata.data.youtube.FeedLinkEntry
`getCountHint, getDescription, getFeedLink, getFeedUrl, getThumbnail, setCountHint, setDescription, setFeedLink, setThumbnail`

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

`addAdaptor, addHtmlLink, addLink, addLink, delete, generate, generateAtom, generateRss, getAdaptedEntry, getAdaptor, getAdaptors, getAuthors, getCanEdit, getCategories, getContent, getContentHandlerInfo, getContributors, getEdited, getEditLink, getEtag, getHandler, getHtmlLink, getId, getKind, getLink, getLinks, getLinks, getMediaEditLink, getPlainTextContent, getPubControl, getPublished, getResumableEditMediaLink, getRights, getSelectedFields, getSelf, getSelfLink, getService, getSource, getSummary, getTextContent, getTitle, getUpdated, getVersionId, isDraft, parseAtom, parseAtom, parseAtom, readEntry, readEntry, removeLinks, removeLinks, setCanEdit, setContent, setContent, setDraft, setEdited, setEtag, setId, setKind, setPubControl, setPublished, setRights, setSelectedFields, setService, setSource, setSummary, setTitle, setUpdated, setVersionId, update, visitChildren`

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

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

Methods inherited from class com.google.gdata.data.AbstractExtension
`consumeAttributes, disableStrictValidation, enableStrictValidation, eq, 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

### CATEGORIES

    public static final java.lang.String[] CATEGORIES

  Nonstandard categories that might be found in this entry.

Constructor Detail

### SubscriptionEntry

    public SubscriptionEntry()

### SubscriptionEntry

    public SubscriptionEntry(BaseEntry<?> base)

Method Detail

### addSubscriptionType

    public void addSubscriptionType(SubscriptionEntry.Type type)

  Adds a type category to this entry.

  Parameters:
    `type` - subscription types

### getSubscriptionType

    public SubscriptionEntry.Type getSubscriptionType()

  Gets the type of the subscription, if it is of a known type.

  Returns:
    subscription type or null if it is of an unknown type

### setSubscriptionType

    public void setSubscriptionType(SubscriptionEntry.Type type)

  Sets the type category of this entry. If a type category already exists, it will be removed.

  Parameters:
    `type` - new subscription type or `null`

### setUsername

    public void setUsername(java.lang.String username)

  Set the optional username.

  Parameters:
    `username` - content of the yt:username tag

### getUsername

    public java.lang.String getUsername()

  Get the value of the optional username

  Returns:
    the username

### setQueryString

    public void setQueryString(java.lang.String query)

  Set the optional query string of a subscription with the type query.

  Parameters:
    `query` - the query string

### getQueryString

    public java.lang.String getQueryString()

  Get the query string of the subscription.

  Returns:
    the query string

### setPlaylistTitle

    public void setPlaylistTitle(java.lang.String playlistTitle)

  Set the title of the playlist subscribed to.

  Parameters:
    `playlistTitle` - the playlistTitle

### getPlaylistTitle

    public java.lang.String getPlaylistTitle()

  Get the title of the playlist subscribed to.

  Returns:
    the playlist title

### setPlaylistId

    public void setPlaylistId(java.lang.String playlistId)

  Set the optional id of the playlist subscribed to.

  Parameters:
    `playlistId` - the id of the playlist

### getPlaylistId

    public java.lang.String getPlaylistId()

  Get the id of the playlist subscribed to.

  Returns:
    the playlist id

### declareExtensions

    public void declareExtensions(ExtensionProfile extProfile)

  Description copied from class: `ExtensionPoint`
  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.

  Specified by:
    `declareExtensions` in interface `Kind.Adaptor`
  Overrides:
    `declareExtensions` in class `FeedLinkEntry<SubscriptionEntry>`
  Parameters:
    `extProfile` - the ExtensionProfile to initialize.
  See Also:
    `ExtensionProfile.addDeclarations(Kind.Adaptor)`