This package provides helper methods where you may be using values in RawRepresentable Enums and have to call the .rawValue alot. When using Arrays or Dictionaries where you would have the Element or Key type the same as a Enum with a RawValue type the same, this package will provide simmilar getter/setter/add/remove methods so you don't need to add the .rawValue each time
enum CodingKeys: String {
case key1
case key2
case key3
}
var dictionary[String: Any] = [:]
dictionary[CodingKeys.key1] = true
dictionary[CodingKeys.key2] = 1
dictionary[CodingKeys.key3] = "String"
dictionary.removeValue(forKey: CodingKeys.key2)
var array: [String] = []
array.append(CodingKeys.key1)
array.append(CodingKeys.key2)
array.append(CodingKeys.key3)
_ = array.contains(CodingKeys.key3)
- Tyler Anger - Initial work - TheAngryDarling
This project is licensed under Apache License v2.0 - see the LICENSE.md file for details