Interface InventoryLocationService<L extends InventoryLocation>
- 
- Type Parameters:
 L-
- All Superinterfaces:
 com.broadleafcommerce.data.tracking.core.service.CrudEntityService<L>
- All Known Implementing Classes:
 DefaultInventoryLocationService
public interface InventoryLocationService<L extends InventoryLocation> extends com.broadleafcommerce.data.tracking.core.service.CrudEntityService<L>Service to provide business logic / data access related toInventoryLocationreferences.- Author:
 - Kelly Tisdell (ktisdell)
 
 
- 
- 
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description booleanexistsByContextId(String contextId, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Indicates if anInventoryLocationexists with the specified contextId in the provided context.StringgetRepositoryDomain()org.springframework.data.domain.Page<L>readAllByNameOrNumber(String nameOrNumberQuery, cz.jirutka.rsql.parser.ast.Node filters, org.springframework.data.domain.Pageable page, com.broadleafcommerce.data.tracking.core.context.ContextInfo context)Read all Inventory Locations, optionally filtered by name or number.org.springframework.data.domain.Page<L>readAllLocationsByCountryCode(String countryCode, org.springframework.data.domain.Pageable page, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Pageable query forInventoryLocationreferences with a particular country code.org.springframework.data.domain.Page<L>readAllLocationsByCountryCodeAndPostalCode(String countryCode, String postalCode, org.springframework.data.domain.Pageable page, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Pageable query forInventoryLocationreferences with particular country code and postal code.org.springframework.data.domain.Page<L>readAllLocationsByCountryCodeAndStateProvinceRegionCode(String countryCode, String stateProvinceRegionCode, String city, org.springframework.data.domain.Pageable page, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Pageable query forInventoryLocationreferences with a particular country code and state / province / region code.org.springframework.data.domain.Page<L>readAllLocationsByDistanceFromCoordinates(Double latitude, Double longitude, Double distance, DistanceType distanceType, org.springframework.data.domain.Pageable page, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Query for allInventoryLocationreferences that are marked as shipping locations and have a latitude and longitude within a given distance of a provided coordinate.Optional<L>readByContextIdOptional(String contextId, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)An alternative toCrudEntityService.readByContextId(String, ContextInfo)that returns anOptionalrather than throwing an exception if not found.Optional<L>readByLocationNumber(String locationNumber, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Query forInventoryLocationreferences with a given location number, which is an arbitrary reference number (e.g.List<L>readByPickupLocationTrue(com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Returns allInventoryLocationreferences that are pickup locations.List<L>readByShippingLocationTrue(com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Returns allInventoryLocationreferences that are shipping locations.org.springframework.data.domain.Page<L>readLocationsByLocationNumbers(Set<String> locationNumbers, org.springframework.data.domain.Pageable page, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Query forInventoryLocationreferences with a given location number, which is an arbitrary reference number (e.g.org.springframework.data.domain.Page<L>readPickupLocationsByCountryCodeAndPostalCode(String countryCode, String postalCode, org.springframework.data.domain.Pageable page, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Pageable query forInventoryLocationreferences that support pickup with a particular country code and postal code.org.springframework.data.domain.Page<L>readPickupLocationsByCountryCodeAndStateProvinceRegionCode(String countryCode, String stateProvinceRegionCode, String city, org.springframework.data.domain.Pageable page, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Pageable query forInventoryLocationreferences that allow pickup with a particular country code and state / province / region code.org.springframework.data.domain.Page<L>readPickupLocationsByDistanceFromCoordinates(Double latitude, Double longitude, Double distance, DistanceType distanceType, org.springframework.data.domain.Pageable page, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Query for allInventoryLocationreferences that are marked as pickup locations and have a latitude and longitude within a given distance of a provided coordinate.org.springframework.data.domain.Page<L>readShippingLocationsByCountryCodeAndPostalCode(String countryCode, String postalCode, org.springframework.data.domain.Pageable page, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Pageable query forInventoryLocationreferences that support shipping with a particular country code and postal code.org.springframework.data.domain.Page<L>readShippingLocationsByCountryCodeAndStateProvinceRegionCode(String countryCode, String stateProvinceRegionCode, String city, org.springframework.data.domain.Pageable page, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Pageable query forInventoryLocationreferences that allow shipping with a particular country code and state / province / region code.org.springframework.data.domain.Page<L>readShippingLocationsByDistanceFromCoordinates(Double latitude, Double longitude, Double distance, DistanceType distanceType, org.springframework.data.domain.Pageable page, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Query for allInventoryLocationreferences that are marked as shipping locations and have a latitude and longitude within a given distance of a provided coordinate.org.springframework.data.domain.Page<L>readStoreLocationsByCountryCodeAndPostalCode(String countryCode, String postalCode, org.springframework.data.domain.Pageable page, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Pageable query forInventoryLocationreferences that are "Stores" with a particular country code and postal code.org.springframework.data.domain.Page<L>readStoreLocationsByCountryCodeAndStateProvinceRegionCode(String countryCode, String stateProvinceRegionCode, String city, org.springframework.data.domain.Pageable page, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Pageable query forInventoryLocationreferences that are "Stores" with a particular country code and state / province / region code.org.springframework.data.domain.Page<L>readStoreLocationsByDistanceFromCoordinates(Double latitude, Double longitude, Double distance, DistanceType distanceType, org.springframework.data.domain.Pageable page, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Query for allInventoryLocationreferences that are marked as "Store" locations and have a latitude and longitude within a given distance of a provided coordinate.- 
Methods inherited from interface com.broadleafcommerce.data.tracking.core.service.CrudEntityService
create, createAll, createAllAllowingPartialSuccess, delete, readAll, readAll, readAll, readAllByContextId, readByContextId, replace, replaceAll, replaceAllAllowingPartialSuccess, update, updateAll, updateAllAllowingPartialSuccess, updateSort 
 - 
 
 - 
 
- 
- 
Method Detail
- 
readAllByNameOrNumber
org.springframework.data.domain.Page<L> readAllByNameOrNumber(@Nullable String nameOrNumberQuery, @Nullable cz.jirutka.rsql.parser.ast.Node filters, @Nullable org.springframework.data.domain.Pageable page, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo context)
Read all Inventory Locations, optionally filtered by name or number.- Parameters:
 nameOrNumberQuery- (optional) the name or location number to filter bypage- the requested page of results from the databasefilters- additional filters to apply in the query, can be nullcontext- context information surrounding sandboxing and multitenant state- Returns:
 - all Inventory Locations, optionally filtered by name or location number
 
 
- 
readByContextIdOptional
Optional<L> readByContextIdOptional(String contextId, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
An alternative toCrudEntityService.readByContextId(String, ContextInfo)that returns anOptionalrather than throwing an exception if not found.- Parameters:
 contextId- the context ID of the location to findcontextInfo- context information surrounding multitenant state- Returns:
 - an optional containing the requested 
InventoryLocationif found,Optional.empty()otherwise 
 
- 
readByShippingLocationTrue
List<L> readByShippingLocationTrue(@Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Returns allInventoryLocationreferences that are shipping locations.- Parameters:
 contextInfo-- Returns:
 
 
- 
readByPickupLocationTrue
List<L> readByPickupLocationTrue(@Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Returns allInventoryLocationreferences that are pickup locations.- Parameters:
 contextInfo-- Returns:
 
 
- 
readAllLocationsByCountryCodeAndPostalCode
org.springframework.data.domain.Page<L> readAllLocationsByCountryCodeAndPostalCode(String countryCode, String postalCode, @Nullable org.springframework.data.domain.Pageable page, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Pageable query forInventoryLocationreferences with particular country code and postal code.- Parameters:
 countryCode-postalCode-page-contextInfo-- Returns:
 
 
- 
readShippingLocationsByCountryCodeAndPostalCode
org.springframework.data.domain.Page<L> readShippingLocationsByCountryCodeAndPostalCode(String countryCode, String postalCode, @Nullable org.springframework.data.domain.Pageable page, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Pageable query forInventoryLocationreferences that support shipping with a particular country code and postal code.- Parameters:
 countryCode-postalCode-page-contextInfo-- Returns:
 
 
- 
readPickupLocationsByCountryCodeAndPostalCode
org.springframework.data.domain.Page<L> readPickupLocationsByCountryCodeAndPostalCode(String countryCode, String postalCode, @Nullable org.springframework.data.domain.Pageable page, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Pageable query forInventoryLocationreferences that support pickup with a particular country code and postal code.- Parameters:
 countryCode-postalCode-page-contextInfo-- Returns:
 
 
- 
readStoreLocationsByCountryCodeAndPostalCode
org.springframework.data.domain.Page<L> readStoreLocationsByCountryCodeAndPostalCode(String countryCode, String postalCode, @Nullable org.springframework.data.domain.Pageable page, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Pageable query forInventoryLocationreferences that are "Stores" with a particular country code and postal code.- Parameters:
 countryCode-postalCode-page-contextInfo-- Returns:
 
 
- 
readAllLocationsByCountryCode
org.springframework.data.domain.Page<L> readAllLocationsByCountryCode(String countryCode, @Nullable org.springframework.data.domain.Pageable page, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Pageable query forInventoryLocationreferences with a particular country code.- Parameters:
 countryCode-page-contextInfo-- Returns:
 
 
- 
readAllLocationsByCountryCodeAndStateProvinceRegionCode
org.springframework.data.domain.Page<L> readAllLocationsByCountryCodeAndStateProvinceRegionCode(String countryCode, String stateProvinceRegionCode, @Nullable String city, @Nullable org.springframework.data.domain.Pageable page, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Pageable query forInventoryLocationreferences with a particular country code and state / province / region code. The city parameter is optional and will only be used if not null.- Parameters:
 countryCode-stateProvinceRegionCode-page-contextInfo-- Returns:
 
 
- 
readShippingLocationsByCountryCodeAndStateProvinceRegionCode
org.springframework.data.domain.Page<L> readShippingLocationsByCountryCodeAndStateProvinceRegionCode(String countryCode, String stateProvinceRegionCode, @Nullable String city, @Nullable org.springframework.data.domain.Pageable page, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Pageable query forInventoryLocationreferences that allow shipping with a particular country code and state / province / region code.- Parameters:
 countryCode-stateProvinceRegionCode-page-contextInfo-- Returns:
 
 
- 
readPickupLocationsByCountryCodeAndStateProvinceRegionCode
org.springframework.data.domain.Page<L> readPickupLocationsByCountryCodeAndStateProvinceRegionCode(String countryCode, String stateProvinceRegionCode, @Nullable String city, @Nullable org.springframework.data.domain.Pageable page, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Pageable query forInventoryLocationreferences that allow pickup with a particular country code and state / province / region code.- Parameters:
 countryCode-stateProvinceRegionCode-page-contextInfo-- Returns:
 
 
- 
readStoreLocationsByCountryCodeAndStateProvinceRegionCode
org.springframework.data.domain.Page<L> readStoreLocationsByCountryCodeAndStateProvinceRegionCode(String countryCode, String stateProvinceRegionCode, @Nullable String city, @Nullable org.springframework.data.domain.Pageable page, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Pageable query forInventoryLocationreferences that are "Stores" with a particular country code and state / province / region code.- Parameters:
 countryCode-stateProvinceRegionCode-page-contextInfo-- Returns:
 
 
- 
readByLocationNumber
Optional<L> readByLocationNumber(String locationNumber, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Query forInventoryLocationreferences with a given location number, which is an arbitrary reference number (e.g. store number, store ID, warehouse ID, etc.)- Parameters:
 locationNumber-contextInfo-- Returns:
 
 
- 
readLocationsByLocationNumbers
org.springframework.data.domain.Page<L> readLocationsByLocationNumbers(Set<String> locationNumbers, @Nullable org.springframework.data.domain.Pageable page, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Query forInventoryLocationreferences with a given location number, which is an arbitrary reference number (e.g. store number, store ID, warehouse ID, etc.)- Parameters:
 locationNumbers-page-contextInfo-- Returns:
 
 
- 
readPickupLocationsByDistanceFromCoordinates
org.springframework.data.domain.Page<L> readPickupLocationsByDistanceFromCoordinates(Double latitude, Double longitude, Double distance, DistanceType distanceType, @Nullable org.springframework.data.domain.Pageable page, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Query for allInventoryLocationreferences that are marked as pickup locations and have a latitude and longitude within a given distance of a provided coordinate.- Parameters:
 latitude-longitude-distance-distanceType-page-contextInfo-- Returns:
 
 
- 
readShippingLocationsByDistanceFromCoordinates
org.springframework.data.domain.Page<L> readShippingLocationsByDistanceFromCoordinates(Double latitude, Double longitude, Double distance, DistanceType distanceType, @Nullable org.springframework.data.domain.Pageable page, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Query for allInventoryLocationreferences that are marked as shipping locations and have a latitude and longitude within a given distance of a provided coordinate.- Parameters:
 latitude-longitude-distance-distanceType-page-contextInfo-- Returns:
 
 
- 
readStoreLocationsByDistanceFromCoordinates
org.springframework.data.domain.Page<L> readStoreLocationsByDistanceFromCoordinates(Double latitude, Double longitude, Double distance, DistanceType distanceType, @Nullable org.springframework.data.domain.Pageable page, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Query for allInventoryLocationreferences that are marked as "Store" locations and have a latitude and longitude within a given distance of a provided coordinate.- Parameters:
 latitude-longitude-distance-distanceType-page-contextInfo-- Returns:
 
 
- 
readAllLocationsByDistanceFromCoordinates
org.springframework.data.domain.Page<L> readAllLocationsByDistanceFromCoordinates(Double latitude, Double longitude, Double distance, DistanceType distanceType, @Nullable org.springframework.data.domain.Pageable page, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Query for allInventoryLocationreferences that are marked as shipping locations and have a latitude and longitude within a given distance of a provided coordinate.- Parameters:
 latitude-longitude-distance-distanceType-page-contextInfo-- Returns:
 
 
- 
existsByContextId
boolean existsByContextId(String contextId, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Indicates if anInventoryLocationexists with the specified contextId in the provided context.- Parameters:
 contextId-contextInfo-- Returns:
 
 
- 
getRepositoryDomain
String getRepositoryDomain()
 
 - 
 
 -