Class Price
- java.lang.Object
-
- com.rometools.modules.mediarss.types.Price
-
- All Implemented Interfaces:
Serializable
public class Price extends Object implements Serializable
Optional tag to include pricing information about a media object.- Since:
- MediaRSS 1.5.0
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classPrice.TypeValid values arerent,purchase,packageorsubscription.
-
Constructor Summary
Constructors Constructor Description Price()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object obj)StringgetCurrency()use ISO 4217 {@link http://en.wikipedia.org/wiki/ISO_4217} for currency codes.URLgetInfo()if the type is "package" or "subscription", then info is a URL pointing to package or subscription information.DoublegetPrice()price is the price of the media object.Price.TypegetType()Valid values are "rent", "purchase", "package" or "subscription".inthashCode()voidsetCurrency(String currency)use ISO 4217 {@link http://en.wikipedia.org/wiki/ISO_4217} for currency codes.voidsetInfo(URL info)if the type is "package" or "subscription", then info is a URL pointing to package or subscription information.voidsetPrice(Double price)price is the price of the media object.voidsetType(Price.Type type)Valid values are "rent", "purchase", "package" or "subscription".StringtoString()
-
-
-
Method Detail
-
getType
public Price.Type getType()
Valid values are "rent", "purchase", "package" or "subscription". If nothing is specified, then the media is free.- Returns:
- the type
-
setType
public void setType(Price.Type type)
Valid values are "rent", "purchase", "package" or "subscription". If nothing is specified, then the media is free.- Parameters:
type- the type
-
getPrice
public Double getPrice()
price is the price of the media object. This is an optional attribute.- Returns:
- the price
-
setPrice
public void setPrice(Double price)
price is the price of the media object. This is an optional attribute.- Parameters:
price- the price
-
getCurrency
public String getCurrency()
use ISO 4217 {@link http://en.wikipedia.org/wiki/ISO_4217} for currency codes. This is an optional attribute.- Returns:
- ISO 4217 currency code
-
setCurrency
public void setCurrency(String currency)
use ISO 4217 {@link http://en.wikipedia.org/wiki/ISO_4217} for currency codes. This is an optional attribute.- Parameters:
currency- ISO 4217 currency code
-
getInfo
public URL getInfo()
if the type is "package" or "subscription", then info is a URL pointing to package or subscription information. This is an optional attribute.- Returns:
- info url
-
setInfo
public void setInfo(URL info)
if the type is "package" or "subscription", then info is a URL pointing to package or subscription information. This is an optional attribute.- Parameters:
info- url
-
-