-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #97 from OpenStack-mobile/develop
Release v2.3.2
- Loading branch information
Showing
22 changed files
with
137 additions
and
71 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 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,37 @@ | ||
// | ||
// Level.swift | ||
// OpenStack Summit | ||
// | ||
// Created by Gabriel Horacio Cutrini on 4/18/17. | ||
// Copyright © 2017 OpenStack. All rights reserved. | ||
// | ||
|
||
public enum Level: String, Comparable { | ||
|
||
case Beginner | ||
case Intermediate | ||
case Advanced | ||
case NotApplicable = "N/A" | ||
|
||
public var order: Int { | ||
|
||
switch self { | ||
case .Beginner: return 0 | ||
case .Intermediate: return 1 | ||
case .Advanced: return 2 | ||
case .NotApplicable: return 3 | ||
} | ||
} | ||
} | ||
|
||
// MARK: - Comparable | ||
|
||
public func == (lhs: Level, rhs: Level) -> Bool { | ||
|
||
return lhs.order == rhs.order | ||
} | ||
|
||
public func < (lhs: Level, rhs: Level) -> Bool { | ||
|
||
return lhs.order < rhs.order | ||
} |
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 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 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 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 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 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
Oops, something went wrong.