com.ning.api.client.item.ContentItemBase Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of ning-api-java Show documentation
Show all versions of ning-api-java Show documentation
Java client library for accessing Ning external API
package com.ning.api.client.item;
import org.codehaus.jackson.annotate.JsonProperty;
import org.joda.time.DateTime;
/**
* Note: although we do implement {@link ContentItem}
*/
public class ContentItemBase, T extends ContentItem>
implements ContentItem
{
/**
* Id of this content item; should never be null when returned via read-only
* methods; null when constructed from scratch to create a new item
*/
@JsonProperty
protected Key id;
@JsonProperty
protected DateTime createdDate;
// looks like "author" is ubiquitous as well:
@JsonProperty
protected String author;
protected ContentItemBase() { }
@JsonProperty("id")
public final Key id() { return id; }
public DateTime getCreatedDate() { return createdDate; }
public String getAuthor() { return author; }
@Override
public String toString()
{
return "[Content type item of type "+getClass().getSimpleName()+"; id "+id+"]";
}
}