O2Application.swift 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132
  1. //
  2. // O2Data.swift
  3. // Model file generated using JSONExport: https://github.com/Ahmed-Ali/JSONExport
  4. import Foundation
  5. import ObjectMapper
  6. class O2Application : NSObject, NSCoding, Mappable{
  7. var alias : String?
  8. var applicationCategory : String?
  9. var availableCompanyList : [AnyObject]?
  10. var availableDepartmentList : [String]?
  11. var availableIdentityList : [AnyObject]?
  12. var controllerList : [AnyObject]?
  13. var createTime : String?
  14. var creatorPerson : String?
  15. var descriptionField : String?
  16. var icon : String?
  17. var id : String?
  18. var lastUpdatePerson : String?
  19. var lastUpdateTime : String?
  20. var name : String?
  21. var updateTime : String?
  22. class func newInstance(map: Map) -> Mappable?{
  23. return O2Application()
  24. }
  25. required init?(map: Map){}
  26. private override init(){}
  27. func mapping(map: Map)
  28. {
  29. alias <- map["alias"]
  30. applicationCategory <- map["applicationCategory"]
  31. availableCompanyList <- map["availableCompanyList"]
  32. availableDepartmentList <- map["availableDepartmentList"]
  33. availableIdentityList <- map["availableIdentityList"]
  34. controllerList <- map["controllerList"]
  35. createTime <- map["createTime"]
  36. creatorPerson <- map["creatorPerson"]
  37. descriptionField <- map["description"]
  38. icon <- map["icon"]
  39. id <- map["id"]
  40. lastUpdatePerson <- map["lastUpdatePerson"]
  41. lastUpdateTime <- map["lastUpdateTime"]
  42. name <- map["name"]
  43. updateTime <- map["updateTime"]
  44. }
  45. /**
  46. * NSCoding required initializer.
  47. * Fills the data from the passed decoder
  48. */
  49. @objc required init(coder aDecoder: NSCoder)
  50. {
  51. alias = aDecoder.decodeObject(forKey: "alias") as? String
  52. applicationCategory = aDecoder.decodeObject(forKey: "applicationCategory") as? String
  53. availableCompanyList = aDecoder.decodeObject(forKey: "availableCompanyList") as? [AnyObject]
  54. availableDepartmentList = aDecoder.decodeObject(forKey: "availableDepartmentList") as? [String]
  55. availableIdentityList = aDecoder.decodeObject(forKey: "availableIdentityList") as? [AnyObject]
  56. controllerList = aDecoder.decodeObject(forKey: "controllerList") as? [AnyObject]
  57. createTime = aDecoder.decodeObject(forKey: "createTime") as? String
  58. creatorPerson = aDecoder.decodeObject(forKey: "creatorPerson") as? String
  59. descriptionField = aDecoder.decodeObject(forKey: "description") as? String
  60. icon = aDecoder.decodeObject(forKey: "icon") as? String
  61. id = aDecoder.decodeObject(forKey: "id") as? String
  62. lastUpdatePerson = aDecoder.decodeObject(forKey: "lastUpdatePerson") as? String
  63. lastUpdateTime = aDecoder.decodeObject(forKey: "lastUpdateTime") as? String
  64. name = aDecoder.decodeObject(forKey: "name") as? String
  65. updateTime = aDecoder.decodeObject(forKey: "updateTime") as? String
  66. }
  67. /**
  68. * NSCoding required method.
  69. * Encodes mode properties into the decoder
  70. */
  71. @objc func encode(with aCoder: NSCoder)
  72. {
  73. if alias != nil{
  74. aCoder.encode(alias, forKey: "alias")
  75. }
  76. if applicationCategory != nil{
  77. aCoder.encode(applicationCategory, forKey: "applicationCategory")
  78. }
  79. if availableCompanyList != nil{
  80. aCoder.encode(availableCompanyList, forKey: "availableCompanyList")
  81. }
  82. if availableDepartmentList != nil{
  83. aCoder.encode(availableDepartmentList, forKey: "availableDepartmentList")
  84. }
  85. if availableIdentityList != nil{
  86. aCoder.encode(availableIdentityList, forKey: "availableIdentityList")
  87. }
  88. if controllerList != nil{
  89. aCoder.encode(controllerList, forKey: "controllerList")
  90. }
  91. if createTime != nil{
  92. aCoder.encode(createTime, forKey: "createTime")
  93. }
  94. if creatorPerson != nil{
  95. aCoder.encode(creatorPerson, forKey: "creatorPerson")
  96. }
  97. if descriptionField != nil{
  98. aCoder.encode(descriptionField, forKey: "description")
  99. }
  100. if icon != nil{
  101. aCoder.encode(icon, forKey: "icon")
  102. }
  103. if id != nil{
  104. aCoder.encode(id, forKey: "id")
  105. }
  106. if lastUpdatePerson != nil{
  107. aCoder.encode(lastUpdatePerson, forKey: "lastUpdatePerson")
  108. }
  109. if lastUpdateTime != nil{
  110. aCoder.encode(lastUpdateTime, forKey: "lastUpdateTime")
  111. }
  112. if name != nil{
  113. aCoder.encode(name, forKey: "name")
  114. }
  115. if updateTime != nil{
  116. aCoder.encode(updateTime, forKey: "updateTime")
  117. }
  118. }
  119. }