/** * Declare the extensions of the feeds for the Google Sidewiki Data API. */ private void declareExtensions() { new SidewikiEntryFeed().declareExtensions(extProfile); new SidewikiUserFeed().declareExtensions(extProfile); }
@Override public boolean equals(Object obj) { if (this == obj) { return true; } if (!sameClassAs(obj)) { return false; } Source other = (Source) obj; return eq(value, other.value); }
/** * Returns whether it has the Sidewiki author id. * * @return whether it has the Sidewiki author id */ public boolean hasResourceId() { return hasExtension(ResourceId.class); }
@Override public boolean equals(Object obj) { if (this == obj) { return true; } if (!sameClassAs(obj)) { return false; } EntriesNumber other = (EntriesNumber) obj; return eq(value, other.value); }
@Override public boolean equals(Object obj) { if (this == obj) { return true; } if (!sameClassAs(obj)) { return false; } Usefulness other = (Usefulness) obj; return eq(value, other.value); }
/** * Sets the Sidewiki author id. * * @param resourceId Sidewiki author id or <code>null</code> to reset */ public void setResourceId(ResourceId resourceId) { if (resourceId == null) { removeExtension(ResourceId.class); } else { setExtension(resourceId); } }
/** * Immutable constructor. * * @param value number of written Sidewiki entries. */ public EntriesNumber(Integer value) { super(); setValue(value); setImmutable(true); }
/** * Returns the user rating given by the user issued the request. * * @return user rating given by the user issued the request */ public Rating getRating() { return getExtension(Rating.class); }
/** * Sets the number of written Sidewiki entries. * * @param value number of written Sidewiki entries or <code>null</code> to * reset */ public void setValue(Integer value) { throwExceptionIfImmutable(); this.value = value; }
/** * Returns whether it has the Entry ratings given by all users and by the user * issued the request. * * @return whether it has the Entry ratings given by all users and by the user * issued the request */ public boolean hasRating() { return hasExtension(Rating.class); }
/** * Default mutable constructor. */ public SidewikiUserEntry() { super(); setKind("sidewiki#sidewikiUserEntry"); }
/** * Returns whether it has the number of written Sidewiki entries. * * @return whether it has the number of written Sidewiki entries */ public boolean hasValue() { return getValue() != null; }
/** * Constructor (mutable or immutable). * * @param value immutable thumbnail url or <code>null</code> for a mutable * thumbnail url */ public SidewikiThumbnail(String value) { super(SidewikiNamespace.SIDEWIKI_NS, XML_NAME, null, value); setRequired(false); }
/** * Default mutable constructor. */ public SidewikiUserFeed() { super(SidewikiUserEntry.class); setKind("sidewiki#sidewikiUserFeed"); }
/** * Declare the extensions of the feeds for the Google Sidewiki Data API. */ private void declareExtensions() { new SidewikiEntryFeed().declareExtensions(extProfile); new SidewikiUserFeed().declareExtensions(extProfile); }
/** * Returns whether it has the entries number. * * @return whether it has the entries number */ public boolean hasNumEntries() { return hasExtension(EntriesNumber.class); }
/** * Returns the user portrait thumbnail url. * * @return user portrait thumbnail url */ public SidewikiThumbnail getThumbnail() { return getExtension(SidewikiThumbnail.class); }
/** * Sets the number of written Sidewiki entries. * * @param value number of written Sidewiki entries or <code>null</code> to * reset */ public void setValue(Integer value) { throwExceptionIfImmutable(); this.value = value; }
/** * Returns whether it has the Entry ratings given by all users and by the user * issued the request. * * @return whether it has the Entry ratings given by all users and by the user * issued the request */ public boolean hasRating() { return hasExtension(Rating.class); }
/** * Returns whether it has the user rating given by the user issued the * request. * * @return whether it has the user rating given by the user issued the request */ public boolean hasRating() { return hasExtension(Rating.class); }