         case .JBool(let value):
             return "\(value)"
         case .JString(let value):
-            
             let jsonAbleString = value.stringByReplacingOccurrencesOfString("\"", withString: "\\\"", options: NSStringCompareOptions.CaseInsensitiveSearch, range: nil)
             return "\"\(jsonAbleString)\""
         case .JNull:

            return nil
        }
    }
    var bool:Bool?{
        switch self{
        case .JBool(let value):
            return value
        default:
            return nil
        }
    }
    var array:Array<JSONValue>?{
        switch self{
        case .JArray(let value):
            return value
        default:
            return nil
        }
    }
    var object:Dictionary<String,JSONValue>?{
        switch self{
        case .JObject(let value):
            return value
        default:

            self = .JNull
        case let value as NSArray:
            var jsonValues = JSONValue[]()
            for possibleJsonValue : AnyObject in value {
                let jsonValue = JSONValue(possibleJsonValue)
                if  jsonValue {
                    jsonValues.append(jsonValue)
                }
            }
            self = .JArray(jsonValues)
        case let value as NSDictionary:
            var jsonObject = Dictionary<String, JSONValue>()
            for (possibleJsonKey : AnyObject, possibleJsonValue : AnyObject) in value {
                if let key = possibleJsonKey as? NSString {
                    let jsonValue = JSONValue(possibleJsonValue)
                    if jsonValue {
                        jsonObject[key] = jsonValue
                    }
                }
            }
