Skip to content

Commit 1ee5728

Browse files
committed
Add missing QLDoc
1 parent a22fd39 commit 1ee5728

File tree

1 file changed

+10
-0
lines changed
  • java/ql/lib/semmle/code/java/frameworks

1 file changed

+10
-0
lines changed

java/ql/lib/semmle/code/java/frameworks/Regex.qll

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,10 +96,20 @@ class PatternMatchesCall extends MethodCall, RegexExecutionExpr::Range {
9696
class MatcherMatchesCall extends MethodCall, RegexExecutionExpr::Range {
9797
MatcherMatchesCall() { this.getMethod() instanceof MatcherMatchesMethod }
9898

99+
/**
100+
* Get the call to `java.util.regex.Pattern.matcher` which returned the
101+
* qualifier of this call. This is needed to determine the string being
102+
* matched.
103+
*/
99104
PatternMatcherCall getPatternMatcherCall() {
100105
DataFlow::localExprFlow(result, this.getQualifier())
101106
}
102107

108+
/**
109+
* Get the call to `java.util.regex.Pattern.compile` which returned the
110+
* `Pattern` used by this matcher. This is needed to determine the regular
111+
* expression being used.
112+
*/
103113
PatternCompileCall getPatternCompileCall() {
104114
DataFlow::localExprFlow(result, this.getPatternMatcherCall())
105115
}

0 commit comments

Comments
 (0)