public class FullTextMatchingLicense extends BaseLicense implements IHeaderMatcher
The text comparison is case insensitive but assumes only characters in the US-ASCII charset are being matched.
Modifier | Constructor and Description |
---|---|
|
FullTextMatchingLicense() |
protected |
FullTextMatchingLicense(MetaData.Datum licenseFamilyCategory,
MetaData.Datum licenseFamilyName,
String notes,
String fullText) |
Modifier and Type | Method and Description |
---|---|
boolean |
hasFullText() |
boolean |
match(Document subject,
String line)
Matches the text accumulated to licenses.
|
void |
reset()
Resets this matches.
|
void |
setFullText(String text) |
getLicenseFamilyCategory, getLicenseFamilyName, getNotes, prune, reportOnLicense, setLicenseFamilyCategory, setLicenseFamilyName, setNotes
public FullTextMatchingLicense()
protected FullTextMatchingLicense(MetaData.Datum licenseFamilyCategory, MetaData.Datum licenseFamilyName, String notes, String fullText)
public final void setFullText(String text)
public final boolean hasFullText()
public boolean match(Document subject, String line) throws RatHeaderAnalysisException
IHeaderMatcher
match
in interface IHeaderMatcher
subject
- current document.line
- next line of text, not nullRatHeaderAnalysisException
- in case of internal RAT errors.public void reset()
IHeaderMatcher
IHeaderMatcher.match(org.apache.rat.api.Document, java.lang.String)
will accumulate new text.reset
in interface IHeaderMatcher
Copyright © 2006–2018 Apache Software Foundation. All rights reserved.