blob: 6d8af5e1681cf8be2fcad5346494fcdab04d36fa [file] [log] [blame]
<!DOCTYPE HTML>
<!-- NewPage -->
<html lang="en">
<head>
<!-- Generated by javadoc (16) -->
<title>LineRule (OpenJ9 JDK 16)</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="description" content="declaration: module: openj9.dtfj, package: com.ibm.dtfj.javacore.parser.framework.tag, class: LineRule">
<meta name="generator" content="javadoc/ClassWriterImpl">
<meta name="keywords" content="com.ibm.dtfj.javacore.parser.framework.tag.LineRule class">
<meta name="keywords" content="fSource">
<meta name="keywords" content="fCharSubSet">
<meta name="keywords" content="fLineNumber">
<meta name="keywords" content="fOffset">
<meta name="keywords" content="parseLine()">
<meta name="keywords" content="getLineNumber()">
<meta name="keywords" content="processLine()">
<meta name="keywords" content="addToken()">
<meta name="keywords" content="addAllCharactersAsTokenAndConsumeFirstMatch()">
<meta name="keywords" content="addAllCharactersAsTokenUntilFirstMatch()">
<meta name="keywords" content="addAllCharactersAsTokenUntilIndex()">
<meta name="keywords" content="addNonPrefixedHexToken()">
<meta name="keywords" content="addPrefixedHexToken()">
<meta name="keywords" content="matchAndConsumeValue()">
<meta name="keywords" content="consumeCharacters()">
<meta name="keywords" content="consumeUntilFirstMatch()">
<meta name="keywords" content="findFirst()">
<meta name="keywords" content="indexOfLast()">
<link rel="stylesheet" type="text/css" href="../../../../../../../../stylesheet.css" title="Style">
<link rel="stylesheet" type="text/css" href="../../../../../../../../script-dir/jquery-ui.min.css" title="Style">
<link rel="stylesheet" type="text/css" href="../../../../../../../../jquery-ui.overrides.css" title="Style">
<script type="text/javascript" src="../../../../../../../../script.js"></script>
<script type="text/javascript" src="../../../../../../../../script-dir/jquery-3.5.1.min.js"></script>
<script type="text/javascript" src="../../../../../../../../script-dir/jquery-ui.min.js"></script>
</head>
<body class="class-declaration-page">
<script type="text/javascript">var evenRowColor = "even-row-color";
var oddRowColor = "odd-row-color";
var tableTab = "table-tab";
var activeTableTab = "active-table-tab";
var pathtoroot = "../../../../../../../../";
loadScripts(document, 'script');</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<div class="flex-box">
<header role="banner" class="flex-header">
<nav role="navigation">
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="top-nav" id="navbar.top">
<div class="skip-nav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div>
<div class="about-language"><div style="margin-top: 9px;"><strong>OpenJ9 JDK 16</strong></div></div>
<ul id="navbar.top.firstrow" class="nav-list" title="Navigation">
<li><a href="../../../../../../../../index.html">Overview</a></li>
<li><a href="../../../../../../../module-summary.html">Module</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="nav-bar-cell1-rev">Class</li>
<li><a href="class-use/LineRule.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../../../../../index-files/index-1.html">Index</a></li>
<li><a href="../../../../../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="sub-nav">
<div>
<ul class="sub-nav-list">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li><a href="#field.summary">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor.summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="sub-nav-list">
<li>Detail:&nbsp;</li>
<li><a href="#field.detail">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor.detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.detail">Method</a></li>
</ul>
</div>
<div class="nav-list-search"><label for="search">SEARCH:</label>
<input type="text" id="search" value="search" disabled="disabled">
<input type="reset" id="reset" value="reset" disabled="disabled">
</div>
</div>
<!-- ========= END OF TOP NAVBAR ========= -->
<span class="skip-nav" id="skip.navbar.top">
<!-- -->
</span></nav>
</header>
<div class="flex-content">
<main role="main">
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<div class="sub-title"><span class="module-label-in-type">Module</span>&nbsp;<a href="../../../../../../../module-summary.html">openj9.dtfj</a></div>
<div class="sub-title"><span class="package-label-in-type">Package</span>&nbsp;<a href="package-summary.html">com.ibm.dtfj.javacore.parser.framework.tag</a></div>
<h1 title="Class LineRule" class="title">Class LineRule</h1>
</div>
<div class="inheritance" title="Inheritance Tree"><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link" target="_blank">java.lang.Object</a>
<div class="inheritance">com.ibm.dtfj.javacore.parser.framework.tag.LineRule</div>
</div>
<section class="description">
<dl class="notes">
<dt>All Implemented Interfaces:</dt>
<dd><code><a href="ILineRule.html" title="interface in com.ibm.dtfj.javacore.parser.framework.tag">ILineRule</a></code></dd>
</dl>
<dl class="notes">
<dt>Direct Known Subclasses:</dt>
<dd><code><a href="../../j9/section/classloader/ClassLoaderLineRule.html" title="class in com.ibm.dtfj.javacore.parser.j9.section.classloader">ClassLoaderLineRule</a></code>, <code><a href="../../j9/section/monitor/MonitorObjectLineRule.html" title="class in com.ibm.dtfj.javacore.parser.j9.section.monitor">MonitorObjectLineRule</a></code>, <code><a href="../../j9/section/thread/NativeStackTraceLineRule.html" title="class in com.ibm.dtfj.javacore.parser.j9.section.thread">NativeStackTraceLineRule</a></code>, <code><a href="../../j9/section/common/PointerSizeLineRule.html" title="class in com.ibm.dtfj.javacore.parser.j9.section.common">PointerSizeLineRule</a></code>, <code><a href="../../j9/section/thread/StackTraceLineRule.html" title="class in com.ibm.dtfj.javacore.parser.j9.section.thread">StackTraceLineRule</a></code>, <code><a href="../../j9/section/thread/ThreadInfoLineRule.html" title="class in com.ibm.dtfj.javacore.parser.j9.section.thread">ThreadInfoLineRule</a></code></dd>
</dl>
<hr>
<div class="type-signature"><span class="modifiers">public abstract class </span><span class="element-name type-name-label">LineRule</span>
<span class="extends-implements">extends <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link" target="_blank">Object</a>
implements <a href="ILineRule.html" title="interface in com.ibm.dtfj.javacore.parser.framework.tag">ILineRule</a></span></div>
<div class="block">This is the basic line parser for a javacore tag. A set of frequently-encountered pattern matching
behaviours are implemented as helper methods to facilitate pattern matching. However, the concrete subtype
must implement the actual pattern matching and token generation logic for a particular tag.
Each tag is ideally assigned it's own linerule, unless multiple tags share the exact same pattern.
<br><br>
This linerule parses a line based on the parsing logic implemented by the concrete type, and adds
the parsed data as tokens to an internal token map. The concrete classes only need to specify
HOW the line is parsed, and HOW the tokens are generated, but it need not worry about the actual
line parsing call. The parsing framework calls the line parser internally.
<br><br>
<b>GENERAL BEHAVIOUR</b>:
See the javadoc of the helper methods, but generally, as tokens are generated, or alternately, sections
of the source string (which is stored internally in a buffer) matched and discarded, the processed subsections are removed from the source string
until nothing remains. Some helper methods may just find a pattern but not do anything, others will find the first
occurrence of a pattern, and discard all characters from the start of the source to the first encountered pattern.
<br><br>
<b>HANDLING TOKEN TYPES</b>:
Based on how javacores are structured, it is assumed that
each tag line contains at most one instance of a token type.
If two or more of the same token types exist, this is indicative
that the line should be split into two or more separate javacore
tag lines. Consequently, only at most one instance of a token
type is added to the token map. If the token type already exists
in the map, it will be overwritten.
<br><br>
The parser framework will execute the line parsing logic implemented by the concrete subclass and
return a list of tokens (generally a map, where the key is the token type, and the value is the token value)
to the section parser that uses these line rules. A series of line rules
can be registered into a Tag Parser, which in turn gets used by a Section Parser.
<br><br>
Note that methods are provided to explicitly generate and add a token, and the concrete-class must
call these methods explicitly to add a token.
<br><br></div>
<dl class="notes">
<dt>See Also:</dt>
<dd><a href="ITagParser.html" title="interface in com.ibm.dtfj.javacore.parser.framework.tag"><code>ITagParser</code></a>,
<a href="ITagAttributeResult.html" title="interface in com.ibm.dtfj.javacore.parser.framework.tag"><code>ITagAttributeResult</code></a></dd>
</dl>
</section>
<section class="summary">
<ul class="summary-list">
<!-- =========== FIELD SUMMARY =========== -->
<li>
<section class="field-summary" id="field.summary">
<h2>Field Summary</h2>
<div class="caption"><span>Fields</span></div>
<div class="summary-table three-column-summary">
<div class="table-header col-first">Modifier and Type</div>
<div class="table-header col-second">Field</div>
<div class="table-header col-last">Description</div>
<div class="col-first even-row-color"><code>protected <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/StringBuffer.html" title="class or interface in java.lang" class="external-link" target="_blank">StringBuffer</a></code></div>
<div class="col-second even-row-color"><code><span class="member-name-link"><a href="#fCharSubSet">fCharSubSet</a></span></code></div>
<div class="col-last even-row-color">&nbsp;</div>
<div class="col-first odd-row-color"><code>protected int</code></div>
<div class="col-second odd-row-color"><code><span class="member-name-link"><a href="#fLineNumber">fLineNumber</a></span></code></div>
<div class="col-last odd-row-color">&nbsp;</div>
<div class="col-first even-row-color"><code>protected int</code></div>
<div class="col-second even-row-color"><code><span class="member-name-link"><a href="#fOffset">fOffset</a></span></code></div>
<div class="col-last even-row-color">&nbsp;</div>
<div class="col-first odd-row-color"><code>protected <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/StringBuffer.html" title="class or interface in java.lang" class="external-link" target="_blank">StringBuffer</a></code></div>
<div class="col-second odd-row-color"><code><span class="member-name-link"><a href="#fSource">fSource</a></span></code></div>
<div class="col-last odd-row-color">&nbsp;</div>
</div>
</section>
</li>
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<li>
<section class="constructor-summary" id="constructor.summary">
<h2>Constructor Summary</h2>
<div class="caption"><span>Constructors</span></div>
<div class="summary-table two-column-summary">
<div class="table-header col-first">Constructor</div>
<div class="table-header col-last">Description</div>
<div class="col-constructor-name even-row-color"><code><span class="member-name-link"><a href="#%3Cinit%3E()">LineRule</a></span>()</code></div>
<div class="col-last even-row-color">&nbsp;</div>
</div>
</section>
</li>
<!-- ========== METHOD SUMMARY =========== -->
<li>
<section class="method-summary" id="method.summary">
<h2>Method Summary</h2>
<div id="method-summary-table">
<div class="table-tabs" role="tablist" aria-orientation="horizontal"><button id="method-summary-table-tab0" role="tab" aria-selected="true" aria-controls="method-summary-table.tabpanel" tabindex="0" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table', 3)" class="active-table-tab">All Methods</button><button id="method-summary-table-tab2" role="tab" aria-selected="false" aria-controls="method-summary-table.tabpanel" tabindex="-1" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table-tab2', 3)" class="table-tab">Instance Methods</button><button id="method-summary-table-tab3" role="tab" aria-selected="false" aria-controls="method-summary-table.tabpanel" tabindex="-1" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table-tab3', 3)" class="table-tab">Abstract Methods</button><button id="method-summary-table-tab4" role="tab" aria-selected="false" aria-controls="method-summary-table.tabpanel" tabindex="-1" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table-tab4', 3)" class="table-tab">Concrete Methods</button></div>
<div id="method-summary-table.tabpanel" role="tabpanel">
<div class="summary-table three-column-summary" aria-labelledby="method-summary-table-tab0">
<div class="table-header col-first">Modifier and Type</div>
<div class="table-header col-second">Method</div>
<div class="table-header col-last">Description</div>
<div class="col-first even-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code>protected <a href="../scanner/IParserToken.html" title="interface in com.ibm.dtfj.javacore.parser.framework.scanner">IParserToken</a></code></div>
<div class="col-second even-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code><span class="member-name-link"><a href="#addAllCharactersAsTokenAndConsumeFirstMatch(java.lang.String,java.util.regex.Matcher)">addAllCharactersAsTokenAndConsumeFirstMatch</a></span>&#8203;(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link" target="_blank">String</a>&nbsp;type,
<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/regex/Matcher.html" title="class or interface in java.util.regex" class="external-link" target="_blank">Matcher</a>&nbsp;matcher)</code></div>
<div class="col-last even-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table">
<div class="block">Grabs all characters up to the first match specified by the matcher, and adds
the latter as a token of a argument-specified type to the internal token list.</div>
</div>
<div class="col-first odd-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code>protected <a href="../scanner/IParserToken.html" title="interface in com.ibm.dtfj.javacore.parser.framework.scanner">IParserToken</a></code></div>
<div class="col-second odd-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code><span class="member-name-link"><a href="#addAllCharactersAsTokenUntilFirstMatch(java.lang.String,java.util.regex.Matcher)">addAllCharactersAsTokenUntilFirstMatch</a></span>&#8203;(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link" target="_blank">String</a>&nbsp;type,
<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/regex/Matcher.html" title="class or interface in java.util.regex" class="external-link" target="_blank">Matcher</a>&nbsp;matcher)</code></div>
<div class="col-last odd-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table">
<div class="block">Grabs all characters up to but excluding the first match specified by the matcher,
and adds the latter as a token of an argument-specified type.</div>
</div>
<div class="col-first even-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code>protected <a href="../scanner/IParserToken.html" title="interface in com.ibm.dtfj.javacore.parser.framework.scanner">IParserToken</a></code></div>
<div class="col-second even-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code><span class="member-name-link"><a href="#addAllCharactersAsTokenUntilIndex(java.lang.String,int,boolean)">addAllCharactersAsTokenUntilIndex</a></span>&#8203;(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link" target="_blank">String</a>&nbsp;type,
int&nbsp;endIndex,
boolean&nbsp;stripTrailingWhitespace)</code></div>
<div class="col-last even-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table">
<div class="block">Copies all characters from start to endIndex - 1.</div>
</div>
<div class="col-first odd-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code>protected <a href="../scanner/IParserToken.html" title="interface in com.ibm.dtfj.javacore.parser.framework.scanner">IParserToken</a></code></div>
<div class="col-second odd-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code><span class="member-name-link"><a href="#addNonPrefixedHexToken(java.lang.String)">addNonPrefixedHexToken</a></span>&#8203;(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link" target="_blank">String</a>&nbsp;type)</code></div>
<div class="col-last odd-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table">
<div class="block">Matches the first hexadecimal match encountered that is not prefixed by "0x" as a token.</div>
</div>
<div class="col-first even-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code>protected <a href="../scanner/IParserToken.html" title="interface in com.ibm.dtfj.javacore.parser.framework.scanner">IParserToken</a></code></div>
<div class="col-second even-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code><span class="member-name-link"><a href="#addPrefixedHexToken(java.lang.String)">addPrefixedHexToken</a></span>&#8203;(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link" target="_blank">String</a>&nbsp;type)</code></div>
<div class="col-last even-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table">
<div class="block">Matches the first prefixed hexadecimal pattern encountered, and adds it as a token.</div>
</div>
<div class="col-first odd-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code>protected void</code></div>
<div class="col-second odd-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code><span class="member-name-link"><a href="#addToken(com.ibm.dtfj.javacore.parser.framework.scanner.IParserToken)">addToken</a></span>&#8203;(<a href="../scanner/IParserToken.html" title="interface in com.ibm.dtfj.javacore.parser.framework.scanner">IParserToken</a>&nbsp;token)</code></div>
<div class="col-last odd-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table">
<div class="block">Adds a non-null token to the token map.</div>
</div>
<div class="col-first even-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code>protected <a href="../scanner/IParserToken.html" title="interface in com.ibm.dtfj.javacore.parser.framework.scanner">IParserToken</a></code></div>
<div class="col-second even-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code><span class="member-name-link"><a href="#addToken(java.lang.String,java.lang.String)">addToken</a></span>&#8203;(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link" target="_blank">String</a>&nbsp;type,
<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link" target="_blank">String</a>&nbsp;value)</code></div>
<div class="col-last even-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table">
<div class="block">Adds a token of the type specified to the internal token list and assigns it the value specified by the argument.</div>
</div>
<div class="col-first odd-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code>protected <a href="../scanner/IParserToken.html" title="interface in com.ibm.dtfj.javacore.parser.framework.scanner">IParserToken</a></code></div>
<div class="col-second odd-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code><span class="member-name-link"><a href="#addToken(java.lang.String,java.util.regex.Matcher)">addToken</a></span>&#8203;(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link" target="_blank">String</a>&nbsp;type,
<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/regex/Matcher.html" title="class or interface in java.util.regex" class="external-link" target="_blank">Matcher</a>&nbsp;matcher)</code></div>
<div class="col-last odd-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table">
<div class="block">Adds a token of the type specified via argument to the internal token map, and assigns it
the value matched by the pattern matcher.</div>
</div>
<div class="col-first even-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code>protected <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link" target="_blank">String</a></code></div>
<div class="col-second even-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code><span class="member-name-link"><a href="#consumeCharacters(int,int)">consumeCharacters</a></span>&#8203;(int&nbsp;startIndex,
int&nbsp;endIndex)</code></div>
<div class="col-last even-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table">
<div class="block">Consumes a section of characters from the buffer.</div>
</div>
<div class="col-first odd-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code>protected boolean</code></div>
<div class="col-second odd-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code><span class="member-name-link"><a href="#consumeUntilFirstMatch(java.util.regex.Matcher)">consumeUntilFirstMatch</a></span>&#8203;(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/regex/Matcher.html" title="class or interface in java.util.regex" class="external-link" target="_blank">Matcher</a>&nbsp;matcher)</code></div>
<div class="col-last odd-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table">
<div class="block">Matches the first occurrence of the pattern and consumes all characters
from the start of the buffer until the first occurrence of the pattern.</div>
</div>
<div class="col-first even-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code>protected boolean</code></div>
<div class="col-second even-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code><span class="member-name-link"><a href="#findFirst(java.util.regex.Matcher)">findFirst</a></span>&#8203;(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/regex/Matcher.html" title="class or interface in java.util.regex" class="external-link" target="_blank">Matcher</a>&nbsp;matcher)</code></div>
<div class="col-last even-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table">
<div class="block">Finds the first match.</div>
</div>
<div class="col-first odd-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code>protected int</code></div>
<div class="col-second odd-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code><span class="member-name-link"><a href="#getLineNumber()">getLineNumber</a></span>()</code></div>
<div class="col-last odd-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table">&nbsp;</div>
<div class="col-first even-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code>protected int</code></div>
<div class="col-second even-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code><span class="member-name-link"><a href="#indexOfLast(java.util.regex.Matcher)">indexOfLast</a></span>&#8203;(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/regex/Matcher.html" title="class or interface in java.util.regex" class="external-link" target="_blank">Matcher</a>&nbsp;matcher)</code></div>
<div class="col-last even-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table">
<div class="block">Returns the starting index of the last matched pattern, but doesn't consume anything or generate
tokens.</div>
</div>
<div class="col-first odd-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code>protected <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link" target="_blank">String</a></code></div>
<div class="col-second odd-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code><span class="member-name-link"><a href="#matchAndConsumeValue(java.util.regex.Matcher)">matchAndConsumeValue</a></span>&#8203;(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/regex/Matcher.html" title="class or interface in java.util.regex" class="external-link" target="_blank">Matcher</a>&nbsp;matcher)</code></div>
<div class="col-last odd-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table">
<div class="block">Finds the first occurrence of the pattern in the source.</div>
</div>
<div class="col-first even-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code><a href="../../j9/IAttributeValueMap.html" title="interface in com.ibm.dtfj.javacore.parser.j9">IAttributeValueMap</a></code></div>
<div class="col-second even-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table"><code><span class="member-name-link"><a href="#parseLine(java.lang.String,int,int)">parseLine</a></span>&#8203;(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link" target="_blank">String</a>&nbsp;source,
int&nbsp;lineNumber,
int&nbsp;startingOffset)</code></div>
<div class="col-last even-row-color method-summary-table-tab2 method-summary-table-tab4 method-summary-table">
<div class="block">Initializes buffer, token list, and other fields prior to parsing and tokenising a line.</div>
</div>
<div class="col-first odd-row-color method-summary-table-tab2 method-summary-table method-summary-table-tab3"><code>protected abstract void</code></div>
<div class="col-second odd-row-color method-summary-table-tab2 method-summary-table method-summary-table-tab3"><code><span class="member-name-link"><a href="#processLine(java.lang.String,int)">processLine</a></span>&#8203;(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link" target="_blank">String</a>&nbsp;source,
int&nbsp;startingOffset)</code></div>
<div class="col-last odd-row-color method-summary-table-tab2 method-summary-table method-summary-table-tab3">
<div class="block">Must be implemented by the subtype.</div>
</div>
</div>
</div>
</div>
<div class="inherited-list">
<h3 id="methods.inherited.from.class.java.lang.Object">Methods declared in class&nbsp;java.lang.<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link" target="_blank">Object</a></h3>
<code><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html#clone()" title="class or interface in java.lang" class="external-link" target="_blank">clone</a>, <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html#equals(java.lang.Object)" title="class or interface in java.lang" class="external-link" target="_blank">equals</a>, <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html#finalize()" title="class or interface in java.lang" class="external-link" target="_blank">finalize</a>, <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html#getClass()" title="class or interface in java.lang" class="external-link" target="_blank">getClass</a>, <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html#hashCode()" title="class or interface in java.lang" class="external-link" target="_blank">hashCode</a>, <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html#notify()" title="class or interface in java.lang" class="external-link" target="_blank">notify</a>, <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html#notifyAll()" title="class or interface in java.lang" class="external-link" target="_blank">notifyAll</a>, <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html#toString()" title="class or interface in java.lang" class="external-link" target="_blank">toString</a>, <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html#wait()" title="class or interface in java.lang" class="external-link" target="_blank">wait</a>, <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html#wait(long)" title="class or interface in java.lang" class="external-link" target="_blank">wait</a>, <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html#wait(long,int)" title="class or interface in java.lang" class="external-link" target="_blank">wait</a></code></div>
</section>
</li>
</ul>
</section>
<section class="details">
<ul class="details-list">
<!-- ============ FIELD DETAIL =========== -->
<li>
<section class="field-details" id="field.detail">
<h2>Field Details</h2>
<ul class="member-list">
<li>
<section class="detail" id="fSource">
<h3>fSource</h3>
<div class="member-signature"><span class="modifiers">protected final</span>&nbsp;<span class="return-type"><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/StringBuffer.html" title="class or interface in java.lang" class="external-link" target="_blank">StringBuffer</a></span>&nbsp;<span class="element-name">fSource</span></div>
</section>
</li>
<li>
<section class="detail" id="fCharSubSet">
<h3>fCharSubSet</h3>
<div class="member-signature"><span class="modifiers">protected final</span>&nbsp;<span class="return-type"><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/StringBuffer.html" title="class or interface in java.lang" class="external-link" target="_blank">StringBuffer</a></span>&nbsp;<span class="element-name">fCharSubSet</span></div>
</section>
</li>
<li>
<section class="detail" id="fLineNumber">
<h3>fLineNumber</h3>
<div class="member-signature"><span class="modifiers">protected</span>&nbsp;<span class="return-type">int</span>&nbsp;<span class="element-name">fLineNumber</span></div>
</section>
</li>
<li>
<section class="detail" id="fOffset">
<h3>fOffset</h3>
<div class="member-signature"><span class="modifiers">protected</span>&nbsp;<span class="return-type">int</span>&nbsp;<span class="element-name">fOffset</span></div>
</section>
</li>
</ul>
</section>
</li>
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<li>
<section class="constructor-details" id="constructor.detail">
<h2>Constructor Details</h2>
<ul class="member-list">
<li>
<section class="detail" id="&lt;init&gt;()">
<h3>LineRule</h3>
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="element-name">LineRule</span>()</div>
</section>
</li>
</ul>
</section>
</li>
<!-- ============ METHOD DETAIL ========== -->
<li>
<section class="method-details" id="method.detail">
<h2>Method Details</h2>
<ul class="member-list">
<li>
<section class="detail" id="parseLine(java.lang.String,int,int)">
<h3>parseLine</h3>
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type"><a href="../../j9/IAttributeValueMap.html" title="interface in com.ibm.dtfj.javacore.parser.j9">IAttributeValueMap</a></span>&nbsp;<span class="element-name">parseLine</span>&#8203;<span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link" target="_blank">String</a>&nbsp;source,
int&nbsp;lineNumber,
int&nbsp;startingOffset)</span></div>
<div class="block">Initializes buffer, token list, and other fields prior to parsing and tokenising a line.
The user-implemented method that parses the line is called here. This method is called
internally by the framework, so the user never needs to explicitly call this method.</div>
<dl class="notes">
<dt>Specified by:</dt>
<dd><code><a href="ILineRule.html#parseLine(java.lang.String,int,int)">parseLine</a></code>&nbsp;in interface&nbsp;<code><a href="ILineRule.html" title="interface in com.ibm.dtfj.javacore.parser.framework.tag">ILineRule</a></code></dd>
<dt>Parameters:</dt>
<dd><code>source</code> - string containing source to parse</dd>
<dd><code>lineNumber</code> - line number on file of source</dd>
<dd><code>startingOffset</code> - offset of the first character in the source line. offsets are determined externally from the start of the file.</dd>
<dt>Returns:</dt>
<dd>attribute value map containing parsed tokens.</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="getLineNumber()">
<h3>getLineNumber</h3>
<div class="member-signature"><span class="modifiers">protected</span>&nbsp;<span class="return-type">int</span>&nbsp;<span class="element-name">getLineNumber</span>()</div>
<dl class="notes">
<dt>Returns:</dt>
<dd>line number on disk of the source line being parsed.</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="processLine(java.lang.String,int)">
<h3>processLine</h3>
<div class="member-signature"><span class="modifiers">protected abstract</span>&nbsp;<span class="return-type">void</span>&nbsp;<span class="element-name">processLine</span>&#8203;<span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link" target="_blank">String</a>&nbsp;source,
int&nbsp;startingOffset)</span></div>
<div class="block">Must be implemented by the subtype. It gets called internally
by the parser framework, so the user need not worry about
calling this explicitly.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>startingOffset</code> - </dd>
<dd><code>source</code> - to be parsed.</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="addToken(java.lang.String,java.util.regex.Matcher)">
<h3>addToken</h3>
<div class="member-signature"><span class="modifiers">protected</span>&nbsp;<span class="return-type"><a href="../scanner/IParserToken.html" title="interface in com.ibm.dtfj.javacore.parser.framework.scanner">IParserToken</a></span>&nbsp;<span class="element-name">addToken</span>&#8203;<span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link" target="_blank">String</a>&nbsp;type,
<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/regex/Matcher.html" title="class or interface in java.util.regex" class="external-link" target="_blank">Matcher</a>&nbsp;matcher)</span></div>
<div class="block">Adds a token of the type specified via argument to the internal token map, and assigns it
the value matched by the pattern matcher. The generated token is
returned, or null if no pattern was matched.
<br><br>
If the token type already exists in the token map, it overwrites the value with the new token.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>type</code> - of the token to be generated</dd>
<dd><code>matcher</code> - containing pattern to match. the value matched is assigned as the value of the token</dd>
<dt>Returns:</dt>
<dd>generated token if match is successful, or null otherwise</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="addToken(com.ibm.dtfj.javacore.parser.framework.scanner.IParserToken)">
<h3>addToken</h3>
<div class="member-signature"><span class="modifiers">protected</span>&nbsp;<span class="return-type">void</span>&nbsp;<span class="element-name">addToken</span>&#8203;<span class="parameters">(<a href="../scanner/IParserToken.html" title="interface in com.ibm.dtfj.javacore.parser.framework.scanner">IParserToken</a>&nbsp;token)</span></div>
<div class="block">Adds a non-null token to the token map. If the token type already exists, it
overwrites the value.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>token</code> - </dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="addToken(java.lang.String,java.lang.String)">
<h3>addToken</h3>
<div class="member-signature"><span class="modifiers">protected</span>&nbsp;<span class="return-type"><a href="../scanner/IParserToken.html" title="interface in com.ibm.dtfj.javacore.parser.framework.scanner">IParserToken</a></span>&nbsp;<span class="element-name">addToken</span>&#8203;<span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link" target="_blank">String</a>&nbsp;type,
<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link" target="_blank">String</a>&nbsp;value)</span></div>
<div class="block">Adds a token of the type specified to the internal token list and assigns it the value specified by the argument.
Returns the generated token.
<br><br>
If the token type already exists in the token map, it overwrites the value with the new token.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>type</code> - of the token</dd>
<dd><code>value</code> - of the token</dd>
<dt>Returns:</dt>
<dd>generated token.</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="addAllCharactersAsTokenAndConsumeFirstMatch(java.lang.String,java.util.regex.Matcher)">
<h3>addAllCharactersAsTokenAndConsumeFirstMatch</h3>
<div class="member-signature"><span class="modifiers">protected</span>&nbsp;<span class="return-type"><a href="../scanner/IParserToken.html" title="interface in com.ibm.dtfj.javacore.parser.framework.scanner">IParserToken</a></span>&nbsp;<span class="element-name">addAllCharactersAsTokenAndConsumeFirstMatch</span>&#8203;<span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link" target="_blank">String</a>&nbsp;type,
<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/regex/Matcher.html" title="class or interface in java.util.regex" class="external-link" target="_blank">Matcher</a>&nbsp;matcher)</span></div>
<div class="block">Grabs all characters up to the first match specified by the matcher, and adds
the latter as a token of a argument-specified type to the internal token list. All the aforementioned characters
as well as the first pattern matched are removed from the source buffer. The matched pattern
is not included in the token.
<br><br>
If the token type already exists in the token map, it overwrites the value with the new token.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>type</code> - </dd>
<dd><code>matcher</code> - </dd>
<dt>Returns:</dt>
<dd>generated token if match found, or null otherwise</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="addAllCharactersAsTokenUntilFirstMatch(java.lang.String,java.util.regex.Matcher)">
<h3>addAllCharactersAsTokenUntilFirstMatch</h3>
<div class="member-signature"><span class="modifiers">protected</span>&nbsp;<span class="return-type"><a href="../scanner/IParserToken.html" title="interface in com.ibm.dtfj.javacore.parser.framework.scanner">IParserToken</a></span>&nbsp;<span class="element-name">addAllCharactersAsTokenUntilFirstMatch</span>&#8203;<span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link" target="_blank">String</a>&nbsp;type,
<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/regex/Matcher.html" title="class or interface in java.util.regex" class="external-link" target="_blank">Matcher</a>&nbsp;matcher)</span></div>
<div class="block">Grabs all characters up to but excluding the first match specified by the matcher,
and adds the latter as a token of an argument-specified type.
<br><br>
If the token type already exists in the token map, it overwrites the value with the new token.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>type</code> - </dd>
<dd><code>matcher</code> - </dd>
<dt>Returns:</dt>
<dd>generated token if match found, or null otherwise</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="addAllCharactersAsTokenUntilIndex(java.lang.String,int,boolean)">
<h3>addAllCharactersAsTokenUntilIndex</h3>
<div class="member-signature"><span class="modifiers">protected</span>&nbsp;<span class="return-type"><a href="../scanner/IParserToken.html" title="interface in com.ibm.dtfj.javacore.parser.framework.scanner">IParserToken</a></span>&nbsp;<span class="element-name">addAllCharactersAsTokenUntilIndex</span>&#8203;<span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link" target="_blank">String</a>&nbsp;type,
int&nbsp;endIndex,
boolean&nbsp;stripTrailingWhitespace)</span></div>
<div class="block">Copies all characters from start to endIndex - 1. Also gives the option to strip trailing whitespace.
<br><br>
If the token type already exists in the token map, it overwrites the value with the new token.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>type</code> - token type</dd>
<dd><code>endIndex</code> - </dd>
<dd><code>stripTrailingWhitespace</code> - if whitespace starting from endIndex - 1 to n, where n >=0 && n < endIndex.</dd>
<dt>Returns:</dt>
<dd>generated token</dd>
<dt>Throws:</dt>
<dd><code><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/IndexOutOfBoundsException.html" title="class or interface in java.lang" class="external-link" target="_blank">IndexOutOfBoundsException</a></code> - if endIndex > source buffer length || endIndex <= 0</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="addNonPrefixedHexToken(java.lang.String)">
<h3>addNonPrefixedHexToken</h3>
<div class="member-signature"><span class="modifiers">protected</span>&nbsp;<span class="return-type"><a href="../scanner/IParserToken.html" title="interface in com.ibm.dtfj.javacore.parser.framework.scanner">IParserToken</a></span>&nbsp;<span class="element-name">addNonPrefixedHexToken</span>&#8203;<span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link" target="_blank">String</a>&nbsp;type)</span></div>
<div class="block">Matches the first hexadecimal match encountered that is not prefixed by "0x" as a token. The latter
is then prefixed to the value of the token before generating the token.
<br><br>
If the token type already exists in the token map, it overwrites the value with the new token.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>type</code> - of token to be generated</dd>
<dt>Returns:</dt>
<dd>generated token if hexadecimal match found, or null otherwise.</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="addPrefixedHexToken(java.lang.String)">
<h3>addPrefixedHexToken</h3>
<div class="member-signature"><span class="modifiers">protected</span>&nbsp;<span class="return-type"><a href="../scanner/IParserToken.html" title="interface in com.ibm.dtfj.javacore.parser.framework.scanner">IParserToken</a></span>&nbsp;<span class="element-name">addPrefixedHexToken</span>&#8203;<span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link" target="_blank">String</a>&nbsp;type)</span></div>
<div class="block">Matches the first prefixed hexadecimal pattern encountered, and adds it as a token.
Pattern, and all characters prior to the pattern are consumed from the buffer.
<br><br>
If the token type already exists in the token map, it overwrites the value with the new token.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>type</code> - of token to be generated</dd>
<dt>Returns:</dt>
<dd>generated token, if match found, or null otherwise</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="matchAndConsumeValue(java.util.regex.Matcher)">
<h3>matchAndConsumeValue</h3>
<div class="member-signature"><span class="modifiers">protected</span>&nbsp;<span class="return-type"><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link" target="_blank">String</a></span>&nbsp;<span class="element-name">matchAndConsumeValue</span>&#8203;<span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/regex/Matcher.html" title="class or interface in java.util.regex" class="external-link" target="_blank">Matcher</a>&nbsp;matcher)</span></div>
<div class="block">Finds the first occurrence of the pattern in the source.
<br>
Returns the character sequence that matched that pattern.
<br>
Deletes any character sequences from the start of the source to the end
of the matched character sequence, and retains the remainder characters for
further analysis.
<br></div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>matcher</code> - containing pattern to match</dd>
<dt>Returns:</dt>
<dd>string value or null</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="consumeCharacters(int,int)">
<h3>consumeCharacters</h3>
<div class="member-signature"><span class="modifiers">protected</span>&nbsp;<span class="return-type"><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link" target="_blank">String</a></span>&nbsp;<span class="element-name">consumeCharacters</span>&#8203;<span class="parameters">(int&nbsp;startIndex,
int&nbsp;endIndex)</span></div>
<div class="block">Consumes a section of characters from the buffer.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>startIndex</code> - inclusive</dd>
<dd><code>endIndex</code> - exclusive</dd>
<dt>Returns:</dt>
<dd>String value of consumed characters</dd>
<dt>Throws:</dt>
<dd><code><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/IndexOutOfBoundsException.html" title="class or interface in java.lang" class="external-link" target="_blank">IndexOutOfBoundsException</a></code> - if start and end are outside the buffer range.</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="consumeUntilFirstMatch(java.util.regex.Matcher)">
<h3>consumeUntilFirstMatch</h3>
<div class="member-signature"><span class="modifiers">protected</span>&nbsp;<span class="return-type">boolean</span>&nbsp;<span class="element-name">consumeUntilFirstMatch</span>&#8203;<span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/regex/Matcher.html" title="class or interface in java.util.regex" class="external-link" target="_blank">Matcher</a>&nbsp;matcher)</span></div>
<div class="block">Matches the first occurrence of the pattern and consumes all characters
from the start of the buffer until the first occurrence of the pattern.
The pattern itself is also consumed. No tokens are generated.
<br></div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>matcher</code> - </dd>
<dt>Returns:</dt>
<dd>true if matched and consumed, false otherwise</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="findFirst(java.util.regex.Matcher)">
<h3>findFirst</h3>
<div class="member-signature"><span class="modifiers">protected</span>&nbsp;<span class="return-type">boolean</span>&nbsp;<span class="element-name">findFirst</span>&#8203;<span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/regex/Matcher.html" title="class or interface in java.util.regex" class="external-link" target="_blank">Matcher</a>&nbsp;matcher)</span></div>
<div class="block">Finds the first match. No consumption or token generation occurs.
The buffer state is left intact.
<br></div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>matcher</code> - </dd>
<dt>Returns:</dt>
<dd>true if match found, false otherwise</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="indexOfLast(java.util.regex.Matcher)">
<h3>indexOfLast</h3>
<div class="member-signature"><span class="modifiers">protected</span>&nbsp;<span class="return-type">int</span>&nbsp;<span class="element-name">indexOfLast</span>&#8203;<span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/regex/Matcher.html" title="class or interface in java.util.regex" class="external-link" target="_blank">Matcher</a>&nbsp;matcher)</span></div>
<div class="block">Returns the starting index of the last matched pattern, but doesn't consume anything or generate
tokens.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>matcher</code> - </dd>
<dt>Returns:</dt>
<dd>starting index of last match, or -1 if nothing found</dd>
</dl>
</section>
</li>
</ul>
</section>
</li>
</ul>
</section>
<!-- ========= END OF CLASS DATA ========= -->
</main>
<footer role="contentinfo">
<hr>
<p class="legal-copy"><small><a href="https://www.eclipse.org/openj9/" target="_blank">Eclipse OpenJ9 website.</a><br> To raise a bug report or suggest an improvement create an <a href="https://github.com/eclipse-openj9/openj9/issues" target="_blank">Eclipse Openj9 issue.</a><br> Copyright &copy; 1998, 2021, IBM Corp. and others.</small></p>
</footer>
</div>
</div>
</body>
</html>