-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
7977300
commit dad2110
Showing
12 changed files
with
260 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
// | ||
// PageInfo.swift | ||
// SwiftRorty.iOS | ||
// | ||
// Created by developersancho on 31.01.2022. | ||
// | ||
|
||
import Foundation | ||
|
||
struct PageInfo: Codable { | ||
let count: Int? | ||
let next: String? | ||
let pages: Int? | ||
let prev: String? | ||
|
||
enum CodingKeys: String, CodingKey { | ||
case count = "count" | ||
case next = "next" | ||
case pages = "pages" | ||
case prev = "prev" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
// | ||
// Status.swift | ||
// SwiftRorty.iOS | ||
// | ||
// Created by developersancho on 3.02.2022. | ||
// | ||
|
||
import Foundation | ||
|
||
enum Status: String, Codable { | ||
case Alive | ||
case Dead | ||
case Unknown | ||
} |
23 changes: 23 additions & 0 deletions
23
SwiftRorty.iOS/data/model/remote/character/CharacterInfo.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
// | ||
// CharacterInfo.swift | ||
// SwiftRorty.iOS | ||
// | ||
// Created by developersancho on 3.02.2022. | ||
// | ||
|
||
import Foundation | ||
|
||
struct CharacterInfo: Codable { | ||
let created: String? | ||
let episode: [String]? | ||
let gender: String? | ||
let id: Int? | ||
let image: String? | ||
let location: Location? | ||
let name: String? | ||
let origin: Origin? | ||
let species: String? | ||
let status: Status? | ||
let type: String? | ||
let url: String? | ||
} |
13 changes: 13 additions & 0 deletions
13
SwiftRorty.iOS/data/model/remote/character/CharacterResponse.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
// | ||
// CharacterResponse.swift | ||
// SwiftRorty.iOS | ||
// | ||
// Created by developersancho on 3.02.2022. | ||
// | ||
|
||
import Foundation | ||
|
||
struct CharacterResponse: Codable { | ||
let pageInfo: PageInfo? | ||
let results: [CharacterInfo]? | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
// | ||
// Location.swift | ||
// SwiftRorty.iOS | ||
// | ||
// Created by developersancho on 3.02.2022. | ||
// | ||
|
||
import Foundation | ||
|
||
struct Location: Codable { | ||
let name: String? | ||
let url: String? | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
// | ||
// Origin.swift | ||
// SwiftRorty.iOS | ||
// | ||
// Created by developersancho on 3.02.2022. | ||
// | ||
|
||
import Foundation | ||
|
||
struct Origin: Codable { | ||
let name: String? | ||
let url: String? | ||
} |
18 changes: 18 additions & 0 deletions
18
SwiftRorty.iOS/data/model/remote/episode/EpisodeInfo.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
// | ||
// EpisodeInfo.swift | ||
// SwiftRorty.iOS | ||
// | ||
// Created by developersancho on 3.02.2022. | ||
// | ||
|
||
import Foundation | ||
|
||
struct EpisodeInfo: Codable { | ||
let airDate: String? | ||
let characters: [String]? | ||
let created: String? | ||
let episode: String? | ||
let id: Int? | ||
let name: String? | ||
let url: String? | ||
} |
13 changes: 13 additions & 0 deletions
13
SwiftRorty.iOS/data/model/remote/episode/EpisodeResponse.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
// | ||
// EpisodeResponse.swift | ||
// SwiftRorty.iOS | ||
// | ||
// Created by developersancho on 3.02.2022. | ||
// | ||
|
||
import Foundation | ||
|
||
struct EpisodeResponse: Codable { | ||
let pageInfo: PageInfo? | ||
let results: [EpisodeInfo]? | ||
} |
28 changes: 28 additions & 0 deletions
28
SwiftRorty.iOS/data/model/remote/location/LocationInfo.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
// | ||
// LocationInfo.swift | ||
// SwiftRorty.iOS | ||
// | ||
// Created by developersancho on 3.02.2022. | ||
// | ||
|
||
import Foundation | ||
|
||
struct LocationInfo: Codable { | ||
let dimension: String? | ||
let residents: [String]? | ||
let created: String? | ||
let type: String? | ||
let id: Int? | ||
let name: String? | ||
let url: String? | ||
|
||
enum CodingKeys: String, CodingKey { | ||
case dimension = "dimension" | ||
case residents = "residents" | ||
case created = "created" | ||
case type = "type" | ||
case id = "id" | ||
case name = "name" | ||
case url = "url" | ||
} | ||
} |
18 changes: 18 additions & 0 deletions
18
SwiftRorty.iOS/data/model/remote/location/LocationResponse.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
// | ||
// LocationResponse.swift | ||
// SwiftRorty.iOS | ||
// | ||
// Created by developersancho on 3.02.2022. | ||
// | ||
|
||
import Foundation | ||
|
||
struct LocationResponse: Codable { | ||
let pageInfo: PageInfo? | ||
let location: [LocationInfo]? | ||
|
||
enum CodingKeys: String, CodingKey { | ||
case pageInfo = "pageInfo" | ||
case location = "results" | ||
} | ||
} |