Code example for JsonParseException

0
            { 
                float var6 = par1JsonElement.getAsFloat();
 
                if (var6 < par4)
                { 
                    throw new JsonParseException("Invalid " + par2Str + ": expected float >= " + par4 + ", was " + var6);
                } 
                else if (var6 > par5)
                { 
                    throw new JsonParseException("Invalid " + par2Str + ": expected float <= " + par5 + ", was " + var6);
                } 
                else 
                { 
                    return var6;
                } 
            } 
            catch (NumberFormatException var7)
            { 
                throw new JsonParseException("Invalid " + par2Str + ": expected float, was " + par1JsonElement, var7);
            } 
Experience pair programming with AI  Get Codota for Java