Skip to content

Instantly share code, notes, and snippets.

@willwfsp
Last active April 12, 2020 22:04
Show Gist options
  • Save willwfsp/2a5a274dd144d31fb7498344d0bc4f38 to your computer and use it in GitHub Desktop.
Save willwfsp/2a5a274dd144d31fb7498344d0bc4f38 to your computer and use it in GitHub Desktop.
Kinds of models
// Entity Model
struct User {
let name: String
let email: String
let nickName: String
}
// Event
struct ViewScreen {
let sessionId: String
let screenName: String
let date: String
}
// Action
struct TargetAction {
let target: Any
let controlEvent: UIControlEvent
let action: () -> Void
}
// Other Data Structures
struct Error {
let message: String
let domain: String
}
struct Coodinate {
let latitude: Double
let longitude: Double
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment