Class Application
- All Implemented Interfaces:
com.broadleafcommerce.data.tracking.core.ContextStateAware,Serializable
- Author:
- Jeff Fischer
- See Also:
-
Application- Serialized Form
-
Constructor Summary
ConstructorsConstructorDescriptionApplication(String id, String name, String token, String identifierType, String identifierValue, String customerContextId, boolean deactivated, Locale defaultLocale, List<Locale> allowedLocales, Currency defaultCurrency, List<Currency> allowedCurrencies, ApplicationAsset portraitAsset, ApplicationAsset logoAsset, Map<String, Object> attributes, List<ApplicationCatalogRef> isolatedCatalogs, boolean isMarketplace, com.broadleafcommerce.data.tracking.core.filtering.business.domain.ContextState contextState, String robots) -
Method Summary
Modifier and TypeMethodDescriptionprotected booleanbooleanList ofCurrenciesthat are available to be selected for use with this application.List ofLocalesthat are available to be selected for this application.Arbitrary attributes associated with this application.com.broadleafcommerce.data.tracking.core.filtering.business.domain.ContextStateA subset ofTrackinginformation to expose the context state for this object.The customer context id that is used to discriminate entities withTrackableBehavior.CUSTOMER_CONTEXT.TheCurrencythat this application, by default, assumes all data is within and can drive the default currency selection on a frontend.getId()The context id, which is a separate identifier from the database primary key.Defines the type of the application resolution identifier: Whether a domain or a domain prefix.Determines how applications are resolved using all or part of their domains or hostnames.Individual catalogs assigned to this application.The asset information for the application's logo.getName()The general name for the applicationThe asset information for the application's portrait.A robots.txt file contents tells search engine crawlers which pages or files the crawler can or can't request from your site.getToken()The token used for API access to this application's data.inthashCode()booleanDetermines whether this application is active.booleanWhether or not the application is a marketplace application.voidsetAllowedCurrencies(List<Currency> allowedCurrencies) List ofCurrenciesthat are available to be selected for use with this application.voidsetAllowedLocales(List<Locale> allowedLocales) List ofLocalesthat are available to be selected for this application.voidsetAttributes(Map<String, Object> attributes) Arbitrary attributes associated with this application.voidsetContextState(com.broadleafcommerce.data.tracking.core.filtering.business.domain.ContextState contextState) A subset ofTrackinginformation to expose the context state for this object.voidsetCustomerContextId(String customerContextId) The customer context id that is used to discriminate entities withTrackableBehavior.CUSTOMER_CONTEXT.voidsetDeactivated(boolean deactivated) Determines whether this application is active.voidsetDefaultCurrency(Currency defaultCurrency) TheCurrencythat this application, by default, assumes all data is within and can drive the default currency selection on a frontend.voidsetDefaultLocale(Locale defaultLocale) voidThe context id, which is a separate identifier from the database primary key.voidsetIdentifierType(String identifierType) Defines the type of the application resolution identifier: Whether a domain or a domain prefix.voidsetIdentifierValue(String identifierValue) Determines how applications are resolved using all or part of their domains or hostnames.voidsetIsolatedCatalogs(List<ApplicationCatalogRef> isolatedCatalogs) Individual catalogs assigned to this application.voidsetLogoAsset(ApplicationAsset logoAsset) The asset information for the application's logo.voidsetMarketplace(boolean isMarketplace) Whether or not the application is a marketplace application.voidThe general name for the applicationvoidsetPortraitAsset(ApplicationAsset portraitAsset) The asset information for the application's portrait.voidA robots.txt file contents tells search engine crawlers which pages or files the crawler can or can't request from your site.voidThe token used for API access to this application's data.toString()
-
Constructor Details
-
Application
public Application() -
Application
public Application(String id, String name, String token, String identifierType, String identifierValue, String customerContextId, boolean deactivated, Locale defaultLocale, List<Locale> allowedLocales, Currency defaultCurrency, List<Currency> allowedCurrencies, ApplicationAsset portraitAsset, ApplicationAsset logoAsset, Map<String, Object> attributes, List<ApplicationCatalogRef> isolatedCatalogs, boolean isMarketplace, com.broadleafcommerce.data.tracking.core.filtering.business.domain.ContextState contextState, String robots)
-
-
Method Details
-
getId
The context id, which is a separate identifier from the database primary key. This may be auto generated, or may be explicitly provided upon entity creation.- Returns:
- Separate identifier from the database primary key
-
getName
The general name for the application- Returns:
- The general name for the application
-
getToken
The token used for API access to this application's data.- Returns:
- the token used for API access to this application's data
-
getIdentifierType
Defines the type of the application resolution identifier: Whether a domain or a domain prefix.- Returns:
- the type of the application resolution identifier: Whether a domain or a domain prefix.
- See Also:
-
ResolutionIdentifierType
-
getIdentifierValue
Determines how applications are resolved using all or part of their domains or hostnames. Values could be themyapplication.mycompany.cominhttps://myapplication.mycompany.com/or themyapplicationinhttps://myapplication.mycompany.com/depending onidentifierType.- Returns:
- the domain (a.k.a., hostname) or domain segment identifying this application.
- See Also:
-
identifierType
-
getCustomerContextId
The customer context id that is used to discriminate entities with
TrackableBehavior.CUSTOMER_CONTEXT.If it is null on a newly created application, then the property
TenantApplicationProperties.Customer.getContextMethod()is used to default it. IfCustomerContextResolverMethod.APPLICATIONuses the ID of theApplication. IfCustomerContextResolverMethod.TENANT, uses the ID of theTenant.- Returns:
- the customer context id
- See Also:
-
isDeactivated
public boolean isDeactivated()Determines whether this application is active.- Returns:
- Determines whether this application is active.
-
getDefaultLocale
TheLocalethat this application, by default, assumes all data is within and can drive the defaultLocaleselection as a result.- Returns:
- The default
Locale
-
getAllowedLocales
List ofLocalesthat are available to be selected for this application. AllCatalogsthat are related to this application should be restricted to this locale set.- Returns:
- List of
Localesavailable for this application.
-
getDefaultCurrency
TheCurrencythat this application, by default, assumes all data is within and can drive the default currency selection on a frontend. If not set, the system will use the default currency fordefaultLocalein response to API requests.- Returns:
- The
Currencythat this application.
-
getAllowedCurrencies
List ofCurrenciesthat are available to be selected for use with this application. AllCatalogsthat are related to this application should be restricted to this currency set. However, note that this can be empty, in which case, APIs will respond to requests with a list of currencies that the system determines to be the defaults for each locale inallowedLocales.- Returns:
- List of
Currenciesthat are available to be selected for use with this application
-
getPortraitAsset
The asset information for the application's portrait. If populated, this property will be used within the admin to display a portrait for this application within the application selector. If not populated, a generic fallback icon will be displayed instead.- Returns:
- the portrait asset, or null
-
getLogoAsset
The asset information for the application's logo. If populated, this property will be used within the admin to display the logo for the application-level admin. If not populated, the admin will utilize theTenant.getLogoAsset()if it exists.- Returns:
- the logo asset, or null
-
getAttributes
Arbitrary attributes associated with this application. May include soft references to related entities, custom fields, or other data.- Returns:
- Map of attributes for this application
-
getIsolatedCatalogs
Individual catalogs assigned to this application.ApplicationCatalogRefsprovide additional control over the mutability and visibility of the entities of the catalogs assigned.- Returns:
- Individual catalogs assigned to this application
- See Also:
-
isMarketplace
public boolean isMarketplace()Whether or not the application is a marketplace application. Marketplace applications leverageMarketplaceApplicationCatalogrelationships to catalogs, in addition to the explicit relationships declared ingetIsolatedCatalogs().Generally, all relationships to vendor catalogs should be defined exclusively with
MarketplaceApplicationCatalog, and any additional relationships to non-vendor catalogs would be ingetIsolatedCatalogs(). Unless theApplicationConfigurationProperties.isAllowVendorCatalogInApplicationIsolatedCatalogs()is enabled.- See Also:
-
ApplicationConfigurationProperties
-
getContextState
public com.broadleafcommerce.data.tracking.core.filtering.business.domain.ContextState getContextState()A subset ofTrackinginformation to expose the context state for this object.- Specified by:
getContextStatein interfacecom.broadleafcommerce.data.tracking.core.ContextStateAware- Returns:
- a subset of
Trackinginformation to expose the context state for this object
-
getRobots
A robots.txt file contents tells search engine crawlers which pages or files the crawler can or can't request from your site. This is used mainly to avoid overloading your site with requests;- Returns:
- a string of the contents of the robots.txt
-
setId
The context id, which is a separate identifier from the database primary key. This may be auto generated, or may be explicitly provided upon entity creation.- Parameters:
id- Separate identifier from the database primary key
-
setName
The general name for the application- Parameters:
name- The general name for the application
-
setToken
The token used for API access to this application's data.- Parameters:
token- the token used for API access to this application's data
-
setIdentifierType
Defines the type of the application resolution identifier: Whether a domain or a domain prefix.- Parameters:
identifierType- the type of the application resolution identifier: Whether a domain or a domain prefix.- See Also:
-
ResolutionIdentifierType
-
setIdentifierValue
Determines how applications are resolved using all or part of their domains or hostnames. Values could be themyapplication.mycompany.cominhttps://myapplication.mycompany.com/or themyapplicationinhttps://myapplication.mycompany.com/depending onidentifierType.- Parameters:
identifierValue- the domain (a.k.a., hostname) or domain segment identifying this application.- See Also:
-
identifierType
-
setCustomerContextId
The customer context id that is used to discriminate entities with
TrackableBehavior.CUSTOMER_CONTEXT.If it is null on a newly created application, then the property
TenantApplicationProperties.Customer.getContextMethod()is used to default it. IfCustomerContextResolverMethod.APPLICATIONuses the ID of theApplication. IfCustomerContextResolverMethod.TENANT, uses the ID of theTenant.- Parameters:
customerContextId- the customer context id- See Also:
-
setDeactivated
public void setDeactivated(boolean deactivated) Determines whether this application is active.- Parameters:
deactivated- Determines whether this application is active.
-
setDefaultLocale
TheLocalethat this application, by default, assumes all data is within and can drive the defaultLocaleselection as a result.- Parameters:
defaultLocale- The defaultLocale
-
setAllowedLocales
List ofLocalesthat are available to be selected for this application. AllCatalogsthat are related to this application should be restricted to this locale set.- Parameters:
allowedLocales- List ofLocalesavailable for this application.
-
setDefaultCurrency
TheCurrencythat this application, by default, assumes all data is within and can drive the default currency selection on a frontend. If not set, the system will use the default currency fordefaultLocalein response to API requests.- Parameters:
defaultCurrency- TheCurrencythat this application
-
setAllowedCurrencies
List ofCurrenciesthat are available to be selected for use with this application. AllCatalogsthat are related to this application should be restricted to this currency set. However, note that this can be empty, in which case, APIs will respond to requests with a list of currencies that the system determines to be the defaults for each locale inallowedLocales.- Parameters:
allowedCurrencies- List ofCurrenciesthat are available to be selected for use with this application
-
setPortraitAsset
The asset information for the application's portrait. If populated, this property will be used within the admin to display a portrait for this application within the application selector. If not populated, a generic fallback icon will be displayed instead.- Parameters:
portraitAsset- the next portrait asset
-
setLogoAsset
The asset information for the application's logo. If populated, this property will be used within the admin to display the logo for the application-level admin. If not populated, the admin will utilize theTenant.getLogoAsset()if it exists.- Parameters:
logoAsset- the next logo asset
-
setAttributes
Arbitrary attributes associated with this application. May include soft references to related entities, custom fields, or other data.- Parameters:
attributes- Map of attributes for this application
-
setIsolatedCatalogs
Individual catalogs assigned to this application.ApplicationCatalogRefsprovide additional control over the mutability and visibility of the entities of the catalogs assigned.- Parameters:
isolatedCatalogs- Individual catalogs assigned to this application- See Also:
-
setMarketplace
public void setMarketplace(boolean isMarketplace) Whether or not the application is a marketplace application. Marketplace applications leverageMarketplaceApplicationCatalogrelationships to catalogs, in addition to the explicit relationships declared ingetIsolatedCatalogs().Generally, all relationships to vendor catalogs should be defined exclusively with
MarketplaceApplicationCatalog, and any additional relationships to non-vendor catalogs would be ingetIsolatedCatalogs(). Unless theApplicationConfigurationProperties.isAllowVendorCatalogInApplicationIsolatedCatalogs()is enabled.- See Also:
-
ApplicationConfigurationProperties
-
setContextState
public void setContextState(com.broadleafcommerce.data.tracking.core.filtering.business.domain.ContextState contextState) A subset ofTrackinginformation to expose the context state for this object.- Specified by:
setContextStatein interfacecom.broadleafcommerce.data.tracking.core.ContextStateAware- Parameters:
contextState- a subset ofTrackinginformation to expose the context state for this object
-
setRobots
A robots.txt file contents tells search engine crawlers which pages or files the crawler can or can't request from your site. This is used mainly to avoid overloading your site with requests; -
equals
-
canEqual
-
hashCode
public int hashCode() -
toString
-