java.lang.Object
it.tdlight.jni.TdApi.Object
it.tdlight.jni.TdApi.PremiumPaymentOption
- Enclosing class:
- TdApi
Describes an option for buying Telegram Premium to a user.
-
Field Summary
Modifier and TypeFieldDescriptionlong
The amount to pay, in the smallest units of the currency.static final int
Identifier uniquely determining type of the object.ISO 4217 currency code for Telegram Premium subscription payment.int
The discount associated with this option, as a percentage.int
Number of month the Telegram Premium subscription will be active.An internal link to be opened for buying Telegram Premium to the user if store payment isn't possible; may be null if direct payment isn't available.Identifier of the store product associated with the option. -
Constructor Summary
ConstructorDescriptionDescribes an option for buying Telegram Premium to a user.PremiumPaymentOption
(DataInput input) Describes an option for buying Telegram Premium to a user.PremiumPaymentOption
(String currency, long amount, int discountPercentage, int monthCount, String storeProductId, TdApi.InternalLinkType paymentLink) Describes an option for buying Telegram Premium to a user. -
Method Summary
Modifier and TypeMethodDescriptionboolean
int
Returns an identifier uniquely determining type of the object.int
hashCode()
void
serialize
(DataOutput output) Serialize the TDLib classMethods inherited from class it.tdlight.jni.TdApi.Object
serialize, toString
-
Field Details
-
currency
ISO 4217 currency code for Telegram Premium subscription payment. -
amount
public long amountThe amount to pay, in the smallest units of the currency. -
discountPercentage
public int discountPercentageThe discount associated with this option, as a percentage. -
monthCount
public int monthCountNumber of month the Telegram Premium subscription will be active. -
storeProductId
Identifier of the store product associated with the option. -
paymentLink
An internal link to be opened for buying Telegram Premium to the user if store payment isn't possible; may be null if direct payment isn't available. -
CONSTRUCTOR
public static final int CONSTRUCTORIdentifier uniquely determining type of the object.- See Also:
-
-
Constructor Details
-
PremiumPaymentOption
public PremiumPaymentOption()Describes an option for buying Telegram Premium to a user. -
PremiumPaymentOption
public PremiumPaymentOption(String currency, long amount, int discountPercentage, int monthCount, String storeProductId, TdApi.InternalLinkType paymentLink) Describes an option for buying Telegram Premium to a user.- Parameters:
currency
- ISO 4217 currency code for Telegram Premium subscription payment.amount
- The amount to pay, in the smallest units of the currency.discountPercentage
- The discount associated with this option, as a percentage.monthCount
- Number of month the Telegram Premium subscription will be active.storeProductId
- Identifier of the store product associated with the option.paymentLink
- An internal link to be opened for buying Telegram Premium to the user if store payment isn't possible; may be null if direct payment isn't available.
-
PremiumPaymentOption
Describes an option for buying Telegram Premium to a user.- Parameters:
input
- Serialized input- Throws:
IOException
- the deserialization failed
-
-
Method Details
-
getConstructor
public int getConstructor()Description copied from class:TdApi.Object
Returns an identifier uniquely determining type of the object.- Specified by:
getConstructor
in classTdApi.Object
- Returns:
- this.CONSTRUCTOR
-
serialize
Serialize the TDLib class- Specified by:
serialize
in classTdApi.Object
- Parameters:
output
- output data stream- Throws:
IOException
- the serialization failed
-
equals
-
hashCode
public int hashCode()
-