@Service(value="blProductLinkedDataGenerator") public class ProductLinkedDataGeneratorImpl extends AbstractLinkedDataGenerator
See http://schema.org/Product, http://schema.org/Offer, and http://schema.org/AggregateOffer
| Modifier and Type | Field and Description |
|---|---|
protected static String |
IN_STOCK |
protected static DateFormat |
ISO_8601_FORMAT |
protected static String |
OUT_OF_STOCK |
protected RatingService |
ratingService |
baseUrlResolver, breadcrumbService, DEFAULT_STRUCTURED_CONTENT_CONTEXT, environment, extensionManager| Constructor and Description |
|---|
ProductLinkedDataGeneratorImpl() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
addImageUrl(Product product,
org.codehaus.jettison.json.JSONObject productData) |
protected org.codehaus.jettison.json.JSONObject |
addProductData(javax.servlet.http.HttpServletRequest request,
Product product,
String url) |
protected void |
addReviewData(javax.servlet.http.HttpServletRequest request,
Product product,
org.codehaus.jettison.json.JSONObject productData) |
protected void |
addSkus(javax.servlet.http.HttpServletRequest request,
Product product,
org.codehaus.jettison.json.JSONObject productData,
String url) |
boolean |
canHandle(javax.servlet.http.HttpServletRequest request)
Determines whether or not this LinkedDataGenerator can handle the incoming request.
|
protected String |
determineAvailability(Sku sku) |
protected String |
getAssetServerUrlPrefix() |
protected String |
getImageUrlPrefix() |
protected org.codehaus.jettison.json.JSONArray |
getLinkedDataJsonInternal(String url,
javax.servlet.http.HttpServletRequest request,
org.codehaus.jettison.json.JSONArray schemaObjects) |
protected Product |
getProduct(javax.servlet.http.HttpServletRequest request) |
getLinkedDataJSON, getRequestParams, getRequestUri, getSiteBaseUrl, getStructuredDataContextprotected static final String IN_STOCK
protected static final String OUT_OF_STOCK
protected static final DateFormat ISO_8601_FORMAT
protected RatingService ratingService
public boolean canHandle(javax.servlet.http.HttpServletRequest request)
LinkedDataGeneratorcanHandle in interface LinkedDataGeneratorcanHandle in class AbstractLinkedDataGeneratorprotected org.codehaus.jettison.json.JSONArray getLinkedDataJsonInternal(String url, javax.servlet.http.HttpServletRequest request, org.codehaus.jettison.json.JSONArray schemaObjects) throws org.codehaus.jettison.json.JSONException
getLinkedDataJsonInternal in class AbstractLinkedDataGeneratororg.codehaus.jettison.json.JSONExceptionprotected Product getProduct(javax.servlet.http.HttpServletRequest request)
protected org.codehaus.jettison.json.JSONObject addProductData(javax.servlet.http.HttpServletRequest request,
Product product,
String url)
throws org.codehaus.jettison.json.JSONException
org.codehaus.jettison.json.JSONExceptionprotected void addImageUrl(Product product, org.codehaus.jettison.json.JSONObject productData) throws org.codehaus.jettison.json.JSONException
org.codehaus.jettison.json.JSONExceptionprotected String getImageUrlPrefix()
protected String getAssetServerUrlPrefix()
protected void addSkus(javax.servlet.http.HttpServletRequest request,
Product product,
org.codehaus.jettison.json.JSONObject productData,
String url)
throws org.codehaus.jettison.json.JSONException
org.codehaus.jettison.json.JSONExceptionprotected void addReviewData(javax.servlet.http.HttpServletRequest request,
Product product,
org.codehaus.jettison.json.JSONObject productData)
throws org.codehaus.jettison.json.JSONException
org.codehaus.jettison.json.JSONExceptionCopyright © 2021. All rights reserved.