Package com.commercetools.api.client
Class ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete
java.lang.Object
io.vrap.rmf.base.client.ApiMethod<T,TResult>
io.vrap.rmf.base.client.TypeApiMethod<ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete,Cart>
com.commercetools.api.client.ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete
- All Implemented Interfaces:
ConflictingTrait<ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete>,Deprecatable200Trait<ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete>,ErrorableTrait<ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete>,ExpandableTrait<ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete>,VersionedTrait<ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete>,ClientRequestCommand<Cart>,CreateHttpRequestCommand,HttpRequestCommand<Cart>,RequestCommand<Cart>
public class ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete
extends TypeApiMethod<ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete,Cart>
implements VersionedTrait<ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete>, ConflictingTrait<ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete>, ExpandableTrait<ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete>, ErrorableTrait<ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete>, Deprecatable200Trait<ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete>
Deletes the Cart for a given id in a Store. Returns a 200 status if successful.
A ResourceNotFound error is returned in the following scenarios:
- If no Cart exists in the Store for the given
id. - If the Cart exists in the Project but does not belong to a Store, or the Cart's
storefield references a different Store. - If the Cart exists in the Project but does not have either a
customerIdthat matches the customer:{id} scope, or ananonymousIdthat matches the anonymous_id:{id} scope.
CompletableFuture<ApiHttpResponse<com.commercetools.api.models.cart.Cart>> result = apiRoot
.withProjectKey("{projectKey}")
.inStoreKeyWithStoreKeyValue("{storeKey}")
.me()
.carts()
.withId("{ID}")
.delete()
.withVersion(version)
.execute()
-
Nested Class Summary
Nested classes/interfaces inherited from class io.vrap.rmf.base.client.ApiMethod
ApiMethod.ParamEntry<K,V> -
Constructor Summary
ConstructorsConstructorDescriptionByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete(ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete t) ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete(ApiHttpClient apiHttpClient, String projectKey, String storeKey, String ID) -
Method Summary
Modifier and TypeMethodDescriptionaddExpand(Collection<TValue> expand) add additional expand query parametersadd additional expand query parameteradd additional expand query parameteraddExpand(TValue expand) add additional expand query parameteraddVersion(Collection<TValue> version) add additional version query parametersadd additional version query parameteraddVersion(Supplier<Long> supplier) add additional version query parameteraddVersion(TValue version) add additional version query parameterbooleanexecute(ApiHttpClient client) executeBlocking(ApiHttpClient client, Duration timeout) getID()inthashCode()intcom.fasterxml.jackson.core.type.TypeReference<Cart>voidvoidsetProjectKey(String projectKey) voidsetStoreKey(String storeKey) toString()withExpand(Collection<TValue> expand) set expand with the specified valuesset expand with the specified valuewithExpand(Supplier<String> supplier) set expand with the specified valuewithExpand(TValue expand) set expand with the specified valuewithVersion(Collection<TValue> version) set version with the specified valuesset version with the specified valuewithVersion(Supplier<Long> supplier) set version with the specified valuewithVersion(TValue version) set version with the specified valueMethods inherited from class io.vrap.rmf.base.client.ApiMethod
addHeader, addQueryParam, addQueryParams, contentType, createHttpRequest, execute, execute, execute, execute, execute, execute, execute, executeBlocking, executeBlocking, executeBlocking, executeBlocking, executeBlocking, executeBlocking, executeBlocking, executeBlocking, executeBlocking, executeBlocking, executeBlocking, executeBlocking, executeBlocking, getFirstQueryParam, getHeaders, getQueryParam, getQueryParams, getQueryParamUriString, getQueryParamUriStrings, send, sendBlocking, sendBlocking, with, with, withHeader, withHeaders, withHttpRequest, withoutHeader, withoutQueryParam, withQueryParam, withQueryParamsMethods inherited from interface io.vrap.rmf.base.client.ClientRequestCommand
executeBlockingMethods inherited from interface com.commercetools.api.client.ConflictingTrait
asConflictingTrait, asConflictingTraitToBaseTypeMethods inherited from interface io.vrap.rmf.base.client.CreateHttpRequestCommand
createHttpRequestMethods inherited from interface com.commercetools.api.client.Deprecatable200Trait
asDeprecatable200Trait, asDeprecatable200TraitToBaseTypeMethods inherited from interface com.commercetools.api.client.ErrorableTrait
asErrorableTrait, asErrorableTraitToBaseTypeMethods inherited from interface com.commercetools.api.client.ExpandableTrait
asExpandableTrait, asExpandableTraitToBaseTypeMethods inherited from interface io.vrap.rmf.base.client.RequestCommand
executeBlockingMethods inherited from interface com.commercetools.api.client.VersionedTrait
asVersionedTrait, asVersionedTraitToBaseType
-
Constructor Details
-
ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete
public ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete(ApiHttpClient apiHttpClient, String projectKey, String storeKey, String ID) -
ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete
public ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete(ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete t)
-
-
Method Details
-
resultType
- Specified by:
resultTypein interfaceHttpRequestCommand<Cart>
-
executeBlocking
- Specified by:
executeBlockingin interfaceClientRequestCommand<Cart>- Specified by:
executeBlockingin classApiMethod<ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete,Cart>
-
execute
- Specified by:
executein interfaceClientRequestCommand<Cart>- Specified by:
executein classApiMethod<ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete,Cart>
-
getProjectKey
-
getStoreKey
-
getID
-
getVersion
- Specified by:
getVersionin interfaceVersionedTrait<ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete>
-
getExpand
- Specified by:
getExpandin interfaceExpandableTrait<ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete>
-
setProjectKey
-
setStoreKey
-
setID
-
withVersion
set version with the specified value- Specified by:
withVersionin interfaceVersionedTrait<ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete>- Type Parameters:
TValue- value type- Parameters:
version- value to be set- Returns:
- ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete
-
addVersion
add additional version query parameter- Specified by:
addVersionin interfaceVersionedTrait<ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete>- Type Parameters:
TValue- value type- Parameters:
version- value to be added- Returns:
- ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete
-
withVersion
set version with the specified value- Parameters:
supplier- supplier for the value to be set- Returns:
- ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete
-
addVersion
add additional version query parameter- Parameters:
supplier- supplier for the value to be added- Returns:
- ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete
-
withVersion
public ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete withVersion(Function<StringBuilder, StringBuilder> op) set version with the specified value- Parameters:
op- builder for the value to be set- Returns:
- ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete
-
addVersion
public ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete addVersion(Function<StringBuilder, StringBuilder> op) add additional version query parameter- Parameters:
op- builder for the value to be added- Returns:
- ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete
-
withVersion
public <TValue> ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete withVersion(Collection<TValue> version) set version with the specified values- Type Parameters:
TValue- value type- Parameters:
version- values to be set- Returns:
- ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete
-
addVersion
public <TValue> ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete addVersion(Collection<TValue> version) add additional version query parameters- Type Parameters:
TValue- value type- Parameters:
version- values to be added- Returns:
- ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete
-
withExpand
set expand with the specified value- Specified by:
withExpandin interfaceExpandableTrait<ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete>- Type Parameters:
TValue- value type- Parameters:
expand- value to be set- Returns:
- ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete
-
addExpand
add additional expand query parameter- Specified by:
addExpandin interfaceExpandableTrait<ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete>- Type Parameters:
TValue- value type- Parameters:
expand- value to be added- Returns:
- ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete
-
withExpand
set expand with the specified value- Parameters:
supplier- supplier for the value to be set- Returns:
- ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete
-
addExpand
add additional expand query parameter- Parameters:
supplier- supplier for the value to be added- Returns:
- ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete
-
withExpand
public ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete withExpand(Function<StringBuilder, StringBuilder> op) set expand with the specified value- Parameters:
op- builder for the value to be set- Returns:
- ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete
-
addExpand
public ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete addExpand(Function<StringBuilder, StringBuilder> op) add additional expand query parameter- Parameters:
op- builder for the value to be added- Returns:
- ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete
-
withExpand
public <TValue> ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete withExpand(Collection<TValue> expand) set expand with the specified values- Type Parameters:
TValue- value type- Parameters:
expand- values to be set- Returns:
- ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete
-
addExpand
public <TValue> ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete addExpand(Collection<TValue> expand) add additional expand query parameters- Type Parameters:
TValue- value type- Parameters:
expand- values to be added- Returns:
- ByProjectKeyInStoreKeyByStoreKeyMeCartsByIDDelete
-
equals
-
hashCode
public int hashCode() -
toString
-
reflectionHashCode
public int reflectionHashCode()
-