APIAdapter

protocol APIAdapter

API Aadpater Protocol, used to define functions to generate different URLs for our App

  • Reuturn rootURL

    Declaration

    Swift

    static func rootURL() -> String
  • Return APIVersion in url form

    Declaration

    Swift

    static func APIVersion() -> String
  • Generate Content Query using keywords and contentType

    Declaration

    Swift

    static func generateContentQueryURL(keyWord: String, contentType: String) -> String
  • Generate login Query URL

    Declaration

    Swift

    static func generateLoginQueryURL() -> String
  • Generate logout Query URL

    Declaration

    Swift

    static func gererateLogoutQueryURL() -> String
  • Generate User Seesion Query URL

    Declaration

    Swift

    static func generateUserSessionQueryURL() -> String
  • Gnerate Featured Content URL

    Declaration

    Swift

    static func generateFeaturedContentURL() -> String
  • Gnerate Featured Note URL

    Declaration

    Swift

    static func generateNotesURL() -> String
  • Gnerate Featured Note URL, with id as parameter

    Declaration

    Swift

    static func generateNotesURL(id: Int) -> String
  • Generate Bookmark url with id

    • id: Content id, Int
    • bookmark: Bool value if the content is being bookmarked

    Declaration

    Swift

    static func TBD_generateBookmarkURL(id: Int, bookmark: Bool) -> String

    Return Value

    bookmark url

  • GenerateReport content url

    Declaration

    Swift

    static func TBD_generateReportURL(id: Int) -> String
  • Undocumented

    Declaration

    Swift

    static func TBD_generateVoteURL(id: Int) -> String