VOWrappingPaperCategory

@interface VOWrappingPaperCategory : NSObject

VOWrappingPaperCategory is the model for representing a collection of like WrappingPapers.

  • A list of WrappingPapers for this category.

    Declaration

    Objective-C

    @property (readwrite, strong, nonatomic, nullable)
        NSArray<VOWrappingPaperMedia *> *wrappingPapers;

    Swift

    var wrappingPapers: [VOWrappingPaperMedia]? { get set }
  • A list of images that can be turned into WrappingPapers if selected.

    Declaration

    Objective-C

    @property (readwrite, strong, nonatomic, nullable)
        NSArray<VOImageMedia *> *imageResults;

    Swift

    var imageResults: [VOImageMedia]? { get set }
  • A title for the category that will be shown at the top of the VOWrappingViewController.

    Declaration

    Objective-C

    @property (readonly, strong, nonatomic, nullable) NSString *title;

    Swift

    var title: String? { get }
  • The text that is searched on google if no WrappingPapers are provided.

    Declaration

    Objective-C

    @property (readonly, strong, nonatomic, nullable) NSString *searchText;

    Swift

    var searchText: String? { get }
  • The carousel image that is shown in the carousel of the VOWrappingViewController.

    Declaration

    Objective-C

    @property (readonly, strong, nonatomic, nullable) NSString *imageUrl;

    Swift

    var imageUrl: String? { get }
  • A round version of the carousel image that is shown in the carousel of the VOWrappingViewController.

    Declaration

    Objective-C

    @property (readonly, strong, nonatomic, nullable) NSString *roundImageUrl;

    Swift

    var roundImageUrl: String? { get }
  • The type of VOWrappingPaperCategory.

    Declaration

    Objective-C

    @property (readonly, nonatomic) VOWrappingPaperCategoryType type;

    Swift

    var type: VOWrappingPaperCategoryType { get }
  • The order this category should show up in the VOWrappingViewController.

    Declaration

    Objective-C

    @property (readonly, nonatomic) NSInteger order;

    Swift

    var order: Int { get }
  • An internal referenceId to associated WrappingPapers.

    Declaration

    Objective-C

    @property (readonly, strong, nonatomic, nullable) NSString *categoryId;

    Swift

    var categoryId: String? { get }
  • Default Initializer for a VOWrappingPaperCategory from a dictionary from the server.

    Declaration

    Objective-C

    + (nonnull instancetype)wrappingPaperCategoryFromDictionary:
        (nonnull NSDictionary *)dictionary;

    Swift

    convenience init(from dictionary: [AnyHashable : Any])

    Parameters

    dictionary

    - The dictionary form of the VOWrappingPaperCategory.

    Return Value

    Instance of VOWrappingPaperCategory.

  • Converts a VOWrappingPaperCategory to an NSDictionary that can be used for caching or sending to the server.

    Declaration

    Objective-C

    - (nonnull NSDictionary *)dictionaryRepresentation;

    Swift

    func dictionaryRepresentation() -> [AnyHashable : Any]

    Return Value

    dictionary - Dictionary form of a VOWrappingPaperCategory.

  • Returns the VOImageMedia or WrappingPaper (whichever is set) at the provided index. If the index is out of bounds, nil will be returned.

    Declaration

    Objective-C

    - (nonnull id)getObjectAtIndex:(NSInteger)index;

    Swift

    func getObjectAt(_ index: Int) -> Any

    Parameters

    index

    - The index of the imageResult / wrappingPaper.

    Return Value

    an VOImageMedia or WrappingPaper at the provided index.