You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
class Grid : NSObject, NSCoding, Mappable{
var b : Int?
class func newInstance(map: Map) -> Mappable?{
return Grid()
}
... ...
Can NOT export "A"。
so.
/**
Creates and returns a dictionary who is built up by combining all the dictionary elements in the passed array.
- parameter array: array of dictionaries.
- returns: dictionary that combines all the dictionary elements in the array.
*/
func unionDictionaryFromArrayElements(_ array: NSArray) -> NSDictionary
{
let dictionary = NSMutableDictionary()
for item in array{
if let dic = item as? NSDictionary{
//loop all over its keys
for key in dic.allKeys as! [String]{
//error : all keys = dictionary + dic
if let old = dictionary[key] as? NSArray,
let new = dic[key] as? [Any] {
dictionary[key] = old.addingObjects(from: new)
} else {
dictionary[key] = dic[key]
}
// dictionary[key] = dic[key]
}
}
}
return dictionary
}
The text was updated successfully, but these errors were encountered:
JSON:
==> "grids.swift"
Can NOT export "A"。
so.
The text was updated successfully, but these errors were encountered: