Package com.stripe.model.entitlements
Class Feature
java.lang.Object
com.stripe.model.StripeObject
com.stripe.net.ApiResource
com.stripe.model.entitlements.Feature
- All Implemented Interfaces:
HasId,MetadataStore<Feature>,StripeActiveObject,StripeObjectInterface
A feature represents a monetizable ability or functionality in your system. Features can be
assigned to products, and when those products are purchased, Stripe will create an entitlement to
the feature for the purchasing customer.
-
Nested Class Summary
Nested classes/interfaces inherited from class com.stripe.net.ApiResource
ApiResource.RequestMethod -
Field Summary
Fields inherited from class com.stripe.net.ApiResource
CHARSET, GSON, INTERNAL_GSONFields inherited from class com.stripe.model.StripeObject
PRETTY_PRINT_GSON -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected booleanstatic Featurecreate(FeatureCreateParams params) Creates a feature.static Featurecreate(FeatureCreateParams params, RequestOptions options) Creates a feature.static FeatureCreates a feature.static Featurecreate(Map<String, Object> params, RequestOptions options) Creates a feature.booleanInactive features cannot be attached to new products and will not be returned from the features list endpoint.getId()Unique identifier for the object.Has the valuetrueif the object exists in live mode or the valuefalseif the object exists in test mode.A unique key you provide as your own system identifier.Set of key-value pairs that you can attach to an object.getName()The feature's name, for your own purpose, not meant to be displayable to the customer.String representing the object's type.inthashCode()static FeatureCollectionlist(FeatureListParams params) Retrieve a list of features.static FeatureCollectionlist(FeatureListParams params, RequestOptions options) Retrieve a list of features.static FeatureCollectionRetrieve a list of features.static FeatureCollectionlist(Map<String, Object> params, RequestOptions options) Retrieve a list of features.static FeatureRetrieves a feature.static Featureretrieve(String id, RequestOptions options) Retrieves a feature.static Featureretrieve(String id, FeatureRetrieveParams params, RequestOptions options) Retrieves a feature.static FeatureRetrieves a feature.voidInactive features cannot be attached to new products and will not be returned from the features list endpoint.voidUnique identifier for the object.voidsetLivemode(Boolean livemode) Has the valuetrueif the object exists in live mode or the valuefalseif the object exists in test mode.voidsetLookupKey(String lookupKey) A unique key you provide as your own system identifier.voidsetMetadata(Map<String, String> metadata) Set of key-value pairs that you can attach to an object.voidThe feature's name, for your own purpose, not meant to be displayable to the customer.voidString representing the object's type.update(FeatureUpdateParams params) Update a feature’s metadata or permanently deactivate it.update(FeatureUpdateParams params, RequestOptions options) Update a feature’s metadata or permanently deactivate it.Update a feature’s metadata or permanently deactivate it.update(Map<String, Object> params, RequestOptions options) Update a feature’s metadata or permanently deactivate it.Methods inherited from class com.stripe.net.ApiResource
checkNullTypedParams, getGlobalResponseGetter, getResponseGetter, setExpandableFieldId, setGlobalResponseGetter, setResponseGetter, urlEncode, urlEncodeIdMethods inherited from class com.stripe.model.StripeObject
deserializeStripeObject, deserializeStripeObject, deserializeStripeObject, deserializeStripeObject, equals, getLastResponse, getRawJsonObject, setLastResponse, toJson, toStringMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface com.stripe.model.StripeActiveObject
trySetResponseGetter
-
Constructor Details
-
Feature
public Feature()
-
-
Method Details
-
create
Creates a feature.- Throws:
StripeException
-
create
public static Feature create(Map<String, Object> params, RequestOptions options) throws StripeExceptionCreates a feature.- Throws:
StripeException
-
create
Creates a feature.- Throws:
StripeException
-
create
public static Feature create(FeatureCreateParams params, RequestOptions options) throws StripeException Creates a feature.- Throws:
StripeException
-
list
Retrieve a list of features.- Throws:
StripeException
-
list
public static FeatureCollection list(Map<String, Object> params, RequestOptions options) throws StripeExceptionRetrieve a list of features.- Throws:
StripeException
-
list
Retrieve a list of features.- Throws:
StripeException
-
list
public static FeatureCollection list(FeatureListParams params, RequestOptions options) throws StripeException Retrieve a list of features.- Throws:
StripeException
-
retrieve
Retrieves a feature.- Throws:
StripeException
-
retrieve
Retrieves a feature.- Throws:
StripeException
-
retrieve
public static Feature retrieve(String id, Map<String, Object> params, RequestOptions options) throws StripeExceptionRetrieves a feature.- Throws:
StripeException
-
retrieve
public static Feature retrieve(String id, FeatureRetrieveParams params, RequestOptions options) throws StripeException Retrieves a feature.- Throws:
StripeException
-
update
Update a feature’s metadata or permanently deactivate it.- Specified by:
updatein interfaceMetadataStore<Feature>- Throws:
StripeException
-
update
Update a feature’s metadata or permanently deactivate it.- Specified by:
updatein interfaceMetadataStore<Feature>- Throws:
StripeException
-
update
Update a feature’s metadata or permanently deactivate it.- Throws:
StripeException
-
update
Update a feature’s metadata or permanently deactivate it.- Throws:
StripeException
-
getActive
Inactive features cannot be attached to new products and will not be returned from the features list endpoint. -
getLivemode
Has the valuetrueif the object exists in live mode or the valuefalseif the object exists in test mode. -
getLookupKey
A unique key you provide as your own system identifier. This may be up to 80 characters. -
getName
The feature's name, for your own purpose, not meant to be displayable to the customer. -
getObject
String representing the object's type. Objects of the same type share the same value.Equal to
entitlements.feature. -
setActive
Inactive features cannot be attached to new products and will not be returned from the features list endpoint. -
setId
Unique identifier for the object. -
setLivemode
Has the valuetrueif the object exists in live mode or the valuefalseif the object exists in test mode. -
setLookupKey
A unique key you provide as your own system identifier. This may be up to 80 characters. -
setMetadata
Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. -
setName
The feature's name, for your own purpose, not meant to be displayable to the customer. -
setObject
String representing the object's type. Objects of the same type share the same value.Equal to
entitlements.feature. -
equals
-
canEqual
-
hashCode
public int hashCode() -
getId
Unique identifier for the object. -
getMetadata
Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.- Specified by:
getMetadatain interfaceMetadataStore<Feature>
-