From 187cfd7be7285beeaa31f0e1607acebd0781c789 Mon Sep 17 00:00:00 2001 From: erik-krogh Date: Tue, 31 Jan 2023 14:23:57 +0100 Subject: [PATCH 001/135] add `isShellInterpreted` to the `SystemCommandExecution` concept --- python/ql/lib/semmle/python/Concepts.qll | 6 ++++ .../lib/semmle/python/frameworks/Fabric.qll | 14 ++++++-- .../lib/semmle/python/frameworks/Invoke.qll | 2 ++ .../lib/semmle/python/frameworks/Stdlib.qll | 32 +++++++++++++++++-- 4 files changed, 50 insertions(+), 4 deletions(-) diff --git a/python/ql/lib/semmle/python/Concepts.qll b/python/ql/lib/semmle/python/Concepts.qll index b4d2a64cb45..8ea64a1373c 100644 --- a/python/ql/lib/semmle/python/Concepts.qll +++ b/python/ql/lib/semmle/python/Concepts.qll @@ -19,6 +19,9 @@ private import semmle.python.security.internal.EncryptionKeySizes * extend `SystemCommandExecution::Range` instead. */ class SystemCommandExecution extends DataFlow::Node instanceof SystemCommandExecution::Range { + /** Holds if a shell interprets `arg`. */ + predicate isShellInterpreted(DataFlow::Node arg) { super.isShellInterpreted(arg) } + /** Gets the argument that specifies the command to be executed. */ DataFlow::Node getCommand() { result = super.getCommand() } } @@ -35,6 +38,9 @@ module SystemCommandExecution { abstract class Range extends DataFlow::Node { /** Gets the argument that specifies the command to be executed. */ abstract DataFlow::Node getCommand(); + + /** Holds if a shell interprets `arg`. */ + predicate isShellInterpreted(DataFlow::Node arg) { none() } } } diff --git a/python/ql/lib/semmle/python/frameworks/Fabric.qll b/python/ql/lib/semmle/python/frameworks/Fabric.qll index 5fd9d2afe18..31511dbeaf4 100644 --- a/python/ql/lib/semmle/python/frameworks/Fabric.qll +++ b/python/ql/lib/semmle/python/frameworks/Fabric.qll @@ -43,13 +43,19 @@ private module FabricV1 { * - https://docs.fabfile.org/en/1.14/api/core/operations.html#fabric.operations.run * - https://docs.fabfile.org/en/1.14/api/core/operations.html#fabric.operations.sudo */ - private class FabricApiLocalRunSudoCall extends SystemCommandExecution::Range, - DataFlow::CallCfgNode { + private class FabricApiLocalRunSudoCall extends SystemCommandExecution::Range, API::CallNode { FabricApiLocalRunSudoCall() { this = api().getMember(["local", "run", "sudo"]).getACall() } override DataFlow::Node getCommand() { result = [this.getArg(0), this.getArgByName("command")] } + + override predicate isShellInterpreted(DataFlow::Node arg) { + arg = this.getCommand() and + // defaults to running in a shell + not this.getParameter(1, "shell").asSink().asExpr().(ImmutableLiteral).booleanValue() = + false // TODO: Test this in unsafe-shell-command-construction - and add tracking as a separate step. + } } } } @@ -161,6 +167,8 @@ private module FabricV2 { override DataFlow::Node getCommand() { result = [this.getArg(0), this.getArgByName("command")] } + + override predicate isShellInterpreted(DataFlow::Node arg) { arg = this.getCommand() } } // ------------------------------------------------------------------------- @@ -243,6 +251,8 @@ private module FabricV2 { override DataFlow::Node getCommand() { result = [this.getArg(0), this.getArgByName("command")] } + + override predicate isShellInterpreted(DataFlow::Node arg) { arg = this.getCommand() } } /** diff --git a/python/ql/lib/semmle/python/frameworks/Invoke.qll b/python/ql/lib/semmle/python/frameworks/Invoke.qll index b1ceb078907..30637610ac9 100644 --- a/python/ql/lib/semmle/python/frameworks/Invoke.qll +++ b/python/ql/lib/semmle/python/frameworks/Invoke.qll @@ -81,5 +81,7 @@ private module Invoke { override DataFlow::Node getCommand() { result in [this.getArg(0), this.getArgByName("command")] } + + override predicate isShellInterpreted(DataFlow::Node arg) { arg = this.getCommand() } } } diff --git a/python/ql/lib/semmle/python/frameworks/Stdlib.qll b/python/ql/lib/semmle/python/frameworks/Stdlib.qll index 3fce979c147..d3512aca668 100644 --- a/python/ql/lib/semmle/python/frameworks/Stdlib.qll +++ b/python/ql/lib/semmle/python/frameworks/Stdlib.qll @@ -1060,7 +1060,11 @@ private module StdlibPrivate { private class OsSystemCall extends SystemCommandExecution::Range, DataFlow::CallCfgNode { OsSystemCall() { this = os().getMember("system").getACall() } - override DataFlow::Node getCommand() { result = this.getArg(0) } + override DataFlow::Node getCommand() { + result in [this.getArg(0), this.getArgByName("command")] + } + + override predicate isShellInterpreted(DataFlow::Node arg) { arg = this.getCommand() } } /** @@ -1071,7 +1075,7 @@ private module StdlibPrivate { * Although deprecated since version 2.6, they still work in 2.7. * See https://docs.python.org/2.7/library/os.html#os.popen2 */ - private class OsPopenCall extends SystemCommandExecution::Range, DataFlow::CallCfgNode { + private class OsPopenCall extends SystemCommandExecution::Range, API::CallNode { string name; OsPopenCall() { @@ -1085,6 +1089,8 @@ private module StdlibPrivate { not name = "popen" and result = this.getArgByName("cmd") } + + override predicate isShellInterpreted(DataFlow::Node arg) { arg = this.getCommand() } } /** @@ -1103,6 +1109,10 @@ private module StdlibPrivate { override DataFlow::Node getCommand() { result = this.getArg(0) } override DataFlow::Node getAPathArgument() { result = this.getCommand() } + + override predicate isShellInterpreted(DataFlow::Node arg) { + none() // this is a safe API. + } } /** @@ -1129,6 +1139,10 @@ private module StdlibPrivate { } override DataFlow::Node getAPathArgument() { result = this.getCommand() } + + override predicate isShellInterpreted(DataFlow::Node arg) { + none() // this is a safe API. + } } /** @@ -1142,6 +1156,10 @@ private module StdlibPrivate { override DataFlow::Node getCommand() { result in [this.getArg(0), this.getArgByName("path")] } override DataFlow::Node getAPathArgument() { result = this.getCommand() } + + override predicate isShellInterpreted(DataFlow::Node arg) { + none() // this is a safe API. + } } /** An additional taint step for calls to `os.path.join` */ @@ -1186,6 +1204,7 @@ private module StdlibPrivate { } private boolean get_shell_arg_value() { + // TODO: API-node this thing - with added tests for unsafe-shell-command-construction not exists(this.get_shell_arg()) and result = false or @@ -1239,6 +1258,11 @@ private module StdlibPrivate { ) ) } + + override predicate isShellInterpreted(DataFlow::Node arg) { + arg = this.get_executable_arg() and + this.get_shell_arg_value() = true + } } // --------------------------------------------------------------------------- @@ -1385,6 +1409,8 @@ private module StdlibPrivate { } override DataFlow::Node getCommand() { result in [this.getArg(0), this.getArgByName("cmd")] } + + override predicate isShellInterpreted(DataFlow::Node arg) { arg = this.getCommand() } } // --------------------------------------------------------------------------- @@ -1401,6 +1427,8 @@ private module StdlibPrivate { PlatformPopenCall() { this = platform().getMember("popen").getACall() } override DataFlow::Node getCommand() { result in [this.getArg(0), this.getArgByName("cmd")] } + + override predicate isShellInterpreted(DataFlow::Node arg) { arg = this.getCommand() } } // --------------------------------------------------------------------------- From 7fcc548665ba307f465767d31e168e54c5244010 Mon Sep 17 00:00:00 2001 From: erik-krogh Date: Tue, 31 Jan 2023 14:51:38 +0100 Subject: [PATCH 002/135] add `py/shell-command-constructed-from-input`, but without a source. It's a very direct port from Ruby, with only minor adjustments to fit the Python APIs --- ...ShellCommandConstructionCustomizations.qll | 158 ++++++++++++++++++ .../UnsafeShellCommandConstructionQuery.qll | 35 ++++ .../UnsafeShellCommandConstruction.qhelp | 73 ++++++++ .../CWE-078/UnsafeShellCommandConstruction.ql | 27 +++ .../unsafe-shell-command-construction.py | 4 + ...unsafe-shell-command-construction_fixed.py | 4 + 6 files changed, 301 insertions(+) create mode 100644 python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll create mode 100644 python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionQuery.qll create mode 100644 python/ql/src/Security/CWE-078/UnsafeShellCommandConstruction.qhelp create mode 100644 python/ql/src/Security/CWE-078/UnsafeShellCommandConstruction.ql create mode 100644 python/ql/src/Security/CWE-078/examples/unsafe-shell-command-construction.py create mode 100644 python/ql/src/Security/CWE-078/examples/unsafe-shell-command-construction_fixed.py diff --git a/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll b/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll new file mode 100644 index 00000000000..6cf1a765c1f --- /dev/null +++ b/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll @@ -0,0 +1,158 @@ +/** + * Provides default sources, sinks and sanitizers for reasoning about + * shell command constructed from library input vulnerabilities, as + * well as extension points for adding your own. + */ + +private import python +import semmle.python.dataflow.new.DataFlow +import semmle.python.dataflow.new.TaintTracking +import CommandInjectionCustomizations::CommandInjection as CommandInjection +private import semmle.python.Concepts as Concepts + +/** + * Module containing sources, sinks, and sanitizers for shell command constructed from library input. + */ +module UnsafeShellCommandConstruction { + /** A source for shell command constructed from library input vulnerabilities. */ + abstract class Source extends DataFlow::Node { } + + /** An input parameter to a gem seen as a source. */ + private class LibraryInputAsSource extends Source instanceof DataFlow::ParameterNode { + LibraryInputAsSource() { + none() // TODO: Do something here, put it in a shared library. + } + } + + /** A sink for shell command constructed from library input vulnerabilities. */ + abstract class Sink extends DataFlow::Node { + /** Gets a description of how the string in this sink was constructed. */ + abstract string describe(); + + /** Gets the dataflow node where the string is constructed. */ + DataFlow::Node getStringConstruction() { result = this } + + /** Gets the dataflow node that executed the string as a shell command. */ + abstract DataFlow::Node getCommandExecution(); + } + + /** Holds if the string constructed at `source` is executed at `shellExec` */ + predicate isUsedAsShellCommand(DataFlow::Node source, Concepts::SystemCommandExecution shellExec) { + source = backtrackShellExec(TypeTracker::TypeBackTracker::end(), shellExec) + } + + import semmle.python.dataflow.new.TypeTracker as TypeTracker + + private DataFlow::LocalSourceNode backtrackShellExec( + TypeTracker::TypeBackTracker t, Concepts::SystemCommandExecution shellExec + ) { + t.start() and + result = any(DataFlow::Node n | shellExec.isShellInterpreted(n)).getALocalSource() + or + exists(TypeTracker::TypeBackTracker t2 | + result = backtrackShellExec(t2, shellExec).backtrack(t2, t) + ) + } + + /** + * A string constructed from a string-literal (e.g. `f'foo {sink}'`), + * where the resulting string ends up being executed as a shell command. + */ + class StringInterpolationAsSink extends Sink { + // TODO: Add test. + Concepts::SystemCommandExecution s; + Fstring fstring; + + StringInterpolationAsSink() { + isUsedAsShellCommand(any(DataFlow::Node n | n.asExpr() = fstring), s) and + this.asExpr() = fstring.getASubExpression() + } + + override string describe() { result = "string construction" } + + override DataFlow::Node getCommandExecution() { result = s } + + override DataFlow::Node getStringConstruction() { result.asExpr() = fstring } + } + + /** + * A component of a string-concatenation (e.g. `"foo " + sink`), + * where the resulting string ends up being executed as a shell command. + */ + class StringConcatAsSink extends Sink { + // TODO: Add test. + Concepts::SystemCommandExecution s; + BinaryExpr add; + + StringConcatAsSink() { + add.getOp() instanceof Add and + isUsedAsShellCommand(any(DataFlow::Node n | n.asExpr() = add), s) and + this.asExpr() = add.getASubExpression() + } + + override DataFlow::Node getCommandExecution() { result = s } + + override string describe() { result = "string concatenation" } + + override DataFlow::Node getStringConstruction() { result.asExpr() = add } + } + + /** + * A string constructed using a `.join(" ")` call, where the resulting string ends up being executed as a shell command. + */ + class ArrayJoin extends Sink { + // TODO: Add test. + Concepts::SystemCommandExecution s; + DataFlow::MethodCallNode call; + + ArrayJoin() { + call.getMethodName() = "join" and + unique( | | call.getArg(_)).asExpr().(Str).getText() = " " and + isUsedAsShellCommand(call, s) and + ( + this = call.getObject() and + not call.getObject().asExpr() instanceof List + or + this.asExpr() = call.getObject().asExpr().(List).getASubExpression() + ) + } + + override string describe() { result = "array" } + + override DataFlow::Node getCommandExecution() { result = s } + + override DataFlow::Node getStringConstruction() { result = call } + } + + /** + * A string constructed from a format call, + * where the resulting string ends up being executed as a shell command. + * Either a call to `.format(..)` or a string-interpolation with a `%` operator. + */ + class TaintedFormatStringAsSink extends Sink { + // TODO: Test + Concepts::SystemCommandExecution s; + DataFlow::Node formatCall; + + TaintedFormatStringAsSink() { + ( + formatCall.asExpr().(BinaryExpr).getOp() instanceof Mod and + this.asExpr() = formatCall.asExpr().(BinaryExpr).getASubExpression() + or + formatCall.(DataFlow::MethodCallNode).getMethodName() = "format" and + this = + [ + formatCall.(DataFlow::MethodCallNode).getArg(_), + formatCall.(DataFlow::MethodCallNode).getObject() + ] + ) and + isUsedAsShellCommand(formatCall, s) + } + + override string describe() { result = "formatted string" } + + override DataFlow::Node getCommandExecution() { result = s } + + override DataFlow::Node getStringConstruction() { result = formatCall } + } +} diff --git a/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionQuery.qll b/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionQuery.qll new file mode 100644 index 00000000000..6fc567289e7 --- /dev/null +++ b/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionQuery.qll @@ -0,0 +1,35 @@ +/** + * Provides a taint tracking configuration for reasoning about shell command + * constructed from library input vulnerabilities + * + * Note, for performance reasons: only import this file if `Configuration` is needed, + * otherwise `UnsafeShellCommandConstructionCustomizations` should be imported instead. + */ + +import python +import UnsafeShellCommandConstructionCustomizations::UnsafeShellCommandConstruction +import semmle.python.dataflow.new.DataFlow +import semmle.python.dataflow.new.TaintTracking +import CommandInjectionCustomizations::CommandInjection as CommandInjection +import semmle.python.dataflow.new.BarrierGuards + +/** + * A taint-tracking configuration for detecting shell command constructed from library input vulnerabilities. + */ +class Configuration extends TaintTracking::Configuration { + Configuration() { this = "UnsafeShellCommandConstruction" } + + override predicate isSource(DataFlow::Node source) { source instanceof Source } + + override predicate isSink(DataFlow::Node sink) { sink instanceof Sink } + + override predicate isSanitizer(DataFlow::Node node) { + node instanceof CommandInjection::Sanitizer or // using all sanitizers from `rb/command-injection` + node instanceof StringConstCompareBarrier + } + + // override to require the path doesn't have unmatched return steps + override DataFlow::FlowFeature getAFeature() { + result instanceof DataFlow::FeatureHasSourceCallContext + } +} diff --git a/python/ql/src/Security/CWE-078/UnsafeShellCommandConstruction.qhelp b/python/ql/src/Security/CWE-078/UnsafeShellCommandConstruction.qhelp new file mode 100644 index 00000000000..3176d5c035d --- /dev/null +++ b/python/ql/src/Security/CWE-078/UnsafeShellCommandConstruction.qhelp @@ -0,0 +1,73 @@ + + + +

+ Dynamically constructing a shell command with inputs from exported + functions may inadvertently change the meaning of the shell command. + + Clients using the exported function may use inputs containing + characters that the shell interprets in a special way, for instance + quotes and spaces. + + This can result in the shell command misbehaving, or even + allowing a malicious user to execute arbitrary commands on the system. +

+ + +
+ + +

+ If possible, provide the dynamic arguments to the shell as an array + to APIs such as system(..) to avoid interpretation by the shell. +

+ +

+ Alternatively, if the shell command must be constructed + dynamically, then add code to ensure that special characters + do not alter the shell command unexpectedly. +

+ +
+ + +

+ The following example shows a dynamically constructed shell + command that downloads a file from a remote URL. +

+ + + +

+ The shell command will, however, fail to work as intended if the + input contains spaces or other special characters interpreted in a + special way by the shell. +

+ +

+ Even worse, a client might pass in user-controlled + data, not knowing that the input is interpreted as a shell command. + This could allow a malicious user to provide the input http://example.org; cat /etc/passwd + in order to execute the command cat /etc/passwd. +

+ +

+ To avoid such potentially catastrophic behaviors, provide the + input from exported functions as an argument that does not + get interpreted by a shell: +

+ + + +
+ + +
  • + OWASP: + Command Injection. +
  • + +
    +
    diff --git a/python/ql/src/Security/CWE-078/UnsafeShellCommandConstruction.ql b/python/ql/src/Security/CWE-078/UnsafeShellCommandConstruction.ql new file mode 100644 index 00000000000..d22ee170f3a --- /dev/null +++ b/python/ql/src/Security/CWE-078/UnsafeShellCommandConstruction.ql @@ -0,0 +1,27 @@ +/** + * @name Unsafe shell command constructed from library input + * @description Using externally controlled strings in a command line may allow a malicious + * user to change the meaning of the command. + * @kind path-problem + * @problem.severity error + * @security-severity 6.3 + * @precision high + * @id py/shell-command-constructed-from-input + * @tags correctness + * security + * external/cwe/cwe-078 + * external/cwe/cwe-088 + * external/cwe/cwe-073 + */ + +import python +import semmle.python.security.dataflow.UnsafeShellCommandConstructionQuery +import DataFlow::PathGraph + +from Configuration config, DataFlow::PathNode source, DataFlow::PathNode sink, Sink sinkNode +where + config.hasFlowPath(source, sink) and + sinkNode = sink.getNode() +select sinkNode.getStringConstruction(), source, sink, + "This " + sinkNode.describe() + " which depends on $@ is later used in a $@.", source.getNode(), + "library input", sinkNode.getCommandExecution(), "shell command" diff --git a/python/ql/src/Security/CWE-078/examples/unsafe-shell-command-construction.py b/python/ql/src/Security/CWE-078/examples/unsafe-shell-command-construction.py new file mode 100644 index 00000000000..644af24938d --- /dev/null +++ b/python/ql/src/Security/CWE-078/examples/unsafe-shell-command-construction.py @@ -0,0 +1,4 @@ +import os + +def download (path): + os.system("wget " + path) # NOT OK diff --git a/python/ql/src/Security/CWE-078/examples/unsafe-shell-command-construction_fixed.py b/python/ql/src/Security/CWE-078/examples/unsafe-shell-command-construction_fixed.py new file mode 100644 index 00000000000..d62b3478bf1 --- /dev/null +++ b/python/ql/src/Security/CWE-078/examples/unsafe-shell-command-construction_fixed.py @@ -0,0 +1,4 @@ +import subprocess + +def download (path): + subprocess.run(["wget", path]) # OK From 47a06d282433fc16c4fb88a42e2893cacca770ca Mon Sep 17 00:00:00 2001 From: erik-krogh Date: Wed, 1 Feb 2023 10:32:02 +0100 Subject: [PATCH 003/135] add library inputs as a source, and get minimal test to work --- python/ql/lib/semmle/python/Frameworks.qll | 1 + .../semmle/python/frameworks/Setuptools.qll | 71 +++++++++++++++++++ ...ShellCommandConstructionCustomizations.qll | 9 +-- .../DataflowQueryTest.expected | 2 + .../DataflowQueryTest.ql | 3 + .../UnsafeShellCommandConstruction.expected | 8 +++ .../UnsafeShellCommandConstruction.qlref | 1 + .../options | 1 + .../setup.py | 0 .../src/__init__.py | 0 .../src/unsafe_shell_test.py | 5 ++ 11 files changed, 97 insertions(+), 4 deletions(-) create mode 100644 python/ql/lib/semmle/python/frameworks/Setuptools.qll create mode 100644 python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/DataflowQueryTest.expected create mode 100644 python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/DataflowQueryTest.ql create mode 100644 python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected create mode 100644 python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.qlref create mode 100644 python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/options create mode 100644 python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/setup.py create mode 100644 python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/__init__.py create mode 100644 python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py diff --git a/python/ql/lib/semmle/python/Frameworks.qll b/python/ql/lib/semmle/python/Frameworks.qll index eab33a03ed7..d9592fcafb3 100644 --- a/python/ql/lib/semmle/python/Frameworks.qll +++ b/python/ql/lib/semmle/python/Frameworks.qll @@ -51,6 +51,7 @@ private import semmle.python.frameworks.Simplejson private import semmle.python.frameworks.SqlAlchemy private import semmle.python.frameworks.Starlette private import semmle.python.frameworks.Stdlib +private import semmle.python.frameworks.Setuptools private import semmle.python.frameworks.Toml private import semmle.python.frameworks.Tornado private import semmle.python.frameworks.Twisted diff --git a/python/ql/lib/semmle/python/frameworks/Setuptools.qll b/python/ql/lib/semmle/python/frameworks/Setuptools.qll new file mode 100644 index 00000000000..32509cfccec --- /dev/null +++ b/python/ql/lib/semmle/python/frameworks/Setuptools.qll @@ -0,0 +1,71 @@ +/** + * Provides classes modeling package setup as defined by `setuptools`. + */ + +private import python +private import semmle.python.dataflow.new.DataFlow + +/** Provides models for the use of `setuptools` in setup scripts, and the APIs exported by the library defined using `setuptools`. */ +module Setuptools { + /** + * Gets a file that sets up a package using `setuptools` (or the deprecated `distutils`). + */ + private File setupFile() { + // all of these might not be extracted, but the support is ready for when they are + result.getBaseName() = ["setup.py", "setup.cfg", "pyproject.toml"] + } + + /** + * Gets a file or folder that is exported by a library. + */ + private Container getALibraryExportedContainer() { + result = setupFile().getParent() + or + // child of a library exported container + result = getALibraryExportedContainer().getAChildContainer() and + ( + // either any file + not result instanceof Folder + or + // or a folder with an __init__.py file + exists(result.(Folder).getFile("__init__.py")) + ) and + // that is not a test folder + not result.(Folder).getBaseName() = ["test", "tests", "testing"] + } + + /** + * Gets an AST node that is exported by a library. + */ + private AstNode getAnExportedLibraryFeature() { + result.(Module).getFile() = getALibraryExportedContainer() + or + result = getAnExportedLibraryFeature().(Module).getAStmt() + or + result = getAnExportedLibraryFeature().(ClassDef).getDefinedClass().getAMethod() + or + result = getAnExportedLibraryFeature().(ClassDef).getDefinedClass().getInitMethod() + or + result = getAnExportedLibraryFeature().(FunctionDef).getDefinedFunction() + } + + /** + * Gets a public function (or __init__) that is exported by a library. + */ + private Function getAnExportedFunction() { + result = getAnExportedLibraryFeature() and + ( + result.isPublic() + or + result.isInitMethod() + ) + } + + /** + * Gets a parameter to a public function that is exported by a library. + */ + DataFlow::ParameterNode getALibraryInput() { + result.getParameter() = getAnExportedFunction().getAnArg() and + not result.getParameter().isSelf() + } +} diff --git a/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll b/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll index 6cf1a765c1f..ac06d12edcd 100644 --- a/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll +++ b/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll @@ -17,15 +17,17 @@ module UnsafeShellCommandConstruction { /** A source for shell command constructed from library input vulnerabilities. */ abstract class Source extends DataFlow::Node { } + private import semmle.python.frameworks.Setuptools + /** An input parameter to a gem seen as a source. */ private class LibraryInputAsSource extends Source instanceof DataFlow::ParameterNode { - LibraryInputAsSource() { - none() // TODO: Do something here, put it in a shared library. - } + LibraryInputAsSource() { this = Setuptools::getALibraryInput() } } /** A sink for shell command constructed from library input vulnerabilities. */ abstract class Sink extends DataFlow::Node { + Sink() { not this.asExpr() instanceof StrConst } // filter out string constants, makes testing easier + /** Gets a description of how the string in this sink was constructed. */ abstract string describe(); @@ -80,7 +82,6 @@ module UnsafeShellCommandConstruction { * where the resulting string ends up being executed as a shell command. */ class StringConcatAsSink extends Sink { - // TODO: Add test. Concepts::SystemCommandExecution s; BinaryExpr add; diff --git a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/DataflowQueryTest.expected b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/DataflowQueryTest.expected new file mode 100644 index 00000000000..3875da4e143 --- /dev/null +++ b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/DataflowQueryTest.expected @@ -0,0 +1,2 @@ +missingAnnotationOnSink +failures diff --git a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/DataflowQueryTest.ql b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/DataflowQueryTest.ql new file mode 100644 index 00000000000..f9a934e1794 --- /dev/null +++ b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/DataflowQueryTest.ql @@ -0,0 +1,3 @@ +import python +import experimental.dataflow.TestUtil.DataflowQueryTest +import semmle.python.security.dataflow.UnsafeShellCommandConstructionQuery diff --git a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected new file mode 100644 index 00000000000..fbb4dc0af1b --- /dev/null +++ b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected @@ -0,0 +1,8 @@ +edges +| src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:5:25:5:28 | ControlFlowNode for name | +nodes +| src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | +| src/unsafe_shell_test.py:5:25:5:28 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | +subpaths +#select +| src/unsafe_shell_test.py:5:15:5:28 | ControlFlowNode for BinaryExpr | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:5:25:5:28 | ControlFlowNode for name | This string concatenation which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:5:5:5:29 | ControlFlowNode for Attribute() | shell command | diff --git a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.qlref b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.qlref new file mode 100644 index 00000000000..fdc01b9ecbf --- /dev/null +++ b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.qlref @@ -0,0 +1 @@ +Security/CWE-078/UnsafeShellCommandConstruction.ql diff --git a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/options b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/options new file mode 100644 index 00000000000..9ec98787409 --- /dev/null +++ b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/options @@ -0,0 +1 @@ +semmle-extractor-options: --lang=3 --max-import-depth=0 -r src diff --git a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/setup.py b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/setup.py new file mode 100644 index 00000000000..e69de29bb2d diff --git a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/__init__.py b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/__init__.py new file mode 100644 index 00000000000..e69de29bb2d diff --git a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py new file mode 100644 index 00000000000..eae8ca34a05 --- /dev/null +++ b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py @@ -0,0 +1,5 @@ +import os +import subprocess + +def unsafe_shell_one(name): + os.system("ping " + name) # $result=BAD From 5bddfc0d79a2c98b7071d50a41f6ed475e0fddc3 Mon Sep 17 00:00:00 2001 From: erik-krogh Date: Wed, 1 Feb 2023 23:05:44 +0100 Subject: [PATCH 004/135] add test for f-strings as sink --- .../dataflow/UnsafeShellCommandConstructionCustomizations.qll | 1 - .../UnsafeShellCommandConstruction.expected | 3 +++ .../src/unsafe_shell_test.py | 3 +++ 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll b/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll index ac06d12edcd..fbea50dc536 100644 --- a/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll +++ b/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll @@ -61,7 +61,6 @@ module UnsafeShellCommandConstruction { * where the resulting string ends up being executed as a shell command. */ class StringInterpolationAsSink extends Sink { - // TODO: Add test. Concepts::SystemCommandExecution s; Fstring fstring; diff --git a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected index fbb4dc0af1b..6b89266b7ea 100644 --- a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected +++ b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected @@ -1,8 +1,11 @@ edges | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:5:25:5:28 | ControlFlowNode for name | +| src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:8:23:8:26 | ControlFlowNode for name | nodes | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | | src/unsafe_shell_test.py:5:25:5:28 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | +| src/unsafe_shell_test.py:8:23:8:26 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | subpaths #select | src/unsafe_shell_test.py:5:15:5:28 | ControlFlowNode for BinaryExpr | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:5:25:5:28 | ControlFlowNode for name | This string concatenation which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:5:5:5:29 | ControlFlowNode for Attribute() | shell command | +| src/unsafe_shell_test.py:8:15:8:28 | ControlFlowNode for Fstring | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:8:23:8:26 | ControlFlowNode for name | This string construction which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:8:5:8:29 | ControlFlowNode for Attribute() | shell command | diff --git a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py index eae8ca34a05..f541b0da99c 100644 --- a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py +++ b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py @@ -3,3 +3,6 @@ import subprocess def unsafe_shell_one(name): os.system("ping " + name) # $result=BAD + + # f-strings + os.system(f"ping {name}") # $result=BAD From 33c506d7feccfd81b2c4938e4c92db7122c3dc39 Mon Sep 17 00:00:00 2001 From: erik-krogh Date: Wed, 1 Feb 2023 23:08:57 +0100 Subject: [PATCH 005/135] add minimal test for Array join as a sink, and learn that the order is flipped compared to JS. Thanks Copilot! --- .../UnsafeShellCommandConstructionCustomizations.qll | 7 +++---- .../UnsafeShellCommandConstruction.expected | 3 +++ .../src/unsafe_shell_test.py | 3 +++ 3 files changed, 9 insertions(+), 4 deletions(-) diff --git a/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll b/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll index fbea50dc536..883c2db408b 100644 --- a/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll +++ b/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll @@ -101,7 +101,6 @@ module UnsafeShellCommandConstruction { * A string constructed using a `.join(" ")` call, where the resulting string ends up being executed as a shell command. */ class ArrayJoin extends Sink { - // TODO: Add test. Concepts::SystemCommandExecution s; DataFlow::MethodCallNode call; @@ -110,10 +109,10 @@ module UnsafeShellCommandConstruction { unique( | | call.getArg(_)).asExpr().(Str).getText() = " " and isUsedAsShellCommand(call, s) and ( - this = call.getObject() and - not call.getObject().asExpr() instanceof List + this = call.getArg(0) and + not call.getArg(0).asExpr() instanceof List or - this.asExpr() = call.getObject().asExpr().(List).getASubExpression() + this.asExpr() = call.getArg(0).asExpr().(List).getASubExpression() ) } diff --git a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected index 6b89266b7ea..c81a17adf28 100644 --- a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected +++ b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected @@ -1,11 +1,14 @@ edges | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:5:25:5:28 | ControlFlowNode for name | | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:8:23:8:26 | ControlFlowNode for name | +| src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:11:25:11:38 | ControlFlowNode for Attribute() | nodes | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | | src/unsafe_shell_test.py:5:25:5:28 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | | src/unsafe_shell_test.py:8:23:8:26 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | +| src/unsafe_shell_test.py:11:25:11:38 | ControlFlowNode for Attribute() | semmle.label | ControlFlowNode for Attribute() | subpaths #select | src/unsafe_shell_test.py:5:15:5:28 | ControlFlowNode for BinaryExpr | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:5:25:5:28 | ControlFlowNode for name | This string concatenation which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:5:5:5:29 | ControlFlowNode for Attribute() | shell command | | src/unsafe_shell_test.py:8:15:8:28 | ControlFlowNode for Fstring | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:8:23:8:26 | ControlFlowNode for name | This string construction which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:8:5:8:29 | ControlFlowNode for Attribute() | shell command | +| src/unsafe_shell_test.py:11:15:11:38 | ControlFlowNode for BinaryExpr | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:11:25:11:38 | ControlFlowNode for Attribute() | This string concatenation which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:11:5:11:39 | ControlFlowNode for Attribute() | shell command | diff --git a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py index f541b0da99c..73ba9a55939 100644 --- a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py +++ b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py @@ -6,3 +6,6 @@ def unsafe_shell_one(name): # f-strings os.system(f"ping {name}") # $result=BAD + + # array.join + os.system("ping " + " ".join(name)) # $result=BAD From 6bbc4f4a482dac5ea34bfcfc9413b1cb3b9c5f93 Mon Sep 17 00:00:00 2001 From: erik-krogh Date: Wed, 1 Feb 2023 23:09:53 +0100 Subject: [PATCH 006/135] add more tests --- .../UnsafeShellCommandConstructionCustomizations.qll | 1 - .../UnsafeShellCommandConstruction.expected | 11 +++++++++++ .../src/unsafe_shell_test.py | 11 +++++++++++ 3 files changed, 22 insertions(+), 1 deletion(-) diff --git a/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll b/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll index 883c2db408b..2012ec0c552 100644 --- a/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll +++ b/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll @@ -129,7 +129,6 @@ module UnsafeShellCommandConstruction { * Either a call to `.format(..)` or a string-interpolation with a `%` operator. */ class TaintedFormatStringAsSink extends Sink { - // TODO: Test Concepts::SystemCommandExecution s; DataFlow::Node formatCall; diff --git a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected index c81a17adf28..d2efe2825ba 100644 --- a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected +++ b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected @@ -2,13 +2,24 @@ edges | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:5:25:5:28 | ControlFlowNode for name | | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:8:23:8:26 | ControlFlowNode for name | | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:11:25:11:38 | ControlFlowNode for Attribute() | +| src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:14:34:14:39 | ControlFlowNode for List | +| src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:17:32:17:35 | ControlFlowNode for name | +| src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:20:27:20:30 | ControlFlowNode for name | +| src/unsafe_shell_test.py:14:34:14:39 | ControlFlowNode for List | src/unsafe_shell_test.py:14:25:14:40 | ControlFlowNode for Attribute() | nodes | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | | src/unsafe_shell_test.py:5:25:5:28 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | | src/unsafe_shell_test.py:8:23:8:26 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | | src/unsafe_shell_test.py:11:25:11:38 | ControlFlowNode for Attribute() | semmle.label | ControlFlowNode for Attribute() | +| src/unsafe_shell_test.py:14:25:14:40 | ControlFlowNode for Attribute() | semmle.label | ControlFlowNode for Attribute() | +| src/unsafe_shell_test.py:14:34:14:39 | ControlFlowNode for List | semmle.label | ControlFlowNode for List | +| src/unsafe_shell_test.py:17:32:17:35 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | +| src/unsafe_shell_test.py:20:27:20:30 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | subpaths #select | src/unsafe_shell_test.py:5:15:5:28 | ControlFlowNode for BinaryExpr | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:5:25:5:28 | ControlFlowNode for name | This string concatenation which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:5:5:5:29 | ControlFlowNode for Attribute() | shell command | | src/unsafe_shell_test.py:8:15:8:28 | ControlFlowNode for Fstring | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:8:23:8:26 | ControlFlowNode for name | This string construction which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:8:5:8:29 | ControlFlowNode for Attribute() | shell command | | src/unsafe_shell_test.py:11:15:11:38 | ControlFlowNode for BinaryExpr | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:11:25:11:38 | ControlFlowNode for Attribute() | This string concatenation which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:11:5:11:39 | ControlFlowNode for Attribute() | shell command | +| src/unsafe_shell_test.py:14:15:14:40 | ControlFlowNode for BinaryExpr | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:14:25:14:40 | ControlFlowNode for Attribute() | This string concatenation which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:14:5:14:41 | ControlFlowNode for Attribute() | shell command | +| src/unsafe_shell_test.py:17:15:17:36 | ControlFlowNode for Attribute() | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:17:32:17:35 | ControlFlowNode for name | This formatted string which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:17:5:17:37 | ControlFlowNode for Attribute() | shell command | +| src/unsafe_shell_test.py:20:15:20:30 | ControlFlowNode for BinaryExpr | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:20:27:20:30 | ControlFlowNode for name | This formatted string which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:20:5:20:31 | ControlFlowNode for Attribute() | shell command | diff --git a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py index 73ba9a55939..b45e81c6513 100644 --- a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py +++ b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py @@ -9,3 +9,14 @@ def unsafe_shell_one(name): # array.join os.system("ping " + " ".join(name)) # $result=BAD + + # array.join, with a list + os.system("ping " + " ".join([name])) # $result=BAD + + # format, using .format + os.system("ping {}".format(name)) # $result=BAD + + # format, using % + os.system("ping %s" % name) # $result=BAD + + os.system(name) # OK - seems intentional. From 0a2c7d062cf18ed5c08e5acffb4013119826831f Mon Sep 17 00:00:00 2001 From: erik-krogh Date: Thu, 2 Feb 2023 10:34:32 +0100 Subject: [PATCH 007/135] add Fabric test, and add tracking of the shell flag in Fabric --- python/ql/lib/semmle/python/frameworks/Fabric.qll | 7 +++++-- .../UnsafeShellCommandConstruction.expected | 4 ++++ .../src/unsafe_shell_test.py | 12 ++++++++++++ 3 files changed, 21 insertions(+), 2 deletions(-) diff --git a/python/ql/lib/semmle/python/frameworks/Fabric.qll b/python/ql/lib/semmle/python/frameworks/Fabric.qll index 31511dbeaf4..21302af2e0a 100644 --- a/python/ql/lib/semmle/python/frameworks/Fabric.qll +++ b/python/ql/lib/semmle/python/frameworks/Fabric.qll @@ -53,8 +53,11 @@ private module FabricV1 { override predicate isShellInterpreted(DataFlow::Node arg) { arg = this.getCommand() and // defaults to running in a shell - not this.getParameter(1, "shell").asSink().asExpr().(ImmutableLiteral).booleanValue() = - false // TODO: Test this in unsafe-shell-command-construction - and add tracking as a separate step. + not this.getParameter(1, "shell") + .getAValueReachingSink() + .asExpr() + .(ImmutableLiteral) + .booleanValue() = false } } } diff --git a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected index d2efe2825ba..208f72925dd 100644 --- a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected +++ b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected @@ -6,6 +6,7 @@ edges | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:17:32:17:35 | ControlFlowNode for name | | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:20:27:20:30 | ControlFlowNode for name | | src/unsafe_shell_test.py:14:34:14:39 | ControlFlowNode for List | src/unsafe_shell_test.py:14:25:14:40 | ControlFlowNode for Attribute() | +| src/unsafe_shell_test.py:26:20:26:23 | ControlFlowNode for name | src/unsafe_shell_test.py:29:30:29:33 | ControlFlowNode for name | nodes | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | | src/unsafe_shell_test.py:5:25:5:28 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | @@ -15,6 +16,8 @@ nodes | src/unsafe_shell_test.py:14:34:14:39 | ControlFlowNode for List | semmle.label | ControlFlowNode for List | | src/unsafe_shell_test.py:17:32:17:35 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | | src/unsafe_shell_test.py:20:27:20:30 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | +| src/unsafe_shell_test.py:26:20:26:23 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | +| src/unsafe_shell_test.py:29:30:29:33 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | subpaths #select | src/unsafe_shell_test.py:5:15:5:28 | ControlFlowNode for BinaryExpr | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:5:25:5:28 | ControlFlowNode for name | This string concatenation which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:5:5:5:29 | ControlFlowNode for Attribute() | shell command | @@ -23,3 +26,4 @@ subpaths | src/unsafe_shell_test.py:14:15:14:40 | ControlFlowNode for BinaryExpr | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:14:25:14:40 | ControlFlowNode for Attribute() | This string concatenation which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:14:5:14:41 | ControlFlowNode for Attribute() | shell command | | src/unsafe_shell_test.py:17:15:17:36 | ControlFlowNode for Attribute() | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:17:32:17:35 | ControlFlowNode for name | This formatted string which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:17:5:17:37 | ControlFlowNode for Attribute() | shell command | | src/unsafe_shell_test.py:20:15:20:30 | ControlFlowNode for BinaryExpr | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:20:27:20:30 | ControlFlowNode for name | This formatted string which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:20:5:20:31 | ControlFlowNode for Attribute() | shell command | +| src/unsafe_shell_test.py:29:20:29:33 | ControlFlowNode for BinaryExpr | src/unsafe_shell_test.py:26:20:26:23 | ControlFlowNode for name | src/unsafe_shell_test.py:29:30:29:33 | ControlFlowNode for name | This string concatenation which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:26:20:26:23 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:29:5:29:46 | ControlFlowNode for Attribute() | shell command | diff --git a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py index b45e81c6513..8954758bce3 100644 --- a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py +++ b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py @@ -20,3 +20,15 @@ def unsafe_shell_one(name): os.system("ping %s" % name) # $result=BAD os.system(name) # OK - seems intentional. + +import fabric + +def facbric_stuff (name): + fabric.api.run("ping " + name, shell=False) # OK + + fabric.api.run("ping " + name, shell=True) # $result=BAD + + def indirect(flag): + fabric.api.run("ping " + name, shell=flag) # OK + + indirect(False) From bce83bfc4ecc960a0a46a20a7050cd90d270b96a Mon Sep 17 00:00:00 2001 From: erik-krogh Date: Thu, 2 Feb 2023 11:05:29 +0100 Subject: [PATCH 008/135] add failing test for indirectly setting the shell=true flag for subprocess.run --- python/ql/lib/semmle/python/frameworks/Stdlib.qll | 2 +- .../UnsafeShellCommandConstruction.expected | 4 ++++ .../src/unsafe_shell_test.py | 10 ++++++++++ 3 files changed, 15 insertions(+), 1 deletion(-) diff --git a/python/ql/lib/semmle/python/frameworks/Stdlib.qll b/python/ql/lib/semmle/python/frameworks/Stdlib.qll index d3512aca668..8e18e0611b8 100644 --- a/python/ql/lib/semmle/python/frameworks/Stdlib.qll +++ b/python/ql/lib/semmle/python/frameworks/Stdlib.qll @@ -1260,7 +1260,7 @@ private module StdlibPrivate { } override predicate isShellInterpreted(DataFlow::Node arg) { - arg = this.get_executable_arg() and + arg = [this.get_executable_arg(), this.get_args_arg()] and this.get_shell_arg_value() = true } } diff --git a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected index 208f72925dd..951c08e5d62 100644 --- a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected +++ b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected @@ -7,6 +7,7 @@ edges | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:20:27:20:30 | ControlFlowNode for name | | src/unsafe_shell_test.py:14:34:14:39 | ControlFlowNode for List | src/unsafe_shell_test.py:14:25:14:40 | ControlFlowNode for Attribute() | | src/unsafe_shell_test.py:26:20:26:23 | ControlFlowNode for name | src/unsafe_shell_test.py:29:30:29:33 | ControlFlowNode for name | +| src/unsafe_shell_test.py:36:22:36:25 | ControlFlowNode for name | src/unsafe_shell_test.py:39:30:39:33 | ControlFlowNode for name | nodes | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | | src/unsafe_shell_test.py:5:25:5:28 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | @@ -18,6 +19,8 @@ nodes | src/unsafe_shell_test.py:20:27:20:30 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | | src/unsafe_shell_test.py:26:20:26:23 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | | src/unsafe_shell_test.py:29:30:29:33 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | +| src/unsafe_shell_test.py:36:22:36:25 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | +| src/unsafe_shell_test.py:39:30:39:33 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | subpaths #select | src/unsafe_shell_test.py:5:15:5:28 | ControlFlowNode for BinaryExpr | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:5:25:5:28 | ControlFlowNode for name | This string concatenation which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:5:5:5:29 | ControlFlowNode for Attribute() | shell command | @@ -27,3 +30,4 @@ subpaths | src/unsafe_shell_test.py:17:15:17:36 | ControlFlowNode for Attribute() | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:17:32:17:35 | ControlFlowNode for name | This formatted string which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:17:5:17:37 | ControlFlowNode for Attribute() | shell command | | src/unsafe_shell_test.py:20:15:20:30 | ControlFlowNode for BinaryExpr | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:20:27:20:30 | ControlFlowNode for name | This formatted string which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:20:5:20:31 | ControlFlowNode for Attribute() | shell command | | src/unsafe_shell_test.py:29:20:29:33 | ControlFlowNode for BinaryExpr | src/unsafe_shell_test.py:26:20:26:23 | ControlFlowNode for name | src/unsafe_shell_test.py:29:30:29:33 | ControlFlowNode for name | This string concatenation which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:26:20:26:23 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:29:5:29:46 | ControlFlowNode for Attribute() | shell command | +| src/unsafe_shell_test.py:39:20:39:33 | ControlFlowNode for BinaryExpr | src/unsafe_shell_test.py:36:22:36:25 | ControlFlowNode for name | src/unsafe_shell_test.py:39:30:39:33 | ControlFlowNode for name | This string concatenation which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:36:22:36:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:39:5:39:46 | ControlFlowNode for Attribute() | shell command | diff --git a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py index 8954758bce3..65d87e5495e 100644 --- a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py +++ b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py @@ -32,3 +32,13 @@ def facbric_stuff (name): fabric.api.run("ping " + name, shell=flag) # OK indirect(False) + +def subprocess_flag (name): + subprocess.run("ping " + name, shell=False) # OK - and nonsensical + + subprocess.run("ping " + name, shell=True) # $result=BAD + + def indirect(flag): + subprocess.run("ping " + name, shell=flag) # $ MISSING: result=BAD + + indirect(True) \ No newline at end of file From d228cf0e7b3d8d8c8223d71f7d16b7b1e5651569 Mon Sep 17 00:00:00 2001 From: erik-krogh Date: Thu, 2 Feb 2023 11:23:27 +0100 Subject: [PATCH 009/135] use more API-nodes to model subprocess.run (and friends) --- .../lib/semmle/python/frameworks/Stdlib.qll | 41 +++++++------------ .../UnsafeShellCommandConstruction.expected | 7 ++++ .../src/unsafe_shell_test.py | 6 +-- 3 files changed, 25 insertions(+), 29 deletions(-) diff --git a/python/ql/lib/semmle/python/frameworks/Stdlib.qll b/python/ql/lib/semmle/python/frameworks/Stdlib.qll index 8e18e0611b8..c21987d9847 100644 --- a/python/ql/lib/semmle/python/frameworks/Stdlib.qll +++ b/python/ql/lib/semmle/python/frameworks/Stdlib.qll @@ -1185,7 +1185,7 @@ private module StdlibPrivate { * See https://docs.python.org/3.8/library/subprocess.html#subprocess.Popen * ref: https://docs.python.org/3/library/subprocess.html#legacy-shell-invocation-functions */ - private class SubprocessPopenCall extends SystemCommandExecution::Range, DataFlow::CallCfgNode { + private class SubprocessPopenCall extends SystemCommandExecution::Range, API::CallNode { SubprocessPopenCall() { exists(string name | name in [ @@ -1195,44 +1195,33 @@ private module StdlibPrivate { ) } - /** Gets the ControlFlowNode for the `args` argument, if any. */ - private DataFlow::Node get_args_arg() { result in [this.getArg(0), this.getArgByName("args")] } + /** Gets the API-node for the `args` argument, if any. */ + private API::Node get_args_arg() { result = this.getParameter(0, "args") } - /** Gets the ControlFlowNode for the `shell` argument, if any. */ - private DataFlow::Node get_shell_arg() { - result in [this.getArg(8), this.getArgByName("shell")] - } + /** Gets the API-node for the `shell` argument, if any. */ + private API::Node get_shell_arg() { result = this.getParameter(8, "shell") } private boolean get_shell_arg_value() { - // TODO: API-node this thing - with added tests for unsafe-shell-command-construction not exists(this.get_shell_arg()) and result = false or - exists(DataFlow::Node shell_arg | shell_arg = this.get_shell_arg() | - result = shell_arg.asCfgNode().getNode().(ImmutableLiteral).booleanValue() - or - // TODO: Track the "shell" argument to determine possible values - not shell_arg.asCfgNode().getNode() instanceof ImmutableLiteral and - ( - result = true - or - result = false - ) - ) + result = + this.get_shell_arg().getAValueReachingSink().asExpr().(ImmutableLiteral).booleanValue() + or + not this.get_shell_arg().getAValueReachingSink().asExpr() instanceof ImmutableLiteral and + result = [true, false] } - /** Gets the ControlFlowNode for the `executable` argument, if any. */ - private DataFlow::Node get_executable_arg() { - result in [this.getArg(2), this.getArgByName("executable")] - } + /** Gets the API-node for the `executable` argument, if any. */ + private API::Node get_executable_arg() { result = this.getParameter(2, "executable") } override DataFlow::Node getCommand() { // TODO: Track arguments ("args" and "shell") // TODO: Handle using `args=["sh", "-c", ]` - result = this.get_executable_arg() + result = this.get_executable_arg().asSink() or exists(DataFlow::Node arg_args, boolean shell | - arg_args = this.get_args_arg() and + arg_args = this.get_args_arg().asSink() and shell = this.get_shell_arg_value() | // When "executable" argument is set, and "shell" argument is `False`, the @@ -1260,7 +1249,7 @@ private module StdlibPrivate { } override predicate isShellInterpreted(DataFlow::Node arg) { - arg = [this.get_executable_arg(), this.get_args_arg()] and + arg = [this.get_executable_arg(), this.get_args_arg()].asSink() and this.get_shell_arg_value() = true } } diff --git a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected index 951c08e5d62..3378661f451 100644 --- a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected +++ b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected @@ -8,6 +8,9 @@ edges | src/unsafe_shell_test.py:14:34:14:39 | ControlFlowNode for List | src/unsafe_shell_test.py:14:25:14:40 | ControlFlowNode for Attribute() | | src/unsafe_shell_test.py:26:20:26:23 | ControlFlowNode for name | src/unsafe_shell_test.py:29:30:29:33 | ControlFlowNode for name | | src/unsafe_shell_test.py:36:22:36:25 | ControlFlowNode for name | src/unsafe_shell_test.py:39:30:39:33 | ControlFlowNode for name | +| src/unsafe_shell_test.py:36:22:36:25 | ControlFlowNode for name | src/unsafe_shell_test.py:44:20:44:23 | ControlFlowNode for name | +| src/unsafe_shell_test.py:41:24:41:24 | ControlFlowNode for x | src/unsafe_shell_test.py:42:34:42:34 | ControlFlowNode for x | +| src/unsafe_shell_test.py:44:20:44:23 | ControlFlowNode for name | src/unsafe_shell_test.py:41:24:41:24 | ControlFlowNode for x | nodes | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | | src/unsafe_shell_test.py:5:25:5:28 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | @@ -21,6 +24,9 @@ nodes | src/unsafe_shell_test.py:29:30:29:33 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | | src/unsafe_shell_test.py:36:22:36:25 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | | src/unsafe_shell_test.py:39:30:39:33 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | +| src/unsafe_shell_test.py:41:24:41:24 | ControlFlowNode for x | semmle.label | ControlFlowNode for x | +| src/unsafe_shell_test.py:42:34:42:34 | ControlFlowNode for x | semmle.label | ControlFlowNode for x | +| src/unsafe_shell_test.py:44:20:44:23 | ControlFlowNode for name | semmle.label | ControlFlowNode for name | subpaths #select | src/unsafe_shell_test.py:5:15:5:28 | ControlFlowNode for BinaryExpr | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:5:25:5:28 | ControlFlowNode for name | This string concatenation which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:5:5:5:29 | ControlFlowNode for Attribute() | shell command | @@ -31,3 +37,4 @@ subpaths | src/unsafe_shell_test.py:20:15:20:30 | ControlFlowNode for BinaryExpr | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:20:27:20:30 | ControlFlowNode for name | This formatted string which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:20:5:20:31 | ControlFlowNode for Attribute() | shell command | | src/unsafe_shell_test.py:29:20:29:33 | ControlFlowNode for BinaryExpr | src/unsafe_shell_test.py:26:20:26:23 | ControlFlowNode for name | src/unsafe_shell_test.py:29:30:29:33 | ControlFlowNode for name | This string concatenation which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:26:20:26:23 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:29:5:29:46 | ControlFlowNode for Attribute() | shell command | | src/unsafe_shell_test.py:39:20:39:33 | ControlFlowNode for BinaryExpr | src/unsafe_shell_test.py:36:22:36:25 | ControlFlowNode for name | src/unsafe_shell_test.py:39:30:39:33 | ControlFlowNode for name | This string concatenation which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:36:22:36:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:39:5:39:46 | ControlFlowNode for Attribute() | shell command | +| src/unsafe_shell_test.py:42:24:42:34 | ControlFlowNode for BinaryExpr | src/unsafe_shell_test.py:36:22:36:25 | ControlFlowNode for name | src/unsafe_shell_test.py:42:34:42:34 | ControlFlowNode for x | This string concatenation which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:36:22:36:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:42:9:42:47 | ControlFlowNode for Attribute() | shell command | diff --git a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py index 65d87e5495e..e3a3f062b85 100644 --- a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py +++ b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py @@ -38,7 +38,7 @@ def subprocess_flag (name): subprocess.run("ping " + name, shell=True) # $result=BAD - def indirect(flag): - subprocess.run("ping " + name, shell=flag) # $ MISSING: result=BAD + def indirect(flag, x): + subprocess.run("ping " + x, shell=flag) # $result=BAD - indirect(True) \ No newline at end of file + indirect(True, name) \ No newline at end of file From e9ebba3350561ebb52f6e5790bb2d36fe049baba Mon Sep 17 00:00:00 2001 From: erik-krogh Date: Thu, 2 Feb 2023 14:43:14 +0100 Subject: [PATCH 010/135] assume shell=False for subprocess calls, fixes FPs in e.g. youtube-dl --- python/ql/lib/semmle/python/frameworks/Stdlib.qll | 2 +- .../src/unsafe_shell_test.py | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/python/ql/lib/semmle/python/frameworks/Stdlib.qll b/python/ql/lib/semmle/python/frameworks/Stdlib.qll index c21987d9847..b08995ad99e 100644 --- a/python/ql/lib/semmle/python/frameworks/Stdlib.qll +++ b/python/ql/lib/semmle/python/frameworks/Stdlib.qll @@ -1209,7 +1209,7 @@ private module StdlibPrivate { this.get_shell_arg().getAValueReachingSink().asExpr().(ImmutableLiteral).booleanValue() or not this.get_shell_arg().getAValueReachingSink().asExpr() instanceof ImmutableLiteral and - result = [true, false] + result = false // defaults to `False` } /** Gets the API-node for the `executable` argument, if any. */ diff --git a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py index e3a3f062b85..c1afd531fbe 100644 --- a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py +++ b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py @@ -41,4 +41,6 @@ def subprocess_flag (name): def indirect(flag, x): subprocess.run("ping " + x, shell=flag) # $result=BAD - indirect(True, name) \ No newline at end of file + indirect(True, name) + + subprocess.Popen("ping " + name, shell=unknownValue) # OK - shell assumed to be False \ No newline at end of file From ef44cb86c2d7b82ab192e70a5bcc0475b8385ec8 Mon Sep 17 00:00:00 2001 From: erik-krogh Date: Thu, 2 Feb 2023 16:59:27 +0100 Subject: [PATCH 011/135] remove FPs related to parameters that are meant to be commands --- .../UnsafeShellCommandConstructionCustomizations.qll | 5 ++++- .../src/unsafe_shell_test.py | 5 ++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll b/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll index 2012ec0c552..fcffb9f5145 100644 --- a/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll +++ b/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll @@ -21,7 +21,10 @@ module UnsafeShellCommandConstruction { /** An input parameter to a gem seen as a source. */ private class LibraryInputAsSource extends Source instanceof DataFlow::ParameterNode { - LibraryInputAsSource() { this = Setuptools::getALibraryInput() } + LibraryInputAsSource() { + this = Setuptools::getALibraryInput() and + not this.getParameter().getName().matches(["cmd%", "command%", "%_command", "%_cmd"]) + } } /** A sink for shell command constructed from library input vulnerabilities. */ diff --git a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py index c1afd531fbe..1b4bc708c45 100644 --- a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py +++ b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/src/unsafe_shell_test.py @@ -43,4 +43,7 @@ def subprocess_flag (name): indirect(True, name) - subprocess.Popen("ping " + name, shell=unknownValue) # OK - shell assumed to be False \ No newline at end of file + subprocess.Popen("ping " + name, shell=unknownValue) # OK - shell assumed to be False + +def intentional(command): + os.system("fish -ic " + command) # $result=OK - intentional \ No newline at end of file From 848b24cfe4527bc02e295d4af9ef4a3d7c67dbc4 Mon Sep 17 00:00:00 2001 From: erik-krogh Date: Thu, 2 Feb 2023 19:36:46 +0100 Subject: [PATCH 012/135] adjust concept tests after changing subprocess model --- .../library-tests/frameworks/stdlib/SystemCommandExecution.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python/ql/test/library-tests/frameworks/stdlib/SystemCommandExecution.py b/python/ql/test/library-tests/frameworks/stdlib/SystemCommandExecution.py index ae165fe14bf..7a9d91d52b9 100644 --- a/python/ql/test/library-tests/frameworks/stdlib/SystemCommandExecution.py +++ b/python/ql/test/library-tests/frameworks/stdlib/SystemCommandExecution.py @@ -140,7 +140,7 @@ subprocess.Popen(args) # $getCommand=args args = "" use_shell = False exe = "executable" -subprocess.Popen(args, shell=use_shell, executable=exe) # $getCommand=exe SPURIOUS: getCommand=args +subprocess.Popen(args, shell=use_shell, executable=exe) # $getCommand=exe ################################################################################ From cf094c2f4f189134882bc2065d728674b1f915bf Mon Sep 17 00:00:00 2001 From: erik-krogh Date: Fri, 3 Feb 2023 12:06:43 +0100 Subject: [PATCH 013/135] adjust which folders are seen as exported to remove an FP --- python/ql/lib/semmle/python/frameworks/Setuptools.qll | 11 +++++++---- .../setup_posix.py | 4 ++++ 2 files changed, 11 insertions(+), 4 deletions(-) create mode 100644 python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/setup_posix.py diff --git a/python/ql/lib/semmle/python/frameworks/Setuptools.qll b/python/ql/lib/semmle/python/frameworks/Setuptools.qll index 32509cfccec..5edff4bf92c 100644 --- a/python/ql/lib/semmle/python/frameworks/Setuptools.qll +++ b/python/ql/lib/semmle/python/frameworks/Setuptools.qll @@ -19,7 +19,12 @@ module Setuptools { * Gets a file or folder that is exported by a library. */ private Container getALibraryExportedContainer() { - result = setupFile().getParent() + // a child folder of the root that has a setup.py file + result = setupFile().getParent().(Folder).getAFolder() and + // where the folder has __init__.py file + exists(result.(Folder).getFile("__init__.py")) and + // and is not a test folder + not result.(Folder).getBaseName() = ["test", "tests", "testing"] or // child of a library exported container result = getALibraryExportedContainer().getAChildContainer() and @@ -29,9 +34,7 @@ module Setuptools { or // or a folder with an __init__.py file exists(result.(Folder).getFile("__init__.py")) - ) and - // that is not a test folder - not result.(Folder).getBaseName() = ["test", "tests", "testing"] + ) } /** diff --git a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/setup_posix.py b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/setup_posix.py new file mode 100644 index 00000000000..d5f3fb63d96 --- /dev/null +++ b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/setup_posix.py @@ -0,0 +1,4 @@ +import os + +def unsafe_setup(name): + os.system("ping " + name) # $result=OK - this is inside a setyp script, so it's fine. \ No newline at end of file From c5350ca6a01298f54228108eeda5b14cef43d2dd Mon Sep 17 00:00:00 2001 From: erik-krogh Date: Fri, 3 Feb 2023 12:09:01 +0100 Subject: [PATCH 014/135] add change-note --- .../2023-02-03-unsafe-shell-command-construction.md | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 python/ql/src/change-notes/2023-02-03-unsafe-shell-command-construction.md diff --git a/python/ql/src/change-notes/2023-02-03-unsafe-shell-command-construction.md b/python/ql/src/change-notes/2023-02-03-unsafe-shell-command-construction.md new file mode 100644 index 00000000000..0654a93582b --- /dev/null +++ b/python/ql/src/change-notes/2023-02-03-unsafe-shell-command-construction.md @@ -0,0 +1,4 @@ +--- +category: newQuery +--- +* Added a new query, `py/shell-command-constructed-from-input`, to detect libraries that unsafely construct shell commands from their inputs. From 8e05fdb36942525ff36da50d276452a55948df46 Mon Sep 17 00:00:00 2001 From: erik-krogh Date: Fri, 3 Feb 2023 15:00:31 +0100 Subject: [PATCH 015/135] make more imports private --- .../UnsafeShellCommandConstructionCustomizations.qll | 6 +++--- .../dataflow/UnsafeShellCommandConstructionQuery.qll | 8 ++++---- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll b/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll index fcffb9f5145..903b8f3eb72 100644 --- a/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll +++ b/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll @@ -5,9 +5,9 @@ */ private import python -import semmle.python.dataflow.new.DataFlow -import semmle.python.dataflow.new.TaintTracking -import CommandInjectionCustomizations::CommandInjection as CommandInjection +private import semmle.python.dataflow.new.DataFlow +private import semmle.python.dataflow.new.TaintTracking +private import CommandInjectionCustomizations::CommandInjection as CommandInjection private import semmle.python.Concepts as Concepts /** diff --git a/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionQuery.qll b/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionQuery.qll index 6fc567289e7..9003b19015c 100644 --- a/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionQuery.qll +++ b/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionQuery.qll @@ -7,11 +7,11 @@ */ import python -import UnsafeShellCommandConstructionCustomizations::UnsafeShellCommandConstruction import semmle.python.dataflow.new.DataFlow -import semmle.python.dataflow.new.TaintTracking -import CommandInjectionCustomizations::CommandInjection as CommandInjection -import semmle.python.dataflow.new.BarrierGuards +import UnsafeShellCommandConstructionCustomizations::UnsafeShellCommandConstruction +private import semmle.python.dataflow.new.TaintTracking +private import CommandInjectionCustomizations::CommandInjection as CommandInjection +private import semmle.python.dataflow.new.BarrierGuards /** * A taint-tracking configuration for detecting shell command constructed from library input vulnerabilities. From 759854991a4ff006cae87703e008cdc331f40fb9 Mon Sep 17 00:00:00 2001 From: erik-krogh Date: Wed, 15 Feb 2023 11:10:43 +0100 Subject: [PATCH 016/135] fix various nits based on feedback --- .../UnsafeShellCommandConstructionCustomizations.qll | 6 +++--- .../dataflow/UnsafeShellCommandConstructionQuery.qll | 3 +-- .../Security/CWE-078/UnsafeShellCommandConstruction.qhelp | 6 +++--- .../CWE-078/examples/unsafe-shell-command-construction.py | 2 +- .../examples/unsafe-shell-command-construction_fixed.py | 2 +- .../UnsafeShellCommandConstruction.expected | 2 +- 6 files changed, 10 insertions(+), 11 deletions(-) diff --git a/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll b/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll index 903b8f3eb72..390c9738cc3 100644 --- a/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll +++ b/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionCustomizations.qll @@ -68,11 +68,11 @@ module UnsafeShellCommandConstruction { Fstring fstring; StringInterpolationAsSink() { - isUsedAsShellCommand(any(DataFlow::Node n | n.asExpr() = fstring), s) and + isUsedAsShellCommand(DataFlow::exprNode(fstring), s) and this.asExpr() = fstring.getASubExpression() } - override string describe() { result = "string construction" } + override string describe() { result = "f-string" } override DataFlow::Node getCommandExecution() { result = s } @@ -101,7 +101,7 @@ module UnsafeShellCommandConstruction { } /** - * A string constructed using a `.join(" ")` call, where the resulting string ends up being executed as a shell command. + * A string constructed using a `" ".join(...)` call, where the resulting string ends up being executed as a shell command. */ class ArrayJoin extends Sink { Concepts::SystemCommandExecution s; diff --git a/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionQuery.qll b/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionQuery.qll index 9003b19015c..0d9ebb8a472 100644 --- a/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionQuery.qll +++ b/python/ql/lib/semmle/python/security/dataflow/UnsafeShellCommandConstructionQuery.qll @@ -24,8 +24,7 @@ class Configuration extends TaintTracking::Configuration { override predicate isSink(DataFlow::Node sink) { sink instanceof Sink } override predicate isSanitizer(DataFlow::Node node) { - node instanceof CommandInjection::Sanitizer or // using all sanitizers from `rb/command-injection` - node instanceof StringConstCompareBarrier + node instanceof CommandInjection::Sanitizer // using all sanitizers from `rb/command-injection` } // override to require the path doesn't have unmatched return steps diff --git a/python/ql/src/Security/CWE-078/UnsafeShellCommandConstruction.qhelp b/python/ql/src/Security/CWE-078/UnsafeShellCommandConstruction.qhelp index 3176d5c035d..007e691c243 100644 --- a/python/ql/src/Security/CWE-078/UnsafeShellCommandConstruction.qhelp +++ b/python/ql/src/Security/CWE-078/UnsafeShellCommandConstruction.qhelp @@ -4,7 +4,7 @@

    - Dynamically constructing a shell command with inputs from exported + Dynamically constructing a shell command with inputs from library functions may inadvertently change the meaning of the shell command. Clients using the exported function may use inputs containing @@ -21,7 +21,7 @@

    If possible, provide the dynamic arguments to the shell as an array - to APIs such as system(..) to avoid interpretation by the shell. + to APIs such as subprocess.run to avoid interpretation by the shell.

    @@ -55,7 +55,7 @@

    To avoid such potentially catastrophic behaviors, provide the - input from exported functions as an argument that does not + input from library functions as an argument that does not get interpreted by a shell:

    diff --git a/python/ql/src/Security/CWE-078/examples/unsafe-shell-command-construction.py b/python/ql/src/Security/CWE-078/examples/unsafe-shell-command-construction.py index 644af24938d..3803f59059b 100644 --- a/python/ql/src/Security/CWE-078/examples/unsafe-shell-command-construction.py +++ b/python/ql/src/Security/CWE-078/examples/unsafe-shell-command-construction.py @@ -1,4 +1,4 @@ import os -def download (path): +def download(path): os.system("wget " + path) # NOT OK diff --git a/python/ql/src/Security/CWE-078/examples/unsafe-shell-command-construction_fixed.py b/python/ql/src/Security/CWE-078/examples/unsafe-shell-command-construction_fixed.py index d62b3478bf1..6009774b9a8 100644 --- a/python/ql/src/Security/CWE-078/examples/unsafe-shell-command-construction_fixed.py +++ b/python/ql/src/Security/CWE-078/examples/unsafe-shell-command-construction_fixed.py @@ -1,4 +1,4 @@ import subprocess -def download (path): +def download(path): subprocess.run(["wget", path]) # OK diff --git a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected index 3378661f451..fc9f49f1c23 100644 --- a/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected +++ b/python/ql/test/query-tests/Security/CWE-078-UnsafeShellCommandConstruction/UnsafeShellCommandConstruction.expected @@ -30,7 +30,7 @@ nodes subpaths #select | src/unsafe_shell_test.py:5:15:5:28 | ControlFlowNode for BinaryExpr | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:5:25:5:28 | ControlFlowNode for name | This string concatenation which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:5:5:5:29 | ControlFlowNode for Attribute() | shell command | -| src/unsafe_shell_test.py:8:15:8:28 | ControlFlowNode for Fstring | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:8:23:8:26 | ControlFlowNode for name | This string construction which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:8:5:8:29 | ControlFlowNode for Attribute() | shell command | +| src/unsafe_shell_test.py:8:15:8:28 | ControlFlowNode for Fstring | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:8:23:8:26 | ControlFlowNode for name | This f-string which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:8:5:8:29 | ControlFlowNode for Attribute() | shell command | | src/unsafe_shell_test.py:11:15:11:38 | ControlFlowNode for BinaryExpr | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:11:25:11:38 | ControlFlowNode for Attribute() | This string concatenation which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:11:5:11:39 | ControlFlowNode for Attribute() | shell command | | src/unsafe_shell_test.py:14:15:14:40 | ControlFlowNode for BinaryExpr | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:14:25:14:40 | ControlFlowNode for Attribute() | This string concatenation which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:14:5:14:41 | ControlFlowNode for Attribute() | shell command | | src/unsafe_shell_test.py:17:15:17:36 | ControlFlowNode for Attribute() | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | src/unsafe_shell_test.py:17:32:17:35 | ControlFlowNode for name | This formatted string which depends on $@ is later used in a $@. | src/unsafe_shell_test.py:4:22:4:25 | ControlFlowNode for name | library input | src/unsafe_shell_test.py:17:5:17:37 | ControlFlowNode for Attribute() | shell command | From b6ec9464eb786b95f530b941718f708fb73c5ec0 Mon Sep 17 00:00:00 2001 From: Asger F Date: Wed, 1 Mar 2023 15:29:51 +0100 Subject: [PATCH 017/135] JS: Remove trailing whitespace --- javascript/extractor/src/com/semmle/jcorn/Parser.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/javascript/extractor/src/com/semmle/jcorn/Parser.java b/javascript/extractor/src/com/semmle/jcorn/Parser.java index 5c8c4e559db..3b9b184a988 100644 --- a/javascript/extractor/src/com/semmle/jcorn/Parser.java +++ b/javascript/extractor/src/com/semmle/jcorn/Parser.java @@ -1648,13 +1648,13 @@ public class Parser { return this.finishNode(node); } else if (this.type == TokenType.pound) { Position startLoc = this.startLoc; - // there is only one case where this is valid, and that is "Ergonomic brand checks for Private Fields", i.e. `#name in obj`. + // there is only one case where this is valid, and that is "Ergonomic brand checks for Private Fields", i.e. `#name in obj`. Identifier id = parseIdent(true); String op = String.valueOf(this.value); if (!op.equals("in")) { this.unexpected(startLoc); } - return this.parseExprOp(id, this.start, startLoc, -1, false); + return this.parseExprOp(id, this.start, startLoc, -1, false); } else if (this.type == TokenType.name) { Position startLoc = this.startLoc; Identifier id = this.parseIdent(this.type != TokenType.name); From f96d6accbbf9ef29040fa9a0a1d403a884b8266a Mon Sep 17 00:00:00 2001 From: erik-krogh Date: Wed, 1 Mar 2023 09:26:43 +0100 Subject: [PATCH 018/135] delete old deprecations --- cpp/ql/lib/semmle/code/cpp/Class.qll | 12 ---- cpp/ql/lib/semmle/code/cpp/XML.qll | 14 ---- .../code/cpp/commons/Synchronization.qll | 20 ------ .../code/cpp/controlflow/SubBasicBlocks.qll | 7 -- .../cpp/dataflow/internal/SubBasicBlocks.qll | 7 -- cpp/ql/lib/semmle/code/cpp/exprs/Expr.qll | 7 -- .../ir/implementation/aliased_ssa/Operand.qll | 16 ----- .../cpp/ir/implementation/raw/Operand.qll | 16 ----- .../implementation/unaliased_ssa/Operand.qll | 16 ----- .../interfaces/FunctionInputsAndOutputs.qll | 54 -------------- .../code/cpp/rangeanalysis/RangeSSA.qll | 9 --- csharp/ql/lib/semmle/code/csharp/XML.qll | 14 ---- .../semmle/code/csharp/commons/Assertions.qll | 20 ------ .../csharp/dispatch/OverridableCallable.qll | 6 -- .../ir/implementation/raw/Operand.qll | 16 ----- .../implementation/unaliased_ssa/Operand.qll | 16 ----- .../internal/AliasAnalysisImports.qll | 34 --------- java/ql/lib/semmle/code/java/Expr.qll | 8 --- java/ql/lib/semmle/code/java/security/XSS.qll | 5 -- java/ql/lib/semmle/code/xml/MavenPom.qll | 15 ---- java/ql/lib/semmle/code/xml/XML.qll | 14 ---- .../ql/lib/semmle/javascript/Functions.qll | 7 -- .../ql/lib/semmle/javascript/TypeScript.qll | 14 ---- javascript/ql/lib/semmle/javascript/XML.qll | 14 ---- .../lib/semmle/javascript/frameworks/HTTP.qll | 6 -- .../semmle/javascript/frameworks/SocketIO.qll | 9 --- .../security/dataflow/MissingRateLimiting.qll | 22 ------ python/ql/lib/semmle/python/xml/XML.qll | 14 ---- ruby/ql/lib/codeql/ruby/ast/Constant.qll | 6 -- ruby/ql/lib/codeql/ruby/ast/Control.qll | 11 --- ruby/ql/lib/codeql/ruby/ast/Expr.qll | 3 - ruby/ql/lib/codeql/ruby/ast/Parameter.qll | 21 ------ ruby/ql/lib/codeql/ruby/ast/Pattern.qll | 72 ------------------- ruby/ql/lib/codeql/ruby/ast/internal/AST.qll | 5 -- .../lib/codeql/ruby/ast/internal/Pattern.qll | 19 ----- 35 files changed, 549 deletions(-) diff --git a/cpp/ql/lib/semmle/code/cpp/Class.qll b/cpp/ql/lib/semmle/code/cpp/Class.qll index f139f67c70a..2aba033329d 100644 --- a/cpp/ql/lib/semmle/code/cpp/Class.qll +++ b/cpp/ql/lib/semmle/code/cpp/Class.qll @@ -227,18 +227,6 @@ class Class extends UserType { result = this.accessOfBaseMember(member.getDeclaringType(), member.getASpecifier()) } - /** - * DEPRECATED: name changed to `hasImplicitCopyConstructor` to reflect that - * `= default` members are no longer included. - */ - deprecated predicate hasGeneratedCopyConstructor() { this.hasImplicitCopyConstructor() } - - /** - * DEPRECATED: name changed to `hasImplicitCopyAssignmentOperator` to - * reflect that `= default` members are no longer included. - */ - deprecated predicate hasGeneratedCopyAssignmentOperator() { this.hasImplicitCopyConstructor() } - /** * Holds if this class, struct or union has an implicitly-declared copy * constructor that is not _deleted_. This predicate is more accurate than diff --git a/cpp/ql/lib/semmle/code/cpp/XML.qll b/cpp/ql/lib/semmle/code/cpp/XML.qll index d74129d425e..33f4cd9e9e6 100644 --- a/cpp/ql/lib/semmle/code/cpp/XML.qll +++ b/cpp/ql/lib/semmle/code/cpp/XML.qll @@ -108,20 +108,6 @@ class XmlFile extends XmlParent, File { /** Gets the name of this XML file. */ override string getName() { result = File.super.getAbsolutePath() } - /** - * DEPRECATED: Use `getAbsolutePath()` instead. - * - * Gets the path of this XML file. - */ - deprecated string getPath() { result = this.getAbsolutePath() } - - /** - * DEPRECATED: Use `getParentContainer().getAbsolutePath()` instead. - * - * Gets the path of the folder that contains this XML file. - */ - deprecated string getFolder() { result = this.getParentContainer().getAbsolutePath() } - /** Gets the encoding of this XML file. */ string getEncoding() { xmlEncoding(this, result) } diff --git a/cpp/ql/lib/semmle/code/cpp/commons/Synchronization.qll b/cpp/ql/lib/semmle/code/cpp/commons/Synchronization.qll index f1b9cf80d64..f02958cd241 100644 --- a/cpp/ql/lib/semmle/code/cpp/commons/Synchronization.qll +++ b/cpp/ql/lib/semmle/code/cpp/commons/Synchronization.qll @@ -59,26 +59,6 @@ abstract class MutexType extends Type { * Gets a call that unlocks any mutex of this type. */ FunctionCall getUnlockAccess() { this.unlockAccess(result, _) } - - /** - * DEPRECATED: use mustlockAccess(fc, arg) instead. - */ - deprecated Function getMustlockFunction() { result = this.getMustlockAccess().getTarget() } - - /** - * DEPRECATED: use trylockAccess(fc, arg) instead. - */ - deprecated Function getTrylockFunction() { result = this.getTrylockAccess().getTarget() } - - /** - * DEPRECATED: use lockAccess(fc, arg) instead. - */ - deprecated Function getLockFunction() { result = this.getLockAccess().getTarget() } - - /** - * DEPRECATED: use unlockAccess(fc, arg) instead. - */ - deprecated Function getUnlockFunction() { result = this.getUnlockAccess().getTarget() } } /** diff --git a/cpp/ql/lib/semmle/code/cpp/controlflow/SubBasicBlocks.qll b/cpp/ql/lib/semmle/code/cpp/controlflow/SubBasicBlocks.qll index 52f09eb7778..9ee0fa3131b 100644 --- a/cpp/ql/lib/semmle/code/cpp/controlflow/SubBasicBlocks.qll +++ b/cpp/ql/lib/semmle/code/cpp/controlflow/SubBasicBlocks.qll @@ -75,13 +75,6 @@ class SubBasicBlock extends ControlFlowNodeBase { ) } - /** - * DEPRECATED: use `getRankInBasicBlock` instead. Note that this predicate - * returns a 0-based position, while `getRankInBasicBlock` returns a 1-based - * position. - */ - deprecated int getPosInBasicBlock(BasicBlock bb) { result = this.getRankInBasicBlock(bb) - 1 } - pragma[noinline] private int getIndexInBasicBlock(BasicBlock bb) { this = bb.getNode(result) } diff --git a/cpp/ql/lib/semmle/code/cpp/dataflow/internal/SubBasicBlocks.qll b/cpp/ql/lib/semmle/code/cpp/dataflow/internal/SubBasicBlocks.qll index 52f09eb7778..9ee0fa3131b 100644 --- a/cpp/ql/lib/semmle/code/cpp/dataflow/internal/SubBasicBlocks.qll +++ b/cpp/ql/lib/semmle/code/cpp/dataflow/internal/SubBasicBlocks.qll @@ -75,13 +75,6 @@ class SubBasicBlock extends ControlFlowNodeBase { ) } - /** - * DEPRECATED: use `getRankInBasicBlock` instead. Note that this predicate - * returns a 0-based position, while `getRankInBasicBlock` returns a 1-based - * position. - */ - deprecated int getPosInBasicBlock(BasicBlock bb) { result = this.getRankInBasicBlock(bb) - 1 } - pragma[noinline] private int getIndexInBasicBlock(BasicBlock bb) { this = bb.getNode(result) } diff --git a/cpp/ql/lib/semmle/code/cpp/exprs/Expr.qll b/cpp/ql/lib/semmle/code/cpp/exprs/Expr.qll index a74a94ae2ba..93aa923a500 100644 --- a/cpp/ql/lib/semmle/code/cpp/exprs/Expr.qll +++ b/cpp/ql/lib/semmle/code/cpp/exprs/Expr.qll @@ -719,13 +719,6 @@ class ReferenceToExpr extends Conversion, @reference_to { class PointerDereferenceExpr extends UnaryOperation, @indirect { override string getAPrimaryQlClass() { result = "PointerDereferenceExpr" } - /** - * DEPRECATED: Use getOperand() instead. - * - * Gets the expression that is being dereferenced. - */ - deprecated Expr getExpr() { result = this.getOperand() } - override string getOperator() { result = "*" } override int getPrecedence() { result = 16 } diff --git a/cpp/ql/lib/semmle/code/cpp/ir/implementation/aliased_ssa/Operand.qll b/cpp/ql/lib/semmle/code/cpp/ir/implementation/aliased_ssa/Operand.qll index 4bd58e6b96a..c1743acdbae 100644 --- a/cpp/ql/lib/semmle/code/cpp/ir/implementation/aliased_ssa/Operand.qll +++ b/cpp/ql/lib/semmle/code/cpp/ir/implementation/aliased_ssa/Operand.qll @@ -87,22 +87,6 @@ class Operand extends TStageOperand { this.getDefinitionOverlap() instanceof MustExactlyOverlap } - /** - * DEPRECATED: renamed to `getUse`. - * - * Gets the `Instruction` that consumes this operand. - */ - deprecated final Instruction getUseInstruction() { result = this.getUse() } - - /** - * DEPRECATED: use `getAnyDef` or `getDef`. The exact replacement for this - * predicate is `getAnyDef`, but most uses of this predicate should probably - * be replaced with `getDef`. - * - * Gets the `Instruction` whose result is the value of the operand. - */ - deprecated final Instruction getDefinitionInstruction() { result = this.getAnyDef() } - /** * Gets the overlap relationship between the operand's definition and its use. */ diff --git a/cpp/ql/lib/semmle/code/cpp/ir/implementation/raw/Operand.qll b/cpp/ql/lib/semmle/code/cpp/ir/implementation/raw/Operand.qll index 4bd58e6b96a..c1743acdbae 100644 --- a/cpp/ql/lib/semmle/code/cpp/ir/implementation/raw/Operand.qll +++ b/cpp/ql/lib/semmle/code/cpp/ir/implementation/raw/Operand.qll @@ -87,22 +87,6 @@ class Operand extends TStageOperand { this.getDefinitionOverlap() instanceof MustExactlyOverlap } - /** - * DEPRECATED: renamed to `getUse`. - * - * Gets the `Instruction` that consumes this operand. - */ - deprecated final Instruction getUseInstruction() { result = this.getUse() } - - /** - * DEPRECATED: use `getAnyDef` or `getDef`. The exact replacement for this - * predicate is `getAnyDef`, but most uses of this predicate should probably - * be replaced with `getDef`. - * - * Gets the `Instruction` whose result is the value of the operand. - */ - deprecated final Instruction getDefinitionInstruction() { result = this.getAnyDef() } - /** * Gets the overlap relationship between the operand's definition and its use. */ diff --git a/cpp/ql/lib/semmle/code/cpp/ir/implementation/unaliased_ssa/Operand.qll b/cpp/ql/lib/semmle/code/cpp/ir/implementation/unaliased_ssa/Operand.qll index 4bd58e6b96a..c1743acdbae 100644 --- a/cpp/ql/lib/semmle/code/cpp/ir/implementation/unaliased_ssa/Operand.qll +++ b/cpp/ql/lib/semmle/code/cpp/ir/implementation/unaliased_ssa/Operand.qll @@ -87,22 +87,6 @@ class Operand extends TStageOperand { this.getDefinitionOverlap() instanceof MustExactlyOverlap } - /** - * DEPRECATED: renamed to `getUse`. - * - * Gets the `Instruction` that consumes this operand. - */ - deprecated final Instruction getUseInstruction() { result = this.getUse() } - - /** - * DEPRECATED: use `getAnyDef` or `getDef`. The exact replacement for this - * predicate is `getAnyDef`, but most uses of this predicate should probably - * be replaced with `getDef`. - * - * Gets the `Instruction` whose result is the value of the operand. - */ - deprecated final Instruction getDefinitionInstruction() { result = this.getAnyDef() } - /** * Gets the overlap relationship between the operand's definition and its use. */ diff --git a/cpp/ql/lib/semmle/code/cpp/models/interfaces/FunctionInputsAndOutputs.qll b/cpp/ql/lib/semmle/code/cpp/models/interfaces/FunctionInputsAndOutputs.qll index de44913a39f..7fd36f26183 100644 --- a/cpp/ql/lib/semmle/code/cpp/models/interfaces/FunctionInputsAndOutputs.qll +++ b/cpp/ql/lib/semmle/code/cpp/models/interfaces/FunctionInputsAndOutputs.qll @@ -40,12 +40,6 @@ class FunctionInput extends TFunctionInput { */ predicate isParameter(ParameterIndex index) { none() } - /** - * Holds if this is the input value of the parameter with index `index`. - * DEPRECATED: Use `isParameter(index)` instead. - */ - deprecated final predicate isInParameter(ParameterIndex index) { this.isParameter(index) } - /** * Holds if this is the input value pointed to (through `ind` number of indirections) by a * pointer parameter to a function, or the input value referred to by a reference parameter @@ -84,16 +78,6 @@ class FunctionInput extends TFunctionInput { */ predicate isParameterDeref(ParameterIndex index) { this.isParameterDeref(index, 1) } - /** - * Holds if this is the input value pointed to by a pointer parameter to a function, or the input - * value referred to by a reference parameter to a function, where the parameter has index - * `index`. - * DEPRECATED: Use `isParameterDeref(index)` instead. - */ - deprecated final predicate isInParameterPointer(ParameterIndex index) { - this.isParameterDeref(index) - } - /** * Holds if this is the input value pointed to by the `this` pointer of an instance member * function. @@ -124,13 +108,6 @@ class FunctionInput extends TFunctionInput { */ predicate isQualifierObject() { this.isQualifierObject(1) } - /** - * Holds if this is the input value pointed to by the `this` pointer of an instance member - * function. - * DEPRECATED: Use `isQualifierObject()` instead. - */ - deprecated final predicate isInQualifier() { this.isQualifierObject() } - /** * Holds if this is the input value of the `this` pointer of an instance member function. * @@ -396,16 +373,6 @@ class FunctionOutput extends TFunctionOutput { */ predicate isParameterDeref(ParameterIndex i, int ind) { ind = 1 and this.isParameterDeref(i) } - /** - * Holds if this is the output value pointed to by a pointer parameter to a function, or the - * output value referred to by a reference parameter to a function, where the parameter has - * index `index`. - * DEPRECATED: Use `isParameterDeref(index)` instead. - */ - deprecated final predicate isOutParameterPointer(ParameterIndex index) { - this.isParameterDeref(index) - } - /** * Holds if this is the output value pointed to by the `this` pointer of an instance member * function. @@ -436,13 +403,6 @@ class FunctionOutput extends TFunctionOutput { */ predicate isQualifierObject(int ind) { ind = 1 and this.isQualifierObject() } - /** - * Holds if this is the output value pointed to by the `this` pointer of an instance member - * function. - * DEPRECATED: Use `isQualifierObject()` instead. - */ - deprecated final predicate isOutQualifier() { this.isQualifierObject() } - /** * Holds if this is the value returned by a function. * @@ -462,12 +422,6 @@ class FunctionOutput extends TFunctionOutput { */ predicate isReturnValue() { none() } - /** - * Holds if this is the value returned by a function. - * DEPRECATED: Use `isReturnValue()` instead. - */ - deprecated final predicate isOutReturnValue() { this.isReturnValue() } - /** * Holds if this is the output value pointed to by the return value of a function, if the function * returns a pointer, or the output value referred to by the return value of a function, if the @@ -508,14 +462,6 @@ class FunctionOutput extends TFunctionOutput { */ predicate isReturnValueDeref(int ind) { ind = 1 and this.isReturnValueDeref() } - /** - * Holds if this is the output value pointed to by the return value of a function, if the function - * returns a pointer, or the output value referred to by the return value of a function, if the - * function returns a reference. - * DEPRECATED: Use `isReturnValueDeref()` instead. - */ - deprecated final predicate isOutReturnPointer() { this.isReturnValueDeref() } - /** * Holds if `i >= 0` and `isParameterDeref(i, ind)` holds for this is the value, or * if `i = -1` and `isQualifierObject(ind)` holds for this value. diff --git a/cpp/ql/lib/semmle/code/cpp/rangeanalysis/RangeSSA.qll b/cpp/ql/lib/semmle/code/cpp/rangeanalysis/RangeSSA.qll index 02cd5cb7876..2503e4713d8 100644 --- a/cpp/ql/lib/semmle/code/cpp/rangeanalysis/RangeSSA.qll +++ b/cpp/ql/lib/semmle/code/cpp/rangeanalysis/RangeSSA.qll @@ -96,15 +96,6 @@ class RangeSsaDefinition extends ControlFlowNodeBase { /** Whether this definition is a phi node for variable `v`. */ predicate isPhiNode(StackVariable v) { exists(RangeSsa x | x.phi_node(v, this)) } - /** - * DEPRECATED: Use isGuardPhi/4 instead - * If this definition is a phi node corresponding to a guard, - * then return the variable access and the guard. - */ - deprecated predicate isGuardPhi(VariableAccess va, Expr guard, boolean branch) { - guard_defn(va, guard, this, branch) - } - /** * If this definition is a phi node corresponding to a guard, * then return the variable guarded, the variable access and the guard. diff --git a/csharp/ql/lib/semmle/code/csharp/XML.qll b/csharp/ql/lib/semmle/code/csharp/XML.qll index d74129d425e..33f4cd9e9e6 100644 --- a/csharp/ql/lib/semmle/code/csharp/XML.qll +++ b/csharp/ql/lib/semmle/code/csharp/XML.qll @@ -108,20 +108,6 @@ class XmlFile extends XmlParent, File { /** Gets the name of this XML file. */ override string getName() { result = File.super.getAbsolutePath() } - /** - * DEPRECATED: Use `getAbsolutePath()` instead. - * - * Gets the path of this XML file. - */ - deprecated string getPath() { result = this.getAbsolutePath() } - - /** - * DEPRECATED: Use `getParentContainer().getAbsolutePath()` instead. - * - * Gets the path of the folder that contains this XML file. - */ - deprecated string getFolder() { result = this.getParentContainer().getAbsolutePath() } - /** Gets the encoding of this XML file. */ string getEncoding() { xmlEncoding(this, result) } diff --git a/csharp/ql/lib/semmle/code/csharp/commons/Assertions.qll b/csharp/ql/lib/semmle/code/csharp/commons/Assertions.qll index f35b10ac934..0e51cbbb895 100644 --- a/csharp/ql/lib/semmle/code/csharp/commons/Assertions.qll +++ b/csharp/ql/lib/semmle/code/csharp/commons/Assertions.qll @@ -37,26 +37,6 @@ abstract class AssertMethod extends Method { /** Gets the index of a parameter being asserted. */ abstract int getAnAssertionIndex(); - /** - * DEPRECATED: Use `getAnAssertionIndex()` instead. - * - * Gets the index of a parameter being asserted. - */ - deprecated final int getAssertionIndex() { result = this.getAnAssertionIndex() } - - /** Gets the parameter at position `i` being asserted. */ - final Parameter getAssertedParameter(int i) { - result = this.getParameter(i) and - i = this.getAnAssertionIndex() - } - - /** - * DEPRECATED: Use `getAssertedParameter(_)` instead. - * - * Gets a parameter being asserted. - */ - deprecated final Parameter getAssertedParameter() { result = this.getAssertedParameter(_) } - /** Gets the failure type if the assertion fails for argument `i`, if any. */ abstract AssertionFailure getAssertionFailure(int i); } diff --git a/csharp/ql/lib/semmle/code/csharp/dispatch/OverridableCallable.qll b/csharp/ql/lib/semmle/code/csharp/dispatch/OverridableCallable.qll index ffb14f1e915..9905f4939b3 100644 --- a/csharp/ql/lib/semmle/code/csharp/dispatch/OverridableCallable.qll +++ b/csharp/ql/lib/semmle/code/csharp/dispatch/OverridableCallable.qll @@ -162,12 +162,6 @@ class OverridableCallable extends Callable, Overridable { } } -/** An overridable method. */ -deprecated class OverridableMethod extends Method, OverridableCallable { } - -/** An overridable accessor. */ -deprecated class OverridableAccessor extends Accessor, OverridableCallable { } - /** An unbound type. */ class UnboundDeclarationType extends Type { UnboundDeclarationType() { this.isUnboundDeclaration() } diff --git a/csharp/ql/src/experimental/ir/implementation/raw/Operand.qll b/csharp/ql/src/experimental/ir/implementation/raw/Operand.qll index 4bd58e6b96a..c1743acdbae 100644 --- a/csharp/ql/src/experimental/ir/implementation/raw/Operand.qll +++ b/csharp/ql/src/experimental/ir/implementation/raw/Operand.qll @@ -87,22 +87,6 @@ class Operand extends TStageOperand { this.getDefinitionOverlap() instanceof MustExactlyOverlap } - /** - * DEPRECATED: renamed to `getUse`. - * - * Gets the `Instruction` that consumes this operand. - */ - deprecated final Instruction getUseInstruction() { result = this.getUse() } - - /** - * DEPRECATED: use `getAnyDef` or `getDef`. The exact replacement for this - * predicate is `getAnyDef`, but most uses of this predicate should probably - * be replaced with `getDef`. - * - * Gets the `Instruction` whose result is the value of the operand. - */ - deprecated final Instruction getDefinitionInstruction() { result = this.getAnyDef() } - /** * Gets the overlap relationship between the operand's definition and its use. */ diff --git a/csharp/ql/src/experimental/ir/implementation/unaliased_ssa/Operand.qll b/csharp/ql/src/experimental/ir/implementation/unaliased_ssa/Operand.qll index 4bd58e6b96a..c1743acdbae 100644 --- a/csharp/ql/src/experimental/ir/implementation/unaliased_ssa/Operand.qll +++ b/csharp/ql/src/experimental/ir/implementation/unaliased_ssa/Operand.qll @@ -87,22 +87,6 @@ class Operand extends TStageOperand { this.getDefinitionOverlap() instanceof MustExactlyOverlap } - /** - * DEPRECATED: renamed to `getUse`. - * - * Gets the `Instruction` that consumes this operand. - */ - deprecated final Instruction getUseInstruction() { result = this.getUse() } - - /** - * DEPRECATED: use `getAnyDef` or `getDef`. The exact replacement for this - * predicate is `getAnyDef`, but most uses of this predicate should probably - * be replaced with `getDef`. - * - * Gets the `Instruction` whose result is the value of the operand. - */ - deprecated final Instruction getDefinitionInstruction() { result = this.getAnyDef() } - /** * Gets the overlap relationship between the operand's definition and its use. */ diff --git a/csharp/ql/src/experimental/ir/implementation/unaliased_ssa/internal/AliasAnalysisImports.qll b/csharp/ql/src/experimental/ir/implementation/unaliased_ssa/internal/AliasAnalysisImports.qll index aaecac058bd..78dcdc95af0 100644 --- a/csharp/ql/src/experimental/ir/implementation/unaliased_ssa/internal/AliasAnalysisImports.qll +++ b/csharp/ql/src/experimental/ir/implementation/unaliased_ssa/internal/AliasAnalysisImports.qll @@ -32,12 +32,6 @@ module AliasModels { */ predicate isParameter(ParameterIndex index) { none() } - /** - * Holds if this is the input value of the parameter with index `index`. - * DEPRECATED: Use `isParameter(index)` instead. - */ - deprecated final predicate isInParameter(ParameterIndex index) { this.isParameter(index) } - /** * Holds if this is the input value pointed to by a pointer parameter to a function, or the input * value referred to by a reference parameter to a function, where the parameter has index @@ -71,13 +65,6 @@ module AliasModels { */ predicate isQualifierObject() { none() } - /** - * Holds if this is the input value pointed to by the `this` pointer of an instance member - * function. - * DEPRECATED: Use `isQualifierObject()` instead. - */ - deprecated final predicate isInQualifier() { this.isQualifierObject() } - /** * Holds if this is the input value of the `this` pointer of an instance member function. * @@ -182,13 +169,6 @@ module AliasModels { */ predicate isQualifierObject() { none() } - /** - * Holds if this is the output value pointed to by the `this` pointer of an instance member - * function. - * DEPRECATED: Use `isQualifierObject()` instead. - */ - deprecated final predicate isOutQualifier() { this.isQualifierObject() } - /** * Holds if this is the value returned by a function. * @@ -208,12 +188,6 @@ module AliasModels { */ predicate isReturnValue() { none() } - /** - * Holds if this is the value returned by a function. - * DEPRECATED: Use `isReturnValue()` instead. - */ - deprecated final predicate isOutReturnValue() { this.isReturnValue() } - /** * Holds if this is the output value pointed to by the return value of a function, if the function * returns a pointer, or the output value referred to by the return value of a function, if the @@ -234,14 +208,6 @@ module AliasModels { */ predicate isReturnValueDeref() { none() } - /** - * Holds if this is the output value pointed to by the return value of a function, if the function - * returns a pointer, or the output value referred to by the return value of a function, if the - * function returns a reference. - * DEPRECATED: Use `isReturnValueDeref()` instead. - */ - deprecated final predicate isOutReturnPointer() { this.isReturnValueDeref() } - /** * Holds if `i >= 0` and `isParameterDeref(i)` holds for this is the value, or * if `i = -1` and `isQualifierObject()` holds for this value. diff --git a/java/ql/lib/semmle/code/java/Expr.qll b/java/ql/lib/semmle/code/java/Expr.qll index 42b8313e063..b4fbfc55818 100644 --- a/java/ql/lib/semmle/code/java/Expr.qll +++ b/java/ql/lib/semmle/code/java/Expr.qll @@ -701,14 +701,6 @@ class StringLiteral extends Literal, @stringliteral { */ override string getValue() { result = super.getValue() } - /** - * DEPRECATED: This predicate will be removed in a future version because - * it is just an alias for `getValue()`; that predicate should be used instead. - * - * Gets the literal string without the quotes. - */ - deprecated string getRepresentedString() { result = this.getValue() } - /** Holds if this string literal is a text block (`""" ... """`). */ predicate isTextBlock() { this.getLiteral().matches("\"\"\"%") } diff --git a/java/ql/lib/semmle/code/java/security/XSS.qll b/java/ql/lib/semmle/code/java/security/XSS.qll index fa94fe09cac..b167cfe049e 100644 --- a/java/ql/lib/semmle/code/java/security/XSS.qll +++ b/java/ql/lib/semmle/code/java/security/XSS.qll @@ -107,11 +107,6 @@ class XssVulnerableWriterSource extends MethodAccess { } } -/** - * DEPRECATED: Use `XssVulnerableWriterSource` instead. - */ -deprecated class ServletWriterSource = XssVulnerableWriterSource; - /** * Holds if `s` is an HTTP Content-Type vulnerable to XSS. */ diff --git a/java/ql/lib/semmle/code/xml/MavenPom.qll b/java/ql/lib/semmle/code/xml/MavenPom.qll index 612c1468259..313a0e08bd8 100644 --- a/java/ql/lib/semmle/code/xml/MavenPom.qll +++ b/java/ql/lib/semmle/code/xml/MavenPom.qll @@ -454,21 +454,11 @@ class MavenRepoJar extends File { ) } - /** - * DEPRECATED: name changed to `getGroupId` for consistent use of camel-case. - */ - deprecated string getGroupID() { result = this.getGroupId() } - /** * Gets the `artifactId` of this jar. */ string getArtifactId() { result = this.getParentContainer().getParentContainer().getBaseName() } - /** - * DEPRECATED: name changed to `getArtifactId` for consistent casing and consistent spelling with Maven. - */ - deprecated string getArtefactID() { result = this.getArtifactId() } - /** * Gets the artifact version string of this jar. */ @@ -482,11 +472,6 @@ class MavenRepoJar extends File { pom.getArtifact().getValue() = this.getArtifactId() } - /** - * DEPRECATED: name changed to `artifactMatches` for consistent spelling with Maven. - */ - deprecated predicate artefactMatches(ProtoPom pom) { this.artifactMatches(pom) } - /** * Holds if this jar is both an artifact for the POM, and has a version string that matches the POM * version string. Only soft and hard version matches are supported. diff --git a/java/ql/lib/semmle/code/xml/XML.qll b/java/ql/lib/semmle/code/xml/XML.qll index d74129d425e..33f4cd9e9e6 100644 --- a/java/ql/lib/semmle/code/xml/XML.qll +++ b/java/ql/lib/semmle/code/xml/XML.qll @@ -108,20 +108,6 @@ class XmlFile extends XmlParent, File { /** Gets the name of this XML file. */ override string getName() { result = File.super.getAbsolutePath() } - /** - * DEPRECATED: Use `getAbsolutePath()` instead. - * - * Gets the path of this XML file. - */ - deprecated string getPath() { result = this.getAbsolutePath() } - - /** - * DEPRECATED: Use `getParentContainer().getAbsolutePath()` instead. - * - * Gets the path of the folder that contains this XML file. - */ - deprecated string getFolder() { result = this.getParentContainer().getAbsolutePath() } - /** Gets the encoding of this XML file. */ string getEncoding() { xmlEncoding(this, result) } diff --git a/javascript/ql/lib/semmle/javascript/Functions.qll b/javascript/ql/lib/semmle/javascript/Functions.qll index 62abdddaa69..b5d8f414181 100644 --- a/javascript/ql/lib/semmle/javascript/Functions.qll +++ b/javascript/ql/lib/semmle/javascript/Functions.qll @@ -82,13 +82,6 @@ class Function extends @function, Parameterized, TypeParameterized, StmtContaine result = this.getDocumentation().getATagByTitle("this").getType() } - /** - * DEPRECATED: Use `getIdentifier()` instead. - * - * Gets the identifier specifying the name of this function, if any. - */ - deprecated VarDecl getId() { result = this.getIdentifier() } - /** Gets the identifier specifying the name of this function, if any. */ VarDecl getIdentifier() { result = this.getChildExpr(-1) } diff --git a/javascript/ql/lib/semmle/javascript/TypeScript.qll b/javascript/ql/lib/semmle/javascript/TypeScript.qll index 5b8cd763dfe..8ebad5d7458 100644 --- a/javascript/ql/lib/semmle/javascript/TypeScript.qll +++ b/javascript/ql/lib/semmle/javascript/TypeScript.qll @@ -7,13 +7,6 @@ import javascript * considered to be namespace definitions. */ class NamespaceDefinition extends Stmt, @namespace_definition, AST::ValueNode { - /** - * DEPRECATED: Use `getIdentifier()` instead. - * - * Gets the identifier naming the namespace. - */ - deprecated Identifier getId() { result = this.getIdentifier() } - /** * Gets the identifier naming the namespace. */ @@ -189,13 +182,6 @@ class GlobalAugmentationDeclaration extends Stmt, StmtContainer, @global_augment /** A TypeScript "import-equals" declaration. */ class ImportEqualsDeclaration extends Stmt, @import_equals_declaration { - /** - * DEPRECATED: Use `getIdentifier()` instead. - * - * Gets the name under which the imported entity is imported. - */ - deprecated Identifier getId() { result = this.getIdentifier() } - /** Gets the name under which the imported entity is imported. */ Identifier getIdentifier() { result = this.getChildExpr(0) } diff --git a/javascript/ql/lib/semmle/javascript/XML.qll b/javascript/ql/lib/semmle/javascript/XML.qll index d74129d425e..33f4cd9e9e6 100644 --- a/javascript/ql/lib/semmle/javascript/XML.qll +++ b/javascript/ql/lib/semmle/javascript/XML.qll @@ -108,20 +108,6 @@ class XmlFile extends XmlParent, File { /** Gets the name of this XML file. */ override string getName() { result = File.super.getAbsolutePath() } - /** - * DEPRECATED: Use `getAbsolutePath()` instead. - * - * Gets the path of this XML file. - */ - deprecated string getPath() { result = this.getAbsolutePath() } - - /** - * DEPRECATED: Use `getParentContainer().getAbsolutePath()` instead. - * - * Gets the path of the folder that contains this XML file. - */ - deprecated string getFolder() { result = this.getParentContainer().getAbsolutePath() } - /** Gets the encoding of this XML file. */ string getEncoding() { xmlEncoding(this, result) } diff --git a/javascript/ql/lib/semmle/javascript/frameworks/HTTP.qll b/javascript/ql/lib/semmle/javascript/frameworks/HTTP.qll index 2fcbb6d2800..c80dc901ee8 100644 --- a/javascript/ql/lib/semmle/javascript/frameworks/HTTP.qll +++ b/javascript/ql/lib/semmle/javascript/frameworks/HTTP.qll @@ -347,9 +347,6 @@ module Http { */ abstract RouteHandler getRouteHandler(); - /** DEPRECATED. Use `ref().flowsTo()` instead. */ - deprecated predicate flowsTo(DataFlow::Node nd) { this.ref().flowsTo(nd) } - private DataFlow::SourceNode ref(DataFlow::TypeTracker t) { t.start() and result = this @@ -372,9 +369,6 @@ module Http { */ abstract RouteHandler getRouteHandler(); - /** DEPRECATED. Use `ref().flowsTo()` instead. */ - deprecated predicate flowsTo(DataFlow::Node nd) { this.ref().flowsTo(nd) } - private DataFlow::SourceNode ref(DataFlow::TypeTracker t) { t.start() and result = this diff --git a/javascript/ql/lib/semmle/javascript/frameworks/SocketIO.qll b/javascript/ql/lib/semmle/javascript/frameworks/SocketIO.qll index 238bcae482a..cde7ec56124 100644 --- a/javascript/ql/lib/semmle/javascript/frameworks/SocketIO.qll +++ b/javascript/ql/lib/semmle/javascript/frameworks/SocketIO.qll @@ -269,9 +269,6 @@ module SocketIO { /** Gets the acknowledgment callback, if any. */ ReceiveCallback getAck() { result.getReceiveNode() = this } - - /** DEPRECATED. Use `getChannel()` instead. */ - deprecated string getEventName() { result = this.getChannel() } } /** An acknowledgment callback when receiving a message. */ @@ -360,9 +357,6 @@ module SocketIO { /** Gets the acknowledgment callback, if any. */ SendCallback getAck() { result.getSendNode() = this } - - /** DEPRECATED. Use `getChannel()` instead. */ - deprecated string getEventName() { result = this.getChannel() } } /** A socket.io namespace, identified by its server and its path. */ @@ -646,9 +640,6 @@ module SocketIOClient { /** Gets the acknowledgment callback, if any. */ DataFlow::FunctionNode getAck() { result.(SendCallback).getSendNode() = this } - - /** DEPRECATED. Use `getChannel()` instead. */ - deprecated string getEventName() { result = this.getChannel() } } /** diff --git a/javascript/ql/lib/semmle/javascript/security/dataflow/MissingRateLimiting.qll b/javascript/ql/lib/semmle/javascript/security/dataflow/MissingRateLimiting.qll index 1eff7fd335e..48ebd032211 100644 --- a/javascript/ql/lib/semmle/javascript/security/dataflow/MissingRateLimiting.qll +++ b/javascript/ql/lib/semmle/javascript/security/dataflow/MissingRateLimiting.qll @@ -40,17 +40,6 @@ abstract class ExpensiveRouteHandler extends DataFlow::Node { abstract predicate explain(string explanation, DataFlow::Node reference, string referenceLabel); } -/** - * DEPRECATED. Use `RateLimitingMiddleware` instead. - * - * A route handler expression that is guarded by a rate limiter. - */ -deprecated class RateLimitedRouteHandlerExpr extends Express::RouteHandlerExpr { - RateLimitedRouteHandlerExpr() { - Routing::getNode(this.flow()).isGuardedBy(any(RateLimitingMiddleware m)) - } -} - // default implementations /** * A route handler that performs an expensive action, and hence should be rate-limited. @@ -99,17 +88,6 @@ class DatabaseAccessAsExpensiveAction extends ExpensiveAction instanceof Databas override string describe() { result = "a database access" } } -/** - * DEPRECATED. Use the `Routing::Node` API instead. - * - * A route handler expression that is rate-limited by a rate-limiting middleware. - */ -deprecated class RouteHandlerExpressionWithRateLimiter extends Expr { - RouteHandlerExpressionWithRateLimiter() { - Routing::getNode(this.flow()).isGuardedBy(any(RateLimitingMiddleware m)) - } -} - /** * The creation of a middleware function that acts as a rate limiter. */ diff --git a/python/ql/lib/semmle/python/xml/XML.qll b/python/ql/lib/semmle/python/xml/XML.qll index d74129d425e..33f4cd9e9e6 100644 --- a/python/ql/lib/semmle/python/xml/XML.qll +++ b/python/ql/lib/semmle/python/xml/XML.qll @@ -108,20 +108,6 @@ class XmlFile extends XmlParent, File { /** Gets the name of this XML file. */ override string getName() { result = File.super.getAbsolutePath() } - /** - * DEPRECATED: Use `getAbsolutePath()` instead. - * - * Gets the path of this XML file. - */ - deprecated string getPath() { result = this.getAbsolutePath() } - - /** - * DEPRECATED: Use `getParentContainer().getAbsolutePath()` instead. - * - * Gets the path of the folder that contains this XML file. - */ - deprecated string getFolder() { result = this.getParentContainer().getAbsolutePath() } - /** Gets the encoding of this XML file. */ string getEncoding() { xmlEncoding(this, result) } diff --git a/ruby/ql/lib/codeql/ruby/ast/Constant.qll b/ruby/ql/lib/codeql/ruby/ast/Constant.qll index 4e2770aab90..b76fac8d47f 100644 --- a/ruby/ql/lib/codeql/ruby/ast/Constant.qll +++ b/ruby/ql/lib/codeql/ruby/ast/Constant.qll @@ -398,12 +398,6 @@ class ConstantWriteAccess extends ConstantAccess { * constant can be ambiguous from just statically looking at the AST. */ string getAQualifiedName() { result = resolveConstantWrite(this) } - - /** - * Gets a qualified name for this constant. Deprecated in favor of - * `getAQualifiedName` because this can return more than one value - */ - deprecated string getQualifiedName() { result = this.getAQualifiedName() } } /** diff --git a/ruby/ql/lib/codeql/ruby/ast/Control.qll b/ruby/ql/lib/codeql/ruby/ast/Control.qll index 2d8f362534d..18182d8268a 100644 --- a/ruby/ql/lib/codeql/ruby/ast/Control.qll +++ b/ruby/ql/lib/codeql/ruby/ast/Control.qll @@ -384,12 +384,6 @@ class CaseExpr extends ControlExpr instanceof CaseExprImpl { */ final AstNode getABranch() { result = this.getBranch(_) } - /** Gets the `n`th `when` branch of this case expression. */ - deprecated final WhenClause getWhenBranch(int n) { result = this.getBranch(n) } - - /** Gets a `when` branch of this case expression. */ - deprecated final WhenClause getAWhenBranch() { result = this.getABranch() } - /** Gets the `else` branch of this case expression, if any. */ final StmtSequence getElseBranch() { result = this.getABranch() } @@ -413,11 +407,6 @@ class CaseExpr extends ControlExpr instanceof CaseExprImpl { } } -/** - * DEPRECATED: Use `WhenClause` instead. - */ -deprecated class WhenExpr = WhenClause; - /** * A `when` branch of a `case` expression. * ```rb diff --git a/ruby/ql/lib/codeql/ruby/ast/Expr.qll b/ruby/ql/lib/codeql/ruby/ast/Expr.qll index 265190ca275..99d955b3400 100644 --- a/ruby/ql/lib/codeql/ruby/ast/Expr.qll +++ b/ruby/ql/lib/codeql/ruby/ast/Expr.qll @@ -22,9 +22,6 @@ class Expr extends Stmt, TExpr { ConstantValue getConstantValue() { result = getConstantValueExpr(this) } } -/** DEPRECATED: Use `SelfVariableAccess` instead. */ -deprecated class Self = SelfVariableAccess; - /** * A sequence of expressions in the right-hand side of an assignment or * a `return`, `break` or `next` statement. diff --git a/ruby/ql/lib/codeql/ruby/ast/Parameter.qll b/ruby/ql/lib/codeql/ruby/ast/Parameter.qll index f67e8566cfc..c4b233b62b6 100644 --- a/ruby/ql/lib/codeql/ruby/ast/Parameter.qll +++ b/ruby/ql/lib/codeql/ruby/ast/Parameter.qll @@ -68,27 +68,6 @@ class DestructuredParameter extends Parameter, TDestructuredParameter { final override string getAPrimaryQlClass() { result = "DestructuredParameter" } } -/** - * DEPRECATED - * - * A parameter defined using a pattern. - * - * This includes both simple parameters and tuple parameters. - */ -deprecated class PatternParameter extends Parameter, Pattern, TPatternParameter { - override LocalVariable getAVariable() { result = Pattern.super.getAVariable() } -} - -/** - * DEPRECATED - * - * A parameter defined using a tuple pattern. - */ -deprecated class TuplePatternParameter extends PatternParameter, TuplePattern, - TDestructuredParameter { - final override LocalVariable getAVariable() { result = TuplePattern.super.getAVariable() } -} - /** A named parameter. */ class NamedParameter extends Parameter, TNamedParameter { /** Gets the name of this parameter. */ diff --git a/ruby/ql/lib/codeql/ruby/ast/Pattern.qll b/ruby/ql/lib/codeql/ruby/ast/Pattern.qll index 884e286c0fa..439881535da 100644 --- a/ruby/ql/lib/codeql/ruby/ast/Pattern.qll +++ b/ruby/ql/lib/codeql/ruby/ast/Pattern.qll @@ -5,78 +5,6 @@ private import internal.TreeSitter private import internal.Variable private import internal.Parameter -/** - * DEPRECATED - * - * A pattern. - */ -deprecated class Pattern extends AstNode { - Pattern() { - explicitAssignmentNode(toGenerated(this), _) - or - implicitAssignmentNode(toGenerated(this)) - or - implicitParameterAssignmentNode(toGenerated(this), _) - or - this = getSynthChild(any(AssignExpr ae), 0) - or - this instanceof SimpleParameterImpl - } - - /** Gets a variable used in (or introduced by) this pattern. */ - Variable getAVariable() { none() } -} - -/** - * DEPRECATED - * - * A simple variable pattern. - */ -deprecated class VariablePattern extends Pattern, LhsExpr, TVariableAccess { - override Variable getAVariable() { result = this.(VariableAccess).getVariable() } -} - -/** - * DEPRECATED - * - * A tuple pattern. - * - * This includes both tuple patterns in parameters and assignments. Example patterns: - * ```rb - * a, self.b = value - * (a, b), c[3] = value - * a, b, *rest, c, d = value - * ``` - */ -deprecated class TuplePattern extends Pattern, TTuplePattern { - private TuplePatternImpl getImpl() { result = toGenerated(this) } - - private Ruby::AstNode getChild(int i) { result = this.getImpl().getChildNode(i) } - - /** Gets the `i`th pattern in this tuple pattern. */ - final Pattern getElement(int i) { - exists(Ruby::AstNode c | c = this.getChild(i) | - toGenerated(result) = c.(Ruby::RestAssignment).getChild() - or - toGenerated(result) = c - ) - } - - /** Gets a sub pattern in this tuple pattern. */ - final Pattern getAnElement() { result = this.getElement(_) } - - /** - * Gets the index of the pattern with the `*` marker on it, if it exists. - * In the example below the index is `2`. - * ```rb - * a, b, *rest, c, d = value - * ``` - */ - final int getRestIndex() { result = this.getImpl().getRestIndex() } - - override Variable getAVariable() { result = this.getElement(_).getAVariable() } -} - private class TPatternNode = TArrayPattern or TFindPattern or THashPattern or TAlternativePattern or TAsPattern or TParenthesizedPattern or TExpressionReferencePattern or TVariableReferencePattern; diff --git a/ruby/ql/lib/codeql/ruby/ast/internal/AST.qll b/ruby/ql/lib/codeql/ruby/ast/internal/AST.qll index 708d9ecf074..4e2853e3a35 100644 --- a/ruby/ql/lib/codeql/ruby/ast/internal/AST.qll +++ b/ruby/ql/lib/codeql/ruby/ast/internal/AST.qll @@ -875,15 +875,10 @@ class TParameter = class TSimpleParameter = TSimpleParameterReal or TSimpleParameterSynth; -deprecated class TPatternParameter = TSimpleParameter or TDestructuredParameter; - class TNamedParameter = TSimpleParameter or TBlockParameter or THashSplatParameter or TKeywordParameter or TOptionalParameter or TSplatParameter; -deprecated class TTuplePattern = - TDestructuredParameter or TDestructuredLeftAssignment or TLeftAssignmentList; - class TVariableAccess = TLocalVariableAccess or TGlobalVariableAccess or TInstanceVariableAccess or TClassVariableAccess or TSelfVariableAccess; diff --git a/ruby/ql/lib/codeql/ruby/ast/internal/Pattern.qll b/ruby/ql/lib/codeql/ruby/ast/internal/Pattern.qll index e25296814c2..c59898d88ee 100644 --- a/ruby/ql/lib/codeql/ruby/ast/internal/Pattern.qll +++ b/ruby/ql/lib/codeql/ruby/ast/internal/Pattern.qll @@ -4,25 +4,6 @@ private import codeql.ruby.ast.internal.Parameter private import AST private import TreeSitter -deprecated class TuplePatternImpl extends Ruby::AstNode { - TuplePatternImpl() { - this instanceof DestructuredParameterImpl or - this instanceof DestructuredLhsExprImpl - } - - Ruby::AstNode getChildNode(int i) { - result = - [ - this.(DestructuredParameterImpl).getChildNode(i), - this.(DestructuredLhsExprImpl).getChildNode(i) - ] - } - - final int getRestIndex() { - result = unique(int i | this.getChildNode(i) instanceof Ruby::RestAssignment) - } -} - /** * Holds if `node` is a case pattern. */ From a928f4c9efd1e796348d37447af46ea04062ea9b Mon Sep 17 00:00:00 2001 From: erik-krogh Date: Fri, 3 Mar 2023 09:19:08 +0100 Subject: [PATCH 019/135] add change-notes --- cpp/ql/lib/change-notes/2023-03-03-delete-deps.md | 12 ++++++++++++ csharp/ql/lib/change-notes/2023-03-03-delete-deps.md | 6 ++++++ java/ql/lib/change-notes/2023-03-03-delete-deps.md | 7 +++++++ .../ql/lib/change-notes/2023-03-03-delete-deps.md | 8 ++++++++ python/ql/lib/change-notes/2023-03-03-delete-deps.md | 4 ++++ ruby/ql/lib/change-notes/2023-03-03-delete-deps.md | 6 ++++++ 6 files changed, 43 insertions(+) create mode 100644 cpp/ql/lib/change-notes/2023-03-03-delete-deps.md create mode 100644 csharp/ql/lib/change-notes/2023-03-03-delete-deps.md create mode 100644 java/ql/lib/change-notes/2023-03-03-delete-deps.md create mode 100644 javascript/ql/lib/change-notes/2023-03-03-delete-deps.md create mode 100644 python/ql/lib/change-notes/2023-03-03-delete-deps.md create mode 100644 ruby/ql/lib/change-notes/2023-03-03-delete-deps.md diff --git a/cpp/ql/lib/change-notes/2023-03-03-delete-deps.md b/cpp/ql/lib/change-notes/2023-03-03-delete-deps.md new file mode 100644 index 00000000000..03efda07926 --- /dev/null +++ b/cpp/ql/lib/change-notes/2023-03-03-delete-deps.md @@ -0,0 +1,12 @@ +--- +category: minorAnalysis +--- +* Deleted the deprecated `hasGeneratedCopyConstructor` and `hasGeneratedCopyAssignmentOperator` predicates from the `Folder` class. +* Deleted the deprecated `getPath` and `getFolder` predicates from the `XmlFile` class. +* Deleted the deprecated `getMustlockFunction`, `getTrylockFunction`, `getLockFunction`, and `getUnlockFunction` predicates from the `MutexType` class. +* Deleted the deprecated `getPosInBasicBlock` predicate from the `SubBasicBlock` class. +* Deleted the deprecated `getExpr` predicate from the `PointerDereferenceExpr` class. +* Deleted the deprecated `getUseInstruction` and `getDefinitionInstruction` predicates from the `Operand` class. +* Deleted the deprecated `isInParameter`, `isInParameterPointer`, and `isInQualifier` predicates from the `FunctionInput` class. +* Deleted the deprecated `isOutParameterPointer`, `isOutQualifier`, `isOutReturnValue`, and `isOutReturnPointer` predicate from the `FunctionOutput` class. +* Deleted the deprecated 3-argument `isGuardPhi` predicate from the `RangeSsaDefinition` class. diff --git a/csharp/ql/lib/change-notes/2023-03-03-delete-deps.md b/csharp/ql/lib/change-notes/2023-03-03-delete-deps.md new file mode 100644 index 00000000000..05ddd56617a --- /dev/null +++ b/csharp/ql/lib/change-notes/2023-03-03-delete-deps.md @@ -0,0 +1,6 @@ +--- +category: minorAnalysis +--- +* Deleted the deprecated `getPath` and `getFolder` predicates from the `XmlFile` class. +* Deleted the deprecated `getAssertionIndex`, `getAssertedParameter`, and `getAssertedParameter` predicates from the `AssertMethod` class. +* Deleted the deprecated `OverridableMethod` and `OverridableAccessor` classes. diff --git a/java/ql/lib/change-notes/2023-03-03-delete-deps.md b/java/ql/lib/change-notes/2023-03-03-delete-deps.md new file mode 100644 index 00000000000..bdc84d43d26 --- /dev/null +++ b/java/ql/lib/change-notes/2023-03-03-delete-deps.md @@ -0,0 +1,7 @@ +--- +category: minorAnalysis +--- +* Deleted the deprecated `getPath` and `getFolder` predicates from the `XmlFile` class. +* Deleted the deprecated `getRepresentedString` predicate from the `StringLiteral` class. +* Deleted the deprecated `ServletWriterSource` class. +* Deleted the deprecated `getGroupID`, `getArtefactID`, and `artefactMatches` predicates from the `MavenRepoJar` class. \ No newline at end of file diff --git a/javascript/ql/lib/change-notes/2023-03-03-delete-deps.md b/javascript/ql/lib/change-notes/2023-03-03-delete-deps.md new file mode 100644 index 00000000000..3ac871fa8a2 --- /dev/null +++ b/javascript/ql/lib/change-notes/2023-03-03-delete-deps.md @@ -0,0 +1,8 @@ +--- +category: minorAnalysis +--- +* Deleted the deprecated `getPath` and `getFolder` predicates from the `XmlFile` class. +* Deleted the deprecated `getId` from the `Function`, `NamespaceDefinition`, and `ImportEqualsDeclaration` classes. +* Deleted the deprecated `flowsTo` predicate from the `HTTP::Servers::RequestSource` and `HTTP::Servers::ResponseSource` class. +* Deleted the deprecated `getEventName` predicate from the `SocketIO::ReceiveNode`, `SocketIO::SendNode`, `SocketIOClient::SendNode` classes. +* Deleted the deprecated `RateLimitedRouteHandlerExpr` and `RouteHandlerExpressionWithRateLimiter` classes. \ No newline at end of file diff --git a/python/ql/lib/change-notes/2023-03-03-delete-deps.md b/python/ql/lib/change-notes/2023-03-03-delete-deps.md new file mode 100644 index 00000000000..887db05e8c9 --- /dev/null +++ b/python/ql/lib/change-notes/2023-03-03-delete-deps.md @@ -0,0 +1,4 @@ +--- +category: minorAnalysis +--- +* Deleted the deprecated `getPath` and `getFolder` predicates from the `XmlFile` class. \ No newline at end of file diff --git a/ruby/ql/lib/change-notes/2023-03-03-delete-deps.md b/ruby/ql/lib/change-notes/2023-03-03-delete-deps.md new file mode 100644 index 00000000000..aab1e76bf70 --- /dev/null +++ b/ruby/ql/lib/change-notes/2023-03-03-delete-deps.md @@ -0,0 +1,6 @@ +--- +category: minorAnalysis +--- +* Deleted the deprecated `getQualifiedName` predicate from the `ConstantWriteAccess` class. +* Deleted the deprecated `getWhenBranch` and `getAWhenBranch` predicates from the `CaseExpr` class. +* Deleted the deprecated `Self`, `PatternParameter`, `Pattern`, `VariablePattern`, `TuplePattern`, and `TuplePatternParameter` classes. \ No newline at end of file From 5fdc293d82071478e3772912c4f9d42ddcff1206 Mon Sep 17 00:00:00 2001 From: Asger F Date: Wed, 1 Mar 2023 15:30:06 +0100 Subject: [PATCH 020/135] JS: Add trap test for import assertions --- .../tests/esnext/input/import-assertion.js | 13 +++++++++++++ .../esnext/output/trap/import-assertion.js.trap | 0 2 files changed, 13 insertions(+) create mode 100644 javascript/extractor/tests/esnext/input/import-assertion.js create mode 100644 javascript/extractor/tests/esnext/output/trap/import-assertion.js.trap diff --git a/javascript/extractor/tests/esnext/input/import-assertion.js b/javascript/extractor/tests/esnext/input/import-assertion.js new file mode 100644 index 00000000000..23c030be511 --- /dev/null +++ b/javascript/extractor/tests/esnext/input/import-assertion.js @@ -0,0 +1,13 @@ +import "module" assert { type: "json" }; +import * as v1 from "module" assert { type: "json" }; +import { v2 } from "module" assert { type: "json" }; +import v3 from "module" assert { type: "json" }; + +export { v4 } from "module" assert { type: "json" }; +export * from "module" assert { type: "json" }; +export * as v5 from "module" assert { type: "json" }; + +const v6 = import("module", { assert: { type: "json" } }); + +import "module" // missing semicolon +assert({type: "json"}); // function call, not import assertion diff --git a/javascript/extractor/tests/esnext/output/trap/import-assertion.js.trap b/javascript/extractor/tests/esnext/output/trap/import-assertion.js.trap new file mode 100644 index 00000000000..e69de29bb2d From c715de2a1000e6669a0e5f70d245b97d088a95c8 Mon Sep 17 00:00:00 2001 From: Asger F Date: Thu, 2 Mar 2023 13:10:59 +0100 Subject: [PATCH 021/135] JS: parse import assertions without storing in AST --- .../src/com/semmle/jcorn/ESNextParser.java | 6 + .../src/com/semmle/jcorn/Parser.java | 30 +- .../src/com/semmle/jcorn/flow/FlowParser.java | 2 + .../output/trap/import-assertion.js.trap | 1047 +++++++++++++++++ 4 files changed, 1081 insertions(+), 4 deletions(-) diff --git a/javascript/extractor/src/com/semmle/jcorn/ESNextParser.java b/javascript/extractor/src/com/semmle/jcorn/ESNextParser.java index e88f6c2321f..eff8cae5803 100644 --- a/javascript/extractor/src/com/semmle/jcorn/ESNextParser.java +++ b/javascript/extractor/src/com/semmle/jcorn/ESNextParser.java @@ -314,6 +314,7 @@ public class ESNextParser extends JSXParser { this.parseExportSpecifiersMaybe(specifiers, exports); } Literal source = (Literal) this.parseExportFrom(specifiers, null, true); + Expression assertion = this.parseImportOrExportAssertionAndSemicolon(); // TODO: store in AST return this.finishNode(new ExportNamedDeclaration(exportStart, null, specifiers, source)); } @@ -330,6 +331,7 @@ public class ESNextParser extends JSXParser { List specifiers = CollectionUtil.makeList(nsSpec); this.parseExportSpecifiersMaybe(specifiers, exports); Literal source = (Literal) this.parseExportFrom(specifiers, null, true); + Expression assertion = this.parseImportOrExportAssertionAndSemicolon(); // TODO: store in AST return this.finishNode(new ExportNamedDeclaration(exportStart, null, specifiers, source)); } @@ -435,6 +437,10 @@ public class ESNextParser extends JSXParser { */ private DynamicImport parseDynamicImport(Position startLoc) { Expression source = parseMaybeAssign(false, null, null); + Expression assertion = null; + if (this.eat(TokenType.comma)) { + assertion = this.parseMaybeAssign(false, null, null); // TODO: store in AST + } this.expect(TokenType.parenR); DynamicImport di = this.finishNode(new DynamicImport(new SourceLocation(startLoc), source)); return di; diff --git a/javascript/extractor/src/com/semmle/jcorn/Parser.java b/javascript/extractor/src/com/semmle/jcorn/Parser.java index 3b9b184a988..135c5221eb5 100644 --- a/javascript/extractor/src/com/semmle/jcorn/Parser.java +++ b/javascript/extractor/src/com/semmle/jcorn/Parser.java @@ -2783,7 +2783,7 @@ public class Parser { boolean isBreak = keyword.equals("break"); this.next(); Identifier label = null; - if (this.eat(TokenType.semi) || this.insertSemicolon()) { + if (this.eagerlyTrySemicolon()) { label = null; } else if (this.type != TokenType.name) { this.unexpected(); @@ -2893,6 +2893,15 @@ public class Parser { new IfStatement(new SourceLocation(startLoc), test, consequent, alternate)); } + /** + * Consumes or inserts a semicolon if possible, and returns true if a semicolon was consumed or inserted. + * + * Returns false if there was no semicolon and insertion was not possible. + */ + protected boolean eagerlyTrySemicolon() { + return this.eat(TokenType.semi) || this.insertSemicolon(); + } + protected ReturnStatement parseReturnStatement(Position startLoc) { if (!this.inFunction && !this.options.allowReturnOutsideFunction()) this.raise(this.start, "'return' outside of function"); @@ -2902,7 +2911,7 @@ public class Parser { // optional arguments, we eagerly look for a semicolon or the // possibility to insert one. Expression argument; - if (this.eat(TokenType.semi) || this.insertSemicolon()) { + if (this.eagerlyTrySemicolon()) { argument = null; } else { argument = this.parseExpression(false, null); @@ -3404,6 +3413,7 @@ public class Parser { Statement declaration; List specifiers; Expression source = null; + Expression assertion = null; if (this.shouldParseExportStatement()) { declaration = this.parseStatement(true, false); if (declaration == null) return null; @@ -3419,11 +3429,13 @@ public class Parser { declaration = null; specifiers = this.parseExportSpecifiers(exports); source = parseExportFrom(specifiers, source, false); + assertion = parseImportOrExportAssertionAndSemicolon(); // TODO: store in AST } return this.finishNode( new ExportNamedDeclaration(loc, declaration, specifiers, (Literal) source)); } + /** Parses the 'from' clause of an export, not including the assertion or semicolon. */ protected Expression parseExportFrom( List specifiers, Expression source, boolean expectFrom) { if (this.eatContextual("from")) { @@ -3442,13 +3454,13 @@ public class Parser { source = null; } - this.semicolon(); return source; } protected ExportDeclaration parseExportAll( SourceLocation loc, Position starLoc, Set exports) { Expression source = parseExportFrom(null, null, true); + Expression assertion = parseImportOrExportAssertionAndSemicolon(); // TODO: store in AST return this.finishNode(new ExportAllDeclaration(loc, (Literal) source)); } @@ -3514,6 +3526,16 @@ public class Parser { return parseImportRest(loc); } + protected Expression parseImportOrExportAssertionAndSemicolon() { + Expression result = null; + if (!this.eagerlyTrySemicolon()) { + this.expectContextual("assert"); + result = this.parseObj(false, null); + this.semicolon(); + } + return result; + } + protected ImportDeclaration parseImportRest(SourceLocation loc) { List specifiers; Literal source; @@ -3527,7 +3549,7 @@ public class Parser { if (this.type != TokenType.string) this.unexpected(); source = (Literal) this.parseExprAtom(null); } - this.semicolon(); + Expression assertion = this.parseImportOrExportAssertionAndSemicolon(); // TODO: store in AST if (specifiers == null) return null; return this.finishNode(new ImportDeclaration(loc, specifiers, source)); } diff --git a/javascript/extractor/src/com/semmle/jcorn/flow/FlowParser.java b/javascript/extractor/src/com/semmle/jcorn/flow/FlowParser.java index 7b01f40bee5..8785eb111bf 100644 --- a/javascript/extractor/src/com/semmle/jcorn/flow/FlowParser.java +++ b/javascript/extractor/src/com/semmle/jcorn/flow/FlowParser.java @@ -943,10 +943,12 @@ public class FlowParser extends ESNextParser { // `export type { foo, bar };` List specifiers = this.parseExportSpecifiers(exports); this.parseExportFrom(specifiers, null, false); + this.parseImportOrExportAssertionAndSemicolon(); // TODO: store in AST? return null; } else if (this.eat(TokenType.star)) { if (this.eatContextual("as")) this.parseIdent(true); this.parseExportFrom(null, null, true); + this.parseImportOrExportAssertionAndSemicolon(); // TODO: store in AST? return null; } else { // `export type Foo = Bar;` diff --git a/javascript/extractor/tests/esnext/output/trap/import-assertion.js.trap b/javascript/extractor/tests/esnext/output/trap/import-assertion.js.trap index e69de29bb2d..4ab0cc54f6d 100644 --- a/javascript/extractor/tests/esnext/output/trap/import-assertion.js.trap +++ b/javascript/extractor/tests/esnext/output/trap/import-assertion.js.trap @@ -0,0 +1,1047 @@ +#10000=@"/import-assertion.js;sourcefile" +files(#10000,"/import-assertion.js") +#10001=@"/;folder" +folders(#10001,"/") +containerparent(#10001,#10000) +#10002=@"loc,{#10000},0,0,0,0" +locations_default(#10002,#10000,0,0,0,0) +hasLocation(#10000,#10002) +#20000=@"global_scope" +scopes(#20000,0) +#20001=@"script;{#10000},1,1" +#20002=* +comments(#20002,0,#20001," missing semicolon","// missing semicolon") +#20003=@"loc,{#10000},12,17,12,36" +locations_default(#20003,#10000,12,17,12,36) +hasLocation(#20002,#20003) +#20004=* +comments(#20004,0,#20001," function call, not import assertion","// func ... sertion") +#20005=@"loc,{#10000},13,25,13,62" +locations_default(#20005,#10000,13,25,13,62) +hasLocation(#20004,#20005) +#20006=* +lines(#20006,#20001,"import ""module"" assert { type: ""json"" };"," +") +#20007=@"loc,{#10000},1,1,1,40" +locations_default(#20007,#10000,1,1,1,40) +hasLocation(#20006,#20007) +#20008=* +lines(#20008,#20001,"import * as v1 from ""module"" assert { type: ""json"" };"," +") +#20009=@"loc,{#10000},2,1,2,53" +locations_default(#20009,#10000,2,1,2,53) +hasLocation(#20008,#20009) +#20010=* +lines(#20010,#20001,"import { v2 } from ""module"" assert { type: ""json"" };"," +") +#20011=@"loc,{#10000},3,1,3,52" +locations_default(#20011,#10000,3,1,3,52) +hasLocation(#20010,#20011) +#20012=* +lines(#20012,#20001,"import v3 from ""module"" assert { type: ""json"" };"," +") +#20013=@"loc,{#10000},4,1,4,48" +locations_default(#20013,#10000,4,1,4,48) +hasLocation(#20012,#20013) +#20014=* +lines(#20014,#20001,""," +") +#20015=@"loc,{#10000},5,1,5,0" +locations_default(#20015,#10000,5,1,5,0) +hasLocation(#20014,#20015) +#20016=* +lines(#20016,#20001,"export { v4 } from ""module"" assert { type: ""json"" };"," +") +#20017=@"loc,{#10000},6,1,6,52" +locations_default(#20017,#10000,6,1,6,52) +hasLocation(#20016,#20017) +#20018=* +lines(#20018,#20001,"export * from ""module"" assert { type: ""json"" };"," +") +#20019=@"loc,{#10000},7,1,7,47" +locations_default(#20019,#10000,7,1,7,47) +hasLocation(#20018,#20019) +#20020=* +lines(#20020,#20001,"export * as v5 from ""module"" assert { type: ""json"" };"," +") +#20021=@"loc,{#10000},8,1,8,53" +locations_default(#20021,#10000,8,1,8,53) +hasLocation(#20020,#20021) +#20022=* +lines(#20022,#20001,""," +") +#20023=@"loc,{#10000},9,1,9,0" +locations_default(#20023,#10000,9,1,9,0) +hasLocation(#20022,#20023) +#20024=* +lines(#20024,#20001,"const v6 = import(""module"", { assert: { type: ""json"" } });"," +") +#20025=@"loc,{#10000},10,1,10,58" +locations_default(#20025,#10000,10,1,10,58) +hasLocation(#20024,#20025) +#20026=* +lines(#20026,#20001,""," +") +#20027=@"loc,{#10000},11,1,11,0" +locations_default(#20027,#10000,11,1,11,0) +hasLocation(#20026,#20027) +#20028=* +lines(#20028,#20001,"import ""module"" // missing semicolon"," +") +#20029=@"loc,{#10000},12,1,12,36" +locations_default(#20029,#10000,12,1,12,36) +hasLocation(#20028,#20029) +#20030=* +lines(#20030,#20001,"assert({type: ""json""}); // function call, not import assertion"," +") +#20031=@"loc,{#10000},13,1,13,62" +locations_default(#20031,#10000,13,1,13,62) +hasLocation(#20030,#20031) +numlines(#20001,13,10,2) +#20032=* +tokeninfo(#20032,7,#20001,0,"import") +#20033=@"loc,{#10000},1,1,1,6" +locations_default(#20033,#10000,1,1,1,6) +hasLocation(#20032,#20033) +#20034=* +tokeninfo(#20034,4,#20001,1,"""module""") +#20035=@"loc,{#10000},1,8,1,15" +locations_default(#20035,#10000,1,8,1,15) +hasLocation(#20034,#20035) +#20036=* +tokeninfo(#20036,6,#20001,2,"assert") +#20037=@"loc,{#10000},1,17,1,22" +locations_default(#20037,#10000,1,17,1,22) +hasLocation(#20036,#20037) +#20038=* +tokeninfo(#20038,8,#20001,3,"{") +#20039=@"loc,{#10000},1,24,1,24" +locations_default(#20039,#10000,1,24,1,24) +hasLocation(#20038,#20039) +#20040=* +tokeninfo(#20040,6,#20001,4,"type") +#20041=@"loc,{#10000},1,26,1,29" +locations_default(#20041,#10000,1,26,1,29) +hasLocation(#20040,#20041) +#20042=* +tokeninfo(#20042,8,#20001,5,":") +#20043=@"loc,{#10000},1,30,1,30" +locations_default(#20043,#10000,1,30,1,30) +hasLocation(#20042,#20043) +#20044=* +tokeninfo(#20044,4,#20001,6,"""json""") +#20045=@"loc,{#10000},1,32,1,37" +locations_default(#20045,#10000,1,32,1,37) +hasLocation(#20044,#20045) +#20046=* +tokeninfo(#20046,8,#20001,7,"}") +#20047=@"loc,{#10000},1,39,1,39" +locations_default(#20047,#10000,1,39,1,39) +hasLocation(#20046,#20047) +#20048=* +tokeninfo(#20048,8,#20001,8,";") +#20049=@"loc,{#10000},1,40,1,40" +locations_default(#20049,#10000,1,40,1,40) +hasLocation(#20048,#20049) +#20050=* +tokeninfo(#20050,7,#20001,9,"import") +#20051=@"loc,{#10000},2,1,2,6" +locations_default(#20051,#10000,2,1,2,6) +hasLocation(#20050,#20051) +#20052=* +tokeninfo(#20052,8,#20001,10,"*") +#20053=@"loc,{#10000},2,8,2,8" +locations_default(#20053,#10000,2,8,2,8) +hasLocation(#20052,#20053) +#20054=* +tokeninfo(#20054,6,#20001,11,"as") +#20055=@"loc,{#10000},2,10,2,11" +locations_default(#20055,#10000,2,10,2,11) +hasLocation(#20054,#20055) +#20056=* +tokeninfo(#20056,6,#20001,12,"v1") +#20057=@"loc,{#10000},2,13,2,14" +locations_default(#20057,#10000,2,13,2,14) +hasLocation(#20056,#20057) +#20058=* +tokeninfo(#20058,6,#20001,13,"from") +#20059=@"loc,{#10000},2,16,2,19" +locations_default(#20059,#10000,2,16,2,19) +hasLocation(#20058,#20059) +#20060=* +tokeninfo(#20060,4,#20001,14,"""module""") +#20061=@"loc,{#10000},2,21,2,28" +locations_default(#20061,#10000,2,21,2,28) +hasLocation(#20060,#20061) +#20062=* +tokeninfo(#20062,6,#20001,15,"assert") +#20063=@"loc,{#10000},2,30,2,35" +locations_default(#20063,#10000,2,30,2,35) +hasLocation(#20062,#20063) +#20064=* +tokeninfo(#20064,8,#20001,16,"{") +#20065=@"loc,{#10000},2,37,2,37" +locations_default(#20065,#10000,2,37,2,37) +hasLocation(#20064,#20065) +#20066=* +tokeninfo(#20066,6,#20001,17,"type") +#20067=@"loc,{#10000},2,39,2,42" +locations_default(#20067,#10000,2,39,2,42) +hasLocation(#20066,#20067) +#20068=* +tokeninfo(#20068,8,#20001,18,":") +#20069=@"loc,{#10000},2,43,2,43" +locations_default(#20069,#10000,2,43,2,43) +hasLocation(#20068,#20069) +#20070=* +tokeninfo(#20070,4,#20001,19,"""json""") +#20071=@"loc,{#10000},2,45,2,50" +locations_default(#20071,#10000,2,45,2,50) +hasLocation(#20070,#20071) +#20072=* +tokeninfo(#20072,8,#20001,20,"}") +#20073=@"loc,{#10000},2,52,2,52" +locations_default(#20073,#10000,2,52,2,52) +hasLocation(#20072,#20073) +#20074=* +tokeninfo(#20074,8,#20001,21,";") +#20075=@"loc,{#10000},2,53,2,53" +locations_default(#20075,#10000,2,53,2,53) +hasLocation(#20074,#20075) +#20076=* +tokeninfo(#20076,7,#20001,22,"import") +#20077=@"loc,{#10000},3,1,3,6" +locations_default(#20077,#10000,3,1,3,6) +hasLocation(#20076,#20077) +#20078=* +tokeninfo(#20078,8,#20001,23,"{") +#20079=@"loc,{#10000},3,8,3,8" +locations_default(#20079,#10000,3,8,3,8) +hasLocation(#20078,#20079) +#20080=* +tokeninfo(#20080,6,#20001,24,"v2") +#20081=@"loc,{#10000},3,10,3,11" +locations_default(#20081,#10000,3,10,3,11) +hasLocation(#20080,#20081) +#20082=* +tokeninfo(#20082,8,#20001,25,"}") +#20083=@"loc,{#10000},3,13,3,13" +locations_default(#20083,#10000,3,13,3,13) +hasLocation(#20082,#20083) +#20084=* +tokeninfo(#20084,6,#20001,26,"from") +#20085=@"loc,{#10000},3,15,3,18" +locations_default(#20085,#10000,3,15,3,18) +hasLocation(#20084,#20085) +#20086=* +tokeninfo(#20086,4,#20001,27,"""module""") +#20087=@"loc,{#10000},3,20,3,27" +locations_default(#20087,#10000,3,20,3,27) +hasLocation(#20086,#20087) +#20088=* +tokeninfo(#20088,6,#20001,28,"assert") +#20089=@"loc,{#10000},3,29,3,34" +locations_default(#20089,#10000,3,29,3,34) +hasLocation(#20088,#20089) +#20090=* +tokeninfo(#20090,8,#20001,29,"{") +#20091=@"loc,{#10000},3,36,3,36" +locations_default(#20091,#10000,3,36,3,36) +hasLocation(#20090,#20091) +#20092=* +tokeninfo(#20092,6,#20001,30,"type") +#20093=@"loc,{#10000},3,38,3,41" +locations_default(#20093,#10000,3,38,3,41) +hasLocation(#20092,#20093) +#20094=* +tokeninfo(#20094,8,#20001,31,":") +#20095=@"loc,{#10000},3,42,3,42" +locations_default(#20095,#10000,3,42,3,42) +hasLocation(#20094,#20095) +#20096=* +tokeninfo(#20096,4,#20001,32,"""json""") +#20097=@"loc,{#10000},3,44,3,49" +locations_default(#20097,#10000,3,44,3,49) +hasLocation(#20096,#20097) +#20098=* +tokeninfo(#20098,8,#20001,33,"}") +#20099=@"loc,{#10000},3,51,3,51" +locations_default(#20099,#10000,3,51,3,51) +hasLocation(#20098,#20099) +#20100=* +tokeninfo(#20100,8,#20001,34,";") +#20101=@"loc,{#10000},3,52,3,52" +locations_default(#20101,#10000,3,52,3,52) +hasLocation(#20100,#20101) +#20102=* +tokeninfo(#20102,7,#20001,35,"import") +#20103=@"loc,{#10000},4,1,4,6" +locations_default(#20103,#10000,4,1,4,6) +hasLocation(#20102,#20103) +#20104=* +tokeninfo(#20104,6,#20001,36,"v3") +#20105=@"loc,{#10000},4,8,4,9" +locations_default(#20105,#10000,4,8,4,9) +hasLocation(#20104,#20105) +#20106=* +tokeninfo(#20106,6,#20001,37,"from") +#20107=@"loc,{#10000},4,11,4,14" +locations_default(#20107,#10000,4,11,4,14) +hasLocation(#20106,#20107) +#20108=* +tokeninfo(#20108,4,#20001,38,"""module""") +#20109=@"loc,{#10000},4,16,4,23" +locations_default(#20109,#10000,4,16,4,23) +hasLocation(#20108,#20109) +#20110=* +tokeninfo(#20110,6,#20001,39,"assert") +#20111=@"loc,{#10000},4,25,4,30" +locations_default(#20111,#10000,4,25,4,30) +hasLocation(#20110,#20111) +#20112=* +tokeninfo(#20112,8,#20001,40,"{") +#20113=@"loc,{#10000},4,32,4,32" +locations_default(#20113,#10000,4,32,4,32) +hasLocation(#20112,#20113) +#20114=* +tokeninfo(#20114,6,#20001,41,"type") +#20115=@"loc,{#10000},4,34,4,37" +locations_default(#20115,#10000,4,34,4,37) +hasLocation(#20114,#20115) +#20116=* +tokeninfo(#20116,8,#20001,42,":") +#20117=@"loc,{#10000},4,38,4,38" +locations_default(#20117,#10000,4,38,4,38) +hasLocation(#20116,#20117) +#20118=* +tokeninfo(#20118,4,#20001,43,"""json""") +#20119=@"loc,{#10000},4,40,4,45" +locations_default(#20119,#10000,4,40,4,45) +hasLocation(#20118,#20119) +#20120=* +tokeninfo(#20120,8,#20001,44,"}") +#20121=@"loc,{#10000},4,47,4,47" +locations_default(#20121,#10000,4,47,4,47) +hasLocation(#20120,#20121) +#20122=* +tokeninfo(#20122,8,#20001,45,";") +#20123=@"loc,{#10000},4,48,4,48" +locations_default(#20123,#10000,4,48,4,48) +hasLocation(#20122,#20123) +#20124=* +tokeninfo(#20124,7,#20001,46,"export") +#20125=@"loc,{#10000},6,1,6,6" +locations_default(#20125,#10000,6,1,6,6) +hasLocation(#20124,#20125) +#20126=* +tokeninfo(#20126,8,#20001,47,"{") +#20127=@"loc,{#10000},6,8,6,8" +locations_default(#20127,#10000,6,8,6,8) +hasLocation(#20126,#20127) +#20128=* +tokeninfo(#20128,6,#20001,48,"v4") +#20129=@"loc,{#10000},6,10,6,11" +locations_default(#20129,#10000,6,10,6,11) +hasLocation(#20128,#20129) +#20130=* +tokeninfo(#20130,8,#20001,49,"}") +#20131=@"loc,{#10000},6,13,6,13" +locations_default(#20131,#10000,6,13,6,13) +hasLocation(#20130,#20131) +#20132=* +tokeninfo(#20132,6,#20001,50,"from") +#20133=@"loc,{#10000},6,15,6,18" +locations_default(#20133,#10000,6,15,6,18) +hasLocation(#20132,#20133) +#20134=* +tokeninfo(#20134,4,#20001,51,"""module""") +#20135=@"loc,{#10000},6,20,6,27" +locations_default(#20135,#10000,6,20,6,27) +hasLocation(#20134,#20135) +#20136=* +tokeninfo(#20136,6,#20001,52,"assert") +#20137=@"loc,{#10000},6,29,6,34" +locations_default(#20137,#10000,6,29,6,34) +hasLocation(#20136,#20137) +#20138=* +tokeninfo(#20138,8,#20001,53,"{") +#20139=@"loc,{#10000},6,36,6,36" +locations_default(#20139,#10000,6,36,6,36) +hasLocation(#20138,#20139) +#20140=* +tokeninfo(#20140,6,#20001,54,"type") +#20141=@"loc,{#10000},6,38,6,41" +locations_default(#20141,#10000,6,38,6,41) +hasLocation(#20140,#20141) +#20142=* +tokeninfo(#20142,8,#20001,55,":") +#20143=@"loc,{#10000},6,42,6,42" +locations_default(#20143,#10000,6,42,6,42) +hasLocation(#20142,#20143) +#20144=* +tokeninfo(#20144,4,#20001,56,"""json""") +#20145=@"loc,{#10000},6,44,6,49" +locations_default(#20145,#10000,6,44,6,49) +hasLocation(#20144,#20145) +#20146=* +tokeninfo(#20146,8,#20001,57,"}") +#20147=@"loc,{#10000},6,51,6,51" +locations_default(#20147,#10000,6,51,6,51) +hasLocation(#20146,#20147) +#20148=* +tokeninfo(#20148,8,#20001,58,";") +#20149=@"loc,{#10000},6,52,6,52" +locations_default(#20149,#10000,6,52,6,52) +hasLocation(#20148,#20149) +#20150=* +tokeninfo(#20150,7,#20001,59,"export") +#20151=@"loc,{#10000},7,1,7,6" +locations_default(#20151,#10000,7,1,7,6) +hasLocation(#20150,#20151) +#20152=* +tokeninfo(#20152,8,#20001,60,"*") +#20153=@"loc,{#10000},7,8,7,8" +locations_default(#20153,#10000,7,8,7,8) +hasLocation(#20152,#20153) +#20154=* +tokeninfo(#20154,6,#20001,61,"from") +#20155=@"loc,{#10000},7,10,7,13" +locations_default(#20155,#10000,7,10,7,13) +hasLocation(#20154,#20155) +#20156=* +tokeninfo(#20156,4,#20001,62,"""module""") +#20157=@"loc,{#10000},7,15,7,22" +locations_default(#20157,#10000,7,15,7,22) +hasLocation(#20156,#20157) +#20158=* +tokeninfo(#20158,6,#20001,63,"assert") +#20159=@"loc,{#10000},7,24,7,29" +locations_default(#20159,#10000,7,24,7,29) +hasLocation(#20158,#20159) +#20160=* +tokeninfo(#20160,8,#20001,64,"{") +#20161=@"loc,{#10000},7,31,7,31" +locations_default(#20161,#10000,7,31,7,31) +hasLocation(#20160,#20161) +#20162=* +tokeninfo(#20162,6,#20001,65,"type") +#20163=@"loc,{#10000},7,33,7,36" +locations_default(#20163,#10000,7,33,7,36) +hasLocation(#20162,#20163) +#20164=* +tokeninfo(#20164,8,#20001,66,":") +#20165=@"loc,{#10000},7,37,7,37" +locations_default(#20165,#10000,7,37,7,37) +hasLocation(#20164,#20165) +#20166=* +tokeninfo(#20166,4,#20001,67,"""json""") +#20167=@"loc,{#10000},7,39,7,44" +locations_default(#20167,#10000,7,39,7,44) +hasLocation(#20166,#20167) +#20168=* +tokeninfo(#20168,8,#20001,68,"}") +#20169=@"loc,{#10000},7,46,7,46" +locations_default(#20169,#10000,7,46,7,46) +hasLocation(#20168,#20169) +#20170=* +tokeninfo(#20170,8,#20001,69,";") +#20171=@"loc,{#10000},7,47,7,47" +locations_default(#20171,#10000,7,47,7,47) +hasLocation(#20170,#20171) +#20172=* +tokeninfo(#20172,7,#20001,70,"export") +#20173=@"loc,{#10000},8,1,8,6" +locations_default(#20173,#10000,8,1,8,6) +hasLocation(#20172,#20173) +#20174=* +tokeninfo(#20174,8,#20001,71,"*") +#20175=@"loc,{#10000},8,8,8,8" +locations_default(#20175,#10000,8,8,8,8) +hasLocation(#20174,#20175) +#20176=* +tokeninfo(#20176,6,#20001,72,"as") +#20177=@"loc,{#10000},8,10,8,11" +locations_default(#20177,#10000,8,10,8,11) +hasLocation(#20176,#20177) +#20178=* +tokeninfo(#20178,6,#20001,73,"v5") +#20179=@"loc,{#10000},8,13,8,14" +locations_default(#20179,#10000,8,13,8,14) +hasLocation(#20178,#20179) +#20180=* +tokeninfo(#20180,6,#20001,74,"from") +#20181=@"loc,{#10000},8,16,8,19" +locations_default(#20181,#10000,8,16,8,19) +hasLocation(#20180,#20181) +#20182=* +tokeninfo(#20182,4,#20001,75,"""module""") +#20183=@"loc,{#10000},8,21,8,28" +locations_default(#20183,#10000,8,21,8,28) +hasLocation(#20182,#20183) +#20184=* +tokeninfo(#20184,6,#20001,76,"assert") +#20185=@"loc,{#10000},8,30,8,35" +locations_default(#20185,#10000,8,30,8,35) +hasLocation(#20184,#20185) +#20186=* +tokeninfo(#20186,8,#20001,77,"{") +#20187=@"loc,{#10000},8,37,8,37" +locations_default(#20187,#10000,8,37,8,37) +hasLocation(#20186,#20187) +#20188=* +tokeninfo(#20188,6,#20001,78,"type") +#20189=@"loc,{#10000},8,39,8,42" +locations_default(#20189,#10000,8,39,8,42) +hasLocation(#20188,#20189) +#20190=* +tokeninfo(#20190,8,#20001,79,":") +#20191=@"loc,{#10000},8,43,8,43" +locations_default(#20191,#10000,8,43,8,43) +hasLocation(#20190,#20191) +#20192=* +tokeninfo(#20192,4,#20001,80,"""json""") +#20193=@"loc,{#10000},8,45,8,50" +locations_default(#20193,#10000,8,45,8,50) +hasLocation(#20192,#20193) +#20194=* +tokeninfo(#20194,8,#20001,81,"}") +#20195=@"loc,{#10000},8,52,8,52" +locations_default(#20195,#10000,8,52,8,52) +hasLocation(#20194,#20195) +#20196=* +tokeninfo(#20196,8,#20001,82,";") +#20197=@"loc,{#10000},8,53,8,53" +locations_default(#20197,#10000,8,53,8,53) +hasLocation(#20196,#20197) +#20198=* +tokeninfo(#20198,7,#20001,83,"const") +#20199=@"loc,{#10000},10,1,10,5" +locations_default(#20199,#10000,10,1,10,5) +hasLocation(#20198,#20199) +#20200=* +tokeninfo(#20200,6,#20001,84,"v6") +#20201=@"loc,{#10000},10,7,10,8" +locations_default(#20201,#10000,10,7,10,8) +hasLocation(#20200,#20201) +#20202=* +tokeninfo(#20202,8,#20001,85,"=") +#20203=@"loc,{#10000},10,10,10,10" +locations_default(#20203,#10000,10,10,10,10) +hasLocation(#20202,#20203) +#20204=* +tokeninfo(#20204,7,#20001,86,"import") +#20205=@"loc,{#10000},10,12,10,17" +locations_default(#20205,#10000,10,12,10,17) +hasLocation(#20204,#20205) +#20206=* +tokeninfo(#20206,8,#20001,87,"(") +#20207=@"loc,{#10000},10,18,10,18" +locations_default(#20207,#10000,10,18,10,18) +hasLocation(#20206,#20207) +#20208=* +tokeninfo(#20208,4,#20001,88,"""module""") +#20209=@"loc,{#10000},10,19,10,26" +locations_default(#20209,#10000,10,19,10,26) +hasLocation(#20208,#20209) +#20210=* +tokeninfo(#20210,8,#20001,89,",") +#20211=@"loc,{#10000},10,27,10,27" +locations_default(#20211,#10000,10,27,10,27) +hasLocation(#20210,#20211) +#20212=* +tokeninfo(#20212,8,#20001,90,"{") +#20213=@"loc,{#10000},10,29,10,29" +locations_default(#20213,#10000,10,29,10,29) +hasLocation(#20212,#20213) +#20214=* +tokeninfo(#20214,6,#20001,91,"assert") +#20215=@"loc,{#10000},10,31,10,36" +locations_default(#20215,#10000,10,31,10,36) +hasLocation(#20214,#20215) +#20216=* +tokeninfo(#20216,8,#20001,92,":") +#20217=@"loc,{#10000},10,37,10,37" +locations_default(#20217,#10000,10,37,10,37) +hasLocation(#20216,#20217) +#20218=* +tokeninfo(#20218,8,#20001,93,"{") +#20219=@"loc,{#10000},10,39,10,39" +locations_default(#20219,#10000,10,39,10,39) +hasLocation(#20218,#20219) +#20220=* +tokeninfo(#20220,6,#20001,94,"type") +#20221=@"loc,{#10000},10,41,10,44" +locations_default(#20221,#10000,10,41,10,44) +hasLocation(#20220,#20221) +#20222=* +tokeninfo(#20222,8,#20001,95,":") +#20223=@"loc,{#10000},10,45,10,45" +locations_default(#20223,#10000,10,45,10,45) +hasLocation(#20222,#20223) +#20224=* +tokeninfo(#20224,4,#20001,96,"""json""") +#20225=@"loc,{#10000},10,47,10,52" +locations_default(#20225,#10000,10,47,10,52) +hasLocation(#20224,#20225) +#20226=* +tokeninfo(#20226,8,#20001,97,"}") +#20227=@"loc,{#10000},10,54,10,54" +locations_default(#20227,#10000,10,54,10,54) +hasLocation(#20226,#20227) +#20228=* +tokeninfo(#20228,8,#20001,98,"}") +#20229=@"loc,{#10000},10,56,10,56" +locations_default(#20229,#10000,10,56,10,56) +hasLocation(#20228,#20229) +#20230=* +tokeninfo(#20230,8,#20001,99,")") +#20231=@"loc,{#10000},10,57,10,57" +locations_default(#20231,#10000,10,57,10,57) +hasLocation(#20230,#20231) +#20232=* +tokeninfo(#20232,8,#20001,100,";") +#20233=@"loc,{#10000},10,58,10,58" +locations_default(#20233,#10000,10,58,10,58) +hasLocation(#20232,#20233) +#20234=* +tokeninfo(#20234,7,#20001,101,"import") +#20235=@"loc,{#10000},12,1,12,6" +locations_default(#20235,#10000,12,1,12,6) +hasLocation(#20234,#20235) +#20236=* +tokeninfo(#20236,4,#20001,102,"""module""") +#20237=@"loc,{#10000},12,8,12,15" +locations_default(#20237,#10000,12,8,12,15) +hasLocation(#20236,#20237) +#20238=* +tokeninfo(#20238,6,#20001,103,"assert") +#20239=@"loc,{#10000},13,1,13,6" +locations_default(#20239,#10000,13,1,13,6) +hasLocation(#20238,#20239) +next_token(#20002,#20238) +#20240=* +tokeninfo(#20240,8,#20001,104,"(") +#20241=@"loc,{#10000},13,7,13,7" +locations_default(#20241,#10000,13,7,13,7) +hasLocation(#20240,#20241) +#20242=* +tokeninfo(#20242,8,#20001,105,"{") +#20243=@"loc,{#10000},13,8,13,8" +locations_default(#20243,#10000,13,8,13,8) +hasLocation(#20242,#20243) +#20244=* +tokeninfo(#20244,6,#20001,106,"type") +#20245=@"loc,{#10000},13,9,13,12" +locations_default(#20245,#10000,13,9,13,12) +hasLocation(#20244,#20245) +#20246=* +tokeninfo(#20246,8,#20001,107,":") +#20247=@"loc,{#10000},13,13,13,13" +locations_default(#20247,#10000,13,13,13,13) +hasLocation(#20246,#20247) +#20248=* +tokeninfo(#20248,4,#20001,108,"""json""") +#20249=@"loc,{#10000},13,15,13,20" +locations_default(#20249,#10000,13,15,13,20) +hasLocation(#20248,#20249) +#20250=* +tokeninfo(#20250,8,#20001,109,"}") +#20251=@"loc,{#10000},13,21,13,21" +locations_default(#20251,#10000,13,21,13,21) +hasLocation(#20250,#20251) +#20252=* +tokeninfo(#20252,8,#20001,110,")") +#20253=@"loc,{#10000},13,22,13,22" +locations_default(#20253,#10000,13,22,13,22) +hasLocation(#20252,#20253) +#20254=* +tokeninfo(#20254,8,#20001,111,";") +#20255=@"loc,{#10000},13,23,13,23" +locations_default(#20255,#10000,13,23,13,23) +hasLocation(#20254,#20255) +#20256=* +tokeninfo(#20256,0,#20001,112,"") +#20257=@"loc,{#10000},14,1,14,0" +locations_default(#20257,#10000,14,1,14,0) +hasLocation(#20256,#20257) +next_token(#20004,#20256) +toplevels(#20001,0) +#20258=@"loc,{#10000},1,1,14,0" +locations_default(#20258,#10000,1,1,14,0) +hasLocation(#20001,#20258) +#20259=@"module;{#10000},1,1" +scopes(#20259,3) +scopenodes(#20001,#20259) +scopenesting(#20259,#20000) +is_module(#20001) +is_es2015_module(#20001) +#20260=@"var;{v1};{#20259}" +variables(#20260,"v1",#20259) +#20261=@"var;{v2};{#20259}" +variables(#20261,"v2",#20259) +#20262=@"var;{v3};{#20259}" +variables(#20262,"v3",#20259) +#20263=@"local_type_name;{v1};{#20259}" +local_type_names(#20263,"v1",#20259) +#20264=@"local_type_name;{v2};{#20259}" +local_type_names(#20264,"v2",#20259) +#20265=@"local_type_name;{v3};{#20259}" +local_type_names(#20265,"v3",#20259) +#20266=@"local_namespace_name;{v1};{#20259}" +local_namespace_names(#20266,"v1",#20259) +#20267=@"local_namespace_name;{v2};{#20259}" +local_namespace_names(#20267,"v2",#20259) +#20268=@"local_namespace_name;{v3};{#20259}" +local_namespace_names(#20268,"v3",#20259) +variables(#20260,"v1",#20259) +variables(#20261,"v2",#20259) +variables(#20262,"v3",#20259) +#20269=@"var;{v6};{#20259}" +variables(#20269,"v6",#20259) +local_type_names(#20263,"v1",#20259) +local_type_names(#20264,"v2",#20259) +local_type_names(#20265,"v3",#20259) +local_namespace_names(#20266,"v1",#20259) +local_namespace_names(#20267,"v2",#20259) +local_namespace_names(#20268,"v3",#20259) +#20270=* +stmts(#20270,27,#20001,0,"import ... son"" };") +hasLocation(#20270,#20007) +stmt_containers(#20270,#20001) +#20271=* +exprs(#20271,4,#20270,-1,"""module""") +hasLocation(#20271,#20035) +enclosing_stmt(#20271,#20270) +expr_containers(#20271,#20001) +literals("module","""module""",#20271) +#20272=* +regexpterm(#20272,14,#20271,0,"module") +#20273=@"loc,{#10000},1,9,1,14" +locations_default(#20273,#10000,1,9,1,14) +hasLocation(#20272,#20273) +regexp_const_value(#20272,"module") +#20274=* +stmts(#20274,27,#20001,1,"import ... son"" };") +hasLocation(#20274,#20009) +stmt_containers(#20274,#20001) +#20275=* +exprs(#20275,4,#20274,-1,"""module""") +hasLocation(#20275,#20061) +enclosing_stmt(#20275,#20274) +expr_containers(#20275,#20001) +literals("module","""module""",#20275) +#20276=* +regexpterm(#20276,14,#20275,0,"module") +#20277=@"loc,{#10000},2,22,2,27" +locations_default(#20277,#10000,2,22,2,27) +hasLocation(#20276,#20277) +regexp_const_value(#20276,"module") +#20278=* +exprs(#20278,85,#20274,0,"* as v1") +#20279=@"loc,{#10000},2,8,2,14" +locations_default(#20279,#10000,2,8,2,14) +hasLocation(#20278,#20279) +enclosing_stmt(#20278,#20274) +expr_containers(#20278,#20001) +#20280=* +exprs(#20280,78,#20278,1,"v1") +hasLocation(#20280,#20057) +enclosing_stmt(#20280,#20274) +expr_containers(#20280,#20001) +literals("v1","v1",#20280) +decl(#20280,#20260) +typedecl(#20280,#20263) +namespacedecl(#20280,#20266) +#20281=* +stmts(#20281,27,#20001,2,"import ... son"" };") +hasLocation(#20281,#20011) +stmt_containers(#20281,#20001) +#20282=* +exprs(#20282,4,#20281,-1,"""module""") +hasLocation(#20282,#20087) +enclosing_stmt(#20282,#20281) +expr_containers(#20282,#20001) +literals("module","""module""",#20282) +#20283=* +regexpterm(#20283,14,#20282,0,"module") +#20284=@"loc,{#10000},3,21,3,26" +locations_default(#20284,#10000,3,21,3,26) +hasLocation(#20283,#20284) +regexp_const_value(#20283,"module") +#20285=* +exprs(#20285,83,#20281,0,"v2") +hasLocation(#20285,#20081) +enclosing_stmt(#20285,#20281) +expr_containers(#20285,#20001) +#20286=* +exprs(#20286,0,#20285,0,"v2") +hasLocation(#20286,#20081) +enclosing_stmt(#20286,#20281) +expr_containers(#20286,#20001) +literals("v2","v2",#20286) +#20287=* +exprs(#20287,78,#20285,1,"v2") +hasLocation(#20287,#20081) +enclosing_stmt(#20287,#20281) +expr_containers(#20287,#20001) +literals("v2","v2",#20287) +decl(#20287,#20261) +typedecl(#20287,#20264) +namespacedecl(#20287,#20267) +#20288=* +stmts(#20288,27,#20001,3,"import ... son"" };") +hasLocation(#20288,#20013) +stmt_containers(#20288,#20001) +#20289=* +exprs(#20289,4,#20288,-1,"""module""") +hasLocation(#20289,#20109) +enclosing_stmt(#20289,#20288) +expr_containers(#20289,#20001) +literals("module","""module""",#20289) +#20290=* +regexpterm(#20290,14,#20289,0,"module") +#20291=@"loc,{#10000},4,17,4,22" +locations_default(#20291,#10000,4,17,4,22) +hasLocation(#20290,#20291) +regexp_const_value(#20290,"module") +#20292=* +exprs(#20292,84,#20288,0,"v3") +hasLocation(#20292,#20105) +enclosing_stmt(#20292,#20288) +expr_containers(#20292,#20001) +#20293=* +exprs(#20293,78,#20292,1,"v3") +hasLocation(#20293,#20105) +enclosing_stmt(#20293,#20288) +expr_containers(#20293,#20001) +literals("v3","v3",#20293) +decl(#20293,#20262) +typedecl(#20293,#20265) +namespacedecl(#20293,#20268) +#20294=* +stmts(#20294,30,#20001,4,"export ... son"" };") +hasLocation(#20294,#20017) +stmt_containers(#20294,#20001) +#20295=* +exprs(#20295,4,#20294,-2,"""module""") +hasLocation(#20295,#20135) +enclosing_stmt(#20295,#20294) +expr_containers(#20295,#20001) +literals("module","""module""",#20295) +#20296=* +regexpterm(#20296,14,#20295,0,"module") +#20297=@"loc,{#10000},6,21,6,26" +locations_default(#20297,#10000,6,21,6,26) +hasLocation(#20296,#20297) +regexp_const_value(#20296,"module") +#20298=* +exprs(#20298,86,#20294,0,"v4") +hasLocation(#20298,#20129) +enclosing_stmt(#20298,#20294) +expr_containers(#20298,#20001) +#20299=* +exprs(#20299,0,#20298,0,"v4") +hasLocation(#20299,#20129) +enclosing_stmt(#20299,#20294) +expr_containers(#20299,#20001) +literals("v4","v4",#20299) +#20300=* +exprs(#20300,0,#20298,1,"v4") +hasLocation(#20300,#20129) +enclosing_stmt(#20300,#20294) +expr_containers(#20300,#20001) +literals("v4","v4",#20300) +#20301=* +stmts(#20301,28,#20001,5,"export ... son"" };") +hasLocation(#20301,#20019) +stmt_containers(#20301,#20001) +#20302=* +exprs(#20302,4,#20301,0,"""module""") +hasLocation(#20302,#20157) +enclosing_stmt(#20302,#20301) +expr_containers(#20302,#20001) +literals("module","""module""",#20302) +#20303=* +regexpterm(#20303,14,#20302,0,"module") +#20304=@"loc,{#10000},7,16,7,21" +locations_default(#20304,#10000,7,16,7,21) +hasLocation(#20303,#20304) +regexp_const_value(#20303,"module") +#20305=* +stmts(#20305,30,#20001,6,"export ... son"" };") +hasLocation(#20305,#20021) +stmt_containers(#20305,#20001) +#20306=* +exprs(#20306,4,#20305,-2,"""module""") +hasLocation(#20306,#20183) +enclosing_stmt(#20306,#20305) +expr_containers(#20306,#20001) +literals("module","""module""",#20306) +#20307=* +regexpterm(#20307,14,#20306,0,"module") +#20308=@"loc,{#10000},8,22,8,27" +locations_default(#20308,#10000,8,22,8,27) +hasLocation(#20307,#20308) +regexp_const_value(#20307,"module") +#20309=* +exprs(#20309,96,#20305,0,"* as v5") +#20310=@"loc,{#10000},8,8,8,14" +locations_default(#20310,#10000,8,8,8,14) +hasLocation(#20309,#20310) +enclosing_stmt(#20309,#20305) +expr_containers(#20309,#20001) +#20311=* +exprs(#20311,0,#20309,1,"v5") +hasLocation(#20311,#20179) +enclosing_stmt(#20311,#20305) +expr_containers(#20311,#20001) +literals("v5","v5",#20311) +#20312=* +stmts(#20312,22,#20001,7,"const v ... "" } });") +hasLocation(#20312,#20025) +stmt_containers(#20312,#20001) +#20313=* +exprs(#20313,64,#20312,0,"v6 = im ... n"" } })") +#20314=@"loc,{#10000},10,7,10,57" +locations_default(#20314,#10000,10,7,10,57) +hasLocation(#20313,#20314) +enclosing_stmt(#20313,#20312) +expr_containers(#20313,#20001) +#20315=* +exprs(#20315,78,#20313,0,"v6") +hasLocation(#20315,#20201) +enclosing_stmt(#20315,#20312) +expr_containers(#20315,#20001) +literals("v6","v6",#20315) +decl(#20315,#20269) +#20316=* +exprs(#20316,99,#20313,1,"import( ... n"" } })") +#20317=@"loc,{#10000},10,12,10,57" +locations_default(#20317,#10000,10,12,10,57) +hasLocation(#20316,#20317) +enclosing_stmt(#20316,#20312) +expr_containers(#20316,#20001) +#20318=* +exprs(#20318,4,#20316,0,"""module""") +hasLocation(#20318,#20209) +enclosing_stmt(#20318,#20312) +expr_containers(#20318,#20001) +literals("module","""module""",#20318) +#20319=* +regexpterm(#20319,14,#20318,0,"module") +#20320=@"loc,{#10000},10,20,10,25" +locations_default(#20320,#10000,10,20,10,25) +hasLocation(#20319,#20320) +regexp_const_value(#20319,"module") +#20321=* +stmts(#20321,27,#20001,8,"import ""module""") +#20322=@"loc,{#10000},12,1,12,15" +locations_default(#20322,#10000,12,1,12,15) +hasLocation(#20321,#20322) +stmt_containers(#20321,#20001) +#20323=* +exprs(#20323,4,#20321,-1,"""module""") +hasLocation(#20323,#20237) +enclosing_stmt(#20323,#20321) +expr_containers(#20323,#20001) +literals("module","""module""",#20323) +#20324=* +regexpterm(#20324,14,#20323,0,"module") +#20325=@"loc,{#10000},12,9,12,14" +locations_default(#20325,#10000,12,9,12,14) +hasLocation(#20324,#20325) +regexp_const_value(#20324,"module") +#20326=* +stmts(#20326,2,#20001,9,"assert( ... son""});") +#20327=@"loc,{#10000},13,1,13,23" +locations_default(#20327,#10000,13,1,13,23) +hasLocation(#20326,#20327) +stmt_containers(#20326,#20001) +#20328=* +exprs(#20328,13,#20326,0,"assert( ... json""})") +#20329=@"loc,{#10000},13,1,13,22" +locations_default(#20329,#10000,13,1,13,22) +hasLocation(#20328,#20329) +enclosing_stmt(#20328,#20326) +expr_containers(#20328,#20001) +#20330=* +exprs(#20330,79,#20328,-1,"assert") +hasLocation(#20330,#20239) +enclosing_stmt(#20330,#20326) +expr_containers(#20330,#20001) +literals("assert","assert",#20330) +#20331=@"var;{assert};{#20000}" +variables(#20331,"assert",#20000) +bind(#20330,#20331) +#20332=* +exprs(#20332,8,#20328,0,"{type: ""json""}") +#20333=@"loc,{#10000},13,8,13,21" +locations_default(#20333,#10000,13,8,13,21) +hasLocation(#20332,#20333) +enclosing_stmt(#20332,#20326) +expr_containers(#20332,#20001) +#20334=* +properties(#20334,#20332,0,0,"type: ""json""") +#20335=@"loc,{#10000},13,9,13,20" +locations_default(#20335,#10000,13,9,13,20) +hasLocation(#20334,#20335) +#20336=* +exprs(#20336,0,#20334,0,"type") +hasLocation(#20336,#20245) +enclosing_stmt(#20336,#20326) +expr_containers(#20336,#20001) +literals("type","type",#20336) +#20337=* +exprs(#20337,4,#20334,1,"""json""") +hasLocation(#20337,#20249) +enclosing_stmt(#20337,#20326) +expr_containers(#20337,#20001) +literals("json","""json""",#20337) +#20338=* +regexpterm(#20338,14,#20337,0,"json") +#20339=@"loc,{#10000},13,16,13,19" +locations_default(#20339,#10000,13,16,13,19) +hasLocation(#20338,#20339) +regexp_const_value(#20338,"json") +#20340=* +entry_cfg_node(#20340,#20001) +#20341=@"loc,{#10000},1,1,1,0" +locations_default(#20341,#10000,1,1,1,0) +hasLocation(#20340,#20341) +#20342=* +exit_cfg_node(#20342,#20001) +hasLocation(#20342,#20257) +successor(#20326,#20330) +successor(#20332,#20336) +successor(#20337,#20334) +successor(#20336,#20337) +successor(#20334,#20328) +successor(#20330,#20332) +successor(#20328,#20342) +successor(#20321,#20326) +successor(#20312,#20315) +successor(#20318,#20316) +successor(#20316,#20313) +successor(#20315,#20318) +successor(#20313,#20321) +successor(#20305,#20306) +successor(#20309,#20311) +successor(#20311,#20312) +successor(#20306,#20309) +successor(#20301,#20302) +successor(#20302,#20305) +successor(#20294,#20295) +successor(#20298,#20299) +successor(#20300,#20301) +successor(#20299,#20300) +successor(#20295,#20298) +successor(#20288,#20294) +successor(#20281,#20288) +successor(#20274,#20281) +successor(#20270,#20274) +successor(#20292,#20270) +successor(#20285,#20292) +successor(#20278,#20285) +successor(#20340,#20278) +numlines(#10000,13,10,2) +filetype(#10000,"javascript") From 8d9060f1f9b12e4476d3be4d4f2330f467e57cd0 Mon Sep 17 00:00:00 2001 From: Asger F Date: Thu, 2 Mar 2023 13:27:29 +0100 Subject: [PATCH 022/135] JS: Store in the Java AST --- .../src/com/semmle/jcorn/ESNextParser.java | 14 +++++++------- .../extractor/src/com/semmle/jcorn/Parser.java | 12 ++++++------ .../src/com/semmle/jcorn/flow/FlowParser.java | 4 ++-- .../src/com/semmle/js/ast/DynamicImport.java | 9 ++++++++- .../com/semmle/js/ast/ExportAllDeclaration.java | 8 +++++++- .../com/semmle/js/ast/ExportNamedDeclaration.java | 13 ++++++++++--- .../src/com/semmle/js/ast/ImportDeclaration.java | 14 +++++++++++--- .../src/com/semmle/js/ast/NodeCopier.java | 9 +++++---- .../ts/extractor/TypeScriptASTConverter.java | 14 +++++++------- 9 files changed, 63 insertions(+), 34 deletions(-) diff --git a/javascript/extractor/src/com/semmle/jcorn/ESNextParser.java b/javascript/extractor/src/com/semmle/jcorn/ESNextParser.java index eff8cae5803..f10e94297bb 100644 --- a/javascript/extractor/src/com/semmle/jcorn/ESNextParser.java +++ b/javascript/extractor/src/com/semmle/jcorn/ESNextParser.java @@ -314,8 +314,8 @@ public class ESNextParser extends JSXParser { this.parseExportSpecifiersMaybe(specifiers, exports); } Literal source = (Literal) this.parseExportFrom(specifiers, null, true); - Expression assertion = this.parseImportOrExportAssertionAndSemicolon(); // TODO: store in AST - return this.finishNode(new ExportNamedDeclaration(exportStart, null, specifiers, source)); + Expression assertion = this.parseImportOrExportAssertionAndSemicolon(); + return this.finishNode(new ExportNamedDeclaration(exportStart, null, specifiers, source, assertion)); } return super.parseExportRest(exportStart, exports); @@ -331,8 +331,8 @@ public class ESNextParser extends JSXParser { List specifiers = CollectionUtil.makeList(nsSpec); this.parseExportSpecifiersMaybe(specifiers, exports); Literal source = (Literal) this.parseExportFrom(specifiers, null, true); - Expression assertion = this.parseImportOrExportAssertionAndSemicolon(); // TODO: store in AST - return this.finishNode(new ExportNamedDeclaration(exportStart, null, specifiers, source)); + Expression assertion = this.parseImportOrExportAssertionAndSemicolon(); + return this.finishNode(new ExportNamedDeclaration(exportStart, null, specifiers, source, assertion)); } return super.parseExportAll(exportStart, starLoc, exports); @@ -437,12 +437,12 @@ public class ESNextParser extends JSXParser { */ private DynamicImport parseDynamicImport(Position startLoc) { Expression source = parseMaybeAssign(false, null, null); - Expression assertion = null; + Expression attributes = null; if (this.eat(TokenType.comma)) { - assertion = this.parseMaybeAssign(false, null, null); // TODO: store in AST + attributes = this.parseMaybeAssign(false, null, null); } this.expect(TokenType.parenR); - DynamicImport di = this.finishNode(new DynamicImport(new SourceLocation(startLoc), source)); + DynamicImport di = this.finishNode(new DynamicImport(new SourceLocation(startLoc), source, attributes)); return di; } diff --git a/javascript/extractor/src/com/semmle/jcorn/Parser.java b/javascript/extractor/src/com/semmle/jcorn/Parser.java index 135c5221eb5..a5a6dc4e0d1 100644 --- a/javascript/extractor/src/com/semmle/jcorn/Parser.java +++ b/javascript/extractor/src/com/semmle/jcorn/Parser.java @@ -3429,10 +3429,10 @@ public class Parser { declaration = null; specifiers = this.parseExportSpecifiers(exports); source = parseExportFrom(specifiers, source, false); - assertion = parseImportOrExportAssertionAndSemicolon(); // TODO: store in AST + assertion = parseImportOrExportAssertionAndSemicolon(); } return this.finishNode( - new ExportNamedDeclaration(loc, declaration, specifiers, (Literal) source)); + new ExportNamedDeclaration(loc, declaration, specifiers, (Literal) source, assertion)); } /** Parses the 'from' clause of an export, not including the assertion or semicolon. */ @@ -3460,8 +3460,8 @@ public class Parser { protected ExportDeclaration parseExportAll( SourceLocation loc, Position starLoc, Set exports) { Expression source = parseExportFrom(null, null, true); - Expression assertion = parseImportOrExportAssertionAndSemicolon(); // TODO: store in AST - return this.finishNode(new ExportAllDeclaration(loc, (Literal) source)); + Expression assertion = parseImportOrExportAssertionAndSemicolon(); + return this.finishNode(new ExportAllDeclaration(loc, (Literal) source, assertion)); } private void checkExport(Set exports, String name, Position pos) { @@ -3549,9 +3549,9 @@ public class Parser { if (this.type != TokenType.string) this.unexpected(); source = (Literal) this.parseExprAtom(null); } - Expression assertion = this.parseImportOrExportAssertionAndSemicolon(); // TODO: store in AST + Expression assertion = this.parseImportOrExportAssertionAndSemicolon(); if (specifiers == null) return null; - return this.finishNode(new ImportDeclaration(loc, specifiers, source)); + return this.finishNode(new ImportDeclaration(loc, specifiers, source, assertion)); } // Parses a comma-separated list of module imports. diff --git a/javascript/extractor/src/com/semmle/jcorn/flow/FlowParser.java b/javascript/extractor/src/com/semmle/jcorn/flow/FlowParser.java index 8785eb111bf..82a9c9eee49 100644 --- a/javascript/extractor/src/com/semmle/jcorn/flow/FlowParser.java +++ b/javascript/extractor/src/com/semmle/jcorn/flow/FlowParser.java @@ -943,12 +943,12 @@ public class FlowParser extends ESNextParser { // `export type { foo, bar };` List specifiers = this.parseExportSpecifiers(exports); this.parseExportFrom(specifiers, null, false); - this.parseImportOrExportAssertionAndSemicolon(); // TODO: store in AST? + this.parseImportOrExportAssertionAndSemicolon(); return null; } else if (this.eat(TokenType.star)) { if (this.eatContextual("as")) this.parseIdent(true); this.parseExportFrom(null, null, true); - this.parseImportOrExportAssertionAndSemicolon(); // TODO: store in AST? + this.parseImportOrExportAssertionAndSemicolon(); return null; } else { // `export type Foo = Bar;` diff --git a/javascript/extractor/src/com/semmle/js/ast/DynamicImport.java b/javascript/extractor/src/com/semmle/js/ast/DynamicImport.java index 79810125a4e..8c1c3aed873 100644 --- a/javascript/extractor/src/com/semmle/js/ast/DynamicImport.java +++ b/javascript/extractor/src/com/semmle/js/ast/DynamicImport.java @@ -2,16 +2,23 @@ package com.semmle.js.ast; public class DynamicImport extends Expression { private final Expression source; + private final Expression attributes; - public DynamicImport(SourceLocation loc, Expression source) { + public DynamicImport(SourceLocation loc, Expression source, Expression attributes) { super("DynamicImport", loc); this.source = source; + this.attributes = attributes; } public Expression getSource() { return source; } + /** Returns the second "argument" provided to the import, such as { assert: { type: "json" }}. */ + public Expression getAttributes() { + return attributes; + } + @Override public R accept(Visitor v, C c) { return v.visit(this, c); diff --git a/javascript/extractor/src/com/semmle/js/ast/ExportAllDeclaration.java b/javascript/extractor/src/com/semmle/js/ast/ExportAllDeclaration.java index 81603f425ca..a726f31c9b1 100644 --- a/javascript/extractor/src/com/semmle/js/ast/ExportAllDeclaration.java +++ b/javascript/extractor/src/com/semmle/js/ast/ExportAllDeclaration.java @@ -9,16 +9,22 @@ package com.semmle.js.ast; */ public class ExportAllDeclaration extends ExportDeclaration { private final Literal source; + private final Expression assertion; - public ExportAllDeclaration(SourceLocation loc, Literal source) { + public ExportAllDeclaration(SourceLocation loc, Literal source, Expression assertion) { super("ExportAllDeclaration", loc); this.source = source; + this.assertion = assertion; } public Literal getSource() { return source; } + public Expression getAssertion() { + return assertion; + } + @Override public R accept(Visitor v, C c) { return v.visit(this, c); diff --git a/javascript/extractor/src/com/semmle/js/ast/ExportNamedDeclaration.java b/javascript/extractor/src/com/semmle/js/ast/ExportNamedDeclaration.java index d4d19b8d1ab..eddca1273a3 100644 --- a/javascript/extractor/src/com/semmle/js/ast/ExportNamedDeclaration.java +++ b/javascript/extractor/src/com/semmle/js/ast/ExportNamedDeclaration.java @@ -15,20 +15,22 @@ public class ExportNamedDeclaration extends ExportDeclaration { private final Statement declaration; private final List specifiers; private final Literal source; + private final Expression assertion; private final boolean hasTypeKeyword; public ExportNamedDeclaration( - SourceLocation loc, Statement declaration, List specifiers, Literal source) { - this(loc, declaration, specifiers, source, false); + SourceLocation loc, Statement declaration, List specifiers, Literal source, Expression assertion) { + this(loc, declaration, specifiers, source, assertion, false); } public ExportNamedDeclaration( SourceLocation loc, Statement declaration, List specifiers, Literal source, - boolean hasTypeKeyword) { + Expression assertion, boolean hasTypeKeyword) { super("ExportNamedDeclaration", loc); this.declaration = declaration; this.specifiers = specifiers; this.source = source; + this.assertion = assertion; this.hasTypeKeyword = hasTypeKeyword; } @@ -57,6 +59,11 @@ public class ExportNamedDeclaration extends ExportDeclaration { return v.visit(this, c); } + /** Returns the expression after the assert keyword, if any, such as { type: "json" }. */ + public Expression getAssertion() { + return assertion; + } + /** Returns true if this is an export type declaration. */ public boolean hasTypeKeyword() { return hasTypeKeyword; diff --git a/javascript/extractor/src/com/semmle/js/ast/ImportDeclaration.java b/javascript/extractor/src/com/semmle/js/ast/ImportDeclaration.java index 8a291000f2f..133266c0b34 100644 --- a/javascript/extractor/src/com/semmle/js/ast/ImportDeclaration.java +++ b/javascript/extractor/src/com/semmle/js/ast/ImportDeclaration.java @@ -23,18 +23,21 @@ public class ImportDeclaration extends Statement implements INodeWithSymbol { /** The module from which declarations are imported. */ private final Literal source; + private final Expression assertion; + private int symbol = -1; private boolean hasTypeKeyword; - public ImportDeclaration(SourceLocation loc, List specifiers, Literal source) { - this(loc, specifiers, source, false); + public ImportDeclaration(SourceLocation loc, List specifiers, Literal source, Expression assertion) { + this(loc, specifiers, source, assertion, false); } - public ImportDeclaration(SourceLocation loc, List specifiers, Literal source, boolean hasTypeKeyword) { + public ImportDeclaration(SourceLocation loc, List specifiers, Literal source, Expression assertion, boolean hasTypeKeyword) { super("ImportDeclaration", loc); this.specifiers = specifiers; this.source = source; + this.assertion = assertion; this.hasTypeKeyword = hasTypeKeyword; } @@ -46,6 +49,11 @@ public class ImportDeclaration extends Statement implements INodeWithSymbol { return specifiers; } + /** Returns the expression after the assert keyword, if any, such as { type: "json" }. */ + public Expression getAssertion() { + return assertion; + } + @Override public R accept(Visitor v, C c) { return v.visit(this, c); diff --git a/javascript/extractor/src/com/semmle/js/ast/NodeCopier.java b/javascript/extractor/src/com/semmle/js/ast/NodeCopier.java index aeea1b79cbc..30b23d28a33 100644 --- a/javascript/extractor/src/com/semmle/js/ast/NodeCopier.java +++ b/javascript/extractor/src/com/semmle/js/ast/NodeCopier.java @@ -523,7 +523,7 @@ public class NodeCopier implements Visitor { @Override public ExportAllDeclaration visit(ExportAllDeclaration nd, Void c) { - return new ExportAllDeclaration(visit(nd.getLoc()), copy(nd.getSource())); + return new ExportAllDeclaration(visit(nd.getLoc()), copy(nd.getSource()), copy(nd.getAssertion())); } @Override @@ -537,7 +537,8 @@ public class NodeCopier implements Visitor { visit(nd.getLoc()), copy(nd.getDeclaration()), copy(nd.getSpecifiers()), - copy(nd.getSource())); + copy(nd.getSource()), + copy(nd.getAssertion())); } @Override @@ -558,7 +559,7 @@ public class NodeCopier implements Visitor { @Override public ImportDeclaration visit(ImportDeclaration nd, Void c) { return new ImportDeclaration( - visit(nd.getLoc()), copy(nd.getSpecifiers()), copy(nd.getSource())); + visit(nd.getLoc()), copy(nd.getSpecifiers()), copy(nd.getSource()), copy(nd.getAssertion()), nd.hasTypeKeyword()); } @Override @@ -678,7 +679,7 @@ public class NodeCopier implements Visitor { @Override public INode visit(DynamicImport nd, Void c) { - return new DynamicImport(visit(nd.getLoc()), copy(nd.getSource())); + return new DynamicImport(visit(nd.getLoc()), copy(nd.getSource()), copy(nd.getAttributes())); } @Override diff --git a/javascript/extractor/src/com/semmle/ts/extractor/TypeScriptASTConverter.java b/javascript/extractor/src/com/semmle/ts/extractor/TypeScriptASTConverter.java index cc748054923..3783a44936e 100644 --- a/javascript/extractor/src/com/semmle/ts/extractor/TypeScriptASTConverter.java +++ b/javascript/extractor/src/com/semmle/ts/extractor/TypeScriptASTConverter.java @@ -342,7 +342,7 @@ public class TypeScriptASTConverter { return convertArrowFunction(node, loc); case "AsExpression": return convertTypeAssertionExpression(node, loc); - case "SatisfiesExpression": + case "SatisfiesExpression": return convertSatisfiesExpression(node, loc); case "AwaitExpression": return convertAwaitExpression(node, loc); @@ -888,7 +888,7 @@ public class TypeScriptASTConverter { private Node convertCallExpression(JsonObject node, SourceLocation loc) throws ParseError { List arguments = convertChildren(node, "arguments"); if (arguments.size() == 1 && hasKind(node.get("expression"), "ImportKeyword")) { - return new DynamicImport(loc, arguments.get(0)); + return new DynamicImport(loc, arguments.get(0), null); // TODO: preserve import attributes } Expression callee = convertChild(node, "expression"); List typeArguments = convertChildrenAsTypes(node, "typeArguments"); @@ -1199,9 +1199,9 @@ public class TypeScriptASTConverter { hasKind(node.get("exportClause"), "NamespaceExport") ? Collections.singletonList(convertChild(node, "exportClause")) : convertChildren(node.get("exportClause").getAsJsonObject(), "elements"); - return new ExportNamedDeclaration(loc, null, specifiers, source, hasTypeKeyword); + return new ExportNamedDeclaration(loc, null, specifiers, source, null, hasTypeKeyword); // TODO: preserve import assertions } else { - return new ExportAllDeclaration(loc, source); + return new ExportAllDeclaration(loc, source, null); // TODO: preserve import assertions } } @@ -1400,7 +1400,7 @@ public class TypeScriptASTConverter { } hasTypeKeyword = importClause.get("isTypeOnly").getAsBoolean(); } - ImportDeclaration importDecl = new ImportDeclaration(loc, specifiers, src, hasTypeKeyword); + ImportDeclaration importDecl = new ImportDeclaration(loc, specifiers, src, null, hasTypeKeyword); // TODO: preserve import assertions attachSymbolInformation(importDecl, node); return importDecl; } @@ -1746,7 +1746,7 @@ public class TypeScriptASTConverter { if (hasFlag(node, "NestedNamespace")) { // In a nested namespace declaration `namespace A.B`, the nested namespace `B` // is implicitly exported. - return new ExportNamedDeclaration(loc, decl, new ArrayList<>(), null); + return new ExportNamedDeclaration(loc, decl, new ArrayList<>(), null, null); // TODO: preserve import assertion } else { return fixExports(loc, decl); } @@ -2455,7 +2455,7 @@ public class TypeScriptASTConverter { advance(loc, skipped); // capture group 1 is `default`, if present if (m.group(1) == null) - return new ExportNamedDeclaration(outerLoc, (Statement) decl, new ArrayList<>(), null); + return new ExportNamedDeclaration(outerLoc, (Statement) decl, new ArrayList<>(), null, null); // TODO: preserve import assertions return new ExportDefaultDeclaration(outerLoc, decl); } return decl; From 3af085afcbe8a49fce7af21f876cf0ad22d13ec5 Mon Sep 17 00:00:00 2001 From: Asger F Date: Thu, 2 Mar 2023 13:32:46 +0100 Subject: [PATCH 023/135] JS: Drive-by allow trailing commas in dynamic imports --- javascript/extractor/src/com/semmle/jcorn/ESNextParser.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/javascript/extractor/src/com/semmle/jcorn/ESNextParser.java b/javascript/extractor/src/com/semmle/jcorn/ESNextParser.java index f10e94297bb..245e0e81321 100644 --- a/javascript/extractor/src/com/semmle/jcorn/ESNextParser.java +++ b/javascript/extractor/src/com/semmle/jcorn/ESNextParser.java @@ -439,7 +439,10 @@ public class ESNextParser extends JSXParser { Expression source = parseMaybeAssign(false, null, null); Expression attributes = null; if (this.eat(TokenType.comma)) { - attributes = this.parseMaybeAssign(false, null, null); + if (this.type != TokenType.parenR) { // Skip if the comma was a trailing comma + attributes = this.parseMaybeAssign(false, null, null); + this.eat(TokenType.comma); // Allow trailing comma + } } this.expect(TokenType.parenR); DynamicImport di = this.finishNode(new DynamicImport(new SourceLocation(startLoc), source, attributes)); From f454151e7a6324143d27e22c5671acea3f9a0455 Mon Sep 17 00:00:00 2001 From: Asger F Date: Thu, 2 Mar 2023 13:51:11 +0100 Subject: [PATCH 024/135] JS: Convert TypeScript import assertions --- .../extractor/lib/typescript/src/main.ts | 1 + .../ts/extractor/TypeScriptASTConverter.java | 38 +- .../tests/ts/input/import-assertion.ts | 13 + .../ts/output/trap/import-assertion.ts.trap | 1117 +++++++++++++++++ 4 files changed, 1162 insertions(+), 7 deletions(-) create mode 100644 javascript/extractor/tests/ts/input/import-assertion.ts create mode 100644 javascript/extractor/tests/ts/output/trap/import-assertion.ts.trap diff --git a/javascript/extractor/lib/typescript/src/main.ts b/javascript/extractor/lib/typescript/src/main.ts index 440e621efd2..0116421a217 100644 --- a/javascript/extractor/lib/typescript/src/main.ts +++ b/javascript/extractor/lib/typescript/src/main.ts @@ -224,6 +224,7 @@ const astProperties: string[] = [ "argument", "argumentExpression", "arguments", + "assertClause", "assertsModifier", "asteriskToken", "attributes", diff --git a/javascript/extractor/src/com/semmle/ts/extractor/TypeScriptASTConverter.java b/javascript/extractor/src/com/semmle/ts/extractor/TypeScriptASTConverter.java index 3783a44936e..f003381064c 100644 --- a/javascript/extractor/src/com/semmle/ts/extractor/TypeScriptASTConverter.java +++ b/javascript/extractor/src/com/semmle/ts/extractor/TypeScriptASTConverter.java @@ -342,6 +342,10 @@ public class TypeScriptASTConverter { return convertArrowFunction(node, loc); case "AsExpression": return convertTypeAssertionExpression(node, loc); + case "AssertClause": + return convertAssertClause(node, loc); + case "AssertEntry": + return convertAssertEntry(node, loc); case "SatisfiesExpression": return convertSatisfiesExpression(node, loc); case "AwaitExpression": @@ -887,8 +891,8 @@ public class TypeScriptASTConverter { private Node convertCallExpression(JsonObject node, SourceLocation loc) throws ParseError { List arguments = convertChildren(node, "arguments"); - if (arguments.size() == 1 && hasKind(node.get("expression"), "ImportKeyword")) { - return new DynamicImport(loc, arguments.get(0), null); // TODO: preserve import attributes + if (arguments.size() >= 1 && hasKind(node.get("expression"), "ImportKeyword")) { + return new DynamicImport(loc, arguments.get(0), arguments.size() > 1 ? arguments.get(1) : null); } Expression callee = convertChild(node, "expression"); List typeArguments = convertChildrenAsTypes(node, "typeArguments"); @@ -1193,15 +1197,16 @@ public class TypeScriptASTConverter { private Node convertExportDeclaration(JsonObject node, SourceLocation loc) throws ParseError { Literal source = tryConvertChild(node, "moduleSpecifier", Literal.class); + Expression assertion = convertChild(node, "assertClause"); if (hasChild(node, "exportClause")) { boolean hasTypeKeyword = node.get("isTypeOnly").getAsBoolean(); List specifiers = hasKind(node.get("exportClause"), "NamespaceExport") ? Collections.singletonList(convertChild(node, "exportClause")) : convertChildren(node.get("exportClause").getAsJsonObject(), "elements"); - return new ExportNamedDeclaration(loc, null, specifiers, source, null, hasTypeKeyword); // TODO: preserve import assertions + return new ExportNamedDeclaration(loc, null, specifiers, source, assertion, hasTypeKeyword); } else { - return new ExportAllDeclaration(loc, source, null); // TODO: preserve import assertions + return new ExportAllDeclaration(loc, source, assertion); } } @@ -1383,6 +1388,7 @@ public class TypeScriptASTConverter { private Node convertImportDeclaration(JsonObject node, SourceLocation loc) throws ParseError { Literal src = tryConvertChild(node, "moduleSpecifier", Literal.class); + Expression assertion = convertChild(node, "assertClause"); List specifiers = new ArrayList<>(); boolean hasTypeKeyword = false; if (hasChild(node, "importClause")) { @@ -1400,7 +1406,7 @@ public class TypeScriptASTConverter { } hasTypeKeyword = importClause.get("isTypeOnly").getAsBoolean(); } - ImportDeclaration importDecl = new ImportDeclaration(loc, specifiers, src, null, hasTypeKeyword); // TODO: preserve import assertions + ImportDeclaration importDecl = new ImportDeclaration(loc, specifiers, src, assertion, hasTypeKeyword); attachSymbolInformation(importDecl, node); return importDecl; } @@ -1746,7 +1752,7 @@ public class TypeScriptASTConverter { if (hasFlag(node, "NestedNamespace")) { // In a nested namespace declaration `namespace A.B`, the nested namespace `B` // is implicitly exported. - return new ExportNamedDeclaration(loc, decl, new ArrayList<>(), null, null); // TODO: preserve import assertion + return new ExportNamedDeclaration(loc, decl, new ArrayList<>(), null, null); } else { return fixExports(loc, decl); } @@ -2276,6 +2282,24 @@ public class TypeScriptASTConverter { return new TypeAssertion(loc, convertChild(node, "expression"), type, false); } + private Node convertAssertClause(JsonObject node, SourceLocation loc) throws ParseError { + List properties = new ArrayList<>(); + for (INode child : convertChildren(node, "elements")) { + properties.add((Property)child); + } + return new ObjectExpression(loc, properties); + } + + private Node convertAssertEntry(JsonObject node, SourceLocation loc) throws ParseError { + return new Property( + loc, + convertChild(node, "key"), + convertChild(node, "value"), + "init", + false, + false); + } + private Node convertSatisfiesExpression(JsonObject node, SourceLocation loc) throws ParseError { ITypeExpression type = convertChildAsType(node, "type"); return new SatisfiesExpr(loc, convertChild(node, "expression"), type); @@ -2455,7 +2479,7 @@ public class TypeScriptASTConverter { advance(loc, skipped); // capture group 1 is `default`, if present if (m.group(1) == null) - return new ExportNamedDeclaration(outerLoc, (Statement) decl, new ArrayList<>(), null, null); // TODO: preserve import assertions + return new ExportNamedDeclaration(outerLoc, (Statement) decl, new ArrayList<>(), null, null); return new ExportDefaultDeclaration(outerLoc, decl); } return decl; diff --git a/javascript/extractor/tests/ts/input/import-assertion.ts b/javascript/extractor/tests/ts/input/import-assertion.ts new file mode 100644 index 00000000000..b138341aa63 --- /dev/null +++ b/javascript/extractor/tests/ts/input/import-assertion.ts @@ -0,0 +1,13 @@ +import "module" assert { type: "json" }; +import * as v1 from "module" assert { type: "json" }; +import { v2 } from "module" assert { type: "json" }; +import v3 from "module" assert { type: "json" }; + +export { v4 } from "module" assert { type: "json" }; +export * from "module" assert { type: "json" }; +export * as v5 from "module" assert { type: "json" }; + +const v6 = import("module", { assert: { type: "json" } }); + +import "module"; // missing semicolon +assert({ type: "json" }); // function call, not import assertion diff --git a/javascript/extractor/tests/ts/output/trap/import-assertion.ts.trap b/javascript/extractor/tests/ts/output/trap/import-assertion.ts.trap new file mode 100644 index 00000000000..d82dca7dee7 --- /dev/null +++ b/javascript/extractor/tests/ts/output/trap/import-assertion.ts.trap @@ -0,0 +1,1117 @@ +#10000=@"/import-assertion.ts;sourcefile" +files(#10000,"/import-assertion.ts") +#10001=@"/;folder" +folders(#10001,"/") +containerparent(#10001,#10000) +#10002=@"loc,{#10000},0,0,0,0" +locations_default(#10002,#10000,0,0,0,0) +hasLocation(#10000,#10002) +#20000=@"global_scope" +scopes(#20000,0) +#20001=@"script;{#10000},1,1" +#20002=* +comments(#20002,0,#20001," missing semicolon","// missing semicolon") +#20003=@"loc,{#10000},12,18,12,37" +locations_default(#20003,#10000,12,18,12,37) +hasLocation(#20002,#20003) +#20004=* +comments(#20004,0,#20001," function call, not import assertion","// func ... sertion") +#20005=@"loc,{#10000},13,27,13,64" +locations_default(#20005,#10000,13,27,13,64) +hasLocation(#20004,#20005) +#20006=* +lines(#20006,#20001,"import ""module"" assert { type: ""json"" };"," +") +#20007=@"loc,{#10000},1,1,1,40" +locations_default(#20007,#10000,1,1,1,40) +hasLocation(#20006,#20007) +#20008=* +lines(#20008,#20001,"import * as v1 from ""module"" assert { type: ""json"" };"," +") +#20009=@"loc,{#10000},2,1,2,53" +locations_default(#20009,#10000,2,1,2,53) +hasLocation(#20008,#20009) +#20010=* +lines(#20010,#20001,"import { v2 } from ""module"" assert { type: ""json"" };"," +") +#20011=@"loc,{#10000},3,1,3,52" +locations_default(#20011,#10000,3,1,3,52) +hasLocation(#20010,#20011) +#20012=* +lines(#20012,#20001,"import v3 from ""module"" assert { type: ""json"" };"," +") +#20013=@"loc,{#10000},4,1,4,48" +locations_default(#20013,#10000,4,1,4,48) +hasLocation(#20012,#20013) +#20014=* +lines(#20014,#20001,""," +") +#20015=@"loc,{#10000},5,1,5,0" +locations_default(#20015,#10000,5,1,5,0) +hasLocation(#20014,#20015) +#20016=* +lines(#20016,#20001,"export { v4 } from ""module"" assert { type: ""json"" };"," +") +#20017=@"loc,{#10000},6,1,6,52" +locations_default(#20017,#10000,6,1,6,52) +hasLocation(#20016,#20017) +#20018=* +lines(#20018,#20001,"export * from ""module"" assert { type: ""json"" };"," +") +#20019=@"loc,{#10000},7,1,7,47" +locations_default(#20019,#10000,7,1,7,47) +hasLocation(#20018,#20019) +#20020=* +lines(#20020,#20001,"export * as v5 from ""module"" assert { type: ""json"" };"," +") +#20021=@"loc,{#10000},8,1,8,53" +locations_default(#20021,#10000,8,1,8,53) +hasLocation(#20020,#20021) +#20022=* +lines(#20022,#20001,""," +") +#20023=@"loc,{#10000},9,1,9,0" +locations_default(#20023,#10000,9,1,9,0) +hasLocation(#20022,#20023) +#20024=* +lines(#20024,#20001,"const v6 = import(""module"", { assert: { type: ""json"" } });"," +") +#20025=@"loc,{#10000},10,1,10,58" +locations_default(#20025,#10000,10,1,10,58) +hasLocation(#20024,#20025) +#20026=* +lines(#20026,#20001,""," +") +#20027=@"loc,{#10000},11,1,11,0" +locations_default(#20027,#10000,11,1,11,0) +hasLocation(#20026,#20027) +#20028=* +lines(#20028,#20001,"import ""module""; // missing semicolon"," +") +#20029=@"loc,{#10000},12,1,12,37" +locations_default(#20029,#10000,12,1,12,37) +hasLocation(#20028,#20029) +#20030=* +lines(#20030,#20001,"assert({ type: ""json"" }); // function call, not import assertion"," +") +#20031=@"loc,{#10000},13,1,13,64" +locations_default(#20031,#10000,13,1,13,64) +hasLocation(#20030,#20031) +numlines(#20001,13,10,2) +#20032=* +tokeninfo(#20032,7,#20001,0,"import") +#20033=@"loc,{#10000},1,1,1,6" +locations_default(#20033,#10000,1,1,1,6) +hasLocation(#20032,#20033) +#20034=* +tokeninfo(#20034,4,#20001,1,"""module""") +#20035=@"loc,{#10000},1,8,1,15" +locations_default(#20035,#10000,1,8,1,15) +hasLocation(#20034,#20035) +#20036=* +tokeninfo(#20036,7,#20001,2,"assert") +#20037=@"loc,{#10000},1,17,1,22" +locations_default(#20037,#10000,1,17,1,22) +hasLocation(#20036,#20037) +#20038=* +tokeninfo(#20038,8,#20001,3,"{") +#20039=@"loc,{#10000},1,24,1,24" +locations_default(#20039,#10000,1,24,1,24) +hasLocation(#20038,#20039) +#20040=* +tokeninfo(#20040,7,#20001,4,"type") +#20041=@"loc,{#10000},1,26,1,29" +locations_default(#20041,#10000,1,26,1,29) +hasLocation(#20040,#20041) +#20042=* +tokeninfo(#20042,8,#20001,5,":") +#20043=@"loc,{#10000},1,30,1,30" +locations_default(#20043,#10000,1,30,1,30) +hasLocation(#20042,#20043) +#20044=* +tokeninfo(#20044,4,#20001,6,"""json""") +#20045=@"loc,{#10000},1,32,1,37" +locations_default(#20045,#10000,1,32,1,37) +hasLocation(#20044,#20045) +#20046=* +tokeninfo(#20046,8,#20001,7,"}") +#20047=@"loc,{#10000},1,39,1,39" +locations_default(#20047,#10000,1,39,1,39) +hasLocation(#20046,#20047) +#20048=* +tokeninfo(#20048,8,#20001,8,";") +#20049=@"loc,{#10000},1,40,1,40" +locations_default(#20049,#10000,1,40,1,40) +hasLocation(#20048,#20049) +#20050=* +tokeninfo(#20050,7,#20001,9,"import") +#20051=@"loc,{#10000},2,1,2,6" +locations_default(#20051,#10000,2,1,2,6) +hasLocation(#20050,#20051) +#20052=* +tokeninfo(#20052,8,#20001,10,"*") +#20053=@"loc,{#10000},2,8,2,8" +locations_default(#20053,#10000,2,8,2,8) +hasLocation(#20052,#20053) +#20054=* +tokeninfo(#20054,7,#20001,11,"as") +#20055=@"loc,{#10000},2,10,2,11" +locations_default(#20055,#10000,2,10,2,11) +hasLocation(#20054,#20055) +#20056=* +tokeninfo(#20056,6,#20001,12,"v1") +#20057=@"loc,{#10000},2,13,2,14" +locations_default(#20057,#10000,2,13,2,14) +hasLocation(#20056,#20057) +#20058=* +tokeninfo(#20058,7,#20001,13,"from") +#20059=@"loc,{#10000},2,16,2,19" +locations_default(#20059,#10000,2,16,2,19) +hasLocation(#20058,#20059) +#20060=* +tokeninfo(#20060,4,#20001,14,"""module""") +#20061=@"loc,{#10000},2,21,2,28" +locations_default(#20061,#10000,2,21,2,28) +hasLocation(#20060,#20061) +#20062=* +tokeninfo(#20062,7,#20001,15,"assert") +#20063=@"loc,{#10000},2,30,2,35" +locations_default(#20063,#10000,2,30,2,35) +hasLocation(#20062,#20063) +#20064=* +tokeninfo(#20064,8,#20001,16,"{") +#20065=@"loc,{#10000},2,37,2,37" +locations_default(#20065,#10000,2,37,2,37) +hasLocation(#20064,#20065) +#20066=* +tokeninfo(#20066,7,#20001,17,"type") +#20067=@"loc,{#10000},2,39,2,42" +locations_default(#20067,#10000,2,39,2,42) +hasLocation(#20066,#20067) +#20068=* +tokeninfo(#20068,8,#20001,18,":") +#20069=@"loc,{#10000},2,43,2,43" +locations_default(#20069,#10000,2,43,2,43) +hasLocation(#20068,#20069) +#20070=* +tokeninfo(#20070,4,#20001,19,"""json""") +#20071=@"loc,{#10000},2,45,2,50" +locations_default(#20071,#10000,2,45,2,50) +hasLocation(#20070,#20071) +#20072=* +tokeninfo(#20072,8,#20001,20,"}") +#20073=@"loc,{#10000},2,52,2,52" +locations_default(#20073,#10000,2,52,2,52) +hasLocation(#20072,#20073) +#20074=* +tokeninfo(#20074,8,#20001,21,";") +#20075=@"loc,{#10000},2,53,2,53" +locations_default(#20075,#10000,2,53,2,53) +hasLocation(#20074,#20075) +#20076=* +tokeninfo(#20076,7,#20001,22,"import") +#20077=@"loc,{#10000},3,1,3,6" +locations_default(#20077,#10000,3,1,3,6) +hasLocation(#20076,#20077) +#20078=* +tokeninfo(#20078,8,#20001,23,"{") +#20079=@"loc,{#10000},3,8,3,8" +locations_default(#20079,#10000,3,8,3,8) +hasLocation(#20078,#20079) +#20080=* +tokeninfo(#20080,6,#20001,24,"v2") +#20081=@"loc,{#10000},3,10,3,11" +locations_default(#20081,#10000,3,10,3,11) +hasLocation(#20080,#20081) +#20082=* +tokeninfo(#20082,8,#20001,25,"}") +#20083=@"loc,{#10000},3,13,3,13" +locations_default(#20083,#10000,3,13,3,13) +hasLocation(#20082,#20083) +#20084=* +tokeninfo(#20084,7,#20001,26,"from") +#20085=@"loc,{#10000},3,15,3,18" +locations_default(#20085,#10000,3,15,3,18) +hasLocation(#20084,#20085) +#20086=* +tokeninfo(#20086,4,#20001,27,"""module""") +#20087=@"loc,{#10000},3,20,3,27" +locations_default(#20087,#10000,3,20,3,27) +hasLocation(#20086,#20087) +#20088=* +tokeninfo(#20088,7,#20001,28,"assert") +#20089=@"loc,{#10000},3,29,3,34" +locations_default(#20089,#10000,3,29,3,34) +hasLocation(#20088,#20089) +#20090=* +tokeninfo(#20090,8,#20001,29,"{") +#20091=@"loc,{#10000},3,36,3,36" +locations_default(#20091,#10000,3,36,3,36) +hasLocation(#20090,#20091) +#20092=* +tokeninfo(#20092,7,#20001,30,"type") +#20093=@"loc,{#10000},3,38,3,41" +locations_default(#20093,#10000,3,38,3,41) +hasLocation(#20092,#20093) +#20094=* +tokeninfo(#20094,8,#20001,31,":") +#20095=@"loc,{#10000},3,42,3,42" +locations_default(#20095,#10000,3,42,3,42) +hasLocation(#20094,#20095) +#20096=* +tokeninfo(#20096,4,#20001,32,"""json""") +#20097=@"loc,{#10000},3,44,3,49" +locations_default(#20097,#10000,3,44,3,49) +hasLocation(#20096,#20097) +#20098=* +tokeninfo(#20098,8,#20001,33,"}") +#20099=@"loc,{#10000},3,51,3,51" +locations_default(#20099,#10000,3,51,3,51) +hasLocation(#20098,#20099) +#20100=* +tokeninfo(#20100,8,#20001,34,";") +#20101=@"loc,{#10000},3,52,3,52" +locations_default(#20101,#10000,3,52,3,52) +hasLocation(#20100,#20101) +#20102=* +tokeninfo(#20102,7,#20001,35,"import") +#20103=@"loc,{#10000},4,1,4,6" +locations_default(#20103,#10000,4,1,4,6) +hasLocation(#20102,#20103) +#20104=* +tokeninfo(#20104,6,#20001,36,"v3") +#20105=@"loc,{#10000},4,8,4,9" +locations_default(#20105,#10000,4,8,4,9) +hasLocation(#20104,#20105) +#20106=* +tokeninfo(#20106,7,#20001,37,"from") +#20107=@"loc,{#10000},4,11,4,14" +locations_default(#20107,#10000,4,11,4,14) +hasLocation(#20106,#20107) +#20108=* +tokeninfo(#20108,4,#20001,38,"""module""") +#20109=@"loc,{#10000},4,16,4,23" +locations_default(#20109,#10000,4,16,4,23) +hasLocation(#20108,#20109) +#20110=* +tokeninfo(#20110,7,#20001,39,"assert") +#20111=@"loc,{#10000},4,25,4,30" +locations_default(#20111,#10000,4,25,4,30) +hasLocation(#20110,#20111) +#20112=* +tokeninfo(#20112,8,#20001,40,"{") +#20113=@"loc,{#10000},4,32,4,32" +locations_default(#20113,#10000,4,32,4,32) +hasLocation(#20112,#20113) +#20114=* +tokeninfo(#20114,7,#20001,41,"type") +#20115=@"loc,{#10000},4,34,4,37" +locations_default(#20115,#10000,4,34,4,37) +hasLocation(#20114,#20115) +#20116=* +tokeninfo(#20116,8,#20001,42,":") +#20117=@"loc,{#10000},4,38,4,38" +locations_default(#20117,#10000,4,38,4,38) +hasLocation(#20116,#20117) +#20118=* +tokeninfo(#20118,4,#20001,43,"""json""") +#20119=@"loc,{#10000},4,40,4,45" +locations_default(#20119,#10000,4,40,4,45) +hasLocation(#20118,#20119) +#20120=* +tokeninfo(#20120,8,#20001,44,"}") +#20121=@"loc,{#10000},4,47,4,47" +locations_default(#20121,#10000,4,47,4,47) +hasLocation(#20120,#20121) +#20122=* +tokeninfo(#20122,8,#20001,45,";") +#20123=@"loc,{#10000},4,48,4,48" +locations_default(#20123,#10000,4,48,4,48) +hasLocation(#20122,#20123) +#20124=* +tokeninfo(#20124,7,#20001,46,"export") +#20125=@"loc,{#10000},6,1,6,6" +locations_default(#20125,#10000,6,1,6,6) +hasLocation(#20124,#20125) +#20126=* +tokeninfo(#20126,8,#20001,47,"{") +#20127=@"loc,{#10000},6,8,6,8" +locations_default(#20127,#10000,6,8,6,8) +hasLocation(#20126,#20127) +#20128=* +tokeninfo(#20128,6,#20001,48,"v4") +#20129=@"loc,{#10000},6,10,6,11" +locations_default(#20129,#10000,6,10,6,11) +hasLocation(#20128,#20129) +#20130=* +tokeninfo(#20130,8,#20001,49,"}") +#20131=@"loc,{#10000},6,13,6,13" +locations_default(#20131,#10000,6,13,6,13) +hasLocation(#20130,#20131) +#20132=* +tokeninfo(#20132,7,#20001,50,"from") +#20133=@"loc,{#10000},6,15,6,18" +locations_default(#20133,#10000,6,15,6,18) +hasLocation(#20132,#20133) +#20134=* +tokeninfo(#20134,4,#20001,51,"""module""") +#20135=@"loc,{#10000},6,20,6,27" +locations_default(#20135,#10000,6,20,6,27) +hasLocation(#20134,#20135) +#20136=* +tokeninfo(#20136,7,#20001,52,"assert") +#20137=@"loc,{#10000},6,29,6,34" +locations_default(#20137,#10000,6,29,6,34) +hasLocation(#20136,#20137) +#20138=* +tokeninfo(#20138,8,#20001,53,"{") +#20139=@"loc,{#10000},6,36,6,36" +locations_default(#20139,#10000,6,36,6,36) +hasLocation(#20138,#20139) +#20140=* +tokeninfo(#20140,7,#20001,54,"type") +#20141=@"loc,{#10000},6,38,6,41" +locations_default(#20141,#10000,6,38,6,41) +hasLocation(#20140,#20141) +#20142=* +tokeninfo(#20142,8,#20001,55,":") +#20143=@"loc,{#10000},6,42,6,42" +locations_default(#20143,#10000,6,42,6,42) +hasLocation(#20142,#20143) +#20144=* +tokeninfo(#20144,4,#20001,56,"""json""") +#20145=@"loc,{#10000},6,44,6,49" +locations_default(#20145,#10000,6,44,6,49) +hasLocation(#20144,#20145) +#20146=* +tokeninfo(#20146,8,#20001,57,"}") +#20147=@"loc,{#10000},6,51,6,51" +locations_default(#20147,#10000,6,51,6,51) +hasLocation(#20146,#20147) +#20148=* +tokeninfo(#20148,8,#20001,58,";") +#20149=@"loc,{#10000},6,52,6,52" +locations_default(#20149,#10000,6,52,6,52) +hasLocation(#20148,#20149) +#20150=* +tokeninfo(#20150,7,#20001,59,"export") +#20151=@"loc,{#10000},7,1,7,6" +locations_default(#20151,#10000,7,1,7,6) +hasLocation(#20150,#20151) +#20152=* +tokeninfo(#20152,8,#20001,60,"*") +#20153=@"loc,{#10000},7,8,7,8" +locations_default(#20153,#10000,7,8,7,8) +hasLocation(#20152,#20153) +#20154=* +tokeninfo(#20154,7,#20001,61,"from") +#20155=@"loc,{#10000},7,10,7,13" +locations_default(#20155,#10000,7,10,7,13) +hasLocation(#20154,#20155) +#20156=* +tokeninfo(#20156,4,#20001,62,"""module""") +#20157=@"loc,{#10000},7,15,7,22" +locations_default(#20157,#10000,7,15,7,22) +hasLocation(#20156,#20157) +#20158=* +tokeninfo(#20158,7,#20001,63,"assert") +#20159=@"loc,{#10000},7,24,7,29" +locations_default(#20159,#10000,7,24,7,29) +hasLocation(#20158,#20159) +#20160=* +tokeninfo(#20160,8,#20001,64,"{") +#20161=@"loc,{#10000},7,31,7,31" +locations_default(#20161,#10000,7,31,7,31) +hasLocation(#20160,#20161) +#20162=* +tokeninfo(#20162,7,#20001,65,"type") +#20163=@"loc,{#10000},7,33,7,36" +locations_default(#20163,#10000,7,33,7,36) +hasLocation(#20162,#20163) +#20164=* +tokeninfo(#20164,8,#20001,66,":") +#20165=@"loc,{#10000},7,37,7,37" +locations_default(#20165,#10000,7,37,7,37) +hasLocation(#20164,#20165) +#20166=* +tokeninfo(#20166,4,#20001,67,"""json""") +#20167=@"loc,{#10000},7,39,7,44" +locations_default(#20167,#10000,7,39,7,44) +hasLocation(#20166,#20167) +#20168=* +tokeninfo(#20168,8,#20001,68,"}") +#20169=@"loc,{#10000},7,46,7,46" +locations_default(#20169,#10000,7,46,7,46) +hasLocation(#20168,#20169) +#20170=* +tokeninfo(#20170,8,#20001,69,";") +#20171=@"loc,{#10000},7,47,7,47" +locations_default(#20171,#10000,7,47,7,47) +hasLocation(#20170,#20171) +#20172=* +tokeninfo(#20172,7,#20001,70,"export") +#20173=@"loc,{#10000},8,1,8,6" +locations_default(#20173,#10000,8,1,8,6) +hasLocation(#20172,#20173) +#20174=* +tokeninfo(#20174,8,#20001,71,"*") +#20175=@"loc,{#10000},8,8,8,8" +locations_default(#20175,#10000,8,8,8,8) +hasLocation(#20174,#20175) +#20176=* +tokeninfo(#20176,7,#20001,72,"as") +#20177=@"loc,{#10000},8,10,8,11" +locations_default(#20177,#10000,8,10,8,11) +hasLocation(#20176,#20177) +#20178=* +tokeninfo(#20178,6,#20001,73,"v5") +#20179=@"loc,{#10000},8,13,8,14" +locations_default(#20179,#10000,8,13,8,14) +hasLocation(#20178,#20179) +#20180=* +tokeninfo(#20180,7,#20001,74,"from") +#20181=@"loc,{#10000},8,16,8,19" +locations_default(#20181,#10000,8,16,8,19) +hasLocation(#20180,#20181) +#20182=* +tokeninfo(#20182,4,#20001,75,"""module""") +#20183=@"loc,{#10000},8,21,8,28" +locations_default(#20183,#10000,8,21,8,28) +hasLocation(#20182,#20183) +#20184=* +tokeninfo(#20184,7,#20001,76,"assert") +#20185=@"loc,{#10000},8,30,8,35" +locations_default(#20185,#10000,8,30,8,35) +hasLocation(#20184,#20185) +#20186=* +tokeninfo(#20186,8,#20001,77,"{") +#20187=@"loc,{#10000},8,37,8,37" +locations_default(#20187,#10000,8,37,8,37) +hasLocation(#20186,#20187) +#20188=* +tokeninfo(#20188,7,#20001,78,"type") +#20189=@"loc,{#10000},8,39,8,42" +locations_default(#20189,#10000,8,39,8,42) +hasLocation(#20188,#20189) +#20190=* +tokeninfo(#20190,8,#20001,79,":") +#20191=@"loc,{#10000},8,43,8,43" +locations_default(#20191,#10000,8,43,8,43) +hasLocation(#20190,#20191) +#20192=* +tokeninfo(#20192,4,#20001,80,"""json""") +#20193=@"loc,{#10000},8,45,8,50" +locations_default(#20193,#10000,8,45,8,50) +hasLocation(#20192,#20193) +#20194=* +tokeninfo(#20194,8,#20001,81,"}") +#20195=@"loc,{#10000},8,52,8,52" +locations_default(#20195,#10000,8,52,8,52) +hasLocation(#20194,#20195) +#20196=* +tokeninfo(#20196,8,#20001,82,";") +#20197=@"loc,{#10000},8,53,8,53" +locations_default(#20197,#10000,8,53,8,53) +hasLocation(#20196,#20197) +#20198=* +tokeninfo(#20198,7,#20001,83,"const") +#20199=@"loc,{#10000},10,1,10,5" +locations_default(#20199,#10000,10,1,10,5) +hasLocation(#20198,#20199) +#20200=* +tokeninfo(#20200,6,#20001,84,"v6") +#20201=@"loc,{#10000},10,7,10,8" +locations_default(#20201,#10000,10,7,10,8) +hasLocation(#20200,#20201) +#20202=* +tokeninfo(#20202,8,#20001,85,"=") +#20203=@"loc,{#10000},10,10,10,10" +locations_default(#20203,#10000,10,10,10,10) +hasLocation(#20202,#20203) +#20204=* +tokeninfo(#20204,7,#20001,86,"import") +#20205=@"loc,{#10000},10,12,10,17" +locations_default(#20205,#10000,10,12,10,17) +hasLocation(#20204,#20205) +#20206=* +tokeninfo(#20206,8,#20001,87,"(") +#20207=@"loc,{#10000},10,18,10,18" +locations_default(#20207,#10000,10,18,10,18) +hasLocation(#20206,#20207) +#20208=* +tokeninfo(#20208,4,#20001,88,"""module""") +#20209=@"loc,{#10000},10,19,10,26" +locations_default(#20209,#10000,10,19,10,26) +hasLocation(#20208,#20209) +#20210=* +tokeninfo(#20210,8,#20001,89,",") +#20211=@"loc,{#10000},10,27,10,27" +locations_default(#20211,#10000,10,27,10,27) +hasLocation(#20210,#20211) +#20212=* +tokeninfo(#20212,8,#20001,90,"{") +#20213=@"loc,{#10000},10,29,10,29" +locations_default(#20213,#10000,10,29,10,29) +hasLocation(#20212,#20213) +#20214=* +tokeninfo(#20214,7,#20001,91,"assert") +#20215=@"loc,{#10000},10,31,10,36" +locations_default(#20215,#10000,10,31,10,36) +hasLocation(#20214,#20215) +#20216=* +tokeninfo(#20216,8,#20001,92,":") +#20217=@"loc,{#10000},10,37,10,37" +locations_default(#20217,#10000,10,37,10,37) +hasLocation(#20216,#20217) +#20218=* +tokeninfo(#20218,8,#20001,93,"{") +#20219=@"loc,{#10000},10,39,10,39" +locations_default(#20219,#10000,10,39,10,39) +hasLocation(#20218,#20219) +#20220=* +tokeninfo(#20220,7,#20001,94,"type") +#20221=@"loc,{#10000},10,41,10,44" +locations_default(#20221,#10000,10,41,10,44) +hasLocation(#20220,#20221) +#20222=* +tokeninfo(#20222,8,#20001,95,":") +#20223=@"loc,{#10000},10,45,10,45" +locations_default(#20223,#10000,10,45,10,45) +hasLocation(#20222,#20223) +#20224=* +tokeninfo(#20224,4,#20001,96,"""json""") +#20225=@"loc,{#10000},10,47,10,52" +locations_default(#20225,#10000,10,47,10,52) +hasLocation(#20224,#20225) +#20226=* +tokeninfo(#20226,8,#20001,97,"}") +#20227=@"loc,{#10000},10,54,10,54" +locations_default(#20227,#10000,10,54,10,54) +hasLocation(#20226,#20227) +#20228=* +tokeninfo(#20228,8,#20001,98,"}") +#20229=@"loc,{#10000},10,56,10,56" +locations_default(#20229,#10000,10,56,10,56) +hasLocation(#20228,#20229) +#20230=* +tokeninfo(#20230,8,#20001,99,")") +#20231=@"loc,{#10000},10,57,10,57" +locations_default(#20231,#10000,10,57,10,57) +hasLocation(#20230,#20231) +#20232=* +tokeninfo(#20232,8,#20001,100,";") +#20233=@"loc,{#10000},10,58,10,58" +locations_default(#20233,#10000,10,58,10,58) +hasLocation(#20232,#20233) +#20234=* +tokeninfo(#20234,7,#20001,101,"import") +#20235=@"loc,{#10000},12,1,12,6" +locations_default(#20235,#10000,12,1,12,6) +hasLocation(#20234,#20235) +#20236=* +tokeninfo(#20236,4,#20001,102,"""module""") +#20237=@"loc,{#10000},12,8,12,15" +locations_default(#20237,#10000,12,8,12,15) +hasLocation(#20236,#20237) +#20238=* +tokeninfo(#20238,8,#20001,103,";") +#20239=@"loc,{#10000},12,16,12,16" +locations_default(#20239,#10000,12,16,12,16) +hasLocation(#20238,#20239) +#20240=* +tokeninfo(#20240,7,#20001,104,"assert") +#20241=@"loc,{#10000},13,1,13,6" +locations_default(#20241,#10000,13,1,13,6) +hasLocation(#20240,#20241) +next_token(#20002,#20240) +#20242=* +tokeninfo(#20242,8,#20001,105,"(") +#20243=@"loc,{#10000},13,7,13,7" +locations_default(#20243,#10000,13,7,13,7) +hasLocation(#20242,#20243) +#20244=* +tokeninfo(#20244,8,#20001,106,"{") +#20245=@"loc,{#10000},13,8,13,8" +locations_default(#20245,#10000,13,8,13,8) +hasLocation(#20244,#20245) +#20246=* +tokeninfo(#20246,7,#20001,107,"type") +#20247=@"loc,{#10000},13,10,13,13" +locations_default(#20247,#10000,13,10,13,13) +hasLocation(#20246,#20247) +#20248=* +tokeninfo(#20248,8,#20001,108,":") +#20249=@"loc,{#10000},13,14,13,14" +locations_default(#20249,#10000,13,14,13,14) +hasLocation(#20248,#20249) +#20250=* +tokeninfo(#20250,4,#20001,109,"""json""") +#20251=@"loc,{#10000},13,16,13,21" +locations_default(#20251,#10000,13,16,13,21) +hasLocation(#20250,#20251) +#20252=* +tokeninfo(#20252,8,#20001,110,"}") +#20253=@"loc,{#10000},13,23,13,23" +locations_default(#20253,#10000,13,23,13,23) +hasLocation(#20252,#20253) +#20254=* +tokeninfo(#20254,8,#20001,111,")") +#20255=@"loc,{#10000},13,24,13,24" +locations_default(#20255,#10000,13,24,13,24) +hasLocation(#20254,#20255) +#20256=* +tokeninfo(#20256,8,#20001,112,";") +#20257=@"loc,{#10000},13,25,13,25" +locations_default(#20257,#10000,13,25,13,25) +hasLocation(#20256,#20257) +#20258=* +tokeninfo(#20258,0,#20001,113,"") +#20259=@"loc,{#10000},14,1,14,0" +locations_default(#20259,#10000,14,1,14,0) +hasLocation(#20258,#20259) +next_token(#20004,#20258) +toplevels(#20001,0) +#20260=@"loc,{#10000},1,1,14,0" +locations_default(#20260,#10000,1,1,14,0) +hasLocation(#20001,#20260) +#20261=@"module;{#10000},1,1" +scopes(#20261,3) +scopenodes(#20001,#20261) +scopenesting(#20261,#20000) +is_module(#20001) +is_es2015_module(#20001) +#20262=@"var;{v1};{#20261}" +variables(#20262,"v1",#20261) +#20263=@"var;{v2};{#20261}" +variables(#20263,"v2",#20261) +#20264=@"var;{v3};{#20261}" +variables(#20264,"v3",#20261) +#20265=@"local_type_name;{v1};{#20261}" +local_type_names(#20265,"v1",#20261) +#20266=@"local_type_name;{v2};{#20261}" +local_type_names(#20266,"v2",#20261) +#20267=@"local_type_name;{v3};{#20261}" +local_type_names(#20267,"v3",#20261) +#20268=@"local_namespace_name;{v1};{#20261}" +local_namespace_names(#20268,"v1",#20261) +#20269=@"local_namespace_name;{v2};{#20261}" +local_namespace_names(#20269,"v2",#20261) +#20270=@"local_namespace_name;{v3};{#20261}" +local_namespace_names(#20270,"v3",#20261) +variables(#20262,"v1",#20261) +variables(#20263,"v2",#20261) +variables(#20264,"v3",#20261) +#20271=@"var;{v6};{#20261}" +variables(#20271,"v6",#20261) +local_type_names(#20265,"v1",#20261) +local_type_names(#20266,"v2",#20261) +local_type_names(#20267,"v3",#20261) +local_namespace_names(#20268,"v1",#20261) +local_namespace_names(#20269,"v2",#20261) +local_namespace_names(#20270,"v3",#20261) +#20272=* +stmts(#20272,27,#20001,0,"import ... son"" };") +hasLocation(#20272,#20007) +stmt_containers(#20272,#20001) +#20273=* +exprs(#20273,4,#20272,-1,"""module""") +hasLocation(#20273,#20035) +enclosing_stmt(#20273,#20272) +expr_containers(#20273,#20001) +literals("module","""module""",#20273) +#20274=* +regexpterm(#20274,14,#20273,0,"module") +#20275=@"loc,{#10000},1,9,1,14" +locations_default(#20275,#10000,1,9,1,14) +hasLocation(#20274,#20275) +regexp_const_value(#20274,"module") +#20276=* +stmts(#20276,27,#20001,1,"import ... son"" };") +hasLocation(#20276,#20009) +stmt_containers(#20276,#20001) +#20277=* +exprs(#20277,4,#20276,-1,"""module""") +hasLocation(#20277,#20061) +enclosing_stmt(#20277,#20276) +expr_containers(#20277,#20001) +literals("module","""module""",#20277) +#20278=* +regexpterm(#20278,14,#20277,0,"module") +#20279=@"loc,{#10000},2,22,2,27" +locations_default(#20279,#10000,2,22,2,27) +hasLocation(#20278,#20279) +regexp_const_value(#20278,"module") +#20280=* +exprs(#20280,85,#20276,0,"* as v1") +#20281=@"loc,{#10000},2,8,2,14" +locations_default(#20281,#10000,2,8,2,14) +hasLocation(#20280,#20281) +enclosing_stmt(#20280,#20276) +expr_containers(#20280,#20001) +#20282=* +exprs(#20282,78,#20280,1,"v1") +hasLocation(#20282,#20057) +enclosing_stmt(#20282,#20276) +expr_containers(#20282,#20001) +literals("v1","v1",#20282) +decl(#20282,#20262) +typedecl(#20282,#20265) +namespacedecl(#20282,#20268) +#20283=* +stmts(#20283,27,#20001,2,"import ... son"" };") +hasLocation(#20283,#20011) +stmt_containers(#20283,#20001) +#20284=* +exprs(#20284,4,#20283,-1,"""module""") +hasLocation(#20284,#20087) +enclosing_stmt(#20284,#20283) +expr_containers(#20284,#20001) +literals("module","""module""",#20284) +#20285=* +regexpterm(#20285,14,#20284,0,"module") +#20286=@"loc,{#10000},3,21,3,26" +locations_default(#20286,#10000,3,21,3,26) +hasLocation(#20285,#20286) +regexp_const_value(#20285,"module") +#20287=* +exprs(#20287,83,#20283,0,"v2") +hasLocation(#20287,#20081) +enclosing_stmt(#20287,#20283) +expr_containers(#20287,#20001) +#20288=* +exprs(#20288,0,#20287,0,"v2") +hasLocation(#20288,#20081) +enclosing_stmt(#20288,#20283) +expr_containers(#20288,#20001) +literals("v2","v2",#20288) +#20289=* +exprs(#20289,78,#20287,1,"v2") +hasLocation(#20289,#20081) +enclosing_stmt(#20289,#20283) +expr_containers(#20289,#20001) +literals("v2","v2",#20289) +decl(#20289,#20263) +typedecl(#20289,#20266) +namespacedecl(#20289,#20269) +#20290=* +stmts(#20290,27,#20001,3,"import ... son"" };") +hasLocation(#20290,#20013) +stmt_containers(#20290,#20001) +#20291=* +exprs(#20291,4,#20290,-1,"""module""") +hasLocation(#20291,#20109) +enclosing_stmt(#20291,#20290) +expr_containers(#20291,#20001) +literals("module","""module""",#20291) +#20292=* +regexpterm(#20292,14,#20291,0,"module") +#20293=@"loc,{#10000},4,17,4,22" +locations_default(#20293,#10000,4,17,4,22) +hasLocation(#20292,#20293) +regexp_const_value(#20292,"module") +#20294=* +exprs(#20294,84,#20290,0,"v3") +hasLocation(#20294,#20105) +enclosing_stmt(#20294,#20290) +expr_containers(#20294,#20001) +#20295=* +exprs(#20295,78,#20294,1,"v3") +hasLocation(#20295,#20105) +enclosing_stmt(#20295,#20290) +expr_containers(#20295,#20001) +literals("v3","v3",#20295) +decl(#20295,#20264) +typedecl(#20295,#20267) +namespacedecl(#20295,#20270) +#20296=* +stmts(#20296,30,#20001,4,"export ... son"" };") +hasLocation(#20296,#20017) +stmt_containers(#20296,#20001) +#20297=* +exprs(#20297,4,#20296,-2,"""module""") +hasLocation(#20297,#20135) +enclosing_stmt(#20297,#20296) +expr_containers(#20297,#20001) +literals("module","""module""",#20297) +#20298=* +regexpterm(#20298,14,#20297,0,"module") +#20299=@"loc,{#10000},6,21,6,26" +locations_default(#20299,#10000,6,21,6,26) +hasLocation(#20298,#20299) +regexp_const_value(#20298,"module") +#20300=* +exprs(#20300,86,#20296,0,"v4") +hasLocation(#20300,#20129) +enclosing_stmt(#20300,#20296) +expr_containers(#20300,#20001) +#20301=* +exprs(#20301,0,#20300,0,"v4") +hasLocation(#20301,#20129) +enclosing_stmt(#20301,#20296) +expr_containers(#20301,#20001) +literals("v4","v4",#20301) +#20302=* +exprs(#20302,0,#20300,1,"v4") +hasLocation(#20302,#20129) +enclosing_stmt(#20302,#20296) +expr_containers(#20302,#20001) +literals("v4","v4",#20302) +#20303=* +stmts(#20303,28,#20001,5,"export ... son"" };") +hasLocation(#20303,#20019) +stmt_containers(#20303,#20001) +#20304=* +exprs(#20304,4,#20303,0,"""module""") +hasLocation(#20304,#20157) +enclosing_stmt(#20304,#20303) +expr_containers(#20304,#20001) +literals("module","""module""",#20304) +#20305=* +regexpterm(#20305,14,#20304,0,"module") +#20306=@"loc,{#10000},7,16,7,21" +locations_default(#20306,#10000,7,16,7,21) +hasLocation(#20305,#20306) +regexp_const_value(#20305,"module") +#20307=* +stmts(#20307,30,#20001,6,"export ... son"" };") +hasLocation(#20307,#20021) +stmt_containers(#20307,#20001) +#20308=* +exprs(#20308,4,#20307,-2,"""module""") +hasLocation(#20308,#20183) +enclosing_stmt(#20308,#20307) +expr_containers(#20308,#20001) +literals("module","""module""",#20308) +#20309=* +regexpterm(#20309,14,#20308,0,"module") +#20310=@"loc,{#10000},8,22,8,27" +locations_default(#20310,#10000,8,22,8,27) +hasLocation(#20309,#20310) +regexp_const_value(#20309,"module") +#20311=* +exprs(#20311,96,#20307,0,"* as v5") +#20312=@"loc,{#10000},8,8,8,14" +locations_default(#20312,#10000,8,8,8,14) +hasLocation(#20311,#20312) +enclosing_stmt(#20311,#20307) +expr_containers(#20311,#20001) +#20313=* +exprs(#20313,0,#20311,1,"v5") +hasLocation(#20313,#20179) +enclosing_stmt(#20313,#20307) +expr_containers(#20313,#20001) +literals("v5","v5",#20313) +#20314=* +stmts(#20314,22,#20001,7,"const v ... "" } });") +hasLocation(#20314,#20025) +stmt_containers(#20314,#20001) +#20315=* +exprs(#20315,64,#20314,0,"v6 = im ... n"" } })") +#20316=@"loc,{#10000},10,7,10,57" +locations_default(#20316,#10000,10,7,10,57) +hasLocation(#20315,#20316) +enclosing_stmt(#20315,#20314) +expr_containers(#20315,#20001) +#20317=* +exprs(#20317,78,#20315,0,"v6") +hasLocation(#20317,#20201) +enclosing_stmt(#20317,#20314) +expr_containers(#20317,#20001) +literals("v6","v6",#20317) +decl(#20317,#20271) +#20318=* +exprs(#20318,13,#20315,1,"import( ... n"" } })") +#20319=@"loc,{#10000},10,12,10,57" +locations_default(#20319,#10000,10,12,10,57) +hasLocation(#20318,#20319) +enclosing_stmt(#20318,#20314) +expr_containers(#20318,#20001) +#20320=* +exprs(#20320,79,#20318,-1,"import") +hasLocation(#20320,#20205) +enclosing_stmt(#20320,#20314) +expr_containers(#20320,#20001) +literals("import","import",#20320) +#20321=@"var;{import};{#20000}" +variables(#20321,"import",#20000) +bind(#20320,#20321) +#20322=* +exprs(#20322,4,#20318,0,"""module""") +hasLocation(#20322,#20209) +enclosing_stmt(#20322,#20314) +expr_containers(#20322,#20001) +literals("module","""module""",#20322) +#20323=* +regexpterm(#20323,14,#20322,0,"module") +#20324=@"loc,{#10000},10,20,10,25" +locations_default(#20324,#10000,10,20,10,25) +hasLocation(#20323,#20324) +regexp_const_value(#20323,"module") +#20325=* +exprs(#20325,8,#20318,1,"{ asser ... on"" } }") +#20326=@"loc,{#10000},10,29,10,56" +locations_default(#20326,#10000,10,29,10,56) +hasLocation(#20325,#20326) +enclosing_stmt(#20325,#20314) +expr_containers(#20325,#20001) +#20327=* +properties(#20327,#20325,0,0,"assert: ... json"" }") +#20328=@"loc,{#10000},10,31,10,54" +locations_default(#20328,#10000,10,31,10,54) +hasLocation(#20327,#20328) +#20329=* +exprs(#20329,0,#20327,0,"assert") +hasLocation(#20329,#20215) +enclosing_stmt(#20329,#20314) +expr_containers(#20329,#20001) +literals("assert","assert",#20329) +#20330=* +exprs(#20330,8,#20327,1,"{ type: ""json"" }") +#20331=@"loc,{#10000},10,39,10,54" +locations_default(#20331,#10000,10,39,10,54) +hasLocation(#20330,#20331) +enclosing_stmt(#20330,#20314) +expr_containers(#20330,#20001) +#20332=* +properties(#20332,#20330,0,0,"type: ""json""") +#20333=@"loc,{#10000},10,41,10,52" +locations_default(#20333,#10000,10,41,10,52) +hasLocation(#20332,#20333) +#20334=* +exprs(#20334,0,#20332,0,"type") +hasLocation(#20334,#20221) +enclosing_stmt(#20334,#20314) +expr_containers(#20334,#20001) +literals("type","type",#20334) +#20335=* +exprs(#20335,4,#20332,1,"""json""") +hasLocation(#20335,#20225) +enclosing_stmt(#20335,#20314) +expr_containers(#20335,#20001) +literals("json","""json""",#20335) +#20336=* +regexpterm(#20336,14,#20335,0,"json") +#20337=@"loc,{#10000},10,48,10,51" +locations_default(#20337,#10000,10,48,10,51) +hasLocation(#20336,#20337) +regexp_const_value(#20336,"json") +#20338=* +stmts(#20338,27,#20001,8,"import ""module"";") +#20339=@"loc,{#10000},12,1,12,16" +locations_default(#20339,#10000,12,1,12,16) +hasLocation(#20338,#20339) +stmt_containers(#20338,#20001) +#20340=* +exprs(#20340,4,#20338,-1,"""module""") +hasLocation(#20340,#20237) +enclosing_stmt(#20340,#20338) +expr_containers(#20340,#20001) +literals("module","""module""",#20340) +#20341=* +regexpterm(#20341,14,#20340,0,"module") +#20342=@"loc,{#10000},12,9,12,14" +locations_default(#20342,#10000,12,9,12,14) +hasLocation(#20341,#20342) +regexp_const_value(#20341,"module") +#20343=* +stmts(#20343,2,#20001,9,"assert( ... on"" });") +#20344=@"loc,{#10000},13,1,13,25" +locations_default(#20344,#10000,13,1,13,25) +hasLocation(#20343,#20344) +stmt_containers(#20343,#20001) +#20345=* +exprs(#20345,13,#20343,0,"assert( ... son"" })") +#20346=@"loc,{#10000},13,1,13,24" +locations_default(#20346,#10000,13,1,13,24) +hasLocation(#20345,#20346) +enclosing_stmt(#20345,#20343) +expr_containers(#20345,#20001) +#20347=* +exprs(#20347,79,#20345,-1,"assert") +hasLocation(#20347,#20241) +enclosing_stmt(#20347,#20343) +expr_containers(#20347,#20001) +literals("assert","assert",#20347) +#20348=@"var;{assert};{#20000}" +variables(#20348,"assert",#20000) +bind(#20347,#20348) +#20349=* +exprs(#20349,8,#20345,0,"{ type: ""json"" }") +#20350=@"loc,{#10000},13,8,13,23" +locations_default(#20350,#10000,13,8,13,23) +hasLocation(#20349,#20350) +enclosing_stmt(#20349,#20343) +expr_containers(#20349,#20001) +#20351=* +properties(#20351,#20349,0,0,"type: ""json""") +#20352=@"loc,{#10000},13,10,13,21" +locations_default(#20352,#10000,13,10,13,21) +hasLocation(#20351,#20352) +#20353=* +exprs(#20353,0,#20351,0,"type") +hasLocation(#20353,#20247) +enclosing_stmt(#20353,#20343) +expr_containers(#20353,#20001) +literals("type","type",#20353) +#20354=* +exprs(#20354,4,#20351,1,"""json""") +hasLocation(#20354,#20251) +enclosing_stmt(#20354,#20343) +expr_containers(#20354,#20001) +literals("json","""json""",#20354) +#20355=* +regexpterm(#20355,14,#20354,0,"json") +#20356=@"loc,{#10000},13,17,13,20" +locations_default(#20356,#10000,13,17,13,20) +hasLocation(#20355,#20356) +regexp_const_value(#20355,"json") +#20357=* +entry_cfg_node(#20357,#20001) +#20358=@"loc,{#10000},1,1,1,0" +locations_default(#20358,#10000,1,1,1,0) +hasLocation(#20357,#20358) +#20359=* +exit_cfg_node(#20359,#20001) +hasLocation(#20359,#20259) +successor(#20343,#20347) +successor(#20349,#20353) +successor(#20354,#20351) +successor(#20353,#20354) +successor(#20351,#20345) +successor(#20347,#20349) +successor(#20345,#20359) +successor(#20338,#20343) +successor(#20314,#20317) +successor(#20325,#20329) +successor(#20330,#20334) +successor(#20335,#20332) +successor(#20334,#20335) +successor(#20332,#20327) +successor(#20329,#20330) +successor(#20327,#20318) +successor(#20322,#20325) +successor(#20320,#20322) +successor(#20318,#20315) +successor(#20317,#20320) +successor(#20315,#20338) +successor(#20307,#20308) +successor(#20311,#20313) +successor(#20313,#20314) +successor(#20308,#20311) +successor(#20303,#20304) +successor(#20304,#20307) +successor(#20296,#20297) +successor(#20300,#20301) +successor(#20302,#20303) +successor(#20301,#20302) +successor(#20297,#20300) +successor(#20290,#20296) +successor(#20283,#20290) +successor(#20276,#20283) +successor(#20272,#20276) +successor(#20294,#20272) +successor(#20287,#20294) +successor(#20280,#20287) +successor(#20357,#20280) +numlines(#10000,13,10,2) +filetype(#10000,"typescript") From 38194c6ae7095ac981b2af1abe5e35c50fd05dd4 Mon Sep 17 00:00:00 2001 From: Asger F Date: Fri, 3 Mar 2023 11:35:24 +0100 Subject: [PATCH 025/135] JS: Extract import assertions to DB --- .../com/semmle/js/extractor/ASTExtractor.java | 4 + .../output/trap/import-assertion.js.trap | 792 ++++++++++++------ .../ts/output/trap/import-assertion.ts.trap | 735 ++++++++-------- .../lib/semmle/javascript/ES2015Modules.qll | 23 + javascript/ql/lib/semmle/javascript/Expr.qll | 11 + .../ImportAssertions/js-import-assertions.js | 13 + .../TypeScript/ImportAssertions/test.expected | 20 + .../TypeScript/ImportAssertions/test.ql | 13 + .../ImportAssertions/ts-import-assertions.ts | 15 + 9 files changed, 1025 insertions(+), 601 deletions(-) create mode 100644 javascript/ql/test/library-tests/TypeScript/ImportAssertions/js-import-assertions.js create mode 100644 javascript/ql/test/library-tests/TypeScript/ImportAssertions/test.expected create mode 100644 javascript/ql/test/library-tests/TypeScript/ImportAssertions/test.ql create mode 100644 javascript/ql/test/library-tests/TypeScript/ImportAssertions/ts-import-assertions.ts diff --git a/javascript/extractor/src/com/semmle/js/extractor/ASTExtractor.java b/javascript/extractor/src/com/semmle/js/extractor/ASTExtractor.java index 0a85e1e87f0..b0b88854239 100644 --- a/javascript/extractor/src/com/semmle/js/extractor/ASTExtractor.java +++ b/javascript/extractor/src/com/semmle/js/extractor/ASTExtractor.java @@ -1759,6 +1759,7 @@ public class ASTExtractor { public Label visit(ExportAllDeclaration nd, Context c) { Label lbl = super.visit(nd, c); visit(nd.getSource(), lbl, 0); + visit(nd.getAssertion(), lbl, -10); return lbl; } @@ -1774,6 +1775,7 @@ public class ASTExtractor { Label lbl = super.visit(nd, c); visit(nd.getDeclaration(), lbl, -1); visit(nd.getSource(), lbl, -2); + visit(nd.getAssertion(), lbl, -10); IdContext childContext = nd.hasSource() ? IdContext.LABEL @@ -1797,6 +1799,7 @@ public class ASTExtractor { public Label visit(ImportDeclaration nd, Context c) { Label lbl = super.visit(nd, c); visit(nd.getSource(), lbl, -1); + visit(nd.getAssertion(), lbl, -10); IdContext childContext = nd.hasTypeKeyword() ? IdContext.TYPE_ONLY_IMPORT @@ -1972,6 +1975,7 @@ public class ASTExtractor { public Label visit(DynamicImport nd, Context c) { Label key = super.visit(nd, c); visit(nd.getSource(), key, 0); + visit(nd.getAttributes(), key, 1); return key; } diff --git a/javascript/extractor/tests/esnext/output/trap/import-assertion.js.trap b/javascript/extractor/tests/esnext/output/trap/import-assertion.js.trap index 4ab0cc54f6d..88f32abcfbf 100644 --- a/javascript/extractor/tests/esnext/output/trap/import-assertion.js.trap +++ b/javascript/extractor/tests/esnext/output/trap/import-assertion.js.trap @@ -721,327 +721,585 @@ locations_default(#20273,#10000,1,9,1,14) hasLocation(#20272,#20273) regexp_const_value(#20272,"module") #20274=* -stmts(#20274,27,#20001,1,"import ... son"" };") -hasLocation(#20274,#20009) -stmt_containers(#20274,#20001) -#20275=* -exprs(#20275,4,#20274,-1,"""module""") -hasLocation(#20275,#20061) -enclosing_stmt(#20275,#20274) -expr_containers(#20275,#20001) -literals("module","""module""",#20275) +exprs(#20274,8,#20270,-10,"{ type: ""json"" }") +#20275=@"loc,{#10000},1,24,1,39" +locations_default(#20275,#10000,1,24,1,39) +hasLocation(#20274,#20275) +enclosing_stmt(#20274,#20270) +expr_containers(#20274,#20001) #20276=* -regexpterm(#20276,14,#20275,0,"module") -#20277=@"loc,{#10000},2,22,2,27" -locations_default(#20277,#10000,2,22,2,27) +properties(#20276,#20274,0,0,"type: ""json""") +#20277=@"loc,{#10000},1,26,1,37" +locations_default(#20277,#10000,1,26,1,37) hasLocation(#20276,#20277) -regexp_const_value(#20276,"module") #20278=* -exprs(#20278,85,#20274,0,"* as v1") -#20279=@"loc,{#10000},2,8,2,14" -locations_default(#20279,#10000,2,8,2,14) -hasLocation(#20278,#20279) -enclosing_stmt(#20278,#20274) +exprs(#20278,0,#20276,0,"type") +hasLocation(#20278,#20041) +enclosing_stmt(#20278,#20270) expr_containers(#20278,#20001) +literals("type","type",#20278) +#20279=* +exprs(#20279,4,#20276,1,"""json""") +hasLocation(#20279,#20045) +enclosing_stmt(#20279,#20270) +expr_containers(#20279,#20001) +literals("json","""json""",#20279) #20280=* -exprs(#20280,78,#20278,1,"v1") -hasLocation(#20280,#20057) -enclosing_stmt(#20280,#20274) -expr_containers(#20280,#20001) -literals("v1","v1",#20280) -decl(#20280,#20260) -typedecl(#20280,#20263) -namespacedecl(#20280,#20266) -#20281=* -stmts(#20281,27,#20001,2,"import ... son"" };") -hasLocation(#20281,#20011) -stmt_containers(#20281,#20001) +regexpterm(#20280,14,#20279,0,"json") +#20281=@"loc,{#10000},1,33,1,36" +locations_default(#20281,#10000,1,33,1,36) +hasLocation(#20280,#20281) +regexp_const_value(#20280,"json") #20282=* -exprs(#20282,4,#20281,-1,"""module""") -hasLocation(#20282,#20087) -enclosing_stmt(#20282,#20281) -expr_containers(#20282,#20001) -literals("module","""module""",#20282) +stmts(#20282,27,#20001,1,"import ... son"" };") +hasLocation(#20282,#20009) +stmt_containers(#20282,#20001) #20283=* -regexpterm(#20283,14,#20282,0,"module") -#20284=@"loc,{#10000},3,21,3,26" -locations_default(#20284,#10000,3,21,3,26) -hasLocation(#20283,#20284) -regexp_const_value(#20283,"module") -#20285=* -exprs(#20285,83,#20281,0,"v2") -hasLocation(#20285,#20081) -enclosing_stmt(#20285,#20281) -expr_containers(#20285,#20001) +exprs(#20283,4,#20282,-1,"""module""") +hasLocation(#20283,#20061) +enclosing_stmt(#20283,#20282) +expr_containers(#20283,#20001) +literals("module","""module""",#20283) +#20284=* +regexpterm(#20284,14,#20283,0,"module") +#20285=@"loc,{#10000},2,22,2,27" +locations_default(#20285,#10000,2,22,2,27) +hasLocation(#20284,#20285) +regexp_const_value(#20284,"module") #20286=* -exprs(#20286,0,#20285,0,"v2") -hasLocation(#20286,#20081) -enclosing_stmt(#20286,#20281) +exprs(#20286,8,#20282,-10,"{ type: ""json"" }") +#20287=@"loc,{#10000},2,37,2,52" +locations_default(#20287,#10000,2,37,2,52) +hasLocation(#20286,#20287) +enclosing_stmt(#20286,#20282) expr_containers(#20286,#20001) -literals("v2","v2",#20286) -#20287=* -exprs(#20287,78,#20285,1,"v2") -hasLocation(#20287,#20081) -enclosing_stmt(#20287,#20281) -expr_containers(#20287,#20001) -literals("v2","v2",#20287) -decl(#20287,#20261) -typedecl(#20287,#20264) -namespacedecl(#20287,#20267) #20288=* -stmts(#20288,27,#20001,3,"import ... son"" };") -hasLocation(#20288,#20013) -stmt_containers(#20288,#20001) -#20289=* -exprs(#20289,4,#20288,-1,"""module""") -hasLocation(#20289,#20109) -enclosing_stmt(#20289,#20288) -expr_containers(#20289,#20001) -literals("module","""module""",#20289) +properties(#20288,#20286,0,0,"type: ""json""") +#20289=@"loc,{#10000},2,39,2,50" +locations_default(#20289,#10000,2,39,2,50) +hasLocation(#20288,#20289) #20290=* -regexpterm(#20290,14,#20289,0,"module") -#20291=@"loc,{#10000},4,17,4,22" -locations_default(#20291,#10000,4,17,4,22) -hasLocation(#20290,#20291) -regexp_const_value(#20290,"module") +exprs(#20290,0,#20288,0,"type") +hasLocation(#20290,#20067) +enclosing_stmt(#20290,#20282) +expr_containers(#20290,#20001) +literals("type","type",#20290) +#20291=* +exprs(#20291,4,#20288,1,"""json""") +hasLocation(#20291,#20071) +enclosing_stmt(#20291,#20282) +expr_containers(#20291,#20001) +literals("json","""json""",#20291) #20292=* -exprs(#20292,84,#20288,0,"v3") -hasLocation(#20292,#20105) -enclosing_stmt(#20292,#20288) -expr_containers(#20292,#20001) -#20293=* -exprs(#20293,78,#20292,1,"v3") -hasLocation(#20293,#20105) -enclosing_stmt(#20293,#20288) -expr_containers(#20293,#20001) -literals("v3","v3",#20293) -decl(#20293,#20262) -typedecl(#20293,#20265) -namespacedecl(#20293,#20268) +regexpterm(#20292,14,#20291,0,"json") +#20293=@"loc,{#10000},2,46,2,49" +locations_default(#20293,#10000,2,46,2,49) +hasLocation(#20292,#20293) +regexp_const_value(#20292,"json") #20294=* -stmts(#20294,30,#20001,4,"export ... son"" };") -hasLocation(#20294,#20017) -stmt_containers(#20294,#20001) -#20295=* -exprs(#20295,4,#20294,-2,"""module""") -hasLocation(#20295,#20135) -enclosing_stmt(#20295,#20294) -expr_containers(#20295,#20001) -literals("module","""module""",#20295) +exprs(#20294,85,#20282,0,"* as v1") +#20295=@"loc,{#10000},2,8,2,14" +locations_default(#20295,#10000,2,8,2,14) +hasLocation(#20294,#20295) +enclosing_stmt(#20294,#20282) +expr_containers(#20294,#20001) #20296=* -regexpterm(#20296,14,#20295,0,"module") -#20297=@"loc,{#10000},6,21,6,26" -locations_default(#20297,#10000,6,21,6,26) -hasLocation(#20296,#20297) -regexp_const_value(#20296,"module") +exprs(#20296,78,#20294,1,"v1") +hasLocation(#20296,#20057) +enclosing_stmt(#20296,#20282) +expr_containers(#20296,#20001) +literals("v1","v1",#20296) +decl(#20296,#20260) +typedecl(#20296,#20263) +namespacedecl(#20296,#20266) +#20297=* +stmts(#20297,27,#20001,2,"import ... son"" };") +hasLocation(#20297,#20011) +stmt_containers(#20297,#20001) #20298=* -exprs(#20298,86,#20294,0,"v4") -hasLocation(#20298,#20129) -enclosing_stmt(#20298,#20294) +exprs(#20298,4,#20297,-1,"""module""") +hasLocation(#20298,#20087) +enclosing_stmt(#20298,#20297) expr_containers(#20298,#20001) +literals("module","""module""",#20298) #20299=* -exprs(#20299,0,#20298,0,"v4") -hasLocation(#20299,#20129) -enclosing_stmt(#20299,#20294) -expr_containers(#20299,#20001) -literals("v4","v4",#20299) -#20300=* -exprs(#20300,0,#20298,1,"v4") -hasLocation(#20300,#20129) -enclosing_stmt(#20300,#20294) -expr_containers(#20300,#20001) -literals("v4","v4",#20300) +regexpterm(#20299,14,#20298,0,"module") +#20300=@"loc,{#10000},3,21,3,26" +locations_default(#20300,#10000,3,21,3,26) +hasLocation(#20299,#20300) +regexp_const_value(#20299,"module") #20301=* -stmts(#20301,28,#20001,5,"export ... son"" };") -hasLocation(#20301,#20019) -stmt_containers(#20301,#20001) -#20302=* -exprs(#20302,4,#20301,0,"""module""") -hasLocation(#20302,#20157) -enclosing_stmt(#20302,#20301) -expr_containers(#20302,#20001) -literals("module","""module""",#20302) +exprs(#20301,8,#20297,-10,"{ type: ""json"" }") +#20302=@"loc,{#10000},3,36,3,51" +locations_default(#20302,#10000,3,36,3,51) +hasLocation(#20301,#20302) +enclosing_stmt(#20301,#20297) +expr_containers(#20301,#20001) #20303=* -regexpterm(#20303,14,#20302,0,"module") -#20304=@"loc,{#10000},7,16,7,21" -locations_default(#20304,#10000,7,16,7,21) +properties(#20303,#20301,0,0,"type: ""json""") +#20304=@"loc,{#10000},3,38,3,49" +locations_default(#20304,#10000,3,38,3,49) hasLocation(#20303,#20304) -regexp_const_value(#20303,"module") #20305=* -stmts(#20305,30,#20001,6,"export ... son"" };") -hasLocation(#20305,#20021) -stmt_containers(#20305,#20001) +exprs(#20305,0,#20303,0,"type") +hasLocation(#20305,#20093) +enclosing_stmt(#20305,#20297) +expr_containers(#20305,#20001) +literals("type","type",#20305) #20306=* -exprs(#20306,4,#20305,-2,"""module""") -hasLocation(#20306,#20183) -enclosing_stmt(#20306,#20305) +exprs(#20306,4,#20303,1,"""json""") +hasLocation(#20306,#20097) +enclosing_stmt(#20306,#20297) expr_containers(#20306,#20001) -literals("module","""module""",#20306) +literals("json","""json""",#20306) #20307=* -regexpterm(#20307,14,#20306,0,"module") -#20308=@"loc,{#10000},8,22,8,27" -locations_default(#20308,#10000,8,22,8,27) +regexpterm(#20307,14,#20306,0,"json") +#20308=@"loc,{#10000},3,45,3,48" +locations_default(#20308,#10000,3,45,3,48) hasLocation(#20307,#20308) -regexp_const_value(#20307,"module") +regexp_const_value(#20307,"json") #20309=* -exprs(#20309,96,#20305,0,"* as v5") -#20310=@"loc,{#10000},8,8,8,14" -locations_default(#20310,#10000,8,8,8,14) -hasLocation(#20309,#20310) -enclosing_stmt(#20309,#20305) +exprs(#20309,83,#20297,0,"v2") +hasLocation(#20309,#20081) +enclosing_stmt(#20309,#20297) expr_containers(#20309,#20001) +#20310=* +exprs(#20310,0,#20309,0,"v2") +hasLocation(#20310,#20081) +enclosing_stmt(#20310,#20297) +expr_containers(#20310,#20001) +literals("v2","v2",#20310) #20311=* -exprs(#20311,0,#20309,1,"v5") -hasLocation(#20311,#20179) -enclosing_stmt(#20311,#20305) +exprs(#20311,78,#20309,1,"v2") +hasLocation(#20311,#20081) +enclosing_stmt(#20311,#20297) expr_containers(#20311,#20001) -literals("v5","v5",#20311) +literals("v2","v2",#20311) +decl(#20311,#20261) +typedecl(#20311,#20264) +namespacedecl(#20311,#20267) #20312=* -stmts(#20312,22,#20001,7,"const v ... "" } });") -hasLocation(#20312,#20025) +stmts(#20312,27,#20001,3,"import ... son"" };") +hasLocation(#20312,#20013) stmt_containers(#20312,#20001) #20313=* -exprs(#20313,64,#20312,0,"v6 = im ... n"" } })") -#20314=@"loc,{#10000},10,7,10,57" -locations_default(#20314,#10000,10,7,10,57) -hasLocation(#20313,#20314) +exprs(#20313,4,#20312,-1,"""module""") +hasLocation(#20313,#20109) enclosing_stmt(#20313,#20312) expr_containers(#20313,#20001) -#20315=* -exprs(#20315,78,#20313,0,"v6") -hasLocation(#20315,#20201) -enclosing_stmt(#20315,#20312) -expr_containers(#20315,#20001) -literals("v6","v6",#20315) -decl(#20315,#20269) +literals("module","""module""",#20313) +#20314=* +regexpterm(#20314,14,#20313,0,"module") +#20315=@"loc,{#10000},4,17,4,22" +locations_default(#20315,#10000,4,17,4,22) +hasLocation(#20314,#20315) +regexp_const_value(#20314,"module") #20316=* -exprs(#20316,99,#20313,1,"import( ... n"" } })") -#20317=@"loc,{#10000},10,12,10,57" -locations_default(#20317,#10000,10,12,10,57) +exprs(#20316,8,#20312,-10,"{ type: ""json"" }") +#20317=@"loc,{#10000},4,32,4,47" +locations_default(#20317,#10000,4,32,4,47) hasLocation(#20316,#20317) enclosing_stmt(#20316,#20312) expr_containers(#20316,#20001) #20318=* -exprs(#20318,4,#20316,0,"""module""") -hasLocation(#20318,#20209) -enclosing_stmt(#20318,#20312) -expr_containers(#20318,#20001) -literals("module","""module""",#20318) -#20319=* -regexpterm(#20319,14,#20318,0,"module") -#20320=@"loc,{#10000},10,20,10,25" -locations_default(#20320,#10000,10,20,10,25) -hasLocation(#20319,#20320) -regexp_const_value(#20319,"module") +properties(#20318,#20316,0,0,"type: ""json""") +#20319=@"loc,{#10000},4,34,4,45" +locations_default(#20319,#10000,4,34,4,45) +hasLocation(#20318,#20319) +#20320=* +exprs(#20320,0,#20318,0,"type") +hasLocation(#20320,#20115) +enclosing_stmt(#20320,#20312) +expr_containers(#20320,#20001) +literals("type","type",#20320) #20321=* -stmts(#20321,27,#20001,8,"import ""module""") -#20322=@"loc,{#10000},12,1,12,15" -locations_default(#20322,#10000,12,1,12,15) -hasLocation(#20321,#20322) -stmt_containers(#20321,#20001) -#20323=* -exprs(#20323,4,#20321,-1,"""module""") -hasLocation(#20323,#20237) -enclosing_stmt(#20323,#20321) -expr_containers(#20323,#20001) -literals("module","""module""",#20323) +exprs(#20321,4,#20318,1,"""json""") +hasLocation(#20321,#20119) +enclosing_stmt(#20321,#20312) +expr_containers(#20321,#20001) +literals("json","""json""",#20321) +#20322=* +regexpterm(#20322,14,#20321,0,"json") +#20323=@"loc,{#10000},4,41,4,44" +locations_default(#20323,#10000,4,41,4,44) +hasLocation(#20322,#20323) +regexp_const_value(#20322,"json") #20324=* -regexpterm(#20324,14,#20323,0,"module") -#20325=@"loc,{#10000},12,9,12,14" -locations_default(#20325,#10000,12,9,12,14) -hasLocation(#20324,#20325) -regexp_const_value(#20324,"module") +exprs(#20324,84,#20312,0,"v3") +hasLocation(#20324,#20105) +enclosing_stmt(#20324,#20312) +expr_containers(#20324,#20001) +#20325=* +exprs(#20325,78,#20324,1,"v3") +hasLocation(#20325,#20105) +enclosing_stmt(#20325,#20312) +expr_containers(#20325,#20001) +literals("v3","v3",#20325) +decl(#20325,#20262) +typedecl(#20325,#20265) +namespacedecl(#20325,#20268) #20326=* -stmts(#20326,2,#20001,9,"assert( ... son""});") -#20327=@"loc,{#10000},13,1,13,23" -locations_default(#20327,#10000,13,1,13,23) -hasLocation(#20326,#20327) +stmts(#20326,30,#20001,4,"export ... son"" };") +hasLocation(#20326,#20017) stmt_containers(#20326,#20001) +#20327=* +exprs(#20327,4,#20326,-2,"""module""") +hasLocation(#20327,#20135) +enclosing_stmt(#20327,#20326) +expr_containers(#20327,#20001) +literals("module","""module""",#20327) #20328=* -exprs(#20328,13,#20326,0,"assert( ... json""})") -#20329=@"loc,{#10000},13,1,13,22" -locations_default(#20329,#10000,13,1,13,22) +regexpterm(#20328,14,#20327,0,"module") +#20329=@"loc,{#10000},6,21,6,26" +locations_default(#20329,#10000,6,21,6,26) hasLocation(#20328,#20329) -enclosing_stmt(#20328,#20326) -expr_containers(#20328,#20001) +regexp_const_value(#20328,"module") #20330=* -exprs(#20330,79,#20328,-1,"assert") -hasLocation(#20330,#20239) +exprs(#20330,8,#20326,-10,"{ type: ""json"" }") +#20331=@"loc,{#10000},6,36,6,51" +locations_default(#20331,#10000,6,36,6,51) +hasLocation(#20330,#20331) enclosing_stmt(#20330,#20326) expr_containers(#20330,#20001) -literals("assert","assert",#20330) -#20331=@"var;{assert};{#20000}" -variables(#20331,"assert",#20000) -bind(#20330,#20331) #20332=* -exprs(#20332,8,#20328,0,"{type: ""json""}") -#20333=@"loc,{#10000},13,8,13,21" -locations_default(#20333,#10000,13,8,13,21) +properties(#20332,#20330,0,0,"type: ""json""") +#20333=@"loc,{#10000},6,38,6,49" +locations_default(#20333,#10000,6,38,6,49) hasLocation(#20332,#20333) -enclosing_stmt(#20332,#20326) -expr_containers(#20332,#20001) #20334=* -properties(#20334,#20332,0,0,"type: ""json""") -#20335=@"loc,{#10000},13,9,13,20" -locations_default(#20335,#10000,13,9,13,20) -hasLocation(#20334,#20335) +exprs(#20334,0,#20332,0,"type") +hasLocation(#20334,#20141) +enclosing_stmt(#20334,#20326) +expr_containers(#20334,#20001) +literals("type","type",#20334) +#20335=* +exprs(#20335,4,#20332,1,"""json""") +hasLocation(#20335,#20145) +enclosing_stmt(#20335,#20326) +expr_containers(#20335,#20001) +literals("json","""json""",#20335) #20336=* -exprs(#20336,0,#20334,0,"type") -hasLocation(#20336,#20245) -enclosing_stmt(#20336,#20326) -expr_containers(#20336,#20001) -literals("type","type",#20336) -#20337=* -exprs(#20337,4,#20334,1,"""json""") -hasLocation(#20337,#20249) -enclosing_stmt(#20337,#20326) -expr_containers(#20337,#20001) -literals("json","""json""",#20337) +regexpterm(#20336,14,#20335,0,"json") +#20337=@"loc,{#10000},6,45,6,48" +locations_default(#20337,#10000,6,45,6,48) +hasLocation(#20336,#20337) +regexp_const_value(#20336,"json") #20338=* -regexpterm(#20338,14,#20337,0,"json") -#20339=@"loc,{#10000},13,16,13,19" -locations_default(#20339,#10000,13,16,13,19) -hasLocation(#20338,#20339) -regexp_const_value(#20338,"json") +exprs(#20338,86,#20326,0,"v4") +hasLocation(#20338,#20129) +enclosing_stmt(#20338,#20326) +expr_containers(#20338,#20001) +#20339=* +exprs(#20339,0,#20338,0,"v4") +hasLocation(#20339,#20129) +enclosing_stmt(#20339,#20326) +expr_containers(#20339,#20001) +literals("v4","v4",#20339) #20340=* -entry_cfg_node(#20340,#20001) -#20341=@"loc,{#10000},1,1,1,0" -locations_default(#20341,#10000,1,1,1,0) -hasLocation(#20340,#20341) +exprs(#20340,0,#20338,1,"v4") +hasLocation(#20340,#20129) +enclosing_stmt(#20340,#20326) +expr_containers(#20340,#20001) +literals("v4","v4",#20340) +#20341=* +stmts(#20341,28,#20001,5,"export ... son"" };") +hasLocation(#20341,#20019) +stmt_containers(#20341,#20001) #20342=* -exit_cfg_node(#20342,#20001) -hasLocation(#20342,#20257) -successor(#20326,#20330) -successor(#20332,#20336) -successor(#20337,#20334) -successor(#20336,#20337) -successor(#20334,#20328) -successor(#20330,#20332) -successor(#20328,#20342) -successor(#20321,#20326) -successor(#20312,#20315) -successor(#20318,#20316) -successor(#20316,#20313) -successor(#20315,#20318) -successor(#20313,#20321) -successor(#20305,#20306) -successor(#20309,#20311) -successor(#20311,#20312) -successor(#20306,#20309) -successor(#20301,#20302) -successor(#20302,#20305) -successor(#20294,#20295) -successor(#20298,#20299) -successor(#20300,#20301) -successor(#20299,#20300) -successor(#20295,#20298) -successor(#20288,#20294) -successor(#20281,#20288) -successor(#20274,#20281) -successor(#20270,#20274) -successor(#20292,#20270) -successor(#20285,#20292) -successor(#20278,#20285) -successor(#20340,#20278) +exprs(#20342,4,#20341,0,"""module""") +hasLocation(#20342,#20157) +enclosing_stmt(#20342,#20341) +expr_containers(#20342,#20001) +literals("module","""module""",#20342) +#20343=* +regexpterm(#20343,14,#20342,0,"module") +#20344=@"loc,{#10000},7,16,7,21" +locations_default(#20344,#10000,7,16,7,21) +hasLocation(#20343,#20344) +regexp_const_value(#20343,"module") +#20345=* +exprs(#20345,8,#20341,-10,"{ type: ""json"" }") +#20346=@"loc,{#10000},7,31,7,46" +locations_default(#20346,#10000,7,31,7,46) +hasLocation(#20345,#20346) +enclosing_stmt(#20345,#20341) +expr_containers(#20345,#20001) +#20347=* +properties(#20347,#20345,0,0,"type: ""json""") +#20348=@"loc,{#10000},7,33,7,44" +locations_default(#20348,#10000,7,33,7,44) +hasLocation(#20347,#20348) +#20349=* +exprs(#20349,0,#20347,0,"type") +hasLocation(#20349,#20163) +enclosing_stmt(#20349,#20341) +expr_containers(#20349,#20001) +literals("type","type",#20349) +#20350=* +exprs(#20350,4,#20347,1,"""json""") +hasLocation(#20350,#20167) +enclosing_stmt(#20350,#20341) +expr_containers(#20350,#20001) +literals("json","""json""",#20350) +#20351=* +regexpterm(#20351,14,#20350,0,"json") +#20352=@"loc,{#10000},7,40,7,43" +locations_default(#20352,#10000,7,40,7,43) +hasLocation(#20351,#20352) +regexp_const_value(#20351,"json") +#20353=* +stmts(#20353,30,#20001,6,"export ... son"" };") +hasLocation(#20353,#20021) +stmt_containers(#20353,#20001) +#20354=* +exprs(#20354,4,#20353,-2,"""module""") +hasLocation(#20354,#20183) +enclosing_stmt(#20354,#20353) +expr_containers(#20354,#20001) +literals("module","""module""",#20354) +#20355=* +regexpterm(#20355,14,#20354,0,"module") +#20356=@"loc,{#10000},8,22,8,27" +locations_default(#20356,#10000,8,22,8,27) +hasLocation(#20355,#20356) +regexp_const_value(#20355,"module") +#20357=* +exprs(#20357,8,#20353,-10,"{ type: ""json"" }") +#20358=@"loc,{#10000},8,37,8,52" +locations_default(#20358,#10000,8,37,8,52) +hasLocation(#20357,#20358) +enclosing_stmt(#20357,#20353) +expr_containers(#20357,#20001) +#20359=* +properties(#20359,#20357,0,0,"type: ""json""") +#20360=@"loc,{#10000},8,39,8,50" +locations_default(#20360,#10000,8,39,8,50) +hasLocation(#20359,#20360) +#20361=* +exprs(#20361,0,#20359,0,"type") +hasLocation(#20361,#20189) +enclosing_stmt(#20361,#20353) +expr_containers(#20361,#20001) +literals("type","type",#20361) +#20362=* +exprs(#20362,4,#20359,1,"""json""") +hasLocation(#20362,#20193) +enclosing_stmt(#20362,#20353) +expr_containers(#20362,#20001) +literals("json","""json""",#20362) +#20363=* +regexpterm(#20363,14,#20362,0,"json") +#20364=@"loc,{#10000},8,46,8,49" +locations_default(#20364,#10000,8,46,8,49) +hasLocation(#20363,#20364) +regexp_const_value(#20363,"json") +#20365=* +exprs(#20365,96,#20353,0,"* as v5") +#20366=@"loc,{#10000},8,8,8,14" +locations_default(#20366,#10000,8,8,8,14) +hasLocation(#20365,#20366) +enclosing_stmt(#20365,#20353) +expr_containers(#20365,#20001) +#20367=* +exprs(#20367,0,#20365,1,"v5") +hasLocation(#20367,#20179) +enclosing_stmt(#20367,#20353) +expr_containers(#20367,#20001) +literals("v5","v5",#20367) +#20368=* +stmts(#20368,22,#20001,7,"const v ... "" } });") +hasLocation(#20368,#20025) +stmt_containers(#20368,#20001) +#20369=* +exprs(#20369,64,#20368,0,"v6 = im ... n"" } })") +#20370=@"loc,{#10000},10,7,10,57" +locations_default(#20370,#10000,10,7,10,57) +hasLocation(#20369,#20370) +enclosing_stmt(#20369,#20368) +expr_containers(#20369,#20001) +#20371=* +exprs(#20371,78,#20369,0,"v6") +hasLocation(#20371,#20201) +enclosing_stmt(#20371,#20368) +expr_containers(#20371,#20001) +literals("v6","v6",#20371) +decl(#20371,#20269) +#20372=* +exprs(#20372,99,#20369,1,"import( ... n"" } })") +#20373=@"loc,{#10000},10,12,10,57" +locations_default(#20373,#10000,10,12,10,57) +hasLocation(#20372,#20373) +enclosing_stmt(#20372,#20368) +expr_containers(#20372,#20001) +#20374=* +exprs(#20374,4,#20372,0,"""module""") +hasLocation(#20374,#20209) +enclosing_stmt(#20374,#20368) +expr_containers(#20374,#20001) +literals("module","""module""",#20374) +#20375=* +regexpterm(#20375,14,#20374,0,"module") +#20376=@"loc,{#10000},10,20,10,25" +locations_default(#20376,#10000,10,20,10,25) +hasLocation(#20375,#20376) +regexp_const_value(#20375,"module") +#20377=* +exprs(#20377,8,#20372,1,"{ asser ... on"" } }") +#20378=@"loc,{#10000},10,29,10,56" +locations_default(#20378,#10000,10,29,10,56) +hasLocation(#20377,#20378) +enclosing_stmt(#20377,#20368) +expr_containers(#20377,#20001) +#20379=* +properties(#20379,#20377,0,0,"assert: ... json"" }") +#20380=@"loc,{#10000},10,31,10,54" +locations_default(#20380,#10000,10,31,10,54) +hasLocation(#20379,#20380) +#20381=* +exprs(#20381,0,#20379,0,"assert") +hasLocation(#20381,#20215) +enclosing_stmt(#20381,#20368) +expr_containers(#20381,#20001) +literals("assert","assert",#20381) +#20382=* +exprs(#20382,8,#20379,1,"{ type: ""json"" }") +#20383=@"loc,{#10000},10,39,10,54" +locations_default(#20383,#10000,10,39,10,54) +hasLocation(#20382,#20383) +enclosing_stmt(#20382,#20368) +expr_containers(#20382,#20001) +#20384=* +properties(#20384,#20382,0,0,"type: ""json""") +#20385=@"loc,{#10000},10,41,10,52" +locations_default(#20385,#10000,10,41,10,52) +hasLocation(#20384,#20385) +#20386=* +exprs(#20386,0,#20384,0,"type") +hasLocation(#20386,#20221) +enclosing_stmt(#20386,#20368) +expr_containers(#20386,#20001) +literals("type","type",#20386) +#20387=* +exprs(#20387,4,#20384,1,"""json""") +hasLocation(#20387,#20225) +enclosing_stmt(#20387,#20368) +expr_containers(#20387,#20001) +literals("json","""json""",#20387) +#20388=* +regexpterm(#20388,14,#20387,0,"json") +#20389=@"loc,{#10000},10,48,10,51" +locations_default(#20389,#10000,10,48,10,51) +hasLocation(#20388,#20389) +regexp_const_value(#20388,"json") +#20390=* +stmts(#20390,27,#20001,8,"import ""module""") +#20391=@"loc,{#10000},12,1,12,15" +locations_default(#20391,#10000,12,1,12,15) +hasLocation(#20390,#20391) +stmt_containers(#20390,#20001) +#20392=* +exprs(#20392,4,#20390,-1,"""module""") +hasLocation(#20392,#20237) +enclosing_stmt(#20392,#20390) +expr_containers(#20392,#20001) +literals("module","""module""",#20392) +#20393=* +regexpterm(#20393,14,#20392,0,"module") +#20394=@"loc,{#10000},12,9,12,14" +locations_default(#20394,#10000,12,9,12,14) +hasLocation(#20393,#20394) +regexp_const_value(#20393,"module") +#20395=* +stmts(#20395,2,#20001,9,"assert( ... son""});") +#20396=@"loc,{#10000},13,1,13,23" +locations_default(#20396,#10000,13,1,13,23) +hasLocation(#20395,#20396) +stmt_containers(#20395,#20001) +#20397=* +exprs(#20397,13,#20395,0,"assert( ... json""})") +#20398=@"loc,{#10000},13,1,13,22" +locations_default(#20398,#10000,13,1,13,22) +hasLocation(#20397,#20398) +enclosing_stmt(#20397,#20395) +expr_containers(#20397,#20001) +#20399=* +exprs(#20399,79,#20397,-1,"assert") +hasLocation(#20399,#20239) +enclosing_stmt(#20399,#20395) +expr_containers(#20399,#20001) +literals("assert","assert",#20399) +#20400=@"var;{assert};{#20000}" +variables(#20400,"assert",#20000) +bind(#20399,#20400) +#20401=* +exprs(#20401,8,#20397,0,"{type: ""json""}") +#20402=@"loc,{#10000},13,8,13,21" +locations_default(#20402,#10000,13,8,13,21) +hasLocation(#20401,#20402) +enclosing_stmt(#20401,#20395) +expr_containers(#20401,#20001) +#20403=* +properties(#20403,#20401,0,0,"type: ""json""") +#20404=@"loc,{#10000},13,9,13,20" +locations_default(#20404,#10000,13,9,13,20) +hasLocation(#20403,#20404) +#20405=* +exprs(#20405,0,#20403,0,"type") +hasLocation(#20405,#20245) +enclosing_stmt(#20405,#20395) +expr_containers(#20405,#20001) +literals("type","type",#20405) +#20406=* +exprs(#20406,4,#20403,1,"""json""") +hasLocation(#20406,#20249) +enclosing_stmt(#20406,#20395) +expr_containers(#20406,#20001) +literals("json","""json""",#20406) +#20407=* +regexpterm(#20407,14,#20406,0,"json") +#20408=@"loc,{#10000},13,16,13,19" +locations_default(#20408,#10000,13,16,13,19) +hasLocation(#20407,#20408) +regexp_const_value(#20407,"json") +#20409=* +entry_cfg_node(#20409,#20001) +#20410=@"loc,{#10000},1,1,1,0" +locations_default(#20410,#10000,1,1,1,0) +hasLocation(#20409,#20410) +#20411=* +exit_cfg_node(#20411,#20001) +hasLocation(#20411,#20257) +successor(#20395,#20399) +successor(#20401,#20405) +successor(#20406,#20403) +successor(#20405,#20406) +successor(#20403,#20397) +successor(#20399,#20401) +successor(#20397,#20411) +successor(#20390,#20395) +successor(#20368,#20371) +successor(#20374,#20372) +successor(#20372,#20369) +successor(#20371,#20374) +successor(#20369,#20390) +successor(#20353,#20354) +successor(#20365,#20367) +successor(#20367,#20368) +successor(#20354,#20365) +successor(#20341,#20342) +successor(#20342,#20353) +successor(#20326,#20327) +successor(#20338,#20339) +successor(#20340,#20341) +successor(#20339,#20340) +successor(#20327,#20338) +successor(#20312,#20326) +successor(#20297,#20312) +successor(#20282,#20297) +successor(#20270,#20282) +successor(#20324,#20270) +successor(#20309,#20324) +successor(#20294,#20309) +successor(#20409,#20294) numlines(#10000,13,10,2) filetype(#10000,"javascript") diff --git a/javascript/extractor/tests/ts/output/trap/import-assertion.ts.trap b/javascript/extractor/tests/ts/output/trap/import-assertion.ts.trap index d82dca7dee7..82d6671b171 100644 --- a/javascript/extractor/tests/ts/output/trap/import-assertion.ts.trap +++ b/javascript/extractor/tests/ts/output/trap/import-assertion.ts.trap @@ -726,392 +726,459 @@ locations_default(#20275,#10000,1,9,1,14) hasLocation(#20274,#20275) regexp_const_value(#20274,"module") #20276=* -stmts(#20276,27,#20001,1,"import ... son"" };") -hasLocation(#20276,#20009) -stmt_containers(#20276,#20001) -#20277=* -exprs(#20277,4,#20276,-1,"""module""") -hasLocation(#20277,#20061) -enclosing_stmt(#20277,#20276) -expr_containers(#20277,#20001) -literals("module","""module""",#20277) +exprs(#20276,8,#20272,-10,"assert ... json"" }") +#20277=@"loc,{#10000},1,17,1,39" +locations_default(#20277,#10000,1,17,1,39) +hasLocation(#20276,#20277) +enclosing_stmt(#20276,#20272) +expr_containers(#20276,#20001) #20278=* -regexpterm(#20278,14,#20277,0,"module") -#20279=@"loc,{#10000},2,22,2,27" -locations_default(#20279,#10000,2,22,2,27) +properties(#20278,#20276,0,0,"type: ""json""") +#20279=@"loc,{#10000},1,26,1,37" +locations_default(#20279,#10000,1,26,1,37) hasLocation(#20278,#20279) -regexp_const_value(#20278,"module") #20280=* -exprs(#20280,85,#20276,0,"* as v1") -#20281=@"loc,{#10000},2,8,2,14" -locations_default(#20281,#10000,2,8,2,14) -hasLocation(#20280,#20281) -enclosing_stmt(#20280,#20276) -expr_containers(#20280,#20001) +stmts(#20280,27,#20001,1,"import ... son"" };") +hasLocation(#20280,#20009) +stmt_containers(#20280,#20001) +#20281=* +exprs(#20281,4,#20280,-1,"""module""") +hasLocation(#20281,#20061) +enclosing_stmt(#20281,#20280) +expr_containers(#20281,#20001) +literals("module","""module""",#20281) #20282=* -exprs(#20282,78,#20280,1,"v1") -hasLocation(#20282,#20057) -enclosing_stmt(#20282,#20276) -expr_containers(#20282,#20001) -literals("v1","v1",#20282) -decl(#20282,#20262) -typedecl(#20282,#20265) -namespacedecl(#20282,#20268) -#20283=* -stmts(#20283,27,#20001,2,"import ... son"" };") -hasLocation(#20283,#20011) -stmt_containers(#20283,#20001) +regexpterm(#20282,14,#20281,0,"module") +#20283=@"loc,{#10000},2,22,2,27" +locations_default(#20283,#10000,2,22,2,27) +hasLocation(#20282,#20283) +regexp_const_value(#20282,"module") #20284=* -exprs(#20284,4,#20283,-1,"""module""") -hasLocation(#20284,#20087) -enclosing_stmt(#20284,#20283) +exprs(#20284,8,#20280,-10,"assert ... json"" }") +#20285=@"loc,{#10000},2,30,2,52" +locations_default(#20285,#10000,2,30,2,52) +hasLocation(#20284,#20285) +enclosing_stmt(#20284,#20280) expr_containers(#20284,#20001) -literals("module","""module""",#20284) -#20285=* -regexpterm(#20285,14,#20284,0,"module") -#20286=@"loc,{#10000},3,21,3,26" -locations_default(#20286,#10000,3,21,3,26) -hasLocation(#20285,#20286) -regexp_const_value(#20285,"module") -#20287=* -exprs(#20287,83,#20283,0,"v2") -hasLocation(#20287,#20081) -enclosing_stmt(#20287,#20283) -expr_containers(#20287,#20001) +#20286=* +properties(#20286,#20284,0,0,"type: ""json""") +#20287=@"loc,{#10000},2,39,2,50" +locations_default(#20287,#10000,2,39,2,50) +hasLocation(#20286,#20287) #20288=* -exprs(#20288,0,#20287,0,"v2") -hasLocation(#20288,#20081) -enclosing_stmt(#20288,#20283) +exprs(#20288,85,#20280,0,"* as v1") +#20289=@"loc,{#10000},2,8,2,14" +locations_default(#20289,#10000,2,8,2,14) +hasLocation(#20288,#20289) +enclosing_stmt(#20288,#20280) expr_containers(#20288,#20001) -literals("v2","v2",#20288) -#20289=* -exprs(#20289,78,#20287,1,"v2") -hasLocation(#20289,#20081) -enclosing_stmt(#20289,#20283) -expr_containers(#20289,#20001) -literals("v2","v2",#20289) -decl(#20289,#20263) -typedecl(#20289,#20266) -namespacedecl(#20289,#20269) #20290=* -stmts(#20290,27,#20001,3,"import ... son"" };") -hasLocation(#20290,#20013) -stmt_containers(#20290,#20001) +exprs(#20290,78,#20288,1,"v1") +hasLocation(#20290,#20057) +enclosing_stmt(#20290,#20280) +expr_containers(#20290,#20001) +literals("v1","v1",#20290) +decl(#20290,#20262) +typedecl(#20290,#20265) +namespacedecl(#20290,#20268) #20291=* -exprs(#20291,4,#20290,-1,"""module""") -hasLocation(#20291,#20109) -enclosing_stmt(#20291,#20290) -expr_containers(#20291,#20001) -literals("module","""module""",#20291) +stmts(#20291,27,#20001,2,"import ... son"" };") +hasLocation(#20291,#20011) +stmt_containers(#20291,#20001) #20292=* -regexpterm(#20292,14,#20291,0,"module") -#20293=@"loc,{#10000},4,17,4,22" -locations_default(#20293,#10000,4,17,4,22) -hasLocation(#20292,#20293) -regexp_const_value(#20292,"module") -#20294=* -exprs(#20294,84,#20290,0,"v3") -hasLocation(#20294,#20105) -enclosing_stmt(#20294,#20290) -expr_containers(#20294,#20001) +exprs(#20292,4,#20291,-1,"""module""") +hasLocation(#20292,#20087) +enclosing_stmt(#20292,#20291) +expr_containers(#20292,#20001) +literals("module","""module""",#20292) +#20293=* +regexpterm(#20293,14,#20292,0,"module") +#20294=@"loc,{#10000},3,21,3,26" +locations_default(#20294,#10000,3,21,3,26) +hasLocation(#20293,#20294) +regexp_const_value(#20293,"module") #20295=* -exprs(#20295,78,#20294,1,"v3") -hasLocation(#20295,#20105) -enclosing_stmt(#20295,#20290) +exprs(#20295,8,#20291,-10,"assert ... json"" }") +#20296=@"loc,{#10000},3,29,3,51" +locations_default(#20296,#10000,3,29,3,51) +hasLocation(#20295,#20296) +enclosing_stmt(#20295,#20291) expr_containers(#20295,#20001) -literals("v3","v3",#20295) -decl(#20295,#20264) -typedecl(#20295,#20267) -namespacedecl(#20295,#20270) -#20296=* -stmts(#20296,30,#20001,4,"export ... son"" };") -hasLocation(#20296,#20017) -stmt_containers(#20296,#20001) #20297=* -exprs(#20297,4,#20296,-2,"""module""") -hasLocation(#20297,#20135) -enclosing_stmt(#20297,#20296) -expr_containers(#20297,#20001) -literals("module","""module""",#20297) -#20298=* -regexpterm(#20298,14,#20297,0,"module") -#20299=@"loc,{#10000},6,21,6,26" -locations_default(#20299,#10000,6,21,6,26) -hasLocation(#20298,#20299) -regexp_const_value(#20298,"module") +properties(#20297,#20295,0,0,"type: ""json""") +#20298=@"loc,{#10000},3,38,3,49" +locations_default(#20298,#10000,3,38,3,49) +hasLocation(#20297,#20298) +#20299=* +exprs(#20299,83,#20291,0,"v2") +hasLocation(#20299,#20081) +enclosing_stmt(#20299,#20291) +expr_containers(#20299,#20001) #20300=* -exprs(#20300,86,#20296,0,"v4") -hasLocation(#20300,#20129) -enclosing_stmt(#20300,#20296) +exprs(#20300,0,#20299,0,"v2") +hasLocation(#20300,#20081) +enclosing_stmt(#20300,#20291) expr_containers(#20300,#20001) +literals("v2","v2",#20300) #20301=* -exprs(#20301,0,#20300,0,"v4") -hasLocation(#20301,#20129) -enclosing_stmt(#20301,#20296) +exprs(#20301,78,#20299,1,"v2") +hasLocation(#20301,#20081) +enclosing_stmt(#20301,#20291) expr_containers(#20301,#20001) -literals("v4","v4",#20301) +literals("v2","v2",#20301) +decl(#20301,#20263) +typedecl(#20301,#20266) +namespacedecl(#20301,#20269) #20302=* -exprs(#20302,0,#20300,1,"v4") -hasLocation(#20302,#20129) -enclosing_stmt(#20302,#20296) -expr_containers(#20302,#20001) -literals("v4","v4",#20302) +stmts(#20302,27,#20001,3,"import ... son"" };") +hasLocation(#20302,#20013) +stmt_containers(#20302,#20001) #20303=* -stmts(#20303,28,#20001,5,"export ... son"" };") -hasLocation(#20303,#20019) -stmt_containers(#20303,#20001) +exprs(#20303,4,#20302,-1,"""module""") +hasLocation(#20303,#20109) +enclosing_stmt(#20303,#20302) +expr_containers(#20303,#20001) +literals("module","""module""",#20303) #20304=* -exprs(#20304,4,#20303,0,"""module""") -hasLocation(#20304,#20157) -enclosing_stmt(#20304,#20303) -expr_containers(#20304,#20001) -literals("module","""module""",#20304) -#20305=* -regexpterm(#20305,14,#20304,0,"module") -#20306=@"loc,{#10000},7,16,7,21" -locations_default(#20306,#10000,7,16,7,21) -hasLocation(#20305,#20306) -regexp_const_value(#20305,"module") -#20307=* -stmts(#20307,30,#20001,6,"export ... son"" };") -hasLocation(#20307,#20021) -stmt_containers(#20307,#20001) +regexpterm(#20304,14,#20303,0,"module") +#20305=@"loc,{#10000},4,17,4,22" +locations_default(#20305,#10000,4,17,4,22) +hasLocation(#20304,#20305) +regexp_const_value(#20304,"module") +#20306=* +exprs(#20306,8,#20302,-10,"assert ... json"" }") +#20307=@"loc,{#10000},4,25,4,47" +locations_default(#20307,#10000,4,25,4,47) +hasLocation(#20306,#20307) +enclosing_stmt(#20306,#20302) +expr_containers(#20306,#20001) #20308=* -exprs(#20308,4,#20307,-2,"""module""") -hasLocation(#20308,#20183) -enclosing_stmt(#20308,#20307) -expr_containers(#20308,#20001) -literals("module","""module""",#20308) -#20309=* -regexpterm(#20309,14,#20308,0,"module") -#20310=@"loc,{#10000},8,22,8,27" -locations_default(#20310,#10000,8,22,8,27) -hasLocation(#20309,#20310) -regexp_const_value(#20309,"module") +properties(#20308,#20306,0,0,"type: ""json""") +#20309=@"loc,{#10000},4,34,4,45" +locations_default(#20309,#10000,4,34,4,45) +hasLocation(#20308,#20309) +#20310=* +exprs(#20310,84,#20302,0,"v3") +hasLocation(#20310,#20105) +enclosing_stmt(#20310,#20302) +expr_containers(#20310,#20001) #20311=* -exprs(#20311,96,#20307,0,"* as v5") -#20312=@"loc,{#10000},8,8,8,14" -locations_default(#20312,#10000,8,8,8,14) -hasLocation(#20311,#20312) -enclosing_stmt(#20311,#20307) +exprs(#20311,78,#20310,1,"v3") +hasLocation(#20311,#20105) +enclosing_stmt(#20311,#20302) expr_containers(#20311,#20001) +literals("v3","v3",#20311) +decl(#20311,#20264) +typedecl(#20311,#20267) +namespacedecl(#20311,#20270) +#20312=* +stmts(#20312,30,#20001,4,"export ... son"" };") +hasLocation(#20312,#20017) +stmt_containers(#20312,#20001) #20313=* -exprs(#20313,0,#20311,1,"v5") -hasLocation(#20313,#20179) -enclosing_stmt(#20313,#20307) +exprs(#20313,4,#20312,-2,"""module""") +hasLocation(#20313,#20135) +enclosing_stmt(#20313,#20312) expr_containers(#20313,#20001) -literals("v5","v5",#20313) +literals("module","""module""",#20313) #20314=* -stmts(#20314,22,#20001,7,"const v ... "" } });") -hasLocation(#20314,#20025) -stmt_containers(#20314,#20001) -#20315=* -exprs(#20315,64,#20314,0,"v6 = im ... n"" } })") -#20316=@"loc,{#10000},10,7,10,57" -locations_default(#20316,#10000,10,7,10,57) -hasLocation(#20315,#20316) -enclosing_stmt(#20315,#20314) -expr_containers(#20315,#20001) -#20317=* -exprs(#20317,78,#20315,0,"v6") -hasLocation(#20317,#20201) -enclosing_stmt(#20317,#20314) -expr_containers(#20317,#20001) -literals("v6","v6",#20317) -decl(#20317,#20271) +regexpterm(#20314,14,#20313,0,"module") +#20315=@"loc,{#10000},6,21,6,26" +locations_default(#20315,#10000,6,21,6,26) +hasLocation(#20314,#20315) +regexp_const_value(#20314,"module") +#20316=* +exprs(#20316,8,#20312,-10,"assert ... json"" }") +#20317=@"loc,{#10000},6,29,6,51" +locations_default(#20317,#10000,6,29,6,51) +hasLocation(#20316,#20317) +enclosing_stmt(#20316,#20312) +expr_containers(#20316,#20001) #20318=* -exprs(#20318,13,#20315,1,"import( ... n"" } })") -#20319=@"loc,{#10000},10,12,10,57" -locations_default(#20319,#10000,10,12,10,57) +properties(#20318,#20316,0,0,"type: ""json""") +#20319=@"loc,{#10000},6,38,6,49" +locations_default(#20319,#10000,6,38,6,49) hasLocation(#20318,#20319) -enclosing_stmt(#20318,#20314) -expr_containers(#20318,#20001) #20320=* -exprs(#20320,79,#20318,-1,"import") -hasLocation(#20320,#20205) -enclosing_stmt(#20320,#20314) +exprs(#20320,86,#20312,0,"v4") +hasLocation(#20320,#20129) +enclosing_stmt(#20320,#20312) expr_containers(#20320,#20001) -literals("import","import",#20320) -#20321=@"var;{import};{#20000}" -variables(#20321,"import",#20000) -bind(#20320,#20321) +#20321=* +exprs(#20321,0,#20320,0,"v4") +hasLocation(#20321,#20129) +enclosing_stmt(#20321,#20312) +expr_containers(#20321,#20001) +literals("v4","v4",#20321) #20322=* -exprs(#20322,4,#20318,0,"""module""") -hasLocation(#20322,#20209) -enclosing_stmt(#20322,#20314) +exprs(#20322,0,#20320,1,"v4") +hasLocation(#20322,#20129) +enclosing_stmt(#20322,#20312) expr_containers(#20322,#20001) -literals("module","""module""",#20322) +literals("v4","v4",#20322) #20323=* -regexpterm(#20323,14,#20322,0,"module") -#20324=@"loc,{#10000},10,20,10,25" -locations_default(#20324,#10000,10,20,10,25) -hasLocation(#20323,#20324) -regexp_const_value(#20323,"module") +stmts(#20323,28,#20001,5,"export ... son"" };") +hasLocation(#20323,#20019) +stmt_containers(#20323,#20001) +#20324=* +exprs(#20324,4,#20323,0,"""module""") +hasLocation(#20324,#20157) +enclosing_stmt(#20324,#20323) +expr_containers(#20324,#20001) +literals("module","""module""",#20324) #20325=* -exprs(#20325,8,#20318,1,"{ asser ... on"" } }") -#20326=@"loc,{#10000},10,29,10,56" -locations_default(#20326,#10000,10,29,10,56) +regexpterm(#20325,14,#20324,0,"module") +#20326=@"loc,{#10000},7,16,7,21" +locations_default(#20326,#10000,7,16,7,21) hasLocation(#20325,#20326) -enclosing_stmt(#20325,#20314) -expr_containers(#20325,#20001) +regexp_const_value(#20325,"module") #20327=* -properties(#20327,#20325,0,0,"assert: ... json"" }") -#20328=@"loc,{#10000},10,31,10,54" -locations_default(#20328,#10000,10,31,10,54) +exprs(#20327,8,#20323,-10,"assert ... json"" }") +#20328=@"loc,{#10000},7,24,7,46" +locations_default(#20328,#10000,7,24,7,46) hasLocation(#20327,#20328) +enclosing_stmt(#20327,#20323) +expr_containers(#20327,#20001) #20329=* -exprs(#20329,0,#20327,0,"assert") -hasLocation(#20329,#20215) -enclosing_stmt(#20329,#20314) -expr_containers(#20329,#20001) -literals("assert","assert",#20329) -#20330=* -exprs(#20330,8,#20327,1,"{ type: ""json"" }") -#20331=@"loc,{#10000},10,39,10,54" -locations_default(#20331,#10000,10,39,10,54) -hasLocation(#20330,#20331) -enclosing_stmt(#20330,#20314) -expr_containers(#20330,#20001) +properties(#20329,#20327,0,0,"type: ""json""") +#20330=@"loc,{#10000},7,33,7,44" +locations_default(#20330,#10000,7,33,7,44) +hasLocation(#20329,#20330) +#20331=* +stmts(#20331,30,#20001,6,"export ... son"" };") +hasLocation(#20331,#20021) +stmt_containers(#20331,#20001) #20332=* -properties(#20332,#20330,0,0,"type: ""json""") -#20333=@"loc,{#10000},10,41,10,52" -locations_default(#20333,#10000,10,41,10,52) -hasLocation(#20332,#20333) -#20334=* -exprs(#20334,0,#20332,0,"type") -hasLocation(#20334,#20221) -enclosing_stmt(#20334,#20314) -expr_containers(#20334,#20001) -literals("type","type",#20334) +exprs(#20332,4,#20331,-2,"""module""") +hasLocation(#20332,#20183) +enclosing_stmt(#20332,#20331) +expr_containers(#20332,#20001) +literals("module","""module""",#20332) +#20333=* +regexpterm(#20333,14,#20332,0,"module") +#20334=@"loc,{#10000},8,22,8,27" +locations_default(#20334,#10000,8,22,8,27) +hasLocation(#20333,#20334) +regexp_const_value(#20333,"module") #20335=* -exprs(#20335,4,#20332,1,"""json""") -hasLocation(#20335,#20225) -enclosing_stmt(#20335,#20314) +exprs(#20335,8,#20331,-10,"assert ... json"" }") +#20336=@"loc,{#10000},8,30,8,52" +locations_default(#20336,#10000,8,30,8,52) +hasLocation(#20335,#20336) +enclosing_stmt(#20335,#20331) expr_containers(#20335,#20001) -literals("json","""json""",#20335) -#20336=* -regexpterm(#20336,14,#20335,0,"json") -#20337=@"loc,{#10000},10,48,10,51" -locations_default(#20337,#10000,10,48,10,51) -hasLocation(#20336,#20337) -regexp_const_value(#20336,"json") -#20338=* -stmts(#20338,27,#20001,8,"import ""module"";") -#20339=@"loc,{#10000},12,1,12,16" -locations_default(#20339,#10000,12,1,12,16) -hasLocation(#20338,#20339) -stmt_containers(#20338,#20001) -#20340=* -exprs(#20340,4,#20338,-1,"""module""") -hasLocation(#20340,#20237) -enclosing_stmt(#20340,#20338) -expr_containers(#20340,#20001) -literals("module","""module""",#20340) +#20337=* +properties(#20337,#20335,0,0,"type: ""json""") +#20338=@"loc,{#10000},8,39,8,50" +locations_default(#20338,#10000,8,39,8,50) +hasLocation(#20337,#20338) +#20339=* +exprs(#20339,96,#20331,0,"* as v5") +#20340=@"loc,{#10000},8,8,8,14" +locations_default(#20340,#10000,8,8,8,14) +hasLocation(#20339,#20340) +enclosing_stmt(#20339,#20331) +expr_containers(#20339,#20001) #20341=* -regexpterm(#20341,14,#20340,0,"module") -#20342=@"loc,{#10000},12,9,12,14" -locations_default(#20342,#10000,12,9,12,14) -hasLocation(#20341,#20342) -regexp_const_value(#20341,"module") +exprs(#20341,0,#20339,1,"v5") +hasLocation(#20341,#20179) +enclosing_stmt(#20341,#20331) +expr_containers(#20341,#20001) +literals("v5","v5",#20341) +#20342=* +stmts(#20342,22,#20001,7,"const v ... "" } });") +hasLocation(#20342,#20025) +stmt_containers(#20342,#20001) #20343=* -stmts(#20343,2,#20001,9,"assert( ... on"" });") -#20344=@"loc,{#10000},13,1,13,25" -locations_default(#20344,#10000,13,1,13,25) +exprs(#20343,64,#20342,0,"v6 = im ... n"" } })") +#20344=@"loc,{#10000},10,7,10,57" +locations_default(#20344,#10000,10,7,10,57) hasLocation(#20343,#20344) -stmt_containers(#20343,#20001) +enclosing_stmt(#20343,#20342) +expr_containers(#20343,#20001) #20345=* -exprs(#20345,13,#20343,0,"assert( ... son"" })") -#20346=@"loc,{#10000},13,1,13,24" -locations_default(#20346,#10000,13,1,13,24) -hasLocation(#20345,#20346) -enclosing_stmt(#20345,#20343) +exprs(#20345,78,#20343,0,"v6") +hasLocation(#20345,#20201) +enclosing_stmt(#20345,#20342) expr_containers(#20345,#20001) -#20347=* -exprs(#20347,79,#20345,-1,"assert") -hasLocation(#20347,#20241) -enclosing_stmt(#20347,#20343) -expr_containers(#20347,#20001) -literals("assert","assert",#20347) -#20348=@"var;{assert};{#20000}" -variables(#20348,"assert",#20000) -bind(#20347,#20348) +literals("v6","v6",#20345) +decl(#20345,#20271) +#20346=* +exprs(#20346,99,#20343,1,"import( ... n"" } })") +#20347=@"loc,{#10000},10,12,10,57" +locations_default(#20347,#10000,10,12,10,57) +hasLocation(#20346,#20347) +enclosing_stmt(#20346,#20342) +expr_containers(#20346,#20001) +#20348=* +exprs(#20348,4,#20346,0,"""module""") +hasLocation(#20348,#20209) +enclosing_stmt(#20348,#20342) +expr_containers(#20348,#20001) +literals("module","""module""",#20348) #20349=* -exprs(#20349,8,#20345,0,"{ type: ""json"" }") -#20350=@"loc,{#10000},13,8,13,23" -locations_default(#20350,#10000,13,8,13,23) +regexpterm(#20349,14,#20348,0,"module") +#20350=@"loc,{#10000},10,20,10,25" +locations_default(#20350,#10000,10,20,10,25) hasLocation(#20349,#20350) -enclosing_stmt(#20349,#20343) -expr_containers(#20349,#20001) +regexp_const_value(#20349,"module") #20351=* -properties(#20351,#20349,0,0,"type: ""json""") -#20352=@"loc,{#10000},13,10,13,21" -locations_default(#20352,#10000,13,10,13,21) +exprs(#20351,8,#20346,1,"{ asser ... on"" } }") +#20352=@"loc,{#10000},10,29,10,56" +locations_default(#20352,#10000,10,29,10,56) hasLocation(#20351,#20352) +enclosing_stmt(#20351,#20342) +expr_containers(#20351,#20001) #20353=* -exprs(#20353,0,#20351,0,"type") -hasLocation(#20353,#20247) -enclosing_stmt(#20353,#20343) -expr_containers(#20353,#20001) -literals("type","type",#20353) -#20354=* -exprs(#20354,4,#20351,1,"""json""") -hasLocation(#20354,#20251) -enclosing_stmt(#20354,#20343) -expr_containers(#20354,#20001) -literals("json","""json""",#20354) +properties(#20353,#20351,0,0,"assert: ... json"" }") +#20354=@"loc,{#10000},10,31,10,54" +locations_default(#20354,#10000,10,31,10,54) +hasLocation(#20353,#20354) #20355=* -regexpterm(#20355,14,#20354,0,"json") -#20356=@"loc,{#10000},13,17,13,20" -locations_default(#20356,#10000,13,17,13,20) -hasLocation(#20355,#20356) -regexp_const_value(#20355,"json") -#20357=* -entry_cfg_node(#20357,#20001) -#20358=@"loc,{#10000},1,1,1,0" -locations_default(#20358,#10000,1,1,1,0) -hasLocation(#20357,#20358) -#20359=* -exit_cfg_node(#20359,#20001) -hasLocation(#20359,#20259) -successor(#20343,#20347) -successor(#20349,#20353) -successor(#20354,#20351) -successor(#20353,#20354) -successor(#20351,#20345) -successor(#20347,#20349) -successor(#20345,#20359) -successor(#20338,#20343) -successor(#20314,#20317) -successor(#20325,#20329) -successor(#20330,#20334) -successor(#20335,#20332) -successor(#20334,#20335) -successor(#20332,#20327) -successor(#20329,#20330) -successor(#20327,#20318) -successor(#20322,#20325) -successor(#20320,#20322) -successor(#20318,#20315) -successor(#20317,#20320) -successor(#20315,#20338) -successor(#20307,#20308) -successor(#20311,#20313) -successor(#20313,#20314) -successor(#20308,#20311) -successor(#20303,#20304) -successor(#20304,#20307) -successor(#20296,#20297) -successor(#20300,#20301) -successor(#20302,#20303) -successor(#20301,#20302) -successor(#20297,#20300) -successor(#20290,#20296) -successor(#20283,#20290) -successor(#20276,#20283) -successor(#20272,#20276) -successor(#20294,#20272) -successor(#20287,#20294) -successor(#20280,#20287) -successor(#20357,#20280) +exprs(#20355,0,#20353,0,"assert") +hasLocation(#20355,#20215) +enclosing_stmt(#20355,#20342) +expr_containers(#20355,#20001) +literals("assert","assert",#20355) +#20356=* +exprs(#20356,8,#20353,1,"{ type: ""json"" }") +#20357=@"loc,{#10000},10,39,10,54" +locations_default(#20357,#10000,10,39,10,54) +hasLocation(#20356,#20357) +enclosing_stmt(#20356,#20342) +expr_containers(#20356,#20001) +#20358=* +properties(#20358,#20356,0,0,"type: ""json""") +#20359=@"loc,{#10000},10,41,10,52" +locations_default(#20359,#10000,10,41,10,52) +hasLocation(#20358,#20359) +#20360=* +exprs(#20360,0,#20358,0,"type") +hasLocation(#20360,#20221) +enclosing_stmt(#20360,#20342) +expr_containers(#20360,#20001) +literals("type","type",#20360) +#20361=* +exprs(#20361,4,#20358,1,"""json""") +hasLocation(#20361,#20225) +enclosing_stmt(#20361,#20342) +expr_containers(#20361,#20001) +literals("json","""json""",#20361) +#20362=* +regexpterm(#20362,14,#20361,0,"json") +#20363=@"loc,{#10000},10,48,10,51" +locations_default(#20363,#10000,10,48,10,51) +hasLocation(#20362,#20363) +regexp_const_value(#20362,"json") +#20364=* +stmts(#20364,27,#20001,8,"import ""module"";") +#20365=@"loc,{#10000},12,1,12,16" +locations_default(#20365,#10000,12,1,12,16) +hasLocation(#20364,#20365) +stmt_containers(#20364,#20001) +#20366=* +exprs(#20366,4,#20364,-1,"""module""") +hasLocation(#20366,#20237) +enclosing_stmt(#20366,#20364) +expr_containers(#20366,#20001) +literals("module","""module""",#20366) +#20367=* +regexpterm(#20367,14,#20366,0,"module") +#20368=@"loc,{#10000},12,9,12,14" +locations_default(#20368,#10000,12,9,12,14) +hasLocation(#20367,#20368) +regexp_const_value(#20367,"module") +#20369=* +stmts(#20369,2,#20001,9,"assert( ... on"" });") +#20370=@"loc,{#10000},13,1,13,25" +locations_default(#20370,#10000,13,1,13,25) +hasLocation(#20369,#20370) +stmt_containers(#20369,#20001) +#20371=* +exprs(#20371,13,#20369,0,"assert( ... son"" })") +#20372=@"loc,{#10000},13,1,13,24" +locations_default(#20372,#10000,13,1,13,24) +hasLocation(#20371,#20372) +enclosing_stmt(#20371,#20369) +expr_containers(#20371,#20001) +#20373=* +exprs(#20373,79,#20371,-1,"assert") +hasLocation(#20373,#20241) +enclosing_stmt(#20373,#20369) +expr_containers(#20373,#20001) +literals("assert","assert",#20373) +#20374=@"var;{assert};{#20000}" +variables(#20374,"assert",#20000) +bind(#20373,#20374) +#20375=* +exprs(#20375,8,#20371,0,"{ type: ""json"" }") +#20376=@"loc,{#10000},13,8,13,23" +locations_default(#20376,#10000,13,8,13,23) +hasLocation(#20375,#20376) +enclosing_stmt(#20375,#20369) +expr_containers(#20375,#20001) +#20377=* +properties(#20377,#20375,0,0,"type: ""json""") +#20378=@"loc,{#10000},13,10,13,21" +locations_default(#20378,#10000,13,10,13,21) +hasLocation(#20377,#20378) +#20379=* +exprs(#20379,0,#20377,0,"type") +hasLocation(#20379,#20247) +enclosing_stmt(#20379,#20369) +expr_containers(#20379,#20001) +literals("type","type",#20379) +#20380=* +exprs(#20380,4,#20377,1,"""json""") +hasLocation(#20380,#20251) +enclosing_stmt(#20380,#20369) +expr_containers(#20380,#20001) +literals("json","""json""",#20380) +#20381=* +regexpterm(#20381,14,#20380,0,"json") +#20382=@"loc,{#10000},13,17,13,20" +locations_default(#20382,#10000,13,17,13,20) +hasLocation(#20381,#20382) +regexp_const_value(#20381,"json") +#20383=* +entry_cfg_node(#20383,#20001) +#20384=@"loc,{#10000},1,1,1,0" +locations_default(#20384,#10000,1,1,1,0) +hasLocation(#20383,#20384) +#20385=* +exit_cfg_node(#20385,#20001) +hasLocation(#20385,#20259) +successor(#20369,#20373) +successor(#20375,#20379) +successor(#20380,#20377) +successor(#20379,#20380) +successor(#20377,#20371) +successor(#20373,#20375) +successor(#20371,#20385) +successor(#20364,#20369) +successor(#20342,#20345) +successor(#20348,#20346) +successor(#20346,#20343) +successor(#20345,#20348) +successor(#20343,#20364) +successor(#20331,#20332) +successor(#20339,#20341) +successor(#20341,#20342) +successor(#20332,#20339) +successor(#20323,#20324) +successor(#20324,#20331) +successor(#20312,#20313) +successor(#20320,#20321) +successor(#20322,#20323) +successor(#20321,#20322) +successor(#20313,#20320) +successor(#20302,#20312) +successor(#20291,#20302) +successor(#20280,#20291) +successor(#20272,#20280) +successor(#20310,#20272) +successor(#20299,#20310) +successor(#20288,#20299) +successor(#20383,#20288) numlines(#10000,13,10,2) filetype(#10000,"typescript") diff --git a/javascript/ql/lib/semmle/javascript/ES2015Modules.qll b/javascript/ql/lib/semmle/javascript/ES2015Modules.qll index f6e759b87e7..535d2317aa3 100644 --- a/javascript/ql/lib/semmle/javascript/ES2015Modules.qll +++ b/javascript/ql/lib/semmle/javascript/ES2015Modules.qll @@ -90,6 +90,16 @@ class ImportDeclaration extends Stmt, Import, @import_declaration { override PathExpr getImportedPath() { result = getChildExpr(-1) } + /** + * Gets the object literal passed as part of the `assert` clause in this import declaration. + * + * For example, this gets the `{ type: "json" }` object literal in the following: + * ```js + * import foo from "foo" assert { type: "json" }; + * ``` + */ + ObjectExpr getImportAssertion() { result = getChildExpr(-10) } + /** Gets the `i`th import specifier of this import declaration. */ ImportSpecifier getSpecifier(int i) { result = getChildExpr(i) } @@ -310,6 +320,19 @@ abstract class ExportDeclaration extends Stmt, @export_declaration { predicate isTypeOnly() { has_type_keyword(this) } override string getAPrimaryQlClass() { result = "ExportDeclaration" } + + /** + * Gets the object literal passed as part of the `assert` clause, if this is + * a re-export declaration. + * + * For example, this gets the `{ type: "json" }` expression in each of the following: + * ```js + * export { x } from 'foo' assert { type: "json" }; + * export * from 'foo' assert { type: "json" }; + * export * as x from 'foo' assert { type: "json" }; + * ``` + */ + ObjectExpr getImportAssertion() { result = this.getChildExpr(-10) } } /** diff --git a/javascript/ql/lib/semmle/javascript/Expr.qll b/javascript/ql/lib/semmle/javascript/Expr.qll index 925352cacad..aa1b19e0ab9 100644 --- a/javascript/ql/lib/semmle/javascript/Expr.qll +++ b/javascript/ql/lib/semmle/javascript/Expr.qll @@ -2807,6 +2807,7 @@ class FunctionBindExpr extends @bind_expr, Expr { * * ``` * import("fs") + * import("foo", { assert: { type: "json" }}) * ``` */ class DynamicImportExpr extends @dynamic_import, Expr, Import { @@ -2819,6 +2820,16 @@ class DynamicImportExpr extends @dynamic_import, Expr, Import { override PathExpr getImportedPath() { result = this.getSource() } + /** + * Gets the second "argument" to the import expression, that is, the `Y` in `import(X, Y)`. + * + * For example, gets the `{ assert: { type: "json" }}` expression in the following: + * ```js + * import('foo', { assert: { type: "json" }}) + * ``` + */ + Expr getImportAttributes() { result = this.getChildExpr(1) } + override Module getEnclosingModule() { result = this.getTopLevel() } override DataFlow::Node getImportedModuleNode() { result = DataFlow::valueNode(this) } diff --git a/javascript/ql/test/library-tests/TypeScript/ImportAssertions/js-import-assertions.js b/javascript/ql/test/library-tests/TypeScript/ImportAssertions/js-import-assertions.js new file mode 100644 index 00000000000..23c030be511 --- /dev/null +++ b/javascript/ql/test/library-tests/TypeScript/ImportAssertions/js-import-assertions.js @@ -0,0 +1,13 @@ +import "module" assert { type: "json" }; +import * as v1 from "module" assert { type: "json" }; +import { v2 } from "module" assert { type: "json" }; +import v3 from "module" assert { type: "json" }; + +export { v4 } from "module" assert { type: "json" }; +export * from "module" assert { type: "json" }; +export * as v5 from "module" assert { type: "json" }; + +const v6 = import("module", { assert: { type: "json" } }); + +import "module" // missing semicolon +assert({type: "json"}); // function call, not import assertion diff --git a/javascript/ql/test/library-tests/TypeScript/ImportAssertions/test.expected b/javascript/ql/test/library-tests/TypeScript/ImportAssertions/test.expected new file mode 100644 index 00000000000..330f034c7c9 --- /dev/null +++ b/javascript/ql/test/library-tests/TypeScript/ImportAssertions/test.expected @@ -0,0 +1,20 @@ +getImportAssertionFromImport +| js-import-assertions.js:1:1:1:40 | import ... son" }; | js-import-assertions.js:1:24:1:39 | { type: "json" } | +| js-import-assertions.js:2:1:2:53 | import ... son" }; | js-import-assertions.js:2:37:2:52 | { type: "json" } | +| js-import-assertions.js:3:1:3:52 | import ... son" }; | js-import-assertions.js:3:36:3:51 | { type: "json" } | +| js-import-assertions.js:4:1:4:48 | import ... son" }; | js-import-assertions.js:4:32:4:47 | { type: "json" } | +| ts-import-assertions.ts:3:1:3:40 | import ... son" }; | ts-import-assertions.ts:3:17:3:39 | assert ... json" } | +| ts-import-assertions.ts:4:1:4:53 | import ... son" }; | ts-import-assertions.ts:4:30:4:52 | assert ... json" } | +| ts-import-assertions.ts:5:1:5:52 | import ... son" }; | ts-import-assertions.ts:5:29:5:51 | assert ... json" } | +| ts-import-assertions.ts:6:1:6:48 | import ... son" }; | ts-import-assertions.ts:6:25:6:47 | assert ... json" } | +getImportAssertionFromExport +| js-import-assertions.js:6:1:6:52 | export ... son" }; | js-import-assertions.js:6:36:6:51 | { type: "json" } | +| js-import-assertions.js:7:1:7:47 | export ... son" }; | js-import-assertions.js:7:31:7:46 | { type: "json" } | +| js-import-assertions.js:8:1:8:53 | export ... son" }; | js-import-assertions.js:8:37:8:52 | { type: "json" } | +| ts-import-assertions.ts:8:1:8:52 | export ... son" }; | ts-import-assertions.ts:8:29:8:51 | assert ... json" } | +| ts-import-assertions.ts:9:1:9:47 | export ... son" }; | ts-import-assertions.ts:9:24:9:46 | assert ... json" } | +| ts-import-assertions.ts:10:1:10:53 | export ... son" }; | ts-import-assertions.ts:10:30:10:52 | assert ... json" } | +getImportAttributes +| js-import-assertions.js:10:12:10:57 | import( ... n" } }) | js-import-assertions.js:10:29:10:56 | { asser ... on" } } | +| ts-import-assertions.ts:12:12:12:57 | import( ... n" } }) | ts-import-assertions.ts:12:29:12:56 | { asser ... on" } } | +errors diff --git a/javascript/ql/test/library-tests/TypeScript/ImportAssertions/test.ql b/javascript/ql/test/library-tests/TypeScript/ImportAssertions/test.ql new file mode 100644 index 00000000000..d7017a652ef --- /dev/null +++ b/javascript/ql/test/library-tests/TypeScript/ImportAssertions/test.ql @@ -0,0 +1,13 @@ +import javascript + +query Expr getImportAssertionFromImport(ImportDeclaration decl) { + result = decl.getImportAssertion() +} + +query Expr getImportAssertionFromExport(ExportDeclaration decl) { + result = decl.getImportAssertion() +} + +query Expr getImportAttributes(DynamicImportExpr imprt) { result = imprt.getImportAttributes() } + +query JSParseError errors() { any() } diff --git a/javascript/ql/test/library-tests/TypeScript/ImportAssertions/ts-import-assertions.ts b/javascript/ql/test/library-tests/TypeScript/ImportAssertions/ts-import-assertions.ts new file mode 100644 index 00000000000..5d46b200f54 --- /dev/null +++ b/javascript/ql/test/library-tests/TypeScript/ImportAssertions/ts-import-assertions.ts @@ -0,0 +1,15 @@ +// TypeScript + +import "module" assert { type: "json" }; +import * as v1 from "module" assert { type: "json" }; +import { v2 } from "module" assert { type: "json" }; +import v3 from "module" assert { type: "json" }; + +export { v4 } from "module" assert { type: "json" }; +export * from "module" assert { type: "json" }; +export * as v5 from "module" assert { type: "json" }; + +const v6 = import("module", { assert: { type: "json" } }); + +import "module" // missing semicolon +assert({ type: "json" }); // function call, not import assertion From 7a55b003d23d924717b90292313e3970074d3a1f Mon Sep 17 00:00:00 2001 From: Asger F Date: Fri, 3 Mar 2023 11:59:51 +0100 Subject: [PATCH 026/135] JS: Fix location of assert clause --- .../ts/extractor/TypeScriptASTConverter.java | 6 +++ .../ts/output/trap/import-assertion.ts.trap | 42 +++++++++---------- .../TypeScript/ImportAssertions/test.expected | 14 +++---- 3 files changed, 34 insertions(+), 28 deletions(-) diff --git a/javascript/extractor/src/com/semmle/ts/extractor/TypeScriptASTConverter.java b/javascript/extractor/src/com/semmle/ts/extractor/TypeScriptASTConverter.java index f003381064c..b0efdcf4b79 100644 --- a/javascript/extractor/src/com/semmle/ts/extractor/TypeScriptASTConverter.java +++ b/javascript/extractor/src/com/semmle/ts/extractor/TypeScriptASTConverter.java @@ -177,6 +177,7 @@ public class TypeScriptASTConverter { private static final Pattern EXPORT_DECL_START = Pattern.compile("^export" + "(" + WHITESPACE_CHAR + "+default)?" + WHITESPACE_CHAR + "+"); private static final Pattern TYPEOF_START = Pattern.compile("^typeof" + WHITESPACE_CHAR + "+"); + private static final Pattern ASSERT_START = Pattern.compile("^assert" + WHITESPACE_CHAR + "+"); private static final Pattern WHITESPACE_END_PAREN = Pattern.compile("^" + WHITESPACE_CHAR + "*\\)"); @@ -2287,6 +2288,11 @@ public class TypeScriptASTConverter { for (INode child : convertChildren(node, "elements")) { properties.add((Property)child); } + // Adjust location to skip over the `assert` keyword. + Matcher m = ASSERT_START.matcher(loc.getSource()); + if (m.find()) { + advance(loc, m.group(0)); + } return new ObjectExpression(loc, properties); } diff --git a/javascript/extractor/tests/ts/output/trap/import-assertion.ts.trap b/javascript/extractor/tests/ts/output/trap/import-assertion.ts.trap index 82d6671b171..f760d246f7d 100644 --- a/javascript/extractor/tests/ts/output/trap/import-assertion.ts.trap +++ b/javascript/extractor/tests/ts/output/trap/import-assertion.ts.trap @@ -726,9 +726,9 @@ locations_default(#20275,#10000,1,9,1,14) hasLocation(#20274,#20275) regexp_const_value(#20274,"module") #20276=* -exprs(#20276,8,#20272,-10,"assert ... json"" }") -#20277=@"loc,{#10000},1,17,1,39" -locations_default(#20277,#10000,1,17,1,39) +exprs(#20276,8,#20272,-10,"{ type: ""json"" }") +#20277=@"loc,{#10000},1,24,1,39" +locations_default(#20277,#10000,1,24,1,39) hasLocation(#20276,#20277) enclosing_stmt(#20276,#20272) expr_containers(#20276,#20001) @@ -754,9 +754,9 @@ locations_default(#20283,#10000,2,22,2,27) hasLocation(#20282,#20283) regexp_const_value(#20282,"module") #20284=* -exprs(#20284,8,#20280,-10,"assert ... json"" }") -#20285=@"loc,{#10000},2,30,2,52" -locations_default(#20285,#10000,2,30,2,52) +exprs(#20284,8,#20280,-10,"{ type: ""json"" }") +#20285=@"loc,{#10000},2,37,2,52" +locations_default(#20285,#10000,2,37,2,52) hasLocation(#20284,#20285) enclosing_stmt(#20284,#20280) expr_containers(#20284,#20001) @@ -798,9 +798,9 @@ locations_default(#20294,#10000,3,21,3,26) hasLocation(#20293,#20294) regexp_const_value(#20293,"module") #20295=* -exprs(#20295,8,#20291,-10,"assert ... json"" }") -#20296=@"loc,{#10000},3,29,3,51" -locations_default(#20296,#10000,3,29,3,51) +exprs(#20295,8,#20291,-10,"{ type: ""json"" }") +#20296=@"loc,{#10000},3,36,3,51" +locations_default(#20296,#10000,3,36,3,51) hasLocation(#20295,#20296) enclosing_stmt(#20295,#20291) expr_containers(#20295,#20001) @@ -846,9 +846,9 @@ locations_default(#20305,#10000,4,17,4,22) hasLocation(#20304,#20305) regexp_const_value(#20304,"module") #20306=* -exprs(#20306,8,#20302,-10,"assert ... json"" }") -#20307=@"loc,{#10000},4,25,4,47" -locations_default(#20307,#10000,4,25,4,47) +exprs(#20306,8,#20302,-10,"{ type: ""json"" }") +#20307=@"loc,{#10000},4,32,4,47" +locations_default(#20307,#10000,4,32,4,47) hasLocation(#20306,#20307) enclosing_stmt(#20306,#20302) expr_containers(#20306,#20001) @@ -888,9 +888,9 @@ locations_default(#20315,#10000,6,21,6,26) hasLocation(#20314,#20315) regexp_const_value(#20314,"module") #20316=* -exprs(#20316,8,#20312,-10,"assert ... json"" }") -#20317=@"loc,{#10000},6,29,6,51" -locations_default(#20317,#10000,6,29,6,51) +exprs(#20316,8,#20312,-10,"{ type: ""json"" }") +#20317=@"loc,{#10000},6,36,6,51" +locations_default(#20317,#10000,6,36,6,51) hasLocation(#20316,#20317) enclosing_stmt(#20316,#20312) expr_containers(#20316,#20001) @@ -933,9 +933,9 @@ locations_default(#20326,#10000,7,16,7,21) hasLocation(#20325,#20326) regexp_const_value(#20325,"module") #20327=* -exprs(#20327,8,#20323,-10,"assert ... json"" }") -#20328=@"loc,{#10000},7,24,7,46" -locations_default(#20328,#10000,7,24,7,46) +exprs(#20327,8,#20323,-10,"{ type: ""json"" }") +#20328=@"loc,{#10000},7,31,7,46" +locations_default(#20328,#10000,7,31,7,46) hasLocation(#20327,#20328) enclosing_stmt(#20327,#20323) expr_containers(#20327,#20001) @@ -961,9 +961,9 @@ locations_default(#20334,#10000,8,22,8,27) hasLocation(#20333,#20334) regexp_const_value(#20333,"module") #20335=* -exprs(#20335,8,#20331,-10,"assert ... json"" }") -#20336=@"loc,{#10000},8,30,8,52" -locations_default(#20336,#10000,8,30,8,52) +exprs(#20335,8,#20331,-10,"{ type: ""json"" }") +#20336=@"loc,{#10000},8,37,8,52" +locations_default(#20336,#10000,8,37,8,52) hasLocation(#20335,#20336) enclosing_stmt(#20335,#20331) expr_containers(#20335,#20001) diff --git a/javascript/ql/test/library-tests/TypeScript/ImportAssertions/test.expected b/javascript/ql/test/library-tests/TypeScript/ImportAssertions/test.expected index 330f034c7c9..828391ac313 100644 --- a/javascript/ql/test/library-tests/TypeScript/ImportAssertions/test.expected +++ b/javascript/ql/test/library-tests/TypeScript/ImportAssertions/test.expected @@ -3,17 +3,17 @@ getImportAssertionFromImport | js-import-assertions.js:2:1:2:53 | import ... son" }; | js-import-assertions.js:2:37:2:52 | { type: "json" } | | js-import-assertions.js:3:1:3:52 | import ... son" }; | js-import-assertions.js:3:36:3:51 | { type: "json" } | | js-import-assertions.js:4:1:4:48 | import ... son" }; | js-import-assertions.js:4:32:4:47 | { type: "json" } | -| ts-import-assertions.ts:3:1:3:40 | import ... son" }; | ts-import-assertions.ts:3:17:3:39 | assert ... json" } | -| ts-import-assertions.ts:4:1:4:53 | import ... son" }; | ts-import-assertions.ts:4:30:4:52 | assert ... json" } | -| ts-import-assertions.ts:5:1:5:52 | import ... son" }; | ts-import-assertions.ts:5:29:5:51 | assert ... json" } | -| ts-import-assertions.ts:6:1:6:48 | import ... son" }; | ts-import-assertions.ts:6:25:6:47 | assert ... json" } | +| ts-import-assertions.ts:3:1:3:40 | import ... son" }; | ts-import-assertions.ts:3:24:3:39 | { type: "json" } | +| ts-import-assertions.ts:4:1:4:53 | import ... son" }; | ts-import-assertions.ts:4:37:4:52 | { type: "json" } | +| ts-import-assertions.ts:5:1:5:52 | import ... son" }; | ts-import-assertions.ts:5:36:5:51 | { type: "json" } | +| ts-import-assertions.ts:6:1:6:48 | import ... son" }; | ts-import-assertions.ts:6:32:6:47 | { type: "json" } | getImportAssertionFromExport | js-import-assertions.js:6:1:6:52 | export ... son" }; | js-import-assertions.js:6:36:6:51 | { type: "json" } | | js-import-assertions.js:7:1:7:47 | export ... son" }; | js-import-assertions.js:7:31:7:46 | { type: "json" } | | js-import-assertions.js:8:1:8:53 | export ... son" }; | js-import-assertions.js:8:37:8:52 | { type: "json" } | -| ts-import-assertions.ts:8:1:8:52 | export ... son" }; | ts-import-assertions.ts:8:29:8:51 | assert ... json" } | -| ts-import-assertions.ts:9:1:9:47 | export ... son" }; | ts-import-assertions.ts:9:24:9:46 | assert ... json" } | -| ts-import-assertions.ts:10:1:10:53 | export ... son" }; | ts-import-assertions.ts:10:30:10:52 | assert ... json" } | +| ts-import-assertions.ts:8:1:8:52 | export ... son" }; | ts-import-assertions.ts:8:36:8:51 | { type: "json" } | +| ts-import-assertions.ts:9:1:9:47 | export ... son" }; | ts-import-assertions.ts:9:31:9:46 | { type: "json" } | +| ts-import-assertions.ts:10:1:10:53 | export ... son" }; | ts-import-assertions.ts:10:37:10:52 | { type: "json" } | getImportAttributes | js-import-assertions.js:10:12:10:57 | import( ... n" } }) | js-import-assertions.js:10:29:10:56 | { asser ... on" } } | | ts-import-assertions.ts:12:12:12:57 | import( ... n" } }) | ts-import-assertions.ts:12:29:12:56 | { asser ... on" } } | From 126402928221cd87620148f50c4bf97b2ebdd9a7 Mon Sep 17 00:00:00 2001 From: Asger F Date: Fri, 3 Mar 2023 12:09:49 +0100 Subject: [PATCH 027/135] JS: Bump extractor version string --- javascript/extractor/src/com/semmle/js/extractor/Main.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/javascript/extractor/src/com/semmle/js/extractor/Main.java b/javascript/extractor/src/com/semmle/js/extractor/Main.java index a90711545a5..ef712e171ce 100644 --- a/javascript/extractor/src/com/semmle/js/extractor/Main.java +++ b/javascript/extractor/src/com/semmle/js/extractor/Main.java @@ -41,7 +41,7 @@ public class Main { * A version identifier that should be updated every time the extractor changes in such a way that * it may produce different tuples for the same file under the same {@link ExtractorConfig}. */ - public static final String EXTRACTOR_VERSION = "2023-02-15"; + public static final String EXTRACTOR_VERSION = "2023-03-03"; public static final Pattern NEWLINE = Pattern.compile("\n"); From 7f96fe725bcc75fea6effcbac98bc816744e1edc Mon Sep 17 00:00:00 2001 From: Asger F Date: Fri, 3 Mar 2023 12:17:15 +0100 Subject: [PATCH 028/135] JS: Change note --- .../ql/lib/change-notes/2023-03-03-import-assertion.md | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 javascript/ql/lib/change-notes/2023-03-03-import-assertion.md diff --git a/javascript/ql/lib/change-notes/2023-03-03-import-assertion.md b/javascript/ql/lib/change-notes/2023-03-03-import-assertion.md new file mode 100644 index 00000000000..b6ee92a6660 --- /dev/null +++ b/javascript/ql/lib/change-notes/2023-03-03-import-assertion.md @@ -0,0 +1,5 @@ +--- +category: minorAnalysis +--- +* [Import assertions](https://github.com/tc39/proposal-import-assertions) are now supported. + Previously this feature was only supported in TypeScript code, but is now supported for plain JavaScript as well and is also accessible in the AST. From f4b13e09557f51fd890516a3b1b0ce54d7000f66 Mon Sep 17 00:00:00 2001 From: Asger F Date: Fri, 3 Mar 2023 13:42:42 +0100 Subject: [PATCH 029/135] JS: Update printAst expected output --- .../test/library-tests/TypeScript/Types/printAst.expected | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/javascript/ql/test/library-tests/TypeScript/Types/printAst.expected b/javascript/ql/test/library-tests/TypeScript/Types/printAst.expected index e650e55fccf..751e6fd3c07 100644 --- a/javascript/ql/test/library-tests/TypeScript/Types/printAst.expected +++ b/javascript/ql/test/library-tests/TypeScript/Types/printAst.expected @@ -949,6 +949,8 @@ nodes | tst.ts:237:8:237:16 | [ImportSpecifier] * as Foo3 | semmle.label | [ImportSpecifier] * as Foo3 | | tst.ts:237:13:237:16 | [VarDecl] Foo3 | semmle.label | [VarDecl] Foo3 | | tst.ts:237:23:237:40 | [Literal] "./something.json" | semmle.label | [Literal] "./something.json" | +| tst.ts:237:49:237:64 | [ObjectExpr] { type: "json" } | semmle.label | [ObjectExpr] { type: "json" } | +| tst.ts:237:51:237:62 | [Property] type: "json" | semmle.label | [Property] type: "json" | | tst.ts:238:1:238:19 | [DeclStmt] var foo = ... | semmle.label | [DeclStmt] var foo = ... | | tst.ts:238:1:238:19 | [DeclStmt] var foo = ... | semmle.order | 59 | | tst.ts:238:5:238:7 | [VarDecl] foo | semmle.label | [VarDecl] foo | @@ -3461,8 +3463,12 @@ edges | tst.ts:237:1:237:65 | [ImportDeclaration] import ... son" }; | tst.ts:237:8:237:16 | [ImportSpecifier] * as Foo3 | semmle.order | 1 | | tst.ts:237:1:237:65 | [ImportDeclaration] import ... son" }; | tst.ts:237:23:237:40 | [Literal] "./something.json" | semmle.label | 2 | | tst.ts:237:1:237:65 | [ImportDeclaration] import ... son" }; | tst.ts:237:23:237:40 | [Literal] "./something.json" | semmle.order | 2 | +| tst.ts:237:1:237:65 | [ImportDeclaration] import ... son" }; | tst.ts:237:49:237:64 | [ObjectExpr] { type: "json" } | semmle.label | 3 | +| tst.ts:237:1:237:65 | [ImportDeclaration] import ... son" }; | tst.ts:237:49:237:64 | [ObjectExpr] { type: "json" } | semmle.order | 3 | | tst.ts:237:8:237:16 | [ImportSpecifier] * as Foo3 | tst.ts:237:13:237:16 | [VarDecl] Foo3 | semmle.label | 1 | | tst.ts:237:8:237:16 | [ImportSpecifier] * as Foo3 | tst.ts:237:13:237:16 | [VarDecl] Foo3 | semmle.order | 1 | +| tst.ts:237:49:237:64 | [ObjectExpr] { type: "json" } | tst.ts:237:51:237:62 | [Property] type: "json" | semmle.label | 1 | +| tst.ts:237:49:237:64 | [ObjectExpr] { type: "json" } | tst.ts:237:51:237:62 | [Property] type: "json" | semmle.order | 1 | | tst.ts:238:1:238:19 | [DeclStmt] var foo = ... | tst.ts:238:5:238:18 | [VariableDeclarator] foo = Foo3.foo | semmle.label | 1 | | tst.ts:238:1:238:19 | [DeclStmt] var foo = ... | tst.ts:238:5:238:18 | [VariableDeclarator] foo = Foo3.foo | semmle.order | 1 | | tst.ts:238:5:238:18 | [VariableDeclarator] foo = Foo3.foo | tst.ts:238:5:238:7 | [VarDecl] foo | semmle.label | 1 | From 37999eaea04d0b2ca77aa589cbfb8b0b3491e9b2 Mon Sep 17 00:00:00 2001 From: Asger F Date: Fri, 3 Mar 2023 13:43:17 +0100 Subject: [PATCH 030/135] JS: Fix implicit this --- javascript/ql/lib/semmle/javascript/ES2015Modules.qll | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/javascript/ql/lib/semmle/javascript/ES2015Modules.qll b/javascript/ql/lib/semmle/javascript/ES2015Modules.qll index 535d2317aa3..6f139fb95b0 100644 --- a/javascript/ql/lib/semmle/javascript/ES2015Modules.qll +++ b/javascript/ql/lib/semmle/javascript/ES2015Modules.qll @@ -98,7 +98,7 @@ class ImportDeclaration extends Stmt, Import, @import_declaration { * import foo from "foo" assert { type: "json" }; * ``` */ - ObjectExpr getImportAssertion() { result = getChildExpr(-10) } + ObjectExpr getImportAssertion() { result = this.getChildExpr(-10) } /** Gets the `i`th import specifier of this import declaration. */ ImportSpecifier getSpecifier(int i) { result = getChildExpr(i) } From b875d30bc6963169f3760449ebb5ee0b57ac1912 Mon Sep 17 00:00:00 2001 From: erik-krogh Date: Fri, 3 Mar 2023 15:55:17 +0100 Subject: [PATCH 031/135] fix repeated predicate name in change-note --- csharp/ql/lib/change-notes/2023-03-03-delete-deps.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/csharp/ql/lib/change-notes/2023-03-03-delete-deps.md b/csharp/ql/lib/change-notes/2023-03-03-delete-deps.md index 05ddd56617a..f5557fc5b77 100644 --- a/csharp/ql/lib/change-notes/2023-03-03-delete-deps.md +++ b/csharp/ql/lib/change-notes/2023-03-03-delete-deps.md @@ -2,5 +2,5 @@ category: minorAnalysis --- * Deleted the deprecated `getPath` and `getFolder` predicates from the `XmlFile` class. -* Deleted the deprecated `getAssertionIndex`, `getAssertedParameter`, and `getAssertedParameter` predicates from the `AssertMethod` class. +* Deleted the deprecated `getAssertionIndex`, and `getAssertedParameter` predicates from the `AssertMethod` class. * Deleted the deprecated `OverridableMethod` and `OverridableAccessor` classes. From 0affd898dec7db7b246ff4fe3c3934e6097c8e76 Mon Sep 17 00:00:00 2001 From: Asger F Date: Tue, 7 Mar 2023 10:22:26 +0100 Subject: [PATCH 032/135] JS: Track trusted type policy callbacks --- .../ql/lib/semmle/javascript/frameworks/TrustedTypes.qll | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/javascript/ql/lib/semmle/javascript/frameworks/TrustedTypes.qll b/javascript/ql/lib/semmle/javascript/frameworks/TrustedTypes.qll index b1b2cc6cf0a..3fcd5a2d436 100644 --- a/javascript/ql/lib/semmle/javascript/frameworks/TrustedTypes.qll +++ b/javascript/ql/lib/semmle/javascript/frameworks/TrustedTypes.qll @@ -25,8 +25,7 @@ module TrustedTypes { /** Gets the function passed as the given option. */ DataFlow::FunctionNode getPolicyCallback(string method) { - // Require local callback to avoid potential call/return mismatch in the uses below - result = getOptionArgument(1, method).getALocalSource() + result = getParameter(1).getMember(method).getAValueReachingSink() } } From 856b50735d64144c219e18430758cd40f57a8ea5 Mon Sep 17 00:00:00 2001 From: Asger F Date: Tue, 7 Mar 2023 13:04:26 +0100 Subject: [PATCH 033/135] JS: Expand test case --- .../Security/CWE-079/DomBasedXss/Xss.expected | 51 ++++++++++++------- .../XssWithAdditionalSources.expected | 48 +++++++++++------ .../CWE-079/DomBasedXss/trusted-types-lib.js | 3 ++ .../CWE-079/DomBasedXss/trusted-types.js | 19 ++++--- 4 files changed, 80 insertions(+), 41 deletions(-) create mode 100644 javascript/ql/test/query-tests/Security/CWE-079/DomBasedXss/trusted-types-lib.js diff --git a/javascript/ql/test/query-tests/Security/CWE-079/DomBasedXss/Xss.expected b/javascript/ql/test/query-tests/Security/CWE-079/DomBasedXss/Xss.expected index d5f29d04ae7..95fbc8f15c3 100644 --- a/javascript/ql/test/query-tests/Security/CWE-079/DomBasedXss/Xss.expected +++ b/javascript/ql/test/query-tests/Security/CWE-079/DomBasedXss/Xss.expected @@ -689,14 +689,22 @@ nodes | translate.js:9:27:9:50 | searchP ... 'term') | | translate.js:9:27:9:50 | searchP ... 'term') | | translate.js:9:27:9:50 | searchP ... 'term') | -| trusted-types.js:2:66:2:66 | x | -| trusted-types.js:2:66:2:66 | x | -| trusted-types.js:2:71:2:71 | x | -| trusted-types.js:2:71:2:71 | x | -| trusted-types.js:2:71:2:71 | x | -| trusted-types.js:3:24:3:34 | window.name | -| trusted-types.js:3:24:3:34 | window.name | -| trusted-types.js:3:24:3:34 | window.name | +| trusted-types-lib.js:1:28:1:28 | x | +| trusted-types-lib.js:1:28:1:28 | x | +| trusted-types-lib.js:2:12:2:12 | x | +| trusted-types-lib.js:2:12:2:12 | x | +| trusted-types-lib.js:2:12:2:12 | x | +| trusted-types.js:3:62:3:62 | x | +| trusted-types.js:3:62:3:62 | x | +| trusted-types.js:3:67:3:67 | x | +| trusted-types.js:3:67:3:67 | x | +| trusted-types.js:3:67:3:67 | x | +| trusted-types.js:4:20:4:30 | window.name | +| trusted-types.js:4:20:4:30 | window.name | +| trusted-types.js:4:20:4:30 | window.name | +| trusted-types.js:13:20:13:30 | window.name | +| trusted-types.js:13:20:13:30 | window.name | +| trusted-types.js:13:20:13:30 | window.name | | tst3.js:2:12:2:75 | JSON.pa ... tr(1))) | | tst3.js:2:23:2:74 | decodeU ... str(1)) | | tst3.js:2:42:2:63 | window. ... .search | @@ -1818,14 +1826,22 @@ edges | translate.js:9:27:9:38 | searchParams | translate.js:9:27:9:50 | searchP ... 'term') | | translate.js:9:27:9:38 | searchParams | translate.js:9:27:9:50 | searchP ... 'term') | | translate.js:9:27:9:38 | searchParams | translate.js:9:27:9:50 | searchP ... 'term') | -| trusted-types.js:2:66:2:66 | x | trusted-types.js:2:71:2:71 | x | -| trusted-types.js:2:66:2:66 | x | trusted-types.js:2:71:2:71 | x | -| trusted-types.js:2:66:2:66 | x | trusted-types.js:2:71:2:71 | x | -| trusted-types.js:2:66:2:66 | x | trusted-types.js:2:71:2:71 | x | -| trusted-types.js:3:24:3:34 | window.name | trusted-types.js:2:66:2:66 | x | -| trusted-types.js:3:24:3:34 | window.name | trusted-types.js:2:66:2:66 | x | -| trusted-types.js:3:24:3:34 | window.name | trusted-types.js:2:66:2:66 | x | -| trusted-types.js:3:24:3:34 | window.name | trusted-types.js:2:66:2:66 | x | +| trusted-types-lib.js:1:28:1:28 | x | trusted-types-lib.js:2:12:2:12 | x | +| trusted-types-lib.js:1:28:1:28 | x | trusted-types-lib.js:2:12:2:12 | x | +| trusted-types-lib.js:1:28:1:28 | x | trusted-types-lib.js:2:12:2:12 | x | +| trusted-types-lib.js:1:28:1:28 | x | trusted-types-lib.js:2:12:2:12 | x | +| trusted-types.js:3:62:3:62 | x | trusted-types.js:3:67:3:67 | x | +| trusted-types.js:3:62:3:62 | x | trusted-types.js:3:67:3:67 | x | +| trusted-types.js:3:62:3:62 | x | trusted-types.js:3:67:3:67 | x | +| trusted-types.js:3:62:3:62 | x | trusted-types.js:3:67:3:67 | x | +| trusted-types.js:4:20:4:30 | window.name | trusted-types.js:3:62:3:62 | x | +| trusted-types.js:4:20:4:30 | window.name | trusted-types.js:3:62:3:62 | x | +| trusted-types.js:4:20:4:30 | window.name | trusted-types.js:3:62:3:62 | x | +| trusted-types.js:4:20:4:30 | window.name | trusted-types.js:3:62:3:62 | x | +| trusted-types.js:13:20:13:30 | window.name | trusted-types-lib.js:1:28:1:28 | x | +| trusted-types.js:13:20:13:30 | window.name | trusted-types-lib.js:1:28:1:28 | x | +| trusted-types.js:13:20:13:30 | window.name | trusted-types-lib.js:1:28:1:28 | x | +| trusted-types.js:13:20:13:30 | window.name | trusted-types-lib.js:1:28:1:28 | x | | tst3.js:2:12:2:75 | JSON.pa ... tr(1))) | tst3.js:4:25:4:28 | data | | tst3.js:2:12:2:75 | JSON.pa ... tr(1))) | tst3.js:5:26:5:29 | data | | tst3.js:2:12:2:75 | JSON.pa ... tr(1))) | tst3.js:7:32:7:35 | data | @@ -2382,7 +2398,8 @@ edges | tooltip.jsx:10:25:10:30 | source | tooltip.jsx:6:20:6:30 | window.name | tooltip.jsx:10:25:10:30 | source | Cross-site scripting vulnerability due to $@. | tooltip.jsx:6:20:6:30 | window.name | user-provided value | | tooltip.jsx:11:25:11:30 | source | tooltip.jsx:6:20:6:30 | window.name | tooltip.jsx:11:25:11:30 | source | Cross-site scripting vulnerability due to $@. | tooltip.jsx:6:20:6:30 | window.name | user-provided value | | translate.js:9:27:9:50 | searchP ... 'term') | translate.js:6:16:6:39 | documen ... .search | translate.js:9:27:9:50 | searchP ... 'term') | Cross-site scripting vulnerability due to $@. | translate.js:6:16:6:39 | documen ... .search | user-provided value | -| trusted-types.js:2:71:2:71 | x | trusted-types.js:3:24:3:34 | window.name | trusted-types.js:2:71:2:71 | x | Cross-site scripting vulnerability due to $@. | trusted-types.js:3:24:3:34 | window.name | user-provided value | +| trusted-types-lib.js:2:12:2:12 | x | trusted-types.js:13:20:13:30 | window.name | trusted-types-lib.js:2:12:2:12 | x | Cross-site scripting vulnerability due to $@. | trusted-types.js:13:20:13:30 | window.name | user-provided value | +| trusted-types.js:3:67:3:67 | x | trusted-types.js:4:20:4:30 | window.name | trusted-types.js:3:67:3:67 | x | Cross-site scripting vulnerability due to $@. | trusted-types.js:4:20:4:30 | window.name | user-provided value | | tst3.js:4:25:4:32 | data.src | tst3.js:2:42:2:63 | window. ... .search | tst3.js:4:25:4:32 | data.src | Cross-site scripting vulnerability due to $@. | tst3.js:2:42:2:63 | window. ... .search | user-provided value | | tst3.js:5:26:5:31 | data.p | tst3.js:2:42:2:63 | window. ... .search | tst3.js:5:26:5:31 | data.p | Cross-site scripting vulnerability due to $@. | tst3.js:2:42:2:63 | window. ... .search | user-provided value | | tst3.js:7:32:7:37 | data.p | tst3.js:2:42:2:63 | window. ... .search | tst3.js:7:32:7:37 | data.p | Cross-site scripting vulnerability due to $@. | tst3.js:2:42:2:63 | window. ... .search | user-provided value | diff --git a/javascript/ql/test/query-tests/Security/CWE-079/DomBasedXss/XssWithAdditionalSources.expected b/javascript/ql/test/query-tests/Security/CWE-079/DomBasedXss/XssWithAdditionalSources.expected index 68e29eacab4..03c3dd0d9ca 100644 --- a/javascript/ql/test/query-tests/Security/CWE-079/DomBasedXss/XssWithAdditionalSources.expected +++ b/javascript/ql/test/query-tests/Security/CWE-079/DomBasedXss/XssWithAdditionalSources.expected @@ -701,14 +701,22 @@ nodes | translate.js:9:27:9:50 | searchP ... 'term') | | translate.js:9:27:9:50 | searchP ... 'term') | | translate.js:9:27:9:50 | searchP ... 'term') | -| trusted-types.js:2:66:2:66 | x | -| trusted-types.js:2:66:2:66 | x | -| trusted-types.js:2:71:2:71 | x | -| trusted-types.js:2:71:2:71 | x | -| trusted-types.js:2:71:2:71 | x | -| trusted-types.js:3:24:3:34 | window.name | -| trusted-types.js:3:24:3:34 | window.name | -| trusted-types.js:3:24:3:34 | window.name | +| trusted-types-lib.js:1:28:1:28 | x | +| trusted-types-lib.js:1:28:1:28 | x | +| trusted-types-lib.js:2:12:2:12 | x | +| trusted-types-lib.js:2:12:2:12 | x | +| trusted-types-lib.js:2:12:2:12 | x | +| trusted-types.js:3:62:3:62 | x | +| trusted-types.js:3:62:3:62 | x | +| trusted-types.js:3:67:3:67 | x | +| trusted-types.js:3:67:3:67 | x | +| trusted-types.js:3:67:3:67 | x | +| trusted-types.js:4:20:4:30 | window.name | +| trusted-types.js:4:20:4:30 | window.name | +| trusted-types.js:4:20:4:30 | window.name | +| trusted-types.js:13:20:13:30 | window.name | +| trusted-types.js:13:20:13:30 | window.name | +| trusted-types.js:13:20:13:30 | window.name | | tst3.js:2:12:2:75 | JSON.pa ... tr(1))) | | tst3.js:2:23:2:74 | decodeU ... str(1)) | | tst3.js:2:42:2:63 | window. ... .search | @@ -1880,14 +1888,22 @@ edges | translate.js:9:27:9:38 | searchParams | translate.js:9:27:9:50 | searchP ... 'term') | | translate.js:9:27:9:38 | searchParams | translate.js:9:27:9:50 | searchP ... 'term') | | translate.js:9:27:9:38 | searchParams | translate.js:9:27:9:50 | searchP ... 'term') | -| trusted-types.js:2:66:2:66 | x | trusted-types.js:2:71:2:71 | x | -| trusted-types.js:2:66:2:66 | x | trusted-types.js:2:71:2:71 | x | -| trusted-types.js:2:66:2:66 | x | trusted-types.js:2:71:2:71 | x | -| trusted-types.js:2:66:2:66 | x | trusted-types.js:2:71:2:71 | x | -| trusted-types.js:3:24:3:34 | window.name | trusted-types.js:2:66:2:66 | x | -| trusted-types.js:3:24:3:34 | window.name | trusted-types.js:2:66:2:66 | x | -| trusted-types.js:3:24:3:34 | window.name | trusted-types.js:2:66:2:66 | x | -| trusted-types.js:3:24:3:34 | window.name | trusted-types.js:2:66:2:66 | x | +| trusted-types-lib.js:1:28:1:28 | x | trusted-types-lib.js:2:12:2:12 | x | +| trusted-types-lib.js:1:28:1:28 | x | trusted-types-lib.js:2:12:2:12 | x | +| trusted-types-lib.js:1:28:1:28 | x | trusted-types-lib.js:2:12:2:12 | x | +| trusted-types-lib.js:1:28:1:28 | x | trusted-types-lib.js:2:12:2:12 | x | +| trusted-types.js:3:62:3:62 | x | trusted-types.js:3:67:3:67 | x | +| trusted-types.js:3:62:3:62 | x | trusted-types.js:3:67:3:67 | x | +| trusted-types.js:3:62:3:62 | x | trusted-types.js:3:67:3:67 | x | +| trusted-types.js:3:62:3:62 | x | trusted-types.js:3:67:3:67 | x | +| trusted-types.js:4:20:4:30 | window.name | trusted-types.js:3:62:3:62 | x | +| trusted-types.js:4:20:4:30 | window.name | trusted-types.js:3:62:3:62 | x | +| trusted-types.js:4:20:4:30 | window.name | trusted-types.js:3:62:3:62 | x | +| trusted-types.js:4:20:4:30 | window.name | trusted-types.js:3:62:3:62 | x | +| trusted-types.js:13:20:13:30 | window.name | trusted-types-lib.js:1:28:1:28 | x | +| trusted-types.js:13:20:13:30 | window.name | trusted-types-lib.js:1:28:1:28 | x | +| trusted-types.js:13:20:13:30 | window.name | trusted-types-lib.js:1:28:1:28 | x | +| trusted-types.js:13:20:13:30 | window.name | trusted-types-lib.js:1:28:1:28 | x | | tst3.js:2:12:2:75 | JSON.pa ... tr(1))) | tst3.js:4:25:4:28 | data | | tst3.js:2:12:2:75 | JSON.pa ... tr(1))) | tst3.js:5:26:5:29 | data | | tst3.js:2:12:2:75 | JSON.pa ... tr(1))) | tst3.js:7:32:7:35 | data | diff --git a/javascript/ql/test/query-tests/Security/CWE-079/DomBasedXss/trusted-types-lib.js b/javascript/ql/test/query-tests/Security/CWE-079/DomBasedXss/trusted-types-lib.js new file mode 100644 index 00000000000..75137f7de5c --- /dev/null +++ b/javascript/ql/test/query-tests/Security/CWE-079/DomBasedXss/trusted-types-lib.js @@ -0,0 +1,3 @@ +export function createHtml(x) { + return x; +} diff --git a/javascript/ql/test/query-tests/Security/CWE-079/DomBasedXss/trusted-types.js b/javascript/ql/test/query-tests/Security/CWE-079/DomBasedXss/trusted-types.js index cba48137122..7702768d603 100644 --- a/javascript/ql/test/query-tests/Security/CWE-079/DomBasedXss/trusted-types.js +++ b/javascript/ql/test/query-tests/Security/CWE-079/DomBasedXss/trusted-types.js @@ -1,10 +1,13 @@ -(function() { - const policy1 = trustedTypes.createPolicy('x', { createHTML: x => x }); // NOT OK - policy1.createHTML(window.name); +import * as lib from './trusted-types-lib'; - const policy2 = trustedTypes.createPolicy('x', { createHTML: x => 'safe' }); // OK - policy2.createHTML(window.name); +const policy1 = trustedTypes.createPolicy('x', { createHTML: x => x }); // NOT OK +policy1.createHTML(window.name); - const policy3 = trustedTypes.createPolicy('x', { createHTML: x => x }); // OK - policy3.createHTML('safe'); -})(); +const policy2 = trustedTypes.createPolicy('x', { createHTML: x => 'safe' }); // OK +policy2.createHTML(window.name); + +const policy3 = trustedTypes.createPolicy('x', { createHTML: x => x }); // OK +policy3.createHTML('safe'); + +const policy4 = trustedTypes.createPolicy('x', { createHTML: lib.createHtml }); +policy4.createHTML(window.name); From 4cb5bea2c6d27917345bbd4e7a46248154006134 Mon Sep 17 00:00:00 2001 From: Mathias Vorreiter Pedersen Date: Wed, 8 Mar 2023 13:23:05 +0000 Subject: [PATCH 034/135] C++: Add simple negation test cases. --- .../ir/range-analysis/SimpleRangeAnalysis_tests.cpp | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/cpp/ql/test/library-tests/ir/range-analysis/SimpleRangeAnalysis_tests.cpp b/cpp/ql/test/library-tests/ir/range-analysis/SimpleRangeAnalysis_tests.cpp index 38eaeab3b12..ae23b106bf2 100644 --- a/cpp/ql/test/library-tests/ir/range-analysis/SimpleRangeAnalysis_tests.cpp +++ b/cpp/ql/test/library-tests/ir/range-analysis/SimpleRangeAnalysis_tests.cpp @@ -997,3 +997,15 @@ void test_overflow() { range(x + y); // $ range===-2147483393 } } + +void test_negate_unsigned(unsigned u) { + if(10 < u && u < 20) { + range(-u); // underflows + } +} + +void test_negate_signed(int s) { + if(10 < s && s < 20) { + range(-s); // $ MISSING: range=<=-11 range=>=-19 + } +} \ No newline at end of file From b0cb65403bd0ce111187342bfcc357baa24d481f Mon Sep 17 00:00:00 2001 From: Mathias Vorreiter Pedersen Date: Wed, 8 Mar 2023 13:23:18 +0000 Subject: [PATCH 035/135] C++: Add range analysis for unary minus. --- .../code/cpp/semantic/analysis/RangeAnalysisStage.qll | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/cpp/ql/lib/experimental/semmle/code/cpp/semantic/analysis/RangeAnalysisStage.qll b/cpp/ql/lib/experimental/semmle/code/cpp/semantic/analysis/RangeAnalysisStage.qll index fc9e4cfbaef..33b758d6439 100644 --- a/cpp/ql/lib/experimental/semmle/code/cpp/semantic/analysis/RangeAnalysisStage.qll +++ b/cpp/ql/lib/experimental/semmle/code/cpp/semantic/analysis/RangeAnalysisStage.qll @@ -1020,6 +1020,15 @@ module RangeStage Bounds, LangSig LangParam, UtilSig< or upper = false and delta = D::fromFloat(D::toFloat(d1).minimum(D::toFloat(d2))) ) + or + exists(SemExpr mid, D::Delta d, float f | + e.(SemNegateExpr).getOperand() = mid and + b instanceof SemZeroBound and + bounded(mid, b, d, upper.booleanNot(), fromBackEdge, origdelta, reason) and + f = -D::toFloat(d) and + delta = D::fromFloat(f) and + if semPositive(e) then f >= 0 else any() + ) ) } From ce0f2b1788567448cc9c18defbdf17bab3d75d4c Mon Sep 17 00:00:00 2001 From: Mathias Vorreiter Pedersen Date: Tue, 7 Mar 2023 17:43:21 +0000 Subject: [PATCH 036/135] C++: Accept test changes. --- .../SimpleRangeAnalysis_tests.cpp | 24 +++++++++---------- 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/cpp/ql/test/library-tests/ir/range-analysis/SimpleRangeAnalysis_tests.cpp b/cpp/ql/test/library-tests/ir/range-analysis/SimpleRangeAnalysis_tests.cpp index ae23b106bf2..6de91680886 100644 --- a/cpp/ql/test/library-tests/ir/range-analysis/SimpleRangeAnalysis_tests.cpp +++ b/cpp/ql/test/library-tests/ir/range-analysis/SimpleRangeAnalysis_tests.cpp @@ -231,8 +231,8 @@ int test_unary(int a) { int b = +a; range(b); // $ range=<=11 range=>=3 int c = -a; - range(c); - range(b+c); // $ range=<=10 range="<=+ ...:a-1" range=">=- ...+1" + range(c); // $ range=<=-3 range=>=-11 + range(b+c); // $ range=<=10 range="<=+ ...:a-1" range=">=- ...+1" range=>=-10 total += b+c; range(total); } @@ -241,8 +241,8 @@ int test_unary(int a) { int b = +a; range(b); // $ range=<=11 range=>=0 int c = -a; - range(c); - range(b+c); // $ range=<=11 range="<=+ ...:a+0" range=">=- ...+0" + range(c); // $ range=<=0 range=>=-11 + range(b+c); // $ range=<=11 range="<=+ ...:a+0" range=">=- ...+0" range=>=-11 total += b+c; range(total); } @@ -251,7 +251,7 @@ int test_unary(int a) { int b = +a; range(b); // $ range=<=11 range=>=-7 int c = -a; - range(c); + range(c); // $ range=<=7 range=>=-11 range(b+c); total += b+c; range(total); @@ -261,7 +261,7 @@ int test_unary(int a) { int b = +a; range(b); // $ range=<=1 range=>=-7 int c = -a; - range(c); + range(c); // $ range=<=7 range=>=-1 range(b+c); total += b+c; range(total); @@ -271,8 +271,8 @@ int test_unary(int a) { int b = +a; range(b); // $ range=<=0 range=>=-7 int c = -a; - range(c); - range(b+c); // $ range="<=- ...+0" range=">=+ ...:a+0" range=>=-7 + range(c); // $ range=<=7 MISSING: range=>=0 + range(b+c); // $ range="<=- ...+0" range=">=+ ...:a+0" range=>=-7 range=<=7 total += b+c; range(total); } @@ -281,8 +281,8 @@ int test_unary(int a) { int b = +a; range(b); // $ range=<=-2 range=>=-7 int c = -a; - range(c); - range(b+c); // $ range="<=- ...-1" range=">=+ ...:a+1" range=>=-6 + range(c); // $ range=<=7 range=>=2 + range(b+c); // $ range="<=- ...-1" range=">=+ ...:a+1" range=>=-6 range=<=6 total += b+c; range(total); } @@ -552,7 +552,7 @@ int test16(int x) { range(x); // $ range=<=-1 range=>=0 return 1; } - range(d); // $ range===3 + range(d); // $ range=<=0 range=>=3 // Unreachable code range(x); // $ range=<=-1 range=>=0 } range(x); // $ range=>=0 @@ -1006,6 +1006,6 @@ void test_negate_unsigned(unsigned u) { void test_negate_signed(int s) { if(10 < s && s < 20) { - range(-s); // $ MISSING: range=<=-11 range=>=-19 + range(-s); // $ range=<=-11 range=>=-19 } } \ No newline at end of file From 619266d04b69d4759b6b3245ac00da6b5f31bdc4 Mon Sep 17 00:00:00 2001 From: Mathias Vorreiter Pedersen Date: Wed, 8 Mar 2023 13:19:56 +0000 Subject: [PATCH 037/135] C++: Fix floating point imprecision. --- .../code/cpp/semantic/analysis/RangeAnalysisStage.qll | 11 ++++++++++- .../ir/range-analysis/SimpleRangeAnalysis_tests.cpp | 2 +- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/cpp/ql/lib/experimental/semmle/code/cpp/semantic/analysis/RangeAnalysisStage.qll b/cpp/ql/lib/experimental/semmle/code/cpp/semantic/analysis/RangeAnalysisStage.qll index 33b758d6439..e6eaa908d79 100644 --- a/cpp/ql/lib/experimental/semmle/code/cpp/semantic/analysis/RangeAnalysisStage.qll +++ b/cpp/ql/lib/experimental/semmle/code/cpp/semantic/analysis/RangeAnalysisStage.qll @@ -936,6 +936,15 @@ module RangeStage Bounds, LangSig LangParam, UtilSig< bounded(cast.getOperand(), b, delta, upper, fromBackEdge, origdelta, reason) } + /** + * Computes a normal form of `x` where -0.0 has changed to +0.0. This can be + * needed on the lesser side of a floating-point comparison or on both sides of + * a floating point equality because QL does not follow IEEE in floating-point + * comparisons but instead defines -0.0 to be less than and distinct from 0.0. + */ + bindingset[x] + private float normalizeFloatUp(float x) { result = x + 0.0 } + /** * Holds if `b + delta` is a valid bound for `e`. * - `upper = true` : `e <= b + delta` @@ -1025,7 +1034,7 @@ module RangeStage Bounds, LangSig LangParam, UtilSig< e.(SemNegateExpr).getOperand() = mid and b instanceof SemZeroBound and bounded(mid, b, d, upper.booleanNot(), fromBackEdge, origdelta, reason) and - f = -D::toFloat(d) and + f = normalizeFloatUp(-D::toFloat(d)) and delta = D::fromFloat(f) and if semPositive(e) then f >= 0 else any() ) diff --git a/cpp/ql/test/library-tests/ir/range-analysis/SimpleRangeAnalysis_tests.cpp b/cpp/ql/test/library-tests/ir/range-analysis/SimpleRangeAnalysis_tests.cpp index 6de91680886..f5790f3ddcf 100644 --- a/cpp/ql/test/library-tests/ir/range-analysis/SimpleRangeAnalysis_tests.cpp +++ b/cpp/ql/test/library-tests/ir/range-analysis/SimpleRangeAnalysis_tests.cpp @@ -271,7 +271,7 @@ int test_unary(int a) { int b = +a; range(b); // $ range=<=0 range=>=-7 int c = -a; - range(c); // $ range=<=7 MISSING: range=>=0 + range(c); // $ range=<=7 range=>=0 range(b+c); // $ range="<=- ...+0" range=">=+ ...:a+0" range=>=-7 range=<=7 total += b+c; range(total); From 618b608962f7e77bb95d4bf7868094acaeb129ba Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Tue, 17 Jan 2023 13:02:03 -0500 Subject: [PATCH 038/135] Arbitrary APK Installation MVP --- .../CWE/CWE-094/ArbitraryAPKInstallation.ql | 105 ++++++++++++++++++ .../security/CWE-094/APKInstallation.java | 38 +++++++ .../security/CWE-094/APKInstallation.qlref | 1 + .../test/query-tests/security/CWE-094/options | 2 +- 4 files changed, 145 insertions(+), 1 deletion(-) create mode 100644 java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql create mode 100644 java/ql/test/query-tests/security/CWE-094/APKInstallation.java create mode 100644 java/ql/test/query-tests/security/CWE-094/APKInstallation.qlref diff --git a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql new file mode 100644 index 00000000000..6ef44cd0869 --- /dev/null +++ b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql @@ -0,0 +1,105 @@ +/** + * @name Android APK installation + * @description Installing an APK from an untrusted source. + * @kind path-problem + * @tags security + */ + +import java +import semmle.code.java.frameworks.android.Intent +import semmle.code.java.dataflow.DataFlow +import semmle.code.java.dataflow.TaintTracking +private import semmle.code.java.dataflow.ExternalFlow + +class PackageArchiveMimeTypeLiteral extends StringLiteral { + PackageArchiveMimeTypeLiteral() { this.getValue() = "application/vnd.android.package-archive" } +} + +class SetTypeMethod extends Method { + SetTypeMethod() { + this.hasName(["setType", "setTypeAndNormalize"]) and + this.getDeclaringType().getASupertype*() instanceof TypeIntent + } +} + +class SetDataAndTypeMethod extends Method { + SetDataAndTypeMethod() { + this.hasName(["setDataAndType", "setDataAndTypeAndNormalize"]) and + this.getDeclaringType().getASupertype*() instanceof TypeIntent + } +} + +class SetDataMethod extends Method { + SetDataMethod() { + this.hasName(["setData", "setDataAndNormalize", "setDataAndType", "setDataAndTypeAndNormalize"]) and + this.getDeclaringType().getASupertype*() instanceof TypeIntent + } +} + +class SetDataSink extends DataFlow::ExprNode { + SetDataSink() { this.getExpr().(MethodAccess).getMethod() instanceof SetDataMethod } + + DataFlow::ExprNode getUri() { result.asExpr() = this.getExpr().(MethodAccess).getArgument(0) } +} + +class UriParseMethod extends Method { + UriParseMethod() { + this.hasName(["parse", "fromFile"]) and + this.getDeclaringType().hasQualifiedName("android.net", "Uri") + } +} + +class ExternalSource extends DataFlow::Node { + ExternalSource() { + sourceNode(this, "android-external-storage-dir") or + this.asExpr().(MethodAccess).getMethod() instanceof UriParseMethod or + this.asExpr().(StringLiteral).getValue().matches(["file://%", "http://%", "https://%"]) + } +} + +class ExternalSourceConfiguration extends DataFlow2::Configuration { + ExternalSourceConfiguration() { this = "ExternalSourceConfiguration" } + + override predicate isSource(DataFlow::Node node) { node instanceof ExternalSource } + + override predicate isSink(DataFlow::Node node) { + // any(PackageArchiveMimeTypeConfiguration c).hasFlow(_, node) + node instanceof SetDataSink + } +} + +class PackageArchiveMimeTypeConfiguration extends TaintTracking::Configuration { + PackageArchiveMimeTypeConfiguration() { this = "PackageArchiveMimeTypeConfiguration" } + + override predicate isSource(DataFlow::Node node) { + node.asExpr() instanceof PackageArchiveMimeTypeLiteral + } + + override predicate isAdditionalTaintStep( + DataFlow::Node node1, DataFlow::FlowState state1, DataFlow::Node node2, + DataFlow::FlowState state2 + ) { + state1 instanceof DataFlow::FlowStateEmpty and + state2 = "typeSet" and + exists(MethodAccess ma | + ma.getQualifier() = node2.asExpr() and + ( + ma.getMethod() instanceof SetTypeMethod and + ma.getArgument(0) = node1.asExpr() + or + ma.getMethod() instanceof SetDataAndTypeMethod and + ma.getArgument(1) = node1.asExpr() + ) + ) + } + + override predicate isSink(DataFlow::Node node, DataFlow::FlowState state) { + state = "typeSet" and + node instanceof SetDataSink + // and any(ExternalSourceConfiguration c).hasFlow(_, node.(SetDataSink).getUri()) + } +} + +from DataFlow::PathNode source, DataFlow::PathNode sink, PackageArchiveMimeTypeConfiguration config +where config.hasFlowPath(source, sink) +select sink.getNode(), source, sink, "Android APK installation" diff --git a/java/ql/test/query-tests/security/CWE-094/APKInstallation.java b/java/ql/test/query-tests/security/CWE-094/APKInstallation.java new file mode 100644 index 00000000000..4e16985fd0c --- /dev/null +++ b/java/ql/test/query-tests/security/CWE-094/APKInstallation.java @@ -0,0 +1,38 @@ +import android.app.Activity; +import android.content.Intent; +import android.net.Uri; + +import java.io.File; + +public class APKInstallation extends Activity { + static final String APK_MIMETYPE = "application/vnd.android.package-archive"; + + public void installAPK(String path) { + // BAD: the path is not checked + Intent intent = new Intent(Intent.ACTION_VIEW); + intent.setDataAndType(Uri.fromFile(new File(path)), "application/vnd.android.package-archive"); + startActivity(intent); + } + + public void downloadAPK(String url) { + // BAD: the url is not checked + Intent intent = new Intent(Intent.ACTION_VIEW); + intent.setDataAndType(Uri.parse(url), "application/vnd.android.package-archive"); + startActivity(intent); + } + + public void installAPK2() { + String path = "file:///sdcard/Download/MyApp.apk"; + Intent intent = new Intent(Intent.ACTION_VIEW); + intent.setType("application/vnd.android.package-archive"); + intent.setData(Uri.parse(path)); + startActivity(intent); + } + + public void installAPK3(String path) { + Intent intent = new Intent(Intent.ACTION_VIEW); + intent.setType(APK_MIMETYPE); + intent.setData(Uri.fromFile(new File(path))); + startActivity(intent); + } +} diff --git a/java/ql/test/query-tests/security/CWE-094/APKInstallation.qlref b/java/ql/test/query-tests/security/CWE-094/APKInstallation.qlref new file mode 100644 index 00000000000..e2a41dbb284 --- /dev/null +++ b/java/ql/test/query-tests/security/CWE-094/APKInstallation.qlref @@ -0,0 +1 @@ +Security/CWE/CWE-094/ArbitraryAPKInstallation.ql \ No newline at end of file diff --git a/java/ql/test/query-tests/security/CWE-094/options b/java/ql/test/query-tests/security/CWE-094/options index 72dc22e6bd3..469e3df8ac0 100644 --- a/java/ql/test/query-tests/security/CWE-094/options +++ b/java/ql/test/query-tests/security/CWE-094/options @@ -1 +1 @@ -//semmle-extractor-options: --javac-args -cp ${testdir}/../../../stubs/validation-api-2.0.1.Final:${testdir}/../../../stubs/springframework-5.3.8:${testdir}/../../../stubs/apache-commons-jexl-2.1.1:${testdir}/../../../stubs/apache-commons-jexl-3.1:${testdir}/../../../stubs/apache-commons-logging-1.2:${testdir}/../../../stubs/mvel2-2.4.7:${testdir}/../../../stubs/groovy-all-3.0.7:${testdir}/../../../stubs/servlet-api-2.4:${testdir}/../../../stubs/scriptengine:${testdir}/../../../stubs/jsr223-api:${testdir}/../../../stubs/apache-freemarker-2.3.31:${testdir}/../../../stubs/jinjava-2.6.0:${testdir}/../../../stubs/pebble-3.1.5:${testdir}/../../../stubs/thymeleaf-3.0.14:${testdir}/../../../stubs/apache-velocity-2.3 +//semmle-extractor-options: --javac-args -cp ${testdir}/../../../stubs/validation-api-2.0.1.Final:${testdir}/../../../stubs/springframework-5.3.8:${testdir}/../../../stubs/apache-commons-jexl-2.1.1:${testdir}/../../../stubs/apache-commons-jexl-3.1:${testdir}/../../../stubs/apache-commons-logging-1.2:${testdir}/../../../stubs/mvel2-2.4.7:${testdir}/../../../stubs/groovy-all-3.0.7:${testdir}/../../../stubs/servlet-api-2.4:${testdir}/../../../stubs/scriptengine:${testdir}/../../../stubs/jsr223-api:${testdir}/../../../stubs/apache-freemarker-2.3.31:${testdir}/../../../stubs/jinjava-2.6.0:${testdir}/../../../stubs/pebble-3.1.5:${testdir}/../../../stubs/thymeleaf-3.0.14:${testdir}/../../../stubs/apache-velocity-2.3:${testdir}/../../..//stubs/google-android-9.0.0 From 3f589722c282ba7537868f752bf9e945dd7a8fa1 Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Tue, 17 Jan 2023 16:12:05 -0500 Subject: [PATCH 039/135] Refactor query to change returned source --- .../CWE/CWE-094/ArbitraryAPKInstallation.ql | 33 +++++++++---------- 1 file changed, 16 insertions(+), 17 deletions(-) diff --git a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql index 6ef44cd0869..c249831b4cf 100644 --- a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql +++ b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql @@ -8,7 +8,7 @@ import java import semmle.code.java.frameworks.android.Intent import semmle.code.java.dataflow.DataFlow -import semmle.code.java.dataflow.TaintTracking +import semmle.code.java.dataflow.TaintTracking2 private import semmle.code.java.dataflow.ExternalFlow class PackageArchiveMimeTypeLiteral extends StringLiteral { @@ -18,57 +18,57 @@ class PackageArchiveMimeTypeLiteral extends StringLiteral { class SetTypeMethod extends Method { SetTypeMethod() { this.hasName(["setType", "setTypeAndNormalize"]) and - this.getDeclaringType().getASupertype*() instanceof TypeIntent + this.getDeclaringType() instanceof TypeIntent } } class SetDataAndTypeMethod extends Method { SetDataAndTypeMethod() { this.hasName(["setDataAndType", "setDataAndTypeAndNormalize"]) and - this.getDeclaringType().getASupertype*() instanceof TypeIntent + this.getDeclaringType() instanceof TypeIntent } } class SetDataMethod extends Method { SetDataMethod() { this.hasName(["setData", "setDataAndNormalize", "setDataAndType", "setDataAndTypeAndNormalize"]) and - this.getDeclaringType().getASupertype*() instanceof TypeIntent + this.getDeclaringType() instanceof TypeIntent } } class SetDataSink extends DataFlow::ExprNode { SetDataSink() { this.getExpr().(MethodAccess).getMethod() instanceof SetDataMethod } - - DataFlow::ExprNode getUri() { result.asExpr() = this.getExpr().(MethodAccess).getArgument(0) } } -class UriParseMethod extends Method { - UriParseMethod() { - this.hasName(["parse", "fromFile"]) and - this.getDeclaringType().hasQualifiedName("android.net", "Uri") +class UriConstructorMethod extends Method { + UriConstructorMethod() { + this.hasQualifiedName("android.net", "Uri", ["parse", "fromFile", "fromParts"]) } } class ExternalSource extends DataFlow::Node { ExternalSource() { sourceNode(this, "android-external-storage-dir") or - this.asExpr().(MethodAccess).getMethod() instanceof UriParseMethod or + this.asExpr().(MethodAccess).getMethod() instanceof UriConstructorMethod or this.asExpr().(StringLiteral).getValue().matches(["file://%", "http://%", "https://%"]) } } -class ExternalSourceConfiguration extends DataFlow2::Configuration { +class ExternalSourceConfiguration extends DataFlow::Configuration { ExternalSourceConfiguration() { this = "ExternalSourceConfiguration" } override predicate isSource(DataFlow::Node node) { node instanceof ExternalSource } override predicate isSink(DataFlow::Node node) { - // any(PackageArchiveMimeTypeConfiguration c).hasFlow(_, node) - node instanceof SetDataSink + exists(MethodAccess ma | + ma.getMethod() instanceof SetDataMethod and + ma.getArgument(0) = node.asExpr() and + any(PackageArchiveMimeTypeConfiguration c).hasFlowToExpr(ma) + ) } } -class PackageArchiveMimeTypeConfiguration extends TaintTracking::Configuration { +private class PackageArchiveMimeTypeConfiguration extends TaintTracking2::Configuration { PackageArchiveMimeTypeConfiguration() { this = "PackageArchiveMimeTypeConfiguration" } override predicate isSource(DataFlow::Node node) { @@ -96,10 +96,9 @@ class PackageArchiveMimeTypeConfiguration extends TaintTracking::Configuration { override predicate isSink(DataFlow::Node node, DataFlow::FlowState state) { state = "typeSet" and node instanceof SetDataSink - // and any(ExternalSourceConfiguration c).hasFlow(_, node.(SetDataSink).getUri()) } } -from DataFlow::PathNode source, DataFlow::PathNode sink, PackageArchiveMimeTypeConfiguration config +from DataFlow::PathNode source, DataFlow::PathNode sink, ExternalSourceConfiguration config where config.hasFlowPath(source, sink) select sink.getNode(), source, sink, "Android APK installation" From 0ec4df28f534c114945e63e4d96022bf5bc6d936 Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Tue, 17 Jan 2023 16:30:55 -0500 Subject: [PATCH 040/135] Add query metadata --- java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql index c249831b4cf..0ca57ee7b64 100644 --- a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql +++ b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql @@ -1,8 +1,13 @@ /** + * @id java/android/arbitrary-apk-installation * @name Android APK installation * @description Installing an APK from an untrusted source. * @kind path-problem + * @security-severity 9.3 + * @problem.severity warning + * @precision medium * @tags security + * external/cwe/cwe-094 */ import java From 2d6cdff14b0abecf9823e8c17c6761c3355a62f8 Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Thu, 19 Jan 2023 16:23:39 -0500 Subject: [PATCH 041/135] Add period to alert message --- java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql index 0ca57ee7b64..17fc2f2c4c6 100644 --- a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql +++ b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql @@ -106,4 +106,4 @@ private class PackageArchiveMimeTypeConfiguration extends TaintTracking2::Config from DataFlow::PathNode source, DataFlow::PathNode sink, ExternalSourceConfiguration config where config.hasFlowPath(source, sink) -select sink.getNode(), source, sink, "Android APK installation" +select sink.getNode(), source, sink, "Arbitrary Android APK installation." From cd5a46123ed189cc4b0400d80c020ea1f1755563 Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Thu, 19 Jan 2023 16:28:44 -0500 Subject: [PATCH 042/135] Add a change note --- .../change-notes/2023-01-19-arbitrary-apk-installation.md | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 java/ql/src/change-notes/2023-01-19-arbitrary-apk-installation.md diff --git a/java/ql/src/change-notes/2023-01-19-arbitrary-apk-installation.md b/java/ql/src/change-notes/2023-01-19-arbitrary-apk-installation.md new file mode 100644 index 00000000000..cfcc85745b8 --- /dev/null +++ b/java/ql/src/change-notes/2023-01-19-arbitrary-apk-installation.md @@ -0,0 +1,5 @@ +--- +category: newQuery +--- +* Added a new query `java/android/arbitrary-apk-installation` to detect installation of APKs from untrusted sources. + From 12f78dbed45b1d53dbc76c3a1c17a495e845be72 Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Thu, 19 Jan 2023 16:33:41 -0500 Subject: [PATCH 043/135] Add `DataFlow::PathGraph` import --- java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql | 1 + 1 file changed, 1 insertion(+) diff --git a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql index 17fc2f2c4c6..8bad85e609a 100644 --- a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql +++ b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql @@ -15,6 +15,7 @@ import semmle.code.java.frameworks.android.Intent import semmle.code.java.dataflow.DataFlow import semmle.code.java.dataflow.TaintTracking2 private import semmle.code.java.dataflow.ExternalFlow +import DataFlow::PathGraph class PackageArchiveMimeTypeLiteral extends StringLiteral { PackageArchiveMimeTypeLiteral() { this.getValue() = "application/vnd.android.package-archive" } From c448481bf7ed2023b69c9c6dc1a3f28b2ae5cd5e Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Thu, 19 Jan 2023 16:37:17 -0500 Subject: [PATCH 044/135] Added test expectations --- .../security/CWE-094/APKInstallation.expected | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 java/ql/test/query-tests/security/CWE-094/APKInstallation.expected diff --git a/java/ql/test/query-tests/security/CWE-094/APKInstallation.expected b/java/ql/test/query-tests/security/CWE-094/APKInstallation.expected new file mode 100644 index 00000000000..ca44b71ecde --- /dev/null +++ b/java/ql/test/query-tests/security/CWE-094/APKInstallation.expected @@ -0,0 +1,12 @@ +edges +nodes +| APKInstallation.java:13:31:13:58 | fromFile(...) | semmle.label | fromFile(...) | +| APKInstallation.java:20:31:20:44 | parse(...) | semmle.label | parse(...) | +| APKInstallation.java:28:24:28:38 | parse(...) | semmle.label | parse(...) | +| APKInstallation.java:35:24:35:51 | fromFile(...) | semmle.label | fromFile(...) | +subpaths +#select +| APKInstallation.java:13:31:13:58 | fromFile(...) | APKInstallation.java:13:31:13:58 | fromFile(...) | APKInstallation.java:13:31:13:58 | fromFile(...) | Arbitrary Android APK installation. | +| APKInstallation.java:20:31:20:44 | parse(...) | APKInstallation.java:20:31:20:44 | parse(...) | APKInstallation.java:20:31:20:44 | parse(...) | Arbitrary Android APK installation. | +| APKInstallation.java:28:24:28:38 | parse(...) | APKInstallation.java:28:24:28:38 | parse(...) | APKInstallation.java:28:24:28:38 | parse(...) | Arbitrary Android APK installation. | +| APKInstallation.java:35:24:35:51 | fromFile(...) | APKInstallation.java:35:24:35:51 | fromFile(...) | APKInstallation.java:35:24:35:51 | fromFile(...) | Arbitrary Android APK installation. | From 01b20b3a26be286a846b500ba4947c3cbb6d5d36 Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Fri, 20 Jan 2023 15:49:18 -0500 Subject: [PATCH 045/135] Added external storage test case --- .../security/CWE-094/APKInstallation.expected | 18 ++++++++++-------- .../security/CWE-094/APKInstallation.java | 8 ++++++++ 2 files changed, 18 insertions(+), 8 deletions(-) diff --git a/java/ql/test/query-tests/security/CWE-094/APKInstallation.expected b/java/ql/test/query-tests/security/CWE-094/APKInstallation.expected index ca44b71ecde..28a43050106 100644 --- a/java/ql/test/query-tests/security/CWE-094/APKInstallation.expected +++ b/java/ql/test/query-tests/security/CWE-094/APKInstallation.expected @@ -1,12 +1,14 @@ edges nodes -| APKInstallation.java:13:31:13:58 | fromFile(...) | semmle.label | fromFile(...) | -| APKInstallation.java:20:31:20:44 | parse(...) | semmle.label | parse(...) | -| APKInstallation.java:28:24:28:38 | parse(...) | semmle.label | parse(...) | -| APKInstallation.java:35:24:35:51 | fromFile(...) | semmle.label | fromFile(...) | +| APKInstallation.java:14:31:14:58 | fromFile(...) | semmle.label | fromFile(...) | +| APKInstallation.java:21:31:21:44 | parse(...) | semmle.label | parse(...) | +| APKInstallation.java:29:24:29:38 | parse(...) | semmle.label | parse(...) | +| APKInstallation.java:36:24:36:51 | fromFile(...) | semmle.label | fromFile(...) | +| APKInstallation.java:43:31:43:48 | fromFile(...) | semmle.label | fromFile(...) | subpaths #select -| APKInstallation.java:13:31:13:58 | fromFile(...) | APKInstallation.java:13:31:13:58 | fromFile(...) | APKInstallation.java:13:31:13:58 | fromFile(...) | Arbitrary Android APK installation. | -| APKInstallation.java:20:31:20:44 | parse(...) | APKInstallation.java:20:31:20:44 | parse(...) | APKInstallation.java:20:31:20:44 | parse(...) | Arbitrary Android APK installation. | -| APKInstallation.java:28:24:28:38 | parse(...) | APKInstallation.java:28:24:28:38 | parse(...) | APKInstallation.java:28:24:28:38 | parse(...) | Arbitrary Android APK installation. | -| APKInstallation.java:35:24:35:51 | fromFile(...) | APKInstallation.java:35:24:35:51 | fromFile(...) | APKInstallation.java:35:24:35:51 | fromFile(...) | Arbitrary Android APK installation. | +| APKInstallation.java:14:31:14:58 | fromFile(...) | APKInstallation.java:14:31:14:58 | fromFile(...) | APKInstallation.java:14:31:14:58 | fromFile(...) | Arbitrary Android APK installation. | +| APKInstallation.java:21:31:21:44 | parse(...) | APKInstallation.java:21:31:21:44 | parse(...) | APKInstallation.java:21:31:21:44 | parse(...) | Arbitrary Android APK installation. | +| APKInstallation.java:29:24:29:38 | parse(...) | APKInstallation.java:29:24:29:38 | parse(...) | APKInstallation.java:29:24:29:38 | parse(...) | Arbitrary Android APK installation. | +| APKInstallation.java:36:24:36:51 | fromFile(...) | APKInstallation.java:36:24:36:51 | fromFile(...) | APKInstallation.java:36:24:36:51 | fromFile(...) | Arbitrary Android APK installation. | +| APKInstallation.java:43:31:43:48 | fromFile(...) | APKInstallation.java:43:31:43:48 | fromFile(...) | APKInstallation.java:43:31:43:48 | fromFile(...) | Arbitrary Android APK installation. | diff --git a/java/ql/test/query-tests/security/CWE-094/APKInstallation.java b/java/ql/test/query-tests/security/CWE-094/APKInstallation.java index 4e16985fd0c..ffce7b1a841 100644 --- a/java/ql/test/query-tests/security/CWE-094/APKInstallation.java +++ b/java/ql/test/query-tests/security/CWE-094/APKInstallation.java @@ -1,6 +1,7 @@ import android.app.Activity; import android.content.Intent; import android.net.Uri; +import android.os.Environment; import java.io.File; @@ -35,4 +36,11 @@ public class APKInstallation extends Activity { intent.setData(Uri.fromFile(new File(path))); startActivity(intent); } + + public void installAPK4(String path) { + File file = new File(Environment.getExternalStorageDirectory(), path); + Intent intent = new Intent(Intent.ACTION_VIEW); + intent.setDataAndType(Uri.fromFile(file), APK_MIMETYPE); + startActivity(intent); + } } From b606271a61566494bb715b38b17649bbe27aa673 Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Fri, 20 Jan 2023 15:49:30 -0500 Subject: [PATCH 046/135] Additional documentation --- .../CWE/CWE-094/ArbitraryAPKInstallation.ql | 33 +++++++++++++++---- 1 file changed, 26 insertions(+), 7 deletions(-) diff --git a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql index 8bad85e609a..fc131846dce 100644 --- a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql +++ b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql @@ -17,10 +17,12 @@ import semmle.code.java.dataflow.TaintTracking2 private import semmle.code.java.dataflow.ExternalFlow import DataFlow::PathGraph +/** A string literal that represents the MIME type for Android APKs. */ class PackageArchiveMimeTypeLiteral extends StringLiteral { PackageArchiveMimeTypeLiteral() { this.getValue() = "application/vnd.android.package-archive" } } +/** A method that sets the MIME type of an intent. */ class SetTypeMethod extends Method { SetTypeMethod() { this.hasName(["setType", "setTypeAndNormalize"]) and @@ -28,6 +30,7 @@ class SetTypeMethod extends Method { } } +/** A method that sets the data URI and the MIME type of an intent. */ class SetDataAndTypeMethod extends Method { SetDataAndTypeMethod() { this.hasName(["setDataAndType", "setDataAndTypeAndNormalize"]) and @@ -35,6 +38,7 @@ class SetDataAndTypeMethod extends Method { } } +/** A method that sets the data URI of an intent. */ class SetDataMethod extends Method { SetDataMethod() { this.hasName(["setData", "setDataAndNormalize", "setDataAndType", "setDataAndTypeAndNormalize"]) and @@ -42,28 +46,39 @@ class SetDataMethod extends Method { } } +/** A dataflow sink for the URI of an intent. */ class SetDataSink extends DataFlow::ExprNode { SetDataSink() { this.getExpr().(MethodAccess).getMethod() instanceof SetDataMethod } } +/** A method that generates a URI. */ class UriConstructorMethod extends Method { UriConstructorMethod() { - this.hasQualifiedName("android.net", "Uri", ["parse", "fromFile", "fromParts"]) + this.hasQualifiedName("android.net", "Uri", ["parse", "fromFile", "fromParts"]) or + this.hasQualifiedName("androidx.core.content", "FileProvider", "getUriForFile") } } -class ExternalSource extends DataFlow::Node { - ExternalSource() { +/** + * A dataflow source representing the URIs which an APK not controlled by the + * application may come from. Incuding external storage and web URLs. + */ +class ExternalAPKSource extends DataFlow::Node { + ExternalAPKSource() { sourceNode(this, "android-external-storage-dir") or this.asExpr().(MethodAccess).getMethod() instanceof UriConstructorMethod or this.asExpr().(StringLiteral).getValue().matches(["file://%", "http://%", "https://%"]) } } -class ExternalSourceConfiguration extends DataFlow::Configuration { - ExternalSourceConfiguration() { this = "ExternalSourceConfiguration" } +/** + * A dataflow configuration for flow from an external source of an APK to the + * `setData[AndType][AndNormalize]` method of an intent. + */ +class APKConfiguration extends DataFlow::Configuration { + APKConfiguration() { this = "APKConfiguration" } - override predicate isSource(DataFlow::Node node) { node instanceof ExternalSource } + override predicate isSource(DataFlow::Node node) { node instanceof ExternalAPKSource } override predicate isSink(DataFlow::Node node) { exists(MethodAccess ma | @@ -74,6 +89,10 @@ class ExternalSourceConfiguration extends DataFlow::Configuration { } } +/** + * A dataflow configuration tracking the flow of the Android APK MIME type to + * the `setType` or `setTypeAndNormalize` method of an intent. + */ private class PackageArchiveMimeTypeConfiguration extends TaintTracking2::Configuration { PackageArchiveMimeTypeConfiguration() { this = "PackageArchiveMimeTypeConfiguration" } @@ -105,6 +124,6 @@ private class PackageArchiveMimeTypeConfiguration extends TaintTracking2::Config } } -from DataFlow::PathNode source, DataFlow::PathNode sink, ExternalSourceConfiguration config +from DataFlow::PathNode source, DataFlow::PathNode sink, APKConfiguration config where config.hasFlowPath(source, sink) select sink.getNode(), source, sink, "Arbitrary Android APK installation." From 839b88a4bc2a16d1efb6a26ba164388d817770e3 Mon Sep 17 00:00:00 2001 From: Edward Minnix III Date: Mon, 23 Jan 2023 10:41:50 -0500 Subject: [PATCH 047/135] Formatting, capitalization, and typos Co-authored-by: Tony Torralba --- .../CWE/CWE-094/ArbitraryAPKInstallation.ql | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql index fc131846dce..e9fa470cc80 100644 --- a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql +++ b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql @@ -61,10 +61,10 @@ class UriConstructorMethod extends Method { /** * A dataflow source representing the URIs which an APK not controlled by the - * application may come from. Incuding external storage and web URLs. + * application may come from. Including external storage and web URLs. */ -class ExternalAPKSource extends DataFlow::Node { - ExternalAPKSource() { +class ExternalApkSource extends DataFlow::Node { + ExternalApkSource() { sourceNode(this, "android-external-storage-dir") or this.asExpr().(MethodAccess).getMethod() instanceof UriConstructorMethod or this.asExpr().(StringLiteral).getValue().matches(["file://%", "http://%", "https://%"]) @@ -75,10 +75,10 @@ class ExternalAPKSource extends DataFlow::Node { * A dataflow configuration for flow from an external source of an APK to the * `setData[AndType][AndNormalize]` method of an intent. */ -class APKConfiguration extends DataFlow::Configuration { - APKConfiguration() { this = "APKConfiguration" } +class ApkConfiguration extends DataFlow::Configuration { + ApkConfiguration() { this = "ApkConfiguration" } - override predicate isSource(DataFlow::Node node) { node instanceof ExternalAPKSource } + override predicate isSource(DataFlow::Node node) { node instanceof ExternalApkSource } override predicate isSink(DataFlow::Node node) { exists(MethodAccess ma | @@ -124,6 +124,6 @@ private class PackageArchiveMimeTypeConfiguration extends TaintTracking2::Config } } -from DataFlow::PathNode source, DataFlow::PathNode sink, APKConfiguration config +from DataFlow::PathNode source, DataFlow::PathNode sink, ApkConfiguration config where config.hasFlowPath(source, sink) select sink.getNode(), source, sink, "Arbitrary Android APK installation." From f03e90f89467f486122a2a8497754cbcc3e5a613 Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Wed, 25 Jan 2023 12:11:26 -0500 Subject: [PATCH 048/135] Remove http(s) literal sources --- java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql index e9fa470cc80..d54079e37e3 100644 --- a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql +++ b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql @@ -67,7 +67,7 @@ class ExternalApkSource extends DataFlow::Node { ExternalApkSource() { sourceNode(this, "android-external-storage-dir") or this.asExpr().(MethodAccess).getMethod() instanceof UriConstructorMethod or - this.asExpr().(StringLiteral).getValue().matches(["file://%", "http://%", "https://%"]) + this.asExpr().(StringLiteral).getValue().matches("file://%") } } From 5f4e8e3e6a5be887a6de74bc20d6b541c2dc8543 Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Tue, 31 Jan 2023 22:30:46 -0500 Subject: [PATCH 049/135] Add test cases relating to intents with the ACTION_INSTALL_PACKAGE action --- .../CWE/CWE-094/ArbitraryAPKInstallation.ql | 53 +++++++++++++++++-- .../security/CWE-094/APKInstallation.expected | 4 ++ .../security/CWE-094/APKInstallation.java | 14 +++++ 3 files changed, 68 insertions(+), 3 deletions(-) diff --git a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql index d54079e37e3..7f7265c5b34 100644 --- a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql +++ b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql @@ -14,6 +14,7 @@ import java import semmle.code.java.frameworks.android.Intent import semmle.code.java.dataflow.DataFlow import semmle.code.java.dataflow.TaintTracking2 +import semmle.code.java.dataflow.TaintTracking3 private import semmle.code.java.dataflow.ExternalFlow import DataFlow::PathGraph @@ -22,6 +23,17 @@ class PackageArchiveMimeTypeLiteral extends StringLiteral { PackageArchiveMimeTypeLiteral() { this.getValue() = "application/vnd.android.package-archive" } } +class InstallPackageAction extends Expr { + InstallPackageAction() { + this.(StringLiteral).getValue() = "android.intent.action.INSTALL_PACKAGE" + or + exists(VarAccess va | + va.getVariable().hasName("ACTION_INSTALL_PACKAGE") and + va.getQualifier().getType() instanceof TypeIntent + ) + } +} + /** A method that sets the MIME type of an intent. */ class SetTypeMethod extends Method { SetTypeMethod() { @@ -48,7 +60,12 @@ class SetDataMethod extends Method { /** A dataflow sink for the URI of an intent. */ class SetDataSink extends DataFlow::ExprNode { - SetDataSink() { this.getExpr().(MethodAccess).getMethod() instanceof SetDataMethod } + SetDataSink() { + exists(MethodAccess ma | + this.getExpr() = ma.getQualifier() and + ma.getMethod() instanceof SetDataMethod + ) + } } /** A method that generates a URI. */ @@ -84,14 +101,44 @@ class ApkConfiguration extends DataFlow::Configuration { exists(MethodAccess ma | ma.getMethod() instanceof SetDataMethod and ma.getArgument(0) = node.asExpr() and - any(PackageArchiveMimeTypeConfiguration c).hasFlowToExpr(ma) + ( + any(PackageArchiveMimeTypeConfiguration c).hasFlowToExpr(ma.getQualifier()) + or + any(InstallPackageActionConfiguration c).hasFlowToExpr(ma.getQualifier()) + ) ) } } +private class InstallPackageActionConfiguration extends TaintTracking3::Configuration { + InstallPackageActionConfiguration() { this = "InstallPackageActionConfiguration" } + + override predicate isSource(DataFlow::Node source) { + source.asExpr() instanceof InstallPackageAction + } + + override predicate isAdditionalTaintStep( + DataFlow::Node node1, DataFlow::FlowState state1, DataFlow::Node node2, + DataFlow::FlowState state2 + ) { + state1 instanceof DataFlow::FlowStateEmpty and + state2 = "hasPackageInstallAction" and + exists(ConstructorCall cc | + cc.getConstructedType() instanceof TypeIntent and + node1.asExpr() = cc.getArgument(0) and + node2.asExpr() = cc + ) + } + + override predicate isSink(DataFlow::Node node, DataFlow::FlowState state) { + state = "hasPackageInstallAction" and node.asExpr().getType() instanceof TypeIntent + } +} + /** * A dataflow configuration tracking the flow of the Android APK MIME type to - * the `setType` or `setTypeAndNormalize` method of an intent. + * the `setType` or `setTypeAndNormalize` method of an intent, followed by a call + * to `setData[AndType][AndNormalize]`. */ private class PackageArchiveMimeTypeConfiguration extends TaintTracking2::Configuration { PackageArchiveMimeTypeConfiguration() { this = "PackageArchiveMimeTypeConfiguration" } diff --git a/java/ql/test/query-tests/security/CWE-094/APKInstallation.expected b/java/ql/test/query-tests/security/CWE-094/APKInstallation.expected index 28a43050106..f13fdadbe23 100644 --- a/java/ql/test/query-tests/security/CWE-094/APKInstallation.expected +++ b/java/ql/test/query-tests/security/CWE-094/APKInstallation.expected @@ -5,6 +5,8 @@ nodes | APKInstallation.java:29:24:29:38 | parse(...) | semmle.label | parse(...) | | APKInstallation.java:36:24:36:51 | fromFile(...) | semmle.label | fromFile(...) | | APKInstallation.java:43:31:43:48 | fromFile(...) | semmle.label | fromFile(...) | +| APKInstallation.java:50:24:50:41 | fromFile(...) | semmle.label | fromFile(...) | +| APKInstallation.java:57:24:57:41 | fromFile(...) | semmle.label | fromFile(...) | subpaths #select | APKInstallation.java:14:31:14:58 | fromFile(...) | APKInstallation.java:14:31:14:58 | fromFile(...) | APKInstallation.java:14:31:14:58 | fromFile(...) | Arbitrary Android APK installation. | @@ -12,3 +14,5 @@ subpaths | APKInstallation.java:29:24:29:38 | parse(...) | APKInstallation.java:29:24:29:38 | parse(...) | APKInstallation.java:29:24:29:38 | parse(...) | Arbitrary Android APK installation. | | APKInstallation.java:36:24:36:51 | fromFile(...) | APKInstallation.java:36:24:36:51 | fromFile(...) | APKInstallation.java:36:24:36:51 | fromFile(...) | Arbitrary Android APK installation. | | APKInstallation.java:43:31:43:48 | fromFile(...) | APKInstallation.java:43:31:43:48 | fromFile(...) | APKInstallation.java:43:31:43:48 | fromFile(...) | Arbitrary Android APK installation. | +| APKInstallation.java:50:24:50:41 | fromFile(...) | APKInstallation.java:50:24:50:41 | fromFile(...) | APKInstallation.java:50:24:50:41 | fromFile(...) | Arbitrary Android APK installation. | +| APKInstallation.java:57:24:57:41 | fromFile(...) | APKInstallation.java:57:24:57:41 | fromFile(...) | APKInstallation.java:57:24:57:41 | fromFile(...) | Arbitrary Android APK installation. | diff --git a/java/ql/test/query-tests/security/CWE-094/APKInstallation.java b/java/ql/test/query-tests/security/CWE-094/APKInstallation.java index ffce7b1a841..b2c5c9bb50d 100644 --- a/java/ql/test/query-tests/security/CWE-094/APKInstallation.java +++ b/java/ql/test/query-tests/security/CWE-094/APKInstallation.java @@ -43,4 +43,18 @@ public class APKInstallation extends Activity { intent.setDataAndType(Uri.fromFile(file), APK_MIMETYPE); startActivity(intent); } + + public void installAPK5(String path) { + File file = new File(Environment.getExternalStorageDirectory(), path); + Intent intent = new Intent(Intent.ACTION_INSTALL_PACKAGE); + intent.setData(Uri.fromFile(file)); + startActivity(intent); + } + + public void installAPK6(String path) { + File file = new File(Environment.getExternalStorageDirectory(), path); + Intent intent = new Intent("android.intent.action.INSTALL_PACKAGE"); + intent.setData(Uri.fromFile(file)); + startActivity(intent); + } } From d3d712fbff186cd62046557771fb5addd2b9a9eb Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Mon, 13 Feb 2023 13:30:21 -0500 Subject: [PATCH 050/135] Remove `Url#parse` as a source --- .../CWE/CWE-094/ArbitraryAPKInstallation.ql | 26 +++++++++++++++---- .../security/CWE-094/APKInstallation.expected | 6 ++--- .../security/CWE-094/APKInstallation.java | 15 +++++++++++ 3 files changed, 38 insertions(+), 9 deletions(-) diff --git a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql index 7f7265c5b34..35eea49cc73 100644 --- a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql +++ b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql @@ -71,7 +71,7 @@ class SetDataSink extends DataFlow::ExprNode { /** A method that generates a URI. */ class UriConstructorMethod extends Method { UriConstructorMethod() { - this.hasQualifiedName("android.net", "Uri", ["parse", "fromFile", "fromParts"]) or + this.hasQualifiedName("android.net", "Uri", [/*"parse",*/ "fromFile", "fromParts"]) or this.hasQualifiedName("androidx.core.content", "FileProvider", "getUriForFile") } } @@ -110,6 +110,13 @@ class ApkConfiguration extends DataFlow::Configuration { } } +class SetActionMethod extends Method { + SetActionMethod() { + this.hasName("setAction") and + this.getDeclaringType() instanceof TypeIntent + } +} + private class InstallPackageActionConfiguration extends TaintTracking3::Configuration { InstallPackageActionConfiguration() { this = "InstallPackageActionConfiguration" } @@ -123,10 +130,19 @@ private class InstallPackageActionConfiguration extends TaintTracking3::Configur ) { state1 instanceof DataFlow::FlowStateEmpty and state2 = "hasPackageInstallAction" and - exists(ConstructorCall cc | - cc.getConstructedType() instanceof TypeIntent and - node1.asExpr() = cc.getArgument(0) and - node2.asExpr() = cc + ( + exists(ConstructorCall cc | + cc.getConstructedType() instanceof TypeIntent and + node1.asExpr() = cc.getArgument(0) and + node1.asExpr().getType() instanceof TypeString and + node2.asExpr() = cc + ) + or + exists(MethodAccess ma | + ma.getMethod() instanceof SetActionMethod and + node1.asExpr() = ma.getArgument(0) and + node2.asExpr() = ma.getQualifier() + ) ) } diff --git a/java/ql/test/query-tests/security/CWE-094/APKInstallation.expected b/java/ql/test/query-tests/security/CWE-094/APKInstallation.expected index f13fdadbe23..df8f65a004d 100644 --- a/java/ql/test/query-tests/security/CWE-094/APKInstallation.expected +++ b/java/ql/test/query-tests/security/CWE-094/APKInstallation.expected @@ -1,18 +1,16 @@ edges nodes | APKInstallation.java:14:31:14:58 | fromFile(...) | semmle.label | fromFile(...) | -| APKInstallation.java:21:31:21:44 | parse(...) | semmle.label | parse(...) | -| APKInstallation.java:29:24:29:38 | parse(...) | semmle.label | parse(...) | | APKInstallation.java:36:24:36:51 | fromFile(...) | semmle.label | fromFile(...) | | APKInstallation.java:43:31:43:48 | fromFile(...) | semmle.label | fromFile(...) | | APKInstallation.java:50:24:50:41 | fromFile(...) | semmle.label | fromFile(...) | | APKInstallation.java:57:24:57:41 | fromFile(...) | semmle.label | fromFile(...) | +| APKInstallation.java:70:24:70:41 | fromFile(...) | semmle.label | fromFile(...) | subpaths #select | APKInstallation.java:14:31:14:58 | fromFile(...) | APKInstallation.java:14:31:14:58 | fromFile(...) | APKInstallation.java:14:31:14:58 | fromFile(...) | Arbitrary Android APK installation. | -| APKInstallation.java:21:31:21:44 | parse(...) | APKInstallation.java:21:31:21:44 | parse(...) | APKInstallation.java:21:31:21:44 | parse(...) | Arbitrary Android APK installation. | -| APKInstallation.java:29:24:29:38 | parse(...) | APKInstallation.java:29:24:29:38 | parse(...) | APKInstallation.java:29:24:29:38 | parse(...) | Arbitrary Android APK installation. | | APKInstallation.java:36:24:36:51 | fromFile(...) | APKInstallation.java:36:24:36:51 | fromFile(...) | APKInstallation.java:36:24:36:51 | fromFile(...) | Arbitrary Android APK installation. | | APKInstallation.java:43:31:43:48 | fromFile(...) | APKInstallation.java:43:31:43:48 | fromFile(...) | APKInstallation.java:43:31:43:48 | fromFile(...) | Arbitrary Android APK installation. | | APKInstallation.java:50:24:50:41 | fromFile(...) | APKInstallation.java:50:24:50:41 | fromFile(...) | APKInstallation.java:50:24:50:41 | fromFile(...) | Arbitrary Android APK installation. | | APKInstallation.java:57:24:57:41 | fromFile(...) | APKInstallation.java:57:24:57:41 | fromFile(...) | APKInstallation.java:57:24:57:41 | fromFile(...) | Arbitrary Android APK installation. | +| APKInstallation.java:70:24:70:41 | fromFile(...) | APKInstallation.java:70:24:70:41 | fromFile(...) | APKInstallation.java:70:24:70:41 | fromFile(...) | Arbitrary Android APK installation. | \ No newline at end of file diff --git a/java/ql/test/query-tests/security/CWE-094/APKInstallation.java b/java/ql/test/query-tests/security/CWE-094/APKInstallation.java index b2c5c9bb50d..11fe4a64bc7 100644 --- a/java/ql/test/query-tests/security/CWE-094/APKInstallation.java +++ b/java/ql/test/query-tests/security/CWE-094/APKInstallation.java @@ -57,4 +57,19 @@ public class APKInstallation extends Activity { intent.setData(Uri.fromFile(file)); startActivity(intent); } + + public void openWebsite() { + Intent intent = new Intent(Intent.ACTION_VIEW); + intent.setData(Uri.parse("http://www.example.com")); + startActivity(intent); + } + + public void otherIntent(File file) { + Intent intent = new Intent(this, OtherActivity.class); + intent.setAction(Intent.ACTION_VIEW); + intent.setData(Uri.fromFile(file)); + } +} + +class OtherActivity extends Activity { } From fa416564c7e072c2e2c8c440ab1a85202f71e2a8 Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Thu, 2 Mar 2023 10:37:44 -0500 Subject: [PATCH 051/135] Documentation and examples --- .../CWE-094/ArbitraryAPKInstallation.qhelp | 73 +++++++++++++++++++ .../CWE/CWE-094/InstallApkWithFile.java | 14 ++++ .../CWE-094/InstallApkWithFileProvider.java | 31 ++++++++ .../InstallApkWithPackageInstaller.java | 32 ++++++++ 4 files changed, 150 insertions(+) create mode 100644 java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.qhelp create mode 100644 java/ql/src/Security/CWE/CWE-094/InstallApkWithFile.java create mode 100644 java/ql/src/Security/CWE/CWE-094/InstallApkWithFileProvider.java create mode 100644 java/ql/src/Security/CWE/CWE-094/InstallApkWithPackageInstaller.java diff --git a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.qhelp b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.qhelp new file mode 100644 index 00000000000..698c09e8465 --- /dev/null +++ b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.qhelp @@ -0,0 +1,73 @@ + + + +

    + Android allows an application to install an APK (Android package kit) + using an Intent with + the "application/vnd.android.package-archive" MIME type. If + the file used in the Intent is from a location that is not + controlled by the application (for example, the SD card which is + universally writable), this can result in the installation of an + application which was not intended. +

    +
    + + +

    + It is advised to transition to install packages using + the PackageInstaller class. +

    + +

    + If installation from a file is necessary, it is best to use + a FileProvider. Content providers can provide more specific + permissions than file system permissions can. +

    + +

    + When your application does not require installing packages, do not add + the REQUEST_INSTALL_PACKAGES permission in the manifest file. +

    +
    + + + +

    + In the following (bad) example, the package is installed from a file which + may be altered by another application. +

    + + + +

    + In the following (good) example, the package is installed by using + a FileProvider. +

    + + + +

    + In the following (good) example, the package is installed using an + instance of the android.content.pm.PackageInstaller class. +

    + + +
    + + +
  • + Intent.ACTION_INSTALL_PACKAGE: . +
  • +
  • + Android Manifest Permission to Install Packages: . +
  • +
  • + PackageInstaller: . +
  • +
  • + FileProvider: . +
  • +
    +
    diff --git a/java/ql/src/Security/CWE/CWE-094/InstallApkWithFile.java b/java/ql/src/Security/CWE/CWE-094/InstallApkWithFile.java new file mode 100644 index 00000000000..39462a43cc9 --- /dev/null +++ b/java/ql/src/Security/CWE/CWE-094/InstallApkWithFile.java @@ -0,0 +1,14 @@ +import android.app.Activity; +import android.content.Intent; +import android.net.Uri; +import android.os.Environment; + +import java.io.File; + +/* Get a file from external storage */ +File file = new File(Environment.getExternalStorageDirectory(), "myapp.apk"); +Intent intent = new Intent(Intent.ACTION_VIEW); +/* Set the mimetype to APK */ +intent.setDataAndType(Uri.fromFile(file), "application/vnd.android.package-archive"); + +startActivity(intent); diff --git a/java/ql/src/Security/CWE/CWE-094/InstallApkWithFileProvider.java b/java/ql/src/Security/CWE/CWE-094/InstallApkWithFileProvider.java new file mode 100644 index 00000000000..d6e537caf7d --- /dev/null +++ b/java/ql/src/Security/CWE/CWE-094/InstallApkWithFileProvider.java @@ -0,0 +1,31 @@ +import android.app.Activity; +import android.content.Context; +import android.content.Intent; +import android.net.Uri; +import androidx.core.content.FileProvider; + +import java.io.File; +import java.io.FileOutputStream; + +String tempFilename = "temporary.apk"; +byte[] buffer = new byte[16384]; + +/* Copy application asset into temporary file */ +try (InputStream is = getAssets().open(assetName); + FileOutputStream fout = openFileOutput(tempFilename, Context.MODE_PRIVATE)) { + int n; + while ((n=is.read(buffer)) >= 0) { + fout.write(buffer, 0, n); + } +} + +/* Expose temporary file with FileProvider */ +File toInstall = new File(this.getFilesDir(), tempFilename); +Uri applicationUri = FileProvider.getUriForFile(this, "com.example.apkprovider", toInstall); + +/* Create Intent and set data to APK file. */ +Intent intent = new Intent(Intent.ACTION_INSTALL_PACKAGE); +intent.setData(applicationUri); +intent.setFlags(Intent.FLAG_GRANT_READ_URI_PERMISSION); + +startActivity(intent); diff --git a/java/ql/src/Security/CWE/CWE-094/InstallApkWithPackageInstaller.java b/java/ql/src/Security/CWE/CWE-094/InstallApkWithPackageInstaller.java new file mode 100644 index 00000000000..fbe8eca3f47 --- /dev/null +++ b/java/ql/src/Security/CWE/CWE-094/InstallApkWithPackageInstaller.java @@ -0,0 +1,32 @@ +import android.content.Context; +import android.content.Intent; +import android.content.pm.PackageInstaller; + +private static final String PACKAGE_INSTALLED_ACTION = + "com.example.SESSION_API_PACKAGE_INSTALLED"; + +/* Create the package installer and session */ +PackageInstaller packageInstaller = getPackageManager().getPackageInstaller(); +PackageInstaller.SessionParams params = + new PackageInstaller.SessionParams(PackageInstaller.SessionParams.MODE_FULL_INSTALL); +int sessionId = packageInstaller.createSession(params); +session = packageInstaller.openSession(sessionId); + +/* Load asset into session */ +try (OutputStream packageInSession = session.openWrite("package", 0, -1); + InputStream is = getAssets().open(assetName)) { + byte[] buffer = new byte[16384]; + int n; + while ((n = is.read(buffer)) >= 0) { + packageInSession.write(buffer, 0, n); + } +} + +/* Create status receiver */ +Intent intent = new Intent(this, InstallApkSessionApi.class); +intent.setAction(PACKAGE_INSTALLED_ACTION); +PendingIntent pendingIntent = PendingIntent.getActivity(context, 0, intent, 0); +IntentSender statusReceiver = pendingIntent.getIntentSender(); + +/* Commit the session */ +session.commit(statusReceiver); From 8fcf00b73d4e47881936baa503a91bdbf5b0a895 Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Thu, 2 Mar 2023 11:00:24 -0500 Subject: [PATCH 052/135] Test improvements --- .../security/CWE-094/APKInstallation.java | 31 +++++-------------- 1 file changed, 7 insertions(+), 24 deletions(-) diff --git a/java/ql/test/query-tests/security/CWE-094/APKInstallation.java b/java/ql/test/query-tests/security/CWE-094/APKInstallation.java index 11fe4a64bc7..57b893fe36f 100644 --- a/java/ql/test/query-tests/security/CWE-094/APKInstallation.java +++ b/java/ql/test/query-tests/security/CWE-094/APKInstallation.java @@ -15,58 +15,41 @@ public class APKInstallation extends Activity { startActivity(intent); } - public void downloadAPK(String url) { - // BAD: the url is not checked - Intent intent = new Intent(Intent.ACTION_VIEW); - intent.setDataAndType(Uri.parse(url), "application/vnd.android.package-archive"); - startActivity(intent); - } - - public void installAPK2() { - String path = "file:///sdcard/Download/MyApp.apk"; - Intent intent = new Intent(Intent.ACTION_VIEW); - intent.setType("application/vnd.android.package-archive"); - intent.setData(Uri.parse(path)); - startActivity(intent); - } - public void installAPK3(String path) { Intent intent = new Intent(Intent.ACTION_VIEW); intent.setType(APK_MIMETYPE); + // BAD: the path is not checked intent.setData(Uri.fromFile(new File(path))); startActivity(intent); } - public void installAPK4(String path) { + public void installAPKFromExternalStorage(String path) { + // BAD: file is from external storage File file = new File(Environment.getExternalStorageDirectory(), path); Intent intent = new Intent(Intent.ACTION_VIEW); intent.setDataAndType(Uri.fromFile(file), APK_MIMETYPE); startActivity(intent); } - public void installAPK5(String path) { + public void installAPKFromExternalStorageWithActionInstallPackage(String path) { + // BAD: file is from external storage File file = new File(Environment.getExternalStorageDirectory(), path); Intent intent = new Intent(Intent.ACTION_INSTALL_PACKAGE); intent.setData(Uri.fromFile(file)); startActivity(intent); } - public void installAPK6(String path) { + public void installAPKInstallPackageLiteral(String path) { File file = new File(Environment.getExternalStorageDirectory(), path); Intent intent = new Intent("android.intent.action.INSTALL_PACKAGE"); intent.setData(Uri.fromFile(file)); startActivity(intent); } - public void openWebsite() { - Intent intent = new Intent(Intent.ACTION_VIEW); - intent.setData(Uri.parse("http://www.example.com")); - startActivity(intent); - } - public void otherIntent(File file) { Intent intent = new Intent(this, OtherActivity.class); intent.setAction(Intent.ACTION_VIEW); + // BAD: the file is from unknown source intent.setData(Uri.fromFile(file)); } } From 8ec5b5b7fab22341d520fc6e55c5849ac5cd1ce0 Mon Sep 17 00:00:00 2001 From: Edward Minnix III Date: Fri, 3 Mar 2023 15:00:22 -0500 Subject: [PATCH 053/135] Apply suggestions from code review Co-authored-by: Jami <57204504+jcogs33@users.noreply.github.com> --- .../Security/CWE/CWE-094/ArbitraryAPKInstallation.qhelp | 8 ++++---- .../src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql | 2 +- .../change-notes/2023-01-19-arbitrary-apk-installation.md | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.qhelp b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.qhelp index 698c09e8465..c9f65115f23 100644 --- a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.qhelp +++ b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.qhelp @@ -58,16 +58,16 @@
  • - Intent.ACTION_INSTALL_PACKAGE: . + Android Developers: Intent.ACTION_INSTALL_PACKAGE.
  • - Android Manifest Permission to Install Packages: . + Android Developers: Manifest.permission.REQUEST_INSTALL_PACKAGES.
  • - PackageInstaller: . + Android Developers: PackageInstaller.
  • - FileProvider: . + Android Developers: FileProvider.
  • diff --git a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql index 35eea49cc73..f6f0de44cb1 100644 --- a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql +++ b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql @@ -71,7 +71,7 @@ class SetDataSink extends DataFlow::ExprNode { /** A method that generates a URI. */ class UriConstructorMethod extends Method { UriConstructorMethod() { - this.hasQualifiedName("android.net", "Uri", [/*"parse",*/ "fromFile", "fromParts"]) or + this.hasQualifiedName("android.net", "Uri", ["fromFile", "fromParts"]) or this.hasQualifiedName("androidx.core.content", "FileProvider", "getUriForFile") } } diff --git a/java/ql/src/change-notes/2023-01-19-arbitrary-apk-installation.md b/java/ql/src/change-notes/2023-01-19-arbitrary-apk-installation.md index cfcc85745b8..93eb13f87d5 100644 --- a/java/ql/src/change-notes/2023-01-19-arbitrary-apk-installation.md +++ b/java/ql/src/change-notes/2023-01-19-arbitrary-apk-installation.md @@ -1,5 +1,5 @@ --- category: newQuery --- -* Added a new query `java/android/arbitrary-apk-installation` to detect installation of APKs from untrusted sources. +* Added a new query, `java/android/arbitrary-apk-installation`, to detect installation of APKs from untrusted sources. From 10cd6328dc68bf7a329db21d3e1107e8b967a048 Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Fri, 3 Mar 2023 15:08:44 -0500 Subject: [PATCH 054/135] Add missing QLDocs --- .../src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql index f6f0de44cb1..d1ac9c43d69 100644 --- a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql +++ b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql @@ -23,6 +23,7 @@ class PackageArchiveMimeTypeLiteral extends StringLiteral { PackageArchiveMimeTypeLiteral() { this.getValue() = "application/vnd.android.package-archive" } } +/** The `android.content.Intent.ACTION_INSTALL_PACKAGE` constant. */ class InstallPackageAction extends Expr { InstallPackageAction() { this.(StringLiteral).getValue() = "android.intent.action.INSTALL_PACKAGE" @@ -110,6 +111,7 @@ class ApkConfiguration extends DataFlow::Configuration { } } +/** The `setAction` method of the `android.content.Intent` class. */ class SetActionMethod extends Method { SetActionMethod() { this.hasName("setAction") and @@ -117,6 +119,12 @@ class SetActionMethod extends Method { } } +/** + * A dataflow configuration tracking the flow from the `android.content.Intent.ACTION_INSTALL_PACKAGE` + * constant to either the constructor of an intent or the `setAction` method of an intent. + * + * This is used to track if an intent is used to install an APK. + */ private class InstallPackageActionConfiguration extends TaintTracking3::Configuration { InstallPackageActionConfiguration() { this = "InstallPackageActionConfiguration" } From 4d51e4fed0f66f1c08e137737734712c64d11b24 Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Fri, 3 Mar 2023 15:14:09 -0500 Subject: [PATCH 055/135] Change description wording --- java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql index d1ac9c43d69..1b0765da8e2 100644 --- a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql +++ b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql @@ -1,7 +1,7 @@ /** * @id java/android/arbitrary-apk-installation * @name Android APK installation - * @description Installing an APK from an untrusted source. + * @description Creating an intent with a URI pointing to a untrusted file can lead to the installation of an untrusted application. * @kind path-problem * @security-severity 9.3 * @problem.severity warning From 0eaad4136e1e80849dac78be8874ad07fcc3d1e7 Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Mon, 6 Mar 2023 10:03:07 -0500 Subject: [PATCH 056/135] Add RemoteFlowSource as a valid source --- java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql index 1b0765da8e2..027776a6082 100644 --- a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql +++ b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql @@ -15,6 +15,7 @@ import semmle.code.java.frameworks.android.Intent import semmle.code.java.dataflow.DataFlow import semmle.code.java.dataflow.TaintTracking2 import semmle.code.java.dataflow.TaintTracking3 +import semmle.code.java.dataflow.FlowSources private import semmle.code.java.dataflow.ExternalFlow import DataFlow::PathGraph @@ -85,7 +86,8 @@ class ExternalApkSource extends DataFlow::Node { ExternalApkSource() { sourceNode(this, "android-external-storage-dir") or this.asExpr().(MethodAccess).getMethod() instanceof UriConstructorMethod or - this.asExpr().(StringLiteral).getValue().matches("file://%") + this.asExpr().(StringLiteral).getValue().matches("file://%") or + this instanceof RemoteFlowSource } } From 2d1088e92318222c385844b2b554a8d3f4f78333 Mon Sep 17 00:00:00 2001 From: Edward Minnix III Date: Tue, 7 Mar 2023 12:38:20 -0500 Subject: [PATCH 057/135] Change severity level to error Co-authored-by: Tony Torralba --- java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql index 027776a6082..03dc08ac5a2 100644 --- a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql +++ b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql @@ -4,7 +4,7 @@ * @description Creating an intent with a URI pointing to a untrusted file can lead to the installation of an untrusted application. * @kind path-problem * @security-severity 9.3 - * @problem.severity warning + * @problem.severity error * @precision medium * @tags security * external/cwe/cwe-094 From 3ea167cadfd34b77cb49066662af5882ebcd5d6a Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Tue, 7 Mar 2023 18:11:25 -0500 Subject: [PATCH 058/135] Split ArbitraryApkInstallation file into 3 files --- .../security/ArbitraryApkInstallation.qll | 87 ++++++++ .../ArbitraryApkInstallationQuery.qll | 103 ++++++++++ .../CWE/CWE-094/ArbitraryAPKInstallation.ql | 185 +----------------- 3 files changed, 191 insertions(+), 184 deletions(-) create mode 100644 java/ql/lib/semmle/code/java/security/ArbitraryApkInstallation.qll create mode 100644 java/ql/lib/semmle/code/java/security/ArbitraryApkInstallationQuery.qll diff --git a/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallation.qll b/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallation.qll new file mode 100644 index 00000000000..09a74b2e536 --- /dev/null +++ b/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallation.qll @@ -0,0 +1,87 @@ +/** Provide classes to reason about Android Intents that can install APKs. */ + +import java +import semmle.code.java.frameworks.android.Intent +import semmle.code.java.dataflow.DataFlow +private import semmle.code.java.dataflow.ExternalFlow +private import semmle.code.java.dataflow.FlowSources + +/** A string literal that represents the MIME type for Android APKs. */ +class PackageArchiveMimeTypeLiteral extends StringLiteral { + PackageArchiveMimeTypeLiteral() { this.getValue() = "application/vnd.android.package-archive" } +} + +/** The `android.content.Intent.ACTION_INSTALL_PACKAGE` constant. */ +class InstallPackageAction extends Expr { + InstallPackageAction() { + this.(StringLiteral).getValue() = "android.intent.action.INSTALL_PACKAGE" + or + exists(VarAccess va | + va.getVariable().hasName("ACTION_INSTALL_PACKAGE") and + va.getQualifier().getType() instanceof TypeIntent + ) + } +} + +/** A method that sets the MIME type of an intent. */ +class SetTypeMethod extends Method { + SetTypeMethod() { + this.hasName(["setType", "setTypeAndNormalize"]) and + this.getDeclaringType() instanceof TypeIntent + } +} + +/** A method that sets the data URI and the MIME type of an intent. */ +class SetDataAndTypeMethod extends Method { + SetDataAndTypeMethod() { + this.hasName(["setDataAndType", "setDataAndTypeAndNormalize"]) and + this.getDeclaringType() instanceof TypeIntent + } +} + +/** A method that sets the data URI of an intent. */ +class SetDataMethod extends Method { + SetDataMethod() { + this.hasName(["setData", "setDataAndNormalize", "setDataAndType", "setDataAndTypeAndNormalize"]) and + this.getDeclaringType() instanceof TypeIntent + } +} + +/** A dataflow sink for the URI of an intent. */ +class SetDataSink extends DataFlow::ExprNode { + SetDataSink() { + exists(MethodAccess ma | + this.getExpr() = ma.getQualifier() and + ma.getMethod() instanceof SetDataMethod + ) + } +} + +/** A method that generates a URI. */ +class UriConstructorMethod extends Method { + UriConstructorMethod() { + this.hasQualifiedName("android.net", "Uri", ["fromFile", "fromParts"]) or + this.hasQualifiedName("androidx.core.content", "FileProvider", "getUriForFile") + } +} + +/** + * A dataflow source representing the URIs which an APK not controlled by the + * application may come from. Including external storage and web URLs. + */ +class ExternalApkSource extends DataFlow::Node { + ExternalApkSource() { + sourceNode(this, "android-external-storage-dir") or + this.asExpr().(MethodAccess).getMethod() instanceof UriConstructorMethod or + this.asExpr().(StringLiteral).getValue().matches("file://%") or + this instanceof RemoteFlowSource + } +} + +/** The `setAction` method of the `android.content.Intent` class. */ +class SetActionMethod extends Method { + SetActionMethod() { + this.hasName("setAction") and + this.getDeclaringType() instanceof TypeIntent + } +} diff --git a/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallationQuery.qll b/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallationQuery.qll new file mode 100644 index 00000000000..bea388deb31 --- /dev/null +++ b/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallationQuery.qll @@ -0,0 +1,103 @@ +import java +import semmle.code.java.dataflow.DataFlow +import semmle.code.java.dataflow.TaintTracking2 +import semmle.code.java.dataflow.TaintTracking3 +private import semmle.code.java.security.ArbitraryApkInstallation + +/** + * A dataflow configuration for flow from an external source of an APK to the + * `setData[AndType][AndNormalize]` method of an intent. + */ +class ApkConfiguration extends DataFlow::Configuration { + ApkConfiguration() { this = "ApkConfiguration" } + + override predicate isSource(DataFlow::Node node) { node instanceof ExternalApkSource } + + override predicate isSink(DataFlow::Node node) { + exists(MethodAccess ma | + ma.getMethod() instanceof SetDataMethod and + ma.getArgument(0) = node.asExpr() and + ( + any(PackageArchiveMimeTypeConfiguration c).hasFlowToExpr(ma.getQualifier()) + or + any(InstallPackageActionConfiguration c).hasFlowToExpr(ma.getQualifier()) + ) + ) + } +} + +/** + * A dataflow configuration tracking the flow from the `android.content.Intent.ACTION_INSTALL_PACKAGE` + * constant to either the constructor of an intent or the `setAction` method of an intent. + * + * This is used to track if an intent is used to install an APK. + */ +private class InstallPackageActionConfiguration extends TaintTracking3::Configuration { + InstallPackageActionConfiguration() { this = "InstallPackageActionConfiguration" } + + override predicate isSource(DataFlow::Node source) { + source.asExpr() instanceof InstallPackageAction + } + + override predicate isAdditionalTaintStep( + DataFlow::Node node1, DataFlow::FlowState state1, DataFlow::Node node2, + DataFlow::FlowState state2 + ) { + state1 instanceof DataFlow::FlowStateEmpty and + state2 = "hasPackageInstallAction" and + ( + exists(ConstructorCall cc | + cc.getConstructedType() instanceof TypeIntent and + node1.asExpr() = cc.getArgument(0) and + node1.asExpr().getType() instanceof TypeString and + node2.asExpr() = cc + ) + or + exists(MethodAccess ma | + ma.getMethod() instanceof SetActionMethod and + node1.asExpr() = ma.getArgument(0) and + node2.asExpr() = ma.getQualifier() + ) + ) + } + + override predicate isSink(DataFlow::Node node, DataFlow::FlowState state) { + state = "hasPackageInstallAction" and node.asExpr().getType() instanceof TypeIntent + } +} + +/** + * A dataflow configuration tracking the flow of the Android APK MIME type to + * the `setType` or `setTypeAndNormalize` method of an intent, followed by a call + * to `setData[AndType][AndNormalize]`. + */ +private class PackageArchiveMimeTypeConfiguration extends TaintTracking2::Configuration { + PackageArchiveMimeTypeConfiguration() { this = "PackageArchiveMimeTypeConfiguration" } + + override predicate isSource(DataFlow::Node node) { + node.asExpr() instanceof PackageArchiveMimeTypeLiteral + } + + override predicate isAdditionalTaintStep( + DataFlow::Node node1, DataFlow::FlowState state1, DataFlow::Node node2, + DataFlow::FlowState state2 + ) { + state1 instanceof DataFlow::FlowStateEmpty and + state2 = "typeSet" and + exists(MethodAccess ma | + ma.getQualifier() = node2.asExpr() and + ( + ma.getMethod() instanceof SetTypeMethod and + ma.getArgument(0) = node1.asExpr() + or + ma.getMethod() instanceof SetDataAndTypeMethod and + ma.getArgument(1) = node1.asExpr() + ) + ) + } + + override predicate isSink(DataFlow::Node node, DataFlow::FlowState state) { + state = "typeSet" and + node instanceof SetDataSink + } +} diff --git a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql index 03dc08ac5a2..88cc5e12244 100644 --- a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql +++ b/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql @@ -11,192 +11,9 @@ */ import java -import semmle.code.java.frameworks.android.Intent -import semmle.code.java.dataflow.DataFlow -import semmle.code.java.dataflow.TaintTracking2 -import semmle.code.java.dataflow.TaintTracking3 -import semmle.code.java.dataflow.FlowSources -private import semmle.code.java.dataflow.ExternalFlow +import semmle.code.java.security.ArbitraryApkInstallationQuery import DataFlow::PathGraph -/** A string literal that represents the MIME type for Android APKs. */ -class PackageArchiveMimeTypeLiteral extends StringLiteral { - PackageArchiveMimeTypeLiteral() { this.getValue() = "application/vnd.android.package-archive" } -} - -/** The `android.content.Intent.ACTION_INSTALL_PACKAGE` constant. */ -class InstallPackageAction extends Expr { - InstallPackageAction() { - this.(StringLiteral).getValue() = "android.intent.action.INSTALL_PACKAGE" - or - exists(VarAccess va | - va.getVariable().hasName("ACTION_INSTALL_PACKAGE") and - va.getQualifier().getType() instanceof TypeIntent - ) - } -} - -/** A method that sets the MIME type of an intent. */ -class SetTypeMethod extends Method { - SetTypeMethod() { - this.hasName(["setType", "setTypeAndNormalize"]) and - this.getDeclaringType() instanceof TypeIntent - } -} - -/** A method that sets the data URI and the MIME type of an intent. */ -class SetDataAndTypeMethod extends Method { - SetDataAndTypeMethod() { - this.hasName(["setDataAndType", "setDataAndTypeAndNormalize"]) and - this.getDeclaringType() instanceof TypeIntent - } -} - -/** A method that sets the data URI of an intent. */ -class SetDataMethod extends Method { - SetDataMethod() { - this.hasName(["setData", "setDataAndNormalize", "setDataAndType", "setDataAndTypeAndNormalize"]) and - this.getDeclaringType() instanceof TypeIntent - } -} - -/** A dataflow sink for the URI of an intent. */ -class SetDataSink extends DataFlow::ExprNode { - SetDataSink() { - exists(MethodAccess ma | - this.getExpr() = ma.getQualifier() and - ma.getMethod() instanceof SetDataMethod - ) - } -} - -/** A method that generates a URI. */ -class UriConstructorMethod extends Method { - UriConstructorMethod() { - this.hasQualifiedName("android.net", "Uri", ["fromFile", "fromParts"]) or - this.hasQualifiedName("androidx.core.content", "FileProvider", "getUriForFile") - } -} - -/** - * A dataflow source representing the URIs which an APK not controlled by the - * application may come from. Including external storage and web URLs. - */ -class ExternalApkSource extends DataFlow::Node { - ExternalApkSource() { - sourceNode(this, "android-external-storage-dir") or - this.asExpr().(MethodAccess).getMethod() instanceof UriConstructorMethod or - this.asExpr().(StringLiteral).getValue().matches("file://%") or - this instanceof RemoteFlowSource - } -} - -/** - * A dataflow configuration for flow from an external source of an APK to the - * `setData[AndType][AndNormalize]` method of an intent. - */ -class ApkConfiguration extends DataFlow::Configuration { - ApkConfiguration() { this = "ApkConfiguration" } - - override predicate isSource(DataFlow::Node node) { node instanceof ExternalApkSource } - - override predicate isSink(DataFlow::Node node) { - exists(MethodAccess ma | - ma.getMethod() instanceof SetDataMethod and - ma.getArgument(0) = node.asExpr() and - ( - any(PackageArchiveMimeTypeConfiguration c).hasFlowToExpr(ma.getQualifier()) - or - any(InstallPackageActionConfiguration c).hasFlowToExpr(ma.getQualifier()) - ) - ) - } -} - -/** The `setAction` method of the `android.content.Intent` class. */ -class SetActionMethod extends Method { - SetActionMethod() { - this.hasName("setAction") and - this.getDeclaringType() instanceof TypeIntent - } -} - -/** - * A dataflow configuration tracking the flow from the `android.content.Intent.ACTION_INSTALL_PACKAGE` - * constant to either the constructor of an intent or the `setAction` method of an intent. - * - * This is used to track if an intent is used to install an APK. - */ -private class InstallPackageActionConfiguration extends TaintTracking3::Configuration { - InstallPackageActionConfiguration() { this = "InstallPackageActionConfiguration" } - - override predicate isSource(DataFlow::Node source) { - source.asExpr() instanceof InstallPackageAction - } - - override predicate isAdditionalTaintStep( - DataFlow::Node node1, DataFlow::FlowState state1, DataFlow::Node node2, - DataFlow::FlowState state2 - ) { - state1 instanceof DataFlow::FlowStateEmpty and - state2 = "hasPackageInstallAction" and - ( - exists(ConstructorCall cc | - cc.getConstructedType() instanceof TypeIntent and - node1.asExpr() = cc.getArgument(0) and - node1.asExpr().getType() instanceof TypeString and - node2.asExpr() = cc - ) - or - exists(MethodAccess ma | - ma.getMethod() instanceof SetActionMethod and - node1.asExpr() = ma.getArgument(0) and - node2.asExpr() = ma.getQualifier() - ) - ) - } - - override predicate isSink(DataFlow::Node node, DataFlow::FlowState state) { - state = "hasPackageInstallAction" and node.asExpr().getType() instanceof TypeIntent - } -} - -/** - * A dataflow configuration tracking the flow of the Android APK MIME type to - * the `setType` or `setTypeAndNormalize` method of an intent, followed by a call - * to `setData[AndType][AndNormalize]`. - */ -private class PackageArchiveMimeTypeConfiguration extends TaintTracking2::Configuration { - PackageArchiveMimeTypeConfiguration() { this = "PackageArchiveMimeTypeConfiguration" } - - override predicate isSource(DataFlow::Node node) { - node.asExpr() instanceof PackageArchiveMimeTypeLiteral - } - - override predicate isAdditionalTaintStep( - DataFlow::Node node1, DataFlow::FlowState state1, DataFlow::Node node2, - DataFlow::FlowState state2 - ) { - state1 instanceof DataFlow::FlowStateEmpty and - state2 = "typeSet" and - exists(MethodAccess ma | - ma.getQualifier() = node2.asExpr() and - ( - ma.getMethod() instanceof SetTypeMethod and - ma.getArgument(0) = node1.asExpr() - or - ma.getMethod() instanceof SetDataAndTypeMethod and - ma.getArgument(1) = node1.asExpr() - ) - ) - } - - override predicate isSink(DataFlow::Node node, DataFlow::FlowState state) { - state = "typeSet" and - node instanceof SetDataSink - } -} - from DataFlow::PathNode source, DataFlow::PathNode sink, ApkConfiguration config where config.hasFlowPath(source, sink) select sink.getNode(), source, sink, "Arbitrary Android APK installation." From 5fb5f1b23be2e82fb9321e873110593d0e75ba8e Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Wed, 8 Mar 2023 12:11:18 -0500 Subject: [PATCH 059/135] Begin InlineExpectationsTest --- .../security/CWE-094/ApkInstallationTest.ql | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 java/ql/test/query-tests/security/CWE-094/ApkInstallationTest.ql diff --git a/java/ql/test/query-tests/security/CWE-094/ApkInstallationTest.ql b/java/ql/test/query-tests/security/CWE-094/ApkInstallationTest.ql new file mode 100644 index 00000000000..19a7434083a --- /dev/null +++ b/java/ql/test/query-tests/security/CWE-094/ApkInstallationTest.ql @@ -0,0 +1,19 @@ +import java +import semmle.code.java.dataflow.DataFlow +import semmle.code.java.security.ArbitraryApkInstallationQuery +import TestUtilities.InlineExpectationsTest + +class HasApkInstallationTest extends InlineExpectationsTest { + HasApkInstallationTest() { this = "HasApkInstallationTest" } + + override string getARelevantTag() { result = "hasApkInstallation" } + + override predicate hasActualResult(Location location, string element, string tag, string value) { + tag = "hasApkInstallation" and + exists(DataFlow::Node sink, ApkConfiguration conf | conf.hasFlowTo(sink) | + sink.getLocation() = location and + element = sink.toString() and + value = "" + ) + } +} From 882e909862f3579bc8b1277eeb6b219906066042 Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Wed, 8 Mar 2023 12:16:46 -0500 Subject: [PATCH 060/135] Renamed ArbitraryAPKInstallation to ArbitraryApkInstallation --- ...itraryAPKInstallation.qhelp => ArbitraryApkInstallation.qhelp} | 0 .../{ArbitraryAPKInstallation.ql => ArbitraryApkInstallation.ql} | 0 2 files changed, 0 insertions(+), 0 deletions(-) rename java/ql/src/Security/CWE/CWE-094/{ArbitraryAPKInstallation.qhelp => ArbitraryApkInstallation.qhelp} (100%) rename java/ql/src/Security/CWE/CWE-094/{ArbitraryAPKInstallation.ql => ArbitraryApkInstallation.ql} (100%) diff --git a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.qhelp b/java/ql/src/Security/CWE/CWE-094/ArbitraryApkInstallation.qhelp similarity index 100% rename from java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.qhelp rename to java/ql/src/Security/CWE/CWE-094/ArbitraryApkInstallation.qhelp diff --git a/java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql b/java/ql/src/Security/CWE/CWE-094/ArbitraryApkInstallation.ql similarity index 100% rename from java/ql/src/Security/CWE/CWE-094/ArbitraryAPKInstallation.ql rename to java/ql/src/Security/CWE/CWE-094/ArbitraryApkInstallation.ql From 24c9a516c97a2aecdfb51b2c87c287fca36d0646 Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Wed, 8 Mar 2023 13:21:09 -0500 Subject: [PATCH 061/135] Add QLdoc to ArbitraryApkInstallationQuery.qll --- .../semmle/code/java/security/ArbitraryApkInstallationQuery.qll | 2 ++ 1 file changed, 2 insertions(+) diff --git a/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallationQuery.qll b/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallationQuery.qll index bea388deb31..7723b19abc9 100644 --- a/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallationQuery.qll +++ b/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallationQuery.qll @@ -1,3 +1,5 @@ +/** Provides dataflow configurations to reason about installation of arbitrary Android APKs. */ + import java import semmle.code.java.dataflow.DataFlow import semmle.code.java.dataflow.TaintTracking2 From bfd430b446c8f92ee80bad6e19f05bba8b00ae0f Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Wed, 8 Mar 2023 13:21:31 -0500 Subject: [PATCH 062/135] Remove qlref tests --- .../security/CWE-094/APKInstallation.expected | 16 ---------------- .../security/CWE-094/APKInstallation.qlref | 1 - 2 files changed, 17 deletions(-) delete mode 100644 java/ql/test/query-tests/security/CWE-094/APKInstallation.expected delete mode 100644 java/ql/test/query-tests/security/CWE-094/APKInstallation.qlref diff --git a/java/ql/test/query-tests/security/CWE-094/APKInstallation.expected b/java/ql/test/query-tests/security/CWE-094/APKInstallation.expected deleted file mode 100644 index df8f65a004d..00000000000 --- a/java/ql/test/query-tests/security/CWE-094/APKInstallation.expected +++ /dev/null @@ -1,16 +0,0 @@ -edges -nodes -| APKInstallation.java:14:31:14:58 | fromFile(...) | semmle.label | fromFile(...) | -| APKInstallation.java:36:24:36:51 | fromFile(...) | semmle.label | fromFile(...) | -| APKInstallation.java:43:31:43:48 | fromFile(...) | semmle.label | fromFile(...) | -| APKInstallation.java:50:24:50:41 | fromFile(...) | semmle.label | fromFile(...) | -| APKInstallation.java:57:24:57:41 | fromFile(...) | semmle.label | fromFile(...) | -| APKInstallation.java:70:24:70:41 | fromFile(...) | semmle.label | fromFile(...) | -subpaths -#select -| APKInstallation.java:14:31:14:58 | fromFile(...) | APKInstallation.java:14:31:14:58 | fromFile(...) | APKInstallation.java:14:31:14:58 | fromFile(...) | Arbitrary Android APK installation. | -| APKInstallation.java:36:24:36:51 | fromFile(...) | APKInstallation.java:36:24:36:51 | fromFile(...) | APKInstallation.java:36:24:36:51 | fromFile(...) | Arbitrary Android APK installation. | -| APKInstallation.java:43:31:43:48 | fromFile(...) | APKInstallation.java:43:31:43:48 | fromFile(...) | APKInstallation.java:43:31:43:48 | fromFile(...) | Arbitrary Android APK installation. | -| APKInstallation.java:50:24:50:41 | fromFile(...) | APKInstallation.java:50:24:50:41 | fromFile(...) | APKInstallation.java:50:24:50:41 | fromFile(...) | Arbitrary Android APK installation. | -| APKInstallation.java:57:24:57:41 | fromFile(...) | APKInstallation.java:57:24:57:41 | fromFile(...) | APKInstallation.java:57:24:57:41 | fromFile(...) | Arbitrary Android APK installation. | -| APKInstallation.java:70:24:70:41 | fromFile(...) | APKInstallation.java:70:24:70:41 | fromFile(...) | APKInstallation.java:70:24:70:41 | fromFile(...) | Arbitrary Android APK installation. | \ No newline at end of file diff --git a/java/ql/test/query-tests/security/CWE-094/APKInstallation.qlref b/java/ql/test/query-tests/security/CWE-094/APKInstallation.qlref deleted file mode 100644 index e2a41dbb284..00000000000 --- a/java/ql/test/query-tests/security/CWE-094/APKInstallation.qlref +++ /dev/null @@ -1 +0,0 @@ -Security/CWE/CWE-094/ArbitraryAPKInstallation.ql \ No newline at end of file From f680a2ecbf66f9764fb40d7eacd9de2b65d33d04 Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Wed, 8 Mar 2023 13:50:02 -0500 Subject: [PATCH 063/135] Update test java file to support InlineExpectationsTest --- .../security/CWE-094/APKInstallation.java | 12 ++++++------ .../security/CWE-094/ApkInstallationTest.expected | 0 2 files changed, 6 insertions(+), 6 deletions(-) create mode 100644 java/ql/test/query-tests/security/CWE-094/ApkInstallationTest.expected diff --git a/java/ql/test/query-tests/security/CWE-094/APKInstallation.java b/java/ql/test/query-tests/security/CWE-094/APKInstallation.java index 57b893fe36f..6094a967fdf 100644 --- a/java/ql/test/query-tests/security/CWE-094/APKInstallation.java +++ b/java/ql/test/query-tests/security/CWE-094/APKInstallation.java @@ -11,7 +11,7 @@ public class APKInstallation extends Activity { public void installAPK(String path) { // BAD: the path is not checked Intent intent = new Intent(Intent.ACTION_VIEW); - intent.setDataAndType(Uri.fromFile(new File(path)), "application/vnd.android.package-archive"); + intent.setDataAndType(Uri.fromFile(new File(path)), "application/vnd.android.package-archive"); // $ hasApkInstallation startActivity(intent); } @@ -19,7 +19,7 @@ public class APKInstallation extends Activity { Intent intent = new Intent(Intent.ACTION_VIEW); intent.setType(APK_MIMETYPE); // BAD: the path is not checked - intent.setData(Uri.fromFile(new File(path))); + intent.setData(Uri.fromFile(new File(path))); // $ hasApkInstallation startActivity(intent); } @@ -27,7 +27,7 @@ public class APKInstallation extends Activity { // BAD: file is from external storage File file = new File(Environment.getExternalStorageDirectory(), path); Intent intent = new Intent(Intent.ACTION_VIEW); - intent.setDataAndType(Uri.fromFile(file), APK_MIMETYPE); + intent.setDataAndType(Uri.fromFile(file), APK_MIMETYPE); // $ hasApkInstallation startActivity(intent); } @@ -35,14 +35,14 @@ public class APKInstallation extends Activity { // BAD: file is from external storage File file = new File(Environment.getExternalStorageDirectory(), path); Intent intent = new Intent(Intent.ACTION_INSTALL_PACKAGE); - intent.setData(Uri.fromFile(file)); + intent.setData(Uri.fromFile(file)); // $ hasApkInstallation startActivity(intent); } public void installAPKInstallPackageLiteral(String path) { File file = new File(Environment.getExternalStorageDirectory(), path); Intent intent = new Intent("android.intent.action.INSTALL_PACKAGE"); - intent.setData(Uri.fromFile(file)); + intent.setData(Uri.fromFile(file)); // $ hasApkInstallation startActivity(intent); } @@ -50,7 +50,7 @@ public class APKInstallation extends Activity { Intent intent = new Intent(this, OtherActivity.class); intent.setAction(Intent.ACTION_VIEW); // BAD: the file is from unknown source - intent.setData(Uri.fromFile(file)); + intent.setData(Uri.fromFile(file)); // $ hasApkInstallation } } diff --git a/java/ql/test/query-tests/security/CWE-094/ApkInstallationTest.expected b/java/ql/test/query-tests/security/CWE-094/ApkInstallationTest.expected new file mode 100644 index 00000000000..e69de29bb2d From eeb9a88c3a9f36cbb9484d172691c69e272978ba Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Wed, 8 Mar 2023 13:56:25 -0500 Subject: [PATCH 064/135] Renamed test file to follow camel casing convention --- .../CWE-094/{APKInstallation.java => ApkInstallation.java} | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) rename java/ql/test/query-tests/security/CWE-094/{APKInstallation.java => ApkInstallation.java} (97%) diff --git a/java/ql/test/query-tests/security/CWE-094/APKInstallation.java b/java/ql/test/query-tests/security/CWE-094/ApkInstallation.java similarity index 97% rename from java/ql/test/query-tests/security/CWE-094/APKInstallation.java rename to java/ql/test/query-tests/security/CWE-094/ApkInstallation.java index 6094a967fdf..680ad633083 100644 --- a/java/ql/test/query-tests/security/CWE-094/APKInstallation.java +++ b/java/ql/test/query-tests/security/CWE-094/ApkInstallation.java @@ -5,7 +5,7 @@ import android.os.Environment; import java.io.File; -public class APKInstallation extends Activity { +public class ApkInstallation extends Activity { static final String APK_MIMETYPE = "application/vnd.android.package-archive"; public void installAPK(String path) { From da43a61506857aaf147a4862bc119051694c3371 Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Wed, 8 Mar 2023 19:19:00 -0500 Subject: [PATCH 065/135] Convert dataflow configuration to using new module-configuration --- .../ArbitraryApkInstallationQuery.qll | 25 +++++++++++++++---- .../CWE/CWE-094/ArbitraryApkInstallation.ql | 4 +-- .../security/CWE-094/ApkInstallationTest.ql | 2 +- 3 files changed, 23 insertions(+), 8 deletions(-) diff --git a/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallationQuery.qll b/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallationQuery.qll index 7723b19abc9..f02801c52d8 100644 --- a/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallationQuery.qll +++ b/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallationQuery.qll @@ -10,12 +10,10 @@ private import semmle.code.java.security.ArbitraryApkInstallation * A dataflow configuration for flow from an external source of an APK to the * `setData[AndType][AndNormalize]` method of an intent. */ -class ApkConfiguration extends DataFlow::Configuration { - ApkConfiguration() { this = "ApkConfiguration" } +private module ApkConf implements DataFlow::ConfigSig { + predicate isSource(DataFlow::Node node) { node instanceof ExternalApkSource } - override predicate isSource(DataFlow::Node node) { node instanceof ExternalApkSource } - - override predicate isSink(DataFlow::Node node) { + predicate isSink(DataFlow::Node node) { exists(MethodAccess ma | ma.getMethod() instanceof SetDataMethod and ma.getArgument(0) = node.asExpr() and @@ -28,6 +26,23 @@ class ApkConfiguration extends DataFlow::Configuration { } } +module ApkConfiguration = DataFlow::Make; + +// class ApkConfiguration extends DataFlow::Configuration { +// ApkConfiguration() { this = "ApkConfiguration" } +// override predicate isSource(DataFlow::Node node) { node instanceof ExternalApkSource } +// override predicate isSink(DataFlow::Node node) { +// exists(MethodAccess ma | +// ma.getMethod() instanceof SetDataMethod and +// ma.getArgument(0) = node.asExpr() and +// ( +// any(PackageArchiveMimeTypeConfiguration c).hasFlowToExpr(ma.getQualifier()) +// or +// any(InstallPackageActionConfiguration c).hasFlowToExpr(ma.getQualifier()) +// ) +// ) +// } +// } /** * A dataflow configuration tracking the flow from the `android.content.Intent.ACTION_INSTALL_PACKAGE` * constant to either the constructor of an intent or the `setAction` method of an intent. diff --git a/java/ql/src/Security/CWE/CWE-094/ArbitraryApkInstallation.ql b/java/ql/src/Security/CWE/CWE-094/ArbitraryApkInstallation.ql index 88cc5e12244..649e64cf0a2 100644 --- a/java/ql/src/Security/CWE/CWE-094/ArbitraryApkInstallation.ql +++ b/java/ql/src/Security/CWE/CWE-094/ArbitraryApkInstallation.ql @@ -14,6 +14,6 @@ import java import semmle.code.java.security.ArbitraryApkInstallationQuery import DataFlow::PathGraph -from DataFlow::PathNode source, DataFlow::PathNode sink, ApkConfiguration config -where config.hasFlowPath(source, sink) +from DataFlow::PathNode source, DataFlow::PathNode sink +where ApkConfiguration::hasFlowPath(source, sink) select sink.getNode(), source, sink, "Arbitrary Android APK installation." diff --git a/java/ql/test/query-tests/security/CWE-094/ApkInstallationTest.ql b/java/ql/test/query-tests/security/CWE-094/ApkInstallationTest.ql index 19a7434083a..8dfe7803c19 100644 --- a/java/ql/test/query-tests/security/CWE-094/ApkInstallationTest.ql +++ b/java/ql/test/query-tests/security/CWE-094/ApkInstallationTest.ql @@ -10,7 +10,7 @@ class HasApkInstallationTest extends InlineExpectationsTest { override predicate hasActualResult(Location location, string element, string tag, string value) { tag = "hasApkInstallation" and - exists(DataFlow::Node sink, ApkConfiguration conf | conf.hasFlowTo(sink) | + exists(DataFlow::Node sink | ApkConfiguration::hasFlowTo(sink) | sink.getLocation() = location and element = sink.toString() and value = "" From ae0b4970aca23ba2b03001df996fe111bb5ed15c Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Wed, 8 Mar 2023 19:21:58 -0500 Subject: [PATCH 066/135] Remove commented out code --- .../security/ArbitraryApkInstallationQuery.qll | 15 --------------- 1 file changed, 15 deletions(-) diff --git a/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallationQuery.qll b/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallationQuery.qll index f02801c52d8..a2ef854f01e 100644 --- a/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallationQuery.qll +++ b/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallationQuery.qll @@ -28,21 +28,6 @@ private module ApkConf implements DataFlow::ConfigSig { module ApkConfiguration = DataFlow::Make; -// class ApkConfiguration extends DataFlow::Configuration { -// ApkConfiguration() { this = "ApkConfiguration" } -// override predicate isSource(DataFlow::Node node) { node instanceof ExternalApkSource } -// override predicate isSink(DataFlow::Node node) { -// exists(MethodAccess ma | -// ma.getMethod() instanceof SetDataMethod and -// ma.getArgument(0) = node.asExpr() and -// ( -// any(PackageArchiveMimeTypeConfiguration c).hasFlowToExpr(ma.getQualifier()) -// or -// any(InstallPackageActionConfiguration c).hasFlowToExpr(ma.getQualifier()) -// ) -// ) -// } -// } /** * A dataflow configuration tracking the flow from the `android.content.Intent.ACTION_INSTALL_PACKAGE` * constant to either the constructor of an intent or the `setAction` method of an intent. From 48ca1d0b721ff4404c19e46e6cbaeebd230df928 Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Wed, 8 Mar 2023 19:51:54 -0500 Subject: [PATCH 067/135] Convert the taint tracking configurations to modules --- .../ArbitraryApkInstallationQuery.qll | 40 ++++++++++++------- 1 file changed, 26 insertions(+), 14 deletions(-) diff --git a/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallationQuery.qll b/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallationQuery.qll index a2ef854f01e..d7efd408656 100644 --- a/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallationQuery.qll +++ b/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallationQuery.qll @@ -2,6 +2,7 @@ import java import semmle.code.java.dataflow.DataFlow +import semmle.code.java.dataflow.TaintTracking import semmle.code.java.dataflow.TaintTracking2 import semmle.code.java.dataflow.TaintTracking3 private import semmle.code.java.security.ArbitraryApkInstallation @@ -18,9 +19,9 @@ private module ApkConf implements DataFlow::ConfigSig { ma.getMethod() instanceof SetDataMethod and ma.getArgument(0) = node.asExpr() and ( - any(PackageArchiveMimeTypeConfiguration c).hasFlowToExpr(ma.getQualifier()) + PackageArchiveMimeTypeConfiguration::hasFlowToExpr(ma.getQualifier()) or - any(InstallPackageActionConfiguration c).hasFlowToExpr(ma.getQualifier()) + InstallPackageActionConfiguration::hasFlowToExpr(ma.getQualifier()) ) ) } @@ -34,14 +35,14 @@ module ApkConfiguration = DataFlow::Make; * * This is used to track if an intent is used to install an APK. */ -private class InstallPackageActionConfiguration extends TaintTracking3::Configuration { - InstallPackageActionConfiguration() { this = "InstallPackageActionConfiguration" } +private module InstallPackageActionConfig implements DataFlow::StateConfigSig { + class FlowState = string; - override predicate isSource(DataFlow::Node source) { - source.asExpr() instanceof InstallPackageAction + predicate isSource(DataFlow::Node source, FlowState state) { + source.asExpr() instanceof InstallPackageAction and state instanceof DataFlow::FlowStateEmpty } - override predicate isAdditionalTaintStep( + predicate isAdditionalFlowStep( DataFlow::Node node1, DataFlow::FlowState state1, DataFlow::Node node2, DataFlow::FlowState state2 ) { @@ -63,24 +64,30 @@ private class InstallPackageActionConfiguration extends TaintTracking3::Configur ) } - override predicate isSink(DataFlow::Node node, DataFlow::FlowState state) { + predicate isSink(DataFlow::Node node, DataFlow::FlowState state) { state = "hasPackageInstallAction" and node.asExpr().getType() instanceof TypeIntent } + + predicate isBarrier(DataFlow::Node node, FlowState state) { none() } } +private module InstallPackageActionConfiguration = + TaintTracking::MakeWithState; + /** * A dataflow configuration tracking the flow of the Android APK MIME type to * the `setType` or `setTypeAndNormalize` method of an intent, followed by a call * to `setData[AndType][AndNormalize]`. */ -private class PackageArchiveMimeTypeConfiguration extends TaintTracking2::Configuration { - PackageArchiveMimeTypeConfiguration() { this = "PackageArchiveMimeTypeConfiguration" } +private module PackageArchiveMimeTypeConfig implements DataFlow::StateConfigSig { + class FlowState = string; - override predicate isSource(DataFlow::Node node) { - node.asExpr() instanceof PackageArchiveMimeTypeLiteral + predicate isSource(DataFlow::Node node, FlowState state) { + node.asExpr() instanceof PackageArchiveMimeTypeLiteral and + state instanceof DataFlow::FlowStateEmpty } - override predicate isAdditionalTaintStep( + predicate isAdditionalFlowStep( DataFlow::Node node1, DataFlow::FlowState state1, DataFlow::Node node2, DataFlow::FlowState state2 ) { @@ -98,8 +105,13 @@ private class PackageArchiveMimeTypeConfiguration extends TaintTracking2::Config ) } - override predicate isSink(DataFlow::Node node, DataFlow::FlowState state) { + predicate isSink(DataFlow::Node node, DataFlow::FlowState state) { state = "typeSet" and node instanceof SetDataSink } + + predicate isBarrier(DataFlow::Node node, FlowState state) { none() } } + +private module PackageArchiveMimeTypeConfiguration = + TaintTracking::MakeWithState; From cb53ff70a62a8a11fdee45878f93bbf4fcf8015d Mon Sep 17 00:00:00 2001 From: Ed Minnix Date: Thu, 9 Mar 2023 10:44:59 -0500 Subject: [PATCH 068/135] Remove unused imports --- .../semmle/code/java/security/ArbitraryApkInstallationQuery.qll | 2 -- 1 file changed, 2 deletions(-) diff --git a/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallationQuery.qll b/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallationQuery.qll index d7efd408656..894417d2493 100644 --- a/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallationQuery.qll +++ b/java/ql/lib/semmle/code/java/security/ArbitraryApkInstallationQuery.qll @@ -3,8 +3,6 @@ import java import semmle.code.java.dataflow.DataFlow import semmle.code.java.dataflow.TaintTracking -import semmle.code.java.dataflow.TaintTracking2 -import semmle.code.java.dataflow.TaintTracking3 private import semmle.code.java.security.ArbitraryApkInstallation /** From e8f1f364c5329b54ea002f36356ada24e705dc44 Mon Sep 17 00:00:00 2001 From: Edward Minnix III Date: Thu, 9 Mar 2023 10:45:55 -0500 Subject: [PATCH 069/135] Refactor to module api for PathNodes Co-authored-by: Tony Torralba --- java/ql/src/Security/CWE/CWE-094/ArbitraryApkInstallation.ql | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/java/ql/src/Security/CWE/CWE-094/ArbitraryApkInstallation.ql b/java/ql/src/Security/CWE/CWE-094/ArbitraryApkInstallation.ql index 649e64cf0a2..ebbe6defd84 100644 --- a/java/ql/src/Security/CWE/CWE-094/ArbitraryApkInstallation.ql +++ b/java/ql/src/Security/CWE/CWE-094/ArbitraryApkInstallation.ql @@ -12,8 +12,8 @@ import java import semmle.code.java.security.ArbitraryApkInstallationQuery -import DataFlow::PathGraph +import ApkConfiguration::PathGraph -from DataFlow::PathNode source, DataFlow::PathNode sink +from ApkConfiguration::PathNode source, ApkConfiguration::PathNode sink where ApkConfiguration::hasFlowPath(source, sink) select sink.getNode(), source, sink, "Arbitrary Android APK installation." From 0c19da926c308cc3bbf332561e1638ecd27a8720 Mon Sep 17 00:00:00 2001 From: Stephan Brandauer Date: Wed, 8 Mar 2023 15:52:01 +0100 Subject: [PATCH 070/135] Update MaD Declarations after Triage --- java/ql/lib/ext/java.io.model.yml | 6 +++++- java/ql/lib/ext/java.lang.model.yml | 12 ++++++++++-- java/ql/lib/ext/java.sql.model.yml | 5 ++--- java/ql/lib/ext/javafx.scene.web.model.yml | 6 ++++++ ...g.apache.commons.compress.archivers.tar.model.yml | 7 +++++++ .../lib/ext/org.apache.http.client.utils.model.yml | 12 ++++++++++++ .../org.codehaus.cargo.container.installer.model.yml | 8 ++++++++ 7 files changed, 50 insertions(+), 6 deletions(-) create mode 100644 java/ql/lib/ext/javafx.scene.web.model.yml create mode 100644 java/ql/lib/ext/org.apache.commons.compress.archivers.tar.model.yml create mode 100644 java/ql/lib/ext/org.apache.http.client.utils.model.yml create mode 100644 java/ql/lib/ext/org.codehaus.cargo.container.installer.model.yml diff --git a/java/ql/lib/ext/java.io.model.yml b/java/ql/lib/ext/java.io.model.yml index a0e7777c3b5..a3ae20a26f6 100644 --- a/java/ql/lib/ext/java.io.model.yml +++ b/java/ql/lib/ext/java.io.model.yml @@ -3,8 +3,13 @@ extensions: pack: codeql/java-all extensible: sinkModel data: + - ["java.io", "File", True, "createTempFile", "(String,String,File)", "", "Argument[2]", "create-file", "ai-generated"] +# suggested label is not supported: - ["java.io", "File", True, "renameTo", "(File)", "", "Argument[0]", "delete-file", "ai-generated"] + - ["java.io", "FileInputStream", True, "FileInputStream", "(File)", "", "Argument[0]", "read-file", "ai-generated"] - ["java.io", "FileOutputStream", False, "FileOutputStream", "", "", "Argument[0]", "create-file", "manual"] - ["java.io", "FileOutputStream", False, "write", "", "", "Argument[0]", "write-file", "manual"] + - ["java.io", "FileReader", True, "FileReader", "(File)", "", "Argument[0]", "read-file", "ai-generated"] + - ["java.io", "FileReader", True, "FileReader", "(String)", "", "Argument[0]", "read-file", "ai-generated"] - ["java.io", "FileWriter", False, "FileWriter", "", "", "Argument[0]", "create-file", "manual"] - ["java.io", "PrintStream", False, "PrintStream", "(File)", "", "Argument[0]", "create-file", "manual"] - ["java.io", "PrintStream", False, "PrintStream", "(File,Charset)", "", "Argument[0]", "create-file", "manual"] @@ -86,7 +91,6 @@ extensions: - ["java.io", "StringReader", False, "StringReader", "", "", "Argument[0]", "Argument[-1]", "taint", "manual"] - ["java.io", "Writer", True, "toString", "", "", "Argument[-1]", "ReturnValue", "taint", "manual"] - ["java.io", "Writer", True, "write", "", "", "Argument[0]", "Argument[-1]", "taint", "manual"] - - addsTo: pack: codeql/java-all extensible: neutralModel diff --git a/java/ql/lib/ext/java.lang.model.yml b/java/ql/lib/ext/java.lang.model.yml index 55a7f7f8990..bffee6ec7b3 100644 --- a/java/ql/lib/ext/java.lang.model.yml +++ b/java/ql/lib/ext/java.lang.model.yml @@ -3,13 +3,23 @@ extensions: pack: codeql/java-all extensible: sinkModel data: + - ["java.lang", "Class", False, "getResource", "(String)", "", "Argument[0]", "read-file", "ai-generated"] + - ["java.lang", "ClassLoader", True, "getSystemResourceAsStream", "(String)", "", "Argument[0]", "read-file", "ai-generated"] - ["java.lang", "Module", True, "getResourceAsStream", "(String)", "", "Argument[0]", "read-file", "ai-generated"] +# suggested label is not supported: - ["java.lang", "ProcessBuilder", False, "directory", "(File)", "", "Argument[0]", "command-injection", "ai-generated"] # suggested label is not supported: - ["java.lang", "ProcessBuilder", True, "ProcessBuilder", "(String[])", "", "Argument[0]", "command-injection", "ai-generated"] +# suggested label is not supported: - ["java.lang", "Runtime", True, "exec", "(String,String[],File)", "", "Argument[2]", "command-injection", "ai-generated"] +# suggested label is not supported: - ["java.lang", "Runtime", True, "exec", "(String)", "", "Argument[0]", "command-injection", "ai-generated"] +# suggested label is not supported: - ["java.lang", "Runtime", True, "exec", "(String[],String[],File)", "", "Argument[0]", "command-injection", "ai-generated"] +# suggested label is not supported: - ["java.lang", "Runtime", True, "exec", "(String[],String[],File)", "", "Argument[2]", "command-injection", "ai-generated"] +# suggested label is not supported: - ["java.lang", "Runtime", True, "exec", "(String[])", "", "Argument[0]", "command-injection", "ai-generated"] - ["java.lang", "String", False, "matches", "(String)", "", "Argument[0]", "regex-use[f-1]", "manual"] - ["java.lang", "String", False, "replaceAll", "(String,String)", "", "Argument[0]", "regex-use[-1]", "manual"] - ["java.lang", "String", False, "replaceFirst", "(String,String)", "", "Argument[0]", "regex-use[-1]", "manual"] - ["java.lang", "String", False, "split", "(String)", "", "Argument[0]", "regex-use[-1]", "manual"] - ["java.lang", "String", False, "split", "(String,int)", "", "Argument[0]", "regex-use[-1]", "manual"] +# suggested label is not supported: - ["java.lang", "System", False, "load", "(String)", "", "Argument[0]", "command-injection", "ai-generated"] # This is actually injecting a library. +# suggested label is not supported: - ["java.lang", "System", False, "loadLibrary", "(String)", "", "Argument[0]", "command-injection", "ai-generated"] # This is actually injecting a library. - ["java.lang", "System$Logger", True, "log", "(Level,Object)", "", "Argument[1]", "logging", "manual"] - ["java.lang", "System$Logger", True, "log", "(Level,ResourceBundle,String,Object[])", "", "Argument[2..3]", "logging", "manual"] - ["java.lang", "System$Logger", True, "log", "(Level,ResourceBundle,String,Throwable)", "", "Argument[2]", "logging", "manual"] @@ -98,7 +108,6 @@ extensions: - ["java.lang", "Throwable", False, "Throwable", "(Throwable)", "", "Argument[0]", "Argument[-1].SyntheticField[java.lang.Throwable.cause]", "value", "manual"] - ["java.lang", "Throwable", True, "getCause", "()", "", "Argument[-1].SyntheticField[java.lang.Throwable.cause]", "ReturnValue", "value", "manual"] - ["java.lang", "Throwable", True, "getMessage", "()", "", "Argument[-1].SyntheticField[java.lang.Throwable.message]", "ReturnValue", "value", "manual"] - - addsTo: pack: codeql/java-all extensible: neutralModel @@ -131,7 +140,6 @@ extensions: - ["java.lang", "System", "nanoTime", "()", "manual"] - ["java.lang", "Thread", "currentThread", "()", "manual"] - ["java.lang", "Thread", "sleep", "(long)", "manual"] - # The below APIs have numeric flow and are currently being stored as neutral models. # These may be changed to summary models with kinds "value-numeric" and "taint-numeric" (or similar) in the future. - ["java.lang", "Integer", "intValue", "()", "manual"] # taint-numeric diff --git a/java/ql/lib/ext/java.sql.model.yml b/java/ql/lib/ext/java.sql.model.yml index bf544fdb8e7..0bc57cb2f75 100644 --- a/java/ql/lib/ext/java.sql.model.yml +++ b/java/ql/lib/ext/java.sql.model.yml @@ -5,6 +5,8 @@ extensions: data: - ["java.sql", "Connection", True, "prepareCall", "", "", "Argument[0]", "sql", "manual"] - ["java.sql", "Connection", True, "prepareStatement", "", "", "Argument[0]", "sql", "manual"] + - ["java.sql", "DatabaseMetaData", True, "getColumns", "(String,String,String,String)", "", "Argument[2]", "sql", "ai-generated"] + - ["java.sql", "DatabaseMetaData", True, "getPrimaryKeys", "(String,String,String)", "", "Argument[2]", "sql", "ai-generated"] - ["java.sql", "Driver", False, "connect", "(String,Properties)", "", "Argument[0]", "jdbc-url", "manual"] - ["java.sql", "DriverManager", False, "getConnection", "(String)", "", "Argument[0]", "jdbc-url", "manual"] - ["java.sql", "DriverManager", False, "getConnection", "(String,Properties)", "", "Argument[0]", "jdbc-url", "manual"] @@ -14,20 +16,17 @@ extensions: - ["java.sql", "Statement", True, "executeLargeUpdate", "", "", "Argument[0]", "sql", "manual"] - ["java.sql", "Statement", True, "executeQuery", "", "", "Argument[0]", "sql", "manual"] - ["java.sql", "Statement", True, "executeUpdate", "", "", "Argument[0]", "sql", "manual"] - - addsTo: pack: codeql/java-all extensible: summaryModel data: - ["java.sql", "PreparedStatement", True, "setString", "(int,String)", "", "Argument[1]", "Argument[-1]", "value", "manual"] - ["java.sql", "ResultSet", True, "getString", "(String)", "", "Argument[-1]", "ReturnValue", "taint", "manual"] - - addsTo: pack: codeql/java-all extensible: neutralModel data: - ["java.sql", "ResultSet", "next", "()", "manual"] - # The below APIs have numeric flow and are currently being stored as neutral models. # These may be changed to summary models with kinds "value-numeric" and "taint-numeric" (or similar) in the future. - ["java.sql", "PreparedStatement", "setInt", "(int,int)", "manual"] # value-numeric diff --git a/java/ql/lib/ext/javafx.scene.web.model.yml b/java/ql/lib/ext/javafx.scene.web.model.yml new file mode 100644 index 00000000000..c31725e1d03 --- /dev/null +++ b/java/ql/lib/ext/javafx.scene.web.model.yml @@ -0,0 +1,6 @@ +extensions: + - addsTo: + pack: codeql/java-all + extensible: sinkModel + data: + - ["javafx.scene.web", "WebEngine", False, "load", "(String)", "", "Argument[0]", "open-url", "ai-generated"] diff --git a/java/ql/lib/ext/org.apache.commons.compress.archivers.tar.model.yml b/java/ql/lib/ext/org.apache.commons.compress.archivers.tar.model.yml new file mode 100644 index 00000000000..37a7a3431b4 --- /dev/null +++ b/java/ql/lib/ext/org.apache.commons.compress.archivers.tar.model.yml @@ -0,0 +1,7 @@ +extensions: + - addsTo: + pack: codeql/java-all + extensible: summaryModel + data: + - ["org.apache.commons.compress.archivers.tar", "TarArchiveEntry", True, "TarArchiveEntry", "(String,boolean)", "", "Argument[0]", "Argument[-1]", "taint", "ai-generated"] + - ["org.apache.commons.compress.archivers.tar", "TarArchiveEntry", True, "TarArchiveEntry", "(String)", "", "Argument[0]", "Argument[-1]", "taint", "ai-generated"] diff --git a/java/ql/lib/ext/org.apache.http.client.utils.model.yml b/java/ql/lib/ext/org.apache.http.client.utils.model.yml new file mode 100644 index 00000000000..e184ff0cdc8 --- /dev/null +++ b/java/ql/lib/ext/org.apache.http.client.utils.model.yml @@ -0,0 +1,12 @@ +extensions: + - addsTo: + pack: codeql/java-all + extensible: summaryModel + data: + - ["org.apache.http.client.utils", "URIBuilder", True, "setHost", "(String)", "", "Argument[0]", "Argument[-1]", "taint", "ai-generated"] + - ["org.apache.http.client.utils", "URIBuilder", True, "setHost", "(String)", "", "Argument[0]", "ReturnValue", "taint", "ai-generated"] + - ["org.apache.http.client.utils", "URIBuilder", True, "setPath", "(String)", "", "Argument[0]", "Argument[-1].SyntheticField[org.apache.http.client.utils.URIBuilder.path]", "taint", "ai-generated"] + - ["org.apache.http.client.utils", "URIBuilder", True, "setPathSegments", "(List)", "", "Argument[0]", "Argument[-1].SyntheticField[org.apache.http.client.utils.URIBuilder.path]", "taint", "ai-generated"] + - ["org.apache.http.client.utils", "URIBuilder", True, "URIBuilder", "(String)", "", "Argument[0]", "Argument[-1]", "taint", "ai-generated"] + - ["org.apache.http.client.utils", "URIBuilder", True, "URIBuilder", "(URI)", "", "Argument[0]", "Argument[-1]", "taint", "ai-generated"] + - ["org.apache.http.client.utils", "URLEncodedUtils", True, "parse", "(URI,String)", "", "Argument[0]", "ReturnValue.Element", "taint", "ai-generated"] diff --git a/java/ql/lib/ext/org.codehaus.cargo.container.installer.model.yml b/java/ql/lib/ext/org.codehaus.cargo.container.installer.model.yml new file mode 100644 index 00000000000..9c0c9db9172 --- /dev/null +++ b/java/ql/lib/ext/org.codehaus.cargo.container.installer.model.yml @@ -0,0 +1,8 @@ +extensions: + - addsTo: + pack: codeql/java-all + extensible: sinkModel + data: + - ["org.codehaus.cargo.container.installer", "ZipURLInstaller", True, "ZipURLInstaller", "(URL,String,String)", "", "Argument[0]", "open-url", "ai-generated"] + - ["org.codehaus.cargo.container.installer", "ZipURLInstaller", True, "ZipURLInstaller", "(URL,String,String)", "", "Argument[1]", "create-file", "ai-generated"] + - ["org.codehaus.cargo.container.installer", "ZipURLInstaller", True, "ZipURLInstaller", "(URL,String,String)", "", "Argument[2]", "create-file", "ai-generated"] From 77d9bac52d66428f39a52e60512f1a4de1a600ed Mon Sep 17 00:00:00 2001 From: Tony Torralba Date: Thu, 9 Mar 2023 18:42:22 +0100 Subject: [PATCH 071/135] Support ai-generated summaries --- .../lib/semmle/code/java/dataflow/internal/FlowSummaryImpl.qll | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/java/ql/lib/semmle/code/java/dataflow/internal/FlowSummaryImpl.qll b/java/ql/lib/semmle/code/java/dataflow/internal/FlowSummaryImpl.qll index 468ed73e81a..b2c7c557467 100644 --- a/java/ql/lib/semmle/code/java/dataflow/internal/FlowSummaryImpl.qll +++ b/java/ql/lib/semmle/code/java/dataflow/internal/FlowSummaryImpl.qll @@ -1012,7 +1012,7 @@ module Private { private predicate relevantSummaryElementGenerated( AccessPath inSpec, AccessPath outSpec, string kind ) { - summaryElement(this, inSpec, outSpec, kind, "generated") and + summaryElement(this, inSpec, outSpec, kind, ["generated", "ai-generated"]) and not summaryElement(this, _, _, _, "manual") } From 698dfa46fc165b2679d8b145f6489607c23149bc Mon Sep 17 00:00:00 2001 From: Tony Torralba Date: Thu, 9 Mar 2023 18:42:41 +0100 Subject: [PATCH 072/135] Minor fixes to the models --- java/ql/lib/ext/java.io.model.yml | 2 +- java/ql/lib/ext/java.lang.model.yml | 20 +++++++++++--------- 2 files changed, 12 insertions(+), 10 deletions(-) diff --git a/java/ql/lib/ext/java.io.model.yml b/java/ql/lib/ext/java.io.model.yml index a3ae20a26f6..225a0e680ab 100644 --- a/java/ql/lib/ext/java.io.model.yml +++ b/java/ql/lib/ext/java.io.model.yml @@ -4,7 +4,7 @@ extensions: extensible: sinkModel data: - ["java.io", "File", True, "createTempFile", "(String,String,File)", "", "Argument[2]", "create-file", "ai-generated"] -# suggested label is not supported: - ["java.io", "File", True, "renameTo", "(File)", "", "Argument[0]", "delete-file", "ai-generated"] + - ["java.io", "File", True, "renameTo", "(File)", "", "Argument[0]", "create-file", "ai-generated"] - ["java.io", "FileInputStream", True, "FileInputStream", "(File)", "", "Argument[0]", "read-file", "ai-generated"] - ["java.io", "FileOutputStream", False, "FileOutputStream", "", "", "Argument[0]", "create-file", "manual"] - ["java.io", "FileOutputStream", False, "write", "", "", "Argument[0]", "write-file", "manual"] diff --git a/java/ql/lib/ext/java.lang.model.yml b/java/ql/lib/ext/java.lang.model.yml index bffee6ec7b3..94fe112301c 100644 --- a/java/ql/lib/ext/java.lang.model.yml +++ b/java/ql/lib/ext/java.lang.model.yml @@ -6,20 +6,22 @@ extensions: - ["java.lang", "Class", False, "getResource", "(String)", "", "Argument[0]", "read-file", "ai-generated"] - ["java.lang", "ClassLoader", True, "getSystemResourceAsStream", "(String)", "", "Argument[0]", "read-file", "ai-generated"] - ["java.lang", "Module", True, "getResourceAsStream", "(String)", "", "Argument[0]", "read-file", "ai-generated"] -# suggested label is not supported: - ["java.lang", "ProcessBuilder", False, "directory", "(File)", "", "Argument[0]", "command-injection", "ai-generated"] -# suggested label is not supported: - ["java.lang", "ProcessBuilder", True, "ProcessBuilder", "(String[])", "", "Argument[0]", "command-injection", "ai-generated"] -# suggested label is not supported: - ["java.lang", "Runtime", True, "exec", "(String,String[],File)", "", "Argument[2]", "command-injection", "ai-generated"] -# suggested label is not supported: - ["java.lang", "Runtime", True, "exec", "(String)", "", "Argument[0]", "command-injection", "ai-generated"] -# suggested label is not supported: - ["java.lang", "Runtime", True, "exec", "(String[],String[],File)", "", "Argument[0]", "command-injection", "ai-generated"] -# suggested label is not supported: - ["java.lang", "Runtime", True, "exec", "(String[],String[],File)", "", "Argument[2]", "command-injection", "ai-generated"] -# suggested label is not supported: - ["java.lang", "Runtime", True, "exec", "(String[])", "", "Argument[0]", "command-injection", "ai-generated"] + # These are modeled in plain CodeQL. TODO: migrate them. + # - ["java.lang", "ProcessBuilder", False, "directory", "(File)", "", "Argument[0]", "command-injection", "ai-generated"] + # - ["java.lang", "ProcessBuilder", True, "ProcessBuilder", "(String[])", "", "Argument[0]", "command-injection", "ai-generated"] + # - ["java.lang", "Runtime", True, "exec", "(String,String[],File)", "", "Argument[2]", "command-injection", "ai-generated"] + # - ["java.lang", "Runtime", True, "exec", "(String)", "", "Argument[0]", "command-injection", "ai-generated"] + # - ["java.lang", "Runtime", True, "exec", "(String[],String[],File)", "", "Argument[0]", "command-injection", "ai-generated"] + # - ["java.lang", "Runtime", True, "exec", "(String[],String[],File)", "", "Argument[2]", "command-injection", "ai-generated"] + # - ["java.lang", "Runtime", True, "exec", "(String[])", "", "Argument[0]", "command-injection", "ai-generated"] - ["java.lang", "String", False, "matches", "(String)", "", "Argument[0]", "regex-use[f-1]", "manual"] - ["java.lang", "String", False, "replaceAll", "(String,String)", "", "Argument[0]", "regex-use[-1]", "manual"] - ["java.lang", "String", False, "replaceFirst", "(String,String)", "", "Argument[0]", "regex-use[-1]", "manual"] - ["java.lang", "String", False, "split", "(String)", "", "Argument[0]", "regex-use[-1]", "manual"] - ["java.lang", "String", False, "split", "(String,int)", "", "Argument[0]", "regex-use[-1]", "manual"] -# suggested label is not supported: - ["java.lang", "System", False, "load", "(String)", "", "Argument[0]", "command-injection", "ai-generated"] # This is actually injecting a library. -# suggested label is not supported: - ["java.lang", "System", False, "loadLibrary", "(String)", "", "Argument[0]", "command-injection", "ai-generated"] # This is actually injecting a library. + # These are modeled in plain CodeQL. TODO: migrate them. + # - ["java.lang", "System", False, "load", "(String)", "", "Argument[0]", "command-injection", "ai-generated"] # This is actually injecting a library. + # - ["java.lang", "System", False, "loadLibrary", "(String)", "", "Argument[0]", "command-injection", "ai-generated"] # This is actually injecting a library. - ["java.lang", "System$Logger", True, "log", "(Level,Object)", "", "Argument[1]", "logging", "manual"] - ["java.lang", "System$Logger", True, "log", "(Level,ResourceBundle,String,Object[])", "", "Argument[2..3]", "logging", "manual"] - ["java.lang", "System$Logger", True, "log", "(Level,ResourceBundle,String,Throwable)", "", "Argument[2]", "logging", "manual"] From eef3dc81df650507d24a47aa19b28d073a002280 Mon Sep 17 00:00:00 2001 From: Tony Torralba Date: Thu, 9 Mar 2023 18:42:50 +0100 Subject: [PATCH 073/135] Add stubs --- .../compress/archivers/ArchiveEntry.java | 14 ++ .../archivers/tar/TarArchiveEntry.java | 92 +++++++++ .../compress/archivers/tar/TarConstants.java | 70 +++++++ .../compress/archivers/zip/ZipEncoding.java | 12 ++ .../org/apache/http/Header.java | 54 +---- .../org/apache/http/HeaderElement.java | 66 +----- .../org/apache/http/HttpEntity.java | 192 ++---------------- .../org/apache/http/NameValuePair.java | 120 +---------- .../apache/http/client/utils/URIBuilder.java | 51 +++++ .../http/client/utils/URLEncodedUtils.java | 34 ++++ .../org/apache/http/util/ByteArrayBuffer.java | 109 ++-------- .../org/apache/http/util/CharArrayBuffer.java | 151 +++----------- 12 files changed, 355 insertions(+), 610 deletions(-) create mode 100644 java/ql/test/stubs/apache-commons-compress/org/apache/commons/compress/archivers/ArchiveEntry.java create mode 100644 java/ql/test/stubs/apache-commons-compress/org/apache/commons/compress/archivers/tar/TarArchiveEntry.java create mode 100644 java/ql/test/stubs/apache-commons-compress/org/apache/commons/compress/archivers/tar/TarConstants.java create mode 100644 java/ql/test/stubs/apache-commons-compress/org/apache/commons/compress/archivers/zip/ZipEncoding.java create mode 100644 java/ql/test/stubs/apache-http-4.4.13/org/apache/http/client/utils/URIBuilder.java create mode 100644 java/ql/test/stubs/apache-http-4.4.13/org/apache/http/client/utils/URLEncodedUtils.java diff --git a/java/ql/test/stubs/apache-commons-compress/org/apache/commons/compress/archivers/ArchiveEntry.java b/java/ql/test/stubs/apache-commons-compress/org/apache/commons/compress/archivers/ArchiveEntry.java new file mode 100644 index 00000000000..73fb5d3fa1b --- /dev/null +++ b/java/ql/test/stubs/apache-commons-compress/org/apache/commons/compress/archivers/ArchiveEntry.java @@ -0,0 +1,14 @@ +// Generated automatically from org.apache.commons.compress.archivers.ArchiveEntry for testing purposes + +package org.apache.commons.compress.archivers; + +import java.util.Date; + +public interface ArchiveEntry +{ + Date getLastModifiedDate(); + String getName(); + boolean isDirectory(); + long getSize(); + static long SIZE_UNKNOWN = 0; +} diff --git a/java/ql/test/stubs/apache-commons-compress/org/apache/commons/compress/archivers/tar/TarArchiveEntry.java b/java/ql/test/stubs/apache-commons-compress/org/apache/commons/compress/archivers/tar/TarArchiveEntry.java new file mode 100644 index 00000000000..ef17fdf904b --- /dev/null +++ b/java/ql/test/stubs/apache-commons-compress/org/apache/commons/compress/archivers/tar/TarArchiveEntry.java @@ -0,0 +1,92 @@ +// Generated automatically from org.apache.commons.compress.archivers.tar.TarArchiveEntry for testing purposes + +package org.apache.commons.compress.archivers.tar; + +import java.io.File; +import java.util.Date; +import java.util.Map; +import org.apache.commons.compress.archivers.ArchiveEntry; +import org.apache.commons.compress.archivers.tar.TarConstants; +import org.apache.commons.compress.archivers.zip.ZipEncoding; + +public class TarArchiveEntry implements ArchiveEntry, TarConstants +{ + protected TarArchiveEntry() {} + public Date getLastModifiedDate(){ return null; } + public Date getModTime(){ return null; } + public File getFile(){ return null; } + public Map getExtraPaxHeaders(){ return null; } + public String getExtraPaxHeader(String p0){ return null; } + public String getGroupName(){ return null; } + public String getLinkName(){ return null; } + public String getName(){ return null; } + public String getUserName(){ return null; } + public TarArchiveEntry(File p0){} + public TarArchiveEntry(File p0, String p1){} + public TarArchiveEntry(String p0){} + public TarArchiveEntry(String p0, boolean p1){} + public TarArchiveEntry(String p0, byte p1){} + public TarArchiveEntry(String p0, byte p1, boolean p2){} + public TarArchiveEntry(byte[] p0){} + public TarArchiveEntry(byte[] p0, ZipEncoding p1){} + public TarArchiveEntry(byte[] p0, ZipEncoding p1, boolean p2){} + public TarArchiveEntry[] getDirectoryEntries(){ return null; } + public boolean equals(Object p0){ return false; } + public boolean equals(TarArchiveEntry p0){ return false; } + public boolean isBlockDevice(){ return false; } + public boolean isCharacterDevice(){ return false; } + public boolean isCheckSumOK(){ return false; } + public boolean isDescendent(TarArchiveEntry p0){ return false; } + public boolean isDirectory(){ return false; } + public boolean isExtended(){ return false; } + public boolean isFIFO(){ return false; } + public boolean isFile(){ return false; } + public boolean isGNULongLinkEntry(){ return false; } + public boolean isGNULongNameEntry(){ return false; } + public boolean isGNUSparse(){ return false; } + public boolean isGlobalPaxHeader(){ return false; } + public boolean isLink(){ return false; } + public boolean isOldGNUSparse(){ return false; } + public boolean isPaxGNUSparse(){ return false; } + public boolean isPaxHeader(){ return false; } + public boolean isSparse(){ return false; } + public boolean isStarSparse(){ return false; } + public boolean isSymbolicLink(){ return false; } + public int getDevMajor(){ return 0; } + public int getDevMinor(){ return 0; } + public int getGroupId(){ return 0; } + public int getMode(){ return 0; } + public int getUserId(){ return 0; } + public int hashCode(){ return 0; } + public long getLongGroupId(){ return 0; } + public long getLongUserId(){ return 0; } + public long getRealSize(){ return 0; } + public long getSize(){ return 0; } + public static int DEFAULT_DIR_MODE = 0; + public static int DEFAULT_FILE_MODE = 0; + public static int MAX_NAMELEN = 0; + public static int MILLIS_PER_SECOND = 0; + public static long UNKNOWN = 0; + public void addPaxHeader(String p0, String p1){} + public void clearExtraPaxHeaders(){} + public void parseTarHeader(byte[] p0){} + public void parseTarHeader(byte[] p0, ZipEncoding p1){} + public void setDevMajor(int p0){} + public void setDevMinor(int p0){} + public void setGroupId(int p0){} + public void setGroupId(long p0){} + public void setGroupName(String p0){} + public void setIds(int p0, int p1){} + public void setLinkName(String p0){} + public void setModTime(Date p0){} + public void setModTime(long p0){} + public void setMode(int p0){} + public void setName(String p0){} + public void setNames(String p0, String p1){} + public void setSize(long p0){} + public void setUserId(int p0){} + public void setUserId(long p0){} + public void setUserName(String p0){} + public void writeEntryHeader(byte[] p0){} + public void writeEntryHeader(byte[] p0, ZipEncoding p1, boolean p2){} +} diff --git a/java/ql/test/stubs/apache-commons-compress/org/apache/commons/compress/archivers/tar/TarConstants.java b/java/ql/test/stubs/apache-commons-compress/org/apache/commons/compress/archivers/tar/TarConstants.java new file mode 100644 index 00000000000..8fd72f07a54 --- /dev/null +++ b/java/ql/test/stubs/apache-commons-compress/org/apache/commons/compress/archivers/tar/TarConstants.java @@ -0,0 +1,70 @@ +// Generated automatically from org.apache.commons.compress.archivers.tar.TarConstants for testing purposes + +package org.apache.commons.compress.archivers.tar; + + +public interface TarConstants +{ + static String GNU_LONGLINK = null; + static String MAGIC_ANT = null; + static String MAGIC_GNU = null; + static String MAGIC_POSIX = null; + static String MAGIC_XSTAR = null; + static String VERSION_ANT = null; + static String VERSION_GNU_SPACE = null; + static String VERSION_GNU_ZERO = null; + static String VERSION_POSIX = null; + static byte LF_BLK = 0; + static byte LF_CHR = 0; + static byte LF_CONTIG = 0; + static byte LF_DIR = 0; + static byte LF_FIFO = 0; + static byte LF_GNUTYPE_LONGLINK = 0; + static byte LF_GNUTYPE_LONGNAME = 0; + static byte LF_GNUTYPE_SPARSE = 0; + static byte LF_LINK = 0; + static byte LF_NORMAL = 0; + static byte LF_OLDNORM = 0; + static byte LF_PAX_EXTENDED_HEADER_LC = 0; + static byte LF_PAX_EXTENDED_HEADER_UC = 0; + static byte LF_PAX_GLOBAL_EXTENDED_HEADER = 0; + static byte LF_SYMLINK = 0; + static int ATIMELEN_GNU = 0; + static int ATIMELEN_XSTAR = 0; + static int CHKSUMLEN = 0; + static int CHKSUM_OFFSET = 0; + static int CTIMELEN_GNU = 0; + static int CTIMELEN_XSTAR = 0; + static int DEFAULT_BLKSIZE = 0; + static int DEFAULT_RCDSIZE = 0; + static int DEVLEN = 0; + static int FORMAT_OLDGNU = 0; + static int FORMAT_POSIX = 0; + static int FORMAT_XSTAR = 0; + static int GIDLEN = 0; + static int GNAMELEN = 0; + static int ISEXTENDEDLEN_GNU = 0; + static int ISEXTENDEDLEN_GNU_SPARSE = 0; + static int LONGNAMESLEN_GNU = 0; + static int MAGICLEN = 0; + static int MAGIC_OFFSET = 0; + static int MODELEN = 0; + static int MODTIMELEN = 0; + static int NAMELEN = 0; + static int OFFSETLEN_GNU = 0; + static int PAD2LEN_GNU = 0; + static int PREFIXLEN = 0; + static int PREFIXLEN_XSTAR = 0; + static int REALSIZELEN_GNU = 0; + static int SIZELEN = 0; + static int SPARSELEN_GNU = 0; + static int SPARSELEN_GNU_SPARSE = 0; + static int UIDLEN = 0; + static int UNAMELEN = 0; + static int VERSIONLEN = 0; + static int VERSION_OFFSET = 0; + static int XSTAR_MAGIC_LEN = 0; + static int XSTAR_MAGIC_OFFSET = 0; + static long MAXID = 0; + static long MAXSIZE = 0; +} diff --git a/java/ql/test/stubs/apache-commons-compress/org/apache/commons/compress/archivers/zip/ZipEncoding.java b/java/ql/test/stubs/apache-commons-compress/org/apache/commons/compress/archivers/zip/ZipEncoding.java new file mode 100644 index 00000000000..246fcc8e75d --- /dev/null +++ b/java/ql/test/stubs/apache-commons-compress/org/apache/commons/compress/archivers/zip/ZipEncoding.java @@ -0,0 +1,12 @@ +// Generated automatically from org.apache.commons.compress.archivers.zip.ZipEncoding for testing purposes + +package org.apache.commons.compress.archivers.zip; + +import java.nio.ByteBuffer; + +public interface ZipEncoding +{ + ByteBuffer encode(String p0); + String decode(byte[] p0); + boolean canEncode(String p0); +} diff --git a/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/Header.java b/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/Header.java index 6e4886fc85c..7674e4c8b3e 100644 --- a/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/Header.java +++ b/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/Header.java @@ -1,53 +1,11 @@ -/* - * ==================================================================== - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - * - */ +// Generated automatically from org.apache.http.Header for testing purposes package org.apache.http; -/** - * Represents an HTTP header field. - * - *

    The HTTP header fields follow the same generic format as - * that given in Section 3.1 of RFC 822. Each header field consists - * of a name followed by a colon (":") and the field value. Field names - * are case-insensitive. The field value MAY be preceded by any amount - * of LWS, though a single SP is preferred. - * - *

    - *     message-header = field-name ":" [ field-value ]
    - *     field-name     = token
    - *     field-value    = *( field-content | LWS )
    - *     field-content  = <the OCTETs making up the field-value
    - *                      and consisting of either *TEXT or combinations
    - *                      of token, separators, and quoted-string>
    - *
    - * - * @since 4.0 - */ -public interface Header extends NameValuePair { - HeaderElement[] getElements() throws ParseException; +import org.apache.http.HeaderElement; +import org.apache.http.NameValuePair; +public interface Header extends NameValuePair +{ + HeaderElement[] getElements(); } diff --git a/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/HeaderElement.java b/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/HeaderElement.java index 9fef05a049a..6c362a9e216 100644 --- a/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/HeaderElement.java +++ b/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/HeaderElement.java @@ -1,65 +1,15 @@ -/* - * $HeadURL: http://svn.apache.org/repos/asf/httpcomponents/httpcore/trunk/module-main/src/main/java/org/apache/http/HeaderElement.java $ - * $Revision: 569828 $ - * $Date: 2007-08-26 08:49:38 -0700 (Sun, 26 Aug 2007) $ - * - * ==================================================================== - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - * - */ +// Generated automatically from org.apache.http.HeaderElement for testing purposes package org.apache.http; -/** - * One element of an HTTP {@link Header header} value. - * - * @author Oleg Kalnichevski - * - * - * - * @version $Revision: 569828 $ $Date: 2007-08-26 08:49:38 -0700 (Sun, 26 Aug - * 2007) $ - * - * @since 4.0 - * - * @deprecated Please use {@link java.net.URL#openConnection} instead. Please - * visit this - * webpage for further details. - */ -@Deprecated -public interface HeaderElement { - - String getName(); - - String getValue(); +import org.apache.http.NameValuePair; +public interface HeaderElement +{ + NameValuePair getParameter(int p0); + NameValuePair getParameterByName(String p0); NameValuePair[] getParameters(); - - NameValuePair getParameterByName(String name); - + String getName(); + String getValue(); int getParameterCount(); - - NameValuePair getParameter(int index); } diff --git a/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/HttpEntity.java b/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/HttpEntity.java index 2de524318b2..8dd6a607624 100644 --- a/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/HttpEntity.java +++ b/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/HttpEntity.java @@ -1,186 +1,20 @@ -/* - * $HeadURL: http://svn.apache.org/repos/asf/httpcomponents/httpcore/trunk/module-main/src/main/java/org/apache/http/HttpEntity.java $ - * $Revision: 645824 $ - * $Date: 2008-04-08 03:12:41 -0700 (Tue, 08 Apr 2008) $ - * - * ==================================================================== - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - * - */ +// Generated automatically from org.apache.http.HttpEntity for testing purposes package org.apache.http; -import java.io.IOException; import java.io.InputStream; import java.io.OutputStream; +import org.apache.http.Header; -/** - * An entity that can be sent or received with an HTTP message. Entities can be - * found in some {@link HttpEntityEnclosingRequest requests} and in - * {@link HttpResponse responses}, where they are optional. - *

    - * In some places, the JavaDoc distinguishes three kinds of entities, depending - * on where their {@link #getContent content} originates: - *

      - *
    • streamed: The content is received from a stream, or generated on - * the fly. In particular, this category includes entities being received from a - * {@link HttpConnection connection}. {@link #isStreaming Streamed} entities are - * generally not {@link #isRepeatable repeatable}.
    • - *
    • self-contained: The content is in memory or obtained by means that - * are independent from a connection or other entity. Self-contained entities - * are generally {@link #isRepeatable repeatable}.
    • - *
    • wrapping: The content is obtained from another entity.
    • - *
    - * This distinction is important for connection management with incoming - * entities. For entities that are created by an application and only sent using - * the HTTP components framework, the difference between streamed and - * self-contained is of little importance. In that case, it is suggested to - * consider non-repeatable entities as streamed, and those that are repeatable - * (without a huge effort) as self-contained. - * - * @author Oleg Kalnichevski - * - * @version $Revision: 645824 $ - * - * @since 4.0 - * - * @deprecated Please use {@link java.net.URL#openConnection} instead. Please - * visit this - * webpage for further details. - */ -@Deprecated -public interface HttpEntity { - - /** - * Tells if the entity is capable to produce its data more than once. A - * repeatable entity's getContent() and writeTo(OutputStream) methods can be - * called more than once whereas a non-repeatable entity's can not. - * - * @return true if the entity is repeatable, false otherwise. - */ - boolean isRepeatable(); - - /** - * Tells about chunked encoding for this entity. The primary purpose of this - * method is to indicate whether chunked encoding should be used when the entity - * is sent. For entities that are received, it can also indicate whether the - * entity was received with chunked encoding.
    - * The behavior of wrapping entities is implementation dependent, but should - * respect the primary purpose. - * - * @return true if chunked encoding is preferred for this entity, - * or false if it is not - */ - boolean isChunked(); - - /** - * Tells the length of the content, if known. - * - * @return the number of bytes of the content, or a negative number if unknown. - * If the content length is known but exceeds - * {@link java.lang.Long#MAX_VALUE Long.MAX_VALUE}, a negative number is - * returned. - */ - long getContentLength(); - - /** - * Obtains the Content-Type header, if known. This is the header that should be - * used when sending the entity, or the one that was received with the entity. - * It can include a charset attribute. - * - * @return the Content-Type header for this entity, or null if the - * content type is unknown - */ - Header getContentType(); - - /** - * Obtains the Content-Encoding header, if known. This is the header that should - * be used when sending the entity, or the one that was received with the - * entity. Wrapping entities that modify the content encoding should adjust this - * header accordingly. - * - * @return the Content-Encoding header for this entity, or null if - * the content encoding is unknown - */ +public interface HttpEntity +{ Header getContentEncoding(); - - /** - * Creates a new InputStream object of the entity. It is a programming error to - * return the same InputStream object more than once. Entities that are not - * {@link #isRepeatable repeatable} will throw an exception if this method is - * called multiple times. - * - * @return a new input stream that returns the entity data. - * - * @throws IOException if the stream could not be created - * @throws IllegalStateException if this entity is not repeatable and the stream - * has already been obtained previously - */ - InputStream getContent() throws IOException, IllegalStateException; - - /** - * Writes the entity content to the output stream. - * - * @param outstream the output stream to write entity content to - * - * @throws IOException if an I/O error occurs - */ - void writeTo(OutputStream outstream) throws IOException; - - /** - * Tells whether this entity depends on an underlying stream. Streamed entities - * should return true until the content has been consumed, - * false afterwards. Self-contained entities should return - * false. Wrapping entities should delegate this call to the - * wrapped entity.
    - * The content of a streamed entity is consumed when the stream returned by - * {@link #getContent getContent} has been read to EOF, or after - * {@link #consumeContent consumeContent} has been called. If a streamed entity - * can not detect whether the stream has been read to EOF, it should return - * true until {@link #consumeContent consumeContent} is called. - * - * @return true if the entity content is streamed and not yet - * consumed, false otherwise - */ - boolean isStreaming(); // don't expect an exception here - - /** - * TODO: The name of this method is misnomer. It will be renamed to #finish() in - * the next major release.
    - * This method is called to indicate that the content of this entity is no - * longer required. All entity implementations are expected to release all - * allocated resources as a result of this method invocation. Content streaming - * entities are also expected to dispose of the remaining content, if any. - * Wrapping entities should delegate this call to the wrapped entity.
    - * This method is of particular importance for entities being received from a - * {@link HttpConnection connection}. The entity needs to be consumed completely - * in order to re-use the connection with keep-alive. - * - * @throws IOException if an I/O error occurs. This indicates that connection - * keep-alive is not possible. - */ - void consumeContent() throws IOException; - -} // interface HttpEntity + Header getContentType(); + InputStream getContent(); + boolean isChunked(); + boolean isRepeatable(); + boolean isStreaming(); + long getContentLength(); + void consumeContent(); + void writeTo(OutputStream p0); +} diff --git a/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/NameValuePair.java b/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/NameValuePair.java index 4ed98cac597..2219b56c811 100644 --- a/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/NameValuePair.java +++ b/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/NameValuePair.java @@ -1,124 +1,10 @@ -/* - * $HeadURL: http://svn.apache.org/repos/asf/httpcomponents/httpcore/trunk/module-main/src/main/java/org/apache/http/NameValuePair.java $ - * $Revision: 496070 $ - * $Date: 2007-01-14 04:18:34 -0800 (Sun, 14 Jan 2007) $ - * - * ==================================================================== - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - * - */ +// Generated automatically from org.apache.http.NameValuePair for testing purposes package org.apache.http; -/** - * A simple class encapsulating an attribute/value pair. - *

    - * This class comforms to the generic grammar and formatting rules outlined in - * the Section - * 2.2 and Section - * 3.6 of RFC - * 2616 - *

    - * 2.2 Basic Rules - *

    - * The following rules are used throughout this specification to describe basic - * parsing constructs. The US-ASCII coded character set is defined by ANSI - * X3.4-1986. - *

    - * - *
    - *     OCTET          = 
    - *     CHAR           = 
    - *     UPALPHA        = 
    - *     LOALPHA        = 
    - *     ALPHA          = UPALPHA | LOALPHA
    - *     DIGIT          = 
    - *     CTL            = 
    - *     CR             = 
    - *     LF             = 
    - *     SP             = 
    - *     HT             = 
    - *     <">            = 
    - * 
    - *

    - * Many HTTP/1.1 header field values consist of words separated by LWS or - * special characters. These special characters MUST be in a quoted string to be - * used within a parameter value (as defined in section 3.6). - *

    - * - *

    - * token          = 1*
    - * separators     = "(" | ")" | "<" | ">" | "@"
    - *                | "," | ";" | ":" | "\" | <">
    - *                | "/" | "[" | "]" | "?" | "="
    - *                | "{" | "}" | SP | HT
    - * 
    - *

    - * A string of text is parsed as a single word if it is quoted using - * double-quote marks. - *

    - * - *
    - * quoted-string  = ( <"> *(qdtext | quoted-pair ) <"> )
    - * qdtext         = >
    - * 
    - *

    - * The backslash character ("\") MAY be used as a single-character quoting - * mechanism only within quoted-string and comment constructs. - *

    - * - *
    - * quoted-pair    = "\" CHAR
    - * 
    - * - * 3.6 Transfer Codings - *

    - * Parameters are in the form of attribute/value pairs. - *

    - * - *
    - * parameter               = attribute "=" value
    - * attribute               = token
    - * value                   = token | quoted-string
    - * 
    - * - * @author Oleg Kalnichevski - * - * - * @deprecated Please use {@link java.net.URL#openConnection} instead. Please - * visit this - * webpage for further details. - */ -@Deprecated -public interface NameValuePair { +public interface NameValuePair +{ String getName(); - String getValue(); - } diff --git a/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/client/utils/URIBuilder.java b/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/client/utils/URIBuilder.java new file mode 100644 index 00000000000..e81eead0e88 --- /dev/null +++ b/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/client/utils/URIBuilder.java @@ -0,0 +1,51 @@ +// Generated automatically from org.apache.http.client.utils.URIBuilder for testing purposes + +package org.apache.http.client.utils; + +import java.net.URI; +import java.nio.charset.Charset; +import java.util.List; +import org.apache.http.NameValuePair; + +public class URIBuilder +{ + public Charset getCharset(){ return null; } + public List getQueryParams(){ return null; } + public List getPathSegments(){ return null; } + public String getFragment(){ return null; } + public String getHost(){ return null; } + public String getPath(){ return null; } + public String getScheme(){ return null; } + public String getUserInfo(){ return null; } + public String toString(){ return null; } + public URI build(){ return null; } + public URIBuilder addParameter(String p0, String p1){ return null; } + public URIBuilder addParameters(List p0){ return null; } + public URIBuilder clearParameters(){ return null; } + public URIBuilder removeQuery(){ return null; } + public URIBuilder setCharset(Charset p0){ return null; } + public URIBuilder setCustomQuery(String p0){ return null; } + public URIBuilder setFragment(String p0){ return null; } + public URIBuilder setHost(String p0){ return null; } + public URIBuilder setParameter(String p0, String p1){ return null; } + public URIBuilder setParameters(List p0){ return null; } + public URIBuilder setParameters(NameValuePair... p0){ return null; } + public URIBuilder setPath(String p0){ return null; } + public URIBuilder setPathSegments(List p0){ return null; } + public URIBuilder setPathSegments(String... p0){ return null; } + public URIBuilder setPort(int p0){ return null; } + public URIBuilder setQuery(String p0){ return null; } + public URIBuilder setScheme(String p0){ return null; } + public URIBuilder setUserInfo(String p0){ return null; } + public URIBuilder setUserInfo(String p0, String p1){ return null; } + public URIBuilder(){} + public URIBuilder(String p0){} + public URIBuilder(String p0, Charset p1){} + public URIBuilder(URI p0){} + public URIBuilder(URI p0, Charset p1){} + public boolean isAbsolute(){ return false; } + public boolean isOpaque(){ return false; } + public boolean isPathEmpty(){ return false; } + public boolean isQueryEmpty(){ return false; } + public int getPort(){ return 0; } +} diff --git a/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/client/utils/URLEncodedUtils.java b/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/client/utils/URLEncodedUtils.java new file mode 100644 index 00000000000..3dd3278311e --- /dev/null +++ b/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/client/utils/URLEncodedUtils.java @@ -0,0 +1,34 @@ +// Generated automatically from org.apache.http.client.utils.URLEncodedUtils for testing purposes + +package org.apache.http.client.utils; + +import java.net.URI; +import java.nio.charset.Charset; +import java.util.List; +import java.util.Scanner; +import org.apache.http.HttpEntity; +import org.apache.http.NameValuePair; +import org.apache.http.util.CharArrayBuffer; + +public class URLEncodedUtils +{ + public URLEncodedUtils(){} + public static List parse(CharArrayBuffer p0, Charset p1, char... p2){ return null; } + public static List parse(HttpEntity p0){ return null; } + public static List parse(String p0, Charset p1){ return null; } + public static List parse(String p0, Charset p1, char... p2){ return null; } + public static List parse(URI p0, Charset p1){ return null; } + public static List parse(URI p0, String p1){ return null; } + public static List parsePathSegments(CharSequence p0){ return null; } + public static List parsePathSegments(CharSequence p0, Charset p1){ return null; } + public static String CONTENT_TYPE = null; + public static String format(Iterable p0, Charset p1){ return null; } + public static String format(Iterable p0, char p1, Charset p2){ return null; } + public static String format(List p0, String p1){ return null; } + public static String format(List p0, char p1, String p2){ return null; } + public static String formatSegments(Iterable p0, Charset p1){ return null; } + public static String formatSegments(String... p0){ return null; } + public static boolean isEncoded(HttpEntity p0){ return false; } + public static void parse(List p0, Scanner p1, String p2){} + public static void parse(List p0, Scanner p1, String p2, String p3){} +} diff --git a/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/util/ByteArrayBuffer.java b/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/util/ByteArrayBuffer.java index 9bc34144de1..7fc54ea0a67 100644 --- a/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/util/ByteArrayBuffer.java +++ b/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/util/ByteArrayBuffer.java @@ -1,93 +1,28 @@ -/* - * ==================================================================== - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - * - */ +// Generated automatically from org.apache.http.util.ByteArrayBuffer for testing purposes package org.apache.http.util; import java.io.Serializable; +import org.apache.http.util.CharArrayBuffer; -public final class ByteArrayBuffer implements Serializable { - public ByteArrayBuffer(final int capacity) { - } - - public void append(final byte[] b, final int off, final int len) { - } - - public void append(final int b) { - } - - public void append(final char[] b, final int off, final int len) { - } - - public void append(final CharArrayBuffer b, final int off, final int len) { - } - - public void clear() { - } - - public byte[] toByteArray() { - return null; - } - - public int byteAt(final int i) { - return 0; - } - - public int capacity() { - return 0; - } - - public int length() { - return 0; - } - - public void ensureCapacity(final int required) { - } - - public byte[] buffer() { - return null; - } - - public void setLength(final int len) { - } - - public boolean isEmpty() { - return false; - } - - public boolean isFull() { - return false; - } - - public int indexOf(final byte b, final int from, final int to) { - return 0; - } - - public int indexOf(final byte b) { - return 0; - } - +public class ByteArrayBuffer implements Serializable +{ + protected ByteArrayBuffer() {} + public ByteArrayBuffer(int p0){} + public boolean isEmpty(){ return false; } + public boolean isFull(){ return false; } + public byte[] buffer(){ return null; } + public byte[] toByteArray(){ return null; } + public int byteAt(int p0){ return 0; } + public int capacity(){ return 0; } + public int indexOf(byte p0){ return 0; } + public int indexOf(byte p0, int p1, int p2){ return 0; } + public int length(){ return 0; } + public void append(CharArrayBuffer p0, int p1, int p2){} + public void append(byte[] p0, int p1, int p2){} + public void append(char[] p0, int p1, int p2){} + public void append(int p0){} + public void clear(){} + public void ensureCapacity(int p0){} + public void setLength(int p0){} } diff --git a/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/util/CharArrayBuffer.java b/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/util/CharArrayBuffer.java index 465962e362e..07c43f35ca1 100644 --- a/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/util/CharArrayBuffer.java +++ b/java/ql/test/stubs/apache-http-4.4.13/org/apache/http/util/CharArrayBuffer.java @@ -1,127 +1,36 @@ -/* - * ==================================================================== - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - * - */ +// Generated automatically from org.apache.http.util.CharArrayBuffer for testing purposes package org.apache.http.util; import java.io.Serializable; -import java.nio.CharBuffer; - - -public final class CharArrayBuffer implements CharSequence, Serializable { - public CharArrayBuffer(final int capacity) { - } - - public void append(final char[] b, final int off, final int len) { - } - - public void append(final String str) { - } - - public void append(final CharArrayBuffer b, final int off, final int len) { - } - - public void append(final CharArrayBuffer b) { - } - - public void append(final char ch) { - } - - public void append(final byte[] b, final int off, final int len) { - } - - public void append(final ByteArrayBuffer b, final int off, final int len) { - } - - public void append(final Object obj) { - } - - public void clear() { - } - - public char[] toCharArray() { - return null; - } - - @Override - public char charAt(final int i) { - return 0; - } - - public char[] buffer() { - return null; - } - - public int capacity() { - return 0; - } - - @Override - public int length() { - return 0; - } - - public void ensureCapacity(final int required) { - } - - public void setLength(final int len) { - } - - public boolean isEmpty() { - return false; - } - - public boolean isFull() { - return false; - } - - public int indexOf(final int ch, final int from, final int to) { - return 0; - } - - public int indexOf(final int ch) { - return 0; - } - - public String substring(final int beginIndex, final int endIndex) { - return null; - } - - public String substringTrimmed(final int beginIndex, final int endIndex) { - return null; - } - - @Override - public CharSequence subSequence(final int beginIndex, final int endIndex) { - return null; - } - - @Override - public String toString() { - return null; - } +import org.apache.http.util.ByteArrayBuffer; +public class CharArrayBuffer implements CharSequence, Serializable +{ + protected CharArrayBuffer() {} + public CharArrayBuffer(int p0){} + public CharSequence subSequence(int p0, int p1){ return null; } + public String substring(int p0, int p1){ return null; } + public String substringTrimmed(int p0, int p1){ return null; } + public String toString(){ return null; } + public boolean isEmpty(){ return false; } + public boolean isFull(){ return false; } + public char charAt(int p0){ return '0'; } + public char[] buffer(){ return null; } + public char[] toCharArray(){ return null; } + public int capacity(){ return 0; } + public int indexOf(int p0){ return 0; } + public int indexOf(int p0, int p1, int p2){ return 0; } + public int length(){ return 0; } + public void append(ByteArrayBuffer p0, int p1, int p2){} + public void append(CharArrayBuffer p0){} + public void append(CharArrayBuffer p0, int p1, int p2){} + public void append(Object p0){} + public void append(String p0){} + public void append(byte[] p0, int p1, int p2){} + public void append(char p0){} + public void append(char[] p0, int p1, int p2){} + public void clear(){} + public void ensureCapacity(int p0){} + public void setLength(int p0){} } From 8065714ebe1d352619786ef9c13748bebdf075c3 Mon Sep 17 00:00:00 2001 From: Tony Torralba Date: Thu, 9 Mar 2023 18:43:09 +0100 Subject: [PATCH 074/135] Add tests --- .../apache-commons-compress/Test.java | 32 +++++++++ .../apache-commons-compress/options | 1 + .../apache-commons-compress/test.expected | 0 .../apache-commons-compress/test.ql | 2 + .../frameworks/apache-http/client/Test.java | 71 +++++++++++++++++++ .../frameworks/apache-http/client/options | 1 + .../apache-http/client/test.expected | 0 .../apache-http/client/test.ext.yml | 6 ++ .../frameworks/apache-http/client/test.ql | 2 + .../security/CWE-022/semmle/tests/Test.java | 5 -- .../CWE-022/semmle/tests/mad/Test.java | 34 +++++++++ .../CWE-089/semmle/examples/Hive.java | 29 -------- .../CWE-089/semmle/examples/mad/Test.java | 37 ++++++++++ .../security/CWE-918/mad/Test.java | 22 ++++++ 14 files changed, 208 insertions(+), 34 deletions(-) create mode 100644 java/ql/test/library-tests/frameworks/apache-commons-compress/Test.java create mode 100644 java/ql/test/library-tests/frameworks/apache-commons-compress/options create mode 100644 java/ql/test/library-tests/frameworks/apache-commons-compress/test.expected create mode 100644 java/ql/test/library-tests/frameworks/apache-commons-compress/test.ql create mode 100644 java/ql/test/library-tests/frameworks/apache-http/client/Test.java create mode 100644 java/ql/test/library-tests/frameworks/apache-http/client/options create mode 100644 java/ql/test/library-tests/frameworks/apache-http/client/test.expected create mode 100644 java/ql/test/library-tests/frameworks/apache-http/client/test.ext.yml create mode 100644 java/ql/test/library-tests/frameworks/apache-http/client/test.ql create mode 100644 java/ql/test/query-tests/security/CWE-022/semmle/tests/mad/Test.java delete mode 100644 java/ql/test/query-tests/security/CWE-089/semmle/examples/Hive.java create mode 100644 java/ql/test/query-tests/security/CWE-089/semmle/examples/mad/Test.java create mode 100644 java/ql/test/query-tests/security/CWE-918/mad/Test.java diff --git a/java/ql/test/library-tests/frameworks/apache-commons-compress/Test.java b/java/ql/test/library-tests/frameworks/apache-commons-compress/Test.java new file mode 100644 index 00000000000..5d3470874b8 --- /dev/null +++ b/java/ql/test/library-tests/frameworks/apache-commons-compress/Test.java @@ -0,0 +1,32 @@ +package generatedtest; + +import org.apache.commons.compress.archivers.tar.TarArchiveEntry; + +// Test case generated by GenerateFlowTestCase.ql +public class Test { + + Object source() { + return null; + } + + void sink(Object o) {} + + public void test() throws Exception { + { + // "org.apache.commons.compress.archivers.tar;TarArchiveEntry;true;TarArchiveEntry;(String);;Argument[0];Argument[-1];taint;ai-generated" + TarArchiveEntry out = null; + String in = (String) source(); + out = new TarArchiveEntry(in); + sink(out); // $ hasTaintFlow + } + { + // "org.apache.commons.compress.archivers.tar;TarArchiveEntry;true;TarArchiveEntry;(String,boolean);;Argument[0];Argument[-1];taint;ai-generated" + TarArchiveEntry out = null; + String in = (String) source(); + out = new TarArchiveEntry(in, false); + sink(out); // $ hasTaintFlow + } + + } + +} diff --git a/java/ql/test/library-tests/frameworks/apache-commons-compress/options b/java/ql/test/library-tests/frameworks/apache-commons-compress/options new file mode 100644 index 00000000000..0e1282300e0 --- /dev/null +++ b/java/ql/test/library-tests/frameworks/apache-commons-compress/options @@ -0,0 +1 @@ +//semmle-extractor-options: --javac-args -cp ${testdir}/../../../stubs/apache-commons-compress diff --git a/java/ql/test/library-tests/frameworks/apache-commons-compress/test.expected b/java/ql/test/library-tests/frameworks/apache-commons-compress/test.expected new file mode 100644 index 00000000000..e69de29bb2d diff --git a/java/ql/test/library-tests/frameworks/apache-commons-compress/test.ql b/java/ql/test/library-tests/frameworks/apache-commons-compress/test.ql new file mode 100644 index 00000000000..5d91e4e8e26 --- /dev/null +++ b/java/ql/test/library-tests/frameworks/apache-commons-compress/test.ql @@ -0,0 +1,2 @@ +import java +import TestUtilities.InlineFlowTest diff --git a/java/ql/test/library-tests/frameworks/apache-http/client/Test.java b/java/ql/test/library-tests/frameworks/apache-http/client/Test.java new file mode 100644 index 00000000000..b78d6981d44 --- /dev/null +++ b/java/ql/test/library-tests/frameworks/apache-http/client/Test.java @@ -0,0 +1,71 @@ +package generatedtest; + +import java.net.URI; +import java.util.List; +import org.apache.http.client.utils.URIBuilder; +import org.apache.http.client.utils.URLEncodedUtils; + +// Test case generated by GenerateFlowTestCase.ql +public class Test { + + T getElement(Iterable it) { return it.iterator().next(); } + Object getURIBuilder_pathDefault(Object container) { return null; } + Object source() { return null; } + void sink(Object o) { } + + public void test() throws Exception { + + { + // "org.apache.http.client.utils;URIBuilder;true;URIBuilder;(String);;Argument[0];Argument[-1];taint;ai-generated" + URIBuilder out = null; + String in = (String)source(); + out = new URIBuilder(in); + sink(out); // $ hasTaintFlow + } + { + // "org.apache.http.client.utils;URIBuilder;true;URIBuilder;(URI);;Argument[0];Argument[-1];taint;ai-generated" + URIBuilder out = null; + URI in = (URI)source(); + out = new URIBuilder(in); + sink(out); // $ hasTaintFlow + } + { + // "org.apache.http.client.utils;URIBuilder;true;setHost;(String);;Argument[0];Argument[-1];taint;ai-generated" + URIBuilder out = null; + String in = (String)source(); + out.setHost(in); + sink(out); // $ hasTaintFlow + } + { + // "org.apache.http.client.utils;URIBuilder;true;setHost;(String);;Argument[0];ReturnValue;taint;ai-generated" + URIBuilder out = null; + String in = (String)source(); + URIBuilder instance = null; + out = instance.setHost(in); + sink(out); // $ hasTaintFlow + } + { + // "org.apache.http.client.utils;URIBuilder;true;setPath;(String);;Argument[0];Argument[-1].SyntheticField[org.apache.http.client.utils.URIBuilder.path];taint;ai-generated" + URIBuilder out = null; + String in = (String)source(); + out.setPath(in); + sink(getURIBuilder_pathDefault(out)); // $ hasTaintFlow + } + { + // "org.apache.http.client.utils;URIBuilder;true;setPathSegments;(List);;Argument[0];Argument[-1].SyntheticField[org.apache.http.client.utils.URIBuilder.path];taint;ai-generated" + URIBuilder out = null; + List in = (List)source(); + out.setPathSegments(in); + sink(getURIBuilder_pathDefault(out)); // $ hasTaintFlow + } + { + // "org.apache.http.client.utils;URLEncodedUtils;true;parse;(URI,String);;Argument[0];ReturnValue.Element;taint;ai-generated" + List out = null; + URI in = (URI)source(); + out = URLEncodedUtils.parse(in, (String)null); + sink(getElement(out)); // $ hasTaintFlow + } + + } + +} \ No newline at end of file diff --git a/java/ql/test/library-tests/frameworks/apache-http/client/options b/java/ql/test/library-tests/frameworks/apache-http/client/options new file mode 100644 index 00000000000..e564d247696 --- /dev/null +++ b/java/ql/test/library-tests/frameworks/apache-http/client/options @@ -0,0 +1 @@ +//semmle-extractor-options: --javac-args -cp ${testdir}/../../../../stubs/apache-http-4.4.13 diff --git a/java/ql/test/library-tests/frameworks/apache-http/client/test.expected b/java/ql/test/library-tests/frameworks/apache-http/client/test.expected new file mode 100644 index 00000000000..e69de29bb2d diff --git a/java/ql/test/library-tests/frameworks/apache-http/client/test.ext.yml b/java/ql/test/library-tests/frameworks/apache-http/client/test.ext.yml new file mode 100644 index 00000000000..dde1f4345b8 --- /dev/null +++ b/java/ql/test/library-tests/frameworks/apache-http/client/test.ext.yml @@ -0,0 +1,6 @@ +extensions: + - addsTo: + pack: codeql/java-tests + extensible: summaryModel + data: + - ["generatedtest", "Test", False, "getURIBuilder_pathDefault", "(Object)", "", "Argument[0].SyntheticField[org.apache.http.client.utils.URIBuilder.path]", "ReturnValue", "value", "manual"] diff --git a/java/ql/test/library-tests/frameworks/apache-http/client/test.ql b/java/ql/test/library-tests/frameworks/apache-http/client/test.ql new file mode 100644 index 00000000000..5d91e4e8e26 --- /dev/null +++ b/java/ql/test/library-tests/frameworks/apache-http/client/test.ql @@ -0,0 +1,2 @@ +import java +import TestUtilities.InlineFlowTest diff --git a/java/ql/test/query-tests/security/CWE-022/semmle/tests/Test.java b/java/ql/test/query-tests/security/CWE-022/semmle/tests/Test.java index 626851215e0..446c9b50a35 100644 --- a/java/ql/test/query-tests/security/CWE-022/semmle/tests/Test.java +++ b/java/ql/test/query-tests/security/CWE-022/semmle/tests/Test.java @@ -101,9 +101,4 @@ class Test { new File(new URI(null, null, null, 0, t, null, null)); } - void doGet6(InetAddress address) throws IOException { - String t = address.getHostName(); - // BAD: accessing local resource with user input - getClass().getModule().getResourceAsStream(t); - } } diff --git a/java/ql/test/query-tests/security/CWE-022/semmle/tests/mad/Test.java b/java/ql/test/query-tests/security/CWE-022/semmle/tests/mad/Test.java new file mode 100644 index 00000000000..f465b5a75e7 --- /dev/null +++ b/java/ql/test/query-tests/security/CWE-022/semmle/tests/mad/Test.java @@ -0,0 +1,34 @@ +import java.io.File; +import java.io.FileInputStream; +import java.io.FileReader; +import java.io.IOException; +import java.net.InetAddress; +import java.net.URL; +import org.codehaus.cargo.container.installer.ZipURLInstaller; + +public class Test { + + void test(InetAddress address) throws IOException { + String t = address.getHostName(); + // "java.lang;Module;true;getResourceAsStream;(String);;Argument[0];read-file;ai-generated" + getClass().getModule().getResourceAsStream(t); + // "java.lang;Class;false;getResource;(String);;Argument[0];read-file;ai-generated" + getClass().getResource(t); + // "java.lang;ClassLoader;true;getSystemResourceAsStream;(String);;Argument[0];read-file;ai-generated" + ClassLoader.getSystemResource(t); + // "java.io;File;true;createTempFile;(String,String,File);;Argument[2];create-file;ai-generated" + File.createTempFile(";", t); + // "java.io;File;true;renameTo;(File);;Argument[0];create-file;ai-generated" + new File("").renameTo((File) t); + // "java.io;FileInputStream;true;FileInputStream;(File);;Argument[0];read-file;ai-generated" + new FileInputStream((File) t); + // "java.io;FileReader;true;FileReader;(File);;Argument[0];read-file;ai-generated" + new FileReader((File) t); + // "java.io;FileReader;true;FileReader;(String);;Argument[0];read-file;ai-generated" + new FileReader(t); + // "org.codehaus.cargo.container.installer;ZipURLInstaller;true;ZipURLInstaller;(URL,String,String);;Argument[1];create-file;ai-generated" + new ZipURLInstaller((URL) null, t, ""); + // "org.codehaus.cargo.container.installer;ZipURLInstaller;true;ZipURLInstaller;(URL,String,String);;Argument[2];create-file;ai-generated" + new ZipURLInstaller((URL) null, "", t); + } +} diff --git a/java/ql/test/query-tests/security/CWE-089/semmle/examples/Hive.java b/java/ql/test/query-tests/security/CWE-089/semmle/examples/Hive.java deleted file mode 100644 index 0adbd3e2c52..00000000000 --- a/java/ql/test/query-tests/security/CWE-089/semmle/examples/Hive.java +++ /dev/null @@ -1,29 +0,0 @@ -import org.apache.hadoop.hive.metastore.api.ColumnStatistics; -import org.apache.hadoop.hive.metastore.api.DefaultConstraintsRequest; -import org.apache.hadoop.hive.metastore.ObjectStore; -import org.apache.hive.hcatalog.templeton.ColumnDesc; -import org.apache.hive.hcatalog.templeton.HcatDelegator; -import java.util.List; - -public class Hive { - - public static Object source() { - return null; - } - - public void test(ObjectStore objStore, HcatDelegator hcatDel) throws Exception { - { - String taint = (String) source(); - new DefaultConstraintsRequest("", taint, ""); // $ sqlInjection - } - { - ColumnStatistics taint = (ColumnStatistics) source(); - //objStore.updatePartitionColumnStatistics(taint, (List) null, (String) null, 0L); // $ sqlInjection - objStore.updatePartitionColumnStatistics(taint, (List) null); // $ sqlInjection - } - { - ColumnDesc taint = (ColumnDesc) source(); - hcatDel.addOneColumn(null, null, null, taint); // $ sqlInjection - } - } -} diff --git a/java/ql/test/query-tests/security/CWE-089/semmle/examples/mad/Test.java b/java/ql/test/query-tests/security/CWE-089/semmle/examples/mad/Test.java new file mode 100644 index 00000000000..9e897da3721 --- /dev/null +++ b/java/ql/test/query-tests/security/CWE-089/semmle/examples/mad/Test.java @@ -0,0 +1,37 @@ +import java.sql.DatabaseMetaData; + +public class Test { + public static Object source() { + return null; + } + + public void test(DatabaseMetaData dmd) { + String taint = (String) source(); + // java.sql;DatabaseMetaData;true;getColumns;(String,String,String,String);;Argument[2];sql;ai-generated + dmd.getCoolumns("", "", taint, ""); // $ sqlInjection + // java.sql;DatabaseMetaData;true;getPrimaryKeys;(String,String,String);;Argument[2];sql;ai-generated + dmd.getPrimaryKeys("", "", taint); // $ sqlInjection + } + + public void test(ObjectStore objStore, HcatDelegator hcatDel) throws Exception { + { + String taint = (String) source(); + // "org.apache.hadoop.hive.metastore.api;DefaultConstraintsRequest;true;DefaultConstraintsRequest;(String,String,String);;Argument[1];sql;ai-generated" + new DefaultConstraintsRequest("", taint, ""); // $ sqlInjection + } + { + ColumnStatistics taint = (ColumnStatistics) source(); + // "org.apache.hadoop.hive.metastore;ObjectStore;true;updatePartitionColumnStatistics;(ColumnStatistics,List,String,long);;Argument[0];sql;ai-generated" + // @formatter:off + // objStore.updatePartitionColumnStatistics(taint, (List) null, (String) null, 0L); // $ sqlInjection + // @formatter:on + // "org.apache.hadoop.hive.metastore;ObjectStore;true;updatePartitionColumnStatistics;(ColumnStatistics,List);;Argument[0];sql;ai-generated" + objStore.updatePartitionColumnStatistics(taint, (List) null); // $ sqlInjection + } + { + ColumnDesc taint = (ColumnDesc) source(); + // "org.apache.hive.hcatalog.templeton;HcatDelegator;true;addOneColumn;(String,String,String,ColumnDesc);;Argument[3];sql;ai-generated" + hcatDel.addOneColumn(null, null, null, taint); // $ sqlInjection + } + } +} diff --git a/java/ql/test/query-tests/security/CWE-918/mad/Test.java b/java/ql/test/query-tests/security/CWE-918/mad/Test.java new file mode 100644 index 00000000000..a5d72a249a0 --- /dev/null +++ b/java/ql/test/query-tests/security/CWE-918/mad/Test.java @@ -0,0 +1,22 @@ +import javax.servlet.http.HttpServletRequest; +import javafx.scene.web.WebEngine; +import org.codehaus.cargo.container.installer.ZipURLInstaller; + +public class Test { + + public static Object source(HttpServletRequest request) { + return request.getParameter(null); + } + + public void test(WebEngine webEngine) { + String taint = source(null); + // "javafx.scene.web;WebEngine;false;load;(String);;Argument[0];open-url;ai-generated" + webEngine.load(taint); // $ SSRF + } + + public void test() { + // "org.codehaus.cargo.container.installer;ZipURLInstaller;true;ZipURLInstaller;(URL,String,String);;Argument[0];open-url:ai-generated" + new ZipURLInstaller((URL) source(), "", ""); // $ SSRF + } + +} From 8aa80882ea29de847fa6457f16cc5f20fc473cfc Mon Sep 17 00:00:00 2001 From: Tony Torralba Date: Thu, 9 Mar 2023 18:47:41 +0100 Subject: [PATCH 075/135] Sync files --- .../semmle/code/csharp/dataflow/internal/FlowSummaryImpl.qll | 2 +- go/ql/lib/semmle/go/dataflow/internal/FlowSummaryImpl.qll | 2 +- .../lib/semmle/python/dataflow/new/internal/FlowSummaryImpl.qll | 2 +- ruby/ql/lib/codeql/ruby/dataflow/internal/FlowSummaryImpl.qll | 2 +- swift/ql/lib/codeql/swift/dataflow/internal/FlowSummaryImpl.qll | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/csharp/ql/lib/semmle/code/csharp/dataflow/internal/FlowSummaryImpl.qll b/csharp/ql/lib/semmle/code/csharp/dataflow/internal/FlowSummaryImpl.qll index 468ed73e81a..b2c7c557467 100644 --- a/csharp/ql/lib/semmle/code/csharp/dataflow/internal/FlowSummaryImpl.qll +++ b/csharp/ql/lib/semmle/code/csharp/dataflow/internal/FlowSummaryImpl.qll @@ -1012,7 +1012,7 @@ module Private { private predicate relevantSummaryElementGenerated( AccessPath inSpec, AccessPath outSpec, string kind ) { - summaryElement(this, inSpec, outSpec, kind, "generated") and + summaryElement(this, inSpec, outSpec, kind, ["generated", "ai-generated"]) and not summaryElement(this, _, _, _, "manual") } diff --git a/go/ql/lib/semmle/go/dataflow/internal/FlowSummaryImpl.qll b/go/ql/lib/semmle/go/dataflow/internal/FlowSummaryImpl.qll index 468ed73e81a..b2c7c557467 100644 --- a/go/ql/lib/semmle/go/dataflow/internal/FlowSummaryImpl.qll +++ b/go/ql/lib/semmle/go/dataflow/internal/FlowSummaryImpl.qll @@ -1012,7 +1012,7 @@ module Private { private predicate relevantSummaryElementGenerated( AccessPath inSpec, AccessPath outSpec, string kind ) { - summaryElement(this, inSpec, outSpec, kind, "generated") and + summaryElement(this, inSpec, outSpec, kind, ["generated", "ai-generated"]) and not summaryElement(this, _, _, _, "manual") } diff --git a/python/ql/lib/semmle/python/dataflow/new/internal/FlowSummaryImpl.qll b/python/ql/lib/semmle/python/dataflow/new/internal/FlowSummaryImpl.qll index 468ed73e81a..b2c7c557467 100644 --- a/python/ql/lib/semmle/python/dataflow/new/internal/FlowSummaryImpl.qll +++ b/python/ql/lib/semmle/python/dataflow/new/internal/FlowSummaryImpl.qll @@ -1012,7 +1012,7 @@ module Private { private predicate relevantSummaryElementGenerated( AccessPath inSpec, AccessPath outSpec, string kind ) { - summaryElement(this, inSpec, outSpec, kind, "generated") and + summaryElement(this, inSpec, outSpec, kind, ["generated", "ai-generated"]) and not summaryElement(this, _, _, _, "manual") } diff --git a/ruby/ql/lib/codeql/ruby/dataflow/internal/FlowSummaryImpl.qll b/ruby/ql/lib/codeql/ruby/dataflow/internal/FlowSummaryImpl.qll index 468ed73e81a..b2c7c557467 100644 --- a/ruby/ql/lib/codeql/ruby/dataflow/internal/FlowSummaryImpl.qll +++ b/ruby/ql/lib/codeql/ruby/dataflow/internal/FlowSummaryImpl.qll @@ -1012,7 +1012,7 @@ module Private { private predicate relevantSummaryElementGenerated( AccessPath inSpec, AccessPath outSpec, string kind ) { - summaryElement(this, inSpec, outSpec, kind, "generated") and + summaryElement(this, inSpec, outSpec, kind, ["generated", "ai-generated"]) and not summaryElement(this, _, _, _, "manual") } diff --git a/swift/ql/lib/codeql/swift/dataflow/internal/FlowSummaryImpl.qll b/swift/ql/lib/codeql/swift/dataflow/internal/FlowSummaryImpl.qll index 468ed73e81a..b2c7c557467 100644 --- a/swift/ql/lib/codeql/swift/dataflow/internal/FlowSummaryImpl.qll +++ b/swift/ql/lib/codeql/swift/dataflow/internal/FlowSummaryImpl.qll @@ -1012,7 +1012,7 @@ module Private { private predicate relevantSummaryElementGenerated( AccessPath inSpec, AccessPath outSpec, string kind ) { - summaryElement(this, inSpec, outSpec, kind, "generated") and + summaryElement(this, inSpec, outSpec, kind, ["generated", "ai-generated"]) and not summaryElement(this, _, _, _, "manual") } From 393a0759db66bf0765d9eb02fffd86aefff02ab0 Mon Sep 17 00:00:00 2001 From: Tony Torralba Date: Fri, 10 Mar 2023 10:08:58 +0100 Subject: [PATCH 076/135] More stubs --- .../cargo/container/installer/Installer.java | 11 + .../cargo/container/installer/Proxy.java | 23 + .../container/installer/ZipURLInstaller.java | 34 ++ .../org/codehaus/cargo/util/FileHandler.java | 49 ++ .../codehaus/cargo/util/XmlReplacement.java | 28 ++ .../org/codehaus/cargo/util/log/LogLevel.java | 18 + .../org/codehaus/cargo/util/log/Loggable.java | 11 + .../codehaus/cargo/util/log/LoggedObject.java | 13 + .../org/codehaus/cargo/util/log/Logger.java | 14 + .../com/sun/javafx/tk/TKClipboard.java | 26 + .../sun/javafx/tk/TKDragGestureListener.java | 10 + .../com/sun/javafx/tk/TKPulseListener.java | 9 + .../com/zaxxer/hikari/HikariConfig.java | 93 ++++ .../com/zaxxer/hikari/HikariConfigMXBean.java | 25 + .../com/zaxxer/hikari/HikariDataSource.java | 40 ++ .../com/zaxxer/hikari/HikariPoolMXBean.java | 15 + .../zaxxer/hikari/metrics/MetricsTracker.java | 13 + .../hikari/metrics/MetricsTrackerFactory.java | 11 + .../com/zaxxer/hikari/metrics/PoolStats.java | 19 + .../io/micrometer/observation/Context.java | 9 + .../observation/ObservationRegistry.java | 9 + .../javafx-web/jakarta/ws/rs/RuntimeType.java | 10 + .../jakarta/ws/rs/client/AsyncInvoker.java | 47 ++ .../jakarta/ws/rs/client/Client.java | 24 + .../jakarta/ws/rs/client/ClientBuilder.java | 33 ++ .../rs/client/CompletionStageRxInvoker.java | 38 ++ .../jakarta/ws/rs/client/Entity.java | 36 ++ .../jakarta/ws/rs/client/Invocation.java | 53 ++ .../ws/rs/client/InvocationCallback.java | 10 + .../jakarta/ws/rs/client/RxInvoker.java | 35 ++ .../jakarta/ws/rs/client/SyncInvoker.java | 36 ++ .../jakarta/ws/rs/client/WebTarget.java | 28 ++ .../jakarta/ws/rs/core/CacheControl.java | 34 ++ .../jakarta/ws/rs/core/Configurable.java | 20 + .../jakarta/ws/rs/core/Configuration.java | 25 + .../javafx-web/jakarta/ws/rs/core/Cookie.java | 33 ++ .../jakarta/ws/rs/core/EntityTag.java | 17 + .../jakarta/ws/rs/core/Feature.java | 10 + .../jakarta/ws/rs/core/FeatureContext.java | 9 + .../javafx-web/jakarta/ws/rs/core/Form.java | 14 + .../jakarta/ws/rs/core/GenericType.java | 17 + .../javafx-web/jakarta/ws/rs/core/Link.java | 48 ++ .../jakarta/ws/rs/core/MediaType.java | 54 ++ .../jakarta/ws/rs/core/MultivaluedMap.java | 17 + .../jakarta/ws/rs/core/NewCookie.java | 51 ++ .../jakarta/ws/rs/core/Response.java | 131 +++++ .../jakarta/ws/rs/core/UriBuilder.java | 54 ++ .../jakarta/ws/rs/core/Variant.java | 36 ++ .../javafx/animation/Interpolatable.java | 9 + .../javafx/beans/InvalidationListener.java | 10 + .../javafx-web/javafx/beans/Observable.java | 11 + .../javafx/beans/binding/Binding.java | 14 + .../javafx/beans/binding/BooleanBinding.java | 29 ++ .../beans/binding/BooleanExpression.java | 24 + .../javafx/beans/binding/DoubleBinding.java | 29 ++ .../beans/binding/DoubleExpression.java | 44 ++ .../javafx/beans/binding/FloatBinding.java | 29 ++ .../javafx/beans/binding/FloatExpression.java | 40 ++ .../javafx/beans/binding/IntegerBinding.java | 29 ++ .../beans/binding/IntegerExpression.java | 42 ++ .../javafx/beans/binding/LongBinding.java | 29 ++ .../javafx/beans/binding/LongExpression.java | 41 ++ .../javafx/beans/binding/NumberBinding.java | 10 + .../beans/binding/NumberExpression.java | 73 +++ .../beans/binding/NumberExpressionBase.java | 59 +++ .../beans/binding/ObjectExpression.java | 24 + .../javafx/beans/binding/StringBinding.java | 29 ++ .../beans/binding/StringExpression.java | 38 ++ .../beans/property/BooleanProperty.java | 19 + .../javafx/beans/property/DoubleProperty.java | 19 + .../beans/property/IntegerProperty.java | 19 + .../javafx/beans/property/ObjectProperty.java | 16 + .../javafx/beans/property/Property.java | 16 + .../property/ReadOnlyBooleanProperty.java | 15 + .../property/ReadOnlyBooleanPropertyBase.java | 17 + .../property/ReadOnlyDoubleProperty.java | 15 + .../property/ReadOnlyIntegerProperty.java | 15 + .../property/ReadOnlyObjectProperty.java | 12 + .../beans/property/ReadOnlyProperty.java | 11 + .../property/ReadOnlyStringProperty.java | 12 + .../javafx/beans/property/StringProperty.java | 21 + .../javafx/beans/value/ChangeListener.java | 10 + .../beans/value/ObservableBooleanValue.java | 10 + .../beans/value/ObservableDoubleValue.java | 10 + .../beans/value/ObservableFloatValue.java | 10 + .../beans/value/ObservableIntegerValue.java | 10 + .../beans/value/ObservableLongValue.java | 10 + .../beans/value/ObservableNumberValue.java | 13 + .../beans/value/ObservableObjectValue.java | 10 + .../beans/value/ObservableStringValue.java | 9 + .../javafx/beans/value/ObservableValue.java | 18 + .../beans/value/WritableBooleanValue.java | 12 + .../beans/value/WritableDoubleValue.java | 12 + .../beans/value/WritableIntegerValue.java | 12 + .../beans/value/WritableNumberValue.java | 9 + .../beans/value/WritableObjectValue.java | 11 + .../beans/value/WritableStringValue.java | 9 + .../javafx/beans/value/WritableValue.java | 10 + .../collections/ListChangeListener.java | 32 ++ .../javafx/collections/MapChangeListener.java | 21 + .../javafx/collections/ObservableList.java | 27 + .../collections/ObservableListBase.java | 36 ++ .../javafx/collections/ObservableMap.java | 13 + .../javafx/collections/ObservableSet.java | 13 + .../javafx/collections/SetChangeListener.java | 20 + .../transformation/FilteredList.java | 24 + .../transformation/SortedList.java | 24 + .../transformation/TransformationList.java | 19 + .../javafx-web/javafx/concurrent/Worker.java | 36 ++ .../javafx-web/javafx/css/CssMetaData.java | 29 ++ .../javafx-web/javafx/css/ParsedValue.java | 19 + .../javafx-web/javafx/css/PseudoClass.java | 11 + .../javafx-web/javafx/css/StyleConverter.java | 48 ++ .../javafx-web/javafx/css/StyleOrigin.java | 10 + .../javafx-web/javafx/css/Styleable.java | 22 + .../javafx/css/StyleableProperty.java | 15 + .../stubs/javafx-web/javafx/event/Event.java | 52 ++ .../javafx/event/EventDispatchChain.java | 13 + .../javafx/event/EventDispatcher.java | 11 + .../javafx-web/javafx/event/EventHandler.java | 11 + .../javafx-web/javafx/event/EventTarget.java | 10 + .../javafx-web/javafx/event/EventType.java | 18 + .../javafx-web/javafx/geometry/Bounds.java | 35 ++ .../javafx-web/javafx/geometry/Insets.java | 19 + .../javafx/geometry/NodeOrientation.java | 10 + .../javafx/geometry/Orientation.java | 10 + .../javafx-web/javafx/geometry/Point2D.java | 37 ++ .../javafx-web/javafx/geometry/Point3D.java | 37 ++ .../javafx/geometry/Rectangle2D.java | 27 + .../javafx-web/javafx/print/Collation.java | 10 + .../javafx-web/javafx/print/JobSettings.java | 54 ++ .../javafx-web/javafx/print/PageLayout.java | 22 + .../javafx/print/PageOrientation.java | 10 + .../javafx-web/javafx/print/PageRange.java | 16 + .../stubs/javafx-web/javafx/print/Paper.java | 35 ++ .../javafx-web/javafx/print/PaperSource.java | 20 + .../javafx-web/javafx/print/PrintColor.java | 10 + .../javafx-web/javafx/print/PrintQuality.java | 10 + .../javafx/print/PrintResolution.java | 14 + .../javafx-web/javafx/print/PrintSides.java | 10 + .../javafx-web/javafx/print/Printer.java | 29 ++ .../javafx/print/PrinterAttributes.java | 37 ++ .../javafx-web/javafx/print/PrinterJob.java | 36 ++ .../javafx/scene/AccessibleAction.java | 10 + .../javafx/scene/AccessibleAttribute.java | 11 + .../javafx/scene/AccessibleRole.java | 10 + .../javafx-web/javafx/scene/CacheHint.java | 10 + .../stubs/javafx-web/javafx/scene/Camera.java | 17 + .../stubs/javafx-web/javafx/scene/Cursor.java | 30 ++ .../javafx-web/javafx/scene/DepthTest.java | 10 + .../stubs/javafx-web/javafx/scene/Node.java | 406 +++++++++++++++ .../stubs/javafx-web/javafx/scene/Parent.java | 37 ++ .../stubs/javafx-web/javafx/scene/Scene.java | 233 +++++++++ .../javafx/scene/SceneAntialiasing.java | 12 + .../javafx/scene/SnapshotParameters.java | 23 + .../javafx/scene/SnapshotResult.java | 14 + .../javafx/scene/effect/BlendMode.java | 10 + .../javafx/scene/effect/Effect.java | 9 + .../javafx-web/javafx/scene/image/Image.java | 38 ++ .../javafx/scene/image/PixelBuffer.java | 19 + .../javafx/scene/image/PixelFormat.java | 29 ++ .../javafx/scene/image/PixelReader.java | 20 + .../javafx/scene/image/PixelWriter.java | 21 + .../javafx/scene/image/WritableImage.java | 19 + .../scene/image/WritablePixelFormat.java | 13 + .../javafx/scene/input/Clipboard.java | 33 ++ .../javafx/scene/input/ContextMenuEvent.java | 30 ++ .../javafx/scene/input/DataFormat.java | 22 + .../javafx/scene/input/DragEvent.java | 48 ++ .../javafx/scene/input/Dragboard.java | 21 + .../javafx/scene/input/GestureEvent.java | 37 ++ .../javafx/scene/input/InputEvent.java | 16 + .../javafx/scene/input/InputMethodEvent.java | 26 + .../scene/input/InputMethodHighlight.java | 10 + .../scene/input/InputMethodRequests.java | 13 + .../scene/input/InputMethodTextRun.java | 15 + .../javafx/scene/input/KeyCode.java | 23 + .../javafx/scene/input/KeyCombination.java | 49 ++ .../javafx/scene/input/KeyEvent.java | 33 ++ .../javafx/scene/input/Mnemonic.java | 17 + .../javafx/scene/input/MouseButton.java | 10 + .../javafx/scene/input/MouseDragEvent.java | 30 ++ .../javafx/scene/input/MouseEvent.java | 61 +++ .../javafx/scene/input/PickResult.java | 25 + .../javafx/scene/input/RotateEvent.java | 26 + .../javafx/scene/input/ScrollEvent.java | 46 ++ .../javafx/scene/input/SwipeEvent.java | 26 + .../javafx/scene/input/TouchEvent.java | 34 ++ .../javafx/scene/input/TouchPoint.java | 35 ++ .../javafx/scene/input/TransferMode.java | 13 + .../javafx/scene/input/ZoomEvent.java | 26 + .../javafx-web/javafx/scene/paint/Color.java | 192 +++++++ .../javafx-web/javafx/scene/paint/Paint.java | 10 + .../javafx-web/javafx/scene/text/Font.java | 36 ++ .../javafx/scene/text/FontPosture.java | 11 + .../javafx/scene/text/FontWeight.java | 13 + .../javafx/scene/transform/Affine.java | 116 +++++ .../javafx/scene/transform/MatrixType.java | 14 + .../javafx/scene/transform/Rotate.java | 62 +++ .../javafx/scene/transform/Scale.java | 53 ++ .../javafx/scene/transform/Shear.java | 43 ++ .../javafx/scene/transform/Transform.java | 93 ++++ .../transform/TransformChangedEvent.java | 15 + .../javafx/scene/transform/Translate.java | 43 ++ .../javafx/scene/web/PopupFeatures.java | 14 + .../javafx/scene/web/PromptData.java | 12 + .../javafx/scene/web/WebEngine.java | 78 +++ .../javafx/scene/web/WebErrorEvent.java | 19 + .../javafx-web/javafx/scene/web/WebEvent.java | 19 + .../javafx/scene/web/WebHistory.java | 30 ++ .../stubs/javafx-web/javafx/stage/Window.java | 95 ++++ .../javafx-web/javafx/stage/WindowEvent.java | 24 + .../javafx-web/javafx/util/Callback.java | 9 + .../javafx-web/javafx/util/Duration.java | 41 ++ .../stubs/javafx-web/javafx/util/Pair.java | 16 + .../javafx/util/StringConverter.java | 11 + .../javax/net/ServerSocketFactory.java | 16 + .../javafx-web/javax/net/SocketFactory.java | 17 + .../javax/net/ssl/HostnameVerifier.java | 10 + .../javafx-web/javax/net/ssl/KeyManager.java | 8 + .../javafx-web/javax/net/ssl/SNIMatcher.java | 13 + .../javax/net/ssl/SNIServerName.java | 15 + .../javafx-web/javax/net/ssl/SSLContext.java | 36 ++ .../javax/net/ssl/SSLContextSpi.java | 26 + .../javafx-web/javax/net/ssl/SSLEngine.java | 53 ++ .../javax/net/ssl/SSLEngineResult.java | 27 + .../javax/net/ssl/SSLParameters.java | 42 ++ .../javax/net/ssl/SSLServerSocketFactory.java | 13 + .../javafx-web/javax/net/ssl/SSLSession.java | 33 ++ .../javax/net/ssl/SSLSessionContext.java | 16 + .../javax/net/ssl/SSLSocketFactory.java | 17 + .../javax/net/ssl/TrustManager.java | 8 + .../javax/security/cert/Certificate.java | 17 + .../javax/security/cert/X509Certificate.java | 26 + .../javax/servlet/AsyncContext.java | 31 ++ .../javafx-web/javax/servlet/AsyncEvent.java | 20 + .../javax/servlet/AsyncListener.java | 14 + .../javax/servlet/DispatcherType.java | 10 + .../javafx-web/javax/servlet/Filter.java | 15 + .../javafx-web/javax/servlet/FilterChain.java | 11 + .../javax/servlet/FilterConfig.java | 14 + .../javax/servlet/FilterRegistration.java | 19 + .../javax/servlet/GenericServlet.java | 28 ++ .../javax/servlet/HttpConstraintElement.java | 16 + .../servlet/HttpMethodConstraintElement.java | 13 + .../javax/servlet/MultipartConfigElement.java | 17 + .../javax/servlet/ReadListener.java | 12 + .../javax/servlet/Registration.java | 20 + .../javax/servlet/RequestDispatcher.java | 30 ++ .../javafx-web/javax/servlet/Servlet.java | 16 + .../javax/servlet/ServletConfig.java | 14 + .../javax/servlet/ServletContext.java | 83 ++++ .../javax/servlet/ServletInputStream.java | 15 + .../javax/servlet/ServletOutputStream.java | 28 ++ .../javax/servlet/ServletRegistration.java | 23 + .../javax/servlet/ServletRequest.java | 55 ++ .../javax/servlet/ServletResponse.java | 27 + .../javax/servlet/ServletSecurityElement.java | 19 + .../javax/servlet/SessionCookieConfig.java | 22 + .../javax/servlet/SessionTrackingMode.java | 10 + .../javax/servlet/WriteListener.java | 11 + .../servlet/annotation/HttpConstraint.java | 18 + .../annotation/HttpMethodConstraint.java | 19 + .../servlet/annotation/MultipartConfig.java | 19 + .../servlet/annotation/ServletSecurity.java | 33 ++ .../descriptor/JspConfigDescriptor.java | 13 + .../JspPropertyGroupDescriptor.java | 21 + .../servlet/descriptor/TaglibDescriptor.java | 10 + .../javafx-web/javax/servlet/http/Cookie.java | 29 ++ .../javax/servlet/http/HttpServlet.java | 24 + .../servlet/http/HttpServletMapping.java | 13 + .../servlet/http/HttpServletRequest.java | 60 +++ .../servlet/http/HttpServletResponse.java | 77 +++ .../javax/servlet/http/HttpSession.java | 28 ++ .../servlet/http/HttpSessionContext.java | 12 + .../servlet/http/HttpUpgradeHandler.java | 11 + .../javax/servlet/http/MappingMatch.java | 10 + .../javafx-web/javax/servlet/http/Part.java | 20 + .../javax/servlet/http/PushBuilder.java | 23 + .../javax/servlet/http/WebConnection.java | 12 + .../javax/sql/CommonDataSource.java | 17 + .../javafx-web/javax/sql/DataSource.java | 20 + .../javafx-web/javax/ws/rs/RuntimeType.java | 10 + .../javax/ws/rs/client/AsyncInvoker.java | 47 ++ .../javafx-web/javax/ws/rs/client/Client.java | 24 + .../javax/ws/rs/client/ClientBuilder.java | 26 + .../javafx-web/javax/ws/rs/client/Entity.java | 36 ++ .../javax/ws/rs/client/Invocation.java | 49 ++ .../ws/rs/client/InvocationCallback.java | 10 + .../javax/ws/rs/client/SyncInvoker.java | 36 ++ .../javax/ws/rs/client/WebTarget.java | 28 ++ .../javax/ws/rs/core/CacheControl.java | 34 ++ .../javax/ws/rs/core/Configurable.java | 20 + .../javax/ws/rs/core/Configuration.java | 24 + .../javafx-web/javax/ws/rs/core/Cookie.java | 22 + .../javax/ws/rs/core/EntityTag.java | 17 + .../javafx-web/javax/ws/rs/core/Feature.java | 10 + .../javax/ws/rs/core/FeatureContext.java | 9 + .../javafx-web/javax/ws/rs/core/Form.java | 14 + .../javax/ws/rs/core/GenericType.java | 16 + .../javafx-web/javax/ws/rs/core/Link.java | 48 ++ .../javax/ws/rs/core/MediaType.java | 50 ++ .../javax/ws/rs/core/MultivaluedMap.java | 17 + .../javax/ws/rs/core/NewCookie.java | 29 ++ .../javafx-web/javax/ws/rs/core/Response.java | 127 +++++ .../javax/ws/rs/core/UriBuilder.java | 54 ++ .../javafx-web/javax/ws/rs/core/Variant.java | 36 ++ .../org/apache/commons/logging/Log.java | 26 + .../javafx-web/org/apache/http/Header.java | 11 + .../org/apache/http/HeaderElement.java | 15 + .../org/apache/http/HeaderIterator.java | 12 + .../org/apache/http/HttpClientConnection.java | 18 + .../org/apache/http/HttpConnection.java | 17 + .../apache/http/HttpConnectionMetrics.java | 14 + .../org/apache/http/HttpEntity.java | 20 + .../http/HttpEntityEnclosingRequest.java | 13 + .../javafx-web/org/apache/http/HttpHost.java | 36 ++ .../org/apache/http/HttpInetConnection.java | 14 + .../org/apache/http/HttpMessage.java | 29 ++ .../org/apache/http/HttpRequest.java | 11 + .../org/apache/http/HttpResponse.java | 23 + .../org/apache/http/NameValuePair.java | 10 + .../org/apache/http/ProtocolVersion.java | 26 + .../org/apache/http/RequestLine.java | 12 + .../org/apache/http/StatusLine.java | 12 + .../http/client/config/RequestConfig.java | 57 +++ .../client/methods/AbortableHttpRequest.java | 13 + .../AbstractExecutionAwareRequest.java | 24 + .../http/client/methods/Configurable.java | 10 + .../http/client/methods/HttpDelete.java | 15 + .../HttpEntityEnclosingRequestBase.java | 16 + .../client/methods/HttpExecutionAware.java | 11 + .../apache/http/client/methods/HttpGet.java | 15 + .../apache/http/client/methods/HttpHead.java | 15 + .../http/client/methods/HttpOptions.java | 18 + .../apache/http/client/methods/HttpPatch.java | 15 + .../apache/http/client/methods/HttpPost.java | 15 + .../apache/http/client/methods/HttpPut.java | 15 + .../http/client/methods/HttpRequestBase.java | 27 + .../apache/http/client/methods/HttpTrace.java | 15 + .../http/client/methods/HttpUriRequest.java | 14 + .../http/client/methods/RequestBuilder.java | 71 +++ .../apache/http/concurrent/Cancellable.java | 9 + .../http/conn/ClientConnectionRequest.java | 12 + .../http/conn/ConnectionReleaseTrigger.java | 10 + .../http/conn/HttpRoutedConnection.java | 14 + .../http/conn/ManagedClientConnection.java | 30 ++ .../conn/ManagedHttpClientConnection.java | 16 + .../apache/http/conn/routing/HttpRoute.java | 34 ++ .../apache/http/conn/routing/RouteInfo.java | 30 ++ .../http/message/AbstractHttpMessage.java | 33 ++ .../BasicHttpEntityEnclosingRequest.java | 20 + .../apache/http/message/BasicHttpRequest.java | 19 + .../apache/http/message/BasicRequestLine.java | 18 + .../org/apache/http/message/HeaderGroup.java | 28 ++ .../org/apache/http/params/HttpParams.java | 22 + .../org/apache/http/protocol/HttpContext.java | 12 + .../cargo/container/installer/Installer.java | 11 + .../cargo/container/installer/Proxy.java | 23 + .../container/installer/ZipURLInstaller.java | 34 ++ .../org/codehaus/cargo/util/FileHandler.java | 49 ++ .../codehaus/cargo/util/XmlReplacement.java | 28 ++ .../org/codehaus/cargo/util/log/LogLevel.java | 18 + .../org/codehaus/cargo/util/log/Loggable.java | 11 + .../codehaus/cargo/util/log/LoggedObject.java | 13 + .../org/codehaus/cargo/util/log/Logger.java | 14 + .../org/jdbi/v3/core/ConnectionFactory.java | 13 + .../javafx-web/org/jdbi/v3/core/Handle.java | 84 ++++ .../org/jdbi/v3/core/HandleCallback.java | 10 + .../org/jdbi/v3/core/HandleConsumer.java | 12 + .../org/jdbi/v3/core/HandleListener.java | 11 + .../javafx-web/org/jdbi/v3/core/Jdbi.java | 53 ++ .../org/jdbi/v3/core/argument/Argument.java | 11 + .../v3/core/argument/ArgumentFactory.java | 21 + .../v3/core/argument/NamedArgumentFinder.java | 14 + .../argument/QualifiedArgumentFactory.java | 24 + .../internal/NamedArgumentFinderFactory.java | 26 + .../core/array/SqlArrayArgumentStrategy.java | 10 + .../org/jdbi/v3/core/array/SqlArrayType.java | 13 + .../v3/core/array/SqlArrayTypeFactory.java | 15 + .../org/jdbi/v3/core/codec/Codec.java | 16 + .../org/jdbi/v3/core/codec/CodecFactory.java | 41 ++ .../v3/core/collector/CollectorFactory.java | 14 + .../jdbi/v3/core/config/ConfigRegistry.java | 12 + .../org/jdbi/v3/core/config/Configurable.java | 64 +++ .../org/jdbi/v3/core/config/JdbiConfig.java | 11 + .../v3/core/extension/ExtensionCallback.java | 9 + .../v3/core/extension/ExtensionConsumer.java | 9 + .../v3/core/extension/ExtensionContext.java | 15 + .../v3/core/extension/ExtensionFactory.java | 11 + .../v3/core/extension/ExtensionMethod.java | 14 + .../v3/core/extension/HandleSupplier.java | 20 + .../org/jdbi/v3/core/generic/GenericType.java | 11 + .../org/jdbi/v3/core/mapper/ColumnMapper.java | 15 + .../v3/core/mapper/ColumnMapperFactory.java | 14 + .../mapper/QualifiedColumnMapperFactory.java | 16 + .../org/jdbi/v3/core/mapper/RowMapper.java | 14 + .../jdbi/v3/core/mapper/RowMapperFactory.java | 14 + .../jdbi/v3/core/mapper/RowViewMapper.java | 15 + .../jdbi/v3/core/qualifier/QualifiedType.java | 30 ++ .../v3/core/result/BatchResultBearing.java | 49 ++ .../v3/core/result/BatchResultIterable.java | 13 + .../jdbi/v3/core/result/IteratorCallback.java | 10 + .../jdbi/v3/core/result/IteratorConsumer.java | 10 + .../jdbi/v3/core/result/ResultBearing.java | 48 ++ .../jdbi/v3/core/result/ResultIterable.java | 45 ++ .../jdbi/v3/core/result/ResultIterator.java | 15 + .../jdbi/v3/core/result/ResultProducer.java | 12 + .../v3/core/result/ResultSetAccumulator.java | 11 + .../jdbi/v3/core/result/ResultSetScanner.java | 12 + .../org/jdbi/v3/core/result/RowReducer.java | 13 + .../org/jdbi/v3/core/result/RowView.java | 23 + .../jdbi/v3/core/result/StreamCallback.java | 10 + .../jdbi/v3/core/result/StreamConsumer.java | 10 + .../org/jdbi/v3/core/spi/JdbiPlugin.java | 14 + .../jdbi/v3/core/statement/BaseStatement.java | 24 + .../org/jdbi/v3/core/statement/Batch.java | 14 + .../org/jdbi/v3/core/statement/Binding.java | 34 ++ .../org/jdbi/v3/core/statement/Call.java | 24 + .../statement/CallableStatementMapper.java | 10 + .../org/jdbi/v3/core/statement/Cleanable.java | 9 + .../org/jdbi/v3/core/statement/MetaData.java | 26 + .../jdbi/v3/core/statement/OutParameters.java | 35 ++ .../v3/core/statement/ParsedParameters.java | 18 + .../org/jdbi/v3/core/statement/ParsedSql.java | 25 + .../jdbi/v3/core/statement/PreparedBatch.java | 31 ++ .../org/jdbi/v3/core/statement/Query.java | 22 + .../org/jdbi/v3/core/statement/Script.java | 17 + .../org/jdbi/v3/core/statement/SqlLogger.java | 14 + .../org/jdbi/v3/core/statement/SqlParser.java | 12 + .../jdbi/v3/core/statement/SqlStatement.java | 148 ++++++ .../v3/core/statement/StatementBuilder.java | 18 + .../statement/StatementBuilderFactory.java | 11 + .../v3/core/statement/StatementContext.java | 77 +++ .../core/statement/StatementCustomizer.java | 14 + .../v3/core/statement/TemplateEngine.java | 15 + .../v3/core/statement/TimingCollector.java | 11 + .../org/jdbi/v3/core/statement/Update.java | 19 + .../statement/internal/PreparedBinding.java | 22 + .../core/transaction/TransactionHandler.java | 21 + .../TransactionIsolationLevel.java | 11 + .../javafx-web/org/postgresql/Driver.java | 29 ++ .../org/postgresql/util/SharedTimer.java | 13 + .../org/reactivestreams/Publisher.java | 10 + .../org/reactivestreams/Subscriber.java | 13 + .../org/reactivestreams/Subscription.java | 10 + .../boot/jdbc/DataSourceBuilder.java | 20 + .../springframework/core/MethodParameter.java | 67 +++ .../core/NestedRuntimeException.java | 14 + .../core/ParameterNameDiscoverer.java | 12 + .../core/ParameterizedTypeReference.java | 15 + .../springframework/core/ResolvableType.java | 73 +++ .../springframework/core/codec/Decoder.java | 22 + .../springframework/core/codec/Encoder.java | 21 + .../core/io/InputStreamSource.java | 10 + .../org/springframework/core/io/Resource.java | 29 ++ .../core/io/buffer/DataBuffer.java | 59 +++ .../core/io/buffer/DataBufferFactory.java | 17 + .../core/io/support/ResourceRegion.java | 14 + .../springframework/http/CacheControl.java | 29 ++ .../http/ContentDisposition.java | 42 ++ .../org/springframework/http/HttpCookie.java | 15 + .../org/springframework/http/HttpEntity.java | 21 + .../org/springframework/http/HttpHeaders.java | 218 ++++++++ .../http/HttpInputMessage.java | 11 + .../org/springframework/http/HttpMessage.java | 10 + .../org/springframework/http/HttpMethod.java | 12 + .../http/HttpOutputMessage.java | 11 + .../org/springframework/http/HttpRange.java | 22 + .../org/springframework/http/HttpRequest.java | 14 + .../org/springframework/http/HttpStatus.java | 28 ++ .../springframework/http/HttpStatusCode.java | 9 + .../org/springframework/http/MediaType.java | 96 ++++ .../http/ReactiveHttpInputMessage.java | 12 + .../http/ReactiveHttpOutputMessage.java | 20 + .../springframework/http/RequestEntity.java | 70 +++ .../springframework/http/ResponseCookie.java | 33 ++ .../springframework/http/ResponseEntity.java | 64 +++ .../http/client/ClientHttpRequest.java | 12 + .../client/ClientHttpRequestExecution.java | 11 + .../http/client/ClientHttpRequestFactory.java | 12 + .../client/ClientHttpRequestInitializer.java | 10 + .../client/ClientHttpRequestInterceptor.java | 12 + .../http/client/ClientHttpResponse.java | 15 + .../client/reactive/ClientHttpConnector.java | 15 + .../client/reactive/ClientHttpRequest.java | 17 + .../client/reactive/ClientHttpResponse.java | 16 + .../http/client/support/HttpAccessor.java | 22 + .../support/InterceptingHttpAccessor.java | 17 + .../http/codec/ClientCodecConfigurer.java | 25 + .../http/codec/CodecConfigurer.java | 52 ++ .../http/codec/HttpMessageReader.java | 24 + .../http/codec/HttpMessageWriter.java | 22 + .../http/converter/HttpMessageConverter.java | 18 + .../http/server/PathContainer.java | 28 ++ .../http/server/RequestPath.java | 15 + .../server/reactive/ServerHttpRequest.java | 39 ++ .../server/reactive/ServerHttpResponse.java | 18 + .../http/server/reactive/SslInfo.java | 11 + .../jdbc/datasource/AbstractDataSource.java | 21 + .../AbstractDriverBasedDataSource.java | 28 ++ .../datasource/DriverManagerDataSource.java | 18 + .../org/springframework/util/MimeType.java | 44 ++ .../springframework/util/MultiValueMap.java | 18 + .../web/client/RequestCallback.java | 10 + .../web/client/ResponseErrorHandler.java | 14 + .../web/client/ResponseExtractor.java | 10 + .../web/client/RestClientException.java | 12 + .../web/client/RestOperations.java | 60 +++ .../web/client/RestTemplate.java | 86 ++++ .../web/reactive/function/BodyExtractor.java | 21 + .../web/reactive/function/BodyInserter.java | 22 + .../function/client/ClientRequest.java | 52 ++ .../ClientRequestObservationConvention.java | 10 + .../function/client/ClientResponse.java | 76 +++ .../client/ExchangeFilterFunction.java | 18 + .../function/client/ExchangeFunction.java | 14 + .../function/client/ExchangeStrategies.java | 24 + .../reactive/function/client/WebClient.java | 142 ++++++ .../function/client/WebClientException.java | 12 + .../client/WebClientResponseException.java | 37 ++ .../springframework/web/util/UriBuilder.java | 33 ++ .../web/util/UriBuilderFactory.java | 12 + .../web/util/UriTemplateHandler.java | 12 + .../stubs/javafx-web/org/w3c/dom/Attr.java | 18 + .../javafx-web/org/w3c/dom/CDATASection.java | 9 + .../javafx-web/org/w3c/dom/CharacterData.java | 17 + .../stubs/javafx-web/org/w3c/dom/Comment.java | 9 + .../org/w3c/dom/DOMConfiguration.java | 13 + .../org/w3c/dom/DOMImplementation.java | 14 + .../javafx-web/org/w3c/dom/DOMStringList.java | 11 + .../javafx-web/org/w3c/dom/Document.java | 52 ++ .../org/w3c/dom/DocumentFragment.java | 9 + .../javafx-web/org/w3c/dom/DocumentType.java | 16 + .../stubs/javafx-web/org/w3c/dom/Element.java | 32 ++ .../org/w3c/dom/EntityReference.java | 9 + .../javafx-web/org/w3c/dom/NamedNodeMap.java | 17 + .../stubs/javafx-web/org/w3c/dom/Node.java | 67 +++ .../javafx-web/org/w3c/dom/NodeList.java | 11 + .../org/w3c/dom/ProcessingInstruction.java | 12 + .../stubs/javafx-web/org/w3c/dom/Text.java | 13 + .../javafx-web/org/w3c/dom/TypeInfo.java | 15 + .../org/w3c/dom/UserDataHandler.java | 15 + .../reactor/core/CorePublisher.java | 11 + .../reactor/core/CoreSubscriber.java | 13 + .../javafx-web/reactor/core/Disposable.java | 10 + .../core/observability/SignalListener.java | 26 + .../observability/SignalListenerFactory.java | 13 + .../publisher/BufferOverflowStrategy.java | 10 + .../core/publisher/ConnectableFlux.java | 24 + .../reactor/core/publisher/Flux.java | 470 ++++++++++++++++++ .../reactor/core/publisher/FluxSink.java | 27 + .../reactor/core/publisher/GroupedFlux.java | 11 + .../reactor/core/publisher/Mono.java | 261 ++++++++++ .../reactor/core/publisher/MonoSink.java | 20 + .../reactor/core/publisher/ParallelFlux.java | 97 ++++ .../reactor/core/publisher/Signal.java | 37 ++ .../reactor/core/publisher/SignalType.java | 11 + .../core/publisher/SynchronousSink.java | 15 + .../reactor/core/publisher/Timed.java | 15 + .../reactor/core/scheduler/Scheduler.java | 26 + .../stubs/javafx-web/reactor/util/Logger.java | 39 ++ .../reactor/util/context/Context.java | 25 + .../reactor/util/context/ContextView.java | 21 + .../reactor/util/function/Tuple2.java | 25 + .../reactor/util/function/Tuple3.java | 20 + .../reactor/util/function/Tuple4.java | 21 + .../reactor/util/function/Tuple5.java | 22 + .../reactor/util/function/Tuple6.java | 23 + .../reactor/util/function/Tuple7.java | 24 + .../reactor/util/function/Tuple8.java | 25 + .../javafx-web/reactor/util/retry/Retry.java | 35 ++ .../reactor/util/retry/RetryBackoffSpec.java | 43 ++ .../reactor/util/retry/RetrySpec.java | 31 ++ .../boot/jdbc/DataSourceBuilder.java | 60 ++- 575 files changed, 15595 insertions(+), 19 deletions(-) create mode 100644 java/ql/test/stubs/cargo/org/codehaus/cargo/container/installer/Installer.java create mode 100644 java/ql/test/stubs/cargo/org/codehaus/cargo/container/installer/Proxy.java create mode 100644 java/ql/test/stubs/cargo/org/codehaus/cargo/container/installer/ZipURLInstaller.java create mode 100644 java/ql/test/stubs/cargo/org/codehaus/cargo/util/FileHandler.java create mode 100644 java/ql/test/stubs/cargo/org/codehaus/cargo/util/XmlReplacement.java create mode 100644 java/ql/test/stubs/cargo/org/codehaus/cargo/util/log/LogLevel.java create mode 100644 java/ql/test/stubs/cargo/org/codehaus/cargo/util/log/Loggable.java create mode 100644 java/ql/test/stubs/cargo/org/codehaus/cargo/util/log/LoggedObject.java create mode 100644 java/ql/test/stubs/cargo/org/codehaus/cargo/util/log/Logger.java create mode 100644 java/ql/test/stubs/javafx-web/com/sun/javafx/tk/TKClipboard.java create mode 100644 java/ql/test/stubs/javafx-web/com/sun/javafx/tk/TKDragGestureListener.java create mode 100644 java/ql/test/stubs/javafx-web/com/sun/javafx/tk/TKPulseListener.java create mode 100644 java/ql/test/stubs/javafx-web/com/zaxxer/hikari/HikariConfig.java create mode 100644 java/ql/test/stubs/javafx-web/com/zaxxer/hikari/HikariConfigMXBean.java create mode 100644 java/ql/test/stubs/javafx-web/com/zaxxer/hikari/HikariDataSource.java create mode 100644 java/ql/test/stubs/javafx-web/com/zaxxer/hikari/HikariPoolMXBean.java create mode 100644 java/ql/test/stubs/javafx-web/com/zaxxer/hikari/metrics/MetricsTracker.java create mode 100644 java/ql/test/stubs/javafx-web/com/zaxxer/hikari/metrics/MetricsTrackerFactory.java create mode 100644 java/ql/test/stubs/javafx-web/com/zaxxer/hikari/metrics/PoolStats.java create mode 100644 java/ql/test/stubs/javafx-web/io/micrometer/observation/Context.java create mode 100644 java/ql/test/stubs/javafx-web/io/micrometer/observation/ObservationRegistry.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/RuntimeType.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/AsyncInvoker.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/Client.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/ClientBuilder.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/CompletionStageRxInvoker.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/Entity.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/Invocation.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/InvocationCallback.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/RxInvoker.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/SyncInvoker.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/WebTarget.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/CacheControl.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Configurable.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Configuration.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Cookie.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/EntityTag.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Feature.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/FeatureContext.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Form.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/GenericType.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Link.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/MediaType.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/MultivaluedMap.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/NewCookie.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Response.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/UriBuilder.java create mode 100644 java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Variant.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/animation/Interpolatable.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/InvalidationListener.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/Observable.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/binding/Binding.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/binding/BooleanBinding.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/binding/BooleanExpression.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/binding/DoubleBinding.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/binding/DoubleExpression.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/binding/FloatBinding.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/binding/FloatExpression.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/binding/IntegerBinding.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/binding/IntegerExpression.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/binding/LongBinding.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/binding/LongExpression.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/binding/NumberBinding.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/binding/NumberExpression.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/binding/NumberExpressionBase.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/binding/ObjectExpression.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/binding/StringBinding.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/binding/StringExpression.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/property/BooleanProperty.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/property/DoubleProperty.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/property/IntegerProperty.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/property/ObjectProperty.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/property/Property.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyBooleanProperty.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyBooleanPropertyBase.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyDoubleProperty.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyIntegerProperty.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyObjectProperty.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyProperty.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyStringProperty.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/property/StringProperty.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/value/ChangeListener.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableBooleanValue.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableDoubleValue.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableFloatValue.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableIntegerValue.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableLongValue.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableNumberValue.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableObjectValue.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableStringValue.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableValue.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/value/WritableBooleanValue.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/value/WritableDoubleValue.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/value/WritableIntegerValue.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/value/WritableNumberValue.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/value/WritableObjectValue.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/value/WritableStringValue.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/beans/value/WritableValue.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/collections/ListChangeListener.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/collections/MapChangeListener.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/collections/ObservableList.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/collections/ObservableListBase.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/collections/ObservableMap.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/collections/ObservableSet.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/collections/SetChangeListener.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/collections/transformation/FilteredList.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/collections/transformation/SortedList.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/collections/transformation/TransformationList.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/concurrent/Worker.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/css/CssMetaData.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/css/ParsedValue.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/css/PseudoClass.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/css/StyleConverter.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/css/StyleOrigin.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/css/Styleable.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/css/StyleableProperty.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/event/Event.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/event/EventDispatchChain.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/event/EventDispatcher.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/event/EventHandler.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/event/EventTarget.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/event/EventType.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/geometry/Bounds.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/geometry/Insets.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/geometry/NodeOrientation.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/geometry/Orientation.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/geometry/Point2D.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/geometry/Point3D.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/geometry/Rectangle2D.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/print/Collation.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/print/JobSettings.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/print/PageLayout.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/print/PageOrientation.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/print/PageRange.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/print/Paper.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/print/PaperSource.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/print/PrintColor.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/print/PrintQuality.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/print/PrintResolution.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/print/PrintSides.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/print/Printer.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/print/PrinterAttributes.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/print/PrinterJob.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/AccessibleAction.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/AccessibleAttribute.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/AccessibleRole.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/CacheHint.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/Camera.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/Cursor.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/DepthTest.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/Node.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/Parent.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/Scene.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/SceneAntialiasing.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/SnapshotParameters.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/SnapshotResult.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/effect/BlendMode.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/effect/Effect.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/image/Image.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/image/PixelBuffer.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/image/PixelFormat.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/image/PixelReader.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/image/PixelWriter.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/image/WritableImage.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/image/WritablePixelFormat.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/Clipboard.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/ContextMenuEvent.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/DataFormat.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/DragEvent.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/Dragboard.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/GestureEvent.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/InputEvent.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/InputMethodEvent.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/InputMethodHighlight.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/InputMethodRequests.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/InputMethodTextRun.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/KeyCode.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/KeyCombination.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/KeyEvent.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/Mnemonic.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/MouseButton.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/MouseDragEvent.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/MouseEvent.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/PickResult.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/RotateEvent.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/ScrollEvent.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/SwipeEvent.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/TouchEvent.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/TouchPoint.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/TransferMode.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/input/ZoomEvent.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/paint/Color.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/paint/Paint.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/text/Font.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/text/FontPosture.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/text/FontWeight.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/transform/Affine.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/transform/MatrixType.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/transform/Rotate.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/transform/Scale.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/transform/Shear.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/transform/Transform.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/transform/TransformChangedEvent.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/transform/Translate.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/web/PopupFeatures.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/web/PromptData.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/web/WebEngine.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/web/WebErrorEvent.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/web/WebEvent.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/scene/web/WebHistory.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/stage/Window.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/stage/WindowEvent.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/util/Callback.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/util/Duration.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/util/Pair.java create mode 100644 java/ql/test/stubs/javafx-web/javafx/util/StringConverter.java create mode 100644 java/ql/test/stubs/javafx-web/javax/net/ServerSocketFactory.java create mode 100644 java/ql/test/stubs/javafx-web/javax/net/SocketFactory.java create mode 100644 java/ql/test/stubs/javafx-web/javax/net/ssl/HostnameVerifier.java create mode 100644 java/ql/test/stubs/javafx-web/javax/net/ssl/KeyManager.java create mode 100644 java/ql/test/stubs/javafx-web/javax/net/ssl/SNIMatcher.java create mode 100644 java/ql/test/stubs/javafx-web/javax/net/ssl/SNIServerName.java create mode 100644 java/ql/test/stubs/javafx-web/javax/net/ssl/SSLContext.java create mode 100644 java/ql/test/stubs/javafx-web/javax/net/ssl/SSLContextSpi.java create mode 100644 java/ql/test/stubs/javafx-web/javax/net/ssl/SSLEngine.java create mode 100644 java/ql/test/stubs/javafx-web/javax/net/ssl/SSLEngineResult.java create mode 100644 java/ql/test/stubs/javafx-web/javax/net/ssl/SSLParameters.java create mode 100644 java/ql/test/stubs/javafx-web/javax/net/ssl/SSLServerSocketFactory.java create mode 100644 java/ql/test/stubs/javafx-web/javax/net/ssl/SSLSession.java create mode 100644 java/ql/test/stubs/javafx-web/javax/net/ssl/SSLSessionContext.java create mode 100644 java/ql/test/stubs/javafx-web/javax/net/ssl/SSLSocketFactory.java create mode 100644 java/ql/test/stubs/javafx-web/javax/net/ssl/TrustManager.java create mode 100644 java/ql/test/stubs/javafx-web/javax/security/cert/Certificate.java create mode 100644 java/ql/test/stubs/javafx-web/javax/security/cert/X509Certificate.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/AsyncContext.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/AsyncEvent.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/AsyncListener.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/DispatcherType.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/Filter.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/FilterChain.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/FilterConfig.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/FilterRegistration.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/GenericServlet.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/HttpConstraintElement.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/HttpMethodConstraintElement.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/MultipartConfigElement.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/ReadListener.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/Registration.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/RequestDispatcher.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/Servlet.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/ServletConfig.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/ServletContext.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/ServletInputStream.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/ServletOutputStream.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/ServletRegistration.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/ServletRequest.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/ServletResponse.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/ServletSecurityElement.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/SessionCookieConfig.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/SessionTrackingMode.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/WriteListener.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/annotation/HttpConstraint.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/annotation/HttpMethodConstraint.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/annotation/MultipartConfig.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/annotation/ServletSecurity.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/descriptor/JspConfigDescriptor.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/descriptor/JspPropertyGroupDescriptor.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/descriptor/TaglibDescriptor.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/http/Cookie.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/http/HttpServlet.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/http/HttpServletMapping.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/http/HttpServletRequest.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/http/HttpServletResponse.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/http/HttpSession.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/http/HttpSessionContext.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/http/HttpUpgradeHandler.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/http/MappingMatch.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/http/Part.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/http/PushBuilder.java create mode 100644 java/ql/test/stubs/javafx-web/javax/servlet/http/WebConnection.java create mode 100644 java/ql/test/stubs/javafx-web/javax/sql/CommonDataSource.java create mode 100644 java/ql/test/stubs/javafx-web/javax/sql/DataSource.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/RuntimeType.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/client/AsyncInvoker.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/client/Client.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/client/ClientBuilder.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/client/Entity.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/client/Invocation.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/client/InvocationCallback.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/client/SyncInvoker.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/client/WebTarget.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/core/CacheControl.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/core/Configurable.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/core/Configuration.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/core/Cookie.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/core/EntityTag.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/core/Feature.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/core/FeatureContext.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/core/Form.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/core/GenericType.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/core/Link.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/core/MediaType.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/core/MultivaluedMap.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/core/NewCookie.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/core/Response.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/core/UriBuilder.java create mode 100644 java/ql/test/stubs/javafx-web/javax/ws/rs/core/Variant.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/commons/logging/Log.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/Header.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/HeaderElement.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/HeaderIterator.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/HttpClientConnection.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/HttpConnection.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/HttpConnectionMetrics.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/HttpEntity.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/HttpEntityEnclosingRequest.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/HttpHost.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/HttpInetConnection.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/HttpMessage.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/HttpRequest.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/HttpResponse.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/NameValuePair.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/ProtocolVersion.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/RequestLine.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/StatusLine.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/client/config/RequestConfig.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/client/methods/AbortableHttpRequest.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/client/methods/AbstractExecutionAwareRequest.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/client/methods/Configurable.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpDelete.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpEntityEnclosingRequestBase.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpExecutionAware.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpGet.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpHead.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpOptions.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpPatch.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpPost.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpPut.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpRequestBase.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpTrace.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpUriRequest.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/client/methods/RequestBuilder.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/concurrent/Cancellable.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/conn/ClientConnectionRequest.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/conn/ConnectionReleaseTrigger.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/conn/HttpRoutedConnection.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/conn/ManagedClientConnection.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/conn/ManagedHttpClientConnection.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/conn/routing/HttpRoute.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/conn/routing/RouteInfo.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/message/AbstractHttpMessage.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/message/BasicHttpEntityEnclosingRequest.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/message/BasicHttpRequest.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/message/BasicRequestLine.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/message/HeaderGroup.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/params/HttpParams.java create mode 100644 java/ql/test/stubs/javafx-web/org/apache/http/protocol/HttpContext.java create mode 100644 java/ql/test/stubs/javafx-web/org/codehaus/cargo/container/installer/Installer.java create mode 100644 java/ql/test/stubs/javafx-web/org/codehaus/cargo/container/installer/Proxy.java create mode 100644 java/ql/test/stubs/javafx-web/org/codehaus/cargo/container/installer/ZipURLInstaller.java create mode 100644 java/ql/test/stubs/javafx-web/org/codehaus/cargo/util/FileHandler.java create mode 100644 java/ql/test/stubs/javafx-web/org/codehaus/cargo/util/XmlReplacement.java create mode 100644 java/ql/test/stubs/javafx-web/org/codehaus/cargo/util/log/LogLevel.java create mode 100644 java/ql/test/stubs/javafx-web/org/codehaus/cargo/util/log/Loggable.java create mode 100644 java/ql/test/stubs/javafx-web/org/codehaus/cargo/util/log/LoggedObject.java create mode 100644 java/ql/test/stubs/javafx-web/org/codehaus/cargo/util/log/Logger.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/ConnectionFactory.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/Handle.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/HandleCallback.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/HandleConsumer.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/HandleListener.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/Jdbi.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/argument/Argument.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/argument/ArgumentFactory.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/argument/NamedArgumentFinder.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/argument/QualifiedArgumentFactory.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/argument/internal/NamedArgumentFinderFactory.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/array/SqlArrayArgumentStrategy.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/array/SqlArrayType.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/array/SqlArrayTypeFactory.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/codec/Codec.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/codec/CodecFactory.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/collector/CollectorFactory.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/config/ConfigRegistry.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/config/Configurable.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/config/JdbiConfig.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/extension/ExtensionCallback.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/extension/ExtensionConsumer.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/extension/ExtensionContext.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/extension/ExtensionFactory.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/extension/ExtensionMethod.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/extension/HandleSupplier.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/generic/GenericType.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/mapper/ColumnMapper.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/mapper/ColumnMapperFactory.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/mapper/QualifiedColumnMapperFactory.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/mapper/RowMapper.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/mapper/RowMapperFactory.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/mapper/RowViewMapper.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/qualifier/QualifiedType.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/BatchResultBearing.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/BatchResultIterable.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/IteratorCallback.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/IteratorConsumer.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/ResultBearing.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/ResultIterable.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/ResultIterator.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/ResultProducer.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/ResultSetAccumulator.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/ResultSetScanner.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/RowReducer.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/RowView.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/StreamCallback.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/StreamConsumer.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/spi/JdbiPlugin.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/BaseStatement.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Batch.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Binding.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Call.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/CallableStatementMapper.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Cleanable.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/MetaData.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/OutParameters.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/ParsedParameters.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/ParsedSql.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/PreparedBatch.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Query.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Script.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/SqlLogger.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/SqlParser.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/SqlStatement.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/StatementBuilder.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/StatementBuilderFactory.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/StatementContext.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/StatementCustomizer.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/TemplateEngine.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/TimingCollector.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Update.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/internal/PreparedBinding.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/transaction/TransactionHandler.java create mode 100644 java/ql/test/stubs/javafx-web/org/jdbi/v3/core/transaction/TransactionIsolationLevel.java create mode 100644 java/ql/test/stubs/javafx-web/org/postgresql/Driver.java create mode 100644 java/ql/test/stubs/javafx-web/org/postgresql/util/SharedTimer.java create mode 100644 java/ql/test/stubs/javafx-web/org/reactivestreams/Publisher.java create mode 100644 java/ql/test/stubs/javafx-web/org/reactivestreams/Subscriber.java create mode 100644 java/ql/test/stubs/javafx-web/org/reactivestreams/Subscription.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/boot/jdbc/DataSourceBuilder.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/core/MethodParameter.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/core/NestedRuntimeException.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/core/ParameterNameDiscoverer.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/core/ParameterizedTypeReference.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/core/ResolvableType.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/core/codec/Decoder.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/core/codec/Encoder.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/core/io/InputStreamSource.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/core/io/Resource.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/core/io/buffer/DataBuffer.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/core/io/buffer/DataBufferFactory.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/core/io/support/ResourceRegion.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/CacheControl.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/ContentDisposition.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/HttpCookie.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/HttpEntity.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/HttpHeaders.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/HttpInputMessage.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/HttpMessage.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/HttpMethod.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/HttpOutputMessage.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/HttpRange.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/HttpRequest.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/HttpStatus.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/HttpStatusCode.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/MediaType.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/ReactiveHttpInputMessage.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/ReactiveHttpOutputMessage.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/RequestEntity.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/ResponseCookie.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/ResponseEntity.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/client/ClientHttpRequest.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/client/ClientHttpRequestExecution.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/client/ClientHttpRequestFactory.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/client/ClientHttpRequestInitializer.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/client/ClientHttpRequestInterceptor.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/client/ClientHttpResponse.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/client/reactive/ClientHttpConnector.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/client/reactive/ClientHttpRequest.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/client/reactive/ClientHttpResponse.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/client/support/HttpAccessor.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/client/support/InterceptingHttpAccessor.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/codec/ClientCodecConfigurer.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/codec/CodecConfigurer.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/codec/HttpMessageReader.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/codec/HttpMessageWriter.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/converter/HttpMessageConverter.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/server/PathContainer.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/server/RequestPath.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/server/reactive/ServerHttpRequest.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/server/reactive/ServerHttpResponse.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/http/server/reactive/SslInfo.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/jdbc/datasource/AbstractDataSource.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/jdbc/datasource/AbstractDriverBasedDataSource.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/jdbc/datasource/DriverManagerDataSource.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/util/MimeType.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/util/MultiValueMap.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/web/client/RequestCallback.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/web/client/ResponseErrorHandler.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/web/client/ResponseExtractor.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/web/client/RestClientException.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/web/client/RestOperations.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/web/client/RestTemplate.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/web/reactive/function/BodyExtractor.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/web/reactive/function/BodyInserter.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/web/reactive/function/client/ClientRequest.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/web/reactive/function/client/ClientRequestObservationConvention.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/web/reactive/function/client/ClientResponse.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/web/reactive/function/client/ExchangeFilterFunction.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/web/reactive/function/client/ExchangeFunction.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/web/reactive/function/client/ExchangeStrategies.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/web/reactive/function/client/WebClient.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/web/reactive/function/client/WebClientException.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/web/reactive/function/client/WebClientResponseException.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/web/util/UriBuilder.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/web/util/UriBuilderFactory.java create mode 100644 java/ql/test/stubs/javafx-web/org/springframework/web/util/UriTemplateHandler.java create mode 100644 java/ql/test/stubs/javafx-web/org/w3c/dom/Attr.java create mode 100644 java/ql/test/stubs/javafx-web/org/w3c/dom/CDATASection.java create mode 100644 java/ql/test/stubs/javafx-web/org/w3c/dom/CharacterData.java create mode 100644 java/ql/test/stubs/javafx-web/org/w3c/dom/Comment.java create mode 100644 java/ql/test/stubs/javafx-web/org/w3c/dom/DOMConfiguration.java create mode 100644 java/ql/test/stubs/javafx-web/org/w3c/dom/DOMImplementation.java create mode 100644 java/ql/test/stubs/javafx-web/org/w3c/dom/DOMStringList.java create mode 100644 java/ql/test/stubs/javafx-web/org/w3c/dom/Document.java create mode 100644 java/ql/test/stubs/javafx-web/org/w3c/dom/DocumentFragment.java create mode 100644 java/ql/test/stubs/javafx-web/org/w3c/dom/DocumentType.java create mode 100644 java/ql/test/stubs/javafx-web/org/w3c/dom/Element.java create mode 100644 java/ql/test/stubs/javafx-web/org/w3c/dom/EntityReference.java create mode 100644 java/ql/test/stubs/javafx-web/org/w3c/dom/NamedNodeMap.java create mode 100644 java/ql/test/stubs/javafx-web/org/w3c/dom/Node.java create mode 100644 java/ql/test/stubs/javafx-web/org/w3c/dom/NodeList.java create mode 100644 java/ql/test/stubs/javafx-web/org/w3c/dom/ProcessingInstruction.java create mode 100644 java/ql/test/stubs/javafx-web/org/w3c/dom/Text.java create mode 100644 java/ql/test/stubs/javafx-web/org/w3c/dom/TypeInfo.java create mode 100644 java/ql/test/stubs/javafx-web/org/w3c/dom/UserDataHandler.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/core/CorePublisher.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/core/CoreSubscriber.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/core/Disposable.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/core/observability/SignalListener.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/core/observability/SignalListenerFactory.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/core/publisher/BufferOverflowStrategy.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/core/publisher/ConnectableFlux.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/core/publisher/Flux.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/core/publisher/FluxSink.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/core/publisher/GroupedFlux.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/core/publisher/Mono.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/core/publisher/MonoSink.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/core/publisher/ParallelFlux.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/core/publisher/Signal.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/core/publisher/SignalType.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/core/publisher/SynchronousSink.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/core/publisher/Timed.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/core/scheduler/Scheduler.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/util/Logger.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/util/context/Context.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/util/context/ContextView.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/util/function/Tuple2.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/util/function/Tuple3.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/util/function/Tuple4.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/util/function/Tuple5.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/util/function/Tuple6.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/util/function/Tuple7.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/util/function/Tuple8.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/util/retry/Retry.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/util/retry/RetryBackoffSpec.java create mode 100644 java/ql/test/stubs/javafx-web/reactor/util/retry/RetrySpec.java diff --git a/java/ql/test/stubs/cargo/org/codehaus/cargo/container/installer/Installer.java b/java/ql/test/stubs/cargo/org/codehaus/cargo/container/installer/Installer.java new file mode 100644 index 00000000000..02abcd95563 --- /dev/null +++ b/java/ql/test/stubs/cargo/org/codehaus/cargo/container/installer/Installer.java @@ -0,0 +1,11 @@ +// Generated automatically from org.codehaus.cargo.container.installer.Installer for testing purposes + +package org.codehaus.cargo.container.installer; + +import org.codehaus.cargo.util.log.Loggable; + +public interface Installer extends Loggable +{ + String getHome(); + void install(); +} diff --git a/java/ql/test/stubs/cargo/org/codehaus/cargo/container/installer/Proxy.java b/java/ql/test/stubs/cargo/org/codehaus/cargo/container/installer/Proxy.java new file mode 100644 index 00000000000..de5da1c1766 --- /dev/null +++ b/java/ql/test/stubs/cargo/org/codehaus/cargo/container/installer/Proxy.java @@ -0,0 +1,23 @@ +// Generated automatically from org.codehaus.cargo.container.installer.Proxy for testing purposes + +package org.codehaus.cargo.container.installer; + +import java.util.Map; +import org.codehaus.cargo.util.log.LoggedObject; + +public class Proxy extends LoggedObject +{ + public Map configure(){ return null; } + public Proxy(){} + public String getExcludeHosts(){ return null; } + public String getHost(){ return null; } + public String getPassword(){ return null; } + public String getUser(){ return null; } + public int getPort(){ return 0; } + public void clear(Map p0){} + public void setExcludeHosts(String p0){} + public void setHost(String p0){} + public void setPassword(String p0){} + public void setPort(int p0){} + public void setUser(String p0){} +} diff --git a/java/ql/test/stubs/cargo/org/codehaus/cargo/container/installer/ZipURLInstaller.java b/java/ql/test/stubs/cargo/org/codehaus/cargo/container/installer/ZipURLInstaller.java new file mode 100644 index 00000000000..638a19d89fc --- /dev/null +++ b/java/ql/test/stubs/cargo/org/codehaus/cargo/container/installer/ZipURLInstaller.java @@ -0,0 +1,34 @@ +// Generated automatically from org.codehaus.cargo.container.installer.ZipURLInstaller for testing purposes + +package org.codehaus.cargo.container.installer; + +import java.net.URL; +import org.codehaus.cargo.container.installer.Installer; +import org.codehaus.cargo.container.installer.Proxy; +import org.codehaus.cargo.util.FileHandler; +import org.codehaus.cargo.util.log.LoggedObject; +import org.codehaus.cargo.util.log.Logger; + +public class ZipURLInstaller extends LoggedObject implements Installer +{ + protected ZipURLInstaller() {} + protected String getSourceFileName(){ return null; } + protected void doDownload(){} + public FileHandler getFileHandler(){ return null; } + public String getDownloadDir(){ return null; } + public String getDownloadFile(){ return null; } + public String getExtractDir(){ return null; } + public String getHome(){ return null; } + public ZipURLInstaller(URL p0){} + public ZipURLInstaller(URL p0, String p1, String p2){} + public boolean isAlreadyDownloaded(){ return false; } + public boolean isAlreadyExtracted(){ return false; } + public void download(){} + public void install(){} + public void registerInstallation(){} + public void setDownloadDir(String p0){} + public void setExtractDir(String p0){} + public void setFileHandler(FileHandler p0){} + public void setLogger(Logger p0){} + public void setProxy(Proxy p0){} +} diff --git a/java/ql/test/stubs/cargo/org/codehaus/cargo/util/FileHandler.java b/java/ql/test/stubs/cargo/org/codehaus/cargo/util/FileHandler.java new file mode 100644 index 00000000000..07579277d95 --- /dev/null +++ b/java/ql/test/stubs/cargo/org/codehaus/cargo/util/FileHandler.java @@ -0,0 +1,49 @@ +// Generated automatically from org.codehaus.cargo.util.FileHandler for testing purposes + +package org.codehaus.cargo.util; + +import java.io.InputStream; +import java.io.OutputStream; +import java.nio.charset.Charset; +import java.util.List; +import java.util.Map; +import org.codehaus.cargo.util.XmlReplacement; +import org.codehaus.cargo.util.log.Loggable; + +public interface FileHandler extends Loggable +{ + InputStream getInputStream(String p0); + OutputStream getOutputStream(String p0); + String append(String p0, String p1); + String createDirectory(String p0, String p1); + String createUniqueTmpDirectory(); + String getAbsolutePath(String p0); + String getName(String p0); + String getParent(String p0); + String getTmpPath(String p0); + String getURL(String p0); + String readTextFile(String p0, Charset p1); + String[] getChildren(String p0); + String[] getChildren(String p0, List p1); + boolean exists(String p0); + boolean isDirectory(String p0); + boolean isDirectoryEmpty(String p0); + long getSize(String p0); + static String NEW_LINE = null; + void copy(InputStream p0, OutputStream p1); + void copy(InputStream p0, OutputStream p1, int p2); + void copyDirectory(String p0, String p1); + void copyDirectory(String p0, String p1, List p2); + void copyDirectory(String p0, String p1, Map p2, Charset p3); + void copyFile(String p0, String p1); + void copyFile(String p0, String p1, Map p2, Charset p3); + void copyFile(String p0, String p1, boolean p2); + void createFile(String p0); + void delete(String p0); + void explode(String p0, String p1); + void mkdirs(String p0); + void replaceInFile(String p0, Map p1, Charset p2); + void replaceInFile(String p0, Map p1, Charset p2, boolean p3); + void replaceInXmlFile(XmlReplacement... p0); + void writeTextFile(String p0, String p1, Charset p2); +} diff --git a/java/ql/test/stubs/cargo/org/codehaus/cargo/util/XmlReplacement.java b/java/ql/test/stubs/cargo/org/codehaus/cargo/util/XmlReplacement.java new file mode 100644 index 00000000000..16caa14f2b8 --- /dev/null +++ b/java/ql/test/stubs/cargo/org/codehaus/cargo/util/XmlReplacement.java @@ -0,0 +1,28 @@ +// Generated automatically from org.codehaus.cargo.util.XmlReplacement for testing purposes + +package org.codehaus.cargo.util; + + +public class XmlReplacement +{ + public String getAttributeName(){ return null; } + public String getFile(){ return null; } + public String getValue(){ return null; } + public String getXpathExpression(){ return null; } + public String toString(){ return null; } + public XmlReplacement(){} + public XmlReplacement(String p0, String p1, String p2, XmlReplacement.ReplacementBehavior p3, String p4){} + public XmlReplacement.ReplacementBehavior getReplacementBehavior(){ return null; } + public boolean equals(Object p0){ return false; } + public int hashCode(){ return 0; } + public void setAttributeName(String p0){} + public void setFile(String p0){} + public void setReplacementBehavior(XmlReplacement.ReplacementBehavior p0){} + public void setValue(String p0){} + public void setXpathExpression(String p0){} + static public enum ReplacementBehavior + { + ADD_MISSING_NODES, IGNORE_IF_NON_EXISTING, THROW_EXCEPTION; + private ReplacementBehavior() {} + } +} diff --git a/java/ql/test/stubs/cargo/org/codehaus/cargo/util/log/LogLevel.java b/java/ql/test/stubs/cargo/org/codehaus/cargo/util/log/LogLevel.java new file mode 100644 index 00000000000..b7b0d5a37d8 --- /dev/null +++ b/java/ql/test/stubs/cargo/org/codehaus/cargo/util/log/LogLevel.java @@ -0,0 +1,18 @@ +// Generated automatically from org.codehaus.cargo.util.log.LogLevel for testing purposes + +package org.codehaus.cargo.util.log; + + +public class LogLevel implements Comparable +{ + protected LogLevel() {} + public String getLevel(){ return null; } + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public int compareTo(LogLevel p0){ return 0; } + public int hashCode(){ return 0; } + public static LogLevel DEBUG = null; + public static LogLevel INFO = null; + public static LogLevel WARN = null; + public static LogLevel toLevel(String p0){ return null; } +} diff --git a/java/ql/test/stubs/cargo/org/codehaus/cargo/util/log/Loggable.java b/java/ql/test/stubs/cargo/org/codehaus/cargo/util/log/Loggable.java new file mode 100644 index 00000000000..3369fa27ef5 --- /dev/null +++ b/java/ql/test/stubs/cargo/org/codehaus/cargo/util/log/Loggable.java @@ -0,0 +1,11 @@ +// Generated automatically from org.codehaus.cargo.util.log.Loggable for testing purposes + +package org.codehaus.cargo.util.log; + +import org.codehaus.cargo.util.log.Logger; + +public interface Loggable +{ + Logger getLogger(); + void setLogger(Logger p0); +} diff --git a/java/ql/test/stubs/cargo/org/codehaus/cargo/util/log/LoggedObject.java b/java/ql/test/stubs/cargo/org/codehaus/cargo/util/log/LoggedObject.java new file mode 100644 index 00000000000..421da028778 --- /dev/null +++ b/java/ql/test/stubs/cargo/org/codehaus/cargo/util/log/LoggedObject.java @@ -0,0 +1,13 @@ +// Generated automatically from org.codehaus.cargo.util.log.LoggedObject for testing purposes + +package org.codehaus.cargo.util.log; + +import org.codehaus.cargo.util.log.Loggable; +import org.codehaus.cargo.util.log.Logger; + +public class LoggedObject implements Loggable +{ + public LoggedObject(){} + public Logger getLogger(){ return null; } + public void setLogger(Logger p0){} +} diff --git a/java/ql/test/stubs/cargo/org/codehaus/cargo/util/log/Logger.java b/java/ql/test/stubs/cargo/org/codehaus/cargo/util/log/Logger.java new file mode 100644 index 00000000000..965e4bc1ccd --- /dev/null +++ b/java/ql/test/stubs/cargo/org/codehaus/cargo/util/log/Logger.java @@ -0,0 +1,14 @@ +// Generated automatically from org.codehaus.cargo.util.log.Logger for testing purposes + +package org.codehaus.cargo.util.log; + +import org.codehaus.cargo.util.log.LogLevel; + +public interface Logger +{ + LogLevel getLevel(); + void debug(String p0, String p1); + void info(String p0, String p1); + void setLevel(LogLevel p0); + void warn(String p0, String p1); +} diff --git a/java/ql/test/stubs/javafx-web/com/sun/javafx/tk/TKClipboard.java b/java/ql/test/stubs/javafx-web/com/sun/javafx/tk/TKClipboard.java new file mode 100644 index 00000000000..36d910d98ba --- /dev/null +++ b/java/ql/test/stubs/javafx-web/com/sun/javafx/tk/TKClipboard.java @@ -0,0 +1,26 @@ +// Generated automatically from com.sun.javafx.tk.TKClipboard for testing purposes + +package com.sun.javafx.tk; + +import java.security.AccessControlContext; +import java.util.Set; +import javafx.scene.image.Image; +import javafx.scene.input.DataFormat; +import javafx.scene.input.TransferMode; +import javafx.util.Pair; + +public interface TKClipboard +{ + Image getDragView(); + Object getContent(DataFormat p0); + Set getContentTypes(); + Set getTransferModes(); + boolean hasContent(DataFormat p0); + boolean putContent(Pair... p0); + double getDragViewOffsetX(); + double getDragViewOffsetY(); + void setDragView(Image p0); + void setDragViewOffsetX(double p0); + void setDragViewOffsetY(double p0); + void setSecurityContext(AccessControlContext p0); +} diff --git a/java/ql/test/stubs/javafx-web/com/sun/javafx/tk/TKDragGestureListener.java b/java/ql/test/stubs/javafx-web/com/sun/javafx/tk/TKDragGestureListener.java new file mode 100644 index 00000000000..01877fec3e7 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/com/sun/javafx/tk/TKDragGestureListener.java @@ -0,0 +1,10 @@ +// Generated automatically from com.sun.javafx.tk.TKDragGestureListener for testing purposes + +package com.sun.javafx.tk; + +import com.sun.javafx.tk.TKClipboard; + +public interface TKDragGestureListener +{ + void dragGestureRecognized(double p0, double p1, double p2, double p3, int p4, TKClipboard p5); +} diff --git a/java/ql/test/stubs/javafx-web/com/sun/javafx/tk/TKPulseListener.java b/java/ql/test/stubs/javafx-web/com/sun/javafx/tk/TKPulseListener.java new file mode 100644 index 00000000000..f381217d017 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/com/sun/javafx/tk/TKPulseListener.java @@ -0,0 +1,9 @@ +// Generated automatically from com.sun.javafx.tk.TKPulseListener for testing purposes + +package com.sun.javafx.tk; + + +public interface TKPulseListener +{ + void pulse(); +} diff --git a/java/ql/test/stubs/javafx-web/com/zaxxer/hikari/HikariConfig.java b/java/ql/test/stubs/javafx-web/com/zaxxer/hikari/HikariConfig.java new file mode 100644 index 00000000000..a4ff001fcb7 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/com/zaxxer/hikari/HikariConfig.java @@ -0,0 +1,93 @@ +// Generated automatically from com.zaxxer.hikari.HikariConfig for testing purposes + +package com.zaxxer.hikari; + +import com.zaxxer.hikari.HikariConfigMXBean; +import com.zaxxer.hikari.metrics.MetricsTrackerFactory; +import java.util.Properties; +import java.util.concurrent.ScheduledExecutorService; +import java.util.concurrent.ScheduledThreadPoolExecutor; +import java.util.concurrent.ThreadFactory; +import javax.sql.DataSource; + +public class HikariConfig implements HikariConfigMXBean +{ + protected void loadProperties(String p0){} + public DataSource getDataSource(){ return null; } + public HikariConfig(){} + public HikariConfig(Properties p0){} + public HikariConfig(String p0){} + public MetricsTrackerFactory getMetricsTrackerFactory(){ return null; } + public Object getHealthCheckRegistry(){ return null; } + public Object getMetricRegistry(){ return null; } + public Properties getDataSourceProperties(){ return null; } + public Properties getHealthCheckProperties(){ return null; } + public ScheduledExecutorService getScheduledExecutor(){ return null; } + public ScheduledThreadPoolExecutor getScheduledExecutorService(){ return null; } + public String getCatalog(){ return null; } + public String getConnectionInitSql(){ return null; } + public String getConnectionTestQuery(){ return null; } + public String getDataSourceClassName(){ return null; } + public String getDataSourceJNDI(){ return null; } + public String getDriverClassName(){ return null; } + public String getJdbcUrl(){ return null; } + public String getPassword(){ return null; } + public String getPoolName(){ return null; } + public String getTransactionIsolation(){ return null; } + public String getUsername(){ return null; } + public ThreadFactory getThreadFactory(){ return null; } + public boolean isAllowPoolSuspension(){ return false; } + public boolean isAutoCommit(){ return false; } + public boolean isInitializationFailFast(){ return false; } + public boolean isIsolateInternalQueries(){ return false; } + public boolean isJdbc4ConnectionTest(){ return false; } + public boolean isReadOnly(){ return false; } + public boolean isRegisterMbeans(){ return false; } + public int getMaximumPoolSize(){ return 0; } + public int getMinimumIdle(){ return 0; } + public long getConnectionTimeout(){ return 0; } + public long getIdleTimeout(){ return 0; } + public long getInitializationFailTimeout(){ return 0; } + public long getLeakDetectionThreshold(){ return 0; } + public long getMaxLifetime(){ return 0; } + public long getValidationTimeout(){ return 0; } + public void addDataSourceProperty(String p0, Object p1){} + public void addHealthCheckProperty(String p0, String p1){} + public void copyState(HikariConfig p0){} + public void setAllowPoolSuspension(boolean p0){} + public void setAutoCommit(boolean p0){} + public void setCatalog(String p0){} + public void setConnectionInitSql(String p0){} + public void setConnectionTestQuery(String p0){} + public void setConnectionTimeout(long p0){} + public void setDataSource(DataSource p0){} + public void setDataSourceClassName(String p0){} + public void setDataSourceJNDI(String p0){} + public void setDataSourceProperties(Properties p0){} + public void setDriverClassName(String p0){} + public void setHealthCheckProperties(Properties p0){} + public void setHealthCheckRegistry(Object p0){} + public void setIdleTimeout(long p0){} + public void setInitializationFailFast(boolean p0){} + public void setInitializationFailTimeout(long p0){} + public void setIsolateInternalQueries(boolean p0){} + public void setJdbc4ConnectionTest(boolean p0){} + public void setJdbcUrl(String p0){} + public void setLeakDetectionThreshold(long p0){} + public void setMaxLifetime(long p0){} + public void setMaximumPoolSize(int p0){} + public void setMetricRegistry(Object p0){} + public void setMetricsTrackerFactory(MetricsTrackerFactory p0){} + public void setMinimumIdle(int p0){} + public void setPassword(String p0){} + public void setPoolName(String p0){} + public void setReadOnly(boolean p0){} + public void setRegisterMbeans(boolean p0){} + public void setScheduledExecutor(ScheduledExecutorService p0){} + public void setScheduledExecutorService(ScheduledThreadPoolExecutor p0){} + public void setThreadFactory(ThreadFactory p0){} + public void setTransactionIsolation(String p0){} + public void setUsername(String p0){} + public void setValidationTimeout(long p0){} + public void validate(){} +} diff --git a/java/ql/test/stubs/javafx-web/com/zaxxer/hikari/HikariConfigMXBean.java b/java/ql/test/stubs/javafx-web/com/zaxxer/hikari/HikariConfigMXBean.java new file mode 100644 index 00000000000..5d03182f84a --- /dev/null +++ b/java/ql/test/stubs/javafx-web/com/zaxxer/hikari/HikariConfigMXBean.java @@ -0,0 +1,25 @@ +// Generated automatically from com.zaxxer.hikari.HikariConfigMXBean for testing purposes + +package com.zaxxer.hikari; + + +public interface HikariConfigMXBean +{ + String getPoolName(); + int getMaximumPoolSize(); + int getMinimumIdle(); + long getConnectionTimeout(); + long getIdleTimeout(); + long getLeakDetectionThreshold(); + long getMaxLifetime(); + long getValidationTimeout(); + void setConnectionTimeout(long p0); + void setIdleTimeout(long p0); + void setLeakDetectionThreshold(long p0); + void setMaxLifetime(long p0); + void setMaximumPoolSize(int p0); + void setMinimumIdle(int p0); + void setPassword(String p0); + void setUsername(String p0); + void setValidationTimeout(long p0); +} diff --git a/java/ql/test/stubs/javafx-web/com/zaxxer/hikari/HikariDataSource.java b/java/ql/test/stubs/javafx-web/com/zaxxer/hikari/HikariDataSource.java new file mode 100644 index 00000000000..e81f7c654f0 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/com/zaxxer/hikari/HikariDataSource.java @@ -0,0 +1,40 @@ +// Generated automatically from com.zaxxer.hikari.HikariDataSource for testing purposes + +package com.zaxxer.hikari; + +import com.zaxxer.hikari.HikariConfig; +import com.zaxxer.hikari.HikariConfigMXBean; +import com.zaxxer.hikari.HikariPoolMXBean; +import com.zaxxer.hikari.metrics.MetricsTrackerFactory; +import java.io.Closeable; +import java.io.PrintWriter; +import java.sql.Connection; +import java.util.logging.Logger; +import javax.sql.DataSource; + +public class HikariDataSource extends HikariConfig implements Closeable, DataSource +{ + public T unwrap(java.lang.Class p0){ return null; } + public Connection getConnection(){ return null; } + public Connection getConnection(String p0, String p1){ return null; } + public HikariConfigMXBean getHikariConfigMXBean(){ return null; } + public HikariDataSource(){} + public HikariDataSource(HikariConfig p0){} + public HikariPoolMXBean getHikariPoolMXBean(){ return null; } + public Logger getParentLogger(){ return null; } + public PrintWriter getLogWriter(){ return null; } + public String toString(){ return null; } + public boolean isClosed(){ return false; } + public boolean isWrapperFor(Class p0){ return false; } + public int getLoginTimeout(){ return 0; } + public void close(){} + public void evictConnection(Connection p0){} + public void resumePool(){} + public void setHealthCheckRegistry(Object p0){} + public void setLogWriter(PrintWriter p0){} + public void setLoginTimeout(int p0){} + public void setMetricRegistry(Object p0){} + public void setMetricsTrackerFactory(MetricsTrackerFactory p0){} + public void shutdown(){} + public void suspendPool(){} +} diff --git a/java/ql/test/stubs/javafx-web/com/zaxxer/hikari/HikariPoolMXBean.java b/java/ql/test/stubs/javafx-web/com/zaxxer/hikari/HikariPoolMXBean.java new file mode 100644 index 00000000000..25b499bca19 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/com/zaxxer/hikari/HikariPoolMXBean.java @@ -0,0 +1,15 @@ +// Generated automatically from com.zaxxer.hikari.HikariPoolMXBean for testing purposes + +package com.zaxxer.hikari; + + +public interface HikariPoolMXBean +{ + int getActiveConnections(); + int getIdleConnections(); + int getThreadsAwaitingConnection(); + int getTotalConnections(); + void resumePool(); + void softEvictConnections(); + void suspendPool(); +} diff --git a/java/ql/test/stubs/javafx-web/com/zaxxer/hikari/metrics/MetricsTracker.java b/java/ql/test/stubs/javafx-web/com/zaxxer/hikari/metrics/MetricsTracker.java new file mode 100644 index 00000000000..5dcb6100c24 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/com/zaxxer/hikari/metrics/MetricsTracker.java @@ -0,0 +1,13 @@ +// Generated automatically from com.zaxxer.hikari.metrics.MetricsTracker for testing purposes + +package com.zaxxer.hikari.metrics; + + +public class MetricsTracker implements AutoCloseable +{ + public MetricsTracker(){} + public void close(){} + public void recordConnectionAcquiredNanos(long p0){} + public void recordConnectionTimeout(){} + public void recordConnectionUsageMillis(long p0){} +} diff --git a/java/ql/test/stubs/javafx-web/com/zaxxer/hikari/metrics/MetricsTrackerFactory.java b/java/ql/test/stubs/javafx-web/com/zaxxer/hikari/metrics/MetricsTrackerFactory.java new file mode 100644 index 00000000000..ee70d6a542c --- /dev/null +++ b/java/ql/test/stubs/javafx-web/com/zaxxer/hikari/metrics/MetricsTrackerFactory.java @@ -0,0 +1,11 @@ +// Generated automatically from com.zaxxer.hikari.metrics.MetricsTrackerFactory for testing purposes + +package com.zaxxer.hikari.metrics; + +import com.zaxxer.hikari.metrics.MetricsTracker; +import com.zaxxer.hikari.metrics.PoolStats; + +public interface MetricsTrackerFactory +{ + MetricsTracker create(String p0, PoolStats p1); +} diff --git a/java/ql/test/stubs/javafx-web/com/zaxxer/hikari/metrics/PoolStats.java b/java/ql/test/stubs/javafx-web/com/zaxxer/hikari/metrics/PoolStats.java new file mode 100644 index 00000000000..98b7871d56b --- /dev/null +++ b/java/ql/test/stubs/javafx-web/com/zaxxer/hikari/metrics/PoolStats.java @@ -0,0 +1,19 @@ +// Generated automatically from com.zaxxer.hikari.metrics.PoolStats for testing purposes + +package com.zaxxer.hikari.metrics; + + +abstract public class PoolStats +{ + protected PoolStats() {} + protected abstract void update(); + protected int activeConnections = 0; + protected int idleConnections = 0; + protected int pendingThreads = 0; + protected int totalConnections = 0; + public PoolStats(long p0){} + public int getActiveConnections(){ return 0; } + public int getIdleConnections(){ return 0; } + public int getPendingThreads(){ return 0; } + public int getTotalConnections(){ return 0; } +} diff --git a/java/ql/test/stubs/javafx-web/io/micrometer/observation/Context.java b/java/ql/test/stubs/javafx-web/io/micrometer/observation/Context.java new file mode 100644 index 00000000000..4d207214807 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/io/micrometer/observation/Context.java @@ -0,0 +1,9 @@ +// Generated automatically from io.micrometer.observation.Context for testing purposes + +package io.micrometer.observation; + + +public class Context +{ + protected Context() {} +} diff --git a/java/ql/test/stubs/javafx-web/io/micrometer/observation/ObservationRegistry.java b/java/ql/test/stubs/javafx-web/io/micrometer/observation/ObservationRegistry.java new file mode 100644 index 00000000000..64187242e84 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/io/micrometer/observation/ObservationRegistry.java @@ -0,0 +1,9 @@ +// Generated automatically from io.micrometer.observation.ObservationRegistry for testing purposes + +package io.micrometer.observation; + + +public class ObservationRegistry +{ + protected ObservationRegistry() {} +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/RuntimeType.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/RuntimeType.java new file mode 100644 index 00000000000..76edb9fd512 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/RuntimeType.java @@ -0,0 +1,10 @@ +// Generated automatically from jakarta.ws.rs.RuntimeType for testing purposes + +package jakarta.ws.rs; + + +public enum RuntimeType +{ + CLIENT, SERVER; + private RuntimeType() {} +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/AsyncInvoker.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/AsyncInvoker.java new file mode 100644 index 00000000000..d96a2e6fecc --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/AsyncInvoker.java @@ -0,0 +1,47 @@ +// Generated automatically from jakarta.ws.rs.client.AsyncInvoker for testing purposes + +package jakarta.ws.rs.client; + +import jakarta.ws.rs.client.Entity; +import jakarta.ws.rs.client.InvocationCallback; +import jakarta.ws.rs.core.GenericType; +import jakarta.ws.rs.core.Response; +import java.util.concurrent.Future; + +public interface AsyncInvoker +{ + java.util.concurrent.Future delete(jakarta.ws.rs.client.InvocationCallback p0); + java.util.concurrent.Future delete(jakarta.ws.rs.core.GenericType p0); + java.util.concurrent.Future delete(java.lang.Class p0); + java.util.concurrent.Future get(jakarta.ws.rs.client.InvocationCallback p0); + java.util.concurrent.Future get(jakarta.ws.rs.core.GenericType p0); + java.util.concurrent.Future get(java.lang.Class p0); + java.util.concurrent.Future method(String p0, Entity p1, jakarta.ws.rs.client.InvocationCallback p2); + java.util.concurrent.Future method(String p0, Entity p1, jakarta.ws.rs.core.GenericType p2); + java.util.concurrent.Future method(String p0, Entity p1, java.lang.Class p2); + java.util.concurrent.Future method(String p0, jakarta.ws.rs.client.InvocationCallback p1); + java.util.concurrent.Future method(String p0, jakarta.ws.rs.core.GenericType p1); + java.util.concurrent.Future method(String p0, java.lang.Class p1); + java.util.concurrent.Future options(jakarta.ws.rs.client.InvocationCallback p0); + java.util.concurrent.Future options(jakarta.ws.rs.core.GenericType p0); + java.util.concurrent.Future options(java.lang.Class p0); + java.util.concurrent.Future post(Entity p0, jakarta.ws.rs.client.InvocationCallback p1); + java.util.concurrent.Future post(Entity p0, jakarta.ws.rs.core.GenericType p1); + java.util.concurrent.Future post(Entity p0, java.lang.Class p1); + java.util.concurrent.Future put(Entity p0, jakarta.ws.rs.client.InvocationCallback p1); + java.util.concurrent.Future put(Entity p0, jakarta.ws.rs.core.GenericType p1); + java.util.concurrent.Future put(Entity p0, java.lang.Class p1); + java.util.concurrent.Future trace(jakarta.ws.rs.client.InvocationCallback p0); + java.util.concurrent.Future trace(jakarta.ws.rs.core.GenericType p0); + java.util.concurrent.Future trace(java.lang.Class p0); + java.util.concurrent.Future delete(); + java.util.concurrent.Future get(); + java.util.concurrent.Future head(); + java.util.concurrent.Future head(InvocationCallback p0); + java.util.concurrent.Future method(String p0); + java.util.concurrent.Future method(String p0, Entity p1); + java.util.concurrent.Future options(); + java.util.concurrent.Future post(Entity p0); + java.util.concurrent.Future put(Entity p0); + java.util.concurrent.Future trace(); +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/Client.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/Client.java new file mode 100644 index 00000000000..c2d1e654a47 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/Client.java @@ -0,0 +1,24 @@ +// Generated automatically from jakarta.ws.rs.client.Client for testing purposes + +package jakarta.ws.rs.client; + +import jakarta.ws.rs.client.Invocation; +import jakarta.ws.rs.client.WebTarget; +import jakarta.ws.rs.core.Configurable; +import jakarta.ws.rs.core.Link; +import jakarta.ws.rs.core.UriBuilder; +import java.net.URI; +import javax.net.ssl.HostnameVerifier; +import javax.net.ssl.SSLContext; + +public interface Client extends AutoCloseable, Configurable +{ + HostnameVerifier getHostnameVerifier(); + Invocation.Builder invocation(Link p0); + SSLContext getSslContext(); + WebTarget target(Link p0); + WebTarget target(String p0); + WebTarget target(URI p0); + WebTarget target(UriBuilder p0); + void close(); +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/ClientBuilder.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/ClientBuilder.java new file mode 100644 index 00000000000..4e5c0c4c330 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/ClientBuilder.java @@ -0,0 +1,33 @@ +// Generated automatically from jakarta.ws.rs.client.ClientBuilder for testing purposes + +package jakarta.ws.rs.client; + +import jakarta.ws.rs.client.Client; +import jakarta.ws.rs.core.Configurable; +import jakarta.ws.rs.core.Configuration; +import java.security.KeyStore; +import java.util.concurrent.ExecutorService; +import java.util.concurrent.ScheduledExecutorService; +import java.util.concurrent.TimeUnit; +import javax.net.ssl.HostnameVerifier; +import javax.net.ssl.SSLContext; + +abstract public class ClientBuilder implements Configurable +{ + protected ClientBuilder(){} + public ClientBuilder keyStore(KeyStore p0, String p1){ return null; } + public abstract Client build(); + public abstract ClientBuilder connectTimeout(long p0, TimeUnit p1); + public abstract ClientBuilder executorService(ExecutorService p0); + public abstract ClientBuilder hostnameVerifier(HostnameVerifier p0); + public abstract ClientBuilder keyStore(KeyStore p0, char[] p1); + public abstract ClientBuilder readTimeout(long p0, TimeUnit p1); + public abstract ClientBuilder scheduledExecutorService(ScheduledExecutorService p0); + public abstract ClientBuilder sslContext(SSLContext p0); + public abstract ClientBuilder trustStore(KeyStore p0); + public abstract ClientBuilder withConfig(Configuration p0); + public static Client newClient(){ return null; } + public static Client newClient(Configuration p0){ return null; } + public static ClientBuilder newBuilder(){ return null; } + public static String JAXRS_DEFAULT_CLIENT_BUILDER_PROPERTY = null; +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/CompletionStageRxInvoker.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/CompletionStageRxInvoker.java new file mode 100644 index 00000000000..4a454692c98 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/CompletionStageRxInvoker.java @@ -0,0 +1,38 @@ +// Generated automatically from jakarta.ws.rs.client.CompletionStageRxInvoker for testing purposes + +package jakarta.ws.rs.client; + +import jakarta.ws.rs.client.Entity; +import jakarta.ws.rs.client.RxInvoker; +import jakarta.ws.rs.core.GenericType; +import jakarta.ws.rs.core.Response; +import java.util.concurrent.CompletionStage; + +public interface CompletionStageRxInvoker extends RxInvoker +{ + java.util.concurrent.CompletionStage delete(jakarta.ws.rs.core.GenericType p0); + java.util.concurrent.CompletionStage delete(java.lang.Class p0); + java.util.concurrent.CompletionStage get(jakarta.ws.rs.core.GenericType p0); + java.util.concurrent.CompletionStage get(java.lang.Class p0); + java.util.concurrent.CompletionStage method(String p0, Entity p1, jakarta.ws.rs.core.GenericType p2); + java.util.concurrent.CompletionStage method(String p0, Entity p1, java.lang.Class p2); + java.util.concurrent.CompletionStage method(String p0, jakarta.ws.rs.core.GenericType p1); + java.util.concurrent.CompletionStage method(String p0, java.lang.Class p1); + java.util.concurrent.CompletionStage options(jakarta.ws.rs.core.GenericType p0); + java.util.concurrent.CompletionStage options(java.lang.Class p0); + java.util.concurrent.CompletionStage post(Entity p0, jakarta.ws.rs.core.GenericType p1); + java.util.concurrent.CompletionStage post(Entity p0, java.lang.Class p1); + java.util.concurrent.CompletionStage put(Entity p0, jakarta.ws.rs.core.GenericType p1); + java.util.concurrent.CompletionStage put(Entity p0, java.lang.Class p1); + java.util.concurrent.CompletionStage trace(jakarta.ws.rs.core.GenericType p0); + java.util.concurrent.CompletionStage trace(java.lang.Class p0); + CompletionStage delete(); + CompletionStage get(); + CompletionStage head(); + CompletionStage method(String p0); + CompletionStage method(String p0, Entity p1); + CompletionStage options(); + CompletionStage post(Entity p0); + CompletionStage put(Entity p0); + CompletionStage trace(); +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/Entity.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/Entity.java new file mode 100644 index 00000000000..30977a07dd2 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/Entity.java @@ -0,0 +1,36 @@ +// Generated automatically from jakarta.ws.rs.client.Entity for testing purposes + +package jakarta.ws.rs.client; + +import jakarta.ws.rs.core.Form; +import jakarta.ws.rs.core.MediaType; +import jakarta.ws.rs.core.MultivaluedMap; +import jakarta.ws.rs.core.Variant; +import java.lang.annotation.Annotation; +import java.util.Locale; + +public class Entity +{ + protected Entity() {} + public Annotation[] getAnnotations(){ return null; } + public Locale getLanguage(){ return null; } + public MediaType getMediaType(){ return null; } + public String getEncoding(){ return null; } + public String toString(){ return null; } + public T getEntity(){ return null; } + public Variant getVariant(){ return null; } + public boolean equals(Object p0){ return false; } + public int hashCode(){ return 0; } + public static jakarta.ws.rs.client.Entity entity(T p0, MediaType p1){ return null; } + public static jakarta.ws.rs.client.Entity entity(T p0, MediaType p1, Annotation[] p2){ return null; } + public static jakarta.ws.rs.client.Entity entity(T p0, String p1){ return null; } + public static jakarta.ws.rs.client.Entity entity(T p0, Variant p1){ return null; } + public static jakarta.ws.rs.client.Entity entity(T p0, Variant p1, Annotation[] p2){ return null; } + public static jakarta.ws.rs.client.Entity html(T p0){ return null; } + public static jakarta.ws.rs.client.Entity json(T p0){ return null; } + public static jakarta.ws.rs.client.Entity text(T p0){ return null; } + public static jakarta.ws.rs.client.Entity xhtml(T p0){ return null; } + public static jakarta.ws.rs.client.Entity xml(T p0){ return null; } + public static Entity
    form(Form p0){ return null; } + public static Entity form(MultivaluedMap p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/Invocation.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/Invocation.java new file mode 100644 index 00000000000..87267ee1d5d --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/Invocation.java @@ -0,0 +1,53 @@ +// Generated automatically from jakarta.ws.rs.client.Invocation for testing purposes + +package jakarta.ws.rs.client; + +import jakarta.ws.rs.client.AsyncInvoker; +import jakarta.ws.rs.client.CompletionStageRxInvoker; +import jakarta.ws.rs.client.Entity; +import jakarta.ws.rs.client.InvocationCallback; +import jakarta.ws.rs.client.RxInvoker; +import jakarta.ws.rs.client.SyncInvoker; +import jakarta.ws.rs.core.CacheControl; +import jakarta.ws.rs.core.Cookie; +import jakarta.ws.rs.core.GenericType; +import jakarta.ws.rs.core.MediaType; +import jakarta.ws.rs.core.MultivaluedMap; +import jakarta.ws.rs.core.Response; +import java.util.Locale; +import java.util.concurrent.Future; + +public interface Invocation +{ + T invoke(jakarta.ws.rs.core.GenericType p0); + T invoke(java.lang.Class p0); + java.util.concurrent.Future submit(jakarta.ws.rs.client.InvocationCallback p0); + java.util.concurrent.Future submit(jakarta.ws.rs.core.GenericType p0); + java.util.concurrent.Future submit(java.lang.Class p0); + Invocation property(String p0, Object p1); + Response invoke(); + java.util.concurrent.Future submit(); + static public interface Builder extends SyncInvoker + { + T rx(java.lang.Class p0); + AsyncInvoker async(); + CompletionStageRxInvoker rx(); + Invocation build(String p0); + Invocation build(String p0, Entity p1); + Invocation buildDelete(); + Invocation buildGet(); + Invocation buildPost(Entity p0); + Invocation buildPut(Entity p0); + Invocation.Builder accept(MediaType... p0); + Invocation.Builder accept(String... p0); + Invocation.Builder acceptEncoding(String... p0); + Invocation.Builder acceptLanguage(Locale... p0); + Invocation.Builder acceptLanguage(String... p0); + Invocation.Builder cacheControl(CacheControl p0); + Invocation.Builder cookie(Cookie p0); + Invocation.Builder cookie(String p0, String p1); + Invocation.Builder header(String p0, Object p1); + Invocation.Builder headers(MultivaluedMap p0); + Invocation.Builder property(String p0, Object p1); + } +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/InvocationCallback.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/InvocationCallback.java new file mode 100644 index 00000000000..45551014541 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/InvocationCallback.java @@ -0,0 +1,10 @@ +// Generated automatically from jakarta.ws.rs.client.InvocationCallback for testing purposes + +package jakarta.ws.rs.client; + + +public interface InvocationCallback +{ + void completed(RESPONSE p0); + void failed(Throwable p0); +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/RxInvoker.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/RxInvoker.java new file mode 100644 index 00000000000..d36b6155b78 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/RxInvoker.java @@ -0,0 +1,35 @@ +// Generated automatically from jakarta.ws.rs.client.RxInvoker for testing purposes + +package jakarta.ws.rs.client; + +import jakarta.ws.rs.client.Entity; +import jakarta.ws.rs.core.GenericType; + +public interface RxInvoker +{ + T delete(jakarta.ws.rs.core.GenericType p0); + T delete(java.lang.Class p0); + T get(jakarta.ws.rs.core.GenericType p0); + T get(java.lang.Class p0); + T method(String p0, Entity p1, jakarta.ws.rs.core.GenericType p2); + T method(String p0, Entity p1, java.lang.Class p2); + T method(String p0, jakarta.ws.rs.core.GenericType p1); + T method(String p0, java.lang.Class p1); + T options(jakarta.ws.rs.core.GenericType p0); + T options(java.lang.Class p0); + T post(Entity p0, jakarta.ws.rs.core.GenericType p1); + T post(Entity p0, java.lang.Class p1); + T put(Entity p0, jakarta.ws.rs.core.GenericType p1); + T put(Entity p0, java.lang.Class p1); + T trace(jakarta.ws.rs.core.GenericType p0); + T trace(java.lang.Class p0); + T delete(); + T get(); + T head(); + T method(String p0); + T method(String p0, Entity p1); + T options(); + T post(Entity p0); + T put(Entity p0); + T trace(); +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/SyncInvoker.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/SyncInvoker.java new file mode 100644 index 00000000000..3689869116e --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/SyncInvoker.java @@ -0,0 +1,36 @@ +// Generated automatically from jakarta.ws.rs.client.SyncInvoker for testing purposes + +package jakarta.ws.rs.client; + +import jakarta.ws.rs.client.Entity; +import jakarta.ws.rs.core.GenericType; +import jakarta.ws.rs.core.Response; + +public interface SyncInvoker +{ + T delete(jakarta.ws.rs.core.GenericType p0); + T delete(java.lang.Class p0); + T get(jakarta.ws.rs.core.GenericType p0); + T get(java.lang.Class p0); + T method(String p0, Entity p1, jakarta.ws.rs.core.GenericType p2); + T method(String p0, Entity p1, java.lang.Class p2); + T method(String p0, jakarta.ws.rs.core.GenericType p1); + T method(String p0, java.lang.Class p1); + T options(jakarta.ws.rs.core.GenericType p0); + T options(java.lang.Class p0); + T post(Entity p0, jakarta.ws.rs.core.GenericType p1); + T post(Entity p0, java.lang.Class p1); + T put(Entity p0, jakarta.ws.rs.core.GenericType p1); + T put(Entity p0, java.lang.Class p1); + T trace(jakarta.ws.rs.core.GenericType p0); + T trace(java.lang.Class p0); + Response delete(); + Response get(); + Response head(); + Response method(String p0); + Response method(String p0, Entity p1); + Response options(); + Response post(Entity p0); + Response put(Entity p0); + Response trace(); +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/WebTarget.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/WebTarget.java new file mode 100644 index 00000000000..249828a6b86 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/client/WebTarget.java @@ -0,0 +1,28 @@ +// Generated automatically from jakarta.ws.rs.client.WebTarget for testing purposes + +package jakarta.ws.rs.client; + +import jakarta.ws.rs.client.Invocation; +import jakarta.ws.rs.core.Configurable; +import jakarta.ws.rs.core.MediaType; +import jakarta.ws.rs.core.UriBuilder; +import java.net.URI; +import java.util.Map; + +public interface WebTarget extends Configurable +{ + Invocation.Builder request(); + Invocation.Builder request(MediaType... p0); + Invocation.Builder request(String... p0); + URI getUri(); + UriBuilder getUriBuilder(); + WebTarget matrixParam(String p0, Object... p1); + WebTarget path(String p0); + WebTarget queryParam(String p0, Object... p1); + WebTarget resolveTemplate(String p0, Object p1); + WebTarget resolveTemplate(String p0, Object p1, boolean p2); + WebTarget resolveTemplateFromEncoded(String p0, Object p1); + WebTarget resolveTemplates(Map p0); + WebTarget resolveTemplates(Map p0, boolean p1); + WebTarget resolveTemplatesFromEncoded(Map p0); +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/CacheControl.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/CacheControl.java new file mode 100644 index 00000000000..400fab26e4d --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/CacheControl.java @@ -0,0 +1,34 @@ +// Generated automatically from jakarta.ws.rs.core.CacheControl for testing purposes + +package jakarta.ws.rs.core; + +import java.util.List; +import java.util.Map; + +public class CacheControl +{ + public CacheControl(){} + public List getNoCacheFields(){ return null; } + public List getPrivateFields(){ return null; } + public Map getCacheExtension(){ return null; } + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public boolean isMustRevalidate(){ return false; } + public boolean isNoCache(){ return false; } + public boolean isNoStore(){ return false; } + public boolean isNoTransform(){ return false; } + public boolean isPrivate(){ return false; } + public boolean isProxyRevalidate(){ return false; } + public int getMaxAge(){ return 0; } + public int getSMaxAge(){ return 0; } + public int hashCode(){ return 0; } + public static CacheControl valueOf(String p0){ return null; } + public void setMaxAge(int p0){} + public void setMustRevalidate(boolean p0){} + public void setNoCache(boolean p0){} + public void setNoStore(boolean p0){} + public void setNoTransform(boolean p0){} + public void setPrivate(boolean p0){} + public void setProxyRevalidate(boolean p0){} + public void setSMaxAge(int p0){} +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Configurable.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Configurable.java new file mode 100644 index 00000000000..6806fd9fa34 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Configurable.java @@ -0,0 +1,20 @@ +// Generated automatically from jakarta.ws.rs.core.Configurable for testing purposes + +package jakarta.ws.rs.core; + +import jakarta.ws.rs.core.Configuration; +import java.util.Map; + +public interface Configurable +{ + C property(String p0, Object p1); + C register(Class p0); + C register(Class p0, Class... p1); + C register(Class p0, Map, Integer> p1); + C register(Class p0, int p1); + C register(Object p0); + C register(Object p0, Class... p1); + C register(Object p0, Map, Integer> p1); + C register(Object p0, int p1); + Configuration getConfiguration(); +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Configuration.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Configuration.java new file mode 100644 index 00000000000..a03617bb948 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Configuration.java @@ -0,0 +1,25 @@ +// Generated automatically from jakarta.ws.rs.core.Configuration for testing purposes + +package jakarta.ws.rs.core; + +import jakarta.ws.rs.RuntimeType; +import jakarta.ws.rs.core.Feature; +import java.util.Collection; +import java.util.Map; +import java.util.Set; + +public interface Configuration +{ + Collection getPropertyNames(); + Map, Integer> getContracts(Class p0); + Map getProperties(); + Object getProperty(String p0); + RuntimeType getRuntimeType(); + Set> getClasses(); + Set getInstances(); + boolean isEnabled(Feature p0); + boolean isEnabled(java.lang.Class p0); + boolean isRegistered(Class p0); + boolean isRegistered(Object p0); + default boolean hasProperty(String p0){ return false; } +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Cookie.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Cookie.java new file mode 100644 index 00000000000..fcaef867a1e --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Cookie.java @@ -0,0 +1,33 @@ +// Generated automatically from jakarta.ws.rs.core.Cookie for testing purposes + +package jakarta.ws.rs.core; + + +public class Cookie +{ + protected Cookie() {} + abstract static public class AbstractCookieBuilder> + { + protected AbstractCookieBuilder() {} + public AbstractCookieBuilder(String p0){} + public T domain(String p0){ return null; } + public T path(String p0){ return null; } + public T value(String p0){ return null; } + public T version(int p0){ return null; } + public abstract Cookie build(); + } + protected Cookie(Cookie.AbstractCookieBuilder p0){} + public Cookie(String p0, String p1){} + public Cookie(String p0, String p1, String p2, String p3){} + public Cookie(String p0, String p1, String p2, String p3, int p4){} + public String getDomain(){ return null; } + public String getName(){ return null; } + public String getPath(){ return null; } + public String getValue(){ return null; } + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public int getVersion(){ return 0; } + public int hashCode(){ return 0; } + public static Cookie valueOf(String p0){ return null; } + public static int DEFAULT_VERSION = 0; +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/EntityTag.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/EntityTag.java new file mode 100644 index 00000000000..47d0dba0c93 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/EntityTag.java @@ -0,0 +1,17 @@ +// Generated automatically from jakarta.ws.rs.core.EntityTag for testing purposes + +package jakarta.ws.rs.core; + + +public class EntityTag +{ + protected EntityTag() {} + public EntityTag(String p0){} + public EntityTag(String p0, boolean p1){} + public String getValue(){ return null; } + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public boolean isWeak(){ return false; } + public int hashCode(){ return 0; } + public static EntityTag valueOf(String p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Feature.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Feature.java new file mode 100644 index 00000000000..bbb179974fd --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Feature.java @@ -0,0 +1,10 @@ +// Generated automatically from jakarta.ws.rs.core.Feature for testing purposes + +package jakarta.ws.rs.core; + +import jakarta.ws.rs.core.FeatureContext; + +public interface Feature +{ + boolean configure(FeatureContext p0); +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/FeatureContext.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/FeatureContext.java new file mode 100644 index 00000000000..8d0e04ed10b --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/FeatureContext.java @@ -0,0 +1,9 @@ +// Generated automatically from jakarta.ws.rs.core.FeatureContext for testing purposes + +package jakarta.ws.rs.core; + +import jakarta.ws.rs.core.Configurable; + +public interface FeatureContext extends Configurable +{ +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Form.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Form.java new file mode 100644 index 00000000000..67e025dbb14 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Form.java @@ -0,0 +1,14 @@ +// Generated automatically from jakarta.ws.rs.core.Form for testing purposes + +package jakarta.ws.rs.core; + +import jakarta.ws.rs.core.MultivaluedMap; + +public class Form +{ + public Form param(String p0, String p1){ return null; } + public Form(){} + public Form(MultivaluedMap p0){} + public Form(String p0, String p1){} + public MultivaluedMap asMap(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/GenericType.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/GenericType.java new file mode 100644 index 00000000000..a70692d41c5 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/GenericType.java @@ -0,0 +1,17 @@ +// Generated automatically from jakarta.ws.rs.core.GenericType for testing purposes + +package jakarta.ws.rs.core; + +import java.lang.reflect.Type; + +public class GenericType +{ + protected GenericType(){} + public GenericType(Type p0){} + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public final Class getRawType(){ return null; } + public final Type getType(){ return null; } + public int hashCode(){ return 0; } + public static GenericType forInstance(Object p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Link.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Link.java new file mode 100644 index 00000000000..bc66793f67c --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Link.java @@ -0,0 +1,48 @@ +// Generated automatically from jakarta.ws.rs.core.Link for testing purposes + +package jakarta.ws.rs.core; + +import jakarta.ws.rs.core.UriBuilder; +import java.net.URI; +import java.util.List; +import java.util.Map; + +abstract public class Link +{ + public Link(){} + public abstract List getRels(); + public abstract Map getParams(); + public abstract String getRel(); + public abstract String getTitle(); + public abstract String getType(); + public abstract String toString(); + public abstract URI getUri(); + public abstract UriBuilder getUriBuilder(); + public static Link valueOf(String p0){ return null; } + public static Link.Builder fromLink(Link p0){ return null; } + public static Link.Builder fromMethod(Class p0, String p1){ return null; } + public static Link.Builder fromPath(String p0){ return null; } + public static Link.Builder fromResource(Class p0){ return null; } + public static Link.Builder fromUri(String p0){ return null; } + public static Link.Builder fromUri(URI p0){ return null; } + public static Link.Builder fromUriBuilder(UriBuilder p0){ return null; } + public static String REL = null; + public static String TITLE = null; + public static String TYPE = null; + static public interface Builder + { + Link build(Object... p0); + Link buildRelativized(URI p0, Object... p1); + Link.Builder baseUri(String p0); + Link.Builder baseUri(URI p0); + Link.Builder link(Link p0); + Link.Builder link(String p0); + Link.Builder param(String p0, String p1); + Link.Builder rel(String p0); + Link.Builder title(String p0); + Link.Builder type(String p0); + Link.Builder uri(String p0); + Link.Builder uri(URI p0); + Link.Builder uriBuilder(UriBuilder p0); + } +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/MediaType.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/MediaType.java new file mode 100644 index 00000000000..f8d34b1ba8d --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/MediaType.java @@ -0,0 +1,54 @@ +// Generated automatically from jakarta.ws.rs.core.MediaType for testing purposes + +package jakarta.ws.rs.core; + +import java.util.Map; + +public class MediaType +{ + public Map getParameters(){ return null; } + public MediaType withCharset(String p0){ return null; } + public MediaType(){} + public MediaType(String p0, String p1){} + public MediaType(String p0, String p1, Map p2){} + public MediaType(String p0, String p1, String p2){} + public String getSubtype(){ return null; } + public String getType(){ return null; } + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public boolean isCompatible(MediaType p0){ return false; } + public boolean isWildcardSubtype(){ return false; } + public boolean isWildcardType(){ return false; } + public int hashCode(){ return 0; } + public static MediaType APPLICATION_ATOM_XML_TYPE = null; + public static MediaType APPLICATION_FORM_URLENCODED_TYPE = null; + public static MediaType APPLICATION_JSON_PATCH_JSON_TYPE = null; + public static MediaType APPLICATION_JSON_TYPE = null; + public static MediaType APPLICATION_OCTET_STREAM_TYPE = null; + public static MediaType APPLICATION_SVG_XML_TYPE = null; + public static MediaType APPLICATION_XHTML_XML_TYPE = null; + public static MediaType APPLICATION_XML_TYPE = null; + public static MediaType MULTIPART_FORM_DATA_TYPE = null; + public static MediaType SERVER_SENT_EVENTS_TYPE = null; + public static MediaType TEXT_HTML_TYPE = null; + public static MediaType TEXT_PLAIN_TYPE = null; + public static MediaType TEXT_XML_TYPE = null; + public static MediaType WILDCARD_TYPE = null; + public static MediaType valueOf(String p0){ return null; } + public static String APPLICATION_ATOM_XML = null; + public static String APPLICATION_FORM_URLENCODED = null; + public static String APPLICATION_JSON = null; + public static String APPLICATION_JSON_PATCH_JSON = null; + public static String APPLICATION_OCTET_STREAM = null; + public static String APPLICATION_SVG_XML = null; + public static String APPLICATION_XHTML_XML = null; + public static String APPLICATION_XML = null; + public static String CHARSET_PARAMETER = null; + public static String MEDIA_TYPE_WILDCARD = null; + public static String MULTIPART_FORM_DATA = null; + public static String SERVER_SENT_EVENTS = null; + public static String TEXT_HTML = null; + public static String TEXT_PLAIN = null; + public static String TEXT_XML = null; + public static String WILDCARD = null; +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/MultivaluedMap.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/MultivaluedMap.java new file mode 100644 index 00000000000..5cefd2248c2 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/MultivaluedMap.java @@ -0,0 +1,17 @@ +// Generated automatically from jakarta.ws.rs.core.MultivaluedMap for testing purposes + +package jakarta.ws.rs.core; + +import java.util.List; +import java.util.Map; + +public interface MultivaluedMap extends java.util.Map> +{ + V getFirst(K p0); + boolean equalsIgnoreValueOrder(MultivaluedMap p0); + void add(K p0, V p1); + void addAll(K p0, V... p1); + void addAll(K p0, java.util.List p1); + void addFirst(K p0, V p1); + void putSingle(K p0, V p1); +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/NewCookie.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/NewCookie.java new file mode 100644 index 00000000000..77c3f68c4db --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/NewCookie.java @@ -0,0 +1,51 @@ +// Generated automatically from jakarta.ws.rs.core.NewCookie for testing purposes + +package jakarta.ws.rs.core; + +import jakarta.ws.rs.core.Cookie; + +public class NewCookie extends Cookie +{ + protected NewCookie() {} + abstract static public class AbstractNewCookieBuilder> extends Cookie.AbstractCookieBuilder> + { + protected AbstractNewCookieBuilder() {} + public AbstractNewCookieBuilder(Cookie p0){} + public AbstractNewCookieBuilder(String p0){} + public T comment(String p0){ return null; } + public T expiry(java.util.Date p0){ return null; } + public T httpOnly(boolean p0){ return null; } + public T maxAge(int p0){ return null; } + public T sameSite(NewCookie.SameSite p0){ return null; } + public T secure(boolean p0){ return null; } + public abstract NewCookie build(); + } + protected NewCookie(NewCookie.AbstractNewCookieBuilder p0){} + public Cookie toCookie(){ return null; } + public NewCookie(Cookie p0){} + public NewCookie(Cookie p0, String p1, int p2, boolean p3){} + public NewCookie(Cookie p0, String p1, int p2, java.util.Date p3, boolean p4, boolean p5){} + public NewCookie(Cookie p0, String p1, int p2, java.util.Date p3, boolean p4, boolean p5, NewCookie.SameSite p6){} + public NewCookie(String p0, String p1){} + public NewCookie(String p0, String p1, String p2, String p3, String p4, int p5, boolean p6){} + public NewCookie(String p0, String p1, String p2, String p3, String p4, int p5, boolean p6, boolean p7){} + public NewCookie(String p0, String p1, String p2, String p3, int p4, String p5, int p6, boolean p7){} + public NewCookie(String p0, String p1, String p2, String p3, int p4, String p5, int p6, java.util.Date p7, boolean p8, boolean p9){} + public NewCookie(String p0, String p1, String p2, String p3, int p4, String p5, int p6, java.util.Date p7, boolean p8, boolean p9, NewCookie.SameSite p10){} + public NewCookie.SameSite getSameSite(){ return null; } + public String getComment(){ return null; } + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public boolean isHttpOnly(){ return false; } + public boolean isSecure(){ return false; } + public int getMaxAge(){ return 0; } + public int hashCode(){ return 0; } + public java.util.Date getExpiry(){ return null; } + public static NewCookie valueOf(String p0){ return null; } + public static int DEFAULT_MAX_AGE = 0; + static public enum SameSite + { + LAX, NONE, STRICT; + private SameSite() {} + } +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Response.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Response.java new file mode 100644 index 00000000000..260ff646053 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Response.java @@ -0,0 +1,131 @@ +// Generated automatically from jakarta.ws.rs.core.Response for testing purposes + +package jakarta.ws.rs.core; + +import jakarta.ws.rs.core.CacheControl; +import jakarta.ws.rs.core.EntityTag; +import jakarta.ws.rs.core.GenericType; +import jakarta.ws.rs.core.Link; +import jakarta.ws.rs.core.MediaType; +import jakarta.ws.rs.core.MultivaluedMap; +import jakarta.ws.rs.core.NewCookie; +import jakarta.ws.rs.core.Variant; +import java.lang.annotation.Annotation; +import java.net.URI; +import java.util.List; +import java.util.Locale; +import java.util.Map; +import java.util.Set; + +abstract public class Response implements AutoCloseable +{ + abstract static public class ResponseBuilder + { + protected ResponseBuilder(){} + protected static Response.ResponseBuilder newInstance(){ return null; } + public Response.ResponseBuilder status(Response.Status p0){ return null; } + public Response.ResponseBuilder status(Response.StatusType p0){ return null; } + public abstract Response build(); + public abstract Response.ResponseBuilder allow(Set p0); + public abstract Response.ResponseBuilder allow(String... p0); + public abstract Response.ResponseBuilder cacheControl(CacheControl p0); + public abstract Response.ResponseBuilder clone(); + public abstract Response.ResponseBuilder contentLocation(URI p0); + public abstract Response.ResponseBuilder cookie(NewCookie... p0); + public abstract Response.ResponseBuilder encoding(String p0); + public abstract Response.ResponseBuilder entity(Object p0); + public abstract Response.ResponseBuilder entity(Object p0, Annotation[] p1); + public abstract Response.ResponseBuilder expires(java.util.Date p0); + public abstract Response.ResponseBuilder header(String p0, Object p1); + public abstract Response.ResponseBuilder language(Locale p0); + public abstract Response.ResponseBuilder language(String p0); + public abstract Response.ResponseBuilder lastModified(java.util.Date p0); + public abstract Response.ResponseBuilder link(String p0, String p1); + public abstract Response.ResponseBuilder link(URI p0, String p1); + public abstract Response.ResponseBuilder links(Link... p0); + public abstract Response.ResponseBuilder location(URI p0); + public abstract Response.ResponseBuilder replaceAll(MultivaluedMap p0); + public abstract Response.ResponseBuilder status(int p0); + public abstract Response.ResponseBuilder status(int p0, String p1); + public abstract Response.ResponseBuilder tag(EntityTag p0); + public abstract Response.ResponseBuilder tag(String p0); + public abstract Response.ResponseBuilder type(MediaType p0); + public abstract Response.ResponseBuilder type(String p0); + public abstract Response.ResponseBuilder variant(Variant p0); + public abstract Response.ResponseBuilder variants(Variant... p0); + public abstract Response.ResponseBuilder variants(java.util.List p0); + } + protected Response(){} + public MultivaluedMap getHeaders(){ return null; } + public abstract T readEntity(jakarta.ws.rs.core.GenericType p0); + public abstract T readEntity(jakarta.ws.rs.core.GenericType p0, Annotation[] p1); + public abstract T readEntity(java.lang.Class p0); + public abstract T readEntity(java.lang.Class p0, Annotation[] p1); + public abstract EntityTag getEntityTag(); + public abstract Link getLink(String p0); + public abstract Link.Builder getLinkBuilder(String p0); + public abstract Locale getLanguage(); + public abstract MediaType getMediaType(); + public abstract MultivaluedMap getMetadata(); + public abstract MultivaluedMap getStringHeaders(); + public abstract Object getEntity(); + public abstract Response.StatusType getStatusInfo(); + public abstract Set getAllowedMethods(); + public abstract String getHeaderString(String p0); + public abstract URI getLocation(); + public abstract boolean bufferEntity(); + public abstract boolean hasEntity(); + public abstract boolean hasLink(String p0); + public abstract int getLength(); + public abstract int getStatus(); + public abstract java.util.Date getDate(); + public abstract java.util.Date getLastModified(); + public abstract java.util.Map getCookies(); + public abstract java.util.Set getLinks(); + public abstract void close(); + public boolean isClosed(){ return false; } + public static Response.ResponseBuilder accepted(){ return null; } + public static Response.ResponseBuilder accepted(Object p0){ return null; } + public static Response.ResponseBuilder created(URI p0){ return null; } + public static Response.ResponseBuilder fromResponse(Response p0){ return null; } + public static Response.ResponseBuilder noContent(){ return null; } + public static Response.ResponseBuilder notAcceptable(java.util.List p0){ return null; } + public static Response.ResponseBuilder notModified(){ return null; } + public static Response.ResponseBuilder notModified(EntityTag p0){ return null; } + public static Response.ResponseBuilder notModified(String p0){ return null; } + public static Response.ResponseBuilder ok(){ return null; } + public static Response.ResponseBuilder ok(Object p0){ return null; } + public static Response.ResponseBuilder ok(Object p0, MediaType p1){ return null; } + public static Response.ResponseBuilder ok(Object p0, String p1){ return null; } + public static Response.ResponseBuilder ok(Object p0, Variant p1){ return null; } + public static Response.ResponseBuilder seeOther(URI p0){ return null; } + public static Response.ResponseBuilder serverError(){ return null; } + public static Response.ResponseBuilder status(Response.Status p0){ return null; } + public static Response.ResponseBuilder status(Response.StatusType p0){ return null; } + public static Response.ResponseBuilder status(int p0){ return null; } + public static Response.ResponseBuilder status(int p0, String p1){ return null; } + public static Response.ResponseBuilder temporaryRedirect(URI p0){ return null; } + static public enum Status + { + ACCEPTED, BAD_GATEWAY, BAD_REQUEST, CONFLICT, CREATED, EXPECTATION_FAILED, FORBIDDEN, FOUND, GATEWAY_TIMEOUT, GONE, HTTP_VERSION_NOT_SUPPORTED, INTERNAL_SERVER_ERROR, LENGTH_REQUIRED, METHOD_NOT_ALLOWED, MOVED_PERMANENTLY, MULTIPLE_CHOICES, NETWORK_AUTHENTICATION_REQUIRED, NOT_ACCEPTABLE, NOT_FOUND, NOT_IMPLEMENTED, NOT_MODIFIED, NO_CONTENT, OK, PARTIAL_CONTENT, PAYMENT_REQUIRED, PERMANENT_REDIRECT, PRECONDITION_FAILED, PRECONDITION_REQUIRED, PROXY_AUTHENTICATION_REQUIRED, REQUESTED_RANGE_NOT_SATISFIABLE, REQUEST_ENTITY_TOO_LARGE, REQUEST_HEADER_FIELDS_TOO_LARGE, REQUEST_TIMEOUT, REQUEST_URI_TOO_LONG, RESET_CONTENT, SEE_OTHER, SERVICE_UNAVAILABLE, TEMPORARY_REDIRECT, TOO_MANY_REQUESTS, UNAUTHORIZED, UNAVAILABLE_FOR_LEGAL_REASONS, UNSUPPORTED_MEDIA_TYPE, USE_PROXY; + private Status() {} + public Response.Status.Family getFamily(){ return null; } + public String getReasonPhrase(){ return null; } + public String toString(){ return null; } + public int getStatusCode(){ return 0; } + public static Response.Status fromStatusCode(int p0){ return null; } + static public enum Family + { + CLIENT_ERROR, INFORMATIONAL, OTHER, REDIRECTION, SERVER_ERROR, SUCCESSFUL; + private Family() {} + public static Response.Status.Family familyOf(int p0){ return null; } + } + } + static public interface StatusType + { + Response.Status.Family getFamily(); + String getReasonPhrase(); + default Response.Status toEnum(){ return null; } + int getStatusCode(); + } +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/UriBuilder.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/UriBuilder.java new file mode 100644 index 00000000000..019133cfb89 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/UriBuilder.java @@ -0,0 +1,54 @@ +// Generated automatically from jakarta.ws.rs.core.UriBuilder for testing purposes + +package jakarta.ws.rs.core; + +import jakarta.ws.rs.core.Link; +import java.lang.reflect.Method; +import java.net.URI; +import java.util.Map; + +abstract public class UriBuilder +{ + protected UriBuilder(){} + public abstract String toTemplate(); + public abstract URI build(Object... p0); + public abstract URI build(Object[] p0, boolean p1); + public abstract URI buildFromEncoded(Object... p0); + public abstract URI buildFromEncodedMap(Map p0); + public abstract URI buildFromMap(Map p0); + public abstract URI buildFromMap(Map p0, boolean p1); + public abstract UriBuilder clone(); + public abstract UriBuilder fragment(String p0); + public abstract UriBuilder host(String p0); + public abstract UriBuilder matrixParam(String p0, Object... p1); + public abstract UriBuilder path(Class p0); + public abstract UriBuilder path(Class p0, String p1); + public abstract UriBuilder path(Method p0); + public abstract UriBuilder path(String p0); + public abstract UriBuilder port(int p0); + public abstract UriBuilder queryParam(String p0, Object... p1); + public abstract UriBuilder replaceMatrix(String p0); + public abstract UriBuilder replaceMatrixParam(String p0, Object... p1); + public abstract UriBuilder replacePath(String p0); + public abstract UriBuilder replaceQuery(String p0); + public abstract UriBuilder replaceQueryParam(String p0, Object... p1); + public abstract UriBuilder resolveTemplate(String p0, Object p1); + public abstract UriBuilder resolveTemplate(String p0, Object p1, boolean p2); + public abstract UriBuilder resolveTemplateFromEncoded(String p0, Object p1); + public abstract UriBuilder resolveTemplates(Map p0); + public abstract UriBuilder resolveTemplates(Map p0, boolean p1); + public abstract UriBuilder resolveTemplatesFromEncoded(Map p0); + public abstract UriBuilder scheme(String p0); + public abstract UriBuilder schemeSpecificPart(String p0); + public abstract UriBuilder segment(String... p0); + public abstract UriBuilder uri(String p0); + public abstract UriBuilder uri(URI p0); + public abstract UriBuilder userInfo(String p0); + public static UriBuilder fromLink(Link p0){ return null; } + public static UriBuilder fromMethod(Class p0, String p1){ return null; } + public static UriBuilder fromPath(String p0){ return null; } + public static UriBuilder fromResource(Class p0){ return null; } + public static UriBuilder fromUri(String p0){ return null; } + public static UriBuilder fromUri(URI p0){ return null; } + public static UriBuilder newInstance(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Variant.java b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Variant.java new file mode 100644 index 00000000000..e580c5318ff --- /dev/null +++ b/java/ql/test/stubs/javafx-web/jakarta/ws/rs/core/Variant.java @@ -0,0 +1,36 @@ +// Generated automatically from jakarta.ws.rs.core.Variant for testing purposes + +package jakarta.ws.rs.core; + +import jakarta.ws.rs.core.MediaType; +import java.util.List; +import java.util.Locale; + +public class Variant +{ + protected Variant() {} + abstract static public class VariantListBuilder + { + protected VariantListBuilder(){} + public abstract Variant.VariantListBuilder add(); + public abstract Variant.VariantListBuilder encodings(String... p0); + public abstract Variant.VariantListBuilder languages(Locale... p0); + public abstract Variant.VariantListBuilder mediaTypes(MediaType... p0); + public abstract java.util.List build(); + public static Variant.VariantListBuilder newInstance(){ return null; } + } + public Locale getLanguage(){ return null; } + public MediaType getMediaType(){ return null; } + public String getEncoding(){ return null; } + public String getLanguageString(){ return null; } + public String toString(){ return null; } + public Variant(MediaType p0, Locale p1, String p2){} + public Variant(MediaType p0, String p1, String p2){} + public Variant(MediaType p0, String p1, String p2, String p3){} + public Variant(MediaType p0, String p1, String p2, String p3, String p4){} + public boolean equals(Object p0){ return false; } + public int hashCode(){ return 0; } + public static Variant.VariantListBuilder encodings(String... p0){ return null; } + public static Variant.VariantListBuilder languages(Locale... p0){ return null; } + public static Variant.VariantListBuilder mediaTypes(MediaType... p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/animation/Interpolatable.java b/java/ql/test/stubs/javafx-web/javafx/animation/Interpolatable.java new file mode 100644 index 00000000000..518ddddb556 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/animation/Interpolatable.java @@ -0,0 +1,9 @@ +// Generated automatically from javafx.animation.Interpolatable for testing purposes + +package javafx.animation; + + +public interface Interpolatable +{ + T interpolate(T p0, double p1); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/InvalidationListener.java b/java/ql/test/stubs/javafx-web/javafx/beans/InvalidationListener.java new file mode 100644 index 00000000000..71ba5cf74d6 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/InvalidationListener.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.beans.InvalidationListener for testing purposes + +package javafx.beans; + +import javafx.beans.Observable; + +public interface InvalidationListener +{ + void invalidated(Observable p0); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/Observable.java b/java/ql/test/stubs/javafx-web/javafx/beans/Observable.java new file mode 100644 index 00000000000..f8b9e5d6d85 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/Observable.java @@ -0,0 +1,11 @@ +// Generated automatically from javafx.beans.Observable for testing purposes + +package javafx.beans; + +import javafx.beans.InvalidationListener; + +public interface Observable +{ + void addListener(InvalidationListener p0); + void removeListener(InvalidationListener p0); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/binding/Binding.java b/java/ql/test/stubs/javafx-web/javafx/beans/binding/Binding.java new file mode 100644 index 00000000000..eb119f82920 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/binding/Binding.java @@ -0,0 +1,14 @@ +// Generated automatically from javafx.beans.binding.Binding for testing purposes + +package javafx.beans.binding; + +import javafx.beans.value.ObservableValue; +import javafx.collections.ObservableList; + +public interface Binding extends javafx.beans.value.ObservableValue +{ + ObservableList getDependencies(); + boolean isValid(); + void dispose(); + void invalidate(); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/binding/BooleanBinding.java b/java/ql/test/stubs/javafx-web/javafx/beans/binding/BooleanBinding.java new file mode 100644 index 00000000000..3bd08ab5503 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/binding/BooleanBinding.java @@ -0,0 +1,29 @@ +// Generated automatically from javafx.beans.binding.BooleanBinding for testing purposes + +package javafx.beans.binding; + +import javafx.beans.InvalidationListener; +import javafx.beans.Observable; +import javafx.beans.binding.Binding; +import javafx.beans.binding.BooleanExpression; +import javafx.beans.value.ChangeListener; +import javafx.collections.ObservableList; + +abstract public class BooleanBinding extends BooleanExpression implements Binding +{ + protected abstract boolean computeValue(); + protected final void bind(Observable... p0){} + protected final void unbind(Observable... p0){} + protected void onInvalidating(){} + public BooleanBinding(){} + public ObservableList getDependencies(){ return null; } + public String toString(){ return null; } + public final boolean get(){ return false; } + public final boolean isValid(){ return false; } + public final void invalidate(){} + public void addListener(ChangeListener p0){} + public void addListener(InvalidationListener p0){} + public void dispose(){} + public void removeListener(ChangeListener p0){} + public void removeListener(InvalidationListener p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/binding/BooleanExpression.java b/java/ql/test/stubs/javafx-web/javafx/beans/binding/BooleanExpression.java new file mode 100644 index 00000000000..0fc8e4a0300 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/binding/BooleanExpression.java @@ -0,0 +1,24 @@ +// Generated automatically from javafx.beans.binding.BooleanExpression for testing purposes + +package javafx.beans.binding; + +import javafx.beans.binding.BooleanBinding; +import javafx.beans.binding.ObjectExpression; +import javafx.beans.binding.StringBinding; +import javafx.beans.value.ObservableBooleanValue; +import javafx.beans.value.ObservableValue; + +abstract public class BooleanExpression implements ObservableBooleanValue +{ + public Boolean getValue(){ return null; } + public BooleanBinding and(ObservableBooleanValue p0){ return null; } + public BooleanBinding isEqualTo(ObservableBooleanValue p0){ return null; } + public BooleanBinding isNotEqualTo(ObservableBooleanValue p0){ return null; } + public BooleanBinding not(){ return null; } + public BooleanBinding or(ObservableBooleanValue p0){ return null; } + public BooleanExpression(){} + public ObjectExpression asObject(){ return null; } + public StringBinding asString(){ return null; } + public static BooleanExpression booleanExpression(ObservableBooleanValue p0){ return null; } + public static BooleanExpression booleanExpression(ObservableValue p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/binding/DoubleBinding.java b/java/ql/test/stubs/javafx-web/javafx/beans/binding/DoubleBinding.java new file mode 100644 index 00000000000..6e7f925ec38 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/binding/DoubleBinding.java @@ -0,0 +1,29 @@ +// Generated automatically from javafx.beans.binding.DoubleBinding for testing purposes + +package javafx.beans.binding; + +import javafx.beans.InvalidationListener; +import javafx.beans.Observable; +import javafx.beans.binding.DoubleExpression; +import javafx.beans.binding.NumberBinding; +import javafx.beans.value.ChangeListener; +import javafx.collections.ObservableList; + +abstract public class DoubleBinding extends DoubleExpression implements NumberBinding +{ + protected abstract double computeValue(); + protected final void bind(Observable... p0){} + protected final void unbind(Observable... p0){} + protected void onInvalidating(){} + public DoubleBinding(){} + public ObservableList getDependencies(){ return null; } + public String toString(){ return null; } + public final boolean isValid(){ return false; } + public final double get(){ return 0; } + public final void invalidate(){} + public void addListener(ChangeListener p0){} + public void addListener(InvalidationListener p0){} + public void dispose(){} + public void removeListener(ChangeListener p0){} + public void removeListener(InvalidationListener p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/binding/DoubleExpression.java b/java/ql/test/stubs/javafx-web/javafx/beans/binding/DoubleExpression.java new file mode 100644 index 00000000000..530ddb07861 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/binding/DoubleExpression.java @@ -0,0 +1,44 @@ +// Generated automatically from javafx.beans.binding.DoubleExpression for testing purposes + +package javafx.beans.binding; + +import javafx.beans.binding.DoubleBinding; +import javafx.beans.binding.NumberExpressionBase; +import javafx.beans.binding.ObjectExpression; +import javafx.beans.value.ObservableDoubleValue; +import javafx.beans.value.ObservableNumberValue; +import javafx.beans.value.ObservableValue; + +abstract public class DoubleExpression extends NumberExpressionBase implements ObservableDoubleValue +{ + public Double getValue(){ return null; } + public DoubleBinding add(ObservableNumberValue p0){ return null; } + public DoubleBinding add(double p0){ return null; } + public DoubleBinding add(float p0){ return null; } + public DoubleBinding add(int p0){ return null; } + public DoubleBinding add(long p0){ return null; } + public DoubleBinding divide(ObservableNumberValue p0){ return null; } + public DoubleBinding divide(double p0){ return null; } + public DoubleBinding divide(float p0){ return null; } + public DoubleBinding divide(int p0){ return null; } + public DoubleBinding divide(long p0){ return null; } + public DoubleBinding multiply(ObservableNumberValue p0){ return null; } + public DoubleBinding multiply(double p0){ return null; } + public DoubleBinding multiply(float p0){ return null; } + public DoubleBinding multiply(int p0){ return null; } + public DoubleBinding multiply(long p0){ return null; } + public DoubleBinding negate(){ return null; } + public DoubleBinding subtract(ObservableNumberValue p0){ return null; } + public DoubleBinding subtract(double p0){ return null; } + public DoubleBinding subtract(float p0){ return null; } + public DoubleBinding subtract(int p0){ return null; } + public DoubleBinding subtract(long p0){ return null; } + public DoubleExpression(){} + public ObjectExpression asObject(){ return null; } + public double doubleValue(){ return 0; } + public float floatValue(){ return 0; } + public int intValue(){ return 0; } + public long longValue(){ return 0; } + public static DoubleExpression doubleExpression(javafx.beans.value.ObservableValue p0){ return null; } + public static DoubleExpression doubleExpression(ObservableDoubleValue p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/binding/FloatBinding.java b/java/ql/test/stubs/javafx-web/javafx/beans/binding/FloatBinding.java new file mode 100644 index 00000000000..0db30664dc6 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/binding/FloatBinding.java @@ -0,0 +1,29 @@ +// Generated automatically from javafx.beans.binding.FloatBinding for testing purposes + +package javafx.beans.binding; + +import javafx.beans.InvalidationListener; +import javafx.beans.Observable; +import javafx.beans.binding.FloatExpression; +import javafx.beans.binding.NumberBinding; +import javafx.beans.value.ChangeListener; +import javafx.collections.ObservableList; + +abstract public class FloatBinding extends FloatExpression implements NumberBinding +{ + protected abstract float computeValue(); + protected final void bind(Observable... p0){} + protected final void unbind(Observable... p0){} + protected void onInvalidating(){} + public FloatBinding(){} + public ObservableList getDependencies(){ return null; } + public String toString(){ return null; } + public final boolean isValid(){ return false; } + public final float get(){ return 0; } + public final void invalidate(){} + public void addListener(ChangeListener p0){} + public void addListener(InvalidationListener p0){} + public void dispose(){} + public void removeListener(ChangeListener p0){} + public void removeListener(InvalidationListener p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/binding/FloatExpression.java b/java/ql/test/stubs/javafx-web/javafx/beans/binding/FloatExpression.java new file mode 100644 index 00000000000..2aaba3e4034 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/binding/FloatExpression.java @@ -0,0 +1,40 @@ +// Generated automatically from javafx.beans.binding.FloatExpression for testing purposes + +package javafx.beans.binding; + +import javafx.beans.binding.DoubleBinding; +import javafx.beans.binding.FloatBinding; +import javafx.beans.binding.NumberExpressionBase; +import javafx.beans.binding.ObjectExpression; +import javafx.beans.value.ObservableFloatValue; +import javafx.beans.value.ObservableValue; + +abstract public class FloatExpression extends NumberExpressionBase implements ObservableFloatValue +{ + public DoubleBinding add(double p0){ return null; } + public DoubleBinding divide(double p0){ return null; } + public DoubleBinding multiply(double p0){ return null; } + public DoubleBinding subtract(double p0){ return null; } + public Float getValue(){ return null; } + public FloatBinding add(float p0){ return null; } + public FloatBinding add(int p0){ return null; } + public FloatBinding add(long p0){ return null; } + public FloatBinding divide(float p0){ return null; } + public FloatBinding divide(int p0){ return null; } + public FloatBinding divide(long p0){ return null; } + public FloatBinding multiply(float p0){ return null; } + public FloatBinding multiply(int p0){ return null; } + public FloatBinding multiply(long p0){ return null; } + public FloatBinding negate(){ return null; } + public FloatBinding subtract(float p0){ return null; } + public FloatBinding subtract(int p0){ return null; } + public FloatBinding subtract(long p0){ return null; } + public FloatExpression(){} + public ObjectExpression asObject(){ return null; } + public double doubleValue(){ return 0; } + public float floatValue(){ return 0; } + public int intValue(){ return 0; } + public long longValue(){ return 0; } + public static FloatExpression floatExpression(javafx.beans.value.ObservableValue p0){ return null; } + public static FloatExpression floatExpression(ObservableFloatValue p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/binding/IntegerBinding.java b/java/ql/test/stubs/javafx-web/javafx/beans/binding/IntegerBinding.java new file mode 100644 index 00000000000..f15f45d9a99 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/binding/IntegerBinding.java @@ -0,0 +1,29 @@ +// Generated automatically from javafx.beans.binding.IntegerBinding for testing purposes + +package javafx.beans.binding; + +import javafx.beans.InvalidationListener; +import javafx.beans.Observable; +import javafx.beans.binding.IntegerExpression; +import javafx.beans.binding.NumberBinding; +import javafx.beans.value.ChangeListener; +import javafx.collections.ObservableList; + +abstract public class IntegerBinding extends IntegerExpression implements NumberBinding +{ + protected abstract int computeValue(); + protected final void bind(Observable... p0){} + protected final void unbind(Observable... p0){} + protected void onInvalidating(){} + public IntegerBinding(){} + public ObservableList getDependencies(){ return null; } + public String toString(){ return null; } + public final boolean isValid(){ return false; } + public final int get(){ return 0; } + public final void invalidate(){} + public void addListener(ChangeListener p0){} + public void addListener(InvalidationListener p0){} + public void dispose(){} + public void removeListener(ChangeListener p0){} + public void removeListener(InvalidationListener p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/binding/IntegerExpression.java b/java/ql/test/stubs/javafx-web/javafx/beans/binding/IntegerExpression.java new file mode 100644 index 00000000000..24fab5ecd60 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/binding/IntegerExpression.java @@ -0,0 +1,42 @@ +// Generated automatically from javafx.beans.binding.IntegerExpression for testing purposes + +package javafx.beans.binding; + +import javafx.beans.binding.DoubleBinding; +import javafx.beans.binding.FloatBinding; +import javafx.beans.binding.IntegerBinding; +import javafx.beans.binding.LongBinding; +import javafx.beans.binding.NumberExpressionBase; +import javafx.beans.binding.ObjectExpression; +import javafx.beans.value.ObservableIntegerValue; +import javafx.beans.value.ObservableValue; + +abstract public class IntegerExpression extends NumberExpressionBase implements ObservableIntegerValue +{ + public DoubleBinding add(double p0){ return null; } + public DoubleBinding divide(double p0){ return null; } + public DoubleBinding multiply(double p0){ return null; } + public DoubleBinding subtract(double p0){ return null; } + public FloatBinding add(float p0){ return null; } + public FloatBinding divide(float p0){ return null; } + public FloatBinding multiply(float p0){ return null; } + public FloatBinding subtract(float p0){ return null; } + public Integer getValue(){ return null; } + public IntegerBinding add(int p0){ return null; } + public IntegerBinding divide(int p0){ return null; } + public IntegerBinding multiply(int p0){ return null; } + public IntegerBinding negate(){ return null; } + public IntegerBinding subtract(int p0){ return null; } + public IntegerExpression(){} + public LongBinding add(long p0){ return null; } + public LongBinding divide(long p0){ return null; } + public LongBinding multiply(long p0){ return null; } + public LongBinding subtract(long p0){ return null; } + public ObjectExpression asObject(){ return null; } + public double doubleValue(){ return 0; } + public float floatValue(){ return 0; } + public int intValue(){ return 0; } + public long longValue(){ return 0; } + public static IntegerExpression integerExpression(javafx.beans.value.ObservableValue p0){ return null; } + public static IntegerExpression integerExpression(ObservableIntegerValue p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/binding/LongBinding.java b/java/ql/test/stubs/javafx-web/javafx/beans/binding/LongBinding.java new file mode 100644 index 00000000000..90c872ddf87 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/binding/LongBinding.java @@ -0,0 +1,29 @@ +// Generated automatically from javafx.beans.binding.LongBinding for testing purposes + +package javafx.beans.binding; + +import javafx.beans.InvalidationListener; +import javafx.beans.Observable; +import javafx.beans.binding.LongExpression; +import javafx.beans.binding.NumberBinding; +import javafx.beans.value.ChangeListener; +import javafx.collections.ObservableList; + +abstract public class LongBinding extends LongExpression implements NumberBinding +{ + protected abstract long computeValue(); + protected final void bind(Observable... p0){} + protected final void unbind(Observable... p0){} + protected void onInvalidating(){} + public LongBinding(){} + public ObservableList getDependencies(){ return null; } + public String toString(){ return null; } + public final boolean isValid(){ return false; } + public final long get(){ return 0; } + public final void invalidate(){} + public void addListener(ChangeListener p0){} + public void addListener(InvalidationListener p0){} + public void dispose(){} + public void removeListener(ChangeListener p0){} + public void removeListener(InvalidationListener p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/binding/LongExpression.java b/java/ql/test/stubs/javafx-web/javafx/beans/binding/LongExpression.java new file mode 100644 index 00000000000..c27444d3243 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/binding/LongExpression.java @@ -0,0 +1,41 @@ +// Generated automatically from javafx.beans.binding.LongExpression for testing purposes + +package javafx.beans.binding; + +import javafx.beans.binding.DoubleBinding; +import javafx.beans.binding.FloatBinding; +import javafx.beans.binding.LongBinding; +import javafx.beans.binding.NumberExpressionBase; +import javafx.beans.binding.ObjectExpression; +import javafx.beans.value.ObservableLongValue; +import javafx.beans.value.ObservableValue; + +abstract public class LongExpression extends NumberExpressionBase implements ObservableLongValue +{ + public DoubleBinding add(double p0){ return null; } + public DoubleBinding divide(double p0){ return null; } + public DoubleBinding multiply(double p0){ return null; } + public DoubleBinding subtract(double p0){ return null; } + public FloatBinding add(float p0){ return null; } + public FloatBinding divide(float p0){ return null; } + public FloatBinding multiply(float p0){ return null; } + public FloatBinding subtract(float p0){ return null; } + public Long getValue(){ return null; } + public LongBinding add(int p0){ return null; } + public LongBinding add(long p0){ return null; } + public LongBinding divide(int p0){ return null; } + public LongBinding divide(long p0){ return null; } + public LongBinding multiply(int p0){ return null; } + public LongBinding multiply(long p0){ return null; } + public LongBinding negate(){ return null; } + public LongBinding subtract(int p0){ return null; } + public LongBinding subtract(long p0){ return null; } + public LongExpression(){} + public ObjectExpression asObject(){ return null; } + public double doubleValue(){ return 0; } + public float floatValue(){ return 0; } + public int intValue(){ return 0; } + public long longValue(){ return 0; } + public static LongExpression longExpression(javafx.beans.value.ObservableValue p0){ return null; } + public static LongExpression longExpression(ObservableLongValue p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/binding/NumberBinding.java b/java/ql/test/stubs/javafx-web/javafx/beans/binding/NumberBinding.java new file mode 100644 index 00000000000..893219bb85c --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/binding/NumberBinding.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.beans.binding.NumberBinding for testing purposes + +package javafx.beans.binding; + +import javafx.beans.binding.Binding; +import javafx.beans.binding.NumberExpression; + +public interface NumberBinding extends Binding, NumberExpression +{ +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/binding/NumberExpression.java b/java/ql/test/stubs/javafx-web/javafx/beans/binding/NumberExpression.java new file mode 100644 index 00000000000..e6c2a118a5c --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/binding/NumberExpression.java @@ -0,0 +1,73 @@ +// Generated automatically from javafx.beans.binding.NumberExpression for testing purposes + +package javafx.beans.binding; + +import java.util.Locale; +import javafx.beans.binding.BooleanBinding; +import javafx.beans.binding.NumberBinding; +import javafx.beans.binding.StringBinding; +import javafx.beans.value.ObservableNumberValue; + +public interface NumberExpression extends ObservableNumberValue +{ + BooleanBinding greaterThan(ObservableNumberValue p0); + BooleanBinding greaterThan(double p0); + BooleanBinding greaterThan(float p0); + BooleanBinding greaterThan(int p0); + BooleanBinding greaterThan(long p0); + BooleanBinding greaterThanOrEqualTo(ObservableNumberValue p0); + BooleanBinding greaterThanOrEqualTo(double p0); + BooleanBinding greaterThanOrEqualTo(float p0); + BooleanBinding greaterThanOrEqualTo(int p0); + BooleanBinding greaterThanOrEqualTo(long p0); + BooleanBinding isEqualTo(ObservableNumberValue p0); + BooleanBinding isEqualTo(ObservableNumberValue p0, double p1); + BooleanBinding isEqualTo(double p0, double p1); + BooleanBinding isEqualTo(float p0, double p1); + BooleanBinding isEqualTo(int p0); + BooleanBinding isEqualTo(int p0, double p1); + BooleanBinding isEqualTo(long p0); + BooleanBinding isEqualTo(long p0, double p1); + BooleanBinding isNotEqualTo(ObservableNumberValue p0); + BooleanBinding isNotEqualTo(ObservableNumberValue p0, double p1); + BooleanBinding isNotEqualTo(double p0, double p1); + BooleanBinding isNotEqualTo(float p0, double p1); + BooleanBinding isNotEqualTo(int p0); + BooleanBinding isNotEqualTo(int p0, double p1); + BooleanBinding isNotEqualTo(long p0); + BooleanBinding isNotEqualTo(long p0, double p1); + BooleanBinding lessThan(ObservableNumberValue p0); + BooleanBinding lessThan(double p0); + BooleanBinding lessThan(float p0); + BooleanBinding lessThan(int p0); + BooleanBinding lessThan(long p0); + BooleanBinding lessThanOrEqualTo(ObservableNumberValue p0); + BooleanBinding lessThanOrEqualTo(double p0); + BooleanBinding lessThanOrEqualTo(float p0); + BooleanBinding lessThanOrEqualTo(int p0); + BooleanBinding lessThanOrEqualTo(long p0); + NumberBinding add(ObservableNumberValue p0); + NumberBinding add(double p0); + NumberBinding add(float p0); + NumberBinding add(int p0); + NumberBinding add(long p0); + NumberBinding divide(ObservableNumberValue p0); + NumberBinding divide(double p0); + NumberBinding divide(float p0); + NumberBinding divide(int p0); + NumberBinding divide(long p0); + NumberBinding multiply(ObservableNumberValue p0); + NumberBinding multiply(double p0); + NumberBinding multiply(float p0); + NumberBinding multiply(int p0); + NumberBinding multiply(long p0); + NumberBinding negate(); + NumberBinding subtract(ObservableNumberValue p0); + NumberBinding subtract(double p0); + NumberBinding subtract(float p0); + NumberBinding subtract(int p0); + NumberBinding subtract(long p0); + StringBinding asString(); + StringBinding asString(Locale p0, String p1); + StringBinding asString(String p0); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/binding/NumberExpressionBase.java b/java/ql/test/stubs/javafx-web/javafx/beans/binding/NumberExpressionBase.java new file mode 100644 index 00000000000..5cce40064d1 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/binding/NumberExpressionBase.java @@ -0,0 +1,59 @@ +// Generated automatically from javafx.beans.binding.NumberExpressionBase for testing purposes + +package javafx.beans.binding; + +import java.util.Locale; +import javafx.beans.binding.BooleanBinding; +import javafx.beans.binding.NumberBinding; +import javafx.beans.binding.NumberExpression; +import javafx.beans.binding.StringBinding; +import javafx.beans.value.ObservableNumberValue; + +abstract public class NumberExpressionBase implements NumberExpression +{ + public BooleanBinding greaterThan(ObservableNumberValue p0){ return null; } + public BooleanBinding greaterThan(double p0){ return null; } + public BooleanBinding greaterThan(float p0){ return null; } + public BooleanBinding greaterThan(int p0){ return null; } + public BooleanBinding greaterThan(long p0){ return null; } + public BooleanBinding greaterThanOrEqualTo(ObservableNumberValue p0){ return null; } + public BooleanBinding greaterThanOrEqualTo(double p0){ return null; } + public BooleanBinding greaterThanOrEqualTo(float p0){ return null; } + public BooleanBinding greaterThanOrEqualTo(int p0){ return null; } + public BooleanBinding greaterThanOrEqualTo(long p0){ return null; } + public BooleanBinding isEqualTo(ObservableNumberValue p0){ return null; } + public BooleanBinding isEqualTo(ObservableNumberValue p0, double p1){ return null; } + public BooleanBinding isEqualTo(double p0, double p1){ return null; } + public BooleanBinding isEqualTo(float p0, double p1){ return null; } + public BooleanBinding isEqualTo(int p0){ return null; } + public BooleanBinding isEqualTo(int p0, double p1){ return null; } + public BooleanBinding isEqualTo(long p0){ return null; } + public BooleanBinding isEqualTo(long p0, double p1){ return null; } + public BooleanBinding isNotEqualTo(ObservableNumberValue p0){ return null; } + public BooleanBinding isNotEqualTo(ObservableNumberValue p0, double p1){ return null; } + public BooleanBinding isNotEqualTo(double p0, double p1){ return null; } + public BooleanBinding isNotEqualTo(float p0, double p1){ return null; } + public BooleanBinding isNotEqualTo(int p0){ return null; } + public BooleanBinding isNotEqualTo(int p0, double p1){ return null; } + public BooleanBinding isNotEqualTo(long p0){ return null; } + public BooleanBinding isNotEqualTo(long p0, double p1){ return null; } + public BooleanBinding lessThan(ObservableNumberValue p0){ return null; } + public BooleanBinding lessThan(double p0){ return null; } + public BooleanBinding lessThan(float p0){ return null; } + public BooleanBinding lessThan(int p0){ return null; } + public BooleanBinding lessThan(long p0){ return null; } + public BooleanBinding lessThanOrEqualTo(ObservableNumberValue p0){ return null; } + public BooleanBinding lessThanOrEqualTo(double p0){ return null; } + public BooleanBinding lessThanOrEqualTo(float p0){ return null; } + public BooleanBinding lessThanOrEqualTo(int p0){ return null; } + public BooleanBinding lessThanOrEqualTo(long p0){ return null; } + public NumberBinding add(ObservableNumberValue p0){ return null; } + public NumberBinding divide(ObservableNumberValue p0){ return null; } + public NumberBinding multiply(ObservableNumberValue p0){ return null; } + public NumberBinding subtract(ObservableNumberValue p0){ return null; } + public NumberExpressionBase(){} + public StringBinding asString(){ return null; } + public StringBinding asString(Locale p0, String p1){ return null; } + public StringBinding asString(String p0){ return null; } + public static NumberExpressionBase numberExpression(ObservableNumberValue p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/binding/ObjectExpression.java b/java/ql/test/stubs/javafx-web/javafx/beans/binding/ObjectExpression.java new file mode 100644 index 00000000000..de7a09b8113 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/binding/ObjectExpression.java @@ -0,0 +1,24 @@ +// Generated automatically from javafx.beans.binding.ObjectExpression for testing purposes + +package javafx.beans.binding; + +import java.util.Locale; +import javafx.beans.binding.BooleanBinding; +import javafx.beans.binding.StringBinding; +import javafx.beans.value.ObservableObjectValue; + +abstract public class ObjectExpression implements javafx.beans.value.ObservableObjectValue +{ + public BooleanBinding isEqualTo(Object p0){ return null; } + public BooleanBinding isEqualTo(ObservableObjectValue p0){ return null; } + public BooleanBinding isNotEqualTo(Object p0){ return null; } + public BooleanBinding isNotEqualTo(ObservableObjectValue p0){ return null; } + public BooleanBinding isNotNull(){ return null; } + public BooleanBinding isNull(){ return null; } + public ObjectExpression(){} + public StringBinding asString(){ return null; } + public StringBinding asString(Locale p0, String p1){ return null; } + public StringBinding asString(String p0){ return null; } + public T getValue(){ return null; } + public static javafx.beans.binding.ObjectExpression objectExpression(javafx.beans.value.ObservableObjectValue p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/binding/StringBinding.java b/java/ql/test/stubs/javafx-web/javafx/beans/binding/StringBinding.java new file mode 100644 index 00000000000..bd2a844ff79 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/binding/StringBinding.java @@ -0,0 +1,29 @@ +// Generated automatically from javafx.beans.binding.StringBinding for testing purposes + +package javafx.beans.binding; + +import javafx.beans.InvalidationListener; +import javafx.beans.Observable; +import javafx.beans.binding.Binding; +import javafx.beans.binding.StringExpression; +import javafx.beans.value.ChangeListener; +import javafx.collections.ObservableList; + +abstract public class StringBinding extends StringExpression implements Binding +{ + protected abstract String computeValue(); + protected final void bind(Observable... p0){} + protected final void unbind(Observable... p0){} + protected void onInvalidating(){} + public ObservableList getDependencies(){ return null; } + public String toString(){ return null; } + public StringBinding(){} + public final String get(){ return null; } + public final boolean isValid(){ return false; } + public final void invalidate(){} + public void addListener(ChangeListener p0){} + public void addListener(InvalidationListener p0){} + public void dispose(){} + public void removeListener(ChangeListener p0){} + public void removeListener(InvalidationListener p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/binding/StringExpression.java b/java/ql/test/stubs/javafx-web/javafx/beans/binding/StringExpression.java new file mode 100644 index 00000000000..4d7d53ec5b4 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/binding/StringExpression.java @@ -0,0 +1,38 @@ +// Generated automatically from javafx.beans.binding.StringExpression for testing purposes + +package javafx.beans.binding; + +import javafx.beans.binding.BooleanBinding; +import javafx.beans.binding.IntegerBinding; +import javafx.beans.value.ObservableStringValue; +import javafx.beans.value.ObservableValue; + +abstract public class StringExpression implements ObservableStringValue +{ + public BooleanBinding greaterThan(ObservableStringValue p0){ return null; } + public BooleanBinding greaterThan(String p0){ return null; } + public BooleanBinding greaterThanOrEqualTo(ObservableStringValue p0){ return null; } + public BooleanBinding greaterThanOrEqualTo(String p0){ return null; } + public BooleanBinding isEmpty(){ return null; } + public BooleanBinding isEqualTo(ObservableStringValue p0){ return null; } + public BooleanBinding isEqualTo(String p0){ return null; } + public BooleanBinding isEqualToIgnoreCase(ObservableStringValue p0){ return null; } + public BooleanBinding isEqualToIgnoreCase(String p0){ return null; } + public BooleanBinding isNotEmpty(){ return null; } + public BooleanBinding isNotEqualTo(ObservableStringValue p0){ return null; } + public BooleanBinding isNotEqualTo(String p0){ return null; } + public BooleanBinding isNotEqualToIgnoreCase(ObservableStringValue p0){ return null; } + public BooleanBinding isNotEqualToIgnoreCase(String p0){ return null; } + public BooleanBinding isNotNull(){ return null; } + public BooleanBinding isNull(){ return null; } + public BooleanBinding lessThan(ObservableStringValue p0){ return null; } + public BooleanBinding lessThan(String p0){ return null; } + public BooleanBinding lessThanOrEqualTo(ObservableStringValue p0){ return null; } + public BooleanBinding lessThanOrEqualTo(String p0){ return null; } + public IntegerBinding length(){ return null; } + public String getValue(){ return null; } + public StringExpression concat(Object p0){ return null; } + public StringExpression(){} + public final String getValueSafe(){ return null; } + public static StringExpression stringExpression(ObservableValue p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/property/BooleanProperty.java b/java/ql/test/stubs/javafx-web/javafx/beans/property/BooleanProperty.java new file mode 100644 index 00000000000..88dd6f25909 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/property/BooleanProperty.java @@ -0,0 +1,19 @@ +// Generated automatically from javafx.beans.property.BooleanProperty for testing purposes + +package javafx.beans.property; + +import javafx.beans.property.ObjectProperty; +import javafx.beans.property.Property; +import javafx.beans.property.ReadOnlyBooleanProperty; +import javafx.beans.value.WritableBooleanValue; + +abstract public class BooleanProperty extends ReadOnlyBooleanProperty implements Property, WritableBooleanValue +{ + public BooleanProperty(){} + public ObjectProperty asObject(){ return null; } + public String toString(){ return null; } + public static BooleanProperty booleanProperty(Property p0){ return null; } + public void bindBidirectional(Property p0){} + public void setValue(Boolean p0){} + public void unbindBidirectional(Property p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/property/DoubleProperty.java b/java/ql/test/stubs/javafx-web/javafx/beans/property/DoubleProperty.java new file mode 100644 index 00000000000..e69c881f78a --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/property/DoubleProperty.java @@ -0,0 +1,19 @@ +// Generated automatically from javafx.beans.property.DoubleProperty for testing purposes + +package javafx.beans.property; + +import javafx.beans.property.ObjectProperty; +import javafx.beans.property.Property; +import javafx.beans.property.ReadOnlyDoubleProperty; +import javafx.beans.value.WritableDoubleValue; + +abstract public class DoubleProperty extends ReadOnlyDoubleProperty implements Property, WritableDoubleValue +{ + public DoubleProperty(){} + public ObjectProperty asObject(){ return null; } + public String toString(){ return null; } + public static DoubleProperty doubleProperty(Property p0){ return null; } + public void bindBidirectional(Property p0){} + public void setValue(Number p0){} + public void unbindBidirectional(Property p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/property/IntegerProperty.java b/java/ql/test/stubs/javafx-web/javafx/beans/property/IntegerProperty.java new file mode 100644 index 00000000000..d33c8230365 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/property/IntegerProperty.java @@ -0,0 +1,19 @@ +// Generated automatically from javafx.beans.property.IntegerProperty for testing purposes + +package javafx.beans.property; + +import javafx.beans.property.ObjectProperty; +import javafx.beans.property.Property; +import javafx.beans.property.ReadOnlyIntegerProperty; +import javafx.beans.value.WritableIntegerValue; + +abstract public class IntegerProperty extends ReadOnlyIntegerProperty implements Property, WritableIntegerValue +{ + public IntegerProperty(){} + public ObjectProperty asObject(){ return null; } + public String toString(){ return null; } + public static IntegerProperty integerProperty(Property p0){ return null; } + public void bindBidirectional(Property p0){} + public void setValue(Number p0){} + public void unbindBidirectional(Property p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/property/ObjectProperty.java b/java/ql/test/stubs/javafx-web/javafx/beans/property/ObjectProperty.java new file mode 100644 index 00000000000..56db4fb7af0 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/property/ObjectProperty.java @@ -0,0 +1,16 @@ +// Generated automatically from javafx.beans.property.ObjectProperty for testing purposes + +package javafx.beans.property; + +import javafx.beans.property.Property; +import javafx.beans.property.ReadOnlyObjectProperty; +import javafx.beans.value.WritableObjectValue; + +abstract public class ObjectProperty extends ReadOnlyObjectProperty implements WritableObjectValue, javafx.beans.property.Property +{ + public ObjectProperty(){} + public String toString(){ return null; } + public void bindBidirectional(javafx.beans.property.Property p0){} + public void setValue(T p0){} + public void unbindBidirectional(javafx.beans.property.Property p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/property/Property.java b/java/ql/test/stubs/javafx-web/javafx/beans/property/Property.java new file mode 100644 index 00000000000..13f3b3e2c4b --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/property/Property.java @@ -0,0 +1,16 @@ +// Generated automatically from javafx.beans.property.Property for testing purposes + +package javafx.beans.property; + +import javafx.beans.property.ReadOnlyProperty; +import javafx.beans.value.ObservableValue; +import javafx.beans.value.WritableValue; + +public interface Property extends javafx.beans.property.ReadOnlyProperty, javafx.beans.value.WritableValue +{ + boolean isBound(); + void bind(javafx.beans.value.ObservableValue p0); + void bindBidirectional(Property p0); + void unbind(); + void unbindBidirectional(Property p0); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyBooleanProperty.java b/java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyBooleanProperty.java new file mode 100644 index 00000000000..d18dde7c3d2 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyBooleanProperty.java @@ -0,0 +1,15 @@ +// Generated automatically from javafx.beans.property.ReadOnlyBooleanProperty for testing purposes + +package javafx.beans.property; + +import javafx.beans.binding.BooleanExpression; +import javafx.beans.property.ReadOnlyObjectProperty; +import javafx.beans.property.ReadOnlyProperty; + +abstract public class ReadOnlyBooleanProperty extends BooleanExpression implements ReadOnlyProperty +{ + public ReadOnlyBooleanProperty(){} + public ReadOnlyObjectProperty asObject(){ return null; } + public String toString(){ return null; } + public static ReadOnlyBooleanProperty readOnlyBooleanProperty(ReadOnlyProperty p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyBooleanPropertyBase.java b/java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyBooleanPropertyBase.java new file mode 100644 index 00000000000..aaba27ff4bc --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyBooleanPropertyBase.java @@ -0,0 +1,17 @@ +// Generated automatically from javafx.beans.property.ReadOnlyBooleanPropertyBase for testing purposes + +package javafx.beans.property; + +import javafx.beans.InvalidationListener; +import javafx.beans.property.ReadOnlyBooleanProperty; +import javafx.beans.value.ChangeListener; + +abstract public class ReadOnlyBooleanPropertyBase extends ReadOnlyBooleanProperty +{ + protected void fireValueChangedEvent(){} + public ReadOnlyBooleanPropertyBase(){} + public void addListener(ChangeListener p0){} + public void addListener(InvalidationListener p0){} + public void removeListener(ChangeListener p0){} + public void removeListener(InvalidationListener p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyDoubleProperty.java b/java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyDoubleProperty.java new file mode 100644 index 00000000000..f05c2edb588 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyDoubleProperty.java @@ -0,0 +1,15 @@ +// Generated automatically from javafx.beans.property.ReadOnlyDoubleProperty for testing purposes + +package javafx.beans.property; + +import javafx.beans.binding.DoubleExpression; +import javafx.beans.property.ReadOnlyObjectProperty; +import javafx.beans.property.ReadOnlyProperty; + +abstract public class ReadOnlyDoubleProperty extends DoubleExpression implements ReadOnlyProperty +{ + public ReadOnlyDoubleProperty(){} + public ReadOnlyObjectProperty asObject(){ return null; } + public String toString(){ return null; } + public static ReadOnlyDoubleProperty readOnlyDoubleProperty(javafx.beans.property.ReadOnlyProperty p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyIntegerProperty.java b/java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyIntegerProperty.java new file mode 100644 index 00000000000..2d65e925e07 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyIntegerProperty.java @@ -0,0 +1,15 @@ +// Generated automatically from javafx.beans.property.ReadOnlyIntegerProperty for testing purposes + +package javafx.beans.property; + +import javafx.beans.binding.IntegerExpression; +import javafx.beans.property.ReadOnlyObjectProperty; +import javafx.beans.property.ReadOnlyProperty; + +abstract public class ReadOnlyIntegerProperty extends IntegerExpression implements ReadOnlyProperty +{ + public ReadOnlyIntegerProperty(){} + public ReadOnlyObjectProperty asObject(){ return null; } + public String toString(){ return null; } + public static ReadOnlyIntegerProperty readOnlyIntegerProperty(javafx.beans.property.ReadOnlyProperty p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyObjectProperty.java b/java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyObjectProperty.java new file mode 100644 index 00000000000..dc4367f6869 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyObjectProperty.java @@ -0,0 +1,12 @@ +// Generated automatically from javafx.beans.property.ReadOnlyObjectProperty for testing purposes + +package javafx.beans.property; + +import javafx.beans.binding.ObjectExpression; +import javafx.beans.property.ReadOnlyProperty; + +abstract public class ReadOnlyObjectProperty extends javafx.beans.binding.ObjectExpression implements javafx.beans.property.ReadOnlyProperty +{ + public ReadOnlyObjectProperty(){} + public String toString(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyProperty.java b/java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyProperty.java new file mode 100644 index 00000000000..2122b130fb7 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyProperty.java @@ -0,0 +1,11 @@ +// Generated automatically from javafx.beans.property.ReadOnlyProperty for testing purposes + +package javafx.beans.property; + +import javafx.beans.value.ObservableValue; + +public interface ReadOnlyProperty extends javafx.beans.value.ObservableValue +{ + Object getBean(); + String getName(); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyStringProperty.java b/java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyStringProperty.java new file mode 100644 index 00000000000..2a245ee1b0a --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/property/ReadOnlyStringProperty.java @@ -0,0 +1,12 @@ +// Generated automatically from javafx.beans.property.ReadOnlyStringProperty for testing purposes + +package javafx.beans.property; + +import javafx.beans.binding.StringExpression; +import javafx.beans.property.ReadOnlyProperty; + +abstract public class ReadOnlyStringProperty extends StringExpression implements ReadOnlyProperty +{ + public ReadOnlyStringProperty(){} + public String toString(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/property/StringProperty.java b/java/ql/test/stubs/javafx-web/javafx/beans/property/StringProperty.java new file mode 100644 index 00000000000..2b8702bbbf4 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/property/StringProperty.java @@ -0,0 +1,21 @@ +// Generated automatically from javafx.beans.property.StringProperty for testing purposes + +package javafx.beans.property; + +import java.text.Format; +import javafx.beans.property.Property; +import javafx.beans.property.ReadOnlyStringProperty; +import javafx.beans.value.WritableStringValue; +import javafx.util.StringConverter; + +abstract public class StringProperty extends ReadOnlyStringProperty implements Property, WritableStringValue +{ + public void bindBidirectional(javafx.beans.property.Property p0, StringConverter p1){} + public String toString(){ return null; } + public StringProperty(){} + public void bindBidirectional(Property p0, Format p1){} + public void bindBidirectional(Property p0){} + public void setValue(String p0){} + public void unbindBidirectional(Object p0){} + public void unbindBidirectional(Property p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/value/ChangeListener.java b/java/ql/test/stubs/javafx-web/javafx/beans/value/ChangeListener.java new file mode 100644 index 00000000000..922672e76a3 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/value/ChangeListener.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.beans.value.ChangeListener for testing purposes + +package javafx.beans.value; + +import javafx.beans.value.ObservableValue; + +public interface ChangeListener +{ + void changed(javafx.beans.value.ObservableValue p0, T p1, T p2); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableBooleanValue.java b/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableBooleanValue.java new file mode 100644 index 00000000000..aa0f987cdd0 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableBooleanValue.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.beans.value.ObservableBooleanValue for testing purposes + +package javafx.beans.value; + +import javafx.beans.value.ObservableValue; + +public interface ObservableBooleanValue extends ObservableValue +{ + boolean get(); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableDoubleValue.java b/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableDoubleValue.java new file mode 100644 index 00000000000..687e53a65f9 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableDoubleValue.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.beans.value.ObservableDoubleValue for testing purposes + +package javafx.beans.value; + +import javafx.beans.value.ObservableNumberValue; + +public interface ObservableDoubleValue extends ObservableNumberValue +{ + double get(); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableFloatValue.java b/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableFloatValue.java new file mode 100644 index 00000000000..a397d00e9be --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableFloatValue.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.beans.value.ObservableFloatValue for testing purposes + +package javafx.beans.value; + +import javafx.beans.value.ObservableNumberValue; + +public interface ObservableFloatValue extends ObservableNumberValue +{ + float get(); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableIntegerValue.java b/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableIntegerValue.java new file mode 100644 index 00000000000..597d2f1a8cc --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableIntegerValue.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.beans.value.ObservableIntegerValue for testing purposes + +package javafx.beans.value; + +import javafx.beans.value.ObservableNumberValue; + +public interface ObservableIntegerValue extends ObservableNumberValue +{ + int get(); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableLongValue.java b/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableLongValue.java new file mode 100644 index 00000000000..d665fb71c53 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableLongValue.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.beans.value.ObservableLongValue for testing purposes + +package javafx.beans.value; + +import javafx.beans.value.ObservableNumberValue; + +public interface ObservableLongValue extends ObservableNumberValue +{ + long get(); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableNumberValue.java b/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableNumberValue.java new file mode 100644 index 00000000000..036cabc0d81 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableNumberValue.java @@ -0,0 +1,13 @@ +// Generated automatically from javafx.beans.value.ObservableNumberValue for testing purposes + +package javafx.beans.value; + +import javafx.beans.value.ObservableValue; + +public interface ObservableNumberValue extends ObservableValue +{ + double doubleValue(); + float floatValue(); + int intValue(); + long longValue(); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableObjectValue.java b/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableObjectValue.java new file mode 100644 index 00000000000..cdb260b1c2c --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableObjectValue.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.beans.value.ObservableObjectValue for testing purposes + +package javafx.beans.value; + +import javafx.beans.value.ObservableValue; + +public interface ObservableObjectValue extends javafx.beans.value.ObservableValue +{ + T get(); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableStringValue.java b/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableStringValue.java new file mode 100644 index 00000000000..a7152ace61d --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableStringValue.java @@ -0,0 +1,9 @@ +// Generated automatically from javafx.beans.value.ObservableStringValue for testing purposes + +package javafx.beans.value; + +import javafx.beans.value.ObservableObjectValue; + +public interface ObservableStringValue extends ObservableObjectValue +{ +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableValue.java b/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableValue.java new file mode 100644 index 00000000000..fcfbe2e0ee6 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/value/ObservableValue.java @@ -0,0 +1,18 @@ +// Generated automatically from javafx.beans.value.ObservableValue for testing purposes + +package javafx.beans.value; + +import java.util.function.Function; +import javafx.beans.Observable; +import javafx.beans.value.ChangeListener; + +public interface ObservableValue extends Observable +{ + T getValue(); + default javafx.beans.value.ObservableValue flatMap(java.util.function.Function> p0){ return null; } + default javafx.beans.value.ObservableValue map(java.util.function.Function p0){ return null; } + default ObservableValue orElse(T p0){ return null; } + default ObservableValue when(ObservableValue p0){ return null; } + void addListener(javafx.beans.value.ChangeListener p0); + void removeListener(javafx.beans.value.ChangeListener p0); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/value/WritableBooleanValue.java b/java/ql/test/stubs/javafx-web/javafx/beans/value/WritableBooleanValue.java new file mode 100644 index 00000000000..f26fc72ee96 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/value/WritableBooleanValue.java @@ -0,0 +1,12 @@ +// Generated automatically from javafx.beans.value.WritableBooleanValue for testing purposes + +package javafx.beans.value; + +import javafx.beans.value.WritableValue; + +public interface WritableBooleanValue extends WritableValue +{ + boolean get(); + void set(boolean p0); + void setValue(Boolean p0); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/value/WritableDoubleValue.java b/java/ql/test/stubs/javafx-web/javafx/beans/value/WritableDoubleValue.java new file mode 100644 index 00000000000..c44f6e2b3d3 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/value/WritableDoubleValue.java @@ -0,0 +1,12 @@ +// Generated automatically from javafx.beans.value.WritableDoubleValue for testing purposes + +package javafx.beans.value; + +import javafx.beans.value.WritableNumberValue; + +public interface WritableDoubleValue extends WritableNumberValue +{ + double get(); + void set(double p0); + void setValue(Number p0); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/value/WritableIntegerValue.java b/java/ql/test/stubs/javafx-web/javafx/beans/value/WritableIntegerValue.java new file mode 100644 index 00000000000..44348dc480f --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/value/WritableIntegerValue.java @@ -0,0 +1,12 @@ +// Generated automatically from javafx.beans.value.WritableIntegerValue for testing purposes + +package javafx.beans.value; + +import javafx.beans.value.WritableNumberValue; + +public interface WritableIntegerValue extends WritableNumberValue +{ + int get(); + void set(int p0); + void setValue(Number p0); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/value/WritableNumberValue.java b/java/ql/test/stubs/javafx-web/javafx/beans/value/WritableNumberValue.java new file mode 100644 index 00000000000..b063a159332 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/value/WritableNumberValue.java @@ -0,0 +1,9 @@ +// Generated automatically from javafx.beans.value.WritableNumberValue for testing purposes + +package javafx.beans.value; + +import javafx.beans.value.WritableValue; + +public interface WritableNumberValue extends WritableValue +{ +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/value/WritableObjectValue.java b/java/ql/test/stubs/javafx-web/javafx/beans/value/WritableObjectValue.java new file mode 100644 index 00000000000..d5dc3b167cf --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/value/WritableObjectValue.java @@ -0,0 +1,11 @@ +// Generated automatically from javafx.beans.value.WritableObjectValue for testing purposes + +package javafx.beans.value; + +import javafx.beans.value.WritableValue; + +public interface WritableObjectValue extends javafx.beans.value.WritableValue +{ + T get(); + void set(T p0); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/value/WritableStringValue.java b/java/ql/test/stubs/javafx-web/javafx/beans/value/WritableStringValue.java new file mode 100644 index 00000000000..fe0c3ebf1f2 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/value/WritableStringValue.java @@ -0,0 +1,9 @@ +// Generated automatically from javafx.beans.value.WritableStringValue for testing purposes + +package javafx.beans.value; + +import javafx.beans.value.WritableObjectValue; + +public interface WritableStringValue extends WritableObjectValue +{ +} diff --git a/java/ql/test/stubs/javafx-web/javafx/beans/value/WritableValue.java b/java/ql/test/stubs/javafx-web/javafx/beans/value/WritableValue.java new file mode 100644 index 00000000000..cdc3fdd3329 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/beans/value/WritableValue.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.beans.value.WritableValue for testing purposes + +package javafx.beans.value; + + +public interface WritableValue +{ + T getValue(); + void setValue(T p0); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/collections/ListChangeListener.java b/java/ql/test/stubs/javafx-web/javafx/collections/ListChangeListener.java new file mode 100644 index 00000000000..8eb4100f286 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/collections/ListChangeListener.java @@ -0,0 +1,32 @@ +// Generated automatically from javafx.collections.ListChangeListener for testing purposes + +package javafx.collections; + +import java.util.List; +import javafx.collections.ObservableList; + +public interface ListChangeListener +{ + abstract static public class Change + { + protected Change() {} + protected abstract int[] getPermutation(); + public Change(javafx.collections.ObservableList p0){} + public abstract boolean next(); + public abstract int getFrom(); + public abstract int getTo(); + public abstract java.util.List getRemoved(); + public abstract void reset(); + public boolean wasAdded(){ return false; } + public boolean wasPermutated(){ return false; } + public boolean wasRemoved(){ return false; } + public boolean wasReplaced(){ return false; } + public boolean wasUpdated(){ return false; } + public int getAddedSize(){ return 0; } + public int getPermutation(int p0){ return 0; } + public int getRemovedSize(){ return 0; } + public java.util.List getAddedSubList(){ return null; } + public javafx.collections.ObservableList getList(){ return null; } + } + void onChanged(ListChangeListener.Change p0); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/collections/MapChangeListener.java b/java/ql/test/stubs/javafx-web/javafx/collections/MapChangeListener.java new file mode 100644 index 00000000000..cd7c5bd60c2 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/collections/MapChangeListener.java @@ -0,0 +1,21 @@ +// Generated automatically from javafx.collections.MapChangeListener for testing purposes + +package javafx.collections; + +import javafx.collections.ObservableMap; + +public interface MapChangeListener +{ + abstract static public class Change + { + protected Change() {} + public Change(ObservableMap p0){} + public ObservableMap getMap(){ return null; } + public abstract K getKey(); + public abstract V getValueAdded(); + public abstract V getValueRemoved(); + public abstract boolean wasAdded(); + public abstract boolean wasRemoved(); + } + void onChanged(MapChangeListener.Change p0); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/collections/ObservableList.java b/java/ql/test/stubs/javafx-web/javafx/collections/ObservableList.java new file mode 100644 index 00000000000..2cbfcd07770 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/collections/ObservableList.java @@ -0,0 +1,27 @@ +// Generated automatically from javafx.collections.ObservableList for testing purposes + +package javafx.collections; + +import java.util.Collection; +import java.util.Comparator; +import java.util.List; +import java.util.function.Predicate; +import javafx.beans.Observable; +import javafx.collections.ListChangeListener; +import javafx.collections.transformation.FilteredList; +import javafx.collections.transformation.SortedList; + +public interface ObservableList extends Observable, java.util.List +{ + boolean addAll(E... p0); + boolean removeAll(E... p0); + boolean retainAll(E... p0); + boolean setAll(E... p0); + boolean setAll(java.util.Collection p0); + default javafx.collections.transformation.FilteredList filtered(java.util.function.Predicate p0){ return null; } + default javafx.collections.transformation.SortedList sorted(){ return null; } + default javafx.collections.transformation.SortedList sorted(java.util.Comparator p0){ return null; } + void addListener(javafx.collections.ListChangeListener p0); + void remove(int p0, int p1); + void removeListener(javafx.collections.ListChangeListener p0); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/collections/ObservableListBase.java b/java/ql/test/stubs/javafx-web/javafx/collections/ObservableListBase.java new file mode 100644 index 00000000000..085ffbf424f --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/collections/ObservableListBase.java @@ -0,0 +1,36 @@ +// Generated automatically from javafx.collections.ObservableListBase for testing purposes + +package javafx.collections; + +import java.util.AbstractList; +import java.util.Collection; +import java.util.List; +import javafx.beans.InvalidationListener; +import javafx.collections.ListChangeListener; +import javafx.collections.ObservableList; + +abstract public class ObservableListBase extends java.util.AbstractList implements javafx.collections.ObservableList +{ + protected final boolean hasListeners(){ return false; } + protected final void beginChange(){} + protected final void endChange(){} + protected final void fireChange(ListChangeListener.Change p0){} + protected final void nextAdd(int p0, int p1){} + protected final void nextPermutation(int p0, int p1, int[] p2){} + protected final void nextRemove(int p0, E p1){} + protected final void nextRemove(int p0, java.util.List p1){} + protected final void nextReplace(int p0, int p1, java.util.List p2){} + protected final void nextSet(int p0, E p1){} + protected final void nextUpdate(int p0){} + public ObservableListBase(){} + public boolean addAll(E... p0){ return false; } + public boolean removeAll(E... p0){ return false; } + public boolean retainAll(E... p0){ return false; } + public boolean setAll(E... p0){ return false; } + public boolean setAll(java.util.Collection p0){ return false; } + public final void addListener(InvalidationListener p0){} + public final void addListener(javafx.collections.ListChangeListener p0){} + public final void removeListener(InvalidationListener p0){} + public final void removeListener(javafx.collections.ListChangeListener p0){} + public void remove(int p0, int p1){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/collections/ObservableMap.java b/java/ql/test/stubs/javafx-web/javafx/collections/ObservableMap.java new file mode 100644 index 00000000000..c2d059f8f28 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/collections/ObservableMap.java @@ -0,0 +1,13 @@ +// Generated automatically from javafx.collections.ObservableMap for testing purposes + +package javafx.collections; + +import java.util.Map; +import javafx.beans.Observable; +import javafx.collections.MapChangeListener; + +public interface ObservableMap extends Observable, java.util.Map +{ + void addListener(MapChangeListener p0); + void removeListener(MapChangeListener p0); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/collections/ObservableSet.java b/java/ql/test/stubs/javafx-web/javafx/collections/ObservableSet.java new file mode 100644 index 00000000000..49cc9e6a214 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/collections/ObservableSet.java @@ -0,0 +1,13 @@ +// Generated automatically from javafx.collections.ObservableSet for testing purposes + +package javafx.collections; + +import java.util.Set; +import javafx.beans.Observable; +import javafx.collections.SetChangeListener; + +public interface ObservableSet extends Observable, java.util.Set +{ + void addListener(SetChangeListener p0); + void removeListener(SetChangeListener p0); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/collections/SetChangeListener.java b/java/ql/test/stubs/javafx-web/javafx/collections/SetChangeListener.java new file mode 100644 index 00000000000..0168ef4d147 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/collections/SetChangeListener.java @@ -0,0 +1,20 @@ +// Generated automatically from javafx.collections.SetChangeListener for testing purposes + +package javafx.collections; + +import javafx.collections.ObservableSet; + +public interface SetChangeListener +{ + abstract static public class Change + { + protected Change() {} + public Change(ObservableSet p0){} + public ObservableSet getSet(){ return null; } + public abstract E getElementAdded(); + public abstract E getElementRemoved(); + public abstract boolean wasAdded(); + public abstract boolean wasRemoved(); + } + void onChanged(SetChangeListener.Change p0); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/collections/transformation/FilteredList.java b/java/ql/test/stubs/javafx-web/javafx/collections/transformation/FilteredList.java new file mode 100644 index 00000000000..ee83a561cff --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/collections/transformation/FilteredList.java @@ -0,0 +1,24 @@ +// Generated automatically from javafx.collections.transformation.FilteredList for testing purposes + +package javafx.collections.transformation; + +import java.util.function.Predicate; +import javafx.beans.property.ObjectProperty; +import javafx.collections.ListChangeListener; +import javafx.collections.ObservableList; +import javafx.collections.transformation.TransformationList; + +public class FilteredList extends javafx.collections.transformation.TransformationList +{ + protected FilteredList() {} + protected void sourceChanged(ListChangeListener.Change p0){} + public E get(int p0){ return null; } + public FilteredList(javafx.collections.ObservableList p0){} + public FilteredList(javafx.collections.ObservableList p0, java.util.function.Predicate p1){} + public final ObjectProperty> predicateProperty(){ return null; } + public final java.util.function.Predicate getPredicate(){ return null; } + public final void setPredicate(java.util.function.Predicate p0){} + public int getSourceIndex(int p0){ return 0; } + public int getViewIndex(int p0){ return 0; } + public int size(){ return 0; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/collections/transformation/SortedList.java b/java/ql/test/stubs/javafx-web/javafx/collections/transformation/SortedList.java new file mode 100644 index 00000000000..87c183fbfed --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/collections/transformation/SortedList.java @@ -0,0 +1,24 @@ +// Generated automatically from javafx.collections.transformation.SortedList for testing purposes + +package javafx.collections.transformation; + +import java.util.Comparator; +import javafx.beans.property.ObjectProperty; +import javafx.collections.ListChangeListener; +import javafx.collections.ObservableList; +import javafx.collections.transformation.TransformationList; + +public class SortedList extends javafx.collections.transformation.TransformationList +{ + protected SortedList() {} + protected void sourceChanged(ListChangeListener.Change p0){} + public E get(int p0){ return null; } + public SortedList(javafx.collections.ObservableList p0){} + public SortedList(javafx.collections.ObservableList p0, java.util.Comparator p1){} + public final ObjectProperty> comparatorProperty(){ return null; } + public final java.util.Comparator getComparator(){ return null; } + public final void setComparator(java.util.Comparator p0){} + public int getSourceIndex(int p0){ return 0; } + public int getViewIndex(int p0){ return 0; } + public int size(){ return 0; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/collections/transformation/TransformationList.java b/java/ql/test/stubs/javafx-web/javafx/collections/transformation/TransformationList.java new file mode 100644 index 00000000000..541fac5ff92 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/collections/transformation/TransformationList.java @@ -0,0 +1,19 @@ +// Generated automatically from javafx.collections.transformation.TransformationList for testing purposes + +package javafx.collections.transformation; + +import javafx.collections.ListChangeListener; +import javafx.collections.ObservableList; +import javafx.collections.ObservableListBase; + +abstract public class TransformationList extends javafx.collections.ObservableListBase +{ + protected TransformationList() {} + protected TransformationList(ObservableList p0){} + protected abstract void sourceChanged(ListChangeListener.Change p0); + public abstract int getSourceIndex(int p0); + public abstract int getViewIndex(int p0); + public final ObservableList getSource(){ return null; } + public final boolean isInTransformationChain(ObservableList p0){ return false; } + public final int getSourceIndexFor(ObservableList p0, int p1){ return 0; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/concurrent/Worker.java b/java/ql/test/stubs/javafx-web/javafx/concurrent/Worker.java new file mode 100644 index 00000000000..f354eaf0cac --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/concurrent/Worker.java @@ -0,0 +1,36 @@ +// Generated automatically from javafx.concurrent.Worker for testing purposes + +package javafx.concurrent; + +import javafx.beans.property.ReadOnlyBooleanProperty; +import javafx.beans.property.ReadOnlyDoubleProperty; +import javafx.beans.property.ReadOnlyObjectProperty; +import javafx.beans.property.ReadOnlyStringProperty; + +public interface Worker +{ + ReadOnlyBooleanProperty runningProperty(); + ReadOnlyDoubleProperty progressProperty(); + ReadOnlyDoubleProperty totalWorkProperty(); + ReadOnlyDoubleProperty workDoneProperty(); + ReadOnlyObjectProperty exceptionProperty(); + ReadOnlyObjectProperty valueProperty(); + ReadOnlyObjectProperty stateProperty(); + ReadOnlyStringProperty messageProperty(); + ReadOnlyStringProperty titleProperty(); + String getMessage(); + String getTitle(); + Throwable getException(); + V getValue(); + Worker.State getState(); + boolean cancel(); + boolean isRunning(); + double getProgress(); + double getTotalWork(); + double getWorkDone(); + static public enum State + { + CANCELLED, FAILED, READY, RUNNING, SCHEDULED, SUCCEEDED; + private State() {} + } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/css/CssMetaData.java b/java/ql/test/stubs/javafx-web/javafx/css/CssMetaData.java new file mode 100644 index 00000000000..04f4ee2ed3d --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/css/CssMetaData.java @@ -0,0 +1,29 @@ +// Generated automatically from javafx.css.CssMetaData for testing purposes + +package javafx.css; + +import java.util.List; +import javafx.css.StyleConverter; +import javafx.css.StyleOrigin; +import javafx.css.Styleable; +import javafx.css.StyleableProperty; + +abstract public class CssMetaData +{ + protected CssMetaData() {} + protected CssMetaData(String p0, StyleConverter p1){} + protected CssMetaData(String p0, StyleConverter p1, V p2){} + protected CssMetaData(String p0, StyleConverter p1, V p2, boolean p3){} + protected CssMetaData(String p0, StyleConverter p1, V p2, boolean p3, List> p4){} + public String toString(){ return null; } + public V getInitialValue(S p0){ return null; } + public abstract StyleableProperty getStyleableProperty(S p0); + public abstract boolean isSettable(S p0); + public boolean equals(Object p0){ return false; } + public final List> getSubProperties(){ return null; } + public final String getProperty(){ return null; } + public final StyleConverter getConverter(){ return null; } + public final boolean isInherits(){ return false; } + public int hashCode(){ return 0; } + public void set(S p0, V p1, StyleOrigin p2){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/css/ParsedValue.java b/java/ql/test/stubs/javafx-web/javafx/css/ParsedValue.java new file mode 100644 index 00000000000..c84b4c23be2 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/css/ParsedValue.java @@ -0,0 +1,19 @@ +// Generated automatically from javafx.css.ParsedValue for testing purposes + +package javafx.css; + +import javafx.css.StyleConverter; +import javafx.scene.text.Font; + +public class ParsedValue +{ + protected ParsedValue() {} + protected ParsedValue(V p0, StyleConverter p1){} + protected final StyleConverter converter = null; + protected final V value = null; + public T convert(Font p0){ return null; } + public boolean isContainsLookups(){ return false; } + public boolean isLookup(){ return false; } + public final StyleConverter getConverter(){ return null; } + public final V getValue(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/css/PseudoClass.java b/java/ql/test/stubs/javafx-web/javafx/css/PseudoClass.java new file mode 100644 index 00000000000..b82f84e2c90 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/css/PseudoClass.java @@ -0,0 +1,11 @@ +// Generated automatically from javafx.css.PseudoClass for testing purposes + +package javafx.css; + + +abstract public class PseudoClass +{ + public PseudoClass(){} + public abstract String getPseudoClassName(); + public static PseudoClass getPseudoClass(String p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/css/StyleConverter.java b/java/ql/test/stubs/javafx-web/javafx/css/StyleConverter.java new file mode 100644 index 00000000000..14b9e1ea1f6 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/css/StyleConverter.java @@ -0,0 +1,48 @@ +// Generated automatically from javafx.css.StyleConverter for testing purposes + +package javafx.css; + +import java.io.DataInputStream; +import java.io.DataOutputStream; +import java.util.List; +import java.util.Map; +import javafx.css.CssMetaData; +import javafx.css.ParsedValue; +import javafx.css.Styleable; +import javafx.geometry.Insets; +import javafx.scene.effect.Effect; +import javafx.scene.paint.Color; +import javafx.scene.paint.Paint; +import javafx.scene.text.Font; +import javafx.util.Duration; + +public class StyleConverter +{ + protected T getCachedValue(ParsedValue p0){ return null; } + protected void cacheValue(ParsedValue p0, Object p1){} + public StyleConverter(){} + public T convert(Map, Object> p0){ return null; } + public T convert(ParsedValue p0, Font p1){ return null; } + public static > StyleConverter getEnumConverter(java.lang.Class p0){ return null; } + public static StyleConverter readBinary(DataInputStream p0, String[] p1){ return null; } + public static StyleConverter getDurationConverter(){ return null; } + public static StyleConverter getSizeConverter(){ return null; } + public static StyleConverter, Paint> getPaintConverter(){ return null; } + public static StyleConverter getEffectConverter(){ return null; } + public static StyleConverter getFontConverter(){ return null; } + public static StyleConverter getInsetsConverter(){ return null; } + public static StyleConverter getUrlConverter(){ return null; } + public static StyleConverter getBooleanConverter(){ return null; } + public static StyleConverter getColorConverter(){ return null; } + public static StyleConverter getStringConverter(){ return null; } + public static void clearCache(){} + public void writeBinary(DataOutputStream p0, StyleConverter.StringStore p1){} + static public class StringStore + { + public StringStore(){} + public final List strings = null; + public int addString(String p0){ return 0; } + public static String[] readBinary(DataInputStream p0){ return null; } + public void writeBinary(DataOutputStream p0){} + } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/css/StyleOrigin.java b/java/ql/test/stubs/javafx-web/javafx/css/StyleOrigin.java new file mode 100644 index 00000000000..deb7d0cb2d2 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/css/StyleOrigin.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.css.StyleOrigin for testing purposes + +package javafx.css; + + +public enum StyleOrigin +{ + AUTHOR, INLINE, USER, USER_AGENT; + private StyleOrigin() {} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/css/Styleable.java b/java/ql/test/stubs/javafx-web/javafx/css/Styleable.java new file mode 100644 index 00000000000..1a801005a7f --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/css/Styleable.java @@ -0,0 +1,22 @@ +// Generated automatically from javafx.css.Styleable for testing purposes + +package javafx.css; + +import java.util.List; +import javafx.collections.ObservableList; +import javafx.collections.ObservableSet; +import javafx.css.CssMetaData; +import javafx.css.PseudoClass; +import javafx.scene.Node; + +public interface Styleable +{ + List> getCssMetaData(); + ObservableList getStyleClass(); + ObservableSet getPseudoClassStates(); + String getId(); + String getStyle(); + String getTypeSelector(); + Styleable getStyleableParent(); + default Node getStyleableNode(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/css/StyleableProperty.java b/java/ql/test/stubs/javafx-web/javafx/css/StyleableProperty.java new file mode 100644 index 00000000000..da1ddb14913 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/css/StyleableProperty.java @@ -0,0 +1,15 @@ +// Generated automatically from javafx.css.StyleableProperty for testing purposes + +package javafx.css; + +import javafx.beans.value.WritableValue; +import javafx.css.CssMetaData; +import javafx.css.StyleOrigin; +import javafx.css.Styleable; + +public interface StyleableProperty extends javafx.beans.value.WritableValue +{ + CssMetaData getCssMetaData(); + StyleOrigin getStyleOrigin(); + void applyStyle(StyleOrigin p0, T p1); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/event/Event.java b/java/ql/test/stubs/javafx-web/javafx/event/Event.java new file mode 100644 index 00000000000..fec238452c5 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/event/Event.java @@ -0,0 +1,52 @@ +// Generated automatically from javafx.event.Event for testing purposes + +package javafx.event; + +import java.util.EventObject; +import javafx.event.EventTarget; +import javafx.event.EventType; + +public class Event extends EventObject implements Cloneable { + protected Event() { + super(null); + } + + protected EventTarget target = null; + protected EventType eventType = null; + protected boolean consumed = false; + + public Event copyFor(Object p0, EventTarget p1) { + return null; + } + + public Event(EventType p0) { + super(p0); + } + + public Event(Object p0, EventTarget p1, EventType p2) { + super(p0); + } + + public EventTarget getTarget() { + return null; + } + + public EventType getEventType() { + return null; + } + + public Object clone() { + return null; + } + + public boolean isConsumed() { + return false; + } + + public static EventTarget NULL_SOURCE_TARGET = null; + public static EventType ANY = null; + + public static void fireEvent(EventTarget p0, Event p1) {} + + public void consume() {} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/event/EventDispatchChain.java b/java/ql/test/stubs/javafx-web/javafx/event/EventDispatchChain.java new file mode 100644 index 00000000000..8ec2590b053 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/event/EventDispatchChain.java @@ -0,0 +1,13 @@ +// Generated automatically from javafx.event.EventDispatchChain for testing purposes + +package javafx.event; + +import javafx.event.Event; +import javafx.event.EventDispatcher; + +public interface EventDispatchChain +{ + Event dispatchEvent(Event p0); + EventDispatchChain append(EventDispatcher p0); + EventDispatchChain prepend(EventDispatcher p0); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/event/EventDispatcher.java b/java/ql/test/stubs/javafx-web/javafx/event/EventDispatcher.java new file mode 100644 index 00000000000..47f77def0e3 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/event/EventDispatcher.java @@ -0,0 +1,11 @@ +// Generated automatically from javafx.event.EventDispatcher for testing purposes + +package javafx.event; + +import javafx.event.Event; +import javafx.event.EventDispatchChain; + +public interface EventDispatcher +{ + Event dispatchEvent(Event p0, EventDispatchChain p1); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/event/EventHandler.java b/java/ql/test/stubs/javafx-web/javafx/event/EventHandler.java new file mode 100644 index 00000000000..0c988576bcf --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/event/EventHandler.java @@ -0,0 +1,11 @@ +// Generated automatically from javafx.event.EventHandler for testing purposes + +package javafx.event; + +import java.util.EventListener; +import javafx.event.Event; + +public interface EventHandler extends EventListener +{ + void handle(T p0); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/event/EventTarget.java b/java/ql/test/stubs/javafx-web/javafx/event/EventTarget.java new file mode 100644 index 00000000000..afa13325e8d --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/event/EventTarget.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.event.EventTarget for testing purposes + +package javafx.event; + +import javafx.event.EventDispatchChain; + +public interface EventTarget +{ + EventDispatchChain buildEventDispatchChain(EventDispatchChain p0); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/event/EventType.java b/java/ql/test/stubs/javafx-web/javafx/event/EventType.java new file mode 100644 index 00000000000..55ec2de476a --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/event/EventType.java @@ -0,0 +1,18 @@ +// Generated automatically from javafx.event.EventType for testing purposes + +package javafx.event; + +import java.io.Serializable; +import javafx.event.Event; + +public class EventType implements Serializable +{ + public EventType(){} + public EventType(EventType p0){} + public EventType(EventType p0, String p1){} + public EventType(String p0){} + public String toString(){ return null; } + public final EventType getSuperType(){ return null; } + public final String getName(){ return null; } + public static EventType ROOT = null; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/geometry/Bounds.java b/java/ql/test/stubs/javafx-web/javafx/geometry/Bounds.java new file mode 100644 index 00000000000..4d4a4a5cab2 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/geometry/Bounds.java @@ -0,0 +1,35 @@ +// Generated automatically from javafx.geometry.Bounds for testing purposes + +package javafx.geometry; + +import javafx.geometry.Point2D; +import javafx.geometry.Point3D; + +abstract public class Bounds +{ + protected Bounds() {} + protected Bounds(double p0, double p1, double p2, double p3, double p4, double p5){} + public abstract boolean contains(Bounds p0); + public abstract boolean contains(Point2D p0); + public abstract boolean contains(Point3D p0); + public abstract boolean contains(double p0, double p1); + public abstract boolean contains(double p0, double p1, double p2); + public abstract boolean contains(double p0, double p1, double p2, double p3); + public abstract boolean contains(double p0, double p1, double p2, double p3, double p4, double p5); + public abstract boolean intersects(Bounds p0); + public abstract boolean intersects(double p0, double p1, double p2, double p3); + public abstract boolean intersects(double p0, double p1, double p2, double p3, double p4, double p5); + public abstract boolean isEmpty(); + public final double getCenterX(){ return 0; } + public final double getCenterY(){ return 0; } + public final double getCenterZ(){ return 0; } + public final double getDepth(){ return 0; } + public final double getHeight(){ return 0; } + public final double getMaxX(){ return 0; } + public final double getMaxY(){ return 0; } + public final double getMaxZ(){ return 0; } + public final double getMinX(){ return 0; } + public final double getMinY(){ return 0; } + public final double getMinZ(){ return 0; } + public final double getWidth(){ return 0; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/geometry/Insets.java b/java/ql/test/stubs/javafx-web/javafx/geometry/Insets.java new file mode 100644 index 00000000000..3ac369d4bf9 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/geometry/Insets.java @@ -0,0 +1,19 @@ +// Generated automatically from javafx.geometry.Insets for testing purposes + +package javafx.geometry; + + +public class Insets +{ + protected Insets() {} + public Insets(double p0){} + public Insets(double p0, double p1, double p2, double p3){} + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public final double getBottom(){ return 0; } + public final double getLeft(){ return 0; } + public final double getRight(){ return 0; } + public final double getTop(){ return 0; } + public int hashCode(){ return 0; } + public static Insets EMPTY = null; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/geometry/NodeOrientation.java b/java/ql/test/stubs/javafx-web/javafx/geometry/NodeOrientation.java new file mode 100644 index 00000000000..143659bc66e --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/geometry/NodeOrientation.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.geometry.NodeOrientation for testing purposes + +package javafx.geometry; + + +public enum NodeOrientation +{ + INHERIT, LEFT_TO_RIGHT, RIGHT_TO_LEFT; + private NodeOrientation() {} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/geometry/Orientation.java b/java/ql/test/stubs/javafx-web/javafx/geometry/Orientation.java new file mode 100644 index 00000000000..3c994d5eeeb --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/geometry/Orientation.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.geometry.Orientation for testing purposes + +package javafx.geometry; + + +public enum Orientation +{ + HORIZONTAL, VERTICAL; + private Orientation() {} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/geometry/Point2D.java b/java/ql/test/stubs/javafx-web/javafx/geometry/Point2D.java new file mode 100644 index 00000000000..e2b3f467133 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/geometry/Point2D.java @@ -0,0 +1,37 @@ +// Generated automatically from javafx.geometry.Point2D for testing purposes + +package javafx.geometry; + +import javafx.animation.Interpolatable; +import javafx.geometry.Point3D; + +public class Point2D implements Interpolatable +{ + protected Point2D() {} + public Point2D add(Point2D p0){ return null; } + public Point2D add(double p0, double p1){ return null; } + public Point2D interpolate(Point2D p0, double p1){ return null; } + public Point2D midpoint(Point2D p0){ return null; } + public Point2D midpoint(double p0, double p1){ return null; } + public Point2D multiply(double p0){ return null; } + public Point2D normalize(){ return null; } + public Point2D subtract(Point2D p0){ return null; } + public Point2D subtract(double p0, double p1){ return null; } + public Point2D(double p0, double p1){} + public Point3D crossProduct(Point2D p0){ return null; } + public Point3D crossProduct(double p0, double p1){ return null; } + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public double angle(Point2D p0){ return 0; } + public double angle(Point2D p0, Point2D p1){ return 0; } + public double angle(double p0, double p1){ return 0; } + public double distance(Point2D p0){ return 0; } + public double distance(double p0, double p1){ return 0; } + public double dotProduct(Point2D p0){ return 0; } + public double dotProduct(double p0, double p1){ return 0; } + public double magnitude(){ return 0; } + public final double getX(){ return 0; } + public final double getY(){ return 0; } + public int hashCode(){ return 0; } + public static Point2D ZERO = null; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/geometry/Point3D.java b/java/ql/test/stubs/javafx-web/javafx/geometry/Point3D.java new file mode 100644 index 00000000000..1d51d8e70e1 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/geometry/Point3D.java @@ -0,0 +1,37 @@ +// Generated automatically from javafx.geometry.Point3D for testing purposes + +package javafx.geometry; + +import javafx.animation.Interpolatable; + +public class Point3D implements Interpolatable +{ + protected Point3D() {} + public Point3D add(Point3D p0){ return null; } + public Point3D add(double p0, double p1, double p2){ return null; } + public Point3D crossProduct(Point3D p0){ return null; } + public Point3D crossProduct(double p0, double p1, double p2){ return null; } + public Point3D interpolate(Point3D p0, double p1){ return null; } + public Point3D midpoint(Point3D p0){ return null; } + public Point3D midpoint(double p0, double p1, double p2){ return null; } + public Point3D multiply(double p0){ return null; } + public Point3D normalize(){ return null; } + public Point3D subtract(Point3D p0){ return null; } + public Point3D subtract(double p0, double p1, double p2){ return null; } + public Point3D(double p0, double p1, double p2){} + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public double angle(Point3D p0){ return 0; } + public double angle(Point3D p0, Point3D p1){ return 0; } + public double angle(double p0, double p1, double p2){ return 0; } + public double distance(Point3D p0){ return 0; } + public double distance(double p0, double p1, double p2){ return 0; } + public double dotProduct(Point3D p0){ return 0; } + public double dotProduct(double p0, double p1, double p2){ return 0; } + public double magnitude(){ return 0; } + public final double getX(){ return 0; } + public final double getY(){ return 0; } + public final double getZ(){ return 0; } + public int hashCode(){ return 0; } + public static Point3D ZERO = null; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/geometry/Rectangle2D.java b/java/ql/test/stubs/javafx-web/javafx/geometry/Rectangle2D.java new file mode 100644 index 00000000000..36b1b903375 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/geometry/Rectangle2D.java @@ -0,0 +1,27 @@ +// Generated automatically from javafx.geometry.Rectangle2D for testing purposes + +package javafx.geometry; + +import javafx.geometry.Point2D; + +public class Rectangle2D +{ + protected Rectangle2D() {} + public Rectangle2D(double p0, double p1, double p2, double p3){} + public String toString(){ return null; } + public boolean contains(Point2D p0){ return false; } + public boolean contains(Rectangle2D p0){ return false; } + public boolean contains(double p0, double p1){ return false; } + public boolean contains(double p0, double p1, double p2, double p3){ return false; } + public boolean equals(Object p0){ return false; } + public boolean intersects(Rectangle2D p0){ return false; } + public boolean intersects(double p0, double p1, double p2, double p3){ return false; } + public double getHeight(){ return 0; } + public double getMaxX(){ return 0; } + public double getMaxY(){ return 0; } + public double getMinX(){ return 0; } + public double getMinY(){ return 0; } + public double getWidth(){ return 0; } + public int hashCode(){ return 0; } + public static Rectangle2D EMPTY = null; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/print/Collation.java b/java/ql/test/stubs/javafx-web/javafx/print/Collation.java new file mode 100644 index 00000000000..774a2c35d8c --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/print/Collation.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.print.Collation for testing purposes + +package javafx.print; + + +public enum Collation +{ + COLLATED, UNCOLLATED; + private Collation() {} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/print/JobSettings.java b/java/ql/test/stubs/javafx-web/javafx/print/JobSettings.java new file mode 100644 index 00000000000..9e485d38ba1 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/print/JobSettings.java @@ -0,0 +1,54 @@ +// Generated automatically from javafx.print.JobSettings for testing purposes + +package javafx.print; + +import javafx.beans.property.IntegerProperty; +import javafx.beans.property.ObjectProperty; +import javafx.beans.property.StringProperty; +import javafx.print.Collation; +import javafx.print.PageLayout; +import javafx.print.PageRange; +import javafx.print.PaperSource; +import javafx.print.PrintColor; +import javafx.print.PrintQuality; +import javafx.print.PrintResolution; +import javafx.print.PrintSides; + +public class JobSettings +{ + protected JobSettings() {} + public String toString(){ return null; } + public final Collation getCollation(){ return null; } + public final IntegerProperty copiesProperty(){ return null; } + public final ObjectProperty pageRangesProperty(){ return null; } + public final ObjectProperty collationProperty(){ return null; } + public final ObjectProperty pageLayoutProperty(){ return null; } + public final ObjectProperty paperSourceProperty(){ return null; } + public final ObjectProperty printColorProperty(){ return null; } + public final ObjectProperty printQualityProperty(){ return null; } + public final ObjectProperty printResolutionProperty(){ return null; } + public final ObjectProperty printSidesProperty(){ return null; } + public final PageLayout getPageLayout(){ return null; } + public final PageRange[] getPageRanges(){ return null; } + public final PaperSource getPaperSource(){ return null; } + public final PrintColor getPrintColor(){ return null; } + public final PrintQuality getPrintQuality(){ return null; } + public final PrintResolution getPrintResolution(){ return null; } + public final PrintSides getPrintSides(){ return null; } + public final String getJobName(){ return null; } + public final String getOutputFile(){ return null; } + public final StringProperty jobNameProperty(){ return null; } + public final StringProperty outputFileProperty(){ return null; } + public final int getCopies(){ return 0; } + public final void setCollation(Collation p0){} + public final void setCopies(int p0){} + public final void setJobName(String p0){} + public final void setOutputFile(String p0){} + public final void setPageLayout(PageLayout p0){} + public final void setPageRanges(PageRange... p0){} + public final void setPaperSource(PaperSource p0){} + public final void setPrintColor(PrintColor p0){} + public final void setPrintQuality(PrintQuality p0){} + public final void setPrintResolution(PrintResolution p0){} + public final void setPrintSides(PrintSides p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/print/PageLayout.java b/java/ql/test/stubs/javafx-web/javafx/print/PageLayout.java new file mode 100644 index 00000000000..81d16c015db --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/print/PageLayout.java @@ -0,0 +1,22 @@ +// Generated automatically from javafx.print.PageLayout for testing purposes + +package javafx.print; + +import javafx.print.PageOrientation; +import javafx.print.Paper; + +public class PageLayout +{ + protected PageLayout() {} + public PageOrientation getPageOrientation(){ return null; } + public Paper getPaper(){ return null; } + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public double getBottomMargin(){ return 0; } + public double getLeftMargin(){ return 0; } + public double getPrintableHeight(){ return 0; } + public double getPrintableWidth(){ return 0; } + public double getRightMargin(){ return 0; } + public double getTopMargin(){ return 0; } + public int hashCode(){ return 0; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/print/PageOrientation.java b/java/ql/test/stubs/javafx-web/javafx/print/PageOrientation.java new file mode 100644 index 00000000000..8a1ee2274fd --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/print/PageOrientation.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.print.PageOrientation for testing purposes + +package javafx.print; + + +public enum PageOrientation +{ + LANDSCAPE, PORTRAIT, REVERSE_LANDSCAPE, REVERSE_PORTRAIT; + private PageOrientation() {} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/print/PageRange.java b/java/ql/test/stubs/javafx-web/javafx/print/PageRange.java new file mode 100644 index 00000000000..e8e5221441e --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/print/PageRange.java @@ -0,0 +1,16 @@ +// Generated automatically from javafx.print.PageRange for testing purposes + +package javafx.print; + +import javafx.beans.property.ReadOnlyIntegerProperty; + +public class PageRange +{ + protected PageRange() {} + public PageRange(int p0, int p1){} + public String toString(){ return null; } + public final ReadOnlyIntegerProperty endPageProperty(){ return null; } + public final ReadOnlyIntegerProperty startPageProperty(){ return null; } + public final int getEndPage(){ return 0; } + public final int getStartPage(){ return 0; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/print/Paper.java b/java/ql/test/stubs/javafx-web/javafx/print/Paper.java new file mode 100644 index 00000000000..60a31fe3875 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/print/Paper.java @@ -0,0 +1,35 @@ +// Generated automatically from javafx.print.Paper for testing purposes + +package javafx.print; + + +public class Paper +{ + protected Paper() {} + public final String getName(){ return null; } + public final String toString(){ return null; } + public final boolean equals(Object p0){ return false; } + public final double getHeight(){ return 0; } + public final double getWidth(){ return 0; } + public final int hashCode(){ return 0; } + public static Paper A0 = null; + public static Paper A1 = null; + public static Paper A2 = null; + public static Paper A3 = null; + public static Paper A4 = null; + public static Paper A5 = null; + public static Paper A6 = null; + public static Paper C = null; + public static Paper DESIGNATED_LONG = null; + public static Paper EXECUTIVE = null; + public static Paper JAPANESE_POSTCARD = null; + public static Paper JIS_B4 = null; + public static Paper JIS_B5 = null; + public static Paper JIS_B6 = null; + public static Paper LEGAL = null; + public static Paper MONARCH_ENVELOPE = null; + public static Paper NA_8X10 = null; + public static Paper NA_LETTER = null; + public static Paper NA_NUMBER_10_ENVELOPE = null; + public static Paper TABLOID = null; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/print/PaperSource.java b/java/ql/test/stubs/javafx-web/javafx/print/PaperSource.java new file mode 100644 index 00000000000..d3ca53f870d --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/print/PaperSource.java @@ -0,0 +1,20 @@ +// Generated automatically from javafx.print.PaperSource for testing purposes + +package javafx.print; + + +public class PaperSource +{ + protected PaperSource() {} + public String getName(){ return null; } + public String toString(){ return null; } + public static PaperSource AUTOMATIC = null; + public static PaperSource BOTTOM = null; + public static PaperSource ENVELOPE = null; + public static PaperSource LARGE_CAPACITY = null; + public static PaperSource MAIN = null; + public static PaperSource MANUAL = null; + public static PaperSource MIDDLE = null; + public static PaperSource SIDE = null; + public static PaperSource TOP = null; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/print/PrintColor.java b/java/ql/test/stubs/javafx-web/javafx/print/PrintColor.java new file mode 100644 index 00000000000..f2317db8eb8 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/print/PrintColor.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.print.PrintColor for testing purposes + +package javafx.print; + + +public enum PrintColor +{ + COLOR, MONOCHROME; + private PrintColor() {} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/print/PrintQuality.java b/java/ql/test/stubs/javafx-web/javafx/print/PrintQuality.java new file mode 100644 index 00000000000..d0a51cc1551 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/print/PrintQuality.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.print.PrintQuality for testing purposes + +package javafx.print; + + +public enum PrintQuality +{ + DRAFT, HIGH, LOW, NORMAL; + private PrintQuality() {} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/print/PrintResolution.java b/java/ql/test/stubs/javafx-web/javafx/print/PrintResolution.java new file mode 100644 index 00000000000..eada0c7fd2c --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/print/PrintResolution.java @@ -0,0 +1,14 @@ +// Generated automatically from javafx.print.PrintResolution for testing purposes + +package javafx.print; + + +public class PrintResolution +{ + protected PrintResolution() {} + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public int getCrossFeedResolution(){ return 0; } + public int getFeedResolution(){ return 0; } + public int hashCode(){ return 0; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/print/PrintSides.java b/java/ql/test/stubs/javafx-web/javafx/print/PrintSides.java new file mode 100644 index 00000000000..edf90c8e64c --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/print/PrintSides.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.print.PrintSides for testing purposes + +package javafx.print; + + +public enum PrintSides +{ + DUPLEX, ONE_SIDED, TUMBLE; + private PrintSides() {} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/print/Printer.java b/java/ql/test/stubs/javafx-web/javafx/print/Printer.java new file mode 100644 index 00000000000..5aed8020880 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/print/Printer.java @@ -0,0 +1,29 @@ +// Generated automatically from javafx.print.Printer for testing purposes + +package javafx.print; + +import javafx.beans.property.ReadOnlyObjectProperty; +import javafx.collections.ObservableSet; +import javafx.print.PageLayout; +import javafx.print.PageOrientation; +import javafx.print.Paper; +import javafx.print.PrinterAttributes; + +public class Printer +{ + protected Printer() {} + public PageLayout createPageLayout(Paper p0, PageOrientation p1, Printer.MarginType p2){ return null; } + public PageLayout createPageLayout(Paper p0, PageOrientation p1, double p2, double p3, double p4, double p5){ return null; } + public PageLayout getDefaultPageLayout(){ return null; } + public PrinterAttributes getPrinterAttributes(){ return null; } + public String getName(){ return null; } + public String toString(){ return null; } + public static ObservableSet getAllPrinters(){ return null; } + public static Printer getDefaultPrinter(){ return null; } + public static ReadOnlyObjectProperty defaultPrinterProperty(){ return null; } + static public enum MarginType + { + DEFAULT, EQUAL, EQUAL_OPPOSITES, HARDWARE_MINIMUM; + private MarginType() {} + } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/print/PrinterAttributes.java b/java/ql/test/stubs/javafx-web/javafx/print/PrinterAttributes.java new file mode 100644 index 00000000000..8d8076f769a --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/print/PrinterAttributes.java @@ -0,0 +1,37 @@ +// Generated automatically from javafx.print.PrinterAttributes for testing purposes + +package javafx.print; + +import java.util.Set; +import javafx.print.Collation; +import javafx.print.PageOrientation; +import javafx.print.Paper; +import javafx.print.PaperSource; +import javafx.print.PrintColor; +import javafx.print.PrintQuality; +import javafx.print.PrintResolution; +import javafx.print.PrintSides; + +public class PrinterAttributes +{ + protected PrinterAttributes() {} + public Collation getDefaultCollation(){ return null; } + public PageOrientation getDefaultPageOrientation(){ return null; } + public Paper getDefaultPaper(){ return null; } + public PaperSource getDefaultPaperSource(){ return null; } + public PrintColor getDefaultPrintColor(){ return null; } + public PrintQuality getDefaultPrintQuality(){ return null; } + public PrintResolution getDefaultPrintResolution(){ return null; } + public PrintSides getDefaultPrintSides(){ return null; } + public Set getSupportedCollations(){ return null; } + public Set getSupportedPageOrientations(){ return null; } + public Set getSupportedPapers(){ return null; } + public Set getSupportedPaperSources(){ return null; } + public Set getSupportedPrintColors(){ return null; } + public Set getSupportedPrintQuality(){ return null; } + public Set getSupportedPrintResolutions(){ return null; } + public Set getSupportedPrintSides(){ return null; } + public boolean supportsPageRanges(){ return false; } + public int getDefaultCopies(){ return 0; } + public int getMaxCopies(){ return 0; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/print/PrinterJob.java b/java/ql/test/stubs/javafx-web/javafx/print/PrinterJob.java new file mode 100644 index 00000000000..6df822d963f --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/print/PrinterJob.java @@ -0,0 +1,36 @@ +// Generated automatically from javafx.print.PrinterJob for testing purposes + +package javafx.print; + +import javafx.beans.property.ObjectProperty; +import javafx.beans.property.ReadOnlyObjectProperty; +import javafx.print.JobSettings; +import javafx.print.PageLayout; +import javafx.print.Printer; +import javafx.scene.Node; +import javafx.stage.Window; + +public class PrinterJob +{ + protected PrinterJob() {} + public JobSettings getJobSettings(){ return null; } + public String toString(){ return null; } + public boolean endJob(){ return false; } + public boolean printPage(Node p0){ return false; } + public boolean printPage(PageLayout p0, Node p1){ return false; } + public boolean showPageSetupDialog(Window p0){ return false; } + public boolean showPrintDialog(Window p0){ return false; } + public final ObjectProperty printerProperty(){ return null; } + public final Printer getPrinter(){ return null; } + public final PrinterJob.JobStatus getJobStatus(){ return null; } + public final ReadOnlyObjectProperty jobStatusProperty(){ return null; } + public final void setPrinter(Printer p0){} + public static PrinterJob createPrinterJob(){ return null; } + public static PrinterJob createPrinterJob(Printer p0){ return null; } + public void cancelJob(){} + static public enum JobStatus + { + CANCELED, DONE, ERROR, NOT_STARTED, PRINTING; + private JobStatus() {} + } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/AccessibleAction.java b/java/ql/test/stubs/javafx-web/javafx/scene/AccessibleAction.java new file mode 100644 index 00000000000..89154d00ccd --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/AccessibleAction.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.scene.AccessibleAction for testing purposes + +package javafx.scene; + + +public enum AccessibleAction +{ + BLOCK_DECREMENT, BLOCK_INCREMENT, COLLAPSE, DECREMENT, EXPAND, FIRE, INCREMENT, REQUEST_FOCUS, SET_SELECTED_ITEMS, SET_TEXT, SET_TEXT_SELECTION, SET_VALUE, SHOW_ITEM, SHOW_MENU, SHOW_TEXT_RANGE; + private AccessibleAction() {} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/AccessibleAttribute.java b/java/ql/test/stubs/javafx-web/javafx/scene/AccessibleAttribute.java new file mode 100644 index 00000000000..ac27dfef6b1 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/AccessibleAttribute.java @@ -0,0 +1,11 @@ +// Generated automatically from javafx.scene.AccessibleAttribute for testing purposes + +package javafx.scene; + + +public enum AccessibleAttribute +{ + ACCELERATOR, BOUNDS, BOUNDS_FOR_RANGE, CARET_OFFSET, CELL_AT_ROW_COLUMN, CHILDREN, COLUMN_AT_INDEX, COLUMN_COUNT, COLUMN_INDEX, CONTENTS, DATE, DISABLED, DISCLOSURE_LEVEL, EDITABLE, EXPANDED, FOCUSED, FOCUS_ITEM, FOCUS_NODE, FONT, HEADER, HELP, HORIZONTAL_SCROLLBAR, INDETERMINATE, INDEX, ITEM_AT_INDEX, ITEM_COUNT, LABELED_BY, LEAF, LINE_END, LINE_FOR_OFFSET, LINE_START, MAX_VALUE, MIN_VALUE, MNEMONIC, MULTIPLE_SELECTION, NODE_AT_POINT, OFFSET_AT_POINT, ORIENTATION, OVERFLOW_BUTTON, PARENT, PARENT_MENU, ROLE, ROLE_DESCRIPTION, ROW_AT_INDEX, ROW_COUNT, ROW_INDEX, SCENE, SELECTED, SELECTED_ITEMS, SELECTION_END, SELECTION_START, SUBMENU, TEXT, TREE_ITEM_AT_INDEX, TREE_ITEM_COUNT, TREE_ITEM_PARENT, VALUE, VERTICAL_SCROLLBAR, VISIBLE, VISITED; + private AccessibleAttribute() {} + public Class getReturnType(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/AccessibleRole.java b/java/ql/test/stubs/javafx-web/javafx/scene/AccessibleRole.java new file mode 100644 index 00000000000..5eaeb704487 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/AccessibleRole.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.scene.AccessibleRole for testing purposes + +package javafx.scene; + + +public enum AccessibleRole +{ + BUTTON, CHECK_BOX, CHECK_MENU_ITEM, COMBO_BOX, CONTEXT_MENU, DATE_PICKER, DECREMENT_BUTTON, DIALOG, HYPERLINK, IMAGE_VIEW, INCREMENT_BUTTON, LIST_ITEM, LIST_VIEW, MENU, MENU_BAR, MENU_BUTTON, MENU_ITEM, NODE, PAGE_ITEM, PAGINATION, PARENT, PASSWORD_FIELD, PROGRESS_INDICATOR, RADIO_BUTTON, RADIO_MENU_ITEM, SCROLL_BAR, SCROLL_PANE, SLIDER, SPINNER, SPLIT_MENU_BUTTON, TABLE_CELL, TABLE_COLUMN, TABLE_ROW, TABLE_VIEW, TAB_ITEM, TAB_PANE, TEXT, TEXT_AREA, TEXT_FIELD, THUMB, TITLED_PANE, TOGGLE_BUTTON, TOOLTIP, TOOL_BAR, TREE_ITEM, TREE_TABLE_CELL, TREE_TABLE_ROW, TREE_TABLE_VIEW, TREE_VIEW; + private AccessibleRole() {} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/CacheHint.java b/java/ql/test/stubs/javafx-web/javafx/scene/CacheHint.java new file mode 100644 index 00000000000..1cd6cf4a095 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/CacheHint.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.scene.CacheHint for testing purposes + +package javafx.scene; + + +public enum CacheHint +{ + DEFAULT, QUALITY, ROTATE, SCALE, SCALE_AND_ROTATE, SPEED; + private CacheHint() {} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/Camera.java b/java/ql/test/stubs/javafx-web/javafx/scene/Camera.java new file mode 100644 index 00000000000..08c4d8b8592 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/Camera.java @@ -0,0 +1,17 @@ +// Generated automatically from javafx.scene.Camera for testing purposes + +package javafx.scene; + +import javafx.beans.property.DoubleProperty; +import javafx.scene.Node; + +abstract public class Camera extends Node +{ + protected Camera(){} + public final DoubleProperty farClipProperty(){ return null; } + public final DoubleProperty nearClipProperty(){ return null; } + public final double getFarClip(){ return 0; } + public final double getNearClip(){ return 0; } + public final void setFarClip(double p0){} + public final void setNearClip(double p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/Cursor.java b/java/ql/test/stubs/javafx-web/javafx/scene/Cursor.java new file mode 100644 index 00000000000..de75b547da6 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/Cursor.java @@ -0,0 +1,30 @@ +// Generated automatically from javafx.scene.Cursor for testing purposes + +package javafx.scene; + + +abstract public class Cursor +{ + public String toString(){ return null; } + public static Cursor CLOSED_HAND = null; + public static Cursor CROSSHAIR = null; + public static Cursor DEFAULT = null; + public static Cursor DISAPPEAR = null; + public static Cursor E_RESIZE = null; + public static Cursor HAND = null; + public static Cursor H_RESIZE = null; + public static Cursor MOVE = null; + public static Cursor NE_RESIZE = null; + public static Cursor NONE = null; + public static Cursor NW_RESIZE = null; + public static Cursor N_RESIZE = null; + public static Cursor OPEN_HAND = null; + public static Cursor SE_RESIZE = null; + public static Cursor SW_RESIZE = null; + public static Cursor S_RESIZE = null; + public static Cursor TEXT = null; + public static Cursor V_RESIZE = null; + public static Cursor WAIT = null; + public static Cursor W_RESIZE = null; + public static Cursor cursor(String p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/DepthTest.java b/java/ql/test/stubs/javafx-web/javafx/scene/DepthTest.java new file mode 100644 index 00000000000..4d624bd3b7f --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/DepthTest.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.scene.DepthTest for testing purposes + +package javafx.scene; + + +public enum DepthTest +{ + DISABLE, ENABLE, INHERIT; + private DepthTest() {} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/Node.java b/java/ql/test/stubs/javafx-web/javafx/scene/Node.java new file mode 100644 index 00000000000..693d13192ab --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/Node.java @@ -0,0 +1,406 @@ +// Generated automatically from javafx.scene.Node for testing purposes + +package javafx.scene; + +import java.util.List; +import java.util.Set; +import javafx.beans.property.BooleanProperty; +import javafx.beans.property.DoubleProperty; +import javafx.beans.property.ObjectProperty; +import javafx.beans.property.ReadOnlyBooleanProperty; +import javafx.beans.property.ReadOnlyBooleanPropertyBase; +import javafx.beans.property.ReadOnlyObjectProperty; +import javafx.beans.property.StringProperty; +import javafx.collections.ObservableList; +import javafx.collections.ObservableMap; +import javafx.collections.ObservableSet; +import javafx.css.CssMetaData; +import javafx.css.PseudoClass; +import javafx.css.Styleable; +import javafx.event.Event; +import javafx.event.EventDispatchChain; +import javafx.event.EventDispatcher; +import javafx.event.EventHandler; +import javafx.event.EventTarget; +import javafx.event.EventType; +import javafx.geometry.Bounds; +import javafx.geometry.NodeOrientation; +import javafx.geometry.Orientation; +import javafx.geometry.Point2D; +import javafx.geometry.Point3D; +import javafx.scene.AccessibleAction; +import javafx.scene.AccessibleAttribute; +import javafx.scene.AccessibleRole; +import javafx.scene.CacheHint; +import javafx.scene.Cursor; +import javafx.scene.DepthTest; +import javafx.scene.Parent; +import javafx.scene.Scene; +import javafx.scene.SnapshotParameters; +import javafx.scene.SnapshotResult; +import javafx.scene.effect.BlendMode; +import javafx.scene.effect.Effect; +import javafx.scene.image.WritableImage; +import javafx.scene.input.ContextMenuEvent; +import javafx.scene.input.DragEvent; +import javafx.scene.input.Dragboard; +import javafx.scene.input.InputMethodEvent; +import javafx.scene.input.InputMethodRequests; +import javafx.scene.input.KeyEvent; +import javafx.scene.input.MouseDragEvent; +import javafx.scene.input.MouseEvent; +import javafx.scene.input.RotateEvent; +import javafx.scene.input.ScrollEvent; +import javafx.scene.input.SwipeEvent; +import javafx.scene.input.TouchEvent; +import javafx.scene.input.TransferMode; +import javafx.scene.input.ZoomEvent; +import javafx.scene.transform.Transform; +import javafx.util.Callback; + +abstract public class Node implements EventTarget, Styleable +{ + protected Boolean getInitialFocusTraversable(){ return null; } + protected Cursor getInitialCursor(){ return null; } + protected Node(){} + protected final void setEventHandler(javafx.event.EventType p0, javafx.event.EventHandler p1){} + protected final void setDisabled(boolean p0){} + protected final void setFocused(boolean p0){} + protected final void setHover(boolean p0){} + protected final void setPressed(boolean p0){} + public Bounds localToParent(Bounds p0){ return null; } + public Bounds localToScene(Bounds p0){ return null; } + public Bounds localToScene(Bounds p0, boolean p1){ return null; } + public Bounds localToScreen(Bounds p0){ return null; } + public Bounds parentToLocal(Bounds p0){ return null; } + public Bounds sceneToLocal(Bounds p0){ return null; } + public Bounds sceneToLocal(Bounds p0, boolean p1){ return null; } + public Bounds screenToLocal(Bounds p0){ return null; } + public Dragboard startDragAndDrop(TransferMode... p0){ return null; } + public EventDispatchChain buildEventDispatchChain(EventDispatchChain p0){ return null; } + public List> getCssMetaData(){ return null; } + public Node lookup(String p0){ return null; } + public Object getUserData(){ return null; } + public Object queryAccessibleAttribute(AccessibleAttribute p0, Object... p1){ return null; } + public Orientation getContentBias(){ return null; } + public Point2D localToParent(Point2D p0){ return null; } + public Point2D localToParent(double p0, double p1){ return null; } + public Point2D localToScene(Point2D p0){ return null; } + public Point2D localToScene(Point2D p0, boolean p1){ return null; } + public Point2D localToScene(double p0, double p1){ return null; } + public Point2D localToScene(double p0, double p1, boolean p2){ return null; } + public Point2D localToScreen(Point2D p0){ return null; } + public Point2D localToScreen(Point3D p0){ return null; } + public Point2D localToScreen(double p0, double p1){ return null; } + public Point2D localToScreen(double p0, double p1, double p2){ return null; } + public Point2D parentToLocal(Point2D p0){ return null; } + public Point2D parentToLocal(double p0, double p1){ return null; } + public Point2D sceneToLocal(Point2D p0){ return null; } + public Point2D sceneToLocal(Point2D p0, boolean p1){ return null; } + public Point2D sceneToLocal(double p0, double p1){ return null; } + public Point2D sceneToLocal(double p0, double p1, boolean p2){ return null; } + public Point2D screenToLocal(Point2D p0){ return null; } + public Point2D screenToLocal(double p0, double p1){ return null; } + public Point3D localToParent(Point3D p0){ return null; } + public Point3D localToParent(double p0, double p1, double p2){ return null; } + public Point3D localToScene(Point3D p0){ return null; } + public Point3D localToScene(Point3D p0, boolean p1){ return null; } + public Point3D localToScene(double p0, double p1, double p2){ return null; } + public Point3D localToScene(double p0, double p1, double p2, boolean p3){ return null; } + public Point3D parentToLocal(Point3D p0){ return null; } + public Point3D parentToLocal(double p0, double p1, double p2){ return null; } + public Point3D sceneToLocal(Point3D p0){ return null; } + public Point3D sceneToLocal(double p0, double p1, double p2){ return null; } + public Set lookupAll(String p0){ return null; } + public String getTypeSelector(){ return null; } + public String toString(){ return null; } + public Styleable getStyleableParent(){ return null; } + public WritableImage snapshot(SnapshotParameters p0, WritableImage p1){ return null; } + public boolean contains(Point2D p0){ return false; } + public boolean contains(double p0, double p1){ return false; } + public boolean hasProperties(){ return false; } + public boolean intersects(Bounds p0){ return false; } + public boolean intersects(double p0, double p1, double p2, double p3){ return false; } + public boolean isResizable(){ return false; } + public boolean usesMirroring(){ return false; } + public double computeAreaInScreen(){ return 0; } + public double getBaselineOffset(){ return 0; } + public double maxHeight(double p0){ return 0; } + public double maxWidth(double p0){ return 0; } + public double minHeight(double p0){ return 0; } + public double minWidth(double p0){ return 0; } + public double prefHeight(double p0){ return 0; } + public double prefWidth(double p0){ return 0; } + public final void addEventFilter(javafx.event.EventType p0, javafx.event.EventHandler p1){} + public final void addEventHandler(javafx.event.EventType p0, javafx.event.EventHandler p1){} + public final void removeEventFilter(javafx.event.EventType p0, javafx.event.EventHandler p1){} + public final void removeEventHandler(javafx.event.EventType p0, javafx.event.EventHandler p1){} + public final AccessibleRole getAccessibleRole(){ return null; } + public final BlendMode getBlendMode(){ return null; } + public final BooleanProperty cacheProperty(){ return null; } + public final BooleanProperty disableProperty(){ return null; } + public final BooleanProperty focusTraversableProperty(){ return null; } + public final BooleanProperty managedProperty(){ return null; } + public final BooleanProperty mouseTransparentProperty(){ return null; } + public final BooleanProperty pickOnBoundsProperty(){ return null; } + public final BooleanProperty visibleProperty(){ return null; } + public final Bounds getBoundsInLocal(){ return null; } + public final Bounds getBoundsInParent(){ return null; } + public final Bounds getLayoutBounds(){ return null; } + public final CacheHint getCacheHint(){ return null; } + public final Cursor getCursor(){ return null; } + public final DepthTest getDepthTest(){ return null; } + public final DoubleProperty layoutXProperty(){ return null; } + public final DoubleProperty layoutYProperty(){ return null; } + public final DoubleProperty opacityProperty(){ return null; } + public final DoubleProperty rotateProperty(){ return null; } + public final DoubleProperty scaleXProperty(){ return null; } + public final DoubleProperty scaleYProperty(){ return null; } + public final DoubleProperty scaleZProperty(){ return null; } + public final DoubleProperty translateXProperty(){ return null; } + public final DoubleProperty translateYProperty(){ return null; } + public final DoubleProperty translateZProperty(){ return null; } + public final DoubleProperty viewOrderProperty(){ return null; } + public final Effect getEffect(){ return null; } + public final EventDispatcher getEventDispatcher(){ return null; } + public final EventHandler getOnContextMenuRequested(){ return null; } + public final EventHandler getOnDragDone(){ return null; } + public final EventHandler getOnDragDropped(){ return null; } + public final EventHandler getOnDragEntered(){ return null; } + public final EventHandler getOnDragExited(){ return null; } + public final EventHandler getOnDragOver(){ return null; } + public final EventHandler getOnInputMethodTextChanged(){ return null; } + public final EventHandler getOnKeyPressed(){ return null; } + public final EventHandler getOnKeyReleased(){ return null; } + public final EventHandler getOnKeyTyped(){ return null; } + public final EventHandler getOnMouseDragEntered(){ return null; } + public final EventHandler getOnMouseDragExited(){ return null; } + public final EventHandler getOnMouseDragOver(){ return null; } + public final EventHandler getOnMouseDragReleased(){ return null; } + public final EventHandler getOnDragDetected(){ return null; } + public final EventHandler getOnMouseClicked(){ return null; } + public final EventHandler getOnMouseDragged(){ return null; } + public final EventHandler getOnMouseEntered(){ return null; } + public final EventHandler getOnMouseExited(){ return null; } + public final EventHandler getOnMouseMoved(){ return null; } + public final EventHandler getOnMousePressed(){ return null; } + public final EventHandler getOnMouseReleased(){ return null; } + public final EventHandler getOnRotate(){ return null; } + public final EventHandler getOnRotationFinished(){ return null; } + public final EventHandler getOnRotationStarted(){ return null; } + public final EventHandler getOnScroll(){ return null; } + public final EventHandler getOnScrollFinished(){ return null; } + public final EventHandler getOnScrollStarted(){ return null; } + public final EventHandler getOnSwipeDown(){ return null; } + public final EventHandler getOnSwipeLeft(){ return null; } + public final EventHandler getOnSwipeRight(){ return null; } + public final EventHandler getOnSwipeUp(){ return null; } + public final EventHandler getOnTouchMoved(){ return null; } + public final EventHandler getOnTouchPressed(){ return null; } + public final EventHandler getOnTouchReleased(){ return null; } + public final EventHandler getOnTouchStationary(){ return null; } + public final EventHandler getOnZoom(){ return null; } + public final EventHandler getOnZoomFinished(){ return null; } + public final EventHandler getOnZoomStarted(){ return null; } + public final InputMethodRequests getInputMethodRequests(){ return null; } + public final Node getClip(){ return null; } + public final NodeOrientation getEffectiveNodeOrientation(){ return null; } + public final NodeOrientation getNodeOrientation(){ return null; } + public final ObjectProperty accessibleRoleProperty(){ return null; } + public final ObjectProperty blendModeProperty(){ return null; } + public final ObjectProperty cacheHintProperty(){ return null; } + public final ObjectProperty cursorProperty(){ return null; } + public final ObjectProperty depthTestProperty(){ return null; } + public final ObjectProperty effectProperty(){ return null; } + public final ObjectProperty eventDispatcherProperty(){ return null; } + public final ObjectProperty> onContextMenuRequestedProperty(){ return null; } + public final ObjectProperty> onDragDoneProperty(){ return null; } + public final ObjectProperty> onDragDroppedProperty(){ return null; } + public final ObjectProperty> onDragEnteredProperty(){ return null; } + public final ObjectProperty> onDragExitedProperty(){ return null; } + public final ObjectProperty> onDragOverProperty(){ return null; } + public final ObjectProperty> onInputMethodTextChangedProperty(){ return null; } + public final ObjectProperty> onKeyPressedProperty(){ return null; } + public final ObjectProperty> onKeyReleasedProperty(){ return null; } + public final ObjectProperty> onKeyTypedProperty(){ return null; } + public final ObjectProperty> onMouseDragEnteredProperty(){ return null; } + public final ObjectProperty> onMouseDragExitedProperty(){ return null; } + public final ObjectProperty> onMouseDragOverProperty(){ return null; } + public final ObjectProperty> onMouseDragReleasedProperty(){ return null; } + public final ObjectProperty> onDragDetectedProperty(){ return null; } + public final ObjectProperty> onMouseClickedProperty(){ return null; } + public final ObjectProperty> onMouseDraggedProperty(){ return null; } + public final ObjectProperty> onMouseEnteredProperty(){ return null; } + public final ObjectProperty> onMouseExitedProperty(){ return null; } + public final ObjectProperty> onMouseMovedProperty(){ return null; } + public final ObjectProperty> onMousePressedProperty(){ return null; } + public final ObjectProperty> onMouseReleasedProperty(){ return null; } + public final ObjectProperty> onRotateProperty(){ return null; } + public final ObjectProperty> onRotationFinishedProperty(){ return null; } + public final ObjectProperty> onRotationStartedProperty(){ return null; } + public final ObjectProperty> onScrollFinishedProperty(){ return null; } + public final ObjectProperty> onScrollProperty(){ return null; } + public final ObjectProperty> onScrollStartedProperty(){ return null; } + public final ObjectProperty> onSwipeDownProperty(){ return null; } + public final ObjectProperty> onSwipeLeftProperty(){ return null; } + public final ObjectProperty> onSwipeRightProperty(){ return null; } + public final ObjectProperty> onSwipeUpProperty(){ return null; } + public final ObjectProperty> onTouchMovedProperty(){ return null; } + public final ObjectProperty> onTouchPressedProperty(){ return null; } + public final ObjectProperty> onTouchReleasedProperty(){ return null; } + public final ObjectProperty> onTouchStationaryProperty(){ return null; } + public final ObjectProperty> onZoomFinishedProperty(){ return null; } + public final ObjectProperty> onZoomProperty(){ return null; } + public final ObjectProperty> onZoomStartedProperty(){ return null; } + public final ObjectProperty inputMethodRequestsProperty(){ return null; } + public final ObjectProperty clipProperty(){ return null; } + public final ObjectProperty nodeOrientationProperty(){ return null; } + public final ObjectProperty rotationAxisProperty(){ return null; } + public final ObjectProperty accessibleHelpProperty(){ return null; } + public final ObjectProperty accessibleRoleDescriptionProperty(){ return null; } + public final ObjectProperty accessibleTextProperty(){ return null; } + public final ObservableList getStyleClass(){ return null; } + public final ObservableList getTransforms(){ return null; } + public final ObservableMap getProperties(){ return null; } + public final ObservableSet getPseudoClassStates(){ return null; } + public final Parent getParent(){ return null; } + public final Point3D getRotationAxis(){ return null; } + public final ReadOnlyBooleanProperty disabledProperty(){ return null; } + public final ReadOnlyBooleanProperty focusVisibleProperty(){ return null; } + public final ReadOnlyBooleanProperty focusWithinProperty(){ return null; } + public final ReadOnlyBooleanProperty focusedProperty(){ return null; } + public final ReadOnlyBooleanProperty hoverProperty(){ return null; } + public final ReadOnlyBooleanProperty pressedProperty(){ return null; } + public final ReadOnlyObjectProperty boundsInLocalProperty(){ return null; } + public final ReadOnlyObjectProperty boundsInParentProperty(){ return null; } + public final ReadOnlyObjectProperty layoutBoundsProperty(){ return null; } + public final ReadOnlyObjectProperty effectiveNodeOrientationProperty(){ return null; } + public final ReadOnlyObjectProperty parentProperty(){ return null; } + public final ReadOnlyObjectProperty sceneProperty(){ return null; } + public final ReadOnlyObjectProperty localToParentTransformProperty(){ return null; } + public final ReadOnlyObjectProperty localToSceneTransformProperty(){ return null; } + public final Scene getScene(){ return null; } + public final String getAccessibleHelp(){ return null; } + public final String getAccessibleRoleDescription(){ return null; } + public final String getAccessibleText(){ return null; } + public final String getId(){ return null; } + public final String getStyle(){ return null; } + public final StringProperty idProperty(){ return null; } + public final StringProperty styleProperty(){ return null; } + public final Transform getLocalToParentTransform(){ return null; } + public final Transform getLocalToSceneTransform(){ return null; } + public final boolean isCache(){ return false; } + public final boolean isDisable(){ return false; } + public final boolean isDisabled(){ return false; } + public final boolean isFocusTraversable(){ return false; } + public final boolean isFocusVisible(){ return false; } + public final boolean isFocusWithin(){ return false; } + public final boolean isFocused(){ return false; } + public final boolean isHover(){ return false; } + public final boolean isManaged(){ return false; } + public final boolean isMouseTransparent(){ return false; } + public final boolean isPickOnBounds(){ return false; } + public final boolean isPressed(){ return false; } + public final boolean isVisible(){ return false; } + public final double getLayoutX(){ return 0; } + public final double getLayoutY(){ return 0; } + public final double getOpacity(){ return 0; } + public final double getRotate(){ return 0; } + public final double getScaleX(){ return 0; } + public final double getScaleY(){ return 0; } + public final double getScaleZ(){ return 0; } + public final double getTranslateX(){ return 0; } + public final double getTranslateY(){ return 0; } + public final double getTranslateZ(){ return 0; } + public final double getViewOrder(){ return 0; } + public final void applyCss(){} + public final void autosize(){} + public final void fireEvent(Event p0){} + public final void notifyAccessibleAttributeChanged(AccessibleAttribute p0){} + public final void pseudoClassStateChanged(PseudoClass p0, boolean p1){} + public final void setAccessibleHelp(String p0){} + public final void setAccessibleRole(AccessibleRole p0){} + public final void setAccessibleRoleDescription(String p0){} + public final void setAccessibleText(String p0){} + public final void setBlendMode(BlendMode p0){} + public final void setCache(boolean p0){} + public final void setCacheHint(CacheHint p0){} + public final void setClip(Node p0){} + public final void setCursor(Cursor p0){} + public final void setDepthTest(DepthTest p0){} + public final void setDisable(boolean p0){} + public final void setEffect(Effect p0){} + public final void setEventDispatcher(EventDispatcher p0){} + public final void setFocusTraversable(boolean p0){} + public final void setId(String p0){} + public final void setInputMethodRequests(InputMethodRequests p0){} + public final void setLayoutX(double p0){} + public final void setLayoutY(double p0){} + public final void setManaged(boolean p0){} + public final void setMouseTransparent(boolean p0){} + public final void setNodeOrientation(NodeOrientation p0){} + public final void setOnContextMenuRequested(EventHandler p0){} + public final void setOnDragDetected(EventHandler p0){} + public final void setOnDragDone(EventHandler p0){} + public final void setOnDragDropped(EventHandler p0){} + public final void setOnDragEntered(EventHandler p0){} + public final void setOnDragExited(EventHandler p0){} + public final void setOnDragOver(EventHandler p0){} + public final void setOnInputMethodTextChanged(EventHandler p0){} + public final void setOnKeyPressed(EventHandler p0){} + public final void setOnKeyReleased(EventHandler p0){} + public final void setOnKeyTyped(EventHandler p0){} + public final void setOnMouseClicked(EventHandler p0){} + public final void setOnMouseDragEntered(EventHandler p0){} + public final void setOnMouseDragExited(EventHandler p0){} + public final void setOnMouseDragOver(EventHandler p0){} + public final void setOnMouseDragReleased(EventHandler p0){} + public final void setOnMouseDragged(EventHandler p0){} + public final void setOnMouseEntered(EventHandler p0){} + public final void setOnMouseExited(EventHandler p0){} + public final void setOnMouseMoved(EventHandler p0){} + public final void setOnMousePressed(EventHandler p0){} + public final void setOnMouseReleased(EventHandler p0){} + public final void setOnRotate(EventHandler p0){} + public final void setOnRotationFinished(EventHandler p0){} + public final void setOnRotationStarted(EventHandler p0){} + public final void setOnScroll(EventHandler p0){} + public final void setOnScrollFinished(EventHandler p0){} + public final void setOnScrollStarted(EventHandler p0){} + public final void setOnSwipeDown(EventHandler p0){} + public final void setOnSwipeLeft(EventHandler p0){} + public final void setOnSwipeRight(EventHandler p0){} + public final void setOnSwipeUp(EventHandler p0){} + public final void setOnTouchMoved(EventHandler p0){} + public final void setOnTouchPressed(EventHandler p0){} + public final void setOnTouchReleased(EventHandler p0){} + public final void setOnTouchStationary(EventHandler p0){} + public final void setOnZoom(EventHandler p0){} + public final void setOnZoomFinished(EventHandler p0){} + public final void setOnZoomStarted(EventHandler p0){} + public final void setOpacity(double p0){} + public final void setPickOnBounds(boolean p0){} + public final void setRotate(double p0){} + public final void setRotationAxis(Point3D p0){} + public final void setScaleX(double p0){} + public final void setScaleY(double p0){} + public final void setScaleZ(double p0){} + public final void setStyle(String p0){} + public final void setTranslateX(double p0){} + public final void setTranslateY(double p0){} + public final void setTranslateZ(double p0){} + public final void setViewOrder(double p0){} + public final void setVisible(boolean p0){} + public static List> getClassCssMetaData(){ return null; } + public static double BASELINE_OFFSET_SAME_AS_HEIGHT = 0; + public void executeAccessibleAction(AccessibleAction p0, Object... p1){} + public void relocate(double p0, double p1){} + public void requestFocus(){} + public void resize(double p0, double p1){} + public void resizeRelocate(double p0, double p1, double p2, double p3){} + public void setUserData(Object p0){} + public void snapshot(Callback p0, SnapshotParameters p1, WritableImage p2){} + public void startFullDrag(){} + public void toBack(){} + public void toFront(){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/Parent.java b/java/ql/test/stubs/javafx-web/javafx/scene/Parent.java new file mode 100644 index 00000000000..f702c6f4e70 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/Parent.java @@ -0,0 +1,37 @@ +// Generated automatically from javafx.scene.Parent for testing purposes + +package javafx.scene; + +import java.util.List; +import javafx.beans.property.ReadOnlyBooleanProperty; +import javafx.collections.ObservableList; +import javafx.scene.AccessibleAttribute; +import javafx.scene.Node; + +abstract public class Parent extends Node +{ + protected java.util.List getManagedChildren(){ return null; } + protected ObservableList getChildren(){ return null; } + protected Parent(){} + protected double computeMinHeight(double p0){ return 0; } + protected double computeMinWidth(double p0){ return 0; } + protected double computePrefHeight(double p0){ return 0; } + protected double computePrefWidth(double p0){ return 0; } + protected final void requestParentLayout(){} + protected final void setNeedsLayout(boolean p0){} + protected void layoutChildren(){} + protected void updateBounds(){} + public Node lookup(String p0){ return null; } + public Object queryAccessibleAttribute(AccessibleAttribute p0, Object... p1){ return null; } + public ObservableList getChildrenUnmodifiable(){ return null; } + public double getBaselineOffset(){ return 0; } + public double minHeight(double p0){ return 0; } + public double minWidth(double p0){ return 0; } + public double prefHeight(double p0){ return 0; } + public double prefWidth(double p0){ return 0; } + public final ObservableList getStylesheets(){ return null; } + public final ReadOnlyBooleanProperty needsLayoutProperty(){ return null; } + public final boolean isNeedsLayout(){ return false; } + public final void layout(){} + public void requestLayout(){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/Scene.java b/java/ql/test/stubs/javafx-web/javafx/scene/Scene.java new file mode 100644 index 00000000000..cde4aa15e69 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/Scene.java @@ -0,0 +1,233 @@ +// Generated automatically from javafx.scene.Scene for testing purposes + +package javafx.scene; + +import com.sun.javafx.tk.TKClipboard; +import com.sun.javafx.tk.TKDragGestureListener; +import com.sun.javafx.tk.TKPulseListener; +import javafx.beans.property.ObjectProperty; +import javafx.beans.property.ReadOnlyDoubleProperty; +import javafx.beans.property.ReadOnlyObjectProperty; +import javafx.collections.ObservableList; +import javafx.collections.ObservableMap; +import javafx.event.Event; +import javafx.event.EventDispatchChain; +import javafx.event.EventDispatcher; +import javafx.event.EventHandler; +import javafx.event.EventTarget; +import javafx.event.EventType; +import javafx.geometry.NodeOrientation; +import javafx.scene.Camera; +import javafx.scene.Cursor; +import javafx.scene.Node; +import javafx.scene.Parent; +import javafx.scene.SceneAntialiasing; +import javafx.scene.SnapshotResult; +import javafx.scene.image.WritableImage; +import javafx.scene.input.ContextMenuEvent; +import javafx.scene.input.DragEvent; +import javafx.scene.input.Dragboard; +import javafx.scene.input.InputMethodEvent; +import javafx.scene.input.KeyCombination; +import javafx.scene.input.KeyEvent; +import javafx.scene.input.Mnemonic; +import javafx.scene.input.MouseDragEvent; +import javafx.scene.input.MouseEvent; +import javafx.scene.input.RotateEvent; +import javafx.scene.input.ScrollEvent; +import javafx.scene.input.SwipeEvent; +import javafx.scene.input.TouchEvent; +import javafx.scene.input.TransferMode; +import javafx.scene.input.ZoomEvent; +import javafx.scene.paint.Paint; +import javafx.stage.Window; +import javafx.util.Callback; + +public class Scene implements EventTarget +{ + protected Scene() {} + protected final void setEventHandler(javafx.event.EventType p0, javafx.event.EventHandler p1){} + public Dragboard startDragAndDrop(TransferMode... p0){ return null; } + public EventDispatchChain buildEventDispatchChain(EventDispatchChain p0){ return null; } + public Node lookup(String p0){ return null; } + public Object getUserData(){ return null; } + public ObservableMap> getMnemonics(){ return null; } + public ObservableMap getAccelerators(){ return null; } + public Scene(Parent p0){} + public Scene(Parent p0, Paint p1){} + public Scene(Parent p0, double p1, double p2){} + public Scene(Parent p0, double p1, double p2, Paint p3){} + public Scene(Parent p0, double p1, double p2, boolean p3){} + public Scene(Parent p0, double p1, double p2, boolean p3, SceneAntialiasing p4){} + public WritableImage snapshot(WritableImage p0){ return null; } + public boolean hasProperties(){ return false; } + public final void addEventFilter(javafx.event.EventType p0, javafx.event.EventHandler p1){} + public final void addEventHandler(javafx.event.EventType p0, javafx.event.EventHandler p1){} + public final void removeEventFilter(javafx.event.EventType p0, javafx.event.EventHandler p1){} + public final void removeEventHandler(javafx.event.EventType p0, javafx.event.EventHandler p1){} + public final Camera getCamera(){ return null; } + public final Cursor getCursor(){ return null; } + public final EventDispatcher getEventDispatcher(){ return null; } + public final EventHandler getOnContextMenuRequested(){ return null; } + public final EventHandler getOnDragDone(){ return null; } + public final EventHandler getOnDragDropped(){ return null; } + public final EventHandler getOnDragEntered(){ return null; } + public final EventHandler getOnDragExited(){ return null; } + public final EventHandler getOnDragOver(){ return null; } + public final EventHandler getOnInputMethodTextChanged(){ return null; } + public final EventHandler getOnKeyPressed(){ return null; } + public final EventHandler getOnKeyReleased(){ return null; } + public final EventHandler getOnKeyTyped(){ return null; } + public final EventHandler getOnMouseDragEntered(){ return null; } + public final EventHandler getOnMouseDragExited(){ return null; } + public final EventHandler getOnMouseDragOver(){ return null; } + public final EventHandler getOnMouseDragReleased(){ return null; } + public final EventHandler getOnDragDetected(){ return null; } + public final EventHandler getOnMouseClicked(){ return null; } + public final EventHandler getOnMouseDragged(){ return null; } + public final EventHandler getOnMouseEntered(){ return null; } + public final EventHandler getOnMouseExited(){ return null; } + public final EventHandler getOnMouseMoved(){ return null; } + public final EventHandler getOnMousePressed(){ return null; } + public final EventHandler getOnMouseReleased(){ return null; } + public final EventHandler getOnRotate(){ return null; } + public final EventHandler getOnRotationFinished(){ return null; } + public final EventHandler getOnRotationStarted(){ return null; } + public final EventHandler getOnScroll(){ return null; } + public final EventHandler getOnScrollFinished(){ return null; } + public final EventHandler getOnScrollStarted(){ return null; } + public final EventHandler getOnSwipeDown(){ return null; } + public final EventHandler getOnSwipeLeft(){ return null; } + public final EventHandler getOnSwipeRight(){ return null; } + public final EventHandler getOnSwipeUp(){ return null; } + public final EventHandler getOnTouchMoved(){ return null; } + public final EventHandler getOnTouchPressed(){ return null; } + public final EventHandler getOnTouchReleased(){ return null; } + public final EventHandler getOnTouchStationary(){ return null; } + public final EventHandler getOnZoom(){ return null; } + public final EventHandler getOnZoomFinished(){ return null; } + public final EventHandler getOnZoomStarted(){ return null; } + public final Node getFocusOwner(){ return null; } + public final NodeOrientation getEffectiveNodeOrientation(){ return null; } + public final NodeOrientation getNodeOrientation(){ return null; } + public final ObjectProperty cameraProperty(){ return null; } + public final ObjectProperty cursorProperty(){ return null; } + public final ObjectProperty eventDispatcherProperty(){ return null; } + public final ObjectProperty> onContextMenuRequestedProperty(){ return null; } + public final ObjectProperty> onDragDoneProperty(){ return null; } + public final ObjectProperty> onDragDroppedProperty(){ return null; } + public final ObjectProperty> onDragEnteredProperty(){ return null; } + public final ObjectProperty> onDragExitedProperty(){ return null; } + public final ObjectProperty> onDragOverProperty(){ return null; } + public final ObjectProperty> onInputMethodTextChangedProperty(){ return null; } + public final ObjectProperty> onKeyPressedProperty(){ return null; } + public final ObjectProperty> onKeyReleasedProperty(){ return null; } + public final ObjectProperty> onKeyTypedProperty(){ return null; } + public final ObjectProperty> onMouseDragEnteredProperty(){ return null; } + public final ObjectProperty> onMouseDragExitedProperty(){ return null; } + public final ObjectProperty> onMouseDragOverProperty(){ return null; } + public final ObjectProperty> onMouseDragReleasedProperty(){ return null; } + public final ObjectProperty> onDragDetectedProperty(){ return null; } + public final ObjectProperty> onMouseClickedProperty(){ return null; } + public final ObjectProperty> onMouseDraggedProperty(){ return null; } + public final ObjectProperty> onMouseEnteredProperty(){ return null; } + public final ObjectProperty> onMouseExitedProperty(){ return null; } + public final ObjectProperty> onMouseMovedProperty(){ return null; } + public final ObjectProperty> onMousePressedProperty(){ return null; } + public final ObjectProperty> onMouseReleasedProperty(){ return null; } + public final ObjectProperty> onRotateProperty(){ return null; } + public final ObjectProperty> onRotationFinishedProperty(){ return null; } + public final ObjectProperty> onRotationStartedProperty(){ return null; } + public final ObjectProperty> onScrollFinishedProperty(){ return null; } + public final ObjectProperty> onScrollProperty(){ return null; } + public final ObjectProperty> onScrollStartedProperty(){ return null; } + public final ObjectProperty> onSwipeDownProperty(){ return null; } + public final ObjectProperty> onSwipeLeftProperty(){ return null; } + public final ObjectProperty> onSwipeRightProperty(){ return null; } + public final ObjectProperty> onSwipeUpProperty(){ return null; } + public final ObjectProperty> onTouchMovedProperty(){ return null; } + public final ObjectProperty> onTouchPressedProperty(){ return null; } + public final ObjectProperty> onTouchReleasedProperty(){ return null; } + public final ObjectProperty> onTouchStationaryProperty(){ return null; } + public final ObjectProperty> onZoomFinishedProperty(){ return null; } + public final ObjectProperty> onZoomProperty(){ return null; } + public final ObjectProperty> onZoomStartedProperty(){ return null; } + public final ObjectProperty nodeOrientationProperty(){ return null; } + public final ObjectProperty fillProperty(){ return null; } + public final ObjectProperty rootProperty(){ return null; } + public final ObjectProperty userAgentStylesheetProperty(){ return null; } + public final ObservableList getStylesheets(){ return null; } + public final ObservableMap getProperties(){ return null; } + public final Paint getFill(){ return null; } + public final Parent getRoot(){ return null; } + public final ReadOnlyDoubleProperty heightProperty(){ return null; } + public final ReadOnlyDoubleProperty widthProperty(){ return null; } + public final ReadOnlyDoubleProperty xProperty(){ return null; } + public final ReadOnlyDoubleProperty yProperty(){ return null; } + public final ReadOnlyObjectProperty focusOwnerProperty(){ return null; } + public final ReadOnlyObjectProperty effectiveNodeOrientationProperty(){ return null; } + public final ReadOnlyObjectProperty windowProperty(){ return null; } + public final SceneAntialiasing getAntiAliasing(){ return null; } + public final String getUserAgentStylesheet(){ return null; } + public final Window getWindow(){ return null; } + public final boolean isDepthBuffer(){ return false; } + public final double getHeight(){ return 0; } + public final double getWidth(){ return 0; } + public final double getX(){ return 0; } + public final double getY(){ return 0; } + public final void addPostLayoutPulseListener(Runnable p0){} + public final void addPreLayoutPulseListener(Runnable p0){} + public final void removePostLayoutPulseListener(Runnable p0){} + public final void removePreLayoutPulseListener(Runnable p0){} + public final void setCamera(Camera p0){} + public final void setCursor(Cursor p0){} + public final void setEventDispatcher(EventDispatcher p0){} + public final void setFill(Paint p0){} + public final void setNodeOrientation(NodeOrientation p0){} + public final void setOnContextMenuRequested(EventHandler p0){} + public final void setOnDragDetected(EventHandler p0){} + public final void setOnDragDone(EventHandler p0){} + public final void setOnDragDropped(EventHandler p0){} + public final void setOnDragEntered(EventHandler p0){} + public final void setOnDragExited(EventHandler p0){} + public final void setOnDragOver(EventHandler p0){} + public final void setOnInputMethodTextChanged(EventHandler p0){} + public final void setOnKeyPressed(EventHandler p0){} + public final void setOnKeyReleased(EventHandler p0){} + public final void setOnKeyTyped(EventHandler p0){} + public final void setOnMouseClicked(EventHandler p0){} + public final void setOnMouseDragEntered(EventHandler p0){} + public final void setOnMouseDragExited(EventHandler p0){} + public final void setOnMouseDragOver(EventHandler p0){} + public final void setOnMouseDragReleased(EventHandler p0){} + public final void setOnMouseDragged(EventHandler p0){} + public final void setOnMouseEntered(EventHandler p0){} + public final void setOnMouseExited(EventHandler p0){} + public final void setOnMouseMoved(EventHandler p0){} + public final void setOnMousePressed(EventHandler p0){} + public final void setOnMouseReleased(EventHandler p0){} + public final void setOnRotate(EventHandler p0){} + public final void setOnRotationFinished(EventHandler p0){} + public final void setOnRotationStarted(EventHandler p0){} + public final void setOnScroll(EventHandler p0){} + public final void setOnScrollFinished(EventHandler p0){} + public final void setOnScrollStarted(EventHandler p0){} + public final void setOnSwipeDown(EventHandler p0){} + public final void setOnSwipeLeft(EventHandler p0){} + public final void setOnSwipeRight(EventHandler p0){} + public final void setOnSwipeUp(EventHandler p0){} + public final void setOnTouchMoved(EventHandler p0){} + public final void setOnTouchPressed(EventHandler p0){} + public final void setOnTouchReleased(EventHandler p0){} + public final void setOnTouchStationary(EventHandler p0){} + public final void setOnZoom(EventHandler p0){} + public final void setOnZoomFinished(EventHandler p0){} + public final void setOnZoomStarted(EventHandler p0){} + public final void setRoot(Parent p0){} + public final void setUserAgentStylesheet(String p0){} + public void addMnemonic(Mnemonic p0){} + public void removeMnemonic(Mnemonic p0){} + public void setUserData(Object p0){} + public void snapshot(Callback p0, WritableImage p1){} + public void startFullDrag(){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/SceneAntialiasing.java b/java/ql/test/stubs/javafx-web/javafx/scene/SceneAntialiasing.java new file mode 100644 index 00000000000..fc24f3f34ad --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/SceneAntialiasing.java @@ -0,0 +1,12 @@ +// Generated automatically from javafx.scene.SceneAntialiasing for testing purposes + +package javafx.scene; + + +public class SceneAntialiasing +{ + protected SceneAntialiasing() {} + public String toString(){ return null; } + public static SceneAntialiasing BALANCED = null; + public static SceneAntialiasing DISABLED = null; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/SnapshotParameters.java b/java/ql/test/stubs/javafx-web/javafx/scene/SnapshotParameters.java new file mode 100644 index 00000000000..49abb2ce4cd --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/SnapshotParameters.java @@ -0,0 +1,23 @@ +// Generated automatically from javafx.scene.SnapshotParameters for testing purposes + +package javafx.scene; + +import javafx.geometry.Rectangle2D; +import javafx.scene.Camera; +import javafx.scene.paint.Paint; +import javafx.scene.transform.Transform; + +public class SnapshotParameters +{ + public Camera getCamera(){ return null; } + public Paint getFill(){ return null; } + public Rectangle2D getViewport(){ return null; } + public SnapshotParameters(){} + public Transform getTransform(){ return null; } + public boolean isDepthBuffer(){ return false; } + public void setCamera(Camera p0){} + public void setDepthBuffer(boolean p0){} + public void setFill(Paint p0){} + public void setTransform(Transform p0){} + public void setViewport(Rectangle2D p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/SnapshotResult.java b/java/ql/test/stubs/javafx-web/javafx/scene/SnapshotResult.java new file mode 100644 index 00000000000..cd3ed405f43 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/SnapshotResult.java @@ -0,0 +1,14 @@ +// Generated automatically from javafx.scene.SnapshotResult for testing purposes + +package javafx.scene; + +import javafx.scene.SnapshotParameters; +import javafx.scene.image.WritableImage; + +public class SnapshotResult +{ + protected SnapshotResult() {} + public Object getSource(){ return null; } + public SnapshotParameters getSnapshotParameters(){ return null; } + public WritableImage getImage(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/effect/BlendMode.java b/java/ql/test/stubs/javafx-web/javafx/scene/effect/BlendMode.java new file mode 100644 index 00000000000..e9f9dfa4245 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/effect/BlendMode.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.scene.effect.BlendMode for testing purposes + +package javafx.scene.effect; + + +public enum BlendMode +{ + ADD, BLUE, COLOR_BURN, COLOR_DODGE, DARKEN, DIFFERENCE, EXCLUSION, GREEN, HARD_LIGHT, LIGHTEN, MULTIPLY, OVERLAY, RED, SCREEN, SOFT_LIGHT, SRC_ATOP, SRC_OVER; + private BlendMode() {} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/effect/Effect.java b/java/ql/test/stubs/javafx-web/javafx/scene/effect/Effect.java new file mode 100644 index 00000000000..fa10876cd28 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/effect/Effect.java @@ -0,0 +1,9 @@ +// Generated automatically from javafx.scene.effect.Effect for testing purposes + +package javafx.scene.effect; + + +abstract public class Effect +{ + protected Effect(){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/image/Image.java b/java/ql/test/stubs/javafx-web/javafx/scene/image/Image.java new file mode 100644 index 00000000000..2e367c28f05 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/image/Image.java @@ -0,0 +1,38 @@ +// Generated automatically from javafx.scene.image.Image for testing purposes + +package javafx.scene.image; + +import java.io.InputStream; +import javafx.beans.property.ReadOnlyBooleanProperty; +import javafx.beans.property.ReadOnlyDoubleProperty; +import javafx.beans.property.ReadOnlyObjectProperty; +import javafx.scene.image.PixelReader; + +public class Image +{ + protected Image() {} + public Image(InputStream p0){} + public Image(InputStream p0, double p1, double p2, boolean p3, boolean p4){} + public Image(String p0){} + public Image(String p0, boolean p1){} + public Image(String p0, double p1, double p2, boolean p3, boolean p4){} + public Image(String p0, double p1, double p2, boolean p3, boolean p4, boolean p5){} + public final Exception getException(){ return null; } + public final PixelReader getPixelReader(){ return null; } + public final ReadOnlyBooleanProperty errorProperty(){ return null; } + public final ReadOnlyDoubleProperty heightProperty(){ return null; } + public final ReadOnlyDoubleProperty progressProperty(){ return null; } + public final ReadOnlyDoubleProperty widthProperty(){ return null; } + public final ReadOnlyObjectProperty exceptionProperty(){ return null; } + public final String getUrl(){ return null; } + public final boolean isBackgroundLoading(){ return false; } + public final boolean isError(){ return false; } + public final boolean isPreserveRatio(){ return false; } + public final boolean isSmooth(){ return false; } + public final double getHeight(){ return 0; } + public final double getProgress(){ return 0; } + public final double getRequestedHeight(){ return 0; } + public final double getRequestedWidth(){ return 0; } + public final double getWidth(){ return 0; } + public void cancel(){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/image/PixelBuffer.java b/java/ql/test/stubs/javafx-web/javafx/scene/image/PixelBuffer.java new file mode 100644 index 00000000000..bfb39a69668 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/image/PixelBuffer.java @@ -0,0 +1,19 @@ +// Generated automatically from javafx.scene.image.PixelBuffer for testing purposes + +package javafx.scene.image; + +import java.nio.Buffer; +import javafx.geometry.Rectangle2D; +import javafx.scene.image.PixelFormat; +import javafx.util.Callback; + +public class PixelBuffer +{ + protected PixelBuffer() {} + public PixelBuffer(int p0, int p1, T p2, javafx.scene.image.PixelFormat p3){} + public T getBuffer(){ return null; } + public int getHeight(){ return 0; } + public int getWidth(){ return 0; } + public javafx.scene.image.PixelFormat getPixelFormat(){ return null; } + public void updateBuffer(Callback, Rectangle2D> p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/image/PixelFormat.java b/java/ql/test/stubs/javafx-web/javafx/scene/image/PixelFormat.java new file mode 100644 index 00000000000..6aee71ccfd4 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/image/PixelFormat.java @@ -0,0 +1,29 @@ +// Generated automatically from javafx.scene.image.PixelFormat for testing purposes + +package javafx.scene.image; + +import java.nio.Buffer; +import java.nio.ByteBuffer; +import java.nio.IntBuffer; +import javafx.scene.image.WritablePixelFormat; + +abstract public class PixelFormat +{ + protected PixelFormat() {} + public PixelFormat.Type getType(){ return null; } + public abstract boolean isPremultiplied(); + public abstract boolean isWritable(); + public abstract int getArgb(T p0, int p1, int p2, int p3); + public static PixelFormat createByteIndexedInstance(int[] p0){ return null; } + public static PixelFormat createByteIndexedPremultipliedInstance(int[] p0){ return null; } + public static PixelFormat getByteRgbInstance(){ return null; } + public static WritablePixelFormat getByteBgraInstance(){ return null; } + public static WritablePixelFormat getByteBgraPreInstance(){ return null; } + public static WritablePixelFormat getIntArgbInstance(){ return null; } + public static WritablePixelFormat getIntArgbPreInstance(){ return null; } + static public enum Type + { + BYTE_BGRA, BYTE_BGRA_PRE, BYTE_INDEXED, BYTE_RGB, INT_ARGB, INT_ARGB_PRE; + private Type() {} + } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/image/PixelReader.java b/java/ql/test/stubs/javafx-web/javafx/scene/image/PixelReader.java new file mode 100644 index 00000000000..48591ae90ef --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/image/PixelReader.java @@ -0,0 +1,20 @@ +// Generated automatically from javafx.scene.image.PixelReader for testing purposes + +package javafx.scene.image; + +import java.nio.Buffer; +import java.nio.ByteBuffer; +import java.nio.IntBuffer; +import javafx.scene.image.PixelFormat; +import javafx.scene.image.WritablePixelFormat; +import javafx.scene.paint.Color; + +public interface PixelReader +{ + void getPixels(int p0, int p1, int p2, int p3, javafx.scene.image.WritablePixelFormat p4, T p5, int p6); + Color getColor(int p0, int p1); + PixelFormat getPixelFormat(); + int getArgb(int p0, int p1); + void getPixels(int p0, int p1, int p2, int p3, WritablePixelFormat p4, byte[] p5, int p6, int p7); + void getPixels(int p0, int p1, int p2, int p3, WritablePixelFormat p4, int[] p5, int p6, int p7); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/image/PixelWriter.java b/java/ql/test/stubs/javafx-web/javafx/scene/image/PixelWriter.java new file mode 100644 index 00000000000..22df63d9ed2 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/image/PixelWriter.java @@ -0,0 +1,21 @@ +// Generated automatically from javafx.scene.image.PixelWriter for testing purposes + +package javafx.scene.image; + +import java.nio.Buffer; +import java.nio.ByteBuffer; +import java.nio.IntBuffer; +import javafx.scene.image.PixelFormat; +import javafx.scene.image.PixelReader; +import javafx.scene.paint.Color; + +public interface PixelWriter +{ + void setPixels(int p0, int p1, int p2, int p3, javafx.scene.image.PixelFormat p4, T p5, int p6); + PixelFormat getPixelFormat(); + void setArgb(int p0, int p1, int p2); + void setColor(int p0, int p1, Color p2); + void setPixels(int p0, int p1, int p2, int p3, PixelFormat p4, byte[] p5, int p6, int p7); + void setPixels(int p0, int p1, int p2, int p3, PixelFormat p4, int[] p5, int p6, int p7); + void setPixels(int p0, int p1, int p2, int p3, PixelReader p4, int p5, int p6); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/image/WritableImage.java b/java/ql/test/stubs/javafx-web/javafx/scene/image/WritableImage.java new file mode 100644 index 00000000000..c01e0763a84 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/image/WritableImage.java @@ -0,0 +1,19 @@ +// Generated automatically from javafx.scene.image.WritableImage for testing purposes + +package javafx.scene.image; + +import java.nio.Buffer; +import javafx.scene.image.Image; +import javafx.scene.image.PixelBuffer; +import javafx.scene.image.PixelReader; +import javafx.scene.image.PixelWriter; + +public class WritableImage extends Image +{ + protected WritableImage() {} + public WritableImage(PixelBuffer p0){} + public WritableImage(PixelReader p0, int p1, int p2){} + public WritableImage(PixelReader p0, int p1, int p2, int p3, int p4){} + public WritableImage(int p0, int p1){} + public final PixelWriter getPixelWriter(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/image/WritablePixelFormat.java b/java/ql/test/stubs/javafx-web/javafx/scene/image/WritablePixelFormat.java new file mode 100644 index 00000000000..1d748267ef2 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/image/WritablePixelFormat.java @@ -0,0 +1,13 @@ +// Generated automatically from javafx.scene.image.WritablePixelFormat for testing purposes + +package javafx.scene.image; + +import java.nio.Buffer; +import javafx.scene.image.PixelFormat; + +abstract public class WritablePixelFormat extends javafx.scene.image.PixelFormat +{ + protected WritablePixelFormat() {} + public abstract void setArgb(T p0, int p1, int p2, int p3, int p4); + public boolean isWritable(){ return false; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/Clipboard.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/Clipboard.java new file mode 100644 index 00000000000..f6919f62bcd --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/Clipboard.java @@ -0,0 +1,33 @@ +// Generated automatically from javafx.scene.input.Clipboard for testing purposes + +package javafx.scene.input; + +import java.io.File; +import java.util.List; +import java.util.Map; +import java.util.Set; +import javafx.scene.image.Image; +import javafx.scene.input.DataFormat; + +public class Clipboard +{ + protected Clipboard() {} + public final Image getImage(){ return null; } + public final List getFiles(){ return null; } + public final Object getContent(DataFormat p0){ return null; } + public final Set getContentTypes(){ return null; } + public final String getHtml(){ return null; } + public final String getRtf(){ return null; } + public final String getString(){ return null; } + public final String getUrl(){ return null; } + public final boolean hasContent(DataFormat p0){ return false; } + public final boolean hasFiles(){ return false; } + public final boolean hasHtml(){ return false; } + public final boolean hasImage(){ return false; } + public final boolean hasRtf(){ return false; } + public final boolean hasString(){ return false; } + public final boolean hasUrl(){ return false; } + public final boolean setContent(Map p0){ return false; } + public final void clear(){} + public static Clipboard getSystemClipboard(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/ContextMenuEvent.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/ContextMenuEvent.java new file mode 100644 index 00000000000..c702b64e0e9 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/ContextMenuEvent.java @@ -0,0 +1,30 @@ +// Generated automatically from javafx.scene.input.ContextMenuEvent for testing purposes + +package javafx.scene.input; + +import javafx.event.Event; +import javafx.event.EventTarget; +import javafx.event.EventType; +import javafx.scene.input.InputEvent; +import javafx.scene.input.PickResult; + +public class ContextMenuEvent extends InputEvent +{ + protected ContextMenuEvent() {} + public ContextMenuEvent copyFor(Object p0, EventTarget p1){ return null; } + public ContextMenuEvent(EventType p0, double p1, double p2, double p3, double p4, boolean p5, PickResult p6){} + public ContextMenuEvent(Object p0, EventTarget p1, EventType p2, double p3, double p4, double p5, double p6, boolean p7, PickResult p8){} + public EventType getEventType(){ return null; } + public String toString(){ return null; } + public boolean isKeyboardTrigger(){ return false; } + public final PickResult getPickResult(){ return null; } + public final double getSceneX(){ return 0; } + public final double getSceneY(){ return 0; } + public final double getScreenX(){ return 0; } + public final double getScreenY(){ return 0; } + public final double getX(){ return 0; } + public final double getY(){ return 0; } + public final double getZ(){ return 0; } + public static EventType ANY = null; + public static EventType CONTEXT_MENU_REQUESTED = null; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/DataFormat.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/DataFormat.java new file mode 100644 index 00000000000..ed69da87620 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/DataFormat.java @@ -0,0 +1,22 @@ +// Generated automatically from javafx.scene.input.DataFormat for testing purposes + +package javafx.scene.input; + +import java.util.Set; + +public class DataFormat +{ + protected DataFormat() {} + public DataFormat(String... p0){} + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public final Set getIdentifiers(){ return null; } + public int hashCode(){ return 0; } + public static DataFormat FILES = null; + public static DataFormat HTML = null; + public static DataFormat IMAGE = null; + public static DataFormat PLAIN_TEXT = null; + public static DataFormat RTF = null; + public static DataFormat URL = null; + public static DataFormat lookupMimeType(String p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/DragEvent.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/DragEvent.java new file mode 100644 index 00000000000..12cbdd2a777 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/DragEvent.java @@ -0,0 +1,48 @@ +// Generated automatically from javafx.scene.input.DragEvent for testing purposes + +package javafx.scene.input; + +import javafx.event.Event; +import javafx.event.EventTarget; +import javafx.event.EventType; +import javafx.scene.input.Dragboard; +import javafx.scene.input.InputEvent; +import javafx.scene.input.PickResult; +import javafx.scene.input.TransferMode; + +public class DragEvent extends InputEvent +{ + protected DragEvent() {} + public DragEvent copyFor(Object p0, EventTarget p1){ return null; } + public DragEvent copyFor(Object p0, EventTarget p1, EventType p2){ return null; } + public DragEvent copyFor(Object p0, EventTarget p1, Object p2, Object p3, EventType p4){ return null; } + public DragEvent(EventType p0, Dragboard p1, double p2, double p3, double p4, double p5, TransferMode p6, Object p7, Object p8, PickResult p9){} + public DragEvent(Object p0, EventTarget p1, EventType p2, Dragboard p3, double p4, double p5, double p6, double p7, TransferMode p8, Object p9, Object p10, PickResult p11){} + public EventType getEventType(){ return null; } + public boolean isDropCompleted(){ return false; } + public final Dragboard getDragboard(){ return null; } + public final Object getAcceptingObject(){ return null; } + public final Object getGestureSource(){ return null; } + public final Object getGestureTarget(){ return null; } + public final PickResult getPickResult(){ return null; } + public final TransferMode getAcceptedTransferMode(){ return null; } + public final TransferMode getTransferMode(){ return null; } + public final boolean isAccepted(){ return false; } + public final double getSceneX(){ return 0; } + public final double getSceneY(){ return 0; } + public final double getScreenX(){ return 0; } + public final double getScreenY(){ return 0; } + public final double getX(){ return 0; } + public final double getY(){ return 0; } + public final double getZ(){ return 0; } + public static EventType ANY = null; + public static EventType DRAG_DONE = null; + public static EventType DRAG_DROPPED = null; + public static EventType DRAG_ENTERED = null; + public static EventType DRAG_ENTERED_TARGET = null; + public static EventType DRAG_EXITED = null; + public static EventType DRAG_EXITED_TARGET = null; + public static EventType DRAG_OVER = null; + public void acceptTransferModes(TransferMode... p0){} + public void setDropCompleted(boolean p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/Dragboard.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/Dragboard.java new file mode 100644 index 00000000000..0ed168a2c56 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/Dragboard.java @@ -0,0 +1,21 @@ +// Generated automatically from javafx.scene.input.Dragboard for testing purposes + +package javafx.scene.input; + +import java.util.Set; +import javafx.scene.image.Image; +import javafx.scene.input.Clipboard; +import javafx.scene.input.TransferMode; + +public class Dragboard extends Clipboard +{ + protected Dragboard() {} + public Image getDragView(){ return null; } + public double getDragViewOffsetX(){ return 0; } + public double getDragViewOffsetY(){ return 0; } + public final Set getTransferModes(){ return null; } + public void setDragView(Image p0){} + public void setDragView(Image p0, double p1, double p2){} + public void setDragViewOffsetX(double p0){} + public void setDragViewOffsetY(double p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/GestureEvent.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/GestureEvent.java new file mode 100644 index 00000000000..dd89f9f8910 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/GestureEvent.java @@ -0,0 +1,37 @@ +// Generated automatically from javafx.scene.input.GestureEvent for testing purposes + +package javafx.scene.input; + +import javafx.event.Event; +import javafx.event.EventTarget; +import javafx.event.EventType; +import javafx.scene.input.InputEvent; +import javafx.scene.input.PickResult; + +public class GestureEvent extends InputEvent +{ + protected GestureEvent() {} + protected GestureEvent(EventType p0){} + protected GestureEvent(EventType p0, double p1, double p2, double p3, double p4, boolean p5, boolean p6, boolean p7, boolean p8, boolean p9, boolean p10, PickResult p11){} + protected GestureEvent(Object p0, EventTarget p1, EventType p2){} + protected GestureEvent(Object p0, EventTarget p1, EventType p2, double p3, double p4, double p5, double p6, boolean p7, boolean p8, boolean p9, boolean p10, boolean p11, boolean p12, PickResult p13){} + public EventType getEventType(){ return null; } + public GestureEvent copyFor(Object p0, EventTarget p1){ return null; } + public String toString(){ return null; } + public boolean isInertia(){ return false; } + public final PickResult getPickResult(){ return null; } + public final boolean isAltDown(){ return false; } + public final boolean isControlDown(){ return false; } + public final boolean isDirect(){ return false; } + public final boolean isMetaDown(){ return false; } + public final boolean isShiftDown(){ return false; } + public final boolean isShortcutDown(){ return false; } + public final double getSceneX(){ return 0; } + public final double getSceneY(){ return 0; } + public final double getScreenX(){ return 0; } + public final double getScreenY(){ return 0; } + public final double getX(){ return 0; } + public final double getY(){ return 0; } + public final double getZ(){ return 0; } + public static EventType ANY = null; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/InputEvent.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/InputEvent.java new file mode 100644 index 00000000000..6fe35500c56 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/InputEvent.java @@ -0,0 +1,16 @@ +// Generated automatically from javafx.scene.input.InputEvent for testing purposes + +package javafx.scene.input; + +import javafx.event.Event; +import javafx.event.EventTarget; +import javafx.event.EventType; + +public class InputEvent extends Event +{ + protected InputEvent() {} + public EventType getEventType(){ return null; } + public InputEvent(EventType p0){} + public InputEvent(Object p0, EventTarget p1, EventType p2){} + public static EventType ANY = null; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/InputMethodEvent.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/InputMethodEvent.java new file mode 100644 index 00000000000..4df57f1f09f --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/InputMethodEvent.java @@ -0,0 +1,26 @@ +// Generated automatically from javafx.scene.input.InputMethodEvent for testing purposes + +package javafx.scene.input; + +import java.util.List; +import javafx.collections.ObservableList; +import javafx.event.Event; +import javafx.event.EventTarget; +import javafx.event.EventType; +import javafx.scene.input.InputEvent; +import javafx.scene.input.InputMethodTextRun; + +public class InputMethodEvent extends InputEvent +{ + protected InputMethodEvent() {} + public EventType getEventType(){ return null; } + public InputMethodEvent copyFor(Object p0, EventTarget p1){ return null; } + public InputMethodEvent(EventType p0, List p1, String p2, int p3){} + public InputMethodEvent(Object p0, EventTarget p1, EventType p2, List p3, String p4, int p5){} + public String toString(){ return null; } + public final ObservableList getComposed(){ return null; } + public final String getCommitted(){ return null; } + public final int getCaretPosition(){ return 0; } + public static EventType ANY = null; + public static EventType INPUT_METHOD_TEXT_CHANGED = null; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/InputMethodHighlight.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/InputMethodHighlight.java new file mode 100644 index 00000000000..18ef7f1e178 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/InputMethodHighlight.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.scene.input.InputMethodHighlight for testing purposes + +package javafx.scene.input; + + +public enum InputMethodHighlight +{ + SELECTED_CONVERTED, SELECTED_RAW, UNSELECTED_CONVERTED, UNSELECTED_RAW; + private InputMethodHighlight() {} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/InputMethodRequests.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/InputMethodRequests.java new file mode 100644 index 00000000000..63cc3e0b393 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/InputMethodRequests.java @@ -0,0 +1,13 @@ +// Generated automatically from javafx.scene.input.InputMethodRequests for testing purposes + +package javafx.scene.input; + +import javafx.geometry.Point2D; + +public interface InputMethodRequests +{ + Point2D getTextLocation(int p0); + String getSelectedText(); + int getLocationOffset(int p0, int p1); + void cancelLatestCommittedText(); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/InputMethodTextRun.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/InputMethodTextRun.java new file mode 100644 index 00000000000..8ee0aaa95ae --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/InputMethodTextRun.java @@ -0,0 +1,15 @@ +// Generated automatically from javafx.scene.input.InputMethodTextRun for testing purposes + +package javafx.scene.input; + +import java.io.Serializable; +import javafx.scene.input.InputMethodHighlight; + +public class InputMethodTextRun implements Serializable +{ + protected InputMethodTextRun() {} + public InputMethodTextRun(String p0, InputMethodHighlight p1){} + public String toString(){ return null; } + public final InputMethodHighlight getHighlight(){ return null; } + public final String getText(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/KeyCode.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/KeyCode.java new file mode 100644 index 00000000000..beef42511d9 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/KeyCode.java @@ -0,0 +1,23 @@ +// Generated automatically from javafx.scene.input.KeyCode for testing purposes + +package javafx.scene.input; + + +public enum KeyCode +{ + A, ACCEPT, ADD, AGAIN, ALL_CANDIDATES, ALPHANUMERIC, ALT, ALT_GRAPH, AMPERSAND, ASTERISK, AT, B, BACK_QUOTE, BACK_SLASH, BACK_SPACE, BEGIN, BRACELEFT, BRACERIGHT, C, CANCEL, CAPS, CHANNEL_DOWN, CHANNEL_UP, CIRCUMFLEX, CLEAR, CLOSE_BRACKET, CODE_INPUT, COLON, COLORED_KEY_0, COLORED_KEY_1, COLORED_KEY_2, COLORED_KEY_3, COMMA, COMMAND, COMPOSE, CONTEXT_MENU, CONTROL, CONVERT, COPY, CUT, D, DEAD_ABOVEDOT, DEAD_ABOVERING, DEAD_ACUTE, DEAD_BREVE, DEAD_CARON, DEAD_CEDILLA, DEAD_CIRCUMFLEX, DEAD_DIAERESIS, DEAD_DOUBLEACUTE, DEAD_GRAVE, DEAD_IOTA, DEAD_MACRON, DEAD_OGONEK, DEAD_SEMIVOICED_SOUND, DEAD_TILDE, DEAD_VOICED_SOUND, DECIMAL, DELETE, DIGIT0, DIGIT1, DIGIT2, DIGIT3, DIGIT4, DIGIT5, DIGIT6, DIGIT7, DIGIT8, DIGIT9, DIVIDE, DOLLAR, DOWN, E, EJECT_TOGGLE, END, ENTER, EQUALS, ESCAPE, EURO_SIGN, EXCLAMATION_MARK, F, F1, F10, F11, F12, F13, F14, F15, F16, F17, F18, F19, F2, F20, F21, F22, F23, F24, F3, F4, F5, F6, F7, F8, F9, FAST_FWD, FINAL, FIND, FULL_WIDTH, G, GAME_A, GAME_B, GAME_C, GAME_D, GREATER, H, HALF_WIDTH, HELP, HIRAGANA, HOME, I, INFO, INPUT_METHOD_ON_OFF, INSERT, INVERTED_EXCLAMATION_MARK, J, JAPANESE_HIRAGANA, JAPANESE_KATAKANA, JAPANESE_ROMAN, K, KANA, KANA_LOCK, KANJI, KATAKANA, KP_DOWN, KP_LEFT, KP_RIGHT, KP_UP, L, LEFT, LEFT_PARENTHESIS, LESS, M, META, MINUS, MODECHANGE, MULTIPLY, MUTE, N, NONCONVERT, NUMBER_SIGN, NUMPAD0, NUMPAD1, NUMPAD2, NUMPAD3, NUMPAD4, NUMPAD5, NUMPAD6, NUMPAD7, NUMPAD8, NUMPAD9, NUM_LOCK, O, OPEN_BRACKET, P, PAGE_DOWN, PAGE_UP, PASTE, PAUSE, PERIOD, PLAY, PLUS, POUND, POWER, PREVIOUS_CANDIDATE, PRINTSCREEN, PROPS, Q, QUOTE, QUOTEDBL, R, RECORD, REWIND, RIGHT, RIGHT_PARENTHESIS, ROMAN_CHARACTERS, S, SCROLL_LOCK, SEMICOLON, SEPARATOR, SHIFT, SHORTCUT, SLASH, SOFTKEY_0, SOFTKEY_1, SOFTKEY_2, SOFTKEY_3, SOFTKEY_4, SOFTKEY_5, SOFTKEY_6, SOFTKEY_7, SOFTKEY_8, SOFTKEY_9, SPACE, STAR, STOP, SUBTRACT, T, TAB, TRACK_NEXT, TRACK_PREV, U, UNDEFINED, UNDERSCORE, UNDO, UP, V, VOLUME_DOWN, VOLUME_UP, W, WINDOWS, X, Y, Z; + private KeyCode() {} + public final String getChar(){ return null; } + public final String getName(){ return null; } + public final boolean isArrowKey(){ return false; } + public final boolean isDigitKey(){ return false; } + public final boolean isFunctionKey(){ return false; } + public final boolean isKeypadKey(){ return false; } + public final boolean isLetterKey(){ return false; } + public final boolean isMediaKey(){ return false; } + public final boolean isModifierKey(){ return false; } + public final boolean isNavigationKey(){ return false; } + public final boolean isWhitespaceKey(){ return false; } + public final int getCode(){ return 0; } + public static KeyCode getKeyCode(String p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/KeyCombination.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/KeyCombination.java new file mode 100644 index 00000000000..15557be4a2c --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/KeyCombination.java @@ -0,0 +1,49 @@ +// Generated automatically from javafx.scene.input.KeyCombination for testing purposes + +package javafx.scene.input; + +import javafx.scene.input.KeyCode; +import javafx.scene.input.KeyEvent; + +abstract public class KeyCombination +{ + protected KeyCombination() {} + protected KeyCombination(KeyCombination.Modifier... p0){} + protected KeyCombination(KeyCombination.ModifierValue p0, KeyCombination.ModifierValue p1, KeyCombination.ModifierValue p2, KeyCombination.ModifierValue p3, KeyCombination.ModifierValue p4){} + public String getDisplayText(){ return null; } + public String getName(){ return null; } + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public boolean match(KeyEvent p0){ return false; } + public final KeyCombination.ModifierValue getAlt(){ return null; } + public final KeyCombination.ModifierValue getControl(){ return null; } + public final KeyCombination.ModifierValue getMeta(){ return null; } + public final KeyCombination.ModifierValue getShift(){ return null; } + public final KeyCombination.ModifierValue getShortcut(){ return null; } + public int hashCode(){ return 0; } + public static KeyCombination NO_MATCH = null; + public static KeyCombination keyCombination(String p0){ return null; } + public static KeyCombination valueOf(String p0){ return null; } + public static KeyCombination.Modifier ALT_ANY = null; + public static KeyCombination.Modifier ALT_DOWN = null; + public static KeyCombination.Modifier CONTROL_ANY = null; + public static KeyCombination.Modifier CONTROL_DOWN = null; + public static KeyCombination.Modifier META_ANY = null; + public static KeyCombination.Modifier META_DOWN = null; + public static KeyCombination.Modifier SHIFT_ANY = null; + public static KeyCombination.Modifier SHIFT_DOWN = null; + public static KeyCombination.Modifier SHORTCUT_ANY = null; + public static KeyCombination.Modifier SHORTCUT_DOWN = null; + static public class Modifier + { + protected Modifier() {} + public KeyCode getKey(){ return null; } + public KeyCombination.ModifierValue getValue(){ return null; } + public String toString(){ return null; } + } + static public enum ModifierValue + { + ANY, DOWN, UP; + private ModifierValue() {} + } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/KeyEvent.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/KeyEvent.java new file mode 100644 index 00000000000..eee4eea3d02 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/KeyEvent.java @@ -0,0 +1,33 @@ +// Generated automatically from javafx.scene.input.KeyEvent for testing purposes + +package javafx.scene.input; + +import javafx.event.Event; +import javafx.event.EventTarget; +import javafx.event.EventType; +import javafx.scene.input.InputEvent; +import javafx.scene.input.KeyCode; + +public class KeyEvent extends InputEvent +{ + protected KeyEvent() {} + public EventType getEventType(){ return null; } + public KeyEvent copyFor(Object p0, EventTarget p1){ return null; } + public KeyEvent copyFor(Object p0, EventTarget p1, EventType p2){ return null; } + public KeyEvent(EventType p0, String p1, String p2, KeyCode p3, boolean p4, boolean p5, boolean p6, boolean p7){} + public KeyEvent(Object p0, EventTarget p1, EventType p2, String p3, String p4, KeyCode p5, boolean p6, boolean p7, boolean p8, boolean p9){} + public String toString(){ return null; } + public final KeyCode getCode(){ return null; } + public final String getCharacter(){ return null; } + public final String getText(){ return null; } + public final boolean isAltDown(){ return false; } + public final boolean isControlDown(){ return false; } + public final boolean isMetaDown(){ return false; } + public final boolean isShiftDown(){ return false; } + public final boolean isShortcutDown(){ return false; } + public static EventType ANY = null; + public static EventType KEY_PRESSED = null; + public static EventType KEY_RELEASED = null; + public static EventType KEY_TYPED = null; + public static String CHAR_UNDEFINED = null; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/Mnemonic.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/Mnemonic.java new file mode 100644 index 00000000000..78a4a43f0d8 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/Mnemonic.java @@ -0,0 +1,17 @@ +// Generated automatically from javafx.scene.input.Mnemonic for testing purposes + +package javafx.scene.input; + +import javafx.scene.Node; +import javafx.scene.input.KeyCombination; + +public class Mnemonic +{ + protected Mnemonic() {} + public KeyCombination getKeyCombination(){ return null; } + public Mnemonic(Node p0, KeyCombination p1){} + public Node getNode(){ return null; } + public void fire(){} + public void setKeyCombination(KeyCombination p0){} + public void setNode(Node p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/MouseButton.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/MouseButton.java new file mode 100644 index 00000000000..ee534db97cc --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/MouseButton.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.scene.input.MouseButton for testing purposes + +package javafx.scene.input; + + +public enum MouseButton +{ + BACK, FORWARD, MIDDLE, NONE, PRIMARY, SECONDARY; + private MouseButton() {} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/MouseDragEvent.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/MouseDragEvent.java new file mode 100644 index 00000000000..aec5cc71277 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/MouseDragEvent.java @@ -0,0 +1,30 @@ +// Generated automatically from javafx.scene.input.MouseDragEvent for testing purposes + +package javafx.scene.input; + +import javafx.event.Event; +import javafx.event.EventTarget; +import javafx.event.EventType; +import javafx.scene.input.MouseButton; +import javafx.scene.input.MouseEvent; +import javafx.scene.input.PickResult; + +public class MouseDragEvent extends MouseEvent +{ + protected MouseDragEvent() {} + public EventType getEventType(){ return null; } + public MouseDragEvent copyFor(Object p0, EventTarget p1){ return null; } + public MouseDragEvent copyFor(Object p0, EventTarget p1, EventType p2){ return null; } + public MouseDragEvent(EventType p0, double p1, double p2, double p3, double p4, MouseButton p5, int p6, boolean p7, boolean p8, boolean p9, boolean p10, boolean p11, boolean p12, boolean p13, boolean p14, boolean p15, PickResult p16, Object p17){} + public MouseDragEvent(Object p0, EventTarget p1, EventType p2, double p3, double p4, double p5, double p6, MouseButton p7, int p8, boolean p9, boolean p10, boolean p11, boolean p12, boolean p13, boolean p14, boolean p15, boolean p16, boolean p17, PickResult p18, Object p19){} + public MouseDragEvent(Object p0, EventTarget p1, EventType p2, double p3, double p4, double p5, double p6, MouseButton p7, int p8, boolean p9, boolean p10, boolean p11, boolean p12, boolean p13, boolean p14, boolean p15, boolean p16, boolean p17, boolean p18, boolean p19, PickResult p20, Object p21){} + public Object getGestureSource(){ return null; } + public String toString(){ return null; } + public static EventType ANY = null; + public static EventType MOUSE_DRAG_ENTERED = null; + public static EventType MOUSE_DRAG_ENTERED_TARGET = null; + public static EventType MOUSE_DRAG_EXITED = null; + public static EventType MOUSE_DRAG_EXITED_TARGET = null; + public static EventType MOUSE_DRAG_OVER = null; + public static EventType MOUSE_DRAG_RELEASED = null; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/MouseEvent.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/MouseEvent.java new file mode 100644 index 00000000000..2aa1552d9b5 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/MouseEvent.java @@ -0,0 +1,61 @@ +// Generated automatically from javafx.scene.input.MouseEvent for testing purposes + +package javafx.scene.input; + +import javafx.event.Event; +import javafx.event.EventTarget; +import javafx.event.EventType; +import javafx.scene.input.InputEvent; +import javafx.scene.input.MouseButton; +import javafx.scene.input.MouseDragEvent; +import javafx.scene.input.PickResult; + +public class MouseEvent extends InputEvent +{ + protected MouseEvent() {} + public EventType getEventType(){ return null; } + public MouseEvent copyFor(Object p0, EventTarget p1){ return null; } + public MouseEvent copyFor(Object p0, EventTarget p1, EventType p2){ return null; } + public MouseEvent(EventType p0, double p1, double p2, double p3, double p4, MouseButton p5, int p6, boolean p7, boolean p8, boolean p9, boolean p10, boolean p11, boolean p12, boolean p13, boolean p14, boolean p15, boolean p16, PickResult p17){} + public MouseEvent(EventType p0, double p1, double p2, double p3, double p4, MouseButton p5, int p6, boolean p7, boolean p8, boolean p9, boolean p10, boolean p11, boolean p12, boolean p13, boolean p14, boolean p15, boolean p16, boolean p17, boolean p18, PickResult p19){} + public MouseEvent(Object p0, EventTarget p1, EventType p2, double p3, double p4, double p5, double p6, MouseButton p7, int p8, boolean p9, boolean p10, boolean p11, boolean p12, boolean p13, boolean p14, boolean p15, boolean p16, boolean p17, boolean p18, PickResult p19){} + public MouseEvent(Object p0, EventTarget p1, EventType p2, double p3, double p4, double p5, double p6, MouseButton p7, int p8, boolean p9, boolean p10, boolean p11, boolean p12, boolean p13, boolean p14, boolean p15, boolean p16, boolean p17, boolean p18, boolean p19, boolean p20, PickResult p21){} + public String toString(){ return null; } + public boolean isDragDetect(){ return false; } + public boolean isSynthesized(){ return false; } + public final MouseButton getButton(){ return null; } + public final PickResult getPickResult(){ return null; } + public final boolean isAltDown(){ return false; } + public final boolean isBackButtonDown(){ return false; } + public final boolean isControlDown(){ return false; } + public final boolean isForwardButtonDown(){ return false; } + public final boolean isMetaDown(){ return false; } + public final boolean isMiddleButtonDown(){ return false; } + public final boolean isPopupTrigger(){ return false; } + public final boolean isPrimaryButtonDown(){ return false; } + public final boolean isSecondaryButtonDown(){ return false; } + public final boolean isShiftDown(){ return false; } + public final boolean isShortcutDown(){ return false; } + public final boolean isStillSincePress(){ return false; } + public final double getSceneX(){ return 0; } + public final double getSceneY(){ return 0; } + public final double getScreenX(){ return 0; } + public final double getScreenY(){ return 0; } + public final double getX(){ return 0; } + public final double getY(){ return 0; } + public final double getZ(){ return 0; } + public final int getClickCount(){ return 0; } + public static EventType ANY = null; + public static EventType DRAG_DETECTED = null; + public static EventType MOUSE_CLICKED = null; + public static EventType MOUSE_DRAGGED = null; + public static EventType MOUSE_ENTERED = null; + public static EventType MOUSE_ENTERED_TARGET = null; + public static EventType MOUSE_EXITED = null; + public static EventType MOUSE_EXITED_TARGET = null; + public static EventType MOUSE_MOVED = null; + public static EventType MOUSE_PRESSED = null; + public static EventType MOUSE_RELEASED = null; + public static MouseDragEvent copyForMouseDragEvent(MouseEvent p0, Object p1, EventTarget p2, EventType p3, Object p4, PickResult p5){ return null; } + public void setDragDetect(boolean p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/PickResult.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/PickResult.java new file mode 100644 index 00000000000..90aeabfa936 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/PickResult.java @@ -0,0 +1,25 @@ +// Generated automatically from javafx.scene.input.PickResult for testing purposes + +package javafx.scene.input; + +import javafx.event.EventTarget; +import javafx.geometry.Point2D; +import javafx.geometry.Point3D; +import javafx.scene.Node; + +public class PickResult +{ + protected PickResult() {} + public PickResult(EventTarget p0, double p1, double p2){} + public PickResult(Node p0, Point3D p1, double p2){} + public PickResult(Node p0, Point3D p1, double p2, int p3, Point2D p4){} + public PickResult(Node p0, Point3D p1, double p2, int p3, Point3D p4, Point2D p5){} + public String toString(){ return null; } + public final Node getIntersectedNode(){ return null; } + public final Point2D getIntersectedTexCoord(){ return null; } + public final Point3D getIntersectedNormal(){ return null; } + public final Point3D getIntersectedPoint(){ return null; } + public final double getIntersectedDistance(){ return 0; } + public final int getIntersectedFace(){ return 0; } + public static int FACE_UNDEFINED = 0; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/RotateEvent.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/RotateEvent.java new file mode 100644 index 00000000000..501d004b5ff --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/RotateEvent.java @@ -0,0 +1,26 @@ +// Generated automatically from javafx.scene.input.RotateEvent for testing purposes + +package javafx.scene.input; + +import javafx.event.Event; +import javafx.event.EventTarget; +import javafx.event.EventType; +import javafx.scene.input.GestureEvent; +import javafx.scene.input.PickResult; + +public class RotateEvent extends GestureEvent +{ + protected RotateEvent() {} + public EventType getEventType(){ return null; } + public RotateEvent copyFor(Object p0, EventTarget p1){ return null; } + public RotateEvent copyFor(Object p0, EventTarget p1, EventType p2){ return null; } + public RotateEvent(EventType p0, double p1, double p2, double p3, double p4, boolean p5, boolean p6, boolean p7, boolean p8, boolean p9, boolean p10, double p11, double p12, PickResult p13){} + public RotateEvent(Object p0, EventTarget p1, EventType p2, double p3, double p4, double p5, double p6, boolean p7, boolean p8, boolean p9, boolean p10, boolean p11, boolean p12, double p13, double p14, PickResult p15){} + public String toString(){ return null; } + public double getAngle(){ return 0; } + public double getTotalAngle(){ return 0; } + public static EventType ANY = null; + public static EventType ROTATE = null; + public static EventType ROTATION_FINISHED = null; + public static EventType ROTATION_STARTED = null; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/ScrollEvent.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/ScrollEvent.java new file mode 100644 index 00000000000..de34b90cbe8 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/ScrollEvent.java @@ -0,0 +1,46 @@ +// Generated automatically from javafx.scene.input.ScrollEvent for testing purposes + +package javafx.scene.input; + +import javafx.event.Event; +import javafx.event.EventTarget; +import javafx.event.EventType; +import javafx.scene.input.GestureEvent; +import javafx.scene.input.PickResult; + +public class ScrollEvent extends GestureEvent +{ + protected ScrollEvent() {} + public EventType getEventType(){ return null; } + public ScrollEvent copyFor(Object p0, EventTarget p1){ return null; } + public ScrollEvent copyFor(Object p0, EventTarget p1, EventType p2){ return null; } + public ScrollEvent(EventType p0, double p1, double p2, double p3, double p4, boolean p5, boolean p6, boolean p7, boolean p8, boolean p9, boolean p10, double p11, double p12, double p13, double p14, ScrollEvent.HorizontalTextScrollUnits p15, double p16, ScrollEvent.VerticalTextScrollUnits p17, double p18, int p19, PickResult p20){} + public ScrollEvent(EventType p0, double p1, double p2, double p3, double p4, boolean p5, boolean p6, boolean p7, boolean p8, boolean p9, boolean p10, double p11, double p12, double p13, double p14, double p15, double p16, ScrollEvent.HorizontalTextScrollUnits p17, double p18, ScrollEvent.VerticalTextScrollUnits p19, double p20, int p21, PickResult p22){} + public ScrollEvent(Object p0, EventTarget p1, EventType p2, double p3, double p4, double p5, double p6, boolean p7, boolean p8, boolean p9, boolean p10, boolean p11, boolean p12, double p13, double p14, double p15, double p16, ScrollEvent.HorizontalTextScrollUnits p17, double p18, ScrollEvent.VerticalTextScrollUnits p19, double p20, int p21, PickResult p22){} + public ScrollEvent.HorizontalTextScrollUnits getTextDeltaXUnits(){ return null; } + public ScrollEvent.VerticalTextScrollUnits getTextDeltaYUnits(){ return null; } + public String toString(){ return null; } + public double getDeltaX(){ return 0; } + public double getDeltaY(){ return 0; } + public double getMultiplierX(){ return 0; } + public double getMultiplierY(){ return 0; } + public double getTextDeltaX(){ return 0; } + public double getTextDeltaY(){ return 0; } + public double getTotalDeltaX(){ return 0; } + public double getTotalDeltaY(){ return 0; } + public int getTouchCount(){ return 0; } + public static EventType ANY = null; + public static EventType SCROLL = null; + public static EventType SCROLL_FINISHED = null; + public static EventType SCROLL_STARTED = null; + static public enum HorizontalTextScrollUnits + { + CHARACTERS, NONE; + private HorizontalTextScrollUnits() {} + } + static public enum VerticalTextScrollUnits + { + LINES, NONE, PAGES; + private VerticalTextScrollUnits() {} + } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/SwipeEvent.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/SwipeEvent.java new file mode 100644 index 00000000000..7e2545f2897 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/SwipeEvent.java @@ -0,0 +1,26 @@ +// Generated automatically from javafx.scene.input.SwipeEvent for testing purposes + +package javafx.scene.input; + +import javafx.event.Event; +import javafx.event.EventTarget; +import javafx.event.EventType; +import javafx.scene.input.GestureEvent; +import javafx.scene.input.PickResult; + +public class SwipeEvent extends GestureEvent +{ + protected SwipeEvent() {} + public EventType getEventType(){ return null; } + public String toString(){ return null; } + public SwipeEvent copyFor(Object p0, EventTarget p1){ return null; } + public SwipeEvent copyFor(Object p0, EventTarget p1, EventType p2){ return null; } + public SwipeEvent(EventType p0, double p1, double p2, double p3, double p4, boolean p5, boolean p6, boolean p7, boolean p8, boolean p9, int p10, PickResult p11){} + public SwipeEvent(Object p0, EventTarget p1, EventType p2, double p3, double p4, double p5, double p6, boolean p7, boolean p8, boolean p9, boolean p10, boolean p11, int p12, PickResult p13){} + public int getTouchCount(){ return 0; } + public static EventType ANY = null; + public static EventType SWIPE_DOWN = null; + public static EventType SWIPE_LEFT = null; + public static EventType SWIPE_RIGHT = null; + public static EventType SWIPE_UP = null; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/TouchEvent.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/TouchEvent.java new file mode 100644 index 00000000000..20fc62821d1 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/TouchEvent.java @@ -0,0 +1,34 @@ +// Generated automatically from javafx.scene.input.TouchEvent for testing purposes + +package javafx.scene.input; + +import java.util.List; +import javafx.event.Event; +import javafx.event.EventTarget; +import javafx.event.EventType; +import javafx.scene.input.InputEvent; +import javafx.scene.input.TouchPoint; + +public class TouchEvent extends InputEvent +{ + protected TouchEvent() {} + public EventType getEventType(){ return null; } + public List getTouchPoints(){ return null; } + public String toString(){ return null; } + public TouchEvent copyFor(Object p0, EventTarget p1){ return null; } + public TouchEvent copyFor(Object p0, EventTarget p1, EventType p2){ return null; } + public TouchEvent(EventType p0, TouchPoint p1, List p2, int p3, boolean p4, boolean p5, boolean p6, boolean p7){} + public TouchEvent(Object p0, EventTarget p1, EventType p2, TouchPoint p3, List p4, int p5, boolean p6, boolean p7, boolean p8, boolean p9){} + public TouchPoint getTouchPoint(){ return null; } + public final boolean isAltDown(){ return false; } + public final boolean isControlDown(){ return false; } + public final boolean isMetaDown(){ return false; } + public final boolean isShiftDown(){ return false; } + public final int getEventSetId(){ return 0; } + public int getTouchCount(){ return 0; } + public static EventType ANY = null; + public static EventType TOUCH_MOVED = null; + public static EventType TOUCH_PRESSED = null; + public static EventType TOUCH_RELEASED = null; + public static EventType TOUCH_STATIONARY = null; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/TouchPoint.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/TouchPoint.java new file mode 100644 index 00000000000..08a21c1e6d4 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/TouchPoint.java @@ -0,0 +1,35 @@ +// Generated automatically from javafx.scene.input.TouchPoint for testing purposes + +package javafx.scene.input; + +import java.io.Serializable; +import javafx.event.EventTarget; +import javafx.scene.input.PickResult; + +public class TouchPoint implements Serializable +{ + protected TouchPoint() {} + public EventTarget getGrabbed(){ return null; } + public EventTarget getTarget(){ return null; } + public String toString(){ return null; } + public TouchPoint(int p0, TouchPoint.State p1, double p2, double p3, double p4, double p5, EventTarget p6, PickResult p7){} + public boolean belongsTo(EventTarget p0){ return false; } + public final PickResult getPickResult(){ return null; } + public final TouchPoint.State getState(){ return null; } + public final double getSceneX(){ return 0; } + public final double getSceneY(){ return 0; } + public final double getScreenX(){ return 0; } + public final double getScreenY(){ return 0; } + public final double getX(){ return 0; } + public final double getY(){ return 0; } + public final double getZ(){ return 0; } + public final int getId(){ return 0; } + public void grab(){} + public void grab(EventTarget p0){} + public void ungrab(){} + static public enum State + { + MOVED, PRESSED, RELEASED, STATIONARY; + private State() {} + } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/TransferMode.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/TransferMode.java new file mode 100644 index 00000000000..9c2075cd936 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/TransferMode.java @@ -0,0 +1,13 @@ +// Generated automatically from javafx.scene.input.TransferMode for testing purposes + +package javafx.scene.input; + + +public enum TransferMode +{ + COPY, LINK, MOVE; + private TransferMode() {} + public static TransferMode[] ANY = null; + public static TransferMode[] COPY_OR_MOVE = null; + public static TransferMode[] NONE = null; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/input/ZoomEvent.java b/java/ql/test/stubs/javafx-web/javafx/scene/input/ZoomEvent.java new file mode 100644 index 00000000000..bd7fe470544 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/input/ZoomEvent.java @@ -0,0 +1,26 @@ +// Generated automatically from javafx.scene.input.ZoomEvent for testing purposes + +package javafx.scene.input; + +import javafx.event.Event; +import javafx.event.EventTarget; +import javafx.event.EventType; +import javafx.scene.input.GestureEvent; +import javafx.scene.input.PickResult; + +public class ZoomEvent extends GestureEvent +{ + protected ZoomEvent() {} + public EventType getEventType(){ return null; } + public String toString(){ return null; } + public ZoomEvent copyFor(Object p0, EventTarget p1){ return null; } + public ZoomEvent copyFor(Object p0, EventTarget p1, EventType p2){ return null; } + public ZoomEvent(EventType p0, double p1, double p2, double p3, double p4, boolean p5, boolean p6, boolean p7, boolean p8, boolean p9, boolean p10, double p11, double p12, PickResult p13){} + public ZoomEvent(Object p0, EventTarget p1, EventType p2, double p3, double p4, double p5, double p6, boolean p7, boolean p8, boolean p9, boolean p10, boolean p11, boolean p12, double p13, double p14, PickResult p15){} + public double getTotalZoomFactor(){ return 0; } + public double getZoomFactor(){ return 0; } + public static EventType ANY = null; + public static EventType ZOOM = null; + public static EventType ZOOM_FINISHED = null; + public static EventType ZOOM_STARTED = null; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/paint/Color.java b/java/ql/test/stubs/javafx-web/javafx/scene/paint/Color.java new file mode 100644 index 00000000000..0c8193004bd --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/paint/Color.java @@ -0,0 +1,192 @@ +// Generated automatically from javafx.scene.paint.Color for testing purposes + +package javafx.scene.paint; + +import javafx.animation.Interpolatable; +import javafx.scene.paint.Paint; + +public class Color extends Paint implements Interpolatable +{ + protected Color() {} + public Color brighter(){ return null; } + public Color darker(){ return null; } + public Color deriveColor(double p0, double p1, double p2, double p3){ return null; } + public Color desaturate(){ return null; } + public Color grayscale(){ return null; } + public Color interpolate(Color p0, double p1){ return null; } + public Color invert(){ return null; } + public Color saturate(){ return null; } + public Color(double p0, double p1, double p2, double p3){} + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public double getBrightness(){ return 0; } + public double getHue(){ return 0; } + public double getSaturation(){ return 0; } + public final boolean isOpaque(){ return false; } + public final double getBlue(){ return 0; } + public final double getGreen(){ return 0; } + public final double getOpacity(){ return 0; } + public final double getRed(){ return 0; } + public int hashCode(){ return 0; } + public static Color ALICEBLUE = null; + public static Color ANTIQUEWHITE = null; + public static Color AQUA = null; + public static Color AQUAMARINE = null; + public static Color AZURE = null; + public static Color BEIGE = null; + public static Color BISQUE = null; + public static Color BLACK = null; + public static Color BLANCHEDALMOND = null; + public static Color BLUE = null; + public static Color BLUEVIOLET = null; + public static Color BROWN = null; + public static Color BURLYWOOD = null; + public static Color CADETBLUE = null; + public static Color CHARTREUSE = null; + public static Color CHOCOLATE = null; + public static Color CORAL = null; + public static Color CORNFLOWERBLUE = null; + public static Color CORNSILK = null; + public static Color CRIMSON = null; + public static Color CYAN = null; + public static Color DARKBLUE = null; + public static Color DARKCYAN = null; + public static Color DARKGOLDENROD = null; + public static Color DARKGRAY = null; + public static Color DARKGREEN = null; + public static Color DARKGREY = null; + public static Color DARKKHAKI = null; + public static Color DARKMAGENTA = null; + public static Color DARKOLIVEGREEN = null; + public static Color DARKORANGE = null; + public static Color DARKORCHID = null; + public static Color DARKRED = null; + public static Color DARKSALMON = null; + public static Color DARKSEAGREEN = null; + public static Color DARKSLATEBLUE = null; + public static Color DARKSLATEGRAY = null; + public static Color DARKSLATEGREY = null; + public static Color DARKTURQUOISE = null; + public static Color DARKVIOLET = null; + public static Color DEEPPINK = null; + public static Color DEEPSKYBLUE = null; + public static Color DIMGRAY = null; + public static Color DIMGREY = null; + public static Color DODGERBLUE = null; + public static Color FIREBRICK = null; + public static Color FLORALWHITE = null; + public static Color FORESTGREEN = null; + public static Color FUCHSIA = null; + public static Color GAINSBORO = null; + public static Color GHOSTWHITE = null; + public static Color GOLD = null; + public static Color GOLDENROD = null; + public static Color GRAY = null; + public static Color GREEN = null; + public static Color GREENYELLOW = null; + public static Color GREY = null; + public static Color HONEYDEW = null; + public static Color HOTPINK = null; + public static Color INDIANRED = null; + public static Color INDIGO = null; + public static Color IVORY = null; + public static Color KHAKI = null; + public static Color LAVENDER = null; + public static Color LAVENDERBLUSH = null; + public static Color LAWNGREEN = null; + public static Color LEMONCHIFFON = null; + public static Color LIGHTBLUE = null; + public static Color LIGHTCORAL = null; + public static Color LIGHTCYAN = null; + public static Color LIGHTGOLDENRODYELLOW = null; + public static Color LIGHTGRAY = null; + public static Color LIGHTGREEN = null; + public static Color LIGHTGREY = null; + public static Color LIGHTPINK = null; + public static Color LIGHTSALMON = null; + public static Color LIGHTSEAGREEN = null; + public static Color LIGHTSKYBLUE = null; + public static Color LIGHTSLATEGRAY = null; + public static Color LIGHTSLATEGREY = null; + public static Color LIGHTSTEELBLUE = null; + public static Color LIGHTYELLOW = null; + public static Color LIME = null; + public static Color LIMEGREEN = null; + public static Color LINEN = null; + public static Color MAGENTA = null; + public static Color MAROON = null; + public static Color MEDIUMAQUAMARINE = null; + public static Color MEDIUMBLUE = null; + public static Color MEDIUMORCHID = null; + public static Color MEDIUMPURPLE = null; + public static Color MEDIUMSEAGREEN = null; + public static Color MEDIUMSLATEBLUE = null; + public static Color MEDIUMSPRINGGREEN = null; + public static Color MEDIUMTURQUOISE = null; + public static Color MEDIUMVIOLETRED = null; + public static Color MIDNIGHTBLUE = null; + public static Color MINTCREAM = null; + public static Color MISTYROSE = null; + public static Color MOCCASIN = null; + public static Color NAVAJOWHITE = null; + public static Color NAVY = null; + public static Color OLDLACE = null; + public static Color OLIVE = null; + public static Color OLIVEDRAB = null; + public static Color ORANGE = null; + public static Color ORANGERED = null; + public static Color ORCHID = null; + public static Color PALEGOLDENROD = null; + public static Color PALEGREEN = null; + public static Color PALETURQUOISE = null; + public static Color PALEVIOLETRED = null; + public static Color PAPAYAWHIP = null; + public static Color PEACHPUFF = null; + public static Color PERU = null; + public static Color PINK = null; + public static Color PLUM = null; + public static Color POWDERBLUE = null; + public static Color PURPLE = null; + public static Color RED = null; + public static Color ROSYBROWN = null; + public static Color ROYALBLUE = null; + public static Color SADDLEBROWN = null; + public static Color SALMON = null; + public static Color SANDYBROWN = null; + public static Color SEAGREEN = null; + public static Color SEASHELL = null; + public static Color SIENNA = null; + public static Color SILVER = null; + public static Color SKYBLUE = null; + public static Color SLATEBLUE = null; + public static Color SLATEGRAY = null; + public static Color SLATEGREY = null; + public static Color SNOW = null; + public static Color SPRINGGREEN = null; + public static Color STEELBLUE = null; + public static Color TAN = null; + public static Color TEAL = null; + public static Color THISTLE = null; + public static Color TOMATO = null; + public static Color TRANSPARENT = null; + public static Color TURQUOISE = null; + public static Color VIOLET = null; + public static Color WHEAT = null; + public static Color WHITE = null; + public static Color WHITESMOKE = null; + public static Color YELLOW = null; + public static Color YELLOWGREEN = null; + public static Color color(double p0, double p1, double p2){ return null; } + public static Color color(double p0, double p1, double p2, double p3){ return null; } + public static Color gray(double p0){ return null; } + public static Color gray(double p0, double p1){ return null; } + public static Color grayRgb(int p0){ return null; } + public static Color grayRgb(int p0, double p1){ return null; } + public static Color hsb(double p0, double p1, double p2){ return null; } + public static Color hsb(double p0, double p1, double p2, double p3){ return null; } + public static Color rgb(int p0, int p1, int p2){ return null; } + public static Color rgb(int p0, int p1, int p2, double p3){ return null; } + public static Color valueOf(String p0){ return null; } + public static Color web(String p0){ return null; } + public static Color web(String p0, double p1){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/paint/Paint.java b/java/ql/test/stubs/javafx-web/javafx/scene/paint/Paint.java new file mode 100644 index 00000000000..acfb631309f --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/paint/Paint.java @@ -0,0 +1,10 @@ +// Generated automatically from javafx.scene.paint.Paint for testing purposes + +package javafx.scene.paint; + + +abstract public class Paint +{ + public abstract boolean isOpaque(); + public static Paint valueOf(String p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/text/Font.java b/java/ql/test/stubs/javafx-web/javafx/scene/text/Font.java new file mode 100644 index 00000000000..a8319a5a648 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/text/Font.java @@ -0,0 +1,36 @@ +// Generated automatically from javafx.scene.text.Font for testing purposes + +package javafx.scene.text; + +import java.io.InputStream; +import java.util.List; +import javafx.scene.text.FontPosture; +import javafx.scene.text.FontWeight; + +public class Font +{ + protected Font() {} + public Font(String p0, double p1){} + public Font(double p0){} + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public final String getFamily(){ return null; } + public final String getName(){ return null; } + public final String getStyle(){ return null; } + public final double getSize(){ return 0; } + public int hashCode(){ return 0; } + public static Font font(String p0){ return null; } + public static Font font(String p0, FontPosture p1, double p2){ return null; } + public static Font font(String p0, FontWeight p1, FontPosture p2, double p3){ return null; } + public static Font font(String p0, FontWeight p1, double p2){ return null; } + public static Font font(String p0, double p1){ return null; } + public static Font font(double p0){ return null; } + public static Font getDefault(){ return null; } + public static Font loadFont(InputStream p0, double p1){ return null; } + public static Font loadFont(String p0, double p1){ return null; } + public static Font[] loadFonts(InputStream p0, double p1){ return null; } + public static Font[] loadFonts(String p0, double p1){ return null; } + public static List getFamilies(){ return null; } + public static List getFontNames(){ return null; } + public static List getFontNames(String p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/text/FontPosture.java b/java/ql/test/stubs/javafx-web/javafx/scene/text/FontPosture.java new file mode 100644 index 00000000000..4916e6e0f24 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/text/FontPosture.java @@ -0,0 +1,11 @@ +// Generated automatically from javafx.scene.text.FontPosture for testing purposes + +package javafx.scene.text; + + +public enum FontPosture +{ + ITALIC, REGULAR; + private FontPosture() {} + public static FontPosture findByName(String p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/text/FontWeight.java b/java/ql/test/stubs/javafx-web/javafx/scene/text/FontWeight.java new file mode 100644 index 00000000000..9babffe0202 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/text/FontWeight.java @@ -0,0 +1,13 @@ +// Generated automatically from javafx.scene.text.FontWeight for testing purposes + +package javafx.scene.text; + + +public enum FontWeight +{ + BLACK, BOLD, EXTRA_BOLD, EXTRA_LIGHT, LIGHT, MEDIUM, NORMAL, SEMI_BOLD, THIN; + private FontWeight() {} + public int getWeight(){ return 0; } + public static FontWeight findByName(String p0){ return null; } + public static FontWeight findByWeight(int p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/transform/Affine.java b/java/ql/test/stubs/javafx-web/javafx/scene/transform/Affine.java new file mode 100644 index 00000000000..aabe869c990 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/transform/Affine.java @@ -0,0 +1,116 @@ +// Generated automatically from javafx.scene.transform.Affine for testing purposes + +package javafx.scene.transform; + +import javafx.beans.property.DoubleProperty; +import javafx.geometry.Point2D; +import javafx.geometry.Point3D; +import javafx.scene.transform.MatrixType; +import javafx.scene.transform.Transform; + +public class Affine extends Transform +{ + public Affine clone(){ return null; } + public Affine createInverse(){ return null; } + public Affine(){} + public Affine(Transform p0){} + public Affine(double p0, double p1, double p2, double p3, double p4, double p5){} + public Affine(double p0, double p1, double p2, double p3, double p4, double p5, double p6, double p7, double p8, double p9, double p10, double p11){} + public Affine(double[] p0, MatrixType p1, int p2){} + public Point2D deltaTransform(double p0, double p1){ return null; } + public Point2D inverseDeltaTransform(double p0, double p1){ return null; } + public Point2D inverseTransform(double p0, double p1){ return null; } + public Point2D transform(double p0, double p1){ return null; } + public Point3D deltaTransform(double p0, double p1, double p2){ return null; } + public Point3D inverseDeltaTransform(double p0, double p1, double p2){ return null; } + public Point3D inverseTransform(double p0, double p1, double p2){ return null; } + public Point3D transform(double p0, double p1, double p2){ return null; } + public String toString(){ return null; } + public Transform createConcatenation(Transform p0){ return null; } + public double determinant(){ return 0; } + public final DoubleProperty mxxProperty(){ return null; } + public final DoubleProperty mxyProperty(){ return null; } + public final DoubleProperty mxzProperty(){ return null; } + public final DoubleProperty myxProperty(){ return null; } + public final DoubleProperty myyProperty(){ return null; } + public final DoubleProperty myzProperty(){ return null; } + public final DoubleProperty mzxProperty(){ return null; } + public final DoubleProperty mzyProperty(){ return null; } + public final DoubleProperty mzzProperty(){ return null; } + public final DoubleProperty txProperty(){ return null; } + public final DoubleProperty tyProperty(){ return null; } + public final DoubleProperty tzProperty(){ return null; } + public final double getMxx(){ return 0; } + public final double getMxy(){ return 0; } + public final double getMxz(){ return 0; } + public final double getMyx(){ return 0; } + public final double getMyy(){ return 0; } + public final double getMyz(){ return 0; } + public final double getMzx(){ return 0; } + public final double getMzy(){ return 0; } + public final double getMzz(){ return 0; } + public final double getTx(){ return 0; } + public final double getTy(){ return 0; } + public final double getTz(){ return 0; } + public final void setMxx(double p0){} + public final void setMxy(double p0){} + public final void setMxz(double p0){} + public final void setMyx(double p0){} + public final void setMyy(double p0){} + public final void setMyz(double p0){} + public final void setMzx(double p0){} + public final void setMzy(double p0){} + public final void setMzz(double p0){} + public final void setTx(double p0){} + public final void setTy(double p0){} + public final void setTz(double p0){} + public void append(Transform p0){} + public void append(double p0, double p1, double p2, double p3, double p4, double p5){} + public void append(double p0, double p1, double p2, double p3, double p4, double p5, double p6, double p7, double p8, double p9, double p10, double p11){} + public void append(double[] p0, MatrixType p1, int p2){} + public void appendRotation(double p0){} + public void appendRotation(double p0, Point2D p1){} + public void appendRotation(double p0, Point3D p1, Point3D p2){} + public void appendRotation(double p0, double p1, double p2){} + public void appendRotation(double p0, double p1, double p2, double p3, Point3D p4){} + public void appendRotation(double p0, double p1, double p2, double p3, double p4, double p5, double p6){} + public void appendScale(double p0, double p1){} + public void appendScale(double p0, double p1, Point2D p2){} + public void appendScale(double p0, double p1, double p2){} + public void appendScale(double p0, double p1, double p2, Point3D p3){} + public void appendScale(double p0, double p1, double p2, double p3){} + public void appendScale(double p0, double p1, double p2, double p3, double p4, double p5){} + public void appendShear(double p0, double p1){} + public void appendShear(double p0, double p1, Point2D p2){} + public void appendShear(double p0, double p1, double p2, double p3){} + public void appendTranslation(double p0, double p1){} + public void appendTranslation(double p0, double p1, double p2){} + public void invert(){} + public void prepend(Transform p0){} + public void prepend(double p0, double p1, double p2, double p3, double p4, double p5){} + public void prepend(double p0, double p1, double p2, double p3, double p4, double p5, double p6, double p7, double p8, double p9, double p10, double p11){} + public void prepend(double[] p0, MatrixType p1, int p2){} + public void prependRotation(double p0){} + public void prependRotation(double p0, Point2D p1){} + public void prependRotation(double p0, Point3D p1, Point3D p2){} + public void prependRotation(double p0, double p1, double p2){} + public void prependRotation(double p0, double p1, double p2, double p3, Point3D p4){} + public void prependRotation(double p0, double p1, double p2, double p3, double p4, double p5, double p6){} + public void prependScale(double p0, double p1){} + public void prependScale(double p0, double p1, Point2D p2){} + public void prependScale(double p0, double p1, double p2){} + public void prependScale(double p0, double p1, double p2, Point3D p3){} + public void prependScale(double p0, double p1, double p2, double p3){} + public void prependScale(double p0, double p1, double p2, double p3, double p4, double p5){} + public void prependShear(double p0, double p1){} + public void prependShear(double p0, double p1, Point2D p2){} + public void prependShear(double p0, double p1, double p2, double p3){} + public void prependTranslation(double p0, double p1){} + public void prependTranslation(double p0, double p1, double p2){} + public void setElement(MatrixType p0, int p1, int p2, double p3){} + public void setToIdentity(){} + public void setToTransform(Transform p0){} + public void setToTransform(double p0, double p1, double p2, double p3, double p4, double p5){} + public void setToTransform(double p0, double p1, double p2, double p3, double p4, double p5, double p6, double p7, double p8, double p9, double p10, double p11){} + public void setToTransform(double[] p0, MatrixType p1, int p2){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/transform/MatrixType.java b/java/ql/test/stubs/javafx-web/javafx/scene/transform/MatrixType.java new file mode 100644 index 00000000000..d9d0619c5b1 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/transform/MatrixType.java @@ -0,0 +1,14 @@ +// Generated automatically from javafx.scene.transform.MatrixType for testing purposes + +package javafx.scene.transform; + + +public enum MatrixType +{ + MT_2D_2x3, MT_2D_3x3, MT_3D_3x4, MT_3D_4x4; + private MatrixType() {} + public boolean is2D(){ return false; } + public int columns(){ return 0; } + public int elements(){ return 0; } + public int rows(){ return 0; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/transform/Rotate.java b/java/ql/test/stubs/javafx-web/javafx/scene/transform/Rotate.java new file mode 100644 index 00000000000..f13d97ff389 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/transform/Rotate.java @@ -0,0 +1,62 @@ +// Generated automatically from javafx.scene.transform.Rotate for testing purposes + +package javafx.scene.transform; + +import javafx.beans.property.DoubleProperty; +import javafx.beans.property.ObjectProperty; +import javafx.geometry.Point2D; +import javafx.geometry.Point3D; +import javafx.scene.transform.Transform; + +public class Rotate extends Transform +{ + protected void transformChanged(){} + public Point2D deltaTransform(double p0, double p1){ return null; } + public Point2D inverseDeltaTransform(double p0, double p1){ return null; } + public Point2D inverseTransform(double p0, double p1){ return null; } + public Point2D transform(double p0, double p1){ return null; } + public Point3D deltaTransform(double p0, double p1, double p2){ return null; } + public Point3D inverseDeltaTransform(double p0, double p1, double p2){ return null; } + public Point3D inverseTransform(double p0, double p1, double p2){ return null; } + public Point3D transform(double p0, double p1, double p2){ return null; } + public Rotate clone(){ return null; } + public Rotate(){} + public Rotate(double p0){} + public Rotate(double p0, Point3D p1){} + public Rotate(double p0, double p1, double p2){} + public Rotate(double p0, double p1, double p2, double p3){} + public Rotate(double p0, double p1, double p2, double p3, Point3D p4){} + public String toString(){ return null; } + public Transform createConcatenation(Transform p0){ return null; } + public Transform createInverse(){ return null; } + public double getMxx(){ return 0; } + public double getMxy(){ return 0; } + public double getMxz(){ return 0; } + public double getMyx(){ return 0; } + public double getMyy(){ return 0; } + public double getMyz(){ return 0; } + public double getMzx(){ return 0; } + public double getMzy(){ return 0; } + public double getMzz(){ return 0; } + public double getTx(){ return 0; } + public double getTy(){ return 0; } + public double getTz(){ return 0; } + public final DoubleProperty angleProperty(){ return null; } + public final DoubleProperty pivotXProperty(){ return null; } + public final DoubleProperty pivotYProperty(){ return null; } + public final DoubleProperty pivotZProperty(){ return null; } + public final ObjectProperty axisProperty(){ return null; } + public final Point3D getAxis(){ return null; } + public final double getAngle(){ return 0; } + public final double getPivotX(){ return 0; } + public final double getPivotY(){ return 0; } + public final double getPivotZ(){ return 0; } + public final void setAngle(double p0){} + public final void setAxis(Point3D p0){} + public final void setPivotX(double p0){} + public final void setPivotY(double p0){} + public final void setPivotZ(double p0){} + public static Point3D X_AXIS = null; + public static Point3D Y_AXIS = null; + public static Point3D Z_AXIS = null; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/transform/Scale.java b/java/ql/test/stubs/javafx-web/javafx/scene/transform/Scale.java new file mode 100644 index 00000000000..be3dd62baa9 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/transform/Scale.java @@ -0,0 +1,53 @@ +// Generated automatically from javafx.scene.transform.Scale for testing purposes + +package javafx.scene.transform; + +import javafx.beans.property.DoubleProperty; +import javafx.geometry.Point2D; +import javafx.geometry.Point3D; +import javafx.scene.transform.Transform; + +public class Scale extends Transform +{ + public Point2D deltaTransform(double p0, double p1){ return null; } + public Point2D inverseDeltaTransform(double p0, double p1){ return null; } + public Point2D inverseTransform(double p0, double p1){ return null; } + public Point2D transform(double p0, double p1){ return null; } + public Point3D deltaTransform(double p0, double p1, double p2){ return null; } + public Point3D inverseDeltaTransform(double p0, double p1, double p2){ return null; } + public Point3D inverseTransform(double p0, double p1, double p2){ return null; } + public Point3D transform(double p0, double p1, double p2){ return null; } + public Scale clone(){ return null; } + public Scale createInverse(){ return null; } + public Scale(){} + public Scale(double p0, double p1){} + public Scale(double p0, double p1, double p2){} + public Scale(double p0, double p1, double p2, double p3){} + public Scale(double p0, double p1, double p2, double p3, double p4, double p5){} + public String toString(){ return null; } + public Transform createConcatenation(Transform p0){ return null; } + public double getMxx(){ return 0; } + public double getMyy(){ return 0; } + public double getMzz(){ return 0; } + public double getTx(){ return 0; } + public double getTy(){ return 0; } + public double getTz(){ return 0; } + public final DoubleProperty pivotXProperty(){ return null; } + public final DoubleProperty pivotYProperty(){ return null; } + public final DoubleProperty pivotZProperty(){ return null; } + public final DoubleProperty xProperty(){ return null; } + public final DoubleProperty yProperty(){ return null; } + public final DoubleProperty zProperty(){ return null; } + public final double getPivotX(){ return 0; } + public final double getPivotY(){ return 0; } + public final double getPivotZ(){ return 0; } + public final double getX(){ return 0; } + public final double getY(){ return 0; } + public final double getZ(){ return 0; } + public final void setPivotX(double p0){} + public final void setPivotY(double p0){} + public final void setPivotZ(double p0){} + public final void setX(double p0){} + public final void setY(double p0){} + public final void setZ(double p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/transform/Shear.java b/java/ql/test/stubs/javafx-web/javafx/scene/transform/Shear.java new file mode 100644 index 00000000000..3bf3e2ea2dd --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/transform/Shear.java @@ -0,0 +1,43 @@ +// Generated automatically from javafx.scene.transform.Shear for testing purposes + +package javafx.scene.transform; + +import javafx.beans.property.DoubleProperty; +import javafx.geometry.Point2D; +import javafx.geometry.Point3D; +import javafx.scene.transform.Transform; + +public class Shear extends Transform +{ + public Point2D deltaTransform(double p0, double p1){ return null; } + public Point2D inverseDeltaTransform(double p0, double p1){ return null; } + public Point2D inverseTransform(double p0, double p1){ return null; } + public Point2D transform(double p0, double p1){ return null; } + public Point3D deltaTransform(double p0, double p1, double p2){ return null; } + public Point3D inverseDeltaTransform(double p0, double p1, double p2){ return null; } + public Point3D inverseTransform(double p0, double p1, double p2){ return null; } + public Point3D transform(double p0, double p1, double p2){ return null; } + public Shear clone(){ return null; } + public Shear(){} + public Shear(double p0, double p1){} + public Shear(double p0, double p1, double p2, double p3){} + public String toString(){ return null; } + public Transform createConcatenation(Transform p0){ return null; } + public Transform createInverse(){ return null; } + public double getMxy(){ return 0; } + public double getMyx(){ return 0; } + public double getTx(){ return 0; } + public double getTy(){ return 0; } + public final DoubleProperty pivotXProperty(){ return null; } + public final DoubleProperty pivotYProperty(){ return null; } + public final DoubleProperty xProperty(){ return null; } + public final DoubleProperty yProperty(){ return null; } + public final double getPivotX(){ return 0; } + public final double getPivotY(){ return 0; } + public final double getX(){ return 0; } + public final double getY(){ return 0; } + public final void setPivotX(double p0){} + public final void setPivotY(double p0){} + public final void setX(double p0){} + public final void setY(double p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/transform/Transform.java b/java/ql/test/stubs/javafx-web/javafx/scene/transform/Transform.java new file mode 100644 index 00000000000..2c4ac734a25 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/transform/Transform.java @@ -0,0 +1,93 @@ +// Generated automatically from javafx.scene.transform.Transform for testing purposes + +package javafx.scene.transform; + +import javafx.beans.property.ObjectProperty; +import javafx.beans.property.ReadOnlyBooleanProperty; +import javafx.event.Event; +import javafx.event.EventDispatchChain; +import javafx.event.EventHandler; +import javafx.event.EventTarget; +import javafx.event.EventType; +import javafx.geometry.Bounds; +import javafx.geometry.Point2D; +import javafx.geometry.Point3D; +import javafx.scene.transform.Affine; +import javafx.scene.transform.MatrixType; +import javafx.scene.transform.Rotate; +import javafx.scene.transform.Scale; +import javafx.scene.transform.Shear; +import javafx.scene.transform.TransformChangedEvent; +import javafx.scene.transform.Translate; + +abstract public class Transform implements Cloneable, EventTarget +{ + protected void transformChanged(){} + public Bounds inverseTransform(Bounds p0){ return null; } + public Bounds transform(Bounds p0){ return null; } + public EventDispatchChain buildEventDispatchChain(EventDispatchChain p0){ return null; } + public Point2D deltaTransform(Point2D p0){ return null; } + public Point2D deltaTransform(double p0, double p1){ return null; } + public Point2D inverseDeltaTransform(Point2D p0){ return null; } + public Point2D inverseDeltaTransform(double p0, double p1){ return null; } + public Point2D inverseTransform(Point2D p0){ return null; } + public Point2D inverseTransform(double p0, double p1){ return null; } + public Point2D transform(Point2D p0){ return null; } + public Point2D transform(double p0, double p1){ return null; } + public Point3D deltaTransform(Point3D p0){ return null; } + public Point3D deltaTransform(double p0, double p1, double p2){ return null; } + public Point3D inverseDeltaTransform(Point3D p0){ return null; } + public Point3D inverseDeltaTransform(double p0, double p1, double p2){ return null; } + public Point3D inverseTransform(Point3D p0){ return null; } + public Point3D inverseTransform(double p0, double p1, double p2){ return null; } + public Point3D transform(Point3D p0){ return null; } + public Point3D transform(double p0, double p1, double p2){ return null; } + public Transform clone(){ return null; } + public Transform createConcatenation(Transform p0){ return null; } + public Transform createInverse(){ return null; } + public Transform(){} + public boolean similarTo(Transform p0, Bounds p1, double p2){ return false; } + public double determinant(){ return 0; } + public double getElement(MatrixType p0, int p1, int p2){ return 0; } + public double getMxx(){ return 0; } + public double getMxy(){ return 0; } + public double getMxz(){ return 0; } + public double getMyx(){ return 0; } + public double getMyy(){ return 0; } + public double getMyz(){ return 0; } + public double getMzx(){ return 0; } + public double getMzy(){ return 0; } + public double getMzz(){ return 0; } + public double getTx(){ return 0; } + public double getTy(){ return 0; } + public double getTz(){ return 0; } + public double[] column(MatrixType p0, int p1){ return null; } + public double[] column(MatrixType p0, int p1, double[] p2){ return null; } + public double[] row(MatrixType p0, int p1){ return null; } + public double[] row(MatrixType p0, int p1, double[] p2){ return null; } + public double[] toArray(MatrixType p0){ return null; } + public double[] toArray(MatrixType p0, double[] p1){ return null; } + public final void addEventFilter(javafx.event.EventType p0, javafx.event.EventHandler p1){} + public final void addEventHandler(javafx.event.EventType p0, javafx.event.EventHandler p1){} + public final void removeEventFilter(javafx.event.EventType p0, javafx.event.EventHandler p1){} + public final void removeEventHandler(javafx.event.EventType p0, javafx.event.EventHandler p1){} + public final EventHandler getOnTransformChanged(){ return null; } + public final ObjectProperty> onTransformChangedProperty(){ return null; } + public final ReadOnlyBooleanProperty identityProperty(){ return null; } + public final ReadOnlyBooleanProperty type2DProperty(){ return null; } + public final boolean isIdentity(){ return false; } + public final boolean isType2D(){ return false; } + public final void setOnTransformChanged(EventHandler p0){} + public static Affine affine(double p0, double p1, double p2, double p3, double p4, double p5){ return null; } + public static Affine affine(double p0, double p1, double p2, double p3, double p4, double p5, double p6, double p7, double p8, double p9, double p10, double p11){ return null; } + public static Rotate rotate(double p0, double p1, double p2){ return null; } + public static Scale scale(double p0, double p1){ return null; } + public static Scale scale(double p0, double p1, double p2, double p3){ return null; } + public static Shear shear(double p0, double p1){ return null; } + public static Shear shear(double p0, double p1, double p2, double p3){ return null; } + public static Translate translate(double p0, double p1){ return null; } + public void inverseTransform2DPoints(double[] p0, int p1, double[] p2, int p3, int p4){} + public void inverseTransform3DPoints(double[] p0, int p1, double[] p2, int p3, int p4){} + public void transform2DPoints(double[] p0, int p1, double[] p2, int p3, int p4){} + public void transform3DPoints(double[] p0, int p1, double[] p2, int p3, int p4){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/transform/TransformChangedEvent.java b/java/ql/test/stubs/javafx-web/javafx/scene/transform/TransformChangedEvent.java new file mode 100644 index 00000000000..99d09a029c1 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/transform/TransformChangedEvent.java @@ -0,0 +1,15 @@ +// Generated automatically from javafx.scene.transform.TransformChangedEvent for testing purposes + +package javafx.scene.transform; + +import javafx.event.Event; +import javafx.event.EventTarget; +import javafx.event.EventType; + +public class TransformChangedEvent extends Event +{ + public TransformChangedEvent(){} + public TransformChangedEvent(Object p0, EventTarget p1){} + public static EventType ANY = null; + public static EventType TRANSFORM_CHANGED = null; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/transform/Translate.java b/java/ql/test/stubs/javafx-web/javafx/scene/transform/Translate.java new file mode 100644 index 00000000000..1051a35b7b5 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/transform/Translate.java @@ -0,0 +1,43 @@ +// Generated automatically from javafx.scene.transform.Translate for testing purposes + +package javafx.scene.transform; + +import javafx.beans.property.DoubleProperty; +import javafx.geometry.Point2D; +import javafx.geometry.Point3D; +import javafx.scene.transform.Transform; + +public class Translate extends Transform +{ + public Point2D deltaTransform(Point2D p0){ return null; } + public Point2D deltaTransform(double p0, double p1){ return null; } + public Point2D inverseDeltaTransform(Point2D p0){ return null; } + public Point2D inverseDeltaTransform(double p0, double p1){ return null; } + public Point2D inverseTransform(double p0, double p1){ return null; } + public Point2D transform(double p0, double p1){ return null; } + public Point3D deltaTransform(Point3D p0){ return null; } + public Point3D deltaTransform(double p0, double p1, double p2){ return null; } + public Point3D inverseDeltaTransform(Point3D p0){ return null; } + public Point3D inverseDeltaTransform(double p0, double p1, double p2){ return null; } + public Point3D inverseTransform(double p0, double p1, double p2){ return null; } + public Point3D transform(double p0, double p1, double p2){ return null; } + public String toString(){ return null; } + public Transform createConcatenation(Transform p0){ return null; } + public Translate clone(){ return null; } + public Translate createInverse(){ return null; } + public Translate(){} + public Translate(double p0, double p1){} + public Translate(double p0, double p1, double p2){} + public double getTx(){ return 0; } + public double getTy(){ return 0; } + public double getTz(){ return 0; } + public final DoubleProperty xProperty(){ return null; } + public final DoubleProperty yProperty(){ return null; } + public final DoubleProperty zProperty(){ return null; } + public final double getX(){ return 0; } + public final double getY(){ return 0; } + public final double getZ(){ return 0; } + public final void setX(double p0){} + public final void setY(double p0){} + public final void setZ(double p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/web/PopupFeatures.java b/java/ql/test/stubs/javafx-web/javafx/scene/web/PopupFeatures.java new file mode 100644 index 00000000000..0841b1e85a0 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/web/PopupFeatures.java @@ -0,0 +1,14 @@ +// Generated automatically from javafx.scene.web.PopupFeatures for testing purposes + +package javafx.scene.web; + + +public class PopupFeatures +{ + protected PopupFeatures() {} + public PopupFeatures(boolean p0, boolean p1, boolean p2, boolean p3){} + public final boolean hasMenu(){ return false; } + public final boolean hasStatus(){ return false; } + public final boolean hasToolbar(){ return false; } + public final boolean isResizable(){ return false; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/web/PromptData.java b/java/ql/test/stubs/javafx-web/javafx/scene/web/PromptData.java new file mode 100644 index 00000000000..18cee457f60 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/web/PromptData.java @@ -0,0 +1,12 @@ +// Generated automatically from javafx.scene.web.PromptData for testing purposes + +package javafx.scene.web; + + +public class PromptData +{ + protected PromptData() {} + public PromptData(String p0, String p1){} + public final String getDefaultValue(){ return null; } + public final String getMessage(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/web/WebEngine.java b/java/ql/test/stubs/javafx-web/javafx/scene/web/WebEngine.java new file mode 100644 index 00000000000..638f381fd49 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/web/WebEngine.java @@ -0,0 +1,78 @@ +// Generated automatically from javafx.scene.web.WebEngine for testing purposes + +package javafx.scene.web; + +import java.io.File; +import javafx.beans.property.BooleanProperty; +import javafx.beans.property.ObjectProperty; +import javafx.beans.property.ReadOnlyObjectProperty; +import javafx.beans.property.ReadOnlyStringProperty; +import javafx.beans.property.StringProperty; +import javafx.concurrent.Worker; +import javafx.event.Event; +import javafx.event.EventHandler; +import javafx.geometry.Rectangle2D; +import javafx.print.PrinterJob; +import javafx.scene.web.PopupFeatures; +import javafx.scene.web.PromptData; +import javafx.scene.web.WebErrorEvent; +import javafx.scene.web.WebEvent; +import javafx.scene.web.WebHistory; +import javafx.util.Callback; +import org.w3c.dom.Document; + +public class WebEngine +{ + public Object executeScript(String p0){ return null; } + public WebEngine(){} + public WebEngine(String p0){} + public WebHistory getHistory(){ return null; } + public final BooleanProperty javaScriptEnabledProperty(){ return null; } + public final Callback getCreatePopupHandler(){ return null; } + public final Callback getPromptHandler(){ return null; } + public final Callback getConfirmHandler(){ return null; } + public final Document getDocument(){ return null; } + public final EventHandler getOnError(){ return null; } + public final EventHandler> getOnVisibilityChanged(){ return null; } + public final EventHandler> getOnResized(){ return null; } + public final EventHandler> getOnAlert(){ return null; } + public final EventHandler> getOnStatusChanged(){ return null; } + public final File getUserDataDirectory(){ return null; } + public final ObjectProperty> createPopupHandlerProperty(){ return null; } + public final ObjectProperty> promptHandlerProperty(){ return null; } + public final ObjectProperty> confirmHandlerProperty(){ return null; } + public final ObjectProperty> onErrorProperty(){ return null; } + public final ObjectProperty>> onVisibilityChangedProperty(){ return null; } + public final ObjectProperty>> onResizedProperty(){ return null; } + public final ObjectProperty>> onAlertProperty(){ return null; } + public final ObjectProperty>> onStatusChangedProperty(){ return null; } + public final ObjectProperty userDataDirectoryProperty(){ return null; } + public final ReadOnlyObjectProperty documentProperty(){ return null; } + public final ReadOnlyStringProperty locationProperty(){ return null; } + public final ReadOnlyStringProperty titleProperty(){ return null; } + public final String getLocation(){ return null; } + public final String getTitle(){ return null; } + public final String getUserAgent(){ return null; } + public final String getUserStyleSheetLocation(){ return null; } + public final StringProperty userAgentProperty(){ return null; } + public final StringProperty userStyleSheetLocationProperty(){ return null; } + public final Worker getLoadWorker(){ return null; } + public final boolean isJavaScriptEnabled(){ return false; } + public final void setConfirmHandler(Callback p0){} + public final void setCreatePopupHandler(Callback p0){} + public final void setJavaScriptEnabled(boolean p0){} + public final void setOnAlert(EventHandler> p0){} + public final void setOnError(EventHandler p0){} + public final void setOnResized(EventHandler> p0){} + public final void setOnStatusChanged(EventHandler> p0){} + public final void setOnVisibilityChanged(EventHandler> p0){} + public final void setPromptHandler(Callback p0){} + public final void setUserAgent(String p0){} + public final void setUserDataDirectory(File p0){} + public final void setUserStyleSheetLocation(String p0){} + public void load(String p0){} + public void loadContent(String p0){} + public void loadContent(String p0, String p1){} + public void print(PrinterJob p0){} + public void reload(){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/web/WebErrorEvent.java b/java/ql/test/stubs/javafx-web/javafx/scene/web/WebErrorEvent.java new file mode 100644 index 00000000000..99f56e8fa55 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/web/WebErrorEvent.java @@ -0,0 +1,19 @@ +// Generated automatically from javafx.scene.web.WebErrorEvent for testing purposes + +package javafx.scene.web; + +import javafx.event.Event; +import javafx.event.EventType; + +public class WebErrorEvent extends Event +{ + protected WebErrorEvent() {} + public String getMessage(){ return null; } + public String toString(){ return null; } + public Throwable getException(){ return null; } + public WebErrorEvent(Object p0, EventType p1, String p2, Throwable p3){} + public static EventType ANY = null; + public static EventType USER_DATA_DIRECTORY_ALREADY_IN_USE = null; + public static EventType USER_DATA_DIRECTORY_IO_ERROR = null; + public static EventType USER_DATA_DIRECTORY_SECURITY_ERROR = null; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/web/WebEvent.java b/java/ql/test/stubs/javafx-web/javafx/scene/web/WebEvent.java new file mode 100644 index 00000000000..971cf8f5426 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/web/WebEvent.java @@ -0,0 +1,19 @@ +// Generated automatically from javafx.scene.web.WebEvent for testing purposes + +package javafx.scene.web; + +import javafx.event.Event; +import javafx.event.EventType; + +public class WebEvent extends Event +{ + protected WebEvent() {} + public String toString(){ return null; } + public T getData(){ return null; } + public WebEvent(Object p0, EventType p1, T p2){} + public static EventType ALERT = null; + public static EventType ANY = null; + public static EventType RESIZED = null; + public static EventType STATUS_CHANGED = null; + public static EventType VISIBILITY_CHANGED = null; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/scene/web/WebHistory.java b/java/ql/test/stubs/javafx-web/javafx/scene/web/WebHistory.java new file mode 100644 index 00000000000..40e59ffdab0 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/scene/web/WebHistory.java @@ -0,0 +1,30 @@ +// Generated automatically from javafx.scene.web.WebHistory for testing purposes + +package javafx.scene.web; + +import javafx.beans.property.IntegerProperty; +import javafx.beans.property.ReadOnlyIntegerProperty; +import javafx.beans.property.ReadOnlyObjectProperty; +import javafx.collections.ObservableList; + +public class WebHistory +{ + protected WebHistory() {} + public IntegerProperty maxSizeProperty(){ return null; } + public ObservableList getEntries(){ return null; } + public ReadOnlyIntegerProperty currentIndexProperty(){ return null; } + public class Entry + { + protected Entry() {} + public ReadOnlyObjectProperty titleProperty(){ return null; } + public ReadOnlyObjectProperty lastVisitedDateProperty(){ return null; } + public String getTitle(){ return null; } + public String getUrl(){ return null; } + public String toString(){ return null; } + public java.util.Date getLastVisitedDate(){ return null; } + } + public int getCurrentIndex(){ return 0; } + public int getMaxSize(){ return 0; } + public void go(int p0){} + public void setMaxSize(int p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/stage/Window.java b/java/ql/test/stubs/javafx-web/javafx/stage/Window.java new file mode 100644 index 00000000000..958b5648bf0 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/stage/Window.java @@ -0,0 +1,95 @@ +// Generated automatically from javafx.stage.Window for testing purposes + +package javafx.stage; + +import javafx.beans.property.BooleanProperty; +import javafx.beans.property.DoubleProperty; +import javafx.beans.property.ObjectProperty; +import javafx.beans.property.ReadOnlyBooleanProperty; +import javafx.beans.property.ReadOnlyDoubleProperty; +import javafx.beans.property.ReadOnlyObjectProperty; +import javafx.collections.ObservableList; +import javafx.collections.ObservableMap; +import javafx.event.Event; +import javafx.event.EventDispatchChain; +import javafx.event.EventDispatcher; +import javafx.event.EventHandler; +import javafx.event.EventTarget; +import javafx.event.EventType; +import javafx.scene.Scene; +import javafx.stage.WindowEvent; + +public class Window implements EventTarget +{ + protected Window(){} + protected final void setEventHandler(javafx.event.EventType p0, javafx.event.EventHandler p1){} + protected void setScene(Scene p0){} + protected void show(){} + public EventDispatchChain buildEventDispatchChain(EventDispatchChain p0){ return null; } + public Object getUserData(){ return null; } + public boolean hasProperties(){ return false; } + public final void addEventFilter(javafx.event.EventType p0, javafx.event.EventHandler p1){} + public final void addEventHandler(javafx.event.EventType p0, javafx.event.EventHandler p1){} + public final void removeEventFilter(javafx.event.EventType p0, javafx.event.EventHandler p1){} + public final void removeEventHandler(javafx.event.EventType p0, javafx.event.EventHandler p1){} + public final BooleanProperty forceIntegerRenderScaleProperty(){ return null; } + public final DoubleProperty opacityProperty(){ return null; } + public final DoubleProperty renderScaleXProperty(){ return null; } + public final DoubleProperty renderScaleYProperty(){ return null; } + public final EventDispatcher getEventDispatcher(){ return null; } + public final EventHandler getOnCloseRequest(){ return null; } + public final EventHandler getOnHidden(){ return null; } + public final EventHandler getOnHiding(){ return null; } + public final EventHandler getOnShowing(){ return null; } + public final EventHandler getOnShown(){ return null; } + public final ObjectProperty eventDispatcherProperty(){ return null; } + public final ObjectProperty> onCloseRequestProperty(){ return null; } + public final ObjectProperty> onHiddenProperty(){ return null; } + public final ObjectProperty> onHidingProperty(){ return null; } + public final ObjectProperty> onShowingProperty(){ return null; } + public final ObjectProperty> onShownProperty(){ return null; } + public final ObservableMap getProperties(){ return null; } + public final ReadOnlyBooleanProperty focusedProperty(){ return null; } + public final ReadOnlyBooleanProperty showingProperty(){ return null; } + public final ReadOnlyDoubleProperty heightProperty(){ return null; } + public final ReadOnlyDoubleProperty outputScaleXProperty(){ return null; } + public final ReadOnlyDoubleProperty outputScaleYProperty(){ return null; } + public final ReadOnlyDoubleProperty widthProperty(){ return null; } + public final ReadOnlyDoubleProperty xProperty(){ return null; } + public final ReadOnlyDoubleProperty yProperty(){ return null; } + public final ReadOnlyObjectProperty sceneProperty(){ return null; } + public final Scene getScene(){ return null; } + public final boolean isFocused(){ return false; } + public final boolean isForceIntegerRenderScale(){ return false; } + public final boolean isShowing(){ return false; } + public final double getHeight(){ return 0; } + public final double getOpacity(){ return 0; } + public final double getOutputScaleX(){ return 0; } + public final double getOutputScaleY(){ return 0; } + public final double getRenderScaleX(){ return 0; } + public final double getRenderScaleY(){ return 0; } + public final double getWidth(){ return 0; } + public final double getX(){ return 0; } + public final double getY(){ return 0; } + public final void fireEvent(Event p0){} + public final void requestFocus(){} + public final void setEventDispatcher(EventDispatcher p0){} + public final void setForceIntegerRenderScale(boolean p0){} + public final void setHeight(double p0){} + public final void setOnCloseRequest(EventHandler p0){} + public final void setOnHidden(EventHandler p0){} + public final void setOnHiding(EventHandler p0){} + public final void setOnShowing(EventHandler p0){} + public final void setOnShown(EventHandler p0){} + public final void setOpacity(double p0){} + public final void setRenderScaleX(double p0){} + public final void setRenderScaleY(double p0){} + public final void setWidth(double p0){} + public final void setX(double p0){} + public final void setY(double p0){} + public static ObservableList getWindows(){ return null; } + public void centerOnScreen(){} + public void hide(){} + public void setUserData(Object p0){} + public void sizeToScene(){} +} diff --git a/java/ql/test/stubs/javafx-web/javafx/stage/WindowEvent.java b/java/ql/test/stubs/javafx-web/javafx/stage/WindowEvent.java new file mode 100644 index 00000000000..895955e52f7 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/stage/WindowEvent.java @@ -0,0 +1,24 @@ +// Generated automatically from javafx.stage.WindowEvent for testing purposes + +package javafx.stage; + +import javafx.event.Event; +import javafx.event.EventTarget; +import javafx.event.EventType; +import javafx.stage.Window; + +public class WindowEvent extends Event +{ + protected WindowEvent() {} + public EventType getEventType(){ return null; } + public String toString(){ return null; } + public WindowEvent copyFor(Object p0, EventTarget p1){ return null; } + public WindowEvent copyFor(Object p0, EventTarget p1, EventType p2){ return null; } + public WindowEvent(Window p0, EventType p1){} + public static EventType ANY = null; + public static EventType WINDOW_CLOSE_REQUEST = null; + public static EventType WINDOW_HIDDEN = null; + public static EventType WINDOW_HIDING = null; + public static EventType WINDOW_SHOWING = null; + public static EventType WINDOW_SHOWN = null; +} diff --git a/java/ql/test/stubs/javafx-web/javafx/util/Callback.java b/java/ql/test/stubs/javafx-web/javafx/util/Callback.java new file mode 100644 index 00000000000..6a2369c9806 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/util/Callback.java @@ -0,0 +1,9 @@ +// Generated automatically from javafx.util.Callback for testing purposes + +package javafx.util; + + +public interface Callback +{ + R call(P p0); +} diff --git a/java/ql/test/stubs/javafx-web/javafx/util/Duration.java b/java/ql/test/stubs/javafx-web/javafx/util/Duration.java new file mode 100644 index 00000000000..30b60c08618 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/util/Duration.java @@ -0,0 +1,41 @@ +// Generated automatically from javafx.util.Duration for testing purposes + +package javafx.util; + +import java.io.Serializable; + +public class Duration implements Serializable, java.lang.Comparable +{ + protected Duration() {} + public Duration add(Duration p0){ return null; } + public Duration divide(Duration p0){ return null; } + public Duration divide(double p0){ return null; } + public Duration multiply(Duration p0){ return null; } + public Duration multiply(double p0){ return null; } + public Duration negate(){ return null; } + public Duration subtract(Duration p0){ return null; } + public Duration(double p0){} + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public boolean greaterThan(Duration p0){ return false; } + public boolean greaterThanOrEqualTo(Duration p0){ return false; } + public boolean isIndefinite(){ return false; } + public boolean isUnknown(){ return false; } + public boolean lessThan(Duration p0){ return false; } + public boolean lessThanOrEqualTo(Duration p0){ return false; } + public double toHours(){ return 0; } + public double toMillis(){ return 0; } + public double toMinutes(){ return 0; } + public double toSeconds(){ return 0; } + public int compareTo(Duration p0){ return 0; } + public int hashCode(){ return 0; } + public static Duration INDEFINITE = null; + public static Duration ONE = null; + public static Duration UNKNOWN = null; + public static Duration ZERO = null; + public static Duration hours(double p0){ return null; } + public static Duration millis(double p0){ return null; } + public static Duration minutes(double p0){ return null; } + public static Duration seconds(double p0){ return null; } + public static Duration valueOf(String p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/util/Pair.java b/java/ql/test/stubs/javafx-web/javafx/util/Pair.java new file mode 100644 index 00000000000..86d76d98cf6 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/util/Pair.java @@ -0,0 +1,16 @@ +// Generated automatically from javafx.util.Pair for testing purposes + +package javafx.util; + +import java.io.Serializable; + +public class Pair implements Serializable +{ + protected Pair() {} + public K getKey(){ return null; } + public Pair(K p0, V p1){} + public String toString(){ return null; } + public V getValue(){ return null; } + public boolean equals(Object p0){ return false; } + public int hashCode(){ return 0; } +} diff --git a/java/ql/test/stubs/javafx-web/javafx/util/StringConverter.java b/java/ql/test/stubs/javafx-web/javafx/util/StringConverter.java new file mode 100644 index 00000000000..7a89a4cb5df --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javafx/util/StringConverter.java @@ -0,0 +1,11 @@ +// Generated automatically from javafx.util.StringConverter for testing purposes + +package javafx.util; + + +abstract public class StringConverter +{ + public StringConverter(){} + public abstract String toString(T p0); + public abstract T fromString(String p0); +} diff --git a/java/ql/test/stubs/javafx-web/javax/net/ServerSocketFactory.java b/java/ql/test/stubs/javafx-web/javax/net/ServerSocketFactory.java new file mode 100644 index 00000000000..2f4732a4ec0 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/net/ServerSocketFactory.java @@ -0,0 +1,16 @@ +// Generated automatically from javax.net.ServerSocketFactory for testing purposes + +package javax.net; + +import java.net.InetAddress; +import java.net.ServerSocket; + +abstract public class ServerSocketFactory +{ + protected ServerSocketFactory(){} + public ServerSocket createServerSocket(){ return null; } + public abstract ServerSocket createServerSocket(int p0); + public abstract ServerSocket createServerSocket(int p0, int p1); + public abstract ServerSocket createServerSocket(int p0, int p1, InetAddress p2); + public static ServerSocketFactory getDefault(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javax/net/SocketFactory.java b/java/ql/test/stubs/javafx-web/javax/net/SocketFactory.java new file mode 100644 index 00000000000..ddab28a7fc8 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/net/SocketFactory.java @@ -0,0 +1,17 @@ +// Generated automatically from javax.net.SocketFactory for testing purposes + +package javax.net; + +import java.net.InetAddress; +import java.net.Socket; + +abstract public class SocketFactory +{ + protected SocketFactory(){} + public Socket createSocket(){ return null; } + public abstract Socket createSocket(InetAddress p0, int p1); + public abstract Socket createSocket(InetAddress p0, int p1, InetAddress p2, int p3); + public abstract Socket createSocket(String p0, int p1); + public abstract Socket createSocket(String p0, int p1, InetAddress p2, int p3); + public static SocketFactory getDefault(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javax/net/ssl/HostnameVerifier.java b/java/ql/test/stubs/javafx-web/javax/net/ssl/HostnameVerifier.java new file mode 100644 index 00000000000..891b2623061 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/net/ssl/HostnameVerifier.java @@ -0,0 +1,10 @@ +// Generated automatically from javax.net.ssl.HostnameVerifier for testing purposes + +package javax.net.ssl; + +import javax.net.ssl.SSLSession; + +public interface HostnameVerifier +{ + boolean verify(String p0, SSLSession p1); +} diff --git a/java/ql/test/stubs/javafx-web/javax/net/ssl/KeyManager.java b/java/ql/test/stubs/javafx-web/javax/net/ssl/KeyManager.java new file mode 100644 index 00000000000..f7333612723 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/net/ssl/KeyManager.java @@ -0,0 +1,8 @@ +// Generated automatically from javax.net.ssl.KeyManager for testing purposes + +package javax.net.ssl; + + +public interface KeyManager +{ +} diff --git a/java/ql/test/stubs/javafx-web/javax/net/ssl/SNIMatcher.java b/java/ql/test/stubs/javafx-web/javax/net/ssl/SNIMatcher.java new file mode 100644 index 00000000000..4a346519f18 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/net/ssl/SNIMatcher.java @@ -0,0 +1,13 @@ +// Generated automatically from javax.net.ssl.SNIMatcher for testing purposes + +package javax.net.ssl; + +import javax.net.ssl.SNIServerName; + +abstract public class SNIMatcher +{ + protected SNIMatcher() {} + protected SNIMatcher(int p0){} + public abstract boolean matches(SNIServerName p0); + public final int getType(){ return 0; } +} diff --git a/java/ql/test/stubs/javafx-web/javax/net/ssl/SNIServerName.java b/java/ql/test/stubs/javafx-web/javax/net/ssl/SNIServerName.java new file mode 100644 index 00000000000..119f884b2e6 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/net/ssl/SNIServerName.java @@ -0,0 +1,15 @@ +// Generated automatically from javax.net.ssl.SNIServerName for testing purposes + +package javax.net.ssl; + + +abstract public class SNIServerName +{ + protected SNIServerName() {} + protected SNIServerName(int p0, byte[] p1){} + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public final byte[] getEncoded(){ return null; } + public final int getType(){ return 0; } + public int hashCode(){ return 0; } +} diff --git a/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLContext.java b/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLContext.java new file mode 100644 index 00000000000..4bd93e3b71d --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLContext.java @@ -0,0 +1,36 @@ +// Generated automatically from javax.net.ssl.SSLContext for testing purposes + +package javax.net.ssl; + +import java.security.Provider; +import java.security.SecureRandom; +import javax.net.ssl.KeyManager; +import javax.net.ssl.SSLContextSpi; +import javax.net.ssl.SSLEngine; +import javax.net.ssl.SSLParameters; +import javax.net.ssl.SSLServerSocketFactory; +import javax.net.ssl.SSLSessionContext; +import javax.net.ssl.SSLSocketFactory; +import javax.net.ssl.TrustManager; + +public class SSLContext +{ + protected SSLContext() {} + protected SSLContext(SSLContextSpi p0, Provider p1, String p2){} + public final Provider getProvider(){ return null; } + public final SSLEngine createSSLEngine(){ return null; } + public final SSLEngine createSSLEngine(String p0, int p1){ return null; } + public final SSLParameters getDefaultSSLParameters(){ return null; } + public final SSLParameters getSupportedSSLParameters(){ return null; } + public final SSLServerSocketFactory getServerSocketFactory(){ return null; } + public final SSLSessionContext getClientSessionContext(){ return null; } + public final SSLSessionContext getServerSessionContext(){ return null; } + public final SSLSocketFactory getSocketFactory(){ return null; } + public final String getProtocol(){ return null; } + public final void init(KeyManager[] p0, TrustManager[] p1, SecureRandom p2){} + public static SSLContext getDefault(){ return null; } + public static SSLContext getInstance(String p0){ return null; } + public static SSLContext getInstance(String p0, Provider p1){ return null; } + public static SSLContext getInstance(String p0, String p1){ return null; } + public static void setDefault(SSLContext p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLContextSpi.java b/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLContextSpi.java new file mode 100644 index 00000000000..0229edd6d42 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLContextSpi.java @@ -0,0 +1,26 @@ +// Generated automatically from javax.net.ssl.SSLContextSpi for testing purposes + +package javax.net.ssl; + +import java.security.SecureRandom; +import javax.net.ssl.KeyManager; +import javax.net.ssl.SSLEngine; +import javax.net.ssl.SSLParameters; +import javax.net.ssl.SSLServerSocketFactory; +import javax.net.ssl.SSLSessionContext; +import javax.net.ssl.SSLSocketFactory; +import javax.net.ssl.TrustManager; + +abstract public class SSLContextSpi +{ + protected SSLParameters engineGetDefaultSSLParameters(){ return null; } + protected SSLParameters engineGetSupportedSSLParameters(){ return null; } + protected abstract SSLEngine engineCreateSSLEngine(); + protected abstract SSLEngine engineCreateSSLEngine(String p0, int p1); + protected abstract SSLServerSocketFactory engineGetServerSocketFactory(); + protected abstract SSLSessionContext engineGetClientSessionContext(); + protected abstract SSLSessionContext engineGetServerSessionContext(); + protected abstract SSLSocketFactory engineGetSocketFactory(); + protected abstract void engineInit(KeyManager[] p0, TrustManager[] p1, SecureRandom p2); + public SSLContextSpi(){} +} diff --git a/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLEngine.java b/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLEngine.java new file mode 100644 index 00000000000..aae661e6263 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLEngine.java @@ -0,0 +1,53 @@ +// Generated automatically from javax.net.ssl.SSLEngine for testing purposes + +package javax.net.ssl; + +import java.nio.ByteBuffer; +import java.util.List; +import java.util.function.BiFunction; +import javax.net.ssl.SSLEngineResult; +import javax.net.ssl.SSLParameters; +import javax.net.ssl.SSLSession; + +abstract public class SSLEngine +{ + protected SSLEngine(){} + protected SSLEngine(String p0, int p1){} + public BiFunction, String> getHandshakeApplicationProtocolSelector(){ return null; } + public SSLEngineResult unwrap(ByteBuffer p0, ByteBuffer p1){ return null; } + public SSLEngineResult unwrap(ByteBuffer p0, ByteBuffer[] p1){ return null; } + public SSLEngineResult wrap(ByteBuffer p0, ByteBuffer p1){ return null; } + public SSLEngineResult wrap(ByteBuffer[] p0, ByteBuffer p1){ return null; } + public SSLParameters getSSLParameters(){ return null; } + public SSLSession getHandshakeSession(){ return null; } + public String getApplicationProtocol(){ return null; } + public String getHandshakeApplicationProtocol(){ return null; } + public String getPeerHost(){ return null; } + public abstract Runnable getDelegatedTask(); + public abstract SSLEngineResult unwrap(ByteBuffer p0, ByteBuffer[] p1, int p2, int p3); + public abstract SSLEngineResult wrap(ByteBuffer[] p0, int p1, int p2, ByteBuffer p3); + public abstract SSLEngineResult.HandshakeStatus getHandshakeStatus(); + public abstract SSLSession getSession(); + public abstract String[] getEnabledCipherSuites(); + public abstract String[] getEnabledProtocols(); + public abstract String[] getSupportedCipherSuites(); + public abstract String[] getSupportedProtocols(); + public abstract boolean getEnableSessionCreation(); + public abstract boolean getNeedClientAuth(); + public abstract boolean getUseClientMode(); + public abstract boolean getWantClientAuth(); + public abstract boolean isInboundDone(); + public abstract boolean isOutboundDone(); + public abstract void beginHandshake(); + public abstract void closeInbound(); + public abstract void closeOutbound(); + public abstract void setEnableSessionCreation(boolean p0); + public abstract void setEnabledCipherSuites(String[] p0); + public abstract void setEnabledProtocols(String[] p0); + public abstract void setNeedClientAuth(boolean p0); + public abstract void setUseClientMode(boolean p0); + public abstract void setWantClientAuth(boolean p0); + public int getPeerPort(){ return 0; } + public void setHandshakeApplicationProtocolSelector(BiFunction, String> p0){} + public void setSSLParameters(SSLParameters p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLEngineResult.java b/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLEngineResult.java new file mode 100644 index 00000000000..cb8cc4ed682 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLEngineResult.java @@ -0,0 +1,27 @@ +// Generated automatically from javax.net.ssl.SSLEngineResult for testing purposes + +package javax.net.ssl; + + +public class SSLEngineResult +{ + protected SSLEngineResult() {} + public SSLEngineResult(SSLEngineResult.Status p0, SSLEngineResult.HandshakeStatus p1, int p2, int p3){} + public SSLEngineResult(SSLEngineResult.Status p0, SSLEngineResult.HandshakeStatus p1, int p2, int p3, long p4){} + public String toString(){ return null; } + public final SSLEngineResult.HandshakeStatus getHandshakeStatus(){ return null; } + public final SSLEngineResult.Status getStatus(){ return null; } + public final int bytesConsumed(){ return 0; } + public final int bytesProduced(){ return 0; } + public final long sequenceNumber(){ return 0; } + static public enum HandshakeStatus + { + FINISHED, NEED_TASK, NEED_UNWRAP, NEED_UNWRAP_AGAIN, NEED_WRAP, NOT_HANDSHAKING; + private HandshakeStatus() {} + } + static public enum Status + { + BUFFER_OVERFLOW, BUFFER_UNDERFLOW, CLOSED, OK; + private Status() {} + } +} diff --git a/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLParameters.java b/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLParameters.java new file mode 100644 index 00000000000..a586964dc6c --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLParameters.java @@ -0,0 +1,42 @@ +// Generated automatically from javax.net.ssl.SSLParameters for testing purposes + +package javax.net.ssl; + +import java.security.AlgorithmConstraints; +import java.util.Collection; +import java.util.List; +import javax.net.ssl.SNIMatcher; +import javax.net.ssl.SNIServerName; + +public class SSLParameters +{ + public AlgorithmConstraints getAlgorithmConstraints(){ return null; } + public SSLParameters(){} + public SSLParameters(String[] p0){} + public SSLParameters(String[] p0, String[] p1){} + public String getEndpointIdentificationAlgorithm(){ return null; } + public String[] getApplicationProtocols(){ return null; } + public String[] getCipherSuites(){ return null; } + public String[] getProtocols(){ return null; } + public String[] getSignatureSchemes(){ return null; } + public boolean getEnableRetransmissions(){ return false; } + public boolean getNeedClientAuth(){ return false; } + public boolean getWantClientAuth(){ return false; } + public final Collection getSNIMatchers(){ return null; } + public final List getServerNames(){ return null; } + public final boolean getUseCipherSuitesOrder(){ return false; } + public final void setSNIMatchers(Collection p0){} + public final void setServerNames(List p0){} + public final void setUseCipherSuitesOrder(boolean p0){} + public int getMaximumPacketSize(){ return 0; } + public void setAlgorithmConstraints(AlgorithmConstraints p0){} + public void setApplicationProtocols(String[] p0){} + public void setCipherSuites(String[] p0){} + public void setEnableRetransmissions(boolean p0){} + public void setEndpointIdentificationAlgorithm(String p0){} + public void setMaximumPacketSize(int p0){} + public void setNeedClientAuth(boolean p0){} + public void setProtocols(String[] p0){} + public void setSignatureSchemes(String[] p0){} + public void setWantClientAuth(boolean p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLServerSocketFactory.java b/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLServerSocketFactory.java new file mode 100644 index 00000000000..9a76e454b3d --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLServerSocketFactory.java @@ -0,0 +1,13 @@ +// Generated automatically from javax.net.ssl.SSLServerSocketFactory for testing purposes + +package javax.net.ssl; + +import javax.net.ServerSocketFactory; + +abstract public class SSLServerSocketFactory extends ServerSocketFactory +{ + protected SSLServerSocketFactory(){} + public abstract String[] getDefaultCipherSuites(); + public abstract String[] getSupportedCipherSuites(); + public static ServerSocketFactory getDefault(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLSession.java b/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLSession.java new file mode 100644 index 00000000000..293ec637b63 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLSession.java @@ -0,0 +1,33 @@ +// Generated automatically from javax.net.ssl.SSLSession for testing purposes + +package javax.net.ssl; + +import java.security.Principal; +import java.security.cert.Certificate; +import javax.net.ssl.SSLSessionContext; +import javax.security.cert.X509Certificate; + +public interface SSLSession +{ + Certificate[] getLocalCertificates(); + Certificate[] getPeerCertificates(); + Object getValue(String p0); + Principal getLocalPrincipal(); + Principal getPeerPrincipal(); + SSLSessionContext getSessionContext(); + String getCipherSuite(); + String getPeerHost(); + String getProtocol(); + String[] getValueNames(); + boolean isValid(); + byte[] getId(); + default X509Certificate[] getPeerCertificateChain(){ return null; } + int getApplicationBufferSize(); + int getPacketBufferSize(); + int getPeerPort(); + long getCreationTime(); + long getLastAccessedTime(); + void invalidate(); + void putValue(String p0, Object p1); + void removeValue(String p0); +} diff --git a/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLSessionContext.java b/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLSessionContext.java new file mode 100644 index 00000000000..c0d9c6ef650 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLSessionContext.java @@ -0,0 +1,16 @@ +// Generated automatically from javax.net.ssl.SSLSessionContext for testing purposes + +package javax.net.ssl; + +import java.util.Enumeration; +import javax.net.ssl.SSLSession; + +public interface SSLSessionContext +{ + Enumeration getIds(); + SSLSession getSession(byte[] p0); + int getSessionCacheSize(); + int getSessionTimeout(); + void setSessionCacheSize(int p0); + void setSessionTimeout(int p0); +} diff --git a/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLSocketFactory.java b/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLSocketFactory.java new file mode 100644 index 00000000000..47c40526842 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/net/ssl/SSLSocketFactory.java @@ -0,0 +1,17 @@ +// Generated automatically from javax.net.ssl.SSLSocketFactory for testing purposes + +package javax.net.ssl; + +import java.io.InputStream; +import java.net.Socket; +import javax.net.SocketFactory; + +abstract public class SSLSocketFactory extends SocketFactory +{ + public SSLSocketFactory(){} + public Socket createSocket(Socket p0, InputStream p1, boolean p2){ return null; } + public abstract Socket createSocket(Socket p0, String p1, int p2, boolean p3); + public abstract String[] getDefaultCipherSuites(); + public abstract String[] getSupportedCipherSuites(); + public static SocketFactory getDefault(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javax/net/ssl/TrustManager.java b/java/ql/test/stubs/javafx-web/javax/net/ssl/TrustManager.java new file mode 100644 index 00000000000..6698b99ac42 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/net/ssl/TrustManager.java @@ -0,0 +1,8 @@ +// Generated automatically from javax.net.ssl.TrustManager for testing purposes + +package javax.net.ssl; + + +public interface TrustManager +{ +} diff --git a/java/ql/test/stubs/javafx-web/javax/security/cert/Certificate.java b/java/ql/test/stubs/javafx-web/javax/security/cert/Certificate.java new file mode 100644 index 00000000000..56545088a1b --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/security/cert/Certificate.java @@ -0,0 +1,17 @@ +// Generated automatically from javax.security.cert.Certificate for testing purposes + +package javax.security.cert; + +import java.security.PublicKey; + +abstract public class Certificate +{ + public Certificate(){} + public abstract PublicKey getPublicKey(); + public abstract String toString(); + public abstract byte[] getEncoded(); + public abstract void verify(PublicKey p0); + public abstract void verify(PublicKey p0, String p1); + public boolean equals(Object p0){ return false; } + public int hashCode(){ return 0; } +} diff --git a/java/ql/test/stubs/javafx-web/javax/security/cert/X509Certificate.java b/java/ql/test/stubs/javafx-web/javax/security/cert/X509Certificate.java new file mode 100644 index 00000000000..1ec662982d1 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/security/cert/X509Certificate.java @@ -0,0 +1,26 @@ +// Generated automatically from javax.security.cert.X509Certificate for testing purposes + +package javax.security.cert; + +import java.io.InputStream; +import java.math.BigInteger; +import java.security.Principal; +import javax.security.cert.Certificate; + +abstract public class X509Certificate extends Certificate +{ + public X509Certificate(){} + public abstract BigInteger getSerialNumber(); + public abstract Principal getIssuerDN(); + public abstract Principal getSubjectDN(); + public abstract String getSigAlgName(); + public abstract String getSigAlgOID(); + public abstract byte[] getSigAlgParams(); + public abstract int getVersion(); + public abstract java.util.Date getNotAfter(); + public abstract java.util.Date getNotBefore(); + public abstract void checkValidity(); + public abstract void checkValidity(java.util.Date p0); + public static X509Certificate getInstance(InputStream p0){ return null; } + public static X509Certificate getInstance(byte[] p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/AsyncContext.java b/java/ql/test/stubs/javafx-web/javax/servlet/AsyncContext.java new file mode 100644 index 00000000000..70a39f55ac9 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/AsyncContext.java @@ -0,0 +1,31 @@ +// Generated automatically from javax.servlet.AsyncContext for testing purposes + +package javax.servlet; + +import javax.servlet.AsyncListener; +import javax.servlet.ServletContext; +import javax.servlet.ServletRequest; +import javax.servlet.ServletResponse; + +public interface AsyncContext +{ + T createListener(java.lang.Class p0); + ServletRequest getRequest(); + ServletResponse getResponse(); + boolean hasOriginalRequestAndResponse(); + long getTimeout(); + static String ASYNC_CONTEXT_PATH = null; + static String ASYNC_MAPPING = null; + static String ASYNC_PATH_INFO = null; + static String ASYNC_QUERY_STRING = null; + static String ASYNC_REQUEST_URI = null; + static String ASYNC_SERVLET_PATH = null; + void addListener(AsyncListener p0); + void addListener(AsyncListener p0, ServletRequest p1, ServletResponse p2); + void complete(); + void dispatch(); + void dispatch(ServletContext p0, String p1); + void dispatch(String p0); + void setTimeout(long p0); + void start(Runnable p0); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/AsyncEvent.java b/java/ql/test/stubs/javafx-web/javax/servlet/AsyncEvent.java new file mode 100644 index 00000000000..d7cb9c2b175 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/AsyncEvent.java @@ -0,0 +1,20 @@ +// Generated automatically from javax.servlet.AsyncEvent for testing purposes + +package javax.servlet; + +import javax.servlet.AsyncContext; +import javax.servlet.ServletRequest; +import javax.servlet.ServletResponse; + +public class AsyncEvent +{ + protected AsyncEvent() {} + public AsyncContext getAsyncContext(){ return null; } + public AsyncEvent(AsyncContext p0){} + public AsyncEvent(AsyncContext p0, ServletRequest p1, ServletResponse p2){} + public AsyncEvent(AsyncContext p0, ServletRequest p1, ServletResponse p2, Throwable p3){} + public AsyncEvent(AsyncContext p0, Throwable p1){} + public ServletRequest getSuppliedRequest(){ return null; } + public ServletResponse getSuppliedResponse(){ return null; } + public Throwable getThrowable(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/AsyncListener.java b/java/ql/test/stubs/javafx-web/javax/servlet/AsyncListener.java new file mode 100644 index 00000000000..2723482f668 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/AsyncListener.java @@ -0,0 +1,14 @@ +// Generated automatically from javax.servlet.AsyncListener for testing purposes + +package javax.servlet; + +import java.util.EventListener; +import javax.servlet.AsyncEvent; + +public interface AsyncListener extends EventListener +{ + void onComplete(AsyncEvent p0); + void onError(AsyncEvent p0); + void onStartAsync(AsyncEvent p0); + void onTimeout(AsyncEvent p0); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/DispatcherType.java b/java/ql/test/stubs/javafx-web/javax/servlet/DispatcherType.java new file mode 100644 index 00000000000..2b7b44f328d --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/DispatcherType.java @@ -0,0 +1,10 @@ +// Generated automatically from javax.servlet.DispatcherType for testing purposes + +package javax.servlet; + + +public enum DispatcherType +{ + ASYNC, ERROR, FORWARD, INCLUDE, REQUEST; + private DispatcherType() {} +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/Filter.java b/java/ql/test/stubs/javafx-web/javax/servlet/Filter.java new file mode 100644 index 00000000000..64b9f9d73a8 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/Filter.java @@ -0,0 +1,15 @@ +// Generated automatically from javax.servlet.Filter for testing purposes + +package javax.servlet; + +import javax.servlet.FilterChain; +import javax.servlet.FilterConfig; +import javax.servlet.ServletRequest; +import javax.servlet.ServletResponse; + +public interface Filter +{ + default void destroy(){} + default void init(FilterConfig p0){} + void doFilter(ServletRequest p0, ServletResponse p1, FilterChain p2); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/FilterChain.java b/java/ql/test/stubs/javafx-web/javax/servlet/FilterChain.java new file mode 100644 index 00000000000..f64ab722684 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/FilterChain.java @@ -0,0 +1,11 @@ +// Generated automatically from javax.servlet.FilterChain for testing purposes + +package javax.servlet; + +import javax.servlet.ServletRequest; +import javax.servlet.ServletResponse; + +public interface FilterChain +{ + void doFilter(ServletRequest p0, ServletResponse p1); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/FilterConfig.java b/java/ql/test/stubs/javafx-web/javax/servlet/FilterConfig.java new file mode 100644 index 00000000000..0e140c6680c --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/FilterConfig.java @@ -0,0 +1,14 @@ +// Generated automatically from javax.servlet.FilterConfig for testing purposes + +package javax.servlet; + +import java.util.Enumeration; +import javax.servlet.ServletContext; + +public interface FilterConfig +{ + Enumeration getInitParameterNames(); + ServletContext getServletContext(); + String getFilterName(); + String getInitParameter(String p0); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/FilterRegistration.java b/java/ql/test/stubs/javafx-web/javax/servlet/FilterRegistration.java new file mode 100644 index 00000000000..6ad0739ceb6 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/FilterRegistration.java @@ -0,0 +1,19 @@ +// Generated automatically from javax.servlet.FilterRegistration for testing purposes + +package javax.servlet; + +import java.util.Collection; +import java.util.EnumSet; +import javax.servlet.DispatcherType; +import javax.servlet.Registration; + +public interface FilterRegistration extends Registration +{ + Collection getServletNameMappings(); + Collection getUrlPatternMappings(); + static public interface Dynamic extends FilterRegistration, Registration.Dynamic + { + } + void addMappingForServletNames(EnumSet p0, boolean p1, String... p2); + void addMappingForUrlPatterns(EnumSet p0, boolean p1, String... p2); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/GenericServlet.java b/java/ql/test/stubs/javafx-web/javax/servlet/GenericServlet.java new file mode 100644 index 00000000000..5f7bdcda487 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/GenericServlet.java @@ -0,0 +1,28 @@ +// Generated automatically from javax.servlet.GenericServlet for testing purposes + +package javax.servlet; + +import java.io.Serializable; +import java.util.Enumeration; +import javax.servlet.Servlet; +import javax.servlet.ServletConfig; +import javax.servlet.ServletContext; +import javax.servlet.ServletRequest; +import javax.servlet.ServletResponse; + +abstract public class GenericServlet implements Serializable, Servlet, ServletConfig +{ + public Enumeration getInitParameterNames(){ return null; } + public GenericServlet(){} + public ServletConfig getServletConfig(){ return null; } + public ServletContext getServletContext(){ return null; } + public String getInitParameter(String p0){ return null; } + public String getServletInfo(){ return null; } + public String getServletName(){ return null; } + public abstract void service(ServletRequest p0, ServletResponse p1); + public void destroy(){} + public void init(){} + public void init(ServletConfig p0){} + public void log(String p0){} + public void log(String p0, Throwable p1){} +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/HttpConstraintElement.java b/java/ql/test/stubs/javafx-web/javax/servlet/HttpConstraintElement.java new file mode 100644 index 00000000000..6598aa47cc5 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/HttpConstraintElement.java @@ -0,0 +1,16 @@ +// Generated automatically from javax.servlet.HttpConstraintElement for testing purposes + +package javax.servlet; + +import javax.servlet.annotation.ServletSecurity; + +public class HttpConstraintElement +{ + public HttpConstraintElement(){} + public HttpConstraintElement(ServletSecurity.EmptyRoleSemantic p0){} + public HttpConstraintElement(ServletSecurity.EmptyRoleSemantic p0, ServletSecurity.TransportGuarantee p1, String... p2){} + public HttpConstraintElement(ServletSecurity.TransportGuarantee p0, String... p1){} + public ServletSecurity.EmptyRoleSemantic getEmptyRoleSemantic(){ return null; } + public ServletSecurity.TransportGuarantee getTransportGuarantee(){ return null; } + public String[] getRolesAllowed(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/HttpMethodConstraintElement.java b/java/ql/test/stubs/javafx-web/javax/servlet/HttpMethodConstraintElement.java new file mode 100644 index 00000000000..ddb52527004 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/HttpMethodConstraintElement.java @@ -0,0 +1,13 @@ +// Generated automatically from javax.servlet.HttpMethodConstraintElement for testing purposes + +package javax.servlet; + +import javax.servlet.HttpConstraintElement; + +public class HttpMethodConstraintElement extends HttpConstraintElement +{ + protected HttpMethodConstraintElement() {} + public HttpMethodConstraintElement(String p0){} + public HttpMethodConstraintElement(String p0, HttpConstraintElement p1){} + public String getMethodName(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/MultipartConfigElement.java b/java/ql/test/stubs/javafx-web/javax/servlet/MultipartConfigElement.java new file mode 100644 index 00000000000..8470d9a5317 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/MultipartConfigElement.java @@ -0,0 +1,17 @@ +// Generated automatically from javax.servlet.MultipartConfigElement for testing purposes + +package javax.servlet; + +import javax.servlet.annotation.MultipartConfig; + +public class MultipartConfigElement +{ + protected MultipartConfigElement() {} + public MultipartConfigElement(MultipartConfig p0){} + public MultipartConfigElement(String p0){} + public MultipartConfigElement(String p0, long p1, long p2, int p3){} + public String getLocation(){ return null; } + public int getFileSizeThreshold(){ return 0; } + public long getMaxFileSize(){ return 0; } + public long getMaxRequestSize(){ return 0; } +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/ReadListener.java b/java/ql/test/stubs/javafx-web/javax/servlet/ReadListener.java new file mode 100644 index 00000000000..367594ef7da --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/ReadListener.java @@ -0,0 +1,12 @@ +// Generated automatically from javax.servlet.ReadListener for testing purposes + +package javax.servlet; + +import java.util.EventListener; + +public interface ReadListener extends EventListener +{ + void onAllDataRead(); + void onDataAvailable(); + void onError(Throwable p0); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/Registration.java b/java/ql/test/stubs/javafx-web/javax/servlet/Registration.java new file mode 100644 index 00000000000..5d4095813ef --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/Registration.java @@ -0,0 +1,20 @@ +// Generated automatically from javax.servlet.Registration for testing purposes + +package javax.servlet; + +import java.util.Map; +import java.util.Set; + +public interface Registration +{ + Map getInitParameters(); + Set setInitParameters(Map p0); + String getClassName(); + String getInitParameter(String p0); + String getName(); + boolean setInitParameter(String p0, String p1); + static public interface Dynamic extends Registration + { + void setAsyncSupported(boolean p0); + } +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/RequestDispatcher.java b/java/ql/test/stubs/javafx-web/javax/servlet/RequestDispatcher.java new file mode 100644 index 00000000000..ad017e4f501 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/RequestDispatcher.java @@ -0,0 +1,30 @@ +// Generated automatically from javax.servlet.RequestDispatcher for testing purposes + +package javax.servlet; + +import javax.servlet.ServletRequest; +import javax.servlet.ServletResponse; + +public interface RequestDispatcher +{ + static String ERROR_EXCEPTION = null; + static String ERROR_EXCEPTION_TYPE = null; + static String ERROR_MESSAGE = null; + static String ERROR_REQUEST_URI = null; + static String ERROR_SERVLET_NAME = null; + static String ERROR_STATUS_CODE = null; + static String FORWARD_CONTEXT_PATH = null; + static String FORWARD_MAPPING = null; + static String FORWARD_PATH_INFO = null; + static String FORWARD_QUERY_STRING = null; + static String FORWARD_REQUEST_URI = null; + static String FORWARD_SERVLET_PATH = null; + static String INCLUDE_CONTEXT_PATH = null; + static String INCLUDE_MAPPING = null; + static String INCLUDE_PATH_INFO = null; + static String INCLUDE_QUERY_STRING = null; + static String INCLUDE_REQUEST_URI = null; + static String INCLUDE_SERVLET_PATH = null; + void forward(ServletRequest p0, ServletResponse p1); + void include(ServletRequest p0, ServletResponse p1); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/Servlet.java b/java/ql/test/stubs/javafx-web/javax/servlet/Servlet.java new file mode 100644 index 00000000000..231c011a6f8 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/Servlet.java @@ -0,0 +1,16 @@ +// Generated automatically from javax.servlet.Servlet for testing purposes + +package javax.servlet; + +import javax.servlet.ServletConfig; +import javax.servlet.ServletRequest; +import javax.servlet.ServletResponse; + +public interface Servlet +{ + ServletConfig getServletConfig(); + String getServletInfo(); + void destroy(); + void init(ServletConfig p0); + void service(ServletRequest p0, ServletResponse p1); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/ServletConfig.java b/java/ql/test/stubs/javafx-web/javax/servlet/ServletConfig.java new file mode 100644 index 00000000000..c483c16ac4e --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/ServletConfig.java @@ -0,0 +1,14 @@ +// Generated automatically from javax.servlet.ServletConfig for testing purposes + +package javax.servlet; + +import java.util.Enumeration; +import javax.servlet.ServletContext; + +public interface ServletConfig +{ + Enumeration getInitParameterNames(); + ServletContext getServletContext(); + String getInitParameter(String p0); + String getServletName(); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/ServletContext.java b/java/ql/test/stubs/javafx-web/javax/servlet/ServletContext.java new file mode 100644 index 00000000000..812393f61e9 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/ServletContext.java @@ -0,0 +1,83 @@ +// Generated automatically from javax.servlet.ServletContext for testing purposes + +package javax.servlet; + +import java.io.InputStream; +import java.net.URL; +import java.util.Enumeration; +import java.util.EventListener; +import java.util.Map; +import java.util.Set; +import javax.servlet.Filter; +import javax.servlet.FilterRegistration; +import javax.servlet.RequestDispatcher; +import javax.servlet.Servlet; +import javax.servlet.ServletRegistration; +import javax.servlet.SessionCookieConfig; +import javax.servlet.SessionTrackingMode; +import javax.servlet.descriptor.JspConfigDescriptor; + +public interface ServletContext +{ + T createListener(java.lang.Class p0); + void addListener(T p0); + T createFilter(java.lang.Class p0); + T createServlet(java.lang.Class p0); + ClassLoader getClassLoader(); + Enumeration getServlets(); + Enumeration getAttributeNames(); + Enumeration getInitParameterNames(); + Enumeration getServletNames(); + FilterRegistration getFilterRegistration(String p0); + FilterRegistration.Dynamic addFilter(String p0, Class p1); + FilterRegistration.Dynamic addFilter(String p0, Filter p1); + FilterRegistration.Dynamic addFilter(String p0, String p1); + InputStream getResourceAsStream(String p0); + JspConfigDescriptor getJspConfigDescriptor(); + Map getFilterRegistrations(); + Map getServletRegistrations(); + Object getAttribute(String p0); + RequestDispatcher getNamedDispatcher(String p0); + RequestDispatcher getRequestDispatcher(String p0); + Servlet getServlet(String p0); + ServletContext getContext(String p0); + ServletRegistration getServletRegistration(String p0); + ServletRegistration.Dynamic addJspFile(String p0, String p1); + ServletRegistration.Dynamic addServlet(String p0, Class p1); + ServletRegistration.Dynamic addServlet(String p0, Servlet p1); + ServletRegistration.Dynamic addServlet(String p0, String p1); + SessionCookieConfig getSessionCookieConfig(); + Set getDefaultSessionTrackingModes(); + Set getEffectiveSessionTrackingModes(); + Set getResourcePaths(String p0); + String getContextPath(); + String getInitParameter(String p0); + String getMimeType(String p0); + String getRealPath(String p0); + String getRequestCharacterEncoding(); + String getResponseCharacterEncoding(); + String getServerInfo(); + String getServletContextName(); + String getVirtualServerName(); + URL getResource(String p0); + boolean setInitParameter(String p0, String p1); + int getEffectiveMajorVersion(); + int getEffectiveMinorVersion(); + int getMajorVersion(); + int getMinorVersion(); + int getSessionTimeout(); + static String ORDERED_LIBS = null; + static String TEMPDIR = null; + void addListener(Class p0); + void addListener(String p0); + void declareRoles(String... p0); + void log(Exception p0, String p1); + void log(String p0); + void log(String p0, Throwable p1); + void removeAttribute(String p0); + void setAttribute(String p0, Object p1); + void setRequestCharacterEncoding(String p0); + void setResponseCharacterEncoding(String p0); + void setSessionTimeout(int p0); + void setSessionTrackingModes(Set p0); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/ServletInputStream.java b/java/ql/test/stubs/javafx-web/javax/servlet/ServletInputStream.java new file mode 100644 index 00000000000..31034066970 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/ServletInputStream.java @@ -0,0 +1,15 @@ +// Generated automatically from javax.servlet.ServletInputStream for testing purposes + +package javax.servlet; + +import java.io.InputStream; +import javax.servlet.ReadListener; + +abstract public class ServletInputStream extends InputStream +{ + protected ServletInputStream(){} + public abstract boolean isFinished(); + public abstract boolean isReady(); + public abstract void setReadListener(ReadListener p0); + public int readLine(byte[] p0, int p1, int p2){ return 0; } +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/ServletOutputStream.java b/java/ql/test/stubs/javafx-web/javax/servlet/ServletOutputStream.java new file mode 100644 index 00000000000..52a2162c9eb --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/ServletOutputStream.java @@ -0,0 +1,28 @@ +// Generated automatically from javax.servlet.ServletOutputStream for testing purposes + +package javax.servlet; + +import java.io.OutputStream; +import javax.servlet.WriteListener; + +abstract public class ServletOutputStream extends OutputStream +{ + protected ServletOutputStream(){} + public abstract boolean isReady(); + public abstract void setWriteListener(WriteListener p0); + public void print(String p0){} + public void print(boolean p0){} + public void print(char p0){} + public void print(double p0){} + public void print(float p0){} + public void print(int p0){} + public void print(long p0){} + public void println(){} + public void println(String p0){} + public void println(boolean p0){} + public void println(char p0){} + public void println(double p0){} + public void println(float p0){} + public void println(int p0){} + public void println(long p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/ServletRegistration.java b/java/ql/test/stubs/javafx-web/javax/servlet/ServletRegistration.java new file mode 100644 index 00000000000..a1cc66f2d19 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/ServletRegistration.java @@ -0,0 +1,23 @@ +// Generated automatically from javax.servlet.ServletRegistration for testing purposes + +package javax.servlet; + +import java.util.Collection; +import java.util.Set; +import javax.servlet.MultipartConfigElement; +import javax.servlet.Registration; +import javax.servlet.ServletSecurityElement; + +public interface ServletRegistration extends Registration +{ + Collection getMappings(); + Set addMapping(String... p0); + String getRunAsRole(); + static public interface Dynamic extends Registration.Dynamic, ServletRegistration + { + Set setServletSecurity(ServletSecurityElement p0); + void setLoadOnStartup(int p0); + void setMultipartConfig(MultipartConfigElement p0); + void setRunAsRole(String p0); + } +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/ServletRequest.java b/java/ql/test/stubs/javafx-web/javax/servlet/ServletRequest.java new file mode 100644 index 00000000000..fc0db462cc0 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/ServletRequest.java @@ -0,0 +1,55 @@ +// Generated automatically from javax.servlet.ServletRequest for testing purposes + +package javax.servlet; + +import java.io.BufferedReader; +import java.util.Enumeration; +import java.util.Locale; +import java.util.Map; +import javax.servlet.AsyncContext; +import javax.servlet.DispatcherType; +import javax.servlet.RequestDispatcher; +import javax.servlet.ServletContext; +import javax.servlet.ServletInputStream; +import javax.servlet.ServletResponse; + +public interface ServletRequest +{ + AsyncContext getAsyncContext(); + AsyncContext startAsync(); + AsyncContext startAsync(ServletRequest p0, ServletResponse p1); + BufferedReader getReader(); + DispatcherType getDispatcherType(); + Enumeration getLocales(); + Enumeration getAttributeNames(); + Enumeration getParameterNames(); + Locale getLocale(); + Map getParameterMap(); + Object getAttribute(String p0); + RequestDispatcher getRequestDispatcher(String p0); + ServletContext getServletContext(); + ServletInputStream getInputStream(); + String getCharacterEncoding(); + String getContentType(); + String getLocalAddr(); + String getLocalName(); + String getParameter(String p0); + String getProtocol(); + String getRealPath(String p0); + String getRemoteAddr(); + String getRemoteHost(); + String getScheme(); + String getServerName(); + String[] getParameterValues(String p0); + boolean isAsyncStarted(); + boolean isAsyncSupported(); + boolean isSecure(); + int getContentLength(); + int getLocalPort(); + int getRemotePort(); + int getServerPort(); + long getContentLengthLong(); + void removeAttribute(String p0); + void setAttribute(String p0, Object p1); + void setCharacterEncoding(String p0); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/ServletResponse.java b/java/ql/test/stubs/javafx-web/javax/servlet/ServletResponse.java new file mode 100644 index 00000000000..db6610bc15d --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/ServletResponse.java @@ -0,0 +1,27 @@ +// Generated automatically from javax.servlet.ServletResponse for testing purposes + +package javax.servlet; + +import java.io.PrintWriter; +import java.util.Locale; +import javax.servlet.ServletOutputStream; + +public interface ServletResponse +{ + Locale getLocale(); + PrintWriter getWriter(); + ServletOutputStream getOutputStream(); + String getCharacterEncoding(); + String getContentType(); + boolean isCommitted(); + int getBufferSize(); + void flushBuffer(); + void reset(); + void resetBuffer(); + void setBufferSize(int p0); + void setCharacterEncoding(String p0); + void setContentLength(int p0); + void setContentLengthLong(long p0); + void setContentType(String p0); + void setLocale(Locale p0); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/ServletSecurityElement.java b/java/ql/test/stubs/javafx-web/javax/servlet/ServletSecurityElement.java new file mode 100644 index 00000000000..def47937391 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/ServletSecurityElement.java @@ -0,0 +1,19 @@ +// Generated automatically from javax.servlet.ServletSecurityElement for testing purposes + +package javax.servlet; + +import java.util.Collection; +import javax.servlet.HttpConstraintElement; +import javax.servlet.HttpMethodConstraintElement; +import javax.servlet.annotation.ServletSecurity; + +public class ServletSecurityElement extends HttpConstraintElement +{ + public Collection getHttpMethodConstraints(){ return null; } + public Collection getMethodNames(){ return null; } + public ServletSecurityElement(){} + public ServletSecurityElement(Collection p0){} + public ServletSecurityElement(HttpConstraintElement p0){} + public ServletSecurityElement(HttpConstraintElement p0, Collection p1){} + public ServletSecurityElement(ServletSecurity p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/SessionCookieConfig.java b/java/ql/test/stubs/javafx-web/javax/servlet/SessionCookieConfig.java new file mode 100644 index 00000000000..4cae9a11f30 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/SessionCookieConfig.java @@ -0,0 +1,22 @@ +// Generated automatically from javax.servlet.SessionCookieConfig for testing purposes + +package javax.servlet; + + +public interface SessionCookieConfig +{ + String getComment(); + String getDomain(); + String getName(); + String getPath(); + boolean isHttpOnly(); + boolean isSecure(); + int getMaxAge(); + void setComment(String p0); + void setDomain(String p0); + void setHttpOnly(boolean p0); + void setMaxAge(int p0); + void setName(String p0); + void setPath(String p0); + void setSecure(boolean p0); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/SessionTrackingMode.java b/java/ql/test/stubs/javafx-web/javax/servlet/SessionTrackingMode.java new file mode 100644 index 00000000000..684ac40c56f --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/SessionTrackingMode.java @@ -0,0 +1,10 @@ +// Generated automatically from javax.servlet.SessionTrackingMode for testing purposes + +package javax.servlet; + + +public enum SessionTrackingMode +{ + COOKIE, SSL, URL; + private SessionTrackingMode() {} +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/WriteListener.java b/java/ql/test/stubs/javafx-web/javax/servlet/WriteListener.java new file mode 100644 index 00000000000..24fe504271c --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/WriteListener.java @@ -0,0 +1,11 @@ +// Generated automatically from javax.servlet.WriteListener for testing purposes + +package javax.servlet; + +import java.util.EventListener; + +public interface WriteListener extends EventListener +{ + void onError(Throwable p0); + void onWritePossible(); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/annotation/HttpConstraint.java b/java/ql/test/stubs/javafx-web/javax/servlet/annotation/HttpConstraint.java new file mode 100644 index 00000000000..f47efc62744 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/annotation/HttpConstraint.java @@ -0,0 +1,18 @@ +// Generated automatically from javax.servlet.annotation.HttpConstraint for testing purposes + +package javax.servlet.annotation; + +import java.lang.annotation.Annotation; +import java.lang.annotation.Documented; +import java.lang.annotation.Retention; +import java.lang.annotation.RetentionPolicy; +import javax.servlet.annotation.ServletSecurity; + +@Documented +@Retention(value=java.lang.annotation.RetentionPolicy.RUNTIME) +public @interface HttpConstraint +{ + ServletSecurity.EmptyRoleSemantic value(); + ServletSecurity.TransportGuarantee transportGuarantee(); + String[] rolesAllowed(); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/annotation/HttpMethodConstraint.java b/java/ql/test/stubs/javafx-web/javax/servlet/annotation/HttpMethodConstraint.java new file mode 100644 index 00000000000..288f4651018 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/annotation/HttpMethodConstraint.java @@ -0,0 +1,19 @@ +// Generated automatically from javax.servlet.annotation.HttpMethodConstraint for testing purposes + +package javax.servlet.annotation; + +import java.lang.annotation.Annotation; +import java.lang.annotation.Documented; +import java.lang.annotation.Retention; +import java.lang.annotation.RetentionPolicy; +import javax.servlet.annotation.ServletSecurity; + +@Documented +@Retention(value=java.lang.annotation.RetentionPolicy.RUNTIME) +public @interface HttpMethodConstraint +{ + ServletSecurity.EmptyRoleSemantic emptyRoleSemantic(); + ServletSecurity.TransportGuarantee transportGuarantee(); + String value(); + String[] rolesAllowed(); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/annotation/MultipartConfig.java b/java/ql/test/stubs/javafx-web/javax/servlet/annotation/MultipartConfig.java new file mode 100644 index 00000000000..baccad3e199 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/annotation/MultipartConfig.java @@ -0,0 +1,19 @@ +// Generated automatically from javax.servlet.annotation.MultipartConfig for testing purposes + +package javax.servlet.annotation; + +import java.lang.annotation.Annotation; +import java.lang.annotation.ElementType; +import java.lang.annotation.Retention; +import java.lang.annotation.RetentionPolicy; +import java.lang.annotation.Target; + +@Retention(value=java.lang.annotation.RetentionPolicy.RUNTIME) +@Target(value={java.lang.annotation.ElementType.TYPE}) +public @interface MultipartConfig +{ + String location(); + int fileSizeThreshold(); + long maxFileSize(); + long maxRequestSize(); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/annotation/ServletSecurity.java b/java/ql/test/stubs/javafx-web/javax/servlet/annotation/ServletSecurity.java new file mode 100644 index 00000000000..021b6c64c2a --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/annotation/ServletSecurity.java @@ -0,0 +1,33 @@ +// Generated automatically from javax.servlet.annotation.ServletSecurity for testing purposes + +package javax.servlet.annotation; + +import java.lang.annotation.Annotation; +import java.lang.annotation.Documented; +import java.lang.annotation.ElementType; +import java.lang.annotation.Inherited; +import java.lang.annotation.Retention; +import java.lang.annotation.RetentionPolicy; +import java.lang.annotation.Target; +import javax.servlet.annotation.HttpConstraint; +import javax.servlet.annotation.HttpMethodConstraint; + +@Documented +@Inherited +@Retention(value=java.lang.annotation.RetentionPolicy.RUNTIME) +@Target(value={java.lang.annotation.ElementType.TYPE}) +public @interface ServletSecurity +{ + HttpConstraint value(); + HttpMethodConstraint[] httpMethodConstraints(); + static public enum EmptyRoleSemantic + { + DENY, PERMIT; + private EmptyRoleSemantic() {} + } + static public enum TransportGuarantee + { + CONFIDENTIAL, NONE; + private TransportGuarantee() {} + } +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/descriptor/JspConfigDescriptor.java b/java/ql/test/stubs/javafx-web/javax/servlet/descriptor/JspConfigDescriptor.java new file mode 100644 index 00000000000..8d93a4318d7 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/descriptor/JspConfigDescriptor.java @@ -0,0 +1,13 @@ +// Generated automatically from javax.servlet.descriptor.JspConfigDescriptor for testing purposes + +package javax.servlet.descriptor; + +import java.util.Collection; +import javax.servlet.descriptor.JspPropertyGroupDescriptor; +import javax.servlet.descriptor.TaglibDescriptor; + +public interface JspConfigDescriptor +{ + Collection getJspPropertyGroups(); + Collection getTaglibs(); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/descriptor/JspPropertyGroupDescriptor.java b/java/ql/test/stubs/javafx-web/javax/servlet/descriptor/JspPropertyGroupDescriptor.java new file mode 100644 index 00000000000..dd852fa1088 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/descriptor/JspPropertyGroupDescriptor.java @@ -0,0 +1,21 @@ +// Generated automatically from javax.servlet.descriptor.JspPropertyGroupDescriptor for testing purposes + +package javax.servlet.descriptor; + +import java.util.Collection; + +public interface JspPropertyGroupDescriptor +{ + Collection getIncludeCodas(); + Collection getIncludePreludes(); + Collection getUrlPatterns(); + String getBuffer(); + String getDefaultContentType(); + String getDeferredSyntaxAllowedAsLiteral(); + String getElIgnored(); + String getErrorOnUndeclaredNamespace(); + String getIsXml(); + String getPageEncoding(); + String getScriptingInvalid(); + String getTrimDirectiveWhitespaces(); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/descriptor/TaglibDescriptor.java b/java/ql/test/stubs/javafx-web/javax/servlet/descriptor/TaglibDescriptor.java new file mode 100644 index 00000000000..c3dd5c10473 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/descriptor/TaglibDescriptor.java @@ -0,0 +1,10 @@ +// Generated automatically from javax.servlet.descriptor.TaglibDescriptor for testing purposes + +package javax.servlet.descriptor; + + +public interface TaglibDescriptor +{ + String getTaglibLocation(); + String getTaglibURI(); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/http/Cookie.java b/java/ql/test/stubs/javafx-web/javax/servlet/http/Cookie.java new file mode 100644 index 00000000000..b5a180029be --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/http/Cookie.java @@ -0,0 +1,29 @@ +// Generated automatically from javax.servlet.http.Cookie for testing purposes + +package javax.servlet.http; + +import java.io.Serializable; + +public class Cookie implements Cloneable, Serializable +{ + protected Cookie() {} + public Cookie(String p0, String p1){} + public Object clone(){ return null; } + public String getComment(){ return null; } + public String getDomain(){ return null; } + public String getName(){ return null; } + public String getPath(){ return null; } + public String getValue(){ return null; } + public boolean getSecure(){ return false; } + public boolean isHttpOnly(){ return false; } + public int getMaxAge(){ return 0; } + public int getVersion(){ return 0; } + public void setComment(String p0){} + public void setDomain(String p0){} + public void setHttpOnly(boolean p0){} + public void setMaxAge(int p0){} + public void setPath(String p0){} + public void setSecure(boolean p0){} + public void setValue(String p0){} + public void setVersion(int p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/http/HttpServlet.java b/java/ql/test/stubs/javafx-web/javax/servlet/http/HttpServlet.java new file mode 100644 index 00000000000..1247f956d78 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/http/HttpServlet.java @@ -0,0 +1,24 @@ +// Generated automatically from javax.servlet.http.HttpServlet for testing purposes + +package javax.servlet.http; + +import javax.servlet.GenericServlet; +import javax.servlet.ServletRequest; +import javax.servlet.ServletResponse; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; + +abstract public class HttpServlet extends GenericServlet +{ + protected long getLastModified(HttpServletRequest p0){ return 0; } + protected void doDelete(HttpServletRequest p0, HttpServletResponse p1){} + protected void doGet(HttpServletRequest p0, HttpServletResponse p1){} + protected void doHead(HttpServletRequest p0, HttpServletResponse p1){} + protected void doOptions(HttpServletRequest p0, HttpServletResponse p1){} + protected void doPost(HttpServletRequest p0, HttpServletResponse p1){} + protected void doPut(HttpServletRequest p0, HttpServletResponse p1){} + protected void doTrace(HttpServletRequest p0, HttpServletResponse p1){} + protected void service(HttpServletRequest p0, HttpServletResponse p1){} + public HttpServlet(){} + public void service(ServletRequest p0, ServletResponse p1){} +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/http/HttpServletMapping.java b/java/ql/test/stubs/javafx-web/javax/servlet/http/HttpServletMapping.java new file mode 100644 index 00000000000..1b597f27773 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/http/HttpServletMapping.java @@ -0,0 +1,13 @@ +// Generated automatically from javax.servlet.http.HttpServletMapping for testing purposes + +package javax.servlet.http; + +import javax.servlet.http.MappingMatch; + +public interface HttpServletMapping +{ + MappingMatch getMappingMatch(); + String getMatchValue(); + String getPattern(); + String getServletName(); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/http/HttpServletRequest.java b/java/ql/test/stubs/javafx-web/javax/servlet/http/HttpServletRequest.java new file mode 100644 index 00000000000..8612c34fb69 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/http/HttpServletRequest.java @@ -0,0 +1,60 @@ +// Generated automatically from javax.servlet.http.HttpServletRequest for testing purposes + +package javax.servlet.http; + +import java.security.Principal; +import java.util.Collection; +import java.util.Enumeration; +import java.util.Map; +import javax.servlet.ServletRequest; +import javax.servlet.http.Cookie; +import javax.servlet.http.HttpServletMapping; +import javax.servlet.http.HttpServletResponse; +import javax.servlet.http.HttpSession; +import javax.servlet.http.HttpUpgradeHandler; +import javax.servlet.http.Part; +import javax.servlet.http.PushBuilder; + +public interface HttpServletRequest extends ServletRequest +{ + T upgrade(java.lang.Class p0); + Collection getParts(); + Cookie[] getCookies(); + Enumeration getHeaderNames(); + Enumeration getHeaders(String p0); + HttpSession getSession(); + HttpSession getSession(boolean p0); + Part getPart(String p0); + Principal getUserPrincipal(); + String changeSessionId(); + String getAuthType(); + String getContextPath(); + String getHeader(String p0); + String getMethod(); + String getPathInfo(); + String getPathTranslated(); + String getQueryString(); + String getRemoteUser(); + String getRequestURI(); + String getRequestedSessionId(); + String getServletPath(); + StringBuffer getRequestURL(); + boolean authenticate(HttpServletResponse p0); + boolean isRequestedSessionIdFromCookie(); + boolean isRequestedSessionIdFromURL(); + boolean isRequestedSessionIdFromUrl(); + boolean isRequestedSessionIdValid(); + boolean isUserInRole(String p0); + default HttpServletMapping getHttpServletMapping(){ return null; } + default Map getTrailerFields(){ return null; } + default PushBuilder newPushBuilder(){ return null; } + default boolean isTrailerFieldsReady(){ return false; } + int getIntHeader(String p0); + long getDateHeader(String p0); + static String BASIC_AUTH = null; + static String CLIENT_CERT_AUTH = null; + static String DIGEST_AUTH = null; + static String FORM_AUTH = null; + void login(String p0, String p1); + void logout(); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/http/HttpServletResponse.java b/java/ql/test/stubs/javafx-web/javax/servlet/http/HttpServletResponse.java new file mode 100644 index 00000000000..da902dbf30c --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/http/HttpServletResponse.java @@ -0,0 +1,77 @@ +// Generated automatically from javax.servlet.http.HttpServletResponse for testing purposes + +package javax.servlet.http; + +import java.util.Collection; +import java.util.Map; +import java.util.function.Supplier; +import javax.servlet.ServletResponse; +import javax.servlet.http.Cookie; + +public interface HttpServletResponse extends ServletResponse +{ + Collection getHeaderNames(); + Collection getHeaders(String p0); + String encodeRedirectURL(String p0); + String encodeRedirectUrl(String p0); + String encodeURL(String p0); + String encodeUrl(String p0); + String getHeader(String p0); + boolean containsHeader(String p0); + default Supplier> getTrailerFields(){ return null; } + default void setTrailerFields(Supplier> p0){} + int getStatus(); + static int SC_ACCEPTED = 0; + static int SC_BAD_GATEWAY = 0; + static int SC_BAD_REQUEST = 0; + static int SC_CONFLICT = 0; + static int SC_CONTINUE = 0; + static int SC_CREATED = 0; + static int SC_EXPECTATION_FAILED = 0; + static int SC_FORBIDDEN = 0; + static int SC_FOUND = 0; + static int SC_GATEWAY_TIMEOUT = 0; + static int SC_GONE = 0; + static int SC_HTTP_VERSION_NOT_SUPPORTED = 0; + static int SC_INTERNAL_SERVER_ERROR = 0; + static int SC_LENGTH_REQUIRED = 0; + static int SC_METHOD_NOT_ALLOWED = 0; + static int SC_MOVED_PERMANENTLY = 0; + static int SC_MOVED_TEMPORARILY = 0; + static int SC_MULTIPLE_CHOICES = 0; + static int SC_NON_AUTHORITATIVE_INFORMATION = 0; + static int SC_NOT_ACCEPTABLE = 0; + static int SC_NOT_FOUND = 0; + static int SC_NOT_IMPLEMENTED = 0; + static int SC_NOT_MODIFIED = 0; + static int SC_NO_CONTENT = 0; + static int SC_OK = 0; + static int SC_PARTIAL_CONTENT = 0; + static int SC_PAYMENT_REQUIRED = 0; + static int SC_PRECONDITION_FAILED = 0; + static int SC_PROXY_AUTHENTICATION_REQUIRED = 0; + static int SC_REQUESTED_RANGE_NOT_SATISFIABLE = 0; + static int SC_REQUEST_ENTITY_TOO_LARGE = 0; + static int SC_REQUEST_TIMEOUT = 0; + static int SC_REQUEST_URI_TOO_LONG = 0; + static int SC_RESET_CONTENT = 0; + static int SC_SEE_OTHER = 0; + static int SC_SERVICE_UNAVAILABLE = 0; + static int SC_SWITCHING_PROTOCOLS = 0; + static int SC_TEMPORARY_REDIRECT = 0; + static int SC_UNAUTHORIZED = 0; + static int SC_UNSUPPORTED_MEDIA_TYPE = 0; + static int SC_USE_PROXY = 0; + void addCookie(Cookie p0); + void addDateHeader(String p0, long p1); + void addHeader(String p0, String p1); + void addIntHeader(String p0, int p1); + void sendError(int p0); + void sendError(int p0, String p1); + void sendRedirect(String p0); + void setDateHeader(String p0, long p1); + void setHeader(String p0, String p1); + void setIntHeader(String p0, int p1); + void setStatus(int p0); + void setStatus(int p0, String p1); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/http/HttpSession.java b/java/ql/test/stubs/javafx-web/javax/servlet/http/HttpSession.java new file mode 100644 index 00000000000..f8f455b1423 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/http/HttpSession.java @@ -0,0 +1,28 @@ +// Generated automatically from javax.servlet.http.HttpSession for testing purposes + +package javax.servlet.http; + +import java.util.Enumeration; +import javax.servlet.ServletContext; +import javax.servlet.http.HttpSessionContext; + +public interface HttpSession +{ + Enumeration getAttributeNames(); + HttpSessionContext getSessionContext(); + Object getAttribute(String p0); + Object getValue(String p0); + ServletContext getServletContext(); + String getId(); + String[] getValueNames(); + boolean isNew(); + int getMaxInactiveInterval(); + long getCreationTime(); + long getLastAccessedTime(); + void invalidate(); + void putValue(String p0, Object p1); + void removeAttribute(String p0); + void removeValue(String p0); + void setAttribute(String p0, Object p1); + void setMaxInactiveInterval(int p0); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/http/HttpSessionContext.java b/java/ql/test/stubs/javafx-web/javax/servlet/http/HttpSessionContext.java new file mode 100644 index 00000000000..97a77b48358 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/http/HttpSessionContext.java @@ -0,0 +1,12 @@ +// Generated automatically from javax.servlet.http.HttpSessionContext for testing purposes + +package javax.servlet.http; + +import java.util.Enumeration; +import javax.servlet.http.HttpSession; + +public interface HttpSessionContext +{ + Enumeration getIds(); + HttpSession getSession(String p0); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/http/HttpUpgradeHandler.java b/java/ql/test/stubs/javafx-web/javax/servlet/http/HttpUpgradeHandler.java new file mode 100644 index 00000000000..987d49dbde2 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/http/HttpUpgradeHandler.java @@ -0,0 +1,11 @@ +// Generated automatically from javax.servlet.http.HttpUpgradeHandler for testing purposes + +package javax.servlet.http; + +import javax.servlet.http.WebConnection; + +public interface HttpUpgradeHandler +{ + void destroy(); + void init(WebConnection p0); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/http/MappingMatch.java b/java/ql/test/stubs/javafx-web/javax/servlet/http/MappingMatch.java new file mode 100644 index 00000000000..0432fd2ef7d --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/http/MappingMatch.java @@ -0,0 +1,10 @@ +// Generated automatically from javax.servlet.http.MappingMatch for testing purposes + +package javax.servlet.http; + + +public enum MappingMatch +{ + CONTEXT_ROOT, DEFAULT, EXACT, EXTENSION, PATH; + private MappingMatch() {} +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/http/Part.java b/java/ql/test/stubs/javafx-web/javax/servlet/http/Part.java new file mode 100644 index 00000000000..a4e599748a5 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/http/Part.java @@ -0,0 +1,20 @@ +// Generated automatically from javax.servlet.http.Part for testing purposes + +package javax.servlet.http; + +import java.io.InputStream; +import java.util.Collection; + +public interface Part +{ + Collection getHeaderNames(); + Collection getHeaders(String p0); + InputStream getInputStream(); + String getContentType(); + String getHeader(String p0); + String getName(); + String getSubmittedFileName(); + long getSize(); + void delete(); + void write(String p0); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/http/PushBuilder.java b/java/ql/test/stubs/javafx-web/javax/servlet/http/PushBuilder.java new file mode 100644 index 00000000000..195e2426a83 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/http/PushBuilder.java @@ -0,0 +1,23 @@ +// Generated automatically from javax.servlet.http.PushBuilder for testing purposes + +package javax.servlet.http; + +import java.util.Set; + +public interface PushBuilder +{ + PushBuilder addHeader(String p0, String p1); + PushBuilder method(String p0); + PushBuilder path(String p0); + PushBuilder queryString(String p0); + PushBuilder removeHeader(String p0); + PushBuilder sessionId(String p0); + PushBuilder setHeader(String p0, String p1); + Set getHeaderNames(); + String getHeader(String p0); + String getMethod(); + String getPath(); + String getQueryString(); + String getSessionId(); + void push(); +} diff --git a/java/ql/test/stubs/javafx-web/javax/servlet/http/WebConnection.java b/java/ql/test/stubs/javafx-web/javax/servlet/http/WebConnection.java new file mode 100644 index 00000000000..5001c046400 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/servlet/http/WebConnection.java @@ -0,0 +1,12 @@ +// Generated automatically from javax.servlet.http.WebConnection for testing purposes + +package javax.servlet.http; + +import javax.servlet.ServletInputStream; +import javax.servlet.ServletOutputStream; + +public interface WebConnection extends AutoCloseable +{ + ServletInputStream getInputStream(); + ServletOutputStream getOutputStream(); +} diff --git a/java/ql/test/stubs/javafx-web/javax/sql/CommonDataSource.java b/java/ql/test/stubs/javafx-web/javax/sql/CommonDataSource.java new file mode 100644 index 00000000000..cdc814157ce --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/sql/CommonDataSource.java @@ -0,0 +1,17 @@ +// Generated automatically from javax.sql.CommonDataSource for testing purposes + +package javax.sql; + +import java.io.PrintWriter; +import java.sql.ShardingKeyBuilder; +import java.util.logging.Logger; + +public interface CommonDataSource +{ + Logger getParentLogger(); + PrintWriter getLogWriter(); + default ShardingKeyBuilder createShardingKeyBuilder(){ return null; } + int getLoginTimeout(); + void setLogWriter(PrintWriter p0); + void setLoginTimeout(int p0); +} diff --git a/java/ql/test/stubs/javafx-web/javax/sql/DataSource.java b/java/ql/test/stubs/javafx-web/javax/sql/DataSource.java new file mode 100644 index 00000000000..d28d63d6e0a --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/sql/DataSource.java @@ -0,0 +1,20 @@ +// Generated automatically from javax.sql.DataSource for testing purposes + +package javax.sql; + +import java.io.PrintWriter; +import java.sql.Connection; +import java.sql.ConnectionBuilder; +import java.sql.Wrapper; +import javax.sql.CommonDataSource; + +public interface DataSource extends CommonDataSource, Wrapper +{ + Connection getConnection(); + Connection getConnection(String p0, String p1); + PrintWriter getLogWriter(); + default ConnectionBuilder createConnectionBuilder(){ return null; } + int getLoginTimeout(); + void setLogWriter(PrintWriter p0); + void setLoginTimeout(int p0); +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/RuntimeType.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/RuntimeType.java new file mode 100644 index 00000000000..19198662cdb --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/RuntimeType.java @@ -0,0 +1,10 @@ +// Generated automatically from javax.ws.rs.RuntimeType for testing purposes + +package javax.ws.rs; + + +public enum RuntimeType +{ + CLIENT, SERVER; + private RuntimeType() {} +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/client/AsyncInvoker.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/client/AsyncInvoker.java new file mode 100644 index 00000000000..8aaad1d06c7 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/client/AsyncInvoker.java @@ -0,0 +1,47 @@ +// Generated automatically from javax.ws.rs.client.AsyncInvoker for testing purposes + +package javax.ws.rs.client; + +import java.util.concurrent.Future; +import javax.ws.rs.client.Entity; +import javax.ws.rs.client.InvocationCallback; +import javax.ws.rs.core.GenericType; +import javax.ws.rs.core.Response; + +public interface AsyncInvoker +{ + java.util.concurrent.Future delete(java.lang.Class p0); + java.util.concurrent.Future delete(javax.ws.rs.client.InvocationCallback p0); + java.util.concurrent.Future delete(javax.ws.rs.core.GenericType p0); + java.util.concurrent.Future get(java.lang.Class p0); + java.util.concurrent.Future get(javax.ws.rs.client.InvocationCallback p0); + java.util.concurrent.Future get(javax.ws.rs.core.GenericType p0); + java.util.concurrent.Future method(String p0, Entity p1, java.lang.Class p2); + java.util.concurrent.Future method(String p0, Entity p1, javax.ws.rs.client.InvocationCallback p2); + java.util.concurrent.Future method(String p0, Entity p1, javax.ws.rs.core.GenericType p2); + java.util.concurrent.Future method(String p0, java.lang.Class p1); + java.util.concurrent.Future method(String p0, javax.ws.rs.client.InvocationCallback p1); + java.util.concurrent.Future method(String p0, javax.ws.rs.core.GenericType p1); + java.util.concurrent.Future options(java.lang.Class p0); + java.util.concurrent.Future options(javax.ws.rs.client.InvocationCallback p0); + java.util.concurrent.Future options(javax.ws.rs.core.GenericType p0); + java.util.concurrent.Future post(Entity p0, java.lang.Class p1); + java.util.concurrent.Future post(Entity p0, javax.ws.rs.client.InvocationCallback p1); + java.util.concurrent.Future post(Entity p0, javax.ws.rs.core.GenericType p1); + java.util.concurrent.Future put(Entity p0, java.lang.Class p1); + java.util.concurrent.Future put(Entity p0, javax.ws.rs.client.InvocationCallback p1); + java.util.concurrent.Future put(Entity p0, javax.ws.rs.core.GenericType p1); + java.util.concurrent.Future trace(java.lang.Class p0); + java.util.concurrent.Future trace(javax.ws.rs.client.InvocationCallback p0); + java.util.concurrent.Future trace(javax.ws.rs.core.GenericType p0); + java.util.concurrent.Future delete(); + java.util.concurrent.Future get(); + java.util.concurrent.Future head(); + java.util.concurrent.Future head(InvocationCallback p0); + java.util.concurrent.Future method(String p0); + java.util.concurrent.Future method(String p0, Entity p1); + java.util.concurrent.Future options(); + java.util.concurrent.Future post(Entity p0); + java.util.concurrent.Future put(Entity p0); + java.util.concurrent.Future trace(); +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/client/Client.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/client/Client.java new file mode 100644 index 00000000000..7869fa65579 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/client/Client.java @@ -0,0 +1,24 @@ +// Generated automatically from javax.ws.rs.client.Client for testing purposes + +package javax.ws.rs.client; + +import java.net.URI; +import javax.net.ssl.HostnameVerifier; +import javax.net.ssl.SSLContext; +import javax.ws.rs.client.Invocation; +import javax.ws.rs.client.WebTarget; +import javax.ws.rs.core.Configurable; +import javax.ws.rs.core.Link; +import javax.ws.rs.core.UriBuilder; + +public interface Client extends Configurable +{ + HostnameVerifier getHostnameVerifier(); + Invocation.Builder invocation(Link p0); + SSLContext getSslContext(); + WebTarget target(Link p0); + WebTarget target(String p0); + WebTarget target(URI p0); + WebTarget target(UriBuilder p0); + void close(); +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/client/ClientBuilder.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/client/ClientBuilder.java new file mode 100644 index 00000000000..76954b19f23 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/client/ClientBuilder.java @@ -0,0 +1,26 @@ +// Generated automatically from javax.ws.rs.client.ClientBuilder for testing purposes + +package javax.ws.rs.client; + +import java.security.KeyStore; +import javax.net.ssl.HostnameVerifier; +import javax.net.ssl.SSLContext; +import javax.ws.rs.client.Client; +import javax.ws.rs.core.Configurable; +import javax.ws.rs.core.Configuration; + +abstract public class ClientBuilder implements Configurable +{ + protected ClientBuilder(){} + public ClientBuilder keyStore(KeyStore p0, String p1){ return null; } + public abstract Client build(); + public abstract ClientBuilder hostnameVerifier(HostnameVerifier p0); + public abstract ClientBuilder keyStore(KeyStore p0, char[] p1); + public abstract ClientBuilder sslContext(SSLContext p0); + public abstract ClientBuilder trustStore(KeyStore p0); + public abstract ClientBuilder withConfig(Configuration p0); + public static Client newClient(){ return null; } + public static Client newClient(Configuration p0){ return null; } + public static ClientBuilder newBuilder(){ return null; } + public static String JAXRS_DEFAULT_CLIENT_BUILDER_PROPERTY = null; +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/client/Entity.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/client/Entity.java new file mode 100644 index 00000000000..498b1907d7e --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/client/Entity.java @@ -0,0 +1,36 @@ +// Generated automatically from javax.ws.rs.client.Entity for testing purposes + +package javax.ws.rs.client; + +import java.lang.annotation.Annotation; +import java.util.Locale; +import javax.ws.rs.core.Form; +import javax.ws.rs.core.MediaType; +import javax.ws.rs.core.MultivaluedMap; +import javax.ws.rs.core.Variant; + +public class Entity +{ + protected Entity() {} + public Annotation[] getAnnotations(){ return null; } + public Locale getLanguage(){ return null; } + public MediaType getMediaType(){ return null; } + public String getEncoding(){ return null; } + public String toString(){ return null; } + public T getEntity(){ return null; } + public Variant getVariant(){ return null; } + public boolean equals(Object p0){ return false; } + public int hashCode(){ return 0; } + public static javax.ws.rs.client.Entity entity(T p0, MediaType p1){ return null; } + public static javax.ws.rs.client.Entity entity(T p0, MediaType p1, Annotation[] p2){ return null; } + public static javax.ws.rs.client.Entity entity(T p0, String p1){ return null; } + public static javax.ws.rs.client.Entity entity(T p0, Variant p1){ return null; } + public static javax.ws.rs.client.Entity entity(T p0, Variant p1, Annotation[] p2){ return null; } + public static javax.ws.rs.client.Entity html(T p0){ return null; } + public static javax.ws.rs.client.Entity json(T p0){ return null; } + public static javax.ws.rs.client.Entity text(T p0){ return null; } + public static javax.ws.rs.client.Entity xhtml(T p0){ return null; } + public static javax.ws.rs.client.Entity xml(T p0){ return null; } + public static Entity form(Form p0){ return null; } + public static Entity form(MultivaluedMap p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/client/Invocation.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/client/Invocation.java new file mode 100644 index 00000000000..04ed5fb1a12 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/client/Invocation.java @@ -0,0 +1,49 @@ +// Generated automatically from javax.ws.rs.client.Invocation for testing purposes + +package javax.ws.rs.client; + +import java.util.Locale; +import java.util.concurrent.Future; +import javax.ws.rs.client.AsyncInvoker; +import javax.ws.rs.client.Entity; +import javax.ws.rs.client.InvocationCallback; +import javax.ws.rs.client.SyncInvoker; +import javax.ws.rs.core.CacheControl; +import javax.ws.rs.core.Cookie; +import javax.ws.rs.core.GenericType; +import javax.ws.rs.core.MediaType; +import javax.ws.rs.core.MultivaluedMap; +import javax.ws.rs.core.Response; + +public interface Invocation +{ + T invoke(java.lang.Class p0); + T invoke(javax.ws.rs.core.GenericType p0); + java.util.concurrent.Future submit(java.lang.Class p0); + java.util.concurrent.Future submit(javax.ws.rs.client.InvocationCallback p0); + java.util.concurrent.Future submit(javax.ws.rs.core.GenericType p0); + Invocation property(String p0, Object p1); + Response invoke(); + java.util.concurrent.Future submit(); + static public interface Builder extends SyncInvoker + { + AsyncInvoker async(); + Invocation build(String p0); + Invocation build(String p0, Entity p1); + Invocation buildDelete(); + Invocation buildGet(); + Invocation buildPost(Entity p0); + Invocation buildPut(Entity p0); + Invocation.Builder accept(MediaType... p0); + Invocation.Builder accept(String... p0); + Invocation.Builder acceptEncoding(String... p0); + Invocation.Builder acceptLanguage(Locale... p0); + Invocation.Builder acceptLanguage(String... p0); + Invocation.Builder cacheControl(CacheControl p0); + Invocation.Builder cookie(Cookie p0); + Invocation.Builder cookie(String p0, String p1); + Invocation.Builder header(String p0, Object p1); + Invocation.Builder headers(MultivaluedMap p0); + Invocation.Builder property(String p0, Object p1); + } +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/client/InvocationCallback.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/client/InvocationCallback.java new file mode 100644 index 00000000000..22420c4c5db --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/client/InvocationCallback.java @@ -0,0 +1,10 @@ +// Generated automatically from javax.ws.rs.client.InvocationCallback for testing purposes + +package javax.ws.rs.client; + + +public interface InvocationCallback +{ + void completed(RESPONSE p0); + void failed(Throwable p0); +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/client/SyncInvoker.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/client/SyncInvoker.java new file mode 100644 index 00000000000..40294c4a12a --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/client/SyncInvoker.java @@ -0,0 +1,36 @@ +// Generated automatically from javax.ws.rs.client.SyncInvoker for testing purposes + +package javax.ws.rs.client; + +import javax.ws.rs.client.Entity; +import javax.ws.rs.core.GenericType; +import javax.ws.rs.core.Response; + +public interface SyncInvoker +{ + T delete(java.lang.Class p0); + T delete(javax.ws.rs.core.GenericType p0); + T get(java.lang.Class p0); + T get(javax.ws.rs.core.GenericType p0); + T method(String p0, Entity p1, java.lang.Class p2); + T method(String p0, Entity p1, javax.ws.rs.core.GenericType p2); + T method(String p0, java.lang.Class p1); + T method(String p0, javax.ws.rs.core.GenericType p1); + T options(java.lang.Class p0); + T options(javax.ws.rs.core.GenericType p0); + T post(Entity p0, java.lang.Class p1); + T post(Entity p0, javax.ws.rs.core.GenericType p1); + T put(Entity p0, java.lang.Class p1); + T put(Entity p0, javax.ws.rs.core.GenericType p1); + T trace(java.lang.Class p0); + T trace(javax.ws.rs.core.GenericType p0); + Response delete(); + Response get(); + Response head(); + Response method(String p0); + Response method(String p0, Entity p1); + Response options(); + Response post(Entity p0); + Response put(Entity p0); + Response trace(); +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/client/WebTarget.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/client/WebTarget.java new file mode 100644 index 00000000000..d91eb3875cd --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/client/WebTarget.java @@ -0,0 +1,28 @@ +// Generated automatically from javax.ws.rs.client.WebTarget for testing purposes + +package javax.ws.rs.client; + +import java.net.URI; +import java.util.Map; +import javax.ws.rs.client.Invocation; +import javax.ws.rs.core.Configurable; +import javax.ws.rs.core.MediaType; +import javax.ws.rs.core.UriBuilder; + +public interface WebTarget extends Configurable +{ + Invocation.Builder request(); + Invocation.Builder request(MediaType... p0); + Invocation.Builder request(String... p0); + URI getUri(); + UriBuilder getUriBuilder(); + WebTarget matrixParam(String p0, Object... p1); + WebTarget path(String p0); + WebTarget queryParam(String p0, Object... p1); + WebTarget resolveTemplate(String p0, Object p1); + WebTarget resolveTemplate(String p0, Object p1, boolean p2); + WebTarget resolveTemplateFromEncoded(String p0, Object p1); + WebTarget resolveTemplates(Map p0); + WebTarget resolveTemplates(Map p0, boolean p1); + WebTarget resolveTemplatesFromEncoded(Map p0); +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/core/CacheControl.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/CacheControl.java new file mode 100644 index 00000000000..6096a15b91f --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/CacheControl.java @@ -0,0 +1,34 @@ +// Generated automatically from javax.ws.rs.core.CacheControl for testing purposes + +package javax.ws.rs.core; + +import java.util.List; +import java.util.Map; + +public class CacheControl +{ + public CacheControl(){} + public List getNoCacheFields(){ return null; } + public List getPrivateFields(){ return null; } + public Map getCacheExtension(){ return null; } + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public boolean isMustRevalidate(){ return false; } + public boolean isNoCache(){ return false; } + public boolean isNoStore(){ return false; } + public boolean isNoTransform(){ return false; } + public boolean isPrivate(){ return false; } + public boolean isProxyRevalidate(){ return false; } + public int getMaxAge(){ return 0; } + public int getSMaxAge(){ return 0; } + public int hashCode(){ return 0; } + public static CacheControl valueOf(String p0){ return null; } + public void setMaxAge(int p0){} + public void setMustRevalidate(boolean p0){} + public void setNoCache(boolean p0){} + public void setNoStore(boolean p0){} + public void setNoTransform(boolean p0){} + public void setPrivate(boolean p0){} + public void setProxyRevalidate(boolean p0){} + public void setSMaxAge(int p0){} +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/core/Configurable.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/Configurable.java new file mode 100644 index 00000000000..18fbafa13ce --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/Configurable.java @@ -0,0 +1,20 @@ +// Generated automatically from javax.ws.rs.core.Configurable for testing purposes + +package javax.ws.rs.core; + +import java.util.Map; +import javax.ws.rs.core.Configuration; + +public interface Configurable +{ + C property(String p0, Object p1); + C register(Class p0); + C register(Class p0, Class... p1); + C register(Class p0, Map, Integer> p1); + C register(Class p0, int p1); + C register(Object p0); + C register(Object p0, Class... p1); + C register(Object p0, Map, Integer> p1); + C register(Object p0, int p1); + Configuration getConfiguration(); +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/core/Configuration.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/Configuration.java new file mode 100644 index 00000000000..b1b4fb6e50d --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/Configuration.java @@ -0,0 +1,24 @@ +// Generated automatically from javax.ws.rs.core.Configuration for testing purposes + +package javax.ws.rs.core; + +import java.util.Collection; +import java.util.Map; +import java.util.Set; +import javax.ws.rs.RuntimeType; +import javax.ws.rs.core.Feature; + +public interface Configuration +{ + Collection getPropertyNames(); + Map, Integer> getContracts(Class p0); + Map getProperties(); + Object getProperty(String p0); + RuntimeType getRuntimeType(); + Set> getClasses(); + Set getInstances(); + boolean isEnabled(Feature p0); + boolean isEnabled(java.lang.Class p0); + boolean isRegistered(Class p0); + boolean isRegistered(Object p0); +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/core/Cookie.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/Cookie.java new file mode 100644 index 00000000000..52b83dae424 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/Cookie.java @@ -0,0 +1,22 @@ +// Generated automatically from javax.ws.rs.core.Cookie for testing purposes + +package javax.ws.rs.core; + + +public class Cookie +{ + protected Cookie() {} + public Cookie(String p0, String p1){} + public Cookie(String p0, String p1, String p2, String p3){} + public Cookie(String p0, String p1, String p2, String p3, int p4){} + public String getDomain(){ return null; } + public String getName(){ return null; } + public String getPath(){ return null; } + public String getValue(){ return null; } + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public int getVersion(){ return 0; } + public int hashCode(){ return 0; } + public static Cookie valueOf(String p0){ return null; } + public static int DEFAULT_VERSION = 0; +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/core/EntityTag.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/EntityTag.java new file mode 100644 index 00000000000..00b4815a605 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/EntityTag.java @@ -0,0 +1,17 @@ +// Generated automatically from javax.ws.rs.core.EntityTag for testing purposes + +package javax.ws.rs.core; + + +public class EntityTag +{ + protected EntityTag() {} + public EntityTag(String p0){} + public EntityTag(String p0, boolean p1){} + public String getValue(){ return null; } + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public boolean isWeak(){ return false; } + public int hashCode(){ return 0; } + public static EntityTag valueOf(String p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/core/Feature.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/Feature.java new file mode 100644 index 00000000000..cac25873b52 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/Feature.java @@ -0,0 +1,10 @@ +// Generated automatically from javax.ws.rs.core.Feature for testing purposes + +package javax.ws.rs.core; + +import javax.ws.rs.core.FeatureContext; + +public interface Feature +{ + boolean configure(FeatureContext p0); +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/core/FeatureContext.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/FeatureContext.java new file mode 100644 index 00000000000..1827a1bf1a5 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/FeatureContext.java @@ -0,0 +1,9 @@ +// Generated automatically from javax.ws.rs.core.FeatureContext for testing purposes + +package javax.ws.rs.core; + +import javax.ws.rs.core.Configurable; + +public interface FeatureContext extends Configurable +{ +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/core/Form.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/Form.java new file mode 100644 index 00000000000..71f3a826c50 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/Form.java @@ -0,0 +1,14 @@ +// Generated automatically from javax.ws.rs.core.Form for testing purposes + +package javax.ws.rs.core; + +import javax.ws.rs.core.MultivaluedMap; + +public class Form +{ + public Form param(String p0, String p1){ return null; } + public Form(){} + public Form(MultivaluedMap p0){} + public Form(String p0, String p1){} + public MultivaluedMap asMap(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/core/GenericType.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/GenericType.java new file mode 100644 index 00000000000..22617da5fcc --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/GenericType.java @@ -0,0 +1,16 @@ +// Generated automatically from javax.ws.rs.core.GenericType for testing purposes + +package javax.ws.rs.core; + +import java.lang.reflect.Type; + +public class GenericType +{ + protected GenericType(){} + public GenericType(Type p0){} + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public final Class getRawType(){ return null; } + public final Type getType(){ return null; } + public int hashCode(){ return 0; } +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/core/Link.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/Link.java new file mode 100644 index 00000000000..9d2c1e10850 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/Link.java @@ -0,0 +1,48 @@ +// Generated automatically from javax.ws.rs.core.Link for testing purposes + +package javax.ws.rs.core; + +import java.net.URI; +import java.util.List; +import java.util.Map; +import javax.ws.rs.core.UriBuilder; + +abstract public class Link +{ + public Link(){} + public abstract List getRels(); + public abstract Map getParams(); + public abstract String getRel(); + public abstract String getTitle(); + public abstract String getType(); + public abstract String toString(); + public abstract URI getUri(); + public abstract UriBuilder getUriBuilder(); + public static Link valueOf(String p0){ return null; } + public static Link.Builder fromLink(Link p0){ return null; } + public static Link.Builder fromMethod(Class p0, String p1){ return null; } + public static Link.Builder fromPath(String p0){ return null; } + public static Link.Builder fromResource(Class p0){ return null; } + public static Link.Builder fromUri(String p0){ return null; } + public static Link.Builder fromUri(URI p0){ return null; } + public static Link.Builder fromUriBuilder(UriBuilder p0){ return null; } + public static String REL = null; + public static String TITLE = null; + public static String TYPE = null; + static public interface Builder + { + Link build(Object... p0); + Link buildRelativized(URI p0, Object... p1); + Link.Builder baseUri(String p0); + Link.Builder baseUri(URI p0); + Link.Builder link(Link p0); + Link.Builder link(String p0); + Link.Builder param(String p0, String p1); + Link.Builder rel(String p0); + Link.Builder title(String p0); + Link.Builder type(String p0); + Link.Builder uri(String p0); + Link.Builder uri(URI p0); + Link.Builder uriBuilder(UriBuilder p0); + } +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/core/MediaType.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/MediaType.java new file mode 100644 index 00000000000..2ef1caff505 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/MediaType.java @@ -0,0 +1,50 @@ +// Generated automatically from javax.ws.rs.core.MediaType for testing purposes + +package javax.ws.rs.core; + +import java.util.Map; + +public class MediaType +{ + public Map getParameters(){ return null; } + public MediaType withCharset(String p0){ return null; } + public MediaType(){} + public MediaType(String p0, String p1){} + public MediaType(String p0, String p1, Map p2){} + public MediaType(String p0, String p1, String p2){} + public String getSubtype(){ return null; } + public String getType(){ return null; } + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public boolean isCompatible(MediaType p0){ return false; } + public boolean isWildcardSubtype(){ return false; } + public boolean isWildcardType(){ return false; } + public int hashCode(){ return 0; } + public static MediaType APPLICATION_ATOM_XML_TYPE = null; + public static MediaType APPLICATION_FORM_URLENCODED_TYPE = null; + public static MediaType APPLICATION_JSON_TYPE = null; + public static MediaType APPLICATION_OCTET_STREAM_TYPE = null; + public static MediaType APPLICATION_SVG_XML_TYPE = null; + public static MediaType APPLICATION_XHTML_XML_TYPE = null; + public static MediaType APPLICATION_XML_TYPE = null; + public static MediaType MULTIPART_FORM_DATA_TYPE = null; + public static MediaType TEXT_HTML_TYPE = null; + public static MediaType TEXT_PLAIN_TYPE = null; + public static MediaType TEXT_XML_TYPE = null; + public static MediaType WILDCARD_TYPE = null; + public static MediaType valueOf(String p0){ return null; } + public static String APPLICATION_ATOM_XML = null; + public static String APPLICATION_FORM_URLENCODED = null; + public static String APPLICATION_JSON = null; + public static String APPLICATION_OCTET_STREAM = null; + public static String APPLICATION_SVG_XML = null; + public static String APPLICATION_XHTML_XML = null; + public static String APPLICATION_XML = null; + public static String CHARSET_PARAMETER = null; + public static String MEDIA_TYPE_WILDCARD = null; + public static String MULTIPART_FORM_DATA = null; + public static String TEXT_HTML = null; + public static String TEXT_PLAIN = null; + public static String TEXT_XML = null; + public static String WILDCARD = null; +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/core/MultivaluedMap.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/MultivaluedMap.java new file mode 100644 index 00000000000..7fb1e3d682d --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/MultivaluedMap.java @@ -0,0 +1,17 @@ +// Generated automatically from javax.ws.rs.core.MultivaluedMap for testing purposes + +package javax.ws.rs.core; + +import java.util.List; +import java.util.Map; + +public interface MultivaluedMap extends java.util.Map> +{ + V getFirst(K p0); + boolean equalsIgnoreValueOrder(MultivaluedMap p0); + void add(K p0, V p1); + void addAll(K p0, V... p1); + void addAll(K p0, java.util.List p1); + void addFirst(K p0, V p1); + void putSingle(K p0, V p1); +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/core/NewCookie.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/NewCookie.java new file mode 100644 index 00000000000..03de30d6e77 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/NewCookie.java @@ -0,0 +1,29 @@ +// Generated automatically from javax.ws.rs.core.NewCookie for testing purposes + +package javax.ws.rs.core; + +import javax.ws.rs.core.Cookie; + +public class NewCookie extends Cookie +{ + protected NewCookie() {} + public Cookie toCookie(){ return null; } + public NewCookie(Cookie p0){} + public NewCookie(Cookie p0, String p1, int p2, boolean p3){} + public NewCookie(Cookie p0, String p1, int p2, java.util.Date p3, boolean p4, boolean p5){} + public NewCookie(String p0, String p1){} + public NewCookie(String p0, String p1, String p2, String p3, String p4, int p5, boolean p6){} + public NewCookie(String p0, String p1, String p2, String p3, String p4, int p5, boolean p6, boolean p7){} + public NewCookie(String p0, String p1, String p2, String p3, int p4, String p5, int p6, boolean p7){} + public NewCookie(String p0, String p1, String p2, String p3, int p4, String p5, int p6, java.util.Date p7, boolean p8, boolean p9){} + public String getComment(){ return null; } + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public boolean isHttpOnly(){ return false; } + public boolean isSecure(){ return false; } + public int getMaxAge(){ return 0; } + public int hashCode(){ return 0; } + public java.util.Date getExpiry(){ return null; } + public static NewCookie valueOf(String p0){ return null; } + public static int DEFAULT_MAX_AGE = 0; +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/core/Response.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/Response.java new file mode 100644 index 00000000000..bc8364ff18f --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/Response.java @@ -0,0 +1,127 @@ +// Generated automatically from javax.ws.rs.core.Response for testing purposes + +package javax.ws.rs.core; + +import java.lang.annotation.Annotation; +import java.net.URI; +import java.util.List; +import java.util.Locale; +import java.util.Map; +import java.util.Set; +import javax.ws.rs.core.CacheControl; +import javax.ws.rs.core.EntityTag; +import javax.ws.rs.core.GenericType; +import javax.ws.rs.core.Link; +import javax.ws.rs.core.MediaType; +import javax.ws.rs.core.MultivaluedMap; +import javax.ws.rs.core.NewCookie; +import javax.ws.rs.core.Variant; + +abstract public class Response +{ + abstract static public class ResponseBuilder + { + protected ResponseBuilder(){} + protected static Response.ResponseBuilder newInstance(){ return null; } + public Response.ResponseBuilder status(Response.Status p0){ return null; } + public Response.ResponseBuilder status(Response.StatusType p0){ return null; } + public abstract Response build(); + public abstract Response.ResponseBuilder allow(Set p0); + public abstract Response.ResponseBuilder allow(String... p0); + public abstract Response.ResponseBuilder cacheControl(CacheControl p0); + public abstract Response.ResponseBuilder clone(); + public abstract Response.ResponseBuilder contentLocation(URI p0); + public abstract Response.ResponseBuilder cookie(NewCookie... p0); + public abstract Response.ResponseBuilder encoding(String p0); + public abstract Response.ResponseBuilder entity(Object p0); + public abstract Response.ResponseBuilder entity(Object p0, Annotation[] p1); + public abstract Response.ResponseBuilder expires(java.util.Date p0); + public abstract Response.ResponseBuilder header(String p0, Object p1); + public abstract Response.ResponseBuilder language(Locale p0); + public abstract Response.ResponseBuilder language(String p0); + public abstract Response.ResponseBuilder lastModified(java.util.Date p0); + public abstract Response.ResponseBuilder link(String p0, String p1); + public abstract Response.ResponseBuilder link(URI p0, String p1); + public abstract Response.ResponseBuilder links(Link... p0); + public abstract Response.ResponseBuilder location(URI p0); + public abstract Response.ResponseBuilder replaceAll(MultivaluedMap p0); + public abstract Response.ResponseBuilder status(int p0); + public abstract Response.ResponseBuilder tag(EntityTag p0); + public abstract Response.ResponseBuilder tag(String p0); + public abstract Response.ResponseBuilder type(MediaType p0); + public abstract Response.ResponseBuilder type(String p0); + public abstract Response.ResponseBuilder variant(Variant p0); + public abstract Response.ResponseBuilder variants(Variant... p0); + public abstract Response.ResponseBuilder variants(java.util.List p0); + } + protected Response(){} + public MultivaluedMap getHeaders(){ return null; } + public abstract T readEntity(java.lang.Class p0); + public abstract T readEntity(java.lang.Class p0, Annotation[] p1); + public abstract T readEntity(javax.ws.rs.core.GenericType p0); + public abstract T readEntity(javax.ws.rs.core.GenericType p0, Annotation[] p1); + public abstract EntityTag getEntityTag(); + public abstract Link getLink(String p0); + public abstract Link.Builder getLinkBuilder(String p0); + public abstract Locale getLanguage(); + public abstract MediaType getMediaType(); + public abstract MultivaluedMap getMetadata(); + public abstract MultivaluedMap getStringHeaders(); + public abstract Object getEntity(); + public abstract Response.StatusType getStatusInfo(); + public abstract Set getAllowedMethods(); + public abstract String getHeaderString(String p0); + public abstract URI getLocation(); + public abstract boolean bufferEntity(); + public abstract boolean hasEntity(); + public abstract boolean hasLink(String p0); + public abstract int getLength(); + public abstract int getStatus(); + public abstract java.util.Date getDate(); + public abstract java.util.Date getLastModified(); + public abstract java.util.Map getCookies(); + public abstract java.util.Set getLinks(); + public abstract void close(); + public static Response.ResponseBuilder accepted(){ return null; } + public static Response.ResponseBuilder accepted(Object p0){ return null; } + public static Response.ResponseBuilder created(URI p0){ return null; } + public static Response.ResponseBuilder fromResponse(Response p0){ return null; } + public static Response.ResponseBuilder noContent(){ return null; } + public static Response.ResponseBuilder notAcceptable(java.util.List p0){ return null; } + public static Response.ResponseBuilder notModified(){ return null; } + public static Response.ResponseBuilder notModified(EntityTag p0){ return null; } + public static Response.ResponseBuilder notModified(String p0){ return null; } + public static Response.ResponseBuilder ok(){ return null; } + public static Response.ResponseBuilder ok(Object p0){ return null; } + public static Response.ResponseBuilder ok(Object p0, MediaType p1){ return null; } + public static Response.ResponseBuilder ok(Object p0, String p1){ return null; } + public static Response.ResponseBuilder ok(Object p0, Variant p1){ return null; } + public static Response.ResponseBuilder seeOther(URI p0){ return null; } + public static Response.ResponseBuilder serverError(){ return null; } + public static Response.ResponseBuilder status(Response.Status p0){ return null; } + public static Response.ResponseBuilder status(Response.StatusType p0){ return null; } + public static Response.ResponseBuilder status(int p0){ return null; } + public static Response.ResponseBuilder temporaryRedirect(URI p0){ return null; } + static public enum Status + { + ACCEPTED, BAD_GATEWAY, BAD_REQUEST, CONFLICT, CREATED, EXPECTATION_FAILED, FORBIDDEN, FOUND, GATEWAY_TIMEOUT, GONE, HTTP_VERSION_NOT_SUPPORTED, INTERNAL_SERVER_ERROR, LENGTH_REQUIRED, METHOD_NOT_ALLOWED, MOVED_PERMANENTLY, NOT_ACCEPTABLE, NOT_FOUND, NOT_IMPLEMENTED, NOT_MODIFIED, NO_CONTENT, OK, PARTIAL_CONTENT, PAYMENT_REQUIRED, PRECONDITION_FAILED, PROXY_AUTHENTICATION_REQUIRED, REQUESTED_RANGE_NOT_SATISFIABLE, REQUEST_ENTITY_TOO_LARGE, REQUEST_TIMEOUT, REQUEST_URI_TOO_LONG, RESET_CONTENT, SEE_OTHER, SERVICE_UNAVAILABLE, TEMPORARY_REDIRECT, UNAUTHORIZED, UNSUPPORTED_MEDIA_TYPE, USE_PROXY; + private Status() {} + public Response.Status.Family getFamily(){ return null; } + public String getReasonPhrase(){ return null; } + public String toString(){ return null; } + public int getStatusCode(){ return 0; } + public static Response.Status fromStatusCode(int p0){ return null; } + static public enum Family + { + CLIENT_ERROR, INFORMATIONAL, OTHER, REDIRECTION, SERVER_ERROR, SUCCESSFUL; + private Family() {} + public static Response.Status.Family familyOf(int p0){ return null; } + } + } + static public interface StatusType + { + Response.Status.Family getFamily(); + String getReasonPhrase(); + int getStatusCode(); + } +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/core/UriBuilder.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/UriBuilder.java new file mode 100644 index 00000000000..52d051c1b14 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/UriBuilder.java @@ -0,0 +1,54 @@ +// Generated automatically from javax.ws.rs.core.UriBuilder for testing purposes + +package javax.ws.rs.core; + +import java.lang.reflect.Method; +import java.net.URI; +import java.util.Map; +import javax.ws.rs.core.Link; + +abstract public class UriBuilder +{ + protected UriBuilder(){} + protected static UriBuilder newInstance(){ return null; } + public abstract String toTemplate(); + public abstract URI build(Object... p0); + public abstract URI build(Object[] p0, boolean p1); + public abstract URI buildFromEncoded(Object... p0); + public abstract URI buildFromEncodedMap(Map p0); + public abstract URI buildFromMap(Map p0); + public abstract URI buildFromMap(Map p0, boolean p1); + public abstract UriBuilder clone(); + public abstract UriBuilder fragment(String p0); + public abstract UriBuilder host(String p0); + public abstract UriBuilder matrixParam(String p0, Object... p1); + public abstract UriBuilder path(Class p0); + public abstract UriBuilder path(Class p0, String p1); + public abstract UriBuilder path(Method p0); + public abstract UriBuilder path(String p0); + public abstract UriBuilder port(int p0); + public abstract UriBuilder queryParam(String p0, Object... p1); + public abstract UriBuilder replaceMatrix(String p0); + public abstract UriBuilder replaceMatrixParam(String p0, Object... p1); + public abstract UriBuilder replacePath(String p0); + public abstract UriBuilder replaceQuery(String p0); + public abstract UriBuilder replaceQueryParam(String p0, Object... p1); + public abstract UriBuilder resolveTemplate(String p0, Object p1); + public abstract UriBuilder resolveTemplate(String p0, Object p1, boolean p2); + public abstract UriBuilder resolveTemplateFromEncoded(String p0, Object p1); + public abstract UriBuilder resolveTemplates(Map p0); + public abstract UriBuilder resolveTemplates(Map p0, boolean p1); + public abstract UriBuilder resolveTemplatesFromEncoded(Map p0); + public abstract UriBuilder scheme(String p0); + public abstract UriBuilder schemeSpecificPart(String p0); + public abstract UriBuilder segment(String... p0); + public abstract UriBuilder uri(String p0); + public abstract UriBuilder uri(URI p0); + public abstract UriBuilder userInfo(String p0); + public static UriBuilder fromLink(Link p0){ return null; } + public static UriBuilder fromMethod(Class p0, String p1){ return null; } + public static UriBuilder fromPath(String p0){ return null; } + public static UriBuilder fromResource(Class p0){ return null; } + public static UriBuilder fromUri(String p0){ return null; } + public static UriBuilder fromUri(URI p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/javax/ws/rs/core/Variant.java b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/Variant.java new file mode 100644 index 00000000000..0c2ef6892af --- /dev/null +++ b/java/ql/test/stubs/javafx-web/javax/ws/rs/core/Variant.java @@ -0,0 +1,36 @@ +// Generated automatically from javax.ws.rs.core.Variant for testing purposes + +package javax.ws.rs.core; + +import java.util.List; +import java.util.Locale; +import javax.ws.rs.core.MediaType; + +public class Variant +{ + protected Variant() {} + abstract static public class VariantListBuilder + { + protected VariantListBuilder(){} + public abstract Variant.VariantListBuilder add(); + public abstract Variant.VariantListBuilder encodings(String... p0); + public abstract Variant.VariantListBuilder languages(Locale... p0); + public abstract Variant.VariantListBuilder mediaTypes(MediaType... p0); + public abstract java.util.List build(); + public static Variant.VariantListBuilder newInstance(){ return null; } + } + public Locale getLanguage(){ return null; } + public MediaType getMediaType(){ return null; } + public String getEncoding(){ return null; } + public String getLanguageString(){ return null; } + public String toString(){ return null; } + public Variant(MediaType p0, Locale p1, String p2){} + public Variant(MediaType p0, String p1, String p2){} + public Variant(MediaType p0, String p1, String p2, String p3){} + public Variant(MediaType p0, String p1, String p2, String p3, String p4){} + public boolean equals(Object p0){ return false; } + public int hashCode(){ return 0; } + public static Variant.VariantListBuilder encodings(String... p0){ return null; } + public static Variant.VariantListBuilder languages(Locale... p0){ return null; } + public static Variant.VariantListBuilder mediaTypes(MediaType... p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/commons/logging/Log.java b/java/ql/test/stubs/javafx-web/org/apache/commons/logging/Log.java new file mode 100644 index 00000000000..0ff25bcb341 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/commons/logging/Log.java @@ -0,0 +1,26 @@ +// Generated automatically from org.apache.commons.logging.Log for testing purposes + +package org.apache.commons.logging; + + +public interface Log +{ + boolean isDebugEnabled(); + boolean isErrorEnabled(); + boolean isFatalEnabled(); + boolean isInfoEnabled(); + boolean isTraceEnabled(); + boolean isWarnEnabled(); + void debug(Object p0); + void debug(Object p0, Throwable p1); + void error(Object p0); + void error(Object p0, Throwable p1); + void fatal(Object p0); + void fatal(Object p0, Throwable p1); + void info(Object p0); + void info(Object p0, Throwable p1); + void trace(Object p0); + void trace(Object p0, Throwable p1); + void warn(Object p0); + void warn(Object p0, Throwable p1); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/Header.java b/java/ql/test/stubs/javafx-web/org/apache/http/Header.java new file mode 100644 index 00000000000..7674e4c8b3e --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/Header.java @@ -0,0 +1,11 @@ +// Generated automatically from org.apache.http.Header for testing purposes + +package org.apache.http; + +import org.apache.http.HeaderElement; +import org.apache.http.NameValuePair; + +public interface Header extends NameValuePair +{ + HeaderElement[] getElements(); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/HeaderElement.java b/java/ql/test/stubs/javafx-web/org/apache/http/HeaderElement.java new file mode 100644 index 00000000000..6c362a9e216 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/HeaderElement.java @@ -0,0 +1,15 @@ +// Generated automatically from org.apache.http.HeaderElement for testing purposes + +package org.apache.http; + +import org.apache.http.NameValuePair; + +public interface HeaderElement +{ + NameValuePair getParameter(int p0); + NameValuePair getParameterByName(String p0); + NameValuePair[] getParameters(); + String getName(); + String getValue(); + int getParameterCount(); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/HeaderIterator.java b/java/ql/test/stubs/javafx-web/org/apache/http/HeaderIterator.java new file mode 100644 index 00000000000..284ea9c13d3 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/HeaderIterator.java @@ -0,0 +1,12 @@ +// Generated automatically from org.apache.http.HeaderIterator for testing purposes + +package org.apache.http; + +import java.util.Iterator; +import org.apache.http.Header; + +public interface HeaderIterator extends Iterator +{ + Header nextHeader(); + boolean hasNext(); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/HttpClientConnection.java b/java/ql/test/stubs/javafx-web/org/apache/http/HttpClientConnection.java new file mode 100644 index 00000000000..6ea869be329 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/HttpClientConnection.java @@ -0,0 +1,18 @@ +// Generated automatically from org.apache.http.HttpClientConnection for testing purposes + +package org.apache.http; + +import org.apache.http.HttpConnection; +import org.apache.http.HttpEntityEnclosingRequest; +import org.apache.http.HttpRequest; +import org.apache.http.HttpResponse; + +public interface HttpClientConnection extends HttpConnection +{ + HttpResponse receiveResponseHeader(); + boolean isResponseAvailable(int p0); + void flush(); + void receiveResponseEntity(HttpResponse p0); + void sendRequestEntity(HttpEntityEnclosingRequest p0); + void sendRequestHeader(HttpRequest p0); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/HttpConnection.java b/java/ql/test/stubs/javafx-web/org/apache/http/HttpConnection.java new file mode 100644 index 00000000000..221186c2187 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/HttpConnection.java @@ -0,0 +1,17 @@ +// Generated automatically from org.apache.http.HttpConnection for testing purposes + +package org.apache.http; + +import java.io.Closeable; +import org.apache.http.HttpConnectionMetrics; + +public interface HttpConnection extends Closeable +{ + HttpConnectionMetrics getMetrics(); + boolean isOpen(); + boolean isStale(); + int getSocketTimeout(); + void close(); + void setSocketTimeout(int p0); + void shutdown(); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/HttpConnectionMetrics.java b/java/ql/test/stubs/javafx-web/org/apache/http/HttpConnectionMetrics.java new file mode 100644 index 00000000000..1a1b80b9255 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/HttpConnectionMetrics.java @@ -0,0 +1,14 @@ +// Generated automatically from org.apache.http.HttpConnectionMetrics for testing purposes + +package org.apache.http; + + +public interface HttpConnectionMetrics +{ + Object getMetric(String p0); + long getReceivedBytesCount(); + long getRequestCount(); + long getResponseCount(); + long getSentBytesCount(); + void reset(); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/HttpEntity.java b/java/ql/test/stubs/javafx-web/org/apache/http/HttpEntity.java new file mode 100644 index 00000000000..8dd6a607624 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/HttpEntity.java @@ -0,0 +1,20 @@ +// Generated automatically from org.apache.http.HttpEntity for testing purposes + +package org.apache.http; + +import java.io.InputStream; +import java.io.OutputStream; +import org.apache.http.Header; + +public interface HttpEntity +{ + Header getContentEncoding(); + Header getContentType(); + InputStream getContent(); + boolean isChunked(); + boolean isRepeatable(); + boolean isStreaming(); + long getContentLength(); + void consumeContent(); + void writeTo(OutputStream p0); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/HttpEntityEnclosingRequest.java b/java/ql/test/stubs/javafx-web/org/apache/http/HttpEntityEnclosingRequest.java new file mode 100644 index 00000000000..b2fc8b5579a --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/HttpEntityEnclosingRequest.java @@ -0,0 +1,13 @@ +// Generated automatically from org.apache.http.HttpEntityEnclosingRequest for testing purposes + +package org.apache.http; + +import org.apache.http.HttpEntity; +import org.apache.http.HttpRequest; + +public interface HttpEntityEnclosingRequest extends HttpRequest +{ + HttpEntity getEntity(); + boolean expectContinue(); + void setEntity(HttpEntity p0); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/HttpHost.java b/java/ql/test/stubs/javafx-web/org/apache/http/HttpHost.java new file mode 100644 index 00000000000..e342402e069 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/HttpHost.java @@ -0,0 +1,36 @@ +// Generated automatically from org.apache.http.HttpHost for testing purposes + +package org.apache.http; + +import java.io.Serializable; +import java.net.InetAddress; + +public class HttpHost implements Cloneable, Serializable +{ + protected HttpHost() {} + protected final InetAddress address = null; + protected final String hostname = null; + protected final String lcHostname = null; + protected final String schemeName = null; + protected final int port = 0; + public HttpHost(HttpHost p0){} + public HttpHost(InetAddress p0){} + public HttpHost(InetAddress p0, String p1, int p2, String p3){} + public HttpHost(InetAddress p0, int p1){} + public HttpHost(InetAddress p0, int p1, String p2){} + public HttpHost(String p0){} + public HttpHost(String p0, int p1){} + public HttpHost(String p0, int p1, String p2){} + public InetAddress getAddress(){ return null; } + public Object clone(){ return null; } + public String getHostName(){ return null; } + public String getSchemeName(){ return null; } + public String toHostString(){ return null; } + public String toString(){ return null; } + public String toURI(){ return null; } + public boolean equals(Object p0){ return false; } + public int getPort(){ return 0; } + public int hashCode(){ return 0; } + public static HttpHost create(String p0){ return null; } + public static String DEFAULT_SCHEME_NAME = null; +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/HttpInetConnection.java b/java/ql/test/stubs/javafx-web/org/apache/http/HttpInetConnection.java new file mode 100644 index 00000000000..cb17abad3d0 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/HttpInetConnection.java @@ -0,0 +1,14 @@ +// Generated automatically from org.apache.http.HttpInetConnection for testing purposes + +package org.apache.http; + +import java.net.InetAddress; +import org.apache.http.HttpConnection; + +public interface HttpInetConnection extends HttpConnection +{ + InetAddress getLocalAddress(); + InetAddress getRemoteAddress(); + int getLocalPort(); + int getRemotePort(); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/HttpMessage.java b/java/ql/test/stubs/javafx-web/org/apache/http/HttpMessage.java new file mode 100644 index 00000000000..3bd5bd5c1a9 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/HttpMessage.java @@ -0,0 +1,29 @@ +// Generated automatically from org.apache.http.HttpMessage for testing purposes + +package org.apache.http; + +import org.apache.http.Header; +import org.apache.http.HeaderIterator; +import org.apache.http.ProtocolVersion; +import org.apache.http.params.HttpParams; + +public interface HttpMessage +{ + Header getFirstHeader(String p0); + Header getLastHeader(String p0); + HeaderIterator headerIterator(); + HeaderIterator headerIterator(String p0); + Header[] getAllHeaders(); + Header[] getHeaders(String p0); + HttpParams getParams(); + ProtocolVersion getProtocolVersion(); + boolean containsHeader(String p0); + void addHeader(Header p0); + void addHeader(String p0, String p1); + void removeHeader(Header p0); + void removeHeaders(String p0); + void setHeader(Header p0); + void setHeader(String p0, String p1); + void setHeaders(Header[] p0); + void setParams(HttpParams p0); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/HttpRequest.java b/java/ql/test/stubs/javafx-web/org/apache/http/HttpRequest.java new file mode 100644 index 00000000000..b603e3f9c73 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/HttpRequest.java @@ -0,0 +1,11 @@ +// Generated automatically from org.apache.http.HttpRequest for testing purposes + +package org.apache.http; + +import org.apache.http.HttpMessage; +import org.apache.http.RequestLine; + +public interface HttpRequest extends HttpMessage +{ + RequestLine getRequestLine(); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/HttpResponse.java b/java/ql/test/stubs/javafx-web/org/apache/http/HttpResponse.java new file mode 100644 index 00000000000..66246f79ab2 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/HttpResponse.java @@ -0,0 +1,23 @@ +// Generated automatically from org.apache.http.HttpResponse for testing purposes + +package org.apache.http; + +import java.util.Locale; +import org.apache.http.HttpEntity; +import org.apache.http.HttpMessage; +import org.apache.http.ProtocolVersion; +import org.apache.http.StatusLine; + +public interface HttpResponse extends HttpMessage +{ + HttpEntity getEntity(); + Locale getLocale(); + StatusLine getStatusLine(); + void setEntity(HttpEntity p0); + void setLocale(Locale p0); + void setReasonPhrase(String p0); + void setStatusCode(int p0); + void setStatusLine(ProtocolVersion p0, int p1); + void setStatusLine(ProtocolVersion p0, int p1, String p2); + void setStatusLine(StatusLine p0); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/NameValuePair.java b/java/ql/test/stubs/javafx-web/org/apache/http/NameValuePair.java new file mode 100644 index 00000000000..2219b56c811 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/NameValuePair.java @@ -0,0 +1,10 @@ +// Generated automatically from org.apache.http.NameValuePair for testing purposes + +package org.apache.http; + + +public interface NameValuePair +{ + String getName(); + String getValue(); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/ProtocolVersion.java b/java/ql/test/stubs/javafx-web/org/apache/http/ProtocolVersion.java new file mode 100644 index 00000000000..1464659108c --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/ProtocolVersion.java @@ -0,0 +1,26 @@ +// Generated automatically from org.apache.http.ProtocolVersion for testing purposes + +package org.apache.http; + +import java.io.Serializable; + +public class ProtocolVersion implements Cloneable, Serializable +{ + protected ProtocolVersion() {} + protected final String protocol = null; + protected final int major = 0; + protected final int minor = 0; + public Object clone(){ return null; } + public ProtocolVersion forVersion(int p0, int p1){ return null; } + public ProtocolVersion(String p0, int p1, int p2){} + public String toString(){ return null; } + public boolean isComparable(ProtocolVersion p0){ return false; } + public final String getProtocol(){ return null; } + public final boolean equals(Object p0){ return false; } + public final boolean greaterEquals(ProtocolVersion p0){ return false; } + public final boolean lessEquals(ProtocolVersion p0){ return false; } + public final int getMajor(){ return 0; } + public final int getMinor(){ return 0; } + public final int hashCode(){ return 0; } + public int compareToVersion(ProtocolVersion p0){ return 0; } +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/RequestLine.java b/java/ql/test/stubs/javafx-web/org/apache/http/RequestLine.java new file mode 100644 index 00000000000..d2f6d3bd0e5 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/RequestLine.java @@ -0,0 +1,12 @@ +// Generated automatically from org.apache.http.RequestLine for testing purposes + +package org.apache.http; + +import org.apache.http.ProtocolVersion; + +public interface RequestLine +{ + ProtocolVersion getProtocolVersion(); + String getMethod(); + String getUri(); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/StatusLine.java b/java/ql/test/stubs/javafx-web/org/apache/http/StatusLine.java new file mode 100644 index 00000000000..84f39960ef1 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/StatusLine.java @@ -0,0 +1,12 @@ +// Generated automatically from org.apache.http.StatusLine for testing purposes + +package org.apache.http; + +import org.apache.http.ProtocolVersion; + +public interface StatusLine +{ + ProtocolVersion getProtocolVersion(); + String getReasonPhrase(); + int getStatusCode(); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/client/config/RequestConfig.java b/java/ql/test/stubs/javafx-web/org/apache/http/client/config/RequestConfig.java new file mode 100644 index 00000000000..78a6fa53928 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/client/config/RequestConfig.java @@ -0,0 +1,57 @@ +// Generated automatically from org.apache.http.client.config.RequestConfig for testing purposes + +package org.apache.http.client.config; + +import java.net.InetAddress; +import java.util.Collection; +import org.apache.http.HttpHost; + +public class RequestConfig implements Cloneable +{ + protected RequestConfig clone(){ return null; } + protected RequestConfig(){} + public Collection getProxyPreferredAuthSchemes(){ return null; } + public Collection getTargetPreferredAuthSchemes(){ return null; } + public HttpHost getProxy(){ return null; } + public InetAddress getLocalAddress(){ return null; } + public String getCookieSpec(){ return null; } + public String toString(){ return null; } + public boolean isAuthenticationEnabled(){ return false; } + public boolean isCircularRedirectsAllowed(){ return false; } + public boolean isContentCompressionEnabled(){ return false; } + public boolean isDecompressionEnabled(){ return false; } + public boolean isExpectContinueEnabled(){ return false; } + public boolean isNormalizeUri(){ return false; } + public boolean isRedirectsEnabled(){ return false; } + public boolean isRelativeRedirectsAllowed(){ return false; } + public boolean isStaleConnectionCheckEnabled(){ return false; } + public int getConnectTimeout(){ return 0; } + public int getConnectionRequestTimeout(){ return 0; } + public int getMaxRedirects(){ return 0; } + public int getSocketTimeout(){ return 0; } + public static RequestConfig DEFAULT = null; + public static RequestConfig.Builder copy(RequestConfig p0){ return null; } + public static RequestConfig.Builder custom(){ return null; } + static public class Builder + { + public RequestConfig build(){ return null; } + public RequestConfig.Builder setAuthenticationEnabled(boolean p0){ return null; } + public RequestConfig.Builder setCircularRedirectsAllowed(boolean p0){ return null; } + public RequestConfig.Builder setConnectTimeout(int p0){ return null; } + public RequestConfig.Builder setConnectionRequestTimeout(int p0){ return null; } + public RequestConfig.Builder setContentCompressionEnabled(boolean p0){ return null; } + public RequestConfig.Builder setCookieSpec(String p0){ return null; } + public RequestConfig.Builder setDecompressionEnabled(boolean p0){ return null; } + public RequestConfig.Builder setExpectContinueEnabled(boolean p0){ return null; } + public RequestConfig.Builder setLocalAddress(InetAddress p0){ return null; } + public RequestConfig.Builder setMaxRedirects(int p0){ return null; } + public RequestConfig.Builder setNormalizeUri(boolean p0){ return null; } + public RequestConfig.Builder setProxy(HttpHost p0){ return null; } + public RequestConfig.Builder setProxyPreferredAuthSchemes(Collection p0){ return null; } + public RequestConfig.Builder setRedirectsEnabled(boolean p0){ return null; } + public RequestConfig.Builder setRelativeRedirectsAllowed(boolean p0){ return null; } + public RequestConfig.Builder setSocketTimeout(int p0){ return null; } + public RequestConfig.Builder setStaleConnectionCheckEnabled(boolean p0){ return null; } + public RequestConfig.Builder setTargetPreferredAuthSchemes(Collection p0){ return null; } + } +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/AbortableHttpRequest.java b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/AbortableHttpRequest.java new file mode 100644 index 00000000000..2c53f6d9cfa --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/AbortableHttpRequest.java @@ -0,0 +1,13 @@ +// Generated automatically from org.apache.http.client.methods.AbortableHttpRequest for testing purposes + +package org.apache.http.client.methods; + +import org.apache.http.conn.ClientConnectionRequest; +import org.apache.http.conn.ConnectionReleaseTrigger; + +public interface AbortableHttpRequest +{ + void abort(); + void setConnectionRequest(ClientConnectionRequest p0); + void setReleaseTrigger(ConnectionReleaseTrigger p0); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/AbstractExecutionAwareRequest.java b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/AbstractExecutionAwareRequest.java new file mode 100644 index 00000000000..335d2ff7f77 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/AbstractExecutionAwareRequest.java @@ -0,0 +1,24 @@ +// Generated automatically from org.apache.http.client.methods.AbstractExecutionAwareRequest for testing purposes + +package org.apache.http.client.methods; + +import org.apache.http.HttpRequest; +import org.apache.http.client.methods.AbortableHttpRequest; +import org.apache.http.client.methods.HttpExecutionAware; +import org.apache.http.concurrent.Cancellable; +import org.apache.http.conn.ClientConnectionRequest; +import org.apache.http.conn.ConnectionReleaseTrigger; +import org.apache.http.message.AbstractHttpMessage; + +abstract public class AbstractExecutionAwareRequest extends AbstractHttpMessage implements AbortableHttpRequest, Cloneable, HttpExecutionAware, HttpRequest +{ + protected AbstractExecutionAwareRequest(){} + public Object clone(){ return null; } + public boolean isAborted(){ return false; } + public void abort(){} + public void completed(){} + public void reset(){} + public void setCancellable(Cancellable p0){} + public void setConnectionRequest(ClientConnectionRequest p0){} + public void setReleaseTrigger(ConnectionReleaseTrigger p0){} +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/Configurable.java b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/Configurable.java new file mode 100644 index 00000000000..a91c4628748 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/Configurable.java @@ -0,0 +1,10 @@ +// Generated automatically from org.apache.http.client.methods.Configurable for testing purposes + +package org.apache.http.client.methods; + +import org.apache.http.client.config.RequestConfig; + +public interface Configurable +{ + RequestConfig getConfig(); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpDelete.java b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpDelete.java new file mode 100644 index 00000000000..9d1dac980a8 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpDelete.java @@ -0,0 +1,15 @@ +// Generated automatically from org.apache.http.client.methods.HttpDelete for testing purposes + +package org.apache.http.client.methods; + +import java.net.URI; +import org.apache.http.client.methods.HttpRequestBase; + +public class HttpDelete extends HttpRequestBase +{ + public HttpDelete(){} + public HttpDelete(String p0){} + public HttpDelete(URI p0){} + public String getMethod(){ return null; } + public static String METHOD_NAME = null; +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpEntityEnclosingRequestBase.java b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpEntityEnclosingRequestBase.java new file mode 100644 index 00000000000..3765444c9b4 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpEntityEnclosingRequestBase.java @@ -0,0 +1,16 @@ +// Generated automatically from org.apache.http.client.methods.HttpEntityEnclosingRequestBase for testing purposes + +package org.apache.http.client.methods; + +import org.apache.http.HttpEntity; +import org.apache.http.HttpEntityEnclosingRequest; +import org.apache.http.client.methods.HttpRequestBase; + +abstract public class HttpEntityEnclosingRequestBase extends HttpRequestBase implements HttpEntityEnclosingRequest +{ + public HttpEntity getEntity(){ return null; } + public HttpEntityEnclosingRequestBase(){} + public Object clone(){ return null; } + public boolean expectContinue(){ return false; } + public void setEntity(HttpEntity p0){} +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpExecutionAware.java b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpExecutionAware.java new file mode 100644 index 00000000000..d7b9126dcac --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpExecutionAware.java @@ -0,0 +1,11 @@ +// Generated automatically from org.apache.http.client.methods.HttpExecutionAware for testing purposes + +package org.apache.http.client.methods; + +import org.apache.http.concurrent.Cancellable; + +public interface HttpExecutionAware +{ + boolean isAborted(); + void setCancellable(Cancellable p0); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpGet.java b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpGet.java new file mode 100644 index 00000000000..23f57c7ea13 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpGet.java @@ -0,0 +1,15 @@ +// Generated automatically from org.apache.http.client.methods.HttpGet for testing purposes + +package org.apache.http.client.methods; + +import java.net.URI; +import org.apache.http.client.methods.HttpRequestBase; + +public class HttpGet extends HttpRequestBase +{ + public HttpGet(){} + public HttpGet(String p0){} + public HttpGet(URI p0){} + public String getMethod(){ return null; } + public static String METHOD_NAME = null; +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpHead.java b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpHead.java new file mode 100644 index 00000000000..a054dc90f86 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpHead.java @@ -0,0 +1,15 @@ +// Generated automatically from org.apache.http.client.methods.HttpHead for testing purposes + +package org.apache.http.client.methods; + +import java.net.URI; +import org.apache.http.client.methods.HttpRequestBase; + +public class HttpHead extends HttpRequestBase +{ + public HttpHead(){} + public HttpHead(String p0){} + public HttpHead(URI p0){} + public String getMethod(){ return null; } + public static String METHOD_NAME = null; +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpOptions.java b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpOptions.java new file mode 100644 index 00000000000..a1f4f2f7ba1 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpOptions.java @@ -0,0 +1,18 @@ +// Generated automatically from org.apache.http.client.methods.HttpOptions for testing purposes + +package org.apache.http.client.methods; + +import java.net.URI; +import java.util.Set; +import org.apache.http.HttpResponse; +import org.apache.http.client.methods.HttpRequestBase; + +public class HttpOptions extends HttpRequestBase +{ + public HttpOptions(){} + public HttpOptions(String p0){} + public HttpOptions(URI p0){} + public Set getAllowedMethods(HttpResponse p0){ return null; } + public String getMethod(){ return null; } + public static String METHOD_NAME = null; +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpPatch.java b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpPatch.java new file mode 100644 index 00000000000..9b4f315a524 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpPatch.java @@ -0,0 +1,15 @@ +// Generated automatically from org.apache.http.client.methods.HttpPatch for testing purposes + +package org.apache.http.client.methods; + +import java.net.URI; +import org.apache.http.client.methods.HttpEntityEnclosingRequestBase; + +public class HttpPatch extends HttpEntityEnclosingRequestBase +{ + public HttpPatch(){} + public HttpPatch(String p0){} + public HttpPatch(URI p0){} + public String getMethod(){ return null; } + public static String METHOD_NAME = null; +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpPost.java b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpPost.java new file mode 100644 index 00000000000..cea85f34424 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpPost.java @@ -0,0 +1,15 @@ +// Generated automatically from org.apache.http.client.methods.HttpPost for testing purposes + +package org.apache.http.client.methods; + +import java.net.URI; +import org.apache.http.client.methods.HttpEntityEnclosingRequestBase; + +public class HttpPost extends HttpEntityEnclosingRequestBase +{ + public HttpPost(){} + public HttpPost(String p0){} + public HttpPost(URI p0){} + public String getMethod(){ return null; } + public static String METHOD_NAME = null; +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpPut.java b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpPut.java new file mode 100644 index 00000000000..5ca471ca077 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpPut.java @@ -0,0 +1,15 @@ +// Generated automatically from org.apache.http.client.methods.HttpPut for testing purposes + +package org.apache.http.client.methods; + +import java.net.URI; +import org.apache.http.client.methods.HttpEntityEnclosingRequestBase; + +public class HttpPut extends HttpEntityEnclosingRequestBase +{ + public HttpPut(){} + public HttpPut(String p0){} + public HttpPut(URI p0){} + public String getMethod(){ return null; } + public static String METHOD_NAME = null; +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpRequestBase.java b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpRequestBase.java new file mode 100644 index 00000000000..45f64538929 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpRequestBase.java @@ -0,0 +1,27 @@ +// Generated automatically from org.apache.http.client.methods.HttpRequestBase for testing purposes + +package org.apache.http.client.methods; + +import java.net.URI; +import org.apache.http.ProtocolVersion; +import org.apache.http.RequestLine; +import org.apache.http.client.config.RequestConfig; +import org.apache.http.client.methods.AbstractExecutionAwareRequest; +import org.apache.http.client.methods.Configurable; +import org.apache.http.client.methods.HttpUriRequest; + +abstract public class HttpRequestBase extends AbstractExecutionAwareRequest implements Configurable, HttpUriRequest +{ + public HttpRequestBase(){} + public ProtocolVersion getProtocolVersion(){ return null; } + public RequestConfig getConfig(){ return null; } + public RequestLine getRequestLine(){ return null; } + public String toString(){ return null; } + public URI getURI(){ return null; } + public abstract String getMethod(); + public void releaseConnection(){} + public void setConfig(RequestConfig p0){} + public void setProtocolVersion(ProtocolVersion p0){} + public void setURI(URI p0){} + public void started(){} +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpTrace.java b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpTrace.java new file mode 100644 index 00000000000..9809ca8e8c5 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpTrace.java @@ -0,0 +1,15 @@ +// Generated automatically from org.apache.http.client.methods.HttpTrace for testing purposes + +package org.apache.http.client.methods; + +import java.net.URI; +import org.apache.http.client.methods.HttpRequestBase; + +public class HttpTrace extends HttpRequestBase +{ + public HttpTrace(){} + public HttpTrace(String p0){} + public HttpTrace(URI p0){} + public String getMethod(){ return null; } + public static String METHOD_NAME = null; +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpUriRequest.java b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpUriRequest.java new file mode 100644 index 00000000000..87e9ffd286b --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/HttpUriRequest.java @@ -0,0 +1,14 @@ +// Generated automatically from org.apache.http.client.methods.HttpUriRequest for testing purposes + +package org.apache.http.client.methods; + +import java.net.URI; +import org.apache.http.HttpRequest; + +public interface HttpUriRequest extends HttpRequest +{ + String getMethod(); + URI getURI(); + boolean isAborted(); + void abort(); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/RequestBuilder.java b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/RequestBuilder.java new file mode 100644 index 00000000000..4773a1268e0 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/client/methods/RequestBuilder.java @@ -0,0 +1,71 @@ +// Generated automatically from org.apache.http.client.methods.RequestBuilder for testing purposes + +package org.apache.http.client.methods; + +import java.net.URI; +import java.nio.charset.Charset; +import java.util.List; +import org.apache.http.Header; +import org.apache.http.HttpEntity; +import org.apache.http.HttpRequest; +import org.apache.http.NameValuePair; +import org.apache.http.ProtocolVersion; +import org.apache.http.client.config.RequestConfig; +import org.apache.http.client.methods.HttpUriRequest; + +public class RequestBuilder +{ + public Charset getCharset(){ return null; } + public Header getFirstHeader(String p0){ return null; } + public Header getLastHeader(String p0){ return null; } + public Header[] getHeaders(String p0){ return null; } + public HttpEntity getEntity(){ return null; } + public HttpUriRequest build(){ return null; } + public List getParameters(){ return null; } + public ProtocolVersion getVersion(){ return null; } + public RequestBuilder addHeader(Header p0){ return null; } + public RequestBuilder addHeader(String p0, String p1){ return null; } + public RequestBuilder addParameter(NameValuePair p0){ return null; } + public RequestBuilder addParameter(String p0, String p1){ return null; } + public RequestBuilder addParameters(NameValuePair... p0){ return null; } + public RequestBuilder removeHeader(Header p0){ return null; } + public RequestBuilder removeHeaders(String p0){ return null; } + public RequestBuilder setCharset(Charset p0){ return null; } + public RequestBuilder setConfig(RequestConfig p0){ return null; } + public RequestBuilder setEntity(HttpEntity p0){ return null; } + public RequestBuilder setHeader(Header p0){ return null; } + public RequestBuilder setHeader(String p0, String p1){ return null; } + public RequestBuilder setUri(String p0){ return null; } + public RequestBuilder setUri(URI p0){ return null; } + public RequestBuilder setVersion(ProtocolVersion p0){ return null; } + public RequestConfig getConfig(){ return null; } + public String getMethod(){ return null; } + public String toString(){ return null; } + public URI getUri(){ return null; } + public static RequestBuilder copy(HttpRequest p0){ return null; } + public static RequestBuilder create(String p0){ return null; } + public static RequestBuilder delete(){ return null; } + public static RequestBuilder delete(String p0){ return null; } + public static RequestBuilder delete(URI p0){ return null; } + public static RequestBuilder get(){ return null; } + public static RequestBuilder get(String p0){ return null; } + public static RequestBuilder get(URI p0){ return null; } + public static RequestBuilder head(){ return null; } + public static RequestBuilder head(String p0){ return null; } + public static RequestBuilder head(URI p0){ return null; } + public static RequestBuilder options(){ return null; } + public static RequestBuilder options(String p0){ return null; } + public static RequestBuilder options(URI p0){ return null; } + public static RequestBuilder patch(){ return null; } + public static RequestBuilder patch(String p0){ return null; } + public static RequestBuilder patch(URI p0){ return null; } + public static RequestBuilder post(){ return null; } + public static RequestBuilder post(String p0){ return null; } + public static RequestBuilder post(URI p0){ return null; } + public static RequestBuilder put(){ return null; } + public static RequestBuilder put(String p0){ return null; } + public static RequestBuilder put(URI p0){ return null; } + public static RequestBuilder trace(){ return null; } + public static RequestBuilder trace(String p0){ return null; } + public static RequestBuilder trace(URI p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/concurrent/Cancellable.java b/java/ql/test/stubs/javafx-web/org/apache/http/concurrent/Cancellable.java new file mode 100644 index 00000000000..8ed9e80fb78 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/concurrent/Cancellable.java @@ -0,0 +1,9 @@ +// Generated automatically from org.apache.http.concurrent.Cancellable for testing purposes + +package org.apache.http.concurrent; + + +public interface Cancellable +{ + boolean cancel(); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/conn/ClientConnectionRequest.java b/java/ql/test/stubs/javafx-web/org/apache/http/conn/ClientConnectionRequest.java new file mode 100644 index 00000000000..ced43fa25bf --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/conn/ClientConnectionRequest.java @@ -0,0 +1,12 @@ +// Generated automatically from org.apache.http.conn.ClientConnectionRequest for testing purposes + +package org.apache.http.conn; + +import java.util.concurrent.TimeUnit; +import org.apache.http.conn.ManagedClientConnection; + +public interface ClientConnectionRequest +{ + ManagedClientConnection getConnection(long p0, TimeUnit p1); + void abortRequest(); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/conn/ConnectionReleaseTrigger.java b/java/ql/test/stubs/javafx-web/org/apache/http/conn/ConnectionReleaseTrigger.java new file mode 100644 index 00000000000..0a92d18bb5d --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/conn/ConnectionReleaseTrigger.java @@ -0,0 +1,10 @@ +// Generated automatically from org.apache.http.conn.ConnectionReleaseTrigger for testing purposes + +package org.apache.http.conn; + + +public interface ConnectionReleaseTrigger +{ + void abortConnection(); + void releaseConnection(); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/conn/HttpRoutedConnection.java b/java/ql/test/stubs/javafx-web/org/apache/http/conn/HttpRoutedConnection.java new file mode 100644 index 00000000000..173aaa413c9 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/conn/HttpRoutedConnection.java @@ -0,0 +1,14 @@ +// Generated automatically from org.apache.http.conn.HttpRoutedConnection for testing purposes + +package org.apache.http.conn; + +import javax.net.ssl.SSLSession; +import org.apache.http.HttpInetConnection; +import org.apache.http.conn.routing.HttpRoute; + +public interface HttpRoutedConnection extends HttpInetConnection +{ + HttpRoute getRoute(); + SSLSession getSSLSession(); + boolean isSecure(); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/conn/ManagedClientConnection.java b/java/ql/test/stubs/javafx-web/org/apache/http/conn/ManagedClientConnection.java new file mode 100644 index 00000000000..5f023965e52 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/conn/ManagedClientConnection.java @@ -0,0 +1,30 @@ +// Generated automatically from org.apache.http.conn.ManagedClientConnection for testing purposes + +package org.apache.http.conn; + +import java.util.concurrent.TimeUnit; +import javax.net.ssl.SSLSession; +import org.apache.http.HttpHost; +import org.apache.http.conn.ConnectionReleaseTrigger; +import org.apache.http.conn.HttpRoutedConnection; +import org.apache.http.conn.ManagedHttpClientConnection; +import org.apache.http.conn.routing.HttpRoute; +import org.apache.http.params.HttpParams; +import org.apache.http.protocol.HttpContext; + +public interface ManagedClientConnection extends ConnectionReleaseTrigger, HttpRoutedConnection, ManagedHttpClientConnection +{ + HttpRoute getRoute(); + Object getState(); + SSLSession getSSLSession(); + boolean isMarkedReusable(); + boolean isSecure(); + void layerProtocol(HttpContext p0, HttpParams p1); + void markReusable(); + void open(HttpRoute p0, HttpContext p1, HttpParams p2); + void setIdleDuration(long p0, TimeUnit p1); + void setState(Object p0); + void tunnelProxy(HttpHost p0, boolean p1, HttpParams p2); + void tunnelTarget(boolean p0, HttpParams p1); + void unmarkReusable(); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/conn/ManagedHttpClientConnection.java b/java/ql/test/stubs/javafx-web/org/apache/http/conn/ManagedHttpClientConnection.java new file mode 100644 index 00000000000..12020570d8f --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/conn/ManagedHttpClientConnection.java @@ -0,0 +1,16 @@ +// Generated automatically from org.apache.http.conn.ManagedHttpClientConnection for testing purposes + +package org.apache.http.conn; + +import java.net.Socket; +import javax.net.ssl.SSLSession; +import org.apache.http.HttpClientConnection; +import org.apache.http.HttpInetConnection; + +public interface ManagedHttpClientConnection extends HttpClientConnection, HttpInetConnection +{ + SSLSession getSSLSession(); + Socket getSocket(); + String getId(); + void bind(Socket p0); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/conn/routing/HttpRoute.java b/java/ql/test/stubs/javafx-web/org/apache/http/conn/routing/HttpRoute.java new file mode 100644 index 00000000000..bc1478278c0 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/conn/routing/HttpRoute.java @@ -0,0 +1,34 @@ +// Generated automatically from org.apache.http.conn.routing.HttpRoute for testing purposes + +package org.apache.http.conn.routing; + +import java.net.InetAddress; +import java.net.InetSocketAddress; +import org.apache.http.HttpHost; +import org.apache.http.conn.routing.RouteInfo; + +public class HttpRoute implements Cloneable, RouteInfo +{ + protected HttpRoute() {} + public HttpRoute(HttpHost p0){} + public HttpRoute(HttpHost p0, HttpHost p1){} + public HttpRoute(HttpHost p0, InetAddress p1, HttpHost p2, boolean p3){} + public HttpRoute(HttpHost p0, InetAddress p1, HttpHost p2, boolean p3, RouteInfo.TunnelType p4, RouteInfo.LayerType p5){} + public HttpRoute(HttpHost p0, InetAddress p1, HttpHost[] p2, boolean p3, RouteInfo.TunnelType p4, RouteInfo.LayerType p5){} + public HttpRoute(HttpHost p0, InetAddress p1, boolean p2){} + public Object clone(){ return null; } + public final HttpHost getHopTarget(int p0){ return null; } + public final HttpHost getProxyHost(){ return null; } + public final HttpHost getTargetHost(){ return null; } + public final InetAddress getLocalAddress(){ return null; } + public final InetSocketAddress getLocalSocketAddress(){ return null; } + public final RouteInfo.LayerType getLayerType(){ return null; } + public final RouteInfo.TunnelType getTunnelType(){ return null; } + public final String toString(){ return null; } + public final boolean equals(Object p0){ return false; } + public final boolean isLayered(){ return false; } + public final boolean isSecure(){ return false; } + public final boolean isTunnelled(){ return false; } + public final int getHopCount(){ return 0; } + public final int hashCode(){ return 0; } +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/conn/routing/RouteInfo.java b/java/ql/test/stubs/javafx-web/org/apache/http/conn/routing/RouteInfo.java new file mode 100644 index 00000000000..41442212714 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/conn/routing/RouteInfo.java @@ -0,0 +1,30 @@ +// Generated automatically from org.apache.http.conn.routing.RouteInfo for testing purposes + +package org.apache.http.conn.routing; + +import java.net.InetAddress; +import org.apache.http.HttpHost; + +public interface RouteInfo +{ + HttpHost getHopTarget(int p0); + HttpHost getProxyHost(); + HttpHost getTargetHost(); + InetAddress getLocalAddress(); + RouteInfo.LayerType getLayerType(); + RouteInfo.TunnelType getTunnelType(); + boolean isLayered(); + boolean isSecure(); + boolean isTunnelled(); + int getHopCount(); + static public enum LayerType + { + LAYERED, PLAIN; + private LayerType() {} + } + static public enum TunnelType + { + PLAIN, TUNNELLED; + private TunnelType() {} + } +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/message/AbstractHttpMessage.java b/java/ql/test/stubs/javafx-web/org/apache/http/message/AbstractHttpMessage.java new file mode 100644 index 00000000000..90aa1261896 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/message/AbstractHttpMessage.java @@ -0,0 +1,33 @@ +// Generated automatically from org.apache.http.message.AbstractHttpMessage for testing purposes + +package org.apache.http.message; + +import org.apache.http.Header; +import org.apache.http.HeaderIterator; +import org.apache.http.HttpMessage; +import org.apache.http.message.HeaderGroup; +import org.apache.http.params.HttpParams; + +abstract public class AbstractHttpMessage implements HttpMessage +{ + protected AbstractHttpMessage(){} + protected AbstractHttpMessage(HttpParams p0){} + protected HeaderGroup headergroup = null; + protected HttpParams params = null; + public Header getFirstHeader(String p0){ return null; } + public Header getLastHeader(String p0){ return null; } + public HeaderIterator headerIterator(){ return null; } + public HeaderIterator headerIterator(String p0){ return null; } + public Header[] getAllHeaders(){ return null; } + public Header[] getHeaders(String p0){ return null; } + public HttpParams getParams(){ return null; } + public boolean containsHeader(String p0){ return false; } + public void addHeader(Header p0){} + public void addHeader(String p0, String p1){} + public void removeHeader(Header p0){} + public void removeHeaders(String p0){} + public void setHeader(Header p0){} + public void setHeader(String p0, String p1){} + public void setHeaders(Header[] p0){} + public void setParams(HttpParams p0){} +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/message/BasicHttpEntityEnclosingRequest.java b/java/ql/test/stubs/javafx-web/org/apache/http/message/BasicHttpEntityEnclosingRequest.java new file mode 100644 index 00000000000..2d1de9d45fb --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/message/BasicHttpEntityEnclosingRequest.java @@ -0,0 +1,20 @@ +// Generated automatically from org.apache.http.message.BasicHttpEntityEnclosingRequest for testing purposes + +package org.apache.http.message; + +import org.apache.http.HttpEntity; +import org.apache.http.HttpEntityEnclosingRequest; +import org.apache.http.ProtocolVersion; +import org.apache.http.RequestLine; +import org.apache.http.message.BasicHttpRequest; + +public class BasicHttpEntityEnclosingRequest extends BasicHttpRequest implements HttpEntityEnclosingRequest +{ + protected BasicHttpEntityEnclosingRequest() {} + public BasicHttpEntityEnclosingRequest(RequestLine p0){} + public BasicHttpEntityEnclosingRequest(String p0, String p1){} + public BasicHttpEntityEnclosingRequest(String p0, String p1, ProtocolVersion p2){} + public HttpEntity getEntity(){ return null; } + public boolean expectContinue(){ return false; } + public void setEntity(HttpEntity p0){} +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/message/BasicHttpRequest.java b/java/ql/test/stubs/javafx-web/org/apache/http/message/BasicHttpRequest.java new file mode 100644 index 00000000000..455f0167a39 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/message/BasicHttpRequest.java @@ -0,0 +1,19 @@ +// Generated automatically from org.apache.http.message.BasicHttpRequest for testing purposes + +package org.apache.http.message; + +import org.apache.http.HttpRequest; +import org.apache.http.ProtocolVersion; +import org.apache.http.RequestLine; +import org.apache.http.message.AbstractHttpMessage; + +public class BasicHttpRequest extends AbstractHttpMessage implements HttpRequest +{ + protected BasicHttpRequest() {} + public BasicHttpRequest(RequestLine p0){} + public BasicHttpRequest(String p0, String p1){} + public BasicHttpRequest(String p0, String p1, ProtocolVersion p2){} + public ProtocolVersion getProtocolVersion(){ return null; } + public RequestLine getRequestLine(){ return null; } + public String toString(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/message/BasicRequestLine.java b/java/ql/test/stubs/javafx-web/org/apache/http/message/BasicRequestLine.java new file mode 100644 index 00000000000..50f3e1ceb6c --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/message/BasicRequestLine.java @@ -0,0 +1,18 @@ +// Generated automatically from org.apache.http.message.BasicRequestLine for testing purposes + +package org.apache.http.message; + +import java.io.Serializable; +import org.apache.http.ProtocolVersion; +import org.apache.http.RequestLine; + +public class BasicRequestLine implements Cloneable, RequestLine, Serializable +{ + protected BasicRequestLine() {} + public BasicRequestLine(String p0, String p1, ProtocolVersion p2){} + public Object clone(){ return null; } + public ProtocolVersion getProtocolVersion(){ return null; } + public String getMethod(){ return null; } + public String getUri(){ return null; } + public String toString(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/message/HeaderGroup.java b/java/ql/test/stubs/javafx-web/org/apache/http/message/HeaderGroup.java new file mode 100644 index 00000000000..ec6687ed789 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/message/HeaderGroup.java @@ -0,0 +1,28 @@ +// Generated automatically from org.apache.http.message.HeaderGroup for testing purposes + +package org.apache.http.message; + +import java.io.Serializable; +import org.apache.http.Header; +import org.apache.http.HeaderIterator; + +public class HeaderGroup implements Cloneable, Serializable +{ + public Header getCondensedHeader(String p0){ return null; } + public Header getFirstHeader(String p0){ return null; } + public Header getLastHeader(String p0){ return null; } + public HeaderGroup copy(){ return null; } + public HeaderGroup(){} + public HeaderIterator iterator(){ return null; } + public HeaderIterator iterator(String p0){ return null; } + public Header[] getAllHeaders(){ return null; } + public Header[] getHeaders(String p0){ return null; } + public Object clone(){ return null; } + public String toString(){ return null; } + public boolean containsHeader(String p0){ return false; } + public void addHeader(Header p0){} + public void clear(){} + public void removeHeader(Header p0){} + public void setHeaders(Header[] p0){} + public void updateHeader(Header p0){} +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/params/HttpParams.java b/java/ql/test/stubs/javafx-web/org/apache/http/params/HttpParams.java new file mode 100644 index 00000000000..13cede776d4 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/params/HttpParams.java @@ -0,0 +1,22 @@ +// Generated automatically from org.apache.http.params.HttpParams for testing purposes + +package org.apache.http.params; + + +public interface HttpParams +{ + HttpParams copy(); + HttpParams setBooleanParameter(String p0, boolean p1); + HttpParams setDoubleParameter(String p0, double p1); + HttpParams setIntParameter(String p0, int p1); + HttpParams setLongParameter(String p0, long p1); + HttpParams setParameter(String p0, Object p1); + Object getParameter(String p0); + boolean getBooleanParameter(String p0, boolean p1); + boolean isParameterFalse(String p0); + boolean isParameterTrue(String p0); + boolean removeParameter(String p0); + double getDoubleParameter(String p0, double p1); + int getIntParameter(String p0, int p1); + long getLongParameter(String p0, long p1); +} diff --git a/java/ql/test/stubs/javafx-web/org/apache/http/protocol/HttpContext.java b/java/ql/test/stubs/javafx-web/org/apache/http/protocol/HttpContext.java new file mode 100644 index 00000000000..d2e14c83858 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/apache/http/protocol/HttpContext.java @@ -0,0 +1,12 @@ +// Generated automatically from org.apache.http.protocol.HttpContext for testing purposes + +package org.apache.http.protocol; + + +public interface HttpContext +{ + Object getAttribute(String p0); + Object removeAttribute(String p0); + static String RESERVED_PREFIX = null; + void setAttribute(String p0, Object p1); +} diff --git a/java/ql/test/stubs/javafx-web/org/codehaus/cargo/container/installer/Installer.java b/java/ql/test/stubs/javafx-web/org/codehaus/cargo/container/installer/Installer.java new file mode 100644 index 00000000000..02abcd95563 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/codehaus/cargo/container/installer/Installer.java @@ -0,0 +1,11 @@ +// Generated automatically from org.codehaus.cargo.container.installer.Installer for testing purposes + +package org.codehaus.cargo.container.installer; + +import org.codehaus.cargo.util.log.Loggable; + +public interface Installer extends Loggable +{ + String getHome(); + void install(); +} diff --git a/java/ql/test/stubs/javafx-web/org/codehaus/cargo/container/installer/Proxy.java b/java/ql/test/stubs/javafx-web/org/codehaus/cargo/container/installer/Proxy.java new file mode 100644 index 00000000000..de5da1c1766 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/codehaus/cargo/container/installer/Proxy.java @@ -0,0 +1,23 @@ +// Generated automatically from org.codehaus.cargo.container.installer.Proxy for testing purposes + +package org.codehaus.cargo.container.installer; + +import java.util.Map; +import org.codehaus.cargo.util.log.LoggedObject; + +public class Proxy extends LoggedObject +{ + public Map configure(){ return null; } + public Proxy(){} + public String getExcludeHosts(){ return null; } + public String getHost(){ return null; } + public String getPassword(){ return null; } + public String getUser(){ return null; } + public int getPort(){ return 0; } + public void clear(Map p0){} + public void setExcludeHosts(String p0){} + public void setHost(String p0){} + public void setPassword(String p0){} + public void setPort(int p0){} + public void setUser(String p0){} +} diff --git a/java/ql/test/stubs/javafx-web/org/codehaus/cargo/container/installer/ZipURLInstaller.java b/java/ql/test/stubs/javafx-web/org/codehaus/cargo/container/installer/ZipURLInstaller.java new file mode 100644 index 00000000000..638a19d89fc --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/codehaus/cargo/container/installer/ZipURLInstaller.java @@ -0,0 +1,34 @@ +// Generated automatically from org.codehaus.cargo.container.installer.ZipURLInstaller for testing purposes + +package org.codehaus.cargo.container.installer; + +import java.net.URL; +import org.codehaus.cargo.container.installer.Installer; +import org.codehaus.cargo.container.installer.Proxy; +import org.codehaus.cargo.util.FileHandler; +import org.codehaus.cargo.util.log.LoggedObject; +import org.codehaus.cargo.util.log.Logger; + +public class ZipURLInstaller extends LoggedObject implements Installer +{ + protected ZipURLInstaller() {} + protected String getSourceFileName(){ return null; } + protected void doDownload(){} + public FileHandler getFileHandler(){ return null; } + public String getDownloadDir(){ return null; } + public String getDownloadFile(){ return null; } + public String getExtractDir(){ return null; } + public String getHome(){ return null; } + public ZipURLInstaller(URL p0){} + public ZipURLInstaller(URL p0, String p1, String p2){} + public boolean isAlreadyDownloaded(){ return false; } + public boolean isAlreadyExtracted(){ return false; } + public void download(){} + public void install(){} + public void registerInstallation(){} + public void setDownloadDir(String p0){} + public void setExtractDir(String p0){} + public void setFileHandler(FileHandler p0){} + public void setLogger(Logger p0){} + public void setProxy(Proxy p0){} +} diff --git a/java/ql/test/stubs/javafx-web/org/codehaus/cargo/util/FileHandler.java b/java/ql/test/stubs/javafx-web/org/codehaus/cargo/util/FileHandler.java new file mode 100644 index 00000000000..07579277d95 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/codehaus/cargo/util/FileHandler.java @@ -0,0 +1,49 @@ +// Generated automatically from org.codehaus.cargo.util.FileHandler for testing purposes + +package org.codehaus.cargo.util; + +import java.io.InputStream; +import java.io.OutputStream; +import java.nio.charset.Charset; +import java.util.List; +import java.util.Map; +import org.codehaus.cargo.util.XmlReplacement; +import org.codehaus.cargo.util.log.Loggable; + +public interface FileHandler extends Loggable +{ + InputStream getInputStream(String p0); + OutputStream getOutputStream(String p0); + String append(String p0, String p1); + String createDirectory(String p0, String p1); + String createUniqueTmpDirectory(); + String getAbsolutePath(String p0); + String getName(String p0); + String getParent(String p0); + String getTmpPath(String p0); + String getURL(String p0); + String readTextFile(String p0, Charset p1); + String[] getChildren(String p0); + String[] getChildren(String p0, List p1); + boolean exists(String p0); + boolean isDirectory(String p0); + boolean isDirectoryEmpty(String p0); + long getSize(String p0); + static String NEW_LINE = null; + void copy(InputStream p0, OutputStream p1); + void copy(InputStream p0, OutputStream p1, int p2); + void copyDirectory(String p0, String p1); + void copyDirectory(String p0, String p1, List p2); + void copyDirectory(String p0, String p1, Map p2, Charset p3); + void copyFile(String p0, String p1); + void copyFile(String p0, String p1, Map p2, Charset p3); + void copyFile(String p0, String p1, boolean p2); + void createFile(String p0); + void delete(String p0); + void explode(String p0, String p1); + void mkdirs(String p0); + void replaceInFile(String p0, Map p1, Charset p2); + void replaceInFile(String p0, Map p1, Charset p2, boolean p3); + void replaceInXmlFile(XmlReplacement... p0); + void writeTextFile(String p0, String p1, Charset p2); +} diff --git a/java/ql/test/stubs/javafx-web/org/codehaus/cargo/util/XmlReplacement.java b/java/ql/test/stubs/javafx-web/org/codehaus/cargo/util/XmlReplacement.java new file mode 100644 index 00000000000..16caa14f2b8 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/codehaus/cargo/util/XmlReplacement.java @@ -0,0 +1,28 @@ +// Generated automatically from org.codehaus.cargo.util.XmlReplacement for testing purposes + +package org.codehaus.cargo.util; + + +public class XmlReplacement +{ + public String getAttributeName(){ return null; } + public String getFile(){ return null; } + public String getValue(){ return null; } + public String getXpathExpression(){ return null; } + public String toString(){ return null; } + public XmlReplacement(){} + public XmlReplacement(String p0, String p1, String p2, XmlReplacement.ReplacementBehavior p3, String p4){} + public XmlReplacement.ReplacementBehavior getReplacementBehavior(){ return null; } + public boolean equals(Object p0){ return false; } + public int hashCode(){ return 0; } + public void setAttributeName(String p0){} + public void setFile(String p0){} + public void setReplacementBehavior(XmlReplacement.ReplacementBehavior p0){} + public void setValue(String p0){} + public void setXpathExpression(String p0){} + static public enum ReplacementBehavior + { + ADD_MISSING_NODES, IGNORE_IF_NON_EXISTING, THROW_EXCEPTION; + private ReplacementBehavior() {} + } +} diff --git a/java/ql/test/stubs/javafx-web/org/codehaus/cargo/util/log/LogLevel.java b/java/ql/test/stubs/javafx-web/org/codehaus/cargo/util/log/LogLevel.java new file mode 100644 index 00000000000..b7b0d5a37d8 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/codehaus/cargo/util/log/LogLevel.java @@ -0,0 +1,18 @@ +// Generated automatically from org.codehaus.cargo.util.log.LogLevel for testing purposes + +package org.codehaus.cargo.util.log; + + +public class LogLevel implements Comparable +{ + protected LogLevel() {} + public String getLevel(){ return null; } + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public int compareTo(LogLevel p0){ return 0; } + public int hashCode(){ return 0; } + public static LogLevel DEBUG = null; + public static LogLevel INFO = null; + public static LogLevel WARN = null; + public static LogLevel toLevel(String p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/codehaus/cargo/util/log/Loggable.java b/java/ql/test/stubs/javafx-web/org/codehaus/cargo/util/log/Loggable.java new file mode 100644 index 00000000000..3369fa27ef5 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/codehaus/cargo/util/log/Loggable.java @@ -0,0 +1,11 @@ +// Generated automatically from org.codehaus.cargo.util.log.Loggable for testing purposes + +package org.codehaus.cargo.util.log; + +import org.codehaus.cargo.util.log.Logger; + +public interface Loggable +{ + Logger getLogger(); + void setLogger(Logger p0); +} diff --git a/java/ql/test/stubs/javafx-web/org/codehaus/cargo/util/log/LoggedObject.java b/java/ql/test/stubs/javafx-web/org/codehaus/cargo/util/log/LoggedObject.java new file mode 100644 index 00000000000..421da028778 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/codehaus/cargo/util/log/LoggedObject.java @@ -0,0 +1,13 @@ +// Generated automatically from org.codehaus.cargo.util.log.LoggedObject for testing purposes + +package org.codehaus.cargo.util.log; + +import org.codehaus.cargo.util.log.Loggable; +import org.codehaus.cargo.util.log.Logger; + +public class LoggedObject implements Loggable +{ + public LoggedObject(){} + public Logger getLogger(){ return null; } + public void setLogger(Logger p0){} +} diff --git a/java/ql/test/stubs/javafx-web/org/codehaus/cargo/util/log/Logger.java b/java/ql/test/stubs/javafx-web/org/codehaus/cargo/util/log/Logger.java new file mode 100644 index 00000000000..965e4bc1ccd --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/codehaus/cargo/util/log/Logger.java @@ -0,0 +1,14 @@ +// Generated automatically from org.codehaus.cargo.util.log.Logger for testing purposes + +package org.codehaus.cargo.util.log; + +import org.codehaus.cargo.util.log.LogLevel; + +public interface Logger +{ + LogLevel getLevel(); + void debug(String p0, String p1); + void info(String p0, String p1); + void setLevel(LogLevel p0); + void warn(String p0, String p1); +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/ConnectionFactory.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/ConnectionFactory.java new file mode 100644 index 00000000000..b833b0d8b99 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/ConnectionFactory.java @@ -0,0 +1,13 @@ +// Generated automatically from org.jdbi.v3.core.ConnectionFactory for testing purposes + +package org.jdbi.v3.core; + +import java.sql.Connection; +import org.jdbi.v3.core.statement.Cleanable; + +public interface ConnectionFactory +{ + Connection openConnection(); + default Cleanable getCleanableFor(Connection p0){ return null; } + default void closeConnection(Connection p0){} +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/Handle.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/Handle.java new file mode 100644 index 00000000000..585d7fda6db --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/Handle.java @@ -0,0 +1,84 @@ +// Generated automatically from org.jdbi.v3.core.Handle for testing purposes + +package org.jdbi.v3.core; + +import java.io.Closeable; +import java.sql.Connection; +import org.jdbi.v3.core.HandleCallback; +import org.jdbi.v3.core.HandleConsumer; +import org.jdbi.v3.core.HandleListener; +import org.jdbi.v3.core.Jdbi; +import org.jdbi.v3.core.config.ConfigRegistry; +import org.jdbi.v3.core.config.Configurable; +import org.jdbi.v3.core.extension.ExtensionMethod; +import org.jdbi.v3.core.result.ResultBearing; +import org.jdbi.v3.core.statement.Batch; +import org.jdbi.v3.core.statement.Call; +import org.jdbi.v3.core.statement.Cleanable; +import org.jdbi.v3.core.statement.MetaData; +import org.jdbi.v3.core.statement.PreparedBatch; +import org.jdbi.v3.core.statement.Query; +import org.jdbi.v3.core.statement.Script; +import org.jdbi.v3.core.statement.StatementBuilder; +import org.jdbi.v3.core.statement.Update; +import org.jdbi.v3.core.transaction.TransactionIsolationLevel; + +public class Handle implements Closeable, Configurable +{ + protected Handle() {} + public R inTransaction(TransactionIsolationLevel p0, org.jdbi.v3.core.HandleCallback p1){ return null; } + public R inTransaction(org.jdbi.v3.core.HandleCallback p0){ return null; } + public T attach(java.lang.Class p0){ return null; } + public T queryMetadata(MetaData.MetaDataValueProvider p0){ return null; } + public void useTransaction(TransactionIsolationLevel p0, org.jdbi.v3.core.HandleConsumer p1){} + public void useTransaction(org.jdbi.v3.core.HandleConsumer p0){} + public Batch createBatch(){ return null; } + public Call createCall(CharSequence p0){ return null; } + public Call createCall(String p0){ return null; } + public ConfigRegistry getConfig(){ return null; } + public Connection getConnection(){ return null; } + public ExtensionMethod getExtensionMethod(){ return null; } + public Handle addHandleListener(HandleListener p0){ return null; } + public Handle afterCommit(Runnable p0){ return null; } + public Handle afterRollback(Runnable p0){ return null; } + public Handle begin(){ return null; } + public Handle commit(){ return null; } + public Handle release(String p0){ return null; } + public Handle releaseSavepoint(String p0){ return null; } + public Handle removeHandleListener(HandleListener p0){ return null; } + public Handle rollback(){ return null; } + public Handle rollbackToSavepoint(String p0){ return null; } + public Handle savepoint(String p0){ return null; } + public Handle setReadOnly(boolean p0){ return null; } + public Handle setStatementBuilder(StatementBuilder p0){ return null; } + public Jdbi getJdbi(){ return null; } + public PreparedBatch prepareBatch(CharSequence p0){ return null; } + public PreparedBatch prepareBatch(String p0){ return null; } + public Query createQuery(CharSequence p0){ return null; } + public Query createQuery(String p0){ return null; } + public Query select(CharSequence p0, Object... p1){ return null; } + public Query select(String p0, Object... p1){ return null; } + public ResultBearing queryMetadata(MetaData.MetaDataResultSetProvider p0){ return null; } + public Script createScript(CharSequence p0){ return null; } + public Script createScript(String p0){ return null; } + public StatementBuilder getStatementBuilder(){ return null; } + public TransactionIsolationLevel getTransactionIsolationLevel(){ return null; } + public Update createUpdate(CharSequence p0){ return null; } + public Update createUpdate(String p0){ return null; } + public boolean equals(Object p0){ return false; } + public boolean isClean(){ return false; } + public boolean isClosed(){ return false; } + public boolean isInTransaction(){ return false; } + public boolean isReadOnly(){ return false; } + public final void addCleanable(Cleanable p0){} + public final void removeCleanable(Cleanable p0){} + public int execute(CharSequence p0, Object... p1){ return 0; } + public int execute(String p0, Object... p1){ return 0; } + public int hashCode(){ return 0; } + public void clean(){} + public void close(){} + public void setTransactionIsolation(TransactionIsolationLevel p0){} + public void setTransactionIsolation(int p0){} + public void setTransactionIsolationLevel(TransactionIsolationLevel p0){} + public void setTransactionIsolationLevel(int p0){} +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/HandleCallback.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/HandleCallback.java new file mode 100644 index 00000000000..c6d09df1cea --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/HandleCallback.java @@ -0,0 +1,10 @@ +// Generated automatically from org.jdbi.v3.core.HandleCallback for testing purposes + +package org.jdbi.v3.core; + +import org.jdbi.v3.core.Handle; + +public interface HandleCallback +{ + T withHandle(Handle p0); +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/HandleConsumer.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/HandleConsumer.java new file mode 100644 index 00000000000..1345b45a659 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/HandleConsumer.java @@ -0,0 +1,12 @@ +// Generated automatically from org.jdbi.v3.core.HandleConsumer for testing purposes + +package org.jdbi.v3.core; + +import org.jdbi.v3.core.Handle; +import org.jdbi.v3.core.HandleCallback; + +public interface HandleConsumer +{ + default HandleCallback asCallback(){ return null; } + void useHandle(Handle p0); +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/HandleListener.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/HandleListener.java new file mode 100644 index 00000000000..5b1f14b9d7d --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/HandleListener.java @@ -0,0 +1,11 @@ +// Generated automatically from org.jdbi.v3.core.HandleListener for testing purposes + +package org.jdbi.v3.core; + +import org.jdbi.v3.core.Handle; + +public interface HandleListener +{ + default void handleClosed(Handle p0){} + default void handleCreated(Handle p0){} +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/Jdbi.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/Jdbi.java new file mode 100644 index 00000000000..7e2a1de7c77 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/Jdbi.java @@ -0,0 +1,53 @@ +// Generated automatically from org.jdbi.v3.core.Jdbi for testing purposes + +package org.jdbi.v3.core; + +import java.sql.Connection; +import java.util.Properties; +import javax.sql.DataSource; +import org.jdbi.v3.core.ConnectionFactory; +import org.jdbi.v3.core.Handle; +import org.jdbi.v3.core.HandleCallback; +import org.jdbi.v3.core.HandleConsumer; +import org.jdbi.v3.core.config.ConfigRegistry; +import org.jdbi.v3.core.config.Configurable; +import org.jdbi.v3.core.extension.ExtensionCallback; +import org.jdbi.v3.core.extension.ExtensionConsumer; +import org.jdbi.v3.core.spi.JdbiPlugin; +import org.jdbi.v3.core.statement.StatementBuilderFactory; +import org.jdbi.v3.core.transaction.TransactionHandler; +import org.jdbi.v3.core.transaction.TransactionIsolationLevel; + +public class Jdbi implements Configurable +{ + protected Jdbi() {} + public void useExtension(java.lang.Class p0, ExtensionConsumer p1){} + public E onDemand(java.lang.Class p0){ return null; } + public R withExtension(java.lang.Class p0, ExtensionCallback p1){ return null; } + public R inTransaction(TransactionIsolationLevel p0, org.jdbi.v3.core.HandleCallback p1){ return null; } + public R inTransaction(org.jdbi.v3.core.HandleCallback p0){ return null; } + public R withHandle(org.jdbi.v3.core.HandleCallback p0){ return null; } + public void useHandle(org.jdbi.v3.core.HandleConsumer p0){} + public void useTransaction(TransactionIsolationLevel p0, org.jdbi.v3.core.HandleConsumer p1){} + public void useTransaction(org.jdbi.v3.core.HandleConsumer p0){} + public ConfigRegistry getConfig(){ return null; } + public Handle open(){ return null; } + public Jdbi installPlugin(JdbiPlugin p0){ return null; } + public Jdbi installPlugins(){ return null; } + public Jdbi setStatementBuilderFactory(StatementBuilderFactory p0){ return null; } + public Jdbi setTransactionHandler(TransactionHandler p0){ return null; } + public StatementBuilderFactory getStatementBuilderFactory(){ return null; } + public TransactionHandler getTransactionHandler(){ return null; } + public static Handle open(Connection p0){ return null; } + public static Handle open(ConnectionFactory p0){ return null; } + public static Handle open(DataSource p0){ return null; } + public static Handle open(String p0){ return null; } + public static Handle open(String p0, Properties p1){ return null; } + public static Handle open(String p0, String p1, String p2){ return null; } + public static Jdbi create(Connection p0){ return null; } + public static Jdbi create(ConnectionFactory p0){ return null; } + public static Jdbi create(DataSource p0){ return null; } + public static Jdbi create(String p0){ return null; } + public static Jdbi create(String p0, Properties p1){ return null; } + public static Jdbi create(String p0, String p1, String p2){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/argument/Argument.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/argument/Argument.java new file mode 100644 index 00000000000..97cd7042772 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/argument/Argument.java @@ -0,0 +1,11 @@ +// Generated automatically from org.jdbi.v3.core.argument.Argument for testing purposes + +package org.jdbi.v3.core.argument; + +import java.sql.PreparedStatement; +import org.jdbi.v3.core.statement.StatementContext; + +public interface Argument +{ + void apply(int p0, PreparedStatement p1, StatementContext p2); +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/argument/ArgumentFactory.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/argument/ArgumentFactory.java new file mode 100644 index 00000000000..4f197c3e50e --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/argument/ArgumentFactory.java @@ -0,0 +1,21 @@ +// Generated automatically from org.jdbi.v3.core.argument.ArgumentFactory for testing purposes + +package org.jdbi.v3.core.argument; + +import java.lang.reflect.Type; +import java.util.Collection; +import java.util.Optional; +import java.util.function.Function; +import org.jdbi.v3.core.argument.Argument; +import org.jdbi.v3.core.config.ConfigRegistry; + +public interface ArgumentFactory +{ + Optional build(Type p0, Object p1, ConfigRegistry p2); + static public interface Preparable extends ArgumentFactory + { + Optional> prepare(Type p0, ConfigRegistry p1); + default Collection prePreparedTypes(){ return null; } + default Optional build(Type p0, Object p1, ConfigRegistry p2){ return null; } + } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/argument/NamedArgumentFinder.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/argument/NamedArgumentFinder.java new file mode 100644 index 00000000000..730b7f025e5 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/argument/NamedArgumentFinder.java @@ -0,0 +1,14 @@ +// Generated automatically from org.jdbi.v3.core.argument.NamedArgumentFinder for testing purposes + +package org.jdbi.v3.core.argument; + +import java.util.Collection; +import java.util.Optional; +import org.jdbi.v3.core.argument.Argument; +import org.jdbi.v3.core.statement.StatementContext; + +public interface NamedArgumentFinder +{ + Optional find(String p0, StatementContext p1); + default Collection getNames(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/argument/QualifiedArgumentFactory.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/argument/QualifiedArgumentFactory.java new file mode 100644 index 00000000000..3329c56bce8 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/argument/QualifiedArgumentFactory.java @@ -0,0 +1,24 @@ +// Generated automatically from org.jdbi.v3.core.argument.QualifiedArgumentFactory for testing purposes + +package org.jdbi.v3.core.argument; + +import java.util.Collection; +import java.util.Optional; +import java.util.function.Function; +import org.jdbi.v3.core.argument.Argument; +import org.jdbi.v3.core.argument.ArgumentFactory; +import org.jdbi.v3.core.config.ConfigRegistry; +import org.jdbi.v3.core.qualifier.QualifiedType; + +public interface QualifiedArgumentFactory +{ + Optional build(QualifiedType p0, Object p1, ConfigRegistry p2); + static QualifiedArgumentFactory adapt(ConfigRegistry p0, ArgumentFactory p1){ return null; } + static QualifiedArgumentFactory.Preparable adapt(ConfigRegistry p0, ArgumentFactory.Preparable p1){ return null; } + static public interface Preparable extends QualifiedArgumentFactory + { + Optional> prepare(QualifiedType p0, ConfigRegistry p1); + default Collection> prePreparedTypes(){ return null; } + static QualifiedArgumentFactory.Preparable adapt(ConfigRegistry p0, ArgumentFactory.Preparable p1){ return null; } + } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/argument/internal/NamedArgumentFinderFactory.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/argument/internal/NamedArgumentFinderFactory.java new file mode 100644 index 00000000000..a9d39d2b658 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/argument/internal/NamedArgumentFinderFactory.java @@ -0,0 +1,26 @@ +// Generated automatically from org.jdbi.v3.core.argument.internal.NamedArgumentFinderFactory for testing purposes + +package org.jdbi.v3.core.argument.internal; + +import java.lang.reflect.Type; +import java.util.Optional; +import java.util.function.Function; +import org.jdbi.v3.core.argument.Argument; +import org.jdbi.v3.core.config.ConfigRegistry; +import org.jdbi.v3.core.qualifier.QualifiedType; + +public interface NamedArgumentFinderFactory +{ + Function>> prepareFor(ConfigRegistry p0, Function, Function> p1, String p2, Object p3, Type p4); + NamedArgumentFinderFactory.PrepareKey keyFor(String p0, Object p1); + static NamedArgumentFinderFactory BEAN = null; + static NamedArgumentFinderFactory FIELDS = null; + static NamedArgumentFinderFactory METHODS = null; + static NamedArgumentFinderFactory POJO = null; + static public class PrepareKey + { + protected PrepareKey() {} + public boolean equals(Object p0){ return false; } + public int hashCode(){ return 0; } + } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/array/SqlArrayArgumentStrategy.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/array/SqlArrayArgumentStrategy.java new file mode 100644 index 00000000000..c7ace164c41 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/array/SqlArrayArgumentStrategy.java @@ -0,0 +1,10 @@ +// Generated automatically from org.jdbi.v3.core.array.SqlArrayArgumentStrategy for testing purposes + +package org.jdbi.v3.core.array; + + +public enum SqlArrayArgumentStrategy +{ + OBJECT_ARRAY, SQL_ARRAY; + private SqlArrayArgumentStrategy() {} +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/array/SqlArrayType.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/array/SqlArrayType.java new file mode 100644 index 00000000000..d4febf40f4e --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/array/SqlArrayType.java @@ -0,0 +1,13 @@ +// Generated automatically from org.jdbi.v3.core.array.SqlArrayType for testing purposes + +package org.jdbi.v3.core.array; + +import java.util.function.Function; + +public interface SqlArrayType +{ + Object convertArrayElement(T p0); + String getTypeName(); + default Class getArrayElementClass(){ return null; } + static SqlArrayType of(String p0, java.util.function.Function p1){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/array/SqlArrayTypeFactory.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/array/SqlArrayTypeFactory.java new file mode 100644 index 00000000000..30fa19bab35 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/array/SqlArrayTypeFactory.java @@ -0,0 +1,15 @@ +// Generated automatically from org.jdbi.v3.core.array.SqlArrayTypeFactory for testing purposes + +package org.jdbi.v3.core.array; + +import java.lang.reflect.Type; +import java.util.Optional; +import java.util.function.Function; +import org.jdbi.v3.core.array.SqlArrayType; +import org.jdbi.v3.core.config.ConfigRegistry; + +public interface SqlArrayTypeFactory +{ + Optional> build(Type p0, ConfigRegistry p1); + static SqlArrayTypeFactory of(java.lang.Class p0, String p1, java.util.function.Function p2){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/codec/Codec.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/codec/Codec.java new file mode 100644 index 00000000000..d8bc947b036 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/codec/Codec.java @@ -0,0 +1,16 @@ +// Generated automatically from org.jdbi.v3.core.codec.Codec for testing purposes + +package org.jdbi.v3.core.codec; + +import java.util.function.Function; +import org.jdbi.v3.core.argument.Argument; +import org.jdbi.v3.core.config.ConfigRegistry; +import org.jdbi.v3.core.mapper.ColumnMapper; + +public interface Codec +{ + default Function getArgumentFunction(){ return null; } + default Function getArgumentFunction(ConfigRegistry p0){ return null; } + default org.jdbi.v3.core.mapper.ColumnMapper getColumnMapper(){ return null; } + default org.jdbi.v3.core.mapper.ColumnMapper getColumnMapper(ConfigRegistry p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/codec/CodecFactory.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/codec/CodecFactory.java new file mode 100644 index 00000000000..0e704cd90e8 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/codec/CodecFactory.java @@ -0,0 +1,41 @@ +// Generated automatically from org.jdbi.v3.core.codec.CodecFactory for testing purposes + +package org.jdbi.v3.core.codec; + +import java.lang.reflect.Type; +import java.util.Collection; +import java.util.Map; +import java.util.Optional; +import java.util.concurrent.ConcurrentMap; +import java.util.function.Function; +import org.jdbi.v3.core.argument.Argument; +import org.jdbi.v3.core.argument.QualifiedArgumentFactory; +import org.jdbi.v3.core.codec.Codec; +import org.jdbi.v3.core.config.ConfigRegistry; +import org.jdbi.v3.core.generic.GenericType; +import org.jdbi.v3.core.mapper.ColumnMapper; +import org.jdbi.v3.core.mapper.QualifiedColumnMapperFactory; +import org.jdbi.v3.core.qualifier.QualifiedType; + +public class CodecFactory implements QualifiedArgumentFactory.Preparable, QualifiedColumnMapperFactory +{ + protected CodecFactory() {} + protected Codec resolveType(QualifiedType p0){ return null; } + protected final ConcurrentMap, Codec> codecMap = null; + public CodecFactory(Map, Codec> p0){} + public final Collection> prePreparedTypes(){ return null; } + public final Optional build(QualifiedType p0, Object p1, ConfigRegistry p2){ return null; } + public final Optional> build(QualifiedType p0, ConfigRegistry p1){ return null; } + public final Optional> prepare(QualifiedType p0, ConfigRegistry p1){ return null; } + public static CodecFactory forSingleCodec(QualifiedType p0, Codec p1){ return null; } + public static CodecFactory.Builder builder(){ return null; } + static public class Builder + { + protected Builder() {} + public Builder(Function, Codec>, CodecFactory> p0){} + public CodecFactory build(){ return null; } + public CodecFactory.Builder addCodec(GenericType p0, Codec p1){ return null; } + public CodecFactory.Builder addCodec(QualifiedType p0, Codec p1){ return null; } + public CodecFactory.Builder addCodec(Type p0, Codec p1){ return null; } + } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/collector/CollectorFactory.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/collector/CollectorFactory.java new file mode 100644 index 00000000000..1e528c775e8 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/collector/CollectorFactory.java @@ -0,0 +1,14 @@ +// Generated automatically from org.jdbi.v3.core.collector.CollectorFactory for testing purposes + +package org.jdbi.v3.core.collector; + +import java.lang.reflect.Type; +import java.util.Optional; +import java.util.stream.Collector; + +public interface CollectorFactory +{ + Collector build(Type p0); + Optional elementType(Type p0); + boolean accepts(Type p0); +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/config/ConfigRegistry.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/config/ConfigRegistry.java new file mode 100644 index 00000000000..9cf7e64624a --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/config/ConfigRegistry.java @@ -0,0 +1,12 @@ +// Generated automatically from org.jdbi.v3.core.config.ConfigRegistry for testing purposes + +package org.jdbi.v3.core.config; + +import org.jdbi.v3.core.config.JdbiConfig; + +public class ConfigRegistry +{ + public > C get(java.lang.Class p0){ return null; } + public ConfigRegistry createCopy(){ return null; } + public ConfigRegistry(){} +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/config/Configurable.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/config/Configurable.java new file mode 100644 index 00000000000..0095f59b849 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/config/Configurable.java @@ -0,0 +1,64 @@ +// Generated automatically from org.jdbi.v3.core.config.Configurable for testing purposes + +package org.jdbi.v3.core.config; + +import java.lang.reflect.Type; +import java.util.function.Consumer; +import java.util.function.Function; +import org.jdbi.v3.core.argument.ArgumentFactory; +import org.jdbi.v3.core.argument.QualifiedArgumentFactory; +import org.jdbi.v3.core.array.SqlArrayArgumentStrategy; +import org.jdbi.v3.core.array.SqlArrayType; +import org.jdbi.v3.core.array.SqlArrayTypeFactory; +import org.jdbi.v3.core.codec.CodecFactory; +import org.jdbi.v3.core.collector.CollectorFactory; +import org.jdbi.v3.core.config.ConfigRegistry; +import org.jdbi.v3.core.config.JdbiConfig; +import org.jdbi.v3.core.extension.ExtensionFactory; +import org.jdbi.v3.core.generic.GenericType; +import org.jdbi.v3.core.mapper.ColumnMapper; +import org.jdbi.v3.core.mapper.ColumnMapperFactory; +import org.jdbi.v3.core.mapper.QualifiedColumnMapperFactory; +import org.jdbi.v3.core.mapper.RowMapper; +import org.jdbi.v3.core.mapper.RowMapperFactory; +import org.jdbi.v3.core.qualifier.QualifiedType; +import org.jdbi.v3.core.statement.SqlLogger; +import org.jdbi.v3.core.statement.SqlParser; +import org.jdbi.v3.core.statement.StatementCustomizer; +import org.jdbi.v3.core.statement.TemplateEngine; +import org.jdbi.v3.core.statement.TimingCollector; + +public interface Configurable +{ + ConfigRegistry getConfig(); + default > C getConfig(java.lang.Class p0){ return null; } + default > This configure(java.lang.Class p0, java.util.function.Consumer p1){ return null; } + default This registerArrayType(java.lang.Class p0, String p1, java.util.function.Function p2){ return null; } + default This registerColumnMapper(org.jdbi.v3.core.generic.GenericType p0, org.jdbi.v3.core.mapper.ColumnMapper p1){ return null; } + default This registerColumnMapper(org.jdbi.v3.core.qualifier.QualifiedType p0, org.jdbi.v3.core.mapper.ColumnMapper p1){ return null; } + default This registerRowMapper(org.jdbi.v3.core.generic.GenericType p0, org.jdbi.v3.core.mapper.RowMapper p1){ return null; } + default This addCustomizer(StatementCustomizer p0){ return null; } + default This define(String p0, Object p1){ return null; } + default This registerArgument(ArgumentFactory p0){ return null; } + default This registerArgument(QualifiedArgumentFactory p0){ return null; } + default This registerArrayType(Class p0, String p1){ return null; } + default This registerArrayType(SqlArrayType p0){ return null; } + default This registerArrayType(SqlArrayTypeFactory p0){ return null; } + default This registerCodecFactory(CodecFactory p0){ return null; } + default This registerCollector(CollectorFactory p0){ return null; } + default This registerColumnMapper(ColumnMapper p0){ return null; } + default This registerColumnMapper(ColumnMapperFactory p0){ return null; } + default This registerColumnMapper(QualifiedColumnMapperFactory p0){ return null; } + default This registerColumnMapper(Type p0, ColumnMapper p1){ return null; } + default This registerExtension(ExtensionFactory p0){ return null; } + default This registerRowMapper(RowMapper p0){ return null; } + default This registerRowMapper(RowMapperFactory p0){ return null; } + default This registerRowMapper(Type p0, RowMapper p1){ return null; } + default This setMapKeyColumn(String p0){ return null; } + default This setMapValueColumn(String p0){ return null; } + default This setSqlArrayArgumentStrategy(SqlArrayArgumentStrategy p0){ return null; } + default This setSqlLogger(SqlLogger p0){ return null; } + default This setSqlParser(SqlParser p0){ return null; } + default This setTemplateEngine(TemplateEngine p0){ return null; } + default This setTimingCollector(TimingCollector p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/config/JdbiConfig.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/config/JdbiConfig.java new file mode 100644 index 00000000000..fe64fb2c370 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/config/JdbiConfig.java @@ -0,0 +1,11 @@ +// Generated automatically from org.jdbi.v3.core.config.JdbiConfig for testing purposes + +package org.jdbi.v3.core.config; + +import org.jdbi.v3.core.config.ConfigRegistry; + +public interface JdbiConfig> +{ + This createCopy(); + default void setRegistry(ConfigRegistry p0){} +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/extension/ExtensionCallback.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/extension/ExtensionCallback.java new file mode 100644 index 00000000000..ba52cd12f4b --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/extension/ExtensionCallback.java @@ -0,0 +1,9 @@ +// Generated automatically from org.jdbi.v3.core.extension.ExtensionCallback for testing purposes + +package org.jdbi.v3.core.extension; + + +public interface ExtensionCallback +{ + R withExtension(E p0); +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/extension/ExtensionConsumer.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/extension/ExtensionConsumer.java new file mode 100644 index 00000000000..a1fbc338e51 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/extension/ExtensionConsumer.java @@ -0,0 +1,9 @@ +// Generated automatically from org.jdbi.v3.core.extension.ExtensionConsumer for testing purposes + +package org.jdbi.v3.core.extension; + + +public interface ExtensionConsumer +{ + void useExtension(E p0); +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/extension/ExtensionContext.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/extension/ExtensionContext.java new file mode 100644 index 00000000000..0788bc0b337 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/extension/ExtensionContext.java @@ -0,0 +1,15 @@ +// Generated automatically from org.jdbi.v3.core.extension.ExtensionContext for testing purposes + +package org.jdbi.v3.core.extension; + +import org.jdbi.v3.core.config.ConfigRegistry; +import org.jdbi.v3.core.extension.ExtensionMethod; + +public class ExtensionContext +{ + protected ExtensionContext() {} + public ConfigRegistry getConfig(){ return null; } + public ExtensionContext(ConfigRegistry p0, ExtensionMethod p1){} + public ExtensionMethod getExtensionMethod(){ return null; } + public static ExtensionContext forConfig(ConfigRegistry p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/extension/ExtensionFactory.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/extension/ExtensionFactory.java new file mode 100644 index 00000000000..920b0fce8dc --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/extension/ExtensionFactory.java @@ -0,0 +1,11 @@ +// Generated automatically from org.jdbi.v3.core.extension.ExtensionFactory for testing purposes + +package org.jdbi.v3.core.extension; + +import org.jdbi.v3.core.extension.HandleSupplier; + +public interface ExtensionFactory +{ + E attach(java.lang.Class p0, HandleSupplier p1); + boolean accepts(Class p0); +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/extension/ExtensionMethod.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/extension/ExtensionMethod.java new file mode 100644 index 00000000000..42792f09578 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/extension/ExtensionMethod.java @@ -0,0 +1,14 @@ +// Generated automatically from org.jdbi.v3.core.extension.ExtensionMethod for testing purposes + +package org.jdbi.v3.core.extension; + +import java.lang.reflect.Method; + +public class ExtensionMethod +{ + protected ExtensionMethod() {} + public Class getType(){ return null; } + public ExtensionMethod(Class p0, Method p1){} + public Method getMethod(){ return null; } + public String toString(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/extension/HandleSupplier.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/extension/HandleSupplier.java new file mode 100644 index 00000000000..1fbac152c49 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/extension/HandleSupplier.java @@ -0,0 +1,20 @@ +// Generated automatically from org.jdbi.v3.core.extension.HandleSupplier for testing purposes + +package org.jdbi.v3.core.extension; + +import java.util.concurrent.Callable; +import org.jdbi.v3.core.Handle; +import org.jdbi.v3.core.Jdbi; +import org.jdbi.v3.core.config.ConfigRegistry; +import org.jdbi.v3.core.config.Configurable; +import org.jdbi.v3.core.extension.ExtensionContext; +import org.jdbi.v3.core.extension.ExtensionMethod; + +public interface HandleSupplier extends AutoCloseable, Configurable +{ + V invokeInContext(ExtensionMethod p0, ConfigRegistry p1, java.util.concurrent.Callable p2); + Handle getHandle(); + Jdbi getJdbi(); + default V invokeInContext(ExtensionContext p0, java.util.concurrent.Callable p1){ return null; } + default void close(){} +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/generic/GenericType.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/generic/GenericType.java new file mode 100644 index 00000000000..9de35ccd9df --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/generic/GenericType.java @@ -0,0 +1,11 @@ +// Generated automatically from org.jdbi.v3.core.generic.GenericType for testing purposes + +package org.jdbi.v3.core.generic; + +import java.lang.reflect.Type; + +abstract public class GenericType +{ + protected GenericType(){} + public final Type getType(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/mapper/ColumnMapper.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/mapper/ColumnMapper.java new file mode 100644 index 00000000000..c35ffb6e968 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/mapper/ColumnMapper.java @@ -0,0 +1,15 @@ +// Generated automatically from org.jdbi.v3.core.mapper.ColumnMapper for testing purposes + +package org.jdbi.v3.core.mapper; + +import java.sql.ResultSet; +import org.jdbi.v3.core.config.ConfigRegistry; +import org.jdbi.v3.core.statement.StatementContext; + +public interface ColumnMapper +{ + T map(ResultSet p0, int p1, StatementContext p2); + default T map(ResultSet p0, String p1, StatementContext p2){ return null; } + default void init(ConfigRegistry p0){} + static ColumnMapper getDefaultColumnMapper(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/mapper/ColumnMapperFactory.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/mapper/ColumnMapperFactory.java new file mode 100644 index 00000000000..6993098aaec --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/mapper/ColumnMapperFactory.java @@ -0,0 +1,14 @@ +// Generated automatically from org.jdbi.v3.core.mapper.ColumnMapperFactory for testing purposes + +package org.jdbi.v3.core.mapper; + +import java.lang.reflect.Type; +import java.util.Optional; +import org.jdbi.v3.core.config.ConfigRegistry; +import org.jdbi.v3.core.mapper.ColumnMapper; + +public interface ColumnMapperFactory +{ + Optional> build(Type p0, ConfigRegistry p1); + static ColumnMapperFactory of(Type p0, ColumnMapper p1){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/mapper/QualifiedColumnMapperFactory.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/mapper/QualifiedColumnMapperFactory.java new file mode 100644 index 00000000000..e4e9a3c1c53 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/mapper/QualifiedColumnMapperFactory.java @@ -0,0 +1,16 @@ +// Generated automatically from org.jdbi.v3.core.mapper.QualifiedColumnMapperFactory for testing purposes + +package org.jdbi.v3.core.mapper; + +import java.util.Optional; +import org.jdbi.v3.core.config.ConfigRegistry; +import org.jdbi.v3.core.mapper.ColumnMapper; +import org.jdbi.v3.core.mapper.ColumnMapperFactory; +import org.jdbi.v3.core.qualifier.QualifiedType; + +public interface QualifiedColumnMapperFactory +{ + Optional> build(QualifiedType p0, ConfigRegistry p1); + static QualifiedColumnMapperFactory of(org.jdbi.v3.core.qualifier.QualifiedType p0, org.jdbi.v3.core.mapper.ColumnMapper p1){ return null; } + static QualifiedColumnMapperFactory adapt(ColumnMapperFactory p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/mapper/RowMapper.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/mapper/RowMapper.java new file mode 100644 index 00000000000..f0a802777c6 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/mapper/RowMapper.java @@ -0,0 +1,14 @@ +// Generated automatically from org.jdbi.v3.core.mapper.RowMapper for testing purposes + +package org.jdbi.v3.core.mapper; + +import java.sql.ResultSet; +import org.jdbi.v3.core.config.ConfigRegistry; +import org.jdbi.v3.core.statement.StatementContext; + +public interface RowMapper +{ + T map(ResultSet p0, StatementContext p1); + default RowMapper specialize(ResultSet p0, StatementContext p1){ return null; } + default void init(ConfigRegistry p0){} +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/mapper/RowMapperFactory.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/mapper/RowMapperFactory.java new file mode 100644 index 00000000000..41bcf489c69 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/mapper/RowMapperFactory.java @@ -0,0 +1,14 @@ +// Generated automatically from org.jdbi.v3.core.mapper.RowMapperFactory for testing purposes + +package org.jdbi.v3.core.mapper; + +import java.lang.reflect.Type; +import java.util.Optional; +import org.jdbi.v3.core.config.ConfigRegistry; +import org.jdbi.v3.core.mapper.RowMapper; + +public interface RowMapperFactory +{ + Optional> build(Type p0, ConfigRegistry p1); + static RowMapperFactory of(Type p0, RowMapper p1){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/mapper/RowViewMapper.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/mapper/RowViewMapper.java new file mode 100644 index 00000000000..39bb8ba57c9 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/mapper/RowViewMapper.java @@ -0,0 +1,15 @@ +// Generated automatically from org.jdbi.v3.core.mapper.RowViewMapper for testing purposes + +package org.jdbi.v3.core.mapper; + +import java.sql.ResultSet; +import org.jdbi.v3.core.mapper.RowMapper; +import org.jdbi.v3.core.result.RowView; +import org.jdbi.v3.core.statement.StatementContext; + +public interface RowViewMapper extends org.jdbi.v3.core.mapper.RowMapper +{ + T map(RowView p0); + default T map(ResultSet p0, StatementContext p1){ return null; } + default org.jdbi.v3.core.mapper.RowMapper specialize(ResultSet p0, StatementContext p1){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/qualifier/QualifiedType.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/qualifier/QualifiedType.java new file mode 100644 index 00000000000..2df261c613d --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/qualifier/QualifiedType.java @@ -0,0 +1,30 @@ +// Generated automatically from org.jdbi.v3.core.qualifier.QualifiedType for testing purposes + +package org.jdbi.v3.core.qualifier; + +import java.lang.annotation.Annotation; +import java.lang.reflect.Type; +import java.util.Optional; +import java.util.Set; +import java.util.function.Function; +import org.jdbi.v3.core.generic.GenericType; + +public class QualifiedType +{ + protected QualifiedType() {} + public Optional> flatMapType(Function> p0){ return null; } + public QualifiedType mapType(Function p0){ return null; } + public QualifiedType with(Annotation... p0){ return null; } + public QualifiedType withAnnotationClasses(Iterable> p0){ return null; } + public QualifiedType withAnnotations(Iterable p0){ return null; } + public Set getQualifiers(){ return null; } + public String toString(){ return null; } + public Type getType(){ return null; } + public boolean equals(Object p0){ return false; } + public boolean hasQualifier(Class p0){ return false; } + public final QualifiedType with(Class... p0){ return null; } + public int hashCode(){ return 0; } + public static org.jdbi.v3.core.qualifier.QualifiedType of(java.lang.Class p0){ return null; } + public static org.jdbi.v3.core.qualifier.QualifiedType of(org.jdbi.v3.core.generic.GenericType p0){ return null; } + public static QualifiedType of(Type p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/BatchResultBearing.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/BatchResultBearing.java new file mode 100644 index 00000000000..abd2df035f8 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/BatchResultBearing.java @@ -0,0 +1,49 @@ +// Generated automatically from org.jdbi.v3.core.result.BatchResultBearing for testing purposes + +package org.jdbi.v3.core.result; + +import java.lang.reflect.Type; +import java.util.Map; +import java.util.function.BiConsumer; +import java.util.function.BiFunction; +import java.util.function.Supplier; +import java.util.stream.Collector; +import java.util.stream.Stream; +import org.jdbi.v3.core.generic.GenericType; +import org.jdbi.v3.core.mapper.ColumnMapper; +import org.jdbi.v3.core.mapper.RowMapper; +import org.jdbi.v3.core.mapper.RowViewMapper; +import org.jdbi.v3.core.qualifier.QualifiedType; +import org.jdbi.v3.core.result.BatchResultIterable; +import org.jdbi.v3.core.result.ResultBearing; +import org.jdbi.v3.core.result.ResultSetAccumulator; +import org.jdbi.v3.core.result.ResultSetScanner; +import org.jdbi.v3.core.result.RowReducer; +import org.jdbi.v3.core.result.RowView; + +public class BatchResultBearing implements ResultBearing +{ + protected BatchResultBearing() {} + public R collectRows(java.util.stream.Collector p0){ return null; } + public java.util.stream.Stream reduceRows(org.jdbi.v3.core.result.RowReducer p0){ return null; } + public java.util.stream.Stream reduceRows(java.util.function.BiConsumer, RowView> p0){ return null; } + public R collectInto(java.lang.Class p0){ return null; } + public R collectInto(org.jdbi.v3.core.generic.GenericType p0){ return null; } + public R scanResultSet(org.jdbi.v3.core.result.ResultSetScanner p0){ return null; } + public org.jdbi.v3.core.result.BatchResultIterable map(org.jdbi.v3.core.mapper.ColumnMapper p0){ return null; } + public org.jdbi.v3.core.result.BatchResultIterable map(org.jdbi.v3.core.mapper.RowMapper p0){ return null; } + public org.jdbi.v3.core.result.BatchResultIterable map(org.jdbi.v3.core.mapper.RowViewMapper p0){ return null; } + public org.jdbi.v3.core.result.BatchResultIterable mapTo(java.lang.Class p0){ return null; } + public org.jdbi.v3.core.result.BatchResultIterable mapTo(org.jdbi.v3.core.generic.GenericType p0){ return null; } + public org.jdbi.v3.core.result.BatchResultIterable mapTo(org.jdbi.v3.core.qualifier.QualifiedType p0){ return null; } + public org.jdbi.v3.core.result.BatchResultIterable mapToBean(java.lang.Class p0){ return null; } + public org.jdbi.v3.core.result.BatchResultIterable> mapToMap(java.lang.Class p0){ return null; } + public org.jdbi.v3.core.result.BatchResultIterable> mapToMap(org.jdbi.v3.core.generic.GenericType p0){ return null; } + public U reduceResultSet(U p0, org.jdbi.v3.core.result.ResultSetAccumulator p1){ return null; } + public U reduceRows(U p0, java.util.function.BiFunction p1){ return null; } + public BatchResultBearing(ResultBearing p0, Supplier p1){} + public BatchResultIterable mapTo(Type p0){ return null; } + public BatchResultIterable> mapToMap(){ return null; } + public Object collectInto(Type p0){ return null; } + public int[] modifiedRowCounts(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/BatchResultIterable.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/BatchResultIterable.java new file mode 100644 index 00000000000..355bbc6912a --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/BatchResultIterable.java @@ -0,0 +1,13 @@ +// Generated automatically from org.jdbi.v3.core.result.BatchResultIterable for testing purposes + +package org.jdbi.v3.core.result; + +import java.util.List; +import java.util.function.Supplier; +import org.jdbi.v3.core.result.ResultIterable; + +public interface BatchResultIterable extends org.jdbi.v3.core.result.ResultIterable +{ + List> listPerBatch(); + static BatchResultIterable of(ResultIterable p0, Supplier p1){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/IteratorCallback.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/IteratorCallback.java new file mode 100644 index 00000000000..d1f6cb5bbb4 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/IteratorCallback.java @@ -0,0 +1,10 @@ +// Generated automatically from org.jdbi.v3.core.result.IteratorCallback for testing purposes + +package org.jdbi.v3.core.result; + +import org.jdbi.v3.core.result.ResultIterator; + +public interface IteratorCallback +{ + R withIterator(org.jdbi.v3.core.result.ResultIterator p0); +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/IteratorConsumer.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/IteratorConsumer.java new file mode 100644 index 00000000000..63f621c1acb --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/IteratorConsumer.java @@ -0,0 +1,10 @@ +// Generated automatically from org.jdbi.v3.core.result.IteratorConsumer for testing purposes + +package org.jdbi.v3.core.result; + +import org.jdbi.v3.core.result.ResultIterator; + +public interface IteratorConsumer +{ + void useIterator(org.jdbi.v3.core.result.ResultIterator p0); +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/ResultBearing.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/ResultBearing.java new file mode 100644 index 00000000000..e4ab825e581 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/ResultBearing.java @@ -0,0 +1,48 @@ +// Generated automatically from org.jdbi.v3.core.result.ResultBearing for testing purposes + +package org.jdbi.v3.core.result; + +import java.lang.reflect.Type; +import java.sql.ResultSet; +import java.util.Map; +import java.util.function.BiConsumer; +import java.util.function.BiFunction; +import java.util.function.Supplier; +import java.util.stream.Collector; +import java.util.stream.Stream; +import org.jdbi.v3.core.generic.GenericType; +import org.jdbi.v3.core.mapper.ColumnMapper; +import org.jdbi.v3.core.mapper.RowMapper; +import org.jdbi.v3.core.mapper.RowViewMapper; +import org.jdbi.v3.core.qualifier.QualifiedType; +import org.jdbi.v3.core.result.ResultIterable; +import org.jdbi.v3.core.result.ResultSetAccumulator; +import org.jdbi.v3.core.result.ResultSetScanner; +import org.jdbi.v3.core.result.RowReducer; +import org.jdbi.v3.core.result.RowView; +import org.jdbi.v3.core.statement.StatementContext; + +public interface ResultBearing +{ + R scanResultSet(org.jdbi.v3.core.result.ResultSetScanner p0); + default R collectRows(java.util.stream.Collector p0){ return null; } + default java.util.stream.Stream reduceRows(org.jdbi.v3.core.result.RowReducer p0){ return null; } + default java.util.stream.Stream reduceRows(java.util.function.BiConsumer, RowView> p0){ return null; } + default R collectInto(java.lang.Class p0){ return null; } + default R collectInto(org.jdbi.v3.core.generic.GenericType p0){ return null; } + default org.jdbi.v3.core.result.ResultIterable map(org.jdbi.v3.core.mapper.ColumnMapper p0){ return null; } + default org.jdbi.v3.core.result.ResultIterable map(org.jdbi.v3.core.mapper.RowMapper p0){ return null; } + default org.jdbi.v3.core.result.ResultIterable map(org.jdbi.v3.core.mapper.RowViewMapper p0){ return null; } + default org.jdbi.v3.core.result.ResultIterable mapTo(java.lang.Class p0){ return null; } + default org.jdbi.v3.core.result.ResultIterable mapTo(org.jdbi.v3.core.generic.GenericType p0){ return null; } + default org.jdbi.v3.core.result.ResultIterable mapTo(org.jdbi.v3.core.qualifier.QualifiedType p0){ return null; } + default org.jdbi.v3.core.result.ResultIterable mapToBean(java.lang.Class p0){ return null; } + default org.jdbi.v3.core.result.ResultIterable> mapToMap(java.lang.Class p0){ return null; } + default org.jdbi.v3.core.result.ResultIterable> mapToMap(org.jdbi.v3.core.generic.GenericType p0){ return null; } + default U reduceResultSet(U p0, org.jdbi.v3.core.result.ResultSetAccumulator p1){ return null; } + default U reduceRows(U p0, java.util.function.BiFunction p1){ return null; } + default Object collectInto(Type p0){ return null; } + default ResultIterable mapTo(Type p0){ return null; } + default ResultIterable> mapToMap(){ return null; } + static ResultBearing of(Supplier p0, StatementContext p1){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/ResultIterable.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/ResultIterable.java new file mode 100644 index 00000000000..3a4bb976b57 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/ResultIterable.java @@ -0,0 +1,45 @@ +// Generated automatically from org.jdbi.v3.core.result.ResultIterable for testing purposes + +package org.jdbi.v3.core.result; + +import java.sql.ResultSet; +import java.util.List; +import java.util.Optional; +import java.util.function.BiFunction; +import java.util.function.Consumer; +import java.util.function.Function; +import java.util.function.Predicate; +import java.util.function.Supplier; +import java.util.stream.Collector; +import java.util.stream.Stream; +import org.jdbi.v3.core.mapper.RowMapper; +import org.jdbi.v3.core.result.IteratorCallback; +import org.jdbi.v3.core.result.IteratorConsumer; +import org.jdbi.v3.core.result.ResultIterator; +import org.jdbi.v3.core.result.StreamCallback; +import org.jdbi.v3.core.result.StreamConsumer; +import org.jdbi.v3.core.statement.StatementContext; + +public interface ResultIterable extends java.lang.Iterable +{ + default R withIterator(org.jdbi.v3.core.result.IteratorCallback p0){ return null; } + default R withStream(org.jdbi.v3.core.result.StreamCallback p0){ return null; } + default R collect(java.util.stream.Collector p0){ return null; } + default ResultIterable map(java.util.function.Function p0){ return null; } + default U reduce(U p0, java.util.function.BiFunction p1){ return null; } + default void useIterator(org.jdbi.v3.core.result.IteratorConsumer p0){} + default void useStream(org.jdbi.v3.core.result.StreamConsumer p0){} + default ResultIterable filter(java.util.function.Predicate p0){ return null; } + default T findOnly(){ return null; } + default T first(){ return null; } + default T one(){ return null; } + default int forEachWithCount(java.util.function.Consumer p0){ return 0; } + default java.util.List list(){ return null; } + default java.util.Optional findFirst(){ return null; } + default java.util.Optional findOne(){ return null; } + default java.util.stream.Stream stream(){ return null; } + default void forEach(java.util.function.Consumer p0){} + org.jdbi.v3.core.result.ResultIterator iterator(); + static org.jdbi.v3.core.result.ResultIterable of(Supplier p0, org.jdbi.v3.core.mapper.RowMapper p1, StatementContext p2){ return null; } + static org.jdbi.v3.core.result.ResultIterable of(org.jdbi.v3.core.result.ResultIterator p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/ResultIterator.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/ResultIterator.java new file mode 100644 index 00000000000..1efb74ff8a2 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/ResultIterator.java @@ -0,0 +1,15 @@ +// Generated automatically from org.jdbi.v3.core.result.ResultIterator for testing purposes + +package org.jdbi.v3.core.result; + +import java.io.Closeable; +import java.util.Iterator; +import java.util.function.Consumer; +import org.jdbi.v3.core.statement.StatementContext; + +public interface ResultIterator extends Closeable, java.util.Iterator +{ + StatementContext getContext(); + default void forEachRemaining(java.util.function.Consumer p0){} + void close(); +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/ResultProducer.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/ResultProducer.java new file mode 100644 index 00000000000..b3abe5bd54f --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/ResultProducer.java @@ -0,0 +1,12 @@ +// Generated automatically from org.jdbi.v3.core.result.ResultProducer for testing purposes + +package org.jdbi.v3.core.result; + +import java.sql.PreparedStatement; +import java.util.function.Supplier; +import org.jdbi.v3.core.statement.StatementContext; + +public interface ResultProducer +{ + R produce(Supplier p0, StatementContext p1); +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/ResultSetAccumulator.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/ResultSetAccumulator.java new file mode 100644 index 00000000000..0b85ffce1e0 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/ResultSetAccumulator.java @@ -0,0 +1,11 @@ +// Generated automatically from org.jdbi.v3.core.result.ResultSetAccumulator for testing purposes + +package org.jdbi.v3.core.result; + +import java.sql.ResultSet; +import org.jdbi.v3.core.statement.StatementContext; + +public interface ResultSetAccumulator +{ + T apply(T p0, ResultSet p1, StatementContext p2); +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/ResultSetScanner.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/ResultSetScanner.java new file mode 100644 index 00000000000..0634bb27a14 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/ResultSetScanner.java @@ -0,0 +1,12 @@ +// Generated automatically from org.jdbi.v3.core.result.ResultSetScanner for testing purposes + +package org.jdbi.v3.core.result; + +import java.sql.ResultSet; +import java.util.function.Supplier; +import org.jdbi.v3.core.statement.StatementContext; + +public interface ResultSetScanner +{ + T scanResultSet(Supplier p0, StatementContext p1); +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/RowReducer.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/RowReducer.java new file mode 100644 index 00000000000..39d5d403f3f --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/RowReducer.java @@ -0,0 +1,13 @@ +// Generated automatically from org.jdbi.v3.core.result.RowReducer for testing purposes + +package org.jdbi.v3.core.result; + +import java.util.stream.Stream; +import org.jdbi.v3.core.result.RowView; + +public interface RowReducer +{ + C container(); + java.util.stream.Stream stream(C p0); + void accumulate(C p0, RowView p1); +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/RowView.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/RowView.java new file mode 100644 index 00000000000..68e85d9fdcc --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/RowView.java @@ -0,0 +1,23 @@ +// Generated automatically from org.jdbi.v3.core.result.RowView for testing purposes + +package org.jdbi.v3.core.result; + +import java.lang.reflect.Type; +import org.jdbi.v3.core.generic.GenericType; +import org.jdbi.v3.core.qualifier.QualifiedType; + +abstract public class RowView +{ + public T getColumn(String p0, java.lang.Class p1){ return null; } + public T getColumn(String p0, org.jdbi.v3.core.generic.GenericType p1){ return null; } + public T getColumn(int p0, java.lang.Class p1){ return null; } + public T getColumn(int p0, org.jdbi.v3.core.generic.GenericType p1){ return null; } + public T getRow(java.lang.Class p0){ return null; } + public T getRow(org.jdbi.v3.core.generic.GenericType p0){ return null; } + public Object getColumn(String p0, Type p1){ return null; } + public Object getColumn(int p0, Type p1){ return null; } + public RowView(){} + public abstract T getColumn(String p0, org.jdbi.v3.core.qualifier.QualifiedType p1); + public abstract T getColumn(int p0, org.jdbi.v3.core.qualifier.QualifiedType p1); + public abstract Object getRow(Type p0); +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/StreamCallback.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/StreamCallback.java new file mode 100644 index 00000000000..fda0f043f81 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/StreamCallback.java @@ -0,0 +1,10 @@ +// Generated automatically from org.jdbi.v3.core.result.StreamCallback for testing purposes + +package org.jdbi.v3.core.result; + +import java.util.stream.Stream; + +public interface StreamCallback +{ + R withStream(java.util.stream.Stream p0); +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/StreamConsumer.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/StreamConsumer.java new file mode 100644 index 00000000000..d836b0aa885 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/result/StreamConsumer.java @@ -0,0 +1,10 @@ +// Generated automatically from org.jdbi.v3.core.result.StreamConsumer for testing purposes + +package org.jdbi.v3.core.result; + +import java.util.stream.Stream; + +public interface StreamConsumer +{ + void useStream(java.util.stream.Stream p0); +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/spi/JdbiPlugin.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/spi/JdbiPlugin.java new file mode 100644 index 00000000000..79fd2339032 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/spi/JdbiPlugin.java @@ -0,0 +1,14 @@ +// Generated automatically from org.jdbi.v3.core.spi.JdbiPlugin for testing purposes + +package org.jdbi.v3.core.spi; + +import java.sql.Connection; +import org.jdbi.v3.core.Handle; +import org.jdbi.v3.core.Jdbi; + +public interface JdbiPlugin +{ + default Connection customizeConnection(Connection p0){ return null; } + default Handle customizeHandle(Handle p0){ return null; } + default void customizeJdbi(Jdbi p0){} +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/BaseStatement.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/BaseStatement.java new file mode 100644 index 00000000000..2b7e48eb630 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/BaseStatement.java @@ -0,0 +1,24 @@ +// Generated automatically from org.jdbi.v3.core.statement.BaseStatement for testing purposes + +package org.jdbi.v3.core.statement; + +import java.io.Closeable; +import java.sql.SQLException; +import org.jdbi.v3.core.Handle; +import org.jdbi.v3.core.config.ConfigRegistry; +import org.jdbi.v3.core.config.Configurable; +import org.jdbi.v3.core.statement.StatementContext; +import org.jdbi.v3.core.statement.StatementCustomizer; + +abstract class BaseStatement implements Closeable, org.jdbi.v3.core.config.Configurable +{ + protected BaseStatement() {} + protected final void cleanUpForException(SQLException p0){} + public ConfigRegistry getConfig(){ return null; } + public final Handle getHandle(){ return null; } + public final StatementContext getContext(){ return null; } + public final This attachToHandleForCleanup(){ return null; } + public final boolean equals(Object p0){ return false; } + public final int hashCode(){ return 0; } + public void close(){} +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Batch.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Batch.java new file mode 100644 index 00000000000..b8c4029a370 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Batch.java @@ -0,0 +1,14 @@ +// Generated automatically from org.jdbi.v3.core.statement.Batch for testing purposes + +package org.jdbi.v3.core.statement; + +import org.jdbi.v3.core.Handle; +import org.jdbi.v3.core.statement.BaseStatement; + +public class Batch extends BaseStatement +{ + protected Batch() {} + public Batch add(String p0){ return null; } + public Batch(Handle p0){} + public int[] execute(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Binding.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Binding.java new file mode 100644 index 00000000000..4e610983029 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Binding.java @@ -0,0 +1,34 @@ +// Generated automatically from org.jdbi.v3.core.statement.Binding for testing purposes + +package org.jdbi.v3.core.statement; + +import java.util.Collection; +import java.util.List; +import java.util.Map; +import java.util.Optional; +import org.jdbi.v3.core.argument.Argument; +import org.jdbi.v3.core.argument.NamedArgumentFinder; +import org.jdbi.v3.core.qualifier.QualifiedType; +import org.jdbi.v3.core.statement.StatementContext; + +public class Binding +{ + protected Binding() {} + protected Binding(StatementContext p0){} + protected final List namedArgumentFinder = null; + protected final Map positionals = null; + protected final Map named = null; + public Collection getNames(){ return null; } + public Optional findForName(String p0, StatementContext p1){ return null; } + public Optional findForPosition(int p0){ return null; } + public String toString(){ return null; } + public boolean isEmpty(){ return false; } + public void addNamed(String p0, Argument p1){} + public void addNamed(String p0, Object p1){} + public void addNamed(String p0, Object p1, QualifiedType p2){} + public void addNamedArgumentFinder(NamedArgumentFinder p0){} + public void addPositional(int p0, Argument p1){} + public void addPositional(int p0, Object p1){} + public void addPositional(int p0, Object p1, QualifiedType p2){} + public void clear(){} +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Call.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Call.java new file mode 100644 index 00000000000..6b389ce2f33 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Call.java @@ -0,0 +1,24 @@ +// Generated automatically from org.jdbi.v3.core.statement.Call for testing purposes + +package org.jdbi.v3.core.statement; + +import java.util.function.Consumer; +import java.util.function.Function; +import org.jdbi.v3.core.Handle; +import org.jdbi.v3.core.statement.CallableStatementMapper; +import org.jdbi.v3.core.statement.OutParameters; +import org.jdbi.v3.core.statement.SqlStatement; + +public class Call extends SqlStatement +{ + protected Call() {} + public T invoke(Function p0){ return null; } + public Call registerOutParameter(String p0, int p1){ return null; } + public Call registerOutParameter(String p0, int p1, CallableStatementMapper p2){ return null; } + public Call registerOutParameter(int p0, int p1){ return null; } + public Call registerOutParameter(int p0, int p1, CallableStatementMapper p2){ return null; } + public Call(Handle p0, CharSequence p1){} + public Call(Handle p0, String p1){} + public OutParameters invoke(){ return null; } + public void invoke(Consumer p0){} +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/CallableStatementMapper.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/CallableStatementMapper.java new file mode 100644 index 00000000000..e299f1c3fb0 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/CallableStatementMapper.java @@ -0,0 +1,10 @@ +// Generated automatically from org.jdbi.v3.core.statement.CallableStatementMapper for testing purposes + +package org.jdbi.v3.core.statement; + +import java.sql.CallableStatement; + +public interface CallableStatementMapper +{ + Object map(int p0, CallableStatement p1); +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Cleanable.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Cleanable.java new file mode 100644 index 00000000000..baa2f06a6ec --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Cleanable.java @@ -0,0 +1,9 @@ +// Generated automatically from org.jdbi.v3.core.statement.Cleanable for testing purposes + +package org.jdbi.v3.core.statement; + + +public interface Cleanable extends AutoCloseable +{ + void close(); +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/MetaData.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/MetaData.java new file mode 100644 index 00000000000..5772b047558 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/MetaData.java @@ -0,0 +1,26 @@ +// Generated automatically from org.jdbi.v3.core.statement.MetaData for testing purposes + +package org.jdbi.v3.core.statement; + +import java.sql.DatabaseMetaData; +import java.sql.ResultSet; +import org.jdbi.v3.core.Handle; +import org.jdbi.v3.core.result.ResultBearing; +import org.jdbi.v3.core.result.ResultSetScanner; +import org.jdbi.v3.core.statement.BaseStatement; + +public class MetaData extends BaseStatement implements ResultBearing +{ + protected MetaData() {} + public R execute(){ return null; } + public R scanResultSet(org.jdbi.v3.core.result.ResultSetScanner p0){ return null; } + public MetaData(Handle p0, MetaData.MetaDataValueProvider p1){} + static public interface MetaDataResultSetProvider extends MetaData.MetaDataValueProvider + { + ResultSet provideValue(DatabaseMetaData p0); + } + static public interface MetaDataValueProvider + { + T provideValue(DatabaseMetaData p0); + } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/OutParameters.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/OutParameters.java new file mode 100644 index 00000000000..c0126aed19e --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/OutParameters.java @@ -0,0 +1,35 @@ +// Generated automatically from org.jdbi.v3.core.statement.OutParameters for testing purposes + +package org.jdbi.v3.core.statement; + +import java.sql.Timestamp; +import org.jdbi.v3.core.result.ResultBearing; + +public class OutParameters +{ + protected OutParameters() {} + public T getObject(String p0, java.lang.Class p1){ return null; } + public T getObject(int p0, java.lang.Class p1){ return null; } + public Double getDouble(String p0){ return null; } + public Double getDouble(int p0){ return null; } + public Float getFloat(String p0){ return null; } + public Float getFloat(int p0){ return null; } + public Integer getInt(String p0){ return null; } + public Integer getInt(int p0){ return null; } + public Long getLong(String p0){ return null; } + public Long getLong(int p0){ return null; } + public Object getObject(String p0){ return null; } + public Object getObject(int p0){ return null; } + public ResultBearing getRowSet(String p0){ return null; } + public ResultBearing getRowSet(int p0){ return null; } + public Short getShort(String p0){ return null; } + public Short getShort(int p0){ return null; } + public String getString(String p0){ return null; } + public String getString(int p0){ return null; } + public Timestamp getTimestamp(String p0){ return null; } + public Timestamp getTimestamp(int p0){ return null; } + public byte[] getBytes(String p0){ return null; } + public byte[] getBytes(int p0){ return null; } + public java.sql.Date getDate(String p0){ return null; } + public java.sql.Date getDate(int p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/ParsedParameters.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/ParsedParameters.java new file mode 100644 index 00000000000..b6b7d07e4d5 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/ParsedParameters.java @@ -0,0 +1,18 @@ +// Generated automatically from org.jdbi.v3.core.statement.ParsedParameters for testing purposes + +package org.jdbi.v3.core.statement; + +import java.util.List; + +public class ParsedParameters +{ + protected ParsedParameters() {} + public List getParameterNames(){ return null; } + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public boolean isPositional(){ return false; } + public int getParameterCount(){ return 0; } + public int hashCode(){ return 0; } + public static ParsedParameters named(List p0){ return null; } + public static ParsedParameters positional(int p0){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/ParsedSql.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/ParsedSql.java new file mode 100644 index 00000000000..a6c71c8915a --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/ParsedSql.java @@ -0,0 +1,25 @@ +// Generated automatically from org.jdbi.v3.core.statement.ParsedSql for testing purposes + +package org.jdbi.v3.core.statement; + +import org.jdbi.v3.core.statement.ParsedParameters; + +public class ParsedSql +{ + protected ParsedSql() {} + public ParsedParameters getParameters(){ return null; } + public String getSql(){ return null; } + public String toString(){ return null; } + public boolean equals(Object p0){ return false; } + public int hashCode(){ return 0; } + public static ParsedSql of(String p0, ParsedParameters p1){ return null; } + public static ParsedSql.Builder builder(){ return null; } + static public class Builder + { + protected Builder() {} + public ParsedSql build(){ return null; } + public ParsedSql.Builder append(String p0){ return null; } + public ParsedSql.Builder appendNamedParameter(String p0){ return null; } + public ParsedSql.Builder appendPositionalParameter(){ return null; } + } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/PreparedBatch.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/PreparedBatch.java new file mode 100644 index 00000000000..f6544021e48 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/PreparedBatch.java @@ -0,0 +1,31 @@ +// Generated automatically from org.jdbi.v3.core.statement.PreparedBatch for testing purposes + +package org.jdbi.v3.core.statement; + +import java.util.Map; +import org.jdbi.v3.core.Handle; +import org.jdbi.v3.core.result.BatchResultBearing; +import org.jdbi.v3.core.result.ResultBearing; +import org.jdbi.v3.core.result.ResultIterator; +import org.jdbi.v3.core.result.ResultProducer; +import org.jdbi.v3.core.result.ResultSetScanner; +import org.jdbi.v3.core.statement.SqlStatement; +import org.jdbi.v3.core.statement.internal.PreparedBinding; + +public class PreparedBatch extends SqlStatement implements ResultBearing +{ + protected PreparedBatch() {} + protected PreparedBinding getBinding(){ return null; } + public R execute(org.jdbi.v3.core.result.ResultProducer p0){ return null; } + public R scanResultSet(org.jdbi.v3.core.result.ResultSetScanner p0){ return null; } + public BatchResultBearing executePreparedBatch(String... p0){ return null; } + public PreparedBatch add(){ return null; } + public PreparedBatch add(Map p0){ return null; } + public PreparedBatch add(Object... p0){ return null; } + public PreparedBatch(Handle p0, CharSequence p1){} + public PreparedBatch(Handle p0, String p1){} + public ResultBearing executeAndReturnGeneratedKeys(String... p0){ return null; } + public ResultIterator executeAndGetModCount(){ return null; } + public int size(){ return 0; } + public int[] execute(){ return null; } +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Query.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Query.java new file mode 100644 index 00000000000..841bb3be797 --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Query.java @@ -0,0 +1,22 @@ +// Generated automatically from org.jdbi.v3.core.statement.Query for testing purposes + +package org.jdbi.v3.core.statement; + +import org.jdbi.v3.core.Handle; +import org.jdbi.v3.core.result.ResultBearing; +import org.jdbi.v3.core.result.ResultProducer; +import org.jdbi.v3.core.result.ResultSetScanner; +import org.jdbi.v3.core.statement.SqlStatement; + +public class Query extends SqlStatement implements ResultBearing +{ + protected Query() {} + public R execute(org.jdbi.v3.core.result.ResultProducer p0){ return null; } + public R scanResultSet(org.jdbi.v3.core.result.ResultSetScanner p0){ return null; } + public Query concurrentUpdatable(){ return null; } + public Query setFetchSize(int p0){ return null; } + public Query setMaxFieldSize(int p0){ return null; } + public Query setMaxRows(int p0){ return null; } + public Query(Handle p0, CharSequence p1){} + public Query(Handle p0, String p1){} +} diff --git a/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Script.java b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Script.java new file mode 100644 index 00000000000..9da3e966e4c --- /dev/null +++ b/java/ql/test/stubs/javafx-web/org/jdbi/v3/core/statement/Script.java @@ -0,0 +1,17 @@ +// Generated automatically from org.jdbi.v3.core.statement.Script for testing purposes + +package org.jdbi.v3.core.statement; + +import java.util.List; +import org.jdbi.v3.core.Handle; +import org.jdbi.v3.core.statement.SqlStatement; + +public class Script extends SqlStatement