ProductReviews
@objc(GFYProductReviews)
public class ProductReviews : NSObject, Encodable
Contains product review and rating information
-
The product rating rounded to two decimal places
Declaration
Swift
public var rating: Decimal? { get }
-
The allowable rating range
Declaration
Swift
public let ratingScale: ClosedRange<Double>?
-
The number of reviews
Declaration
Swift
public let reviewCount: UInt?
-
Creates a
ProductReviews
instanceReturns
nil
if all parameters arenil
or ifrating
is out of range for the providedratingScale
.Declaration
Swift
public init?(rating: Double?, ratingScale: ClosedRange<Double>?, reviewCount: UInt?)
Parameters
rating
The product rating
ratingScale
The allowable rating range
reviewCount
The number of reviews
-
Retrieves
String
representation ofProductReviews
Declaration
Swift
public override var description: String { get }