Skip to main content

JSONValue

This is a boxed type (a TL class): the Go interface tg.JSONValueClass, implemented by the constructors below. A value of this type is one of them — switch on the concrete type to handle it.

switch v := value.(type) {
case *tg.JSONArray: // jsonArray
case *tg.JSONBool: // jsonBool
case *tg.JSONNull: // jsonNull
case *tg.JSONNumber: // jsonNumber
case *tg.JSONObject: // jsonObject
case *tg.JSONString: // jsonString
}

Constructors

ConstructorTL name
JSONArrayjsonArray
JSONBooljsonBool
JSONNulljsonNull
JSONNumberjsonNumber
JSONObjectjsonObject
JSONStringjsonString

References