|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.broadleafcommerce.catalog.domain.CategoryImpl
public class CategoryImpl
The Class CategoryImpl is the default implementation of Category. A
category is a group of products.
If you want to add fields specific to your implementation of
BroadLeafCommerce you should extend this class and add your fields. If you
need to make significant changes to the CategoryImpl then you should implment
your own version of Category.
This implementation uses a Hibernate implementation of JPA configured through
annotations. The Entity references the following tables: BLC_CATEGORY,
BLC_CATEGORY_XREF, BLC_CATEGORY_IMAGE
Category},
Serialized Form| Field Summary | |
|---|---|
protected java.util.Date |
activeEndDate
The active end date. |
protected java.util.Date |
activeStartDate
The active start date. |
protected java.util.List<Category> |
allChildCategories
The all child categories. |
protected java.util.List<Category> |
allParentCategories
The all parent categories. |
protected java.util.Map<java.lang.String,java.lang.String> |
categoryImages
The category images. |
protected java.util.Map<java.lang.String,Media> |
categoryMedia
|
protected java.util.List<Category> |
childCategories
|
protected java.util.Map<java.lang.String,java.util.List<Category>> |
childCategoryURLMap
|
protected Category |
defaultParentCategory
The default parent category. |
protected java.lang.String |
description
The description. |
protected java.lang.String |
displayTemplate
The display template. |
protected java.util.List<FeaturedProduct> |
featuredProducts
|
protected java.lang.Long |
id
The id. |
protected java.lang.String |
longDescription
The long description. |
protected java.lang.String |
name
The name. |
protected java.lang.String |
url
The url. |
protected java.lang.String |
urlKey
The url key. |
| Constructor Summary | |
|---|---|
CategoryImpl()
|
|
| Method Summary | |
|---|---|
java.util.Map<java.lang.String,java.util.List<Category>> |
createChildCategoryURLMap()
|
boolean |
equals(java.lang.Object obj)
|
java.util.Date |
getActiveEndDate()
Gets the active end date. |
java.util.Date |
getActiveStartDate()
Gets the active start date. |
java.util.List<Category> |
getAllChildCategories()
Gets the child categories. |
java.util.List<Category> |
getAllParentCategories()
|
java.lang.String |
getCategoryImage(java.lang.String imageKey)
Gets the category image. |
java.util.Map<java.lang.String,java.lang.String> |
getCategoryImages()
Gets the category images. |
java.util.Map<java.lang.String,Media> |
getCategoryMedia()
Gets the category media map |
java.util.List<Category> |
getChildCategories()
Gets the child categories. |
java.util.Map<java.lang.String,java.util.List<Category>> |
getChildCategoryURLMap()
Gets the child category url map. |
Category |
getDefaultParentCategory()
Gets the default parent category. |
java.lang.String |
getDescription()
Gets the description. |
java.lang.String |
getDisplayTemplate()
Gets the display template. |
java.util.List<FeaturedProduct> |
getFeaturedProducts()
Gets the featured products. |
java.lang.String |
getGeneratedUrl()
Gets the generated url. |
java.lang.Long |
getId()
Gets the id. |
java.lang.String |
getLongDescription()
Gets the long description. |
java.lang.String |
getName()
Gets the name. |
java.lang.String |
getUrl()
Gets the url. |
java.lang.String |
getUrlKey()
Gets the url key. |
boolean |
hasAllChildCategories()
Checks for child categories. |
boolean |
hasChildCategories()
Checks for child categories. |
int |
hashCode()
|
boolean |
isActive()
Checks if is active. |
void |
setActiveEndDate(java.util.Date activeEndDate)
Sets the active end date. |
void |
setActiveStartDate(java.util.Date activeStartDate)
Sets the active start date. |
void |
setAllChildCategories(java.util.List<Category> childCategories)
Sets the all child categories. |
void |
setAllParentCategories(java.util.List<Category> allParentCategories)
|
void |
setCategoryImages(java.util.Map<java.lang.String,java.lang.String> categoryImages)
Sets the category images. |
void |
setCategoryMedia(java.util.Map<java.lang.String,Media> categoryMedia)
Sets the category images. |
void |
setChildCategories(java.util.List<Category> childCategories)
Sets the all child categories. |
void |
setChildCategoryURLMap(java.util.Map<java.lang.String,java.util.List<Category>> cachedChildCategoryUrlMap)
|
void |
setDefaultParentCategory(Category defaultParentCategory)
Sets the default parent category. |
void |
setDescription(java.lang.String description)
Sets the description. |
void |
setDisplayTemplate(java.lang.String displayTemplate)
Sets the display template. |
void |
setFeaturedProducts(java.util.List<FeaturedProduct> featuredProducts)
Sets the featured products. |
void |
setId(java.lang.Long id)
Sets the id. |
void |
setLongDescription(java.lang.String longDescription)
Sets the long description. |
void |
setName(java.lang.String name)
Sets the name. |
void |
setUrl(java.lang.String url)
Sets the url. |
void |
setUrlKey(java.lang.String urlKey)
Sets the url key. |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected java.lang.Long id
protected java.lang.String name
protected java.lang.String url
protected java.lang.String urlKey
protected Category defaultParentCategory
protected java.lang.String description
protected java.util.Date activeStartDate
protected java.util.Date activeEndDate
protected java.lang.String displayTemplate
protected java.util.List<Category> allChildCategories
protected java.util.List<Category> allParentCategories
protected java.util.Map<java.lang.String,java.lang.String> categoryImages
protected java.util.Map<java.lang.String,Media> categoryMedia
protected java.lang.String longDescription
protected java.util.List<FeaturedProduct> featuredProducts
protected java.util.Map<java.lang.String,java.util.List<Category>> childCategoryURLMap
protected java.util.List<Category> childCategories
| Constructor Detail |
|---|
public CategoryImpl()
| Method Detail |
|---|
public java.lang.Long getId()
Category
getId in interface Categorypublic void setId(java.lang.Long id)
Category
setId in interface Categoryid - the new idpublic java.lang.String getName()
Category
getName in interface Categorypublic void setName(java.lang.String name)
Category
setName in interface Categoryname - the new namepublic Category getDefaultParentCategory()
Category
getDefaultParentCategory in interface Categorypublic void setDefaultParentCategory(Category defaultParentCategory)
Category
setDefaultParentCategory in interface CategorydefaultParentCategory - the new default parent categorypublic java.lang.String getUrl()
Category
getUrl in interface Categorypublic void setUrl(java.lang.String url)
Category
setUrl in interface Categoryurl - the new urlpublic java.lang.String getUrlKey()
Category
getUrlKey in interface Categorypublic java.lang.String getGeneratedUrl()
Category
getGeneratedUrl in interface Categorypublic void setUrlKey(java.lang.String urlKey)
Category
setUrlKey in interface CategoryurlKey - the new url keypublic java.lang.String getDescription()
Category
getDescription in interface Categorypublic void setDescription(java.lang.String description)
Category
setDescription in interface Categorydescription - the new descriptionpublic java.util.Date getActiveStartDate()
Category
getActiveStartDate in interface Categorypublic void setActiveStartDate(java.util.Date activeStartDate)
Category
setActiveStartDate in interface CategoryactiveStartDate - the new active start datepublic java.util.Date getActiveEndDate()
Category
getActiveEndDate in interface Categorypublic void setActiveEndDate(java.util.Date activeEndDate)
Category
setActiveEndDate in interface CategoryactiveEndDate - the new active end datepublic boolean isActive()
Category
isActive in interface Categorypublic java.lang.String getDisplayTemplate()
Category
getDisplayTemplate in interface Categorypublic void setDisplayTemplate(java.lang.String displayTemplate)
Category
setDisplayTemplate in interface CategorydisplayTemplate - the new display templatepublic java.util.List<Category> getAllChildCategories()
getAllChildCategories in interface Categorypublic boolean hasAllChildCategories()
hasAllChildCategories in interface Categorypublic void setAllChildCategories(java.util.List<Category> childCategories)
setAllChildCategories in interface CategoryallChildCategories - the new all child categoriespublic java.util.List<Category> getChildCategories()
Category
getChildCategories in interface Categorypublic boolean hasChildCategories()
Category
hasChildCategories in interface Categorypublic void setChildCategories(java.util.List<Category> childCategories)
Category
setChildCategories in interface Categorypublic java.util.Map<java.lang.String,java.lang.String> getCategoryImages()
Category
getCategoryImages in interface Categorypublic java.lang.String getCategoryImage(java.lang.String imageKey)
Category
getCategoryImage in interface CategoryimageKey - the image key
public void setCategoryImages(java.util.Map<java.lang.String,java.lang.String> categoryImages)
Category
setCategoryImages in interface CategorycategoryImages - the category imagespublic java.lang.String getLongDescription()
Category
getLongDescription in interface Categorypublic void setLongDescription(java.lang.String longDescription)
Category
setLongDescription in interface CategorylongDescription - the new long descriptionpublic java.util.Map<java.lang.String,java.util.List<Category>> getChildCategoryURLMap()
Category
getChildCategoryURLMap in interface Categorypublic void setChildCategoryURLMap(java.util.Map<java.lang.String,java.util.List<Category>> cachedChildCategoryUrlMap)
setChildCategoryURLMap in interface Categorypublic java.util.Map<java.lang.String,java.util.List<Category>> createChildCategoryURLMap()
public java.util.List<Category> getAllParentCategories()
getAllParentCategories in interface Categorypublic void setAllParentCategories(java.util.List<Category> allParentCategories)
setAllParentCategories in interface Categorypublic java.util.List<FeaturedProduct> getFeaturedProducts()
Category
getFeaturedProducts in interface Categorypublic void setFeaturedProducts(java.util.List<FeaturedProduct> featuredProducts)
Category
setFeaturedProducts in interface CategoryfeaturedProducts - the featured productspublic java.util.Map<java.lang.String,Media> getCategoryMedia()
Category
getCategoryMedia in interface Categorypublic void setCategoryMedia(java.util.Map<java.lang.String,Media> categoryMedia)
Category
setCategoryMedia in interface CategorycategoryMedia - the category mediapublic int hashCode()
hashCode in class java.lang.Objectpublic boolean equals(java.lang.Object obj)
equals in class java.lang.Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||