Content
class Content : Hashable
Self defined Content , the source we put in the app is saved as this format
-
Self defined operator ==, return
trueif both equals, else returnfalseDeclaration
Swift
static func == (lhs: Content, rhs: Content) -> Bool -
Perform hash
Declaration
Swift
func hash(into hasher: inout Hasher)
-
This is a
UIImagewhich is used to display thumbnail ofContentDeclaration
Swift
var thumbnail: UIImage -
This is the title of
ContentDeclaration
Swift
let title: String -
Number of views of
ContentDeclaration
Swift
let views: Int -
Duration of
ContentDeclaration
Swift
var duration: Int -
Content Link, used to fetch content from this given link
Declaration
Swift
var contentLink: URL -
Number of likes for the
ContentDeclaration
Swift
var likes: Int -
Number of dislikes for the
ContentDeclaration
Swift
var disLikes: Int -
ID for the content
Declaration
Swift
var id: Int -
This is the description of the
ContentDeclaration
Swift
var description: String -
This is a list of
Contents which is used to store suggested Contents, the suggested Content will base on the currentContent‘s nameDeclaration
Swift
var suggestedContents: [Content] -
Initialization of wiki
Declaration
Swift
var wiki: Wiki
-
Performe
ContentinitializationDeclaration
Swift
init(title: String, id: Int, channelName: String, description: String, url: URL) -
Aviode directly calling
generateContentInfoDeclaration
Swift
func fetchContentInfo() -
Aviode directly calling
fetchSuggestedContentsDeclaration
Swift
func fetchSuggestedContents() -
Declaration
Swift
func fetchWikiChunkEnrichments() -
Increase number of likes
Declaration
Swift
func like() -
Undocumented
Declaration
Swift
func unlike() -
Increase number of dislikes
Declaration
Swift
func dislike() -
Undocumented
Declaration
Swift
func undislike()
Content Class Reference