CodeQL library for Java/Kotlin
codeql/java-all 0.11.0 (changelog, source)
Search

Module JDK

Provides classes and predicates for working with standard classes and methods from the JDK.

Import path

import semmle.code.java.JDK

Imports

ExternalProcess

Definitions related to external processes.

Member

Provides classes and predicates for working with members of Java classes and interfaces, that is, methods, constructors, fields and nested types.

Classes

ArrayLengthField

The length field of the array type.

ClassNameMethod

The method Class.getName().

ClassSimpleNameMethod

The method Class.getSimpleName().

CloneMethod

A method with the same signature as java.lang.Object.clone.

EqualsMethod

A method with the same signature as java.lang.Object.equals.

HashCodeMethod

A method with the same signature as java.lang.Object.hashCode.

ImmutableType

An immutable type.

MainMethod

The public static main method, with a single formal parameter of type String[] and return type void.

MethodAbs

The method Math.abs.

MethodCallSystemGetProperty

A call to a method named getProperty on class java.lang.System.

MethodExit

Any method named exit on class java.lang.Runtime or java.lang.System.

MethodMathMax

The method Math.min.

MethodMathMin

The method Math.min.

MethodProcessBuilderCommand

DEPRECATED: Any of the methods named command on class java.lang.ProcessBuilder.

MethodRuntimeExec

DEPRECATED: Any method named exec on class java.lang.Runtime.

MethodSystemGetProperty

Any method named getProperty on class java.lang.System.

MethodSystemGetenv

Any method named getenv on class java.lang.System.

NumberType

A (reflexive, transitive) subtype of java.lang.Number.

PreMainMethod

A premain method is an agent entry-point.

ProcessBuilderConstructor

DEPRECATED: Any constructor of class java.lang.ProcessBuilder.

ReadObjectMethod

A method that reads an object on type java.io.ObjectInputStream, including readObject, readObjectOverride, readUnshared and resolveObject.

StringBuildingType

Class java.lang.StringBuffer or java.lang.StringBuilder.

StringContainsMethod

The contains() method of the class java.lang.String.

StringLengthMethod

The length() method of the class java.lang.String.

StringPartialMatchMethod

The methods on the class java.lang.String that are used to perform partial matches with a specified substring or char.

SystemErr

The field System.err.

SystemIn

The field System.in.

SystemOut

The field System.out.

ThrowableType

A (reflexive, transitive) subtype of java.lang.Throwable.

ToStringMethod

A method with the same signature as java.lang.Object.toString.

TypeClass

The class java.lang.Class.

TypeClassCastException

The class java.lang.ClassCastException.

TypeCloneable

The interface java.lang.Cloneable.

TypeConstructor

The class java.lang.Constructor.

TypeError

The class java.lang.Error.

TypeException

The class java.lang.Exception.

TypeFile

The class java.io.File.

TypeFileSystem

The class java.nio.file.FileSystem.

TypeInputStream

The class java.io.InputStream.

TypeMath

The class java.lang.Math.

TypeNullPointerException

The class java.lang.NullPointerException.

TypeNumber

The class java.lang.Number.

TypeObject

The class java.lang.Object.

TypeObjectInputStream

The type java.io.ObjectInputStream.

TypeObjectOutput

The interface java.io.ObjectOutput.

TypeObjectOutputStream

The type java.io.ObjectOutputStream.

TypePath

The type java.nio.file.Path.

TypePaths

The class java.nio.file.Paths.

TypeProcessBuilder

The class java.lang.ProcessBuilder.

TypeRuntime

The class java.lang.Runtime.

TypeRuntimeException

The class java.lang.RuntimeException.

TypeSerializable

The interface java.io.Serializable.

TypeString

The class java.lang.String.

TypeStringBuffer

The class java.lang.StringBuffer.

TypeStringBuilder

The class java.lang.StringBuilder.

TypeSystem

The class java.lang.System.

TypeThrowable

The class java.lang.Throwable.

UncheckedThrowableType

An unchecked exception. That is, a (reflexive, transitive) subtype of java.lang.Error or java.lang.RuntimeException.

WriteObjectMethod

A method named writeObject on type java.io.ObjectOutput or java.io.ObjectOutputStream.

Aliases

MethodAccessSystemGetProperty

DEPRECATED: Alias for MethodCallSystemGetProperty.