public class BaseSocialComponent extends java.lang.Object implements SocialComponent
DEFAULT_SELECTOR, INDEX_SELECTOR, PROP_REFERER, QUERY_SELECTOR, TRANSLATE_SELECTOR| Constructor and Description |
|---|
BaseSocialComponent(Resource resource,
ClientUtilities clientUtils) |
| Modifier and Type | Method and Description |
|---|---|
static java.lang.String |
buildJSONString(java.util.Map<java.lang.String,java.lang.Object> data,
boolean tidy) |
java.util.Map<java.lang.String,java.lang.Object> |
getAsMap() |
java.lang.String |
getFriendlyUrl()
Get a url that can be used to display this component, most of the time, this is the page url that contains the
component.
|
ResourceID |
getId() |
SocialComponent |
getParentComponent()
Gets the immediate parent of this component.
|
java.util.Properties |
getProperties() |
Resource |
getResource() |
java.lang.String |
getResourceType() |
SocialComponent |
getSourceComponent()
Gets the SocialComponent that created this piece of UGC.
|
java.lang.String |
getUrl() |
java.lang.String |
toJSONString(boolean tidy) |
public BaseSocialComponent(Resource resource, ClientUtilities clientUtils)
resource - the resource for which this BaseSocialComponent will be created for.clientUtils - an instance of ClientUtilities for accessing helper methods for XSS support and generating
URLs.public static java.lang.String buildJSONString(java.util.Map<java.lang.String,java.lang.Object> data,
boolean tidy)
throws JsonException
JsonExceptionpublic ResourceID getId()
getId in interface SocialComponentpublic java.lang.String getResourceType()
getResourceType in interface SocialComponentpublic java.lang.String getUrl()
getUrl in interface SocialComponentpublic java.util.Properties getProperties()
getProperties in interface SocialComponentpublic java.lang.String toJSONString(boolean tidy)
throws JsonException
toJSONString in interface SocialComponenttidy - true to return readable JSON string.JsonException - if an error occurs during serialization.public Resource getResource()
getResource in interface SocialComponentpublic java.util.Map<java.lang.String,java.lang.Object> getAsMap()
getAsMap in interface SocialComponentpublic SocialComponent getParentComponent()
SocialComponentgetParentComponent in interface SocialComponentpublic SocialComponent getSourceComponent()
SocialComponentgetSourceComponent in interface SocialComponentpublic java.lang.String getFriendlyUrl()
SocialComponentgetFriendlyUrl in interface SocialComponent"Copyright © 2010 - 2018 Adobe Systems Incorporated. All Rights Reserved"