fun optInt(key: String?): Int { return optInt(key, 0) }
Get an optional int value associated with a key , or zero if there is no such key or if the value is not a number . If the value is a string , an attempt will be made to evaluate it as a number .