Inherits from NSManagedObject
Declared in Book.h
Book.m

Overview

Book class description. The class that includes attributes and methods for Book object.

Tasks

Create Methods

Class Methods

bookWithISBN:title:author:publishDate:cover:inManagedObjectContext:

Method that creates a Book object.

+ (Book *)bookWithISBN:(NSString *)isbn title:(NSString *)title author:(NSString *)author publishDate:(NSDate *)publishDate cover:(NSString *)cover inManagedObjectContext:(NSManagedObjectContext *)context

Parameters

isbn

ISBN number of the book.

title

Title of the book.

author

Author of the book.

publishDate

The date the book published.

cover

The image URL of the book cover.

context

Managed object context of the database.

Return Value

Returns the Book object that is created.

Discussion

Method that creates a Book object.

Declared In

Book+Create.h

Instance Methods

addDateAsString

Method that converts addDate to string.

- (NSString *)addDateAsString

Return Value

The string version of the date the book is added to collection.

Discussion

Method that converts addDate to string.

Declared In

Book+Create.h

publishDateAsString

Method that converts publishDate to string.

- (NSString *)publishDateAsString

Return Value

The string version of the attribute publishDate.

Discussion

Method that converts publishDate to string.

Declared In

Book+Create.h