Class SiteServiceImpl
java.lang.Object
org.broadleafcommerce.common.site.service.SiteServiceImpl
- All Implemented Interfaces:
SiteService
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected SiteServiceExtensionManager
protected SiteDao
protected StreamingTransactionCapableUtil
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionCreates an instance ofCatalog
.Creates an instance of Site.Creates an instance ofSiteCatalogXref
.Deprecated.Finds all catalogsReturns all of the active sites in the system and does not attach them to a Hibernate sessionReturns all of the active sites in the system that are still attached to a Hibernate sessionfindAllSites
(boolean persistentResult) findCatalogById
(Long id) Finds a catalog by its id.findCatalogByName
(String name) protected Site
getNonPersistentSite
(Site persistentSite) Deprecated.protected Site
retrieveDefaultSite
(boolean persistentResult) Retrieves the non-persistent version of the default siteretrieveNonPersistentSiteByDomainName
(String domainName) Finds a site by the given domain name and returns a non-persistent versionRetrieves a site by its primary key disconnected from a Hibernate sessionretrieveNonPersistentSiteByIdentifer
(String identifier) Finds a site by itsSite.getSiteIdentifierValue()
and return an entity that is not attached to the Hibernate sessionRetrieves the default site attached to a Hibernate sessionretrievePersistentSiteByDomainName
(String domainName) Finds a site by the domain name which is still attached to a Hibernate sessionRetrieves a site by its primary key whose return value is still attached to a Hibernate sessionretrievePersistentSiteByIdentifier
(String identifier) Finds a site by itsSite.getSiteIdentifierValue()
retrieveSiteByDomainName
(String domainName) Deprecated.retrieveSiteByDomainName
(String domainName, boolean persistentResult) retrieveSiteById
(Long id) Deprecated.protected Site
retrieveSiteById
(Long id, boolean persistentResult) protected Site
retrieveSiteByIdentifier
(String identifier, boolean persistentResult) Saves the given catalog and returns the merged instanceDeprecated.Save updates to a site and returns a non-persistent instancesaveAndReturnPersisted
(Site site) Save updates to a site and return the persistent instance attached to a Hibernate sessionprotected boolean
stripSubdomain
(String subDomain) Checks whether the provided subdomain is one to be stripped/removed from the full domain name
-
Field Details
-
transUtil
-
siteDao
-
extensionManager
-
-
Constructor Details
-
SiteServiceImpl
public SiteServiceImpl()
-
-
Method Details
-
createSite
Description copied from interface:SiteService
Creates an instance of Site. Default implementation delegates toSiteDao.create()
.- Specified by:
createSite
in interfaceSiteService
- Returns:
-
retrieveSiteById
Deprecated.Description copied from interface:SiteService
Find a site by its id and returns a non-persistent version- Specified by:
retrieveSiteById
in interfaceSiteService
- Returns:
-
retrieveNonPersistentSiteById
Description copied from interface:SiteService
Retrieves a site by its primary key disconnected from a Hibernate session- Specified by:
retrieveNonPersistentSiteById
in interfaceSiteService
-
retrievePersistentSiteById
Description copied from interface:SiteService
Retrieves a site by its primary key whose return value is still attached to a Hibernate session- Specified by:
retrievePersistentSiteById
in interfaceSiteService
-
retrieveSiteById
-
retrieveNonPersistentSiteByIdentifer
Description copied from interface:SiteService
Finds a site by itsSite.getSiteIdentifierValue()
and return an entity that is not attached to the Hibernate session- Specified by:
retrieveNonPersistentSiteByIdentifer
in interfaceSiteService
- Parameters:
identifier
- theSite.getSiteIdentifierValue()
to look for
-
retrievePersistentSiteByIdentifier
Description copied from interface:SiteService
Finds a site by itsSite.getSiteIdentifierValue()
- Specified by:
retrievePersistentSiteByIdentifier
in interfaceSiteService
- Parameters:
identifier
- theSite.getSiteIdentifierValue()
to look for
-
retrieveSiteByIdentifier
-
retrieveSiteByDomainName
Deprecated.Description copied from interface:SiteService
Find a site by its domain and returns a non-persistent version- Specified by:
retrieveSiteByDomainName
in interfaceSiteService
- Returns:
-
retrieveNonPersistentSiteByDomainName
Description copied from interface:SiteService
Finds a site by the given domain name and returns a non-persistent version- Specified by:
retrieveNonPersistentSiteByDomainName
in interfaceSiteService
-
retrievePersistentSiteByDomainName
Description copied from interface:SiteService
Finds a site by the domain name which is still attached to a Hibernate session- Specified by:
retrievePersistentSiteByDomainName
in interfaceSiteService
- Returns:
-
retrieveSiteByDomainName
-
stripSubdomain
Checks whether the provided subdomain is one to be stripped/removed from the full domain name- Parameters:
subDomain
-- Returns:
- boolean if subdomain is a candiate to be removed - true indicates it is eligible to be removed
-
save
Deprecated.Description copied from interface:SiteService
Save updates to a site and returns a cloned instance- Specified by:
save
in interfaceSiteService
- Returns:
-
saveAndReturnNonPersisted
Description copied from interface:SiteService
Save updates to a site and returns a non-persistent instance- Specified by:
saveAndReturnNonPersisted
in interfaceSiteService
- Returns:
-
saveAndReturnPersisted
Description copied from interface:SiteService
Save updates to a site and return the persistent instance attached to a Hibernate session- Specified by:
saveAndReturnPersisted
in interfaceSiteService
- Returns:
-
findCatalogById
Description copied from interface:SiteService
Finds a catalog by its id.- Specified by:
findCatalogById
in interfaceSiteService
- Returns:
- the catalog
-
findCatalogByName
- Specified by:
findCatalogByName
in interfaceSiteService
-
retrieveDefaultSite
Deprecated.Description copied from interface:SiteService
Returns a clone of the default site.- Specified by:
retrieveDefaultSite
in interfaceSiteService
- Returns:
-
retrieveNonPersistentDefaultSite
Description copied from interface:SiteService
Retrieves the non-persistent version of the default site- Specified by:
retrieveNonPersistentDefaultSite
in interfaceSiteService
-
retrievePersistentDefaultSite
Description copied from interface:SiteService
Retrieves the default site attached to a Hibernate session- Specified by:
retrievePersistentDefaultSite
in interfaceSiteService
-
retrieveDefaultSite
-
findAllActiveSites
Deprecated.- Specified by:
findAllActiveSites
in interfaceSiteService
- Returns:
- a List of non-persistent versions of all sites in the system
-
findAllNonPersistentActiveSites
Description copied from interface:SiteService
Returns all of the active sites in the system and does not attach them to a Hibernate session- Specified by:
findAllNonPersistentActiveSites
in interfaceSiteService
-
findAllPersistentActiveSites
Description copied from interface:SiteService
Returns all of the active sites in the system that are still attached to a Hibernate session- Specified by:
findAllPersistentActiveSites
in interfaceSiteService
-
findAllSites
-
getNonPersistentSite
-
createCatalog
Description copied from interface:SiteService
Creates an instance ofCatalog
. Default implementation delegates toSiteDao.createCatalog()
.- Specified by:
createCatalog
in interfaceSiteService
- Returns:
- the catalog
-
createSiteCatalog
Description copied from interface:SiteService
Creates an instance ofSiteCatalogXref
. Default implementation delegates toSiteDao.createSiteCatalog()
- Specified by:
createSiteCatalog
in interfaceSiteService
- Returns:
- the site catalog
-
save
Description copied from interface:SiteService
Saves the given catalog and returns the merged instance- Specified by:
save
in interfaceSiteService
- Returns:
-
findAllCatalogs
Description copied from interface:SiteService
Finds all catalogs- Specified by:
findAllCatalogs
in interfaceSiteService
- Returns:
- the list of catalogs
-