Java Class isPrimitive() MethodThe isPrimitive() method of java Class class checks if the specified Class object represents a primitive type. SyntaxParameterNA Returnstrue if and only if this class represents a primitive type. ThrowsNA Example 1Test it NowOutput: true false false Example 2Test it NowOutput: obj is primitive type? = false k is primitive type? = true
Next TopicJava Class
|