public class CompareTemplateOutputHandler extends Object implements ILicenseTemplateOutputHandler
| Constructor and Description |
|---|
CompareTemplateOutputHandler(String compareText) |
| Modifier and Type | Method and Description |
|---|---|
void |
beginOptional(LicenseTemplateRule rule)
Begin optional rule found
|
void |
endOptional(LicenseTemplateRule rule)
End optional rule found
|
boolean |
matches() |
void |
normalText(String text)
Normal text found with the template (non-optional and not within a variable rule)
|
void |
optionalText(String text)
Text found within an optional text block
|
protected boolean |
textEquivalent(String text)
compare the text to the compare text at the current location
|
void |
variableRule(LicenseTemplateRule rule)
Variable rule found within the template
|
public CompareTemplateOutputHandler(String compareText)
compareText - Text to compare the parsed SPDX license template topublic void optionalText(String text)
ILicenseTemplateOutputHandleroptionalText in interface ILicenseTemplateOutputHandlerprotected boolean textEquivalent(String text)
text - public void normalText(String text)
ILicenseTemplateOutputHandlernormalText in interface ILicenseTemplateOutputHandlerpublic void variableRule(LicenseTemplateRule rule)
ILicenseTemplateOutputHandlervariableRule in interface ILicenseTemplateOutputHandlerpublic void beginOptional(LicenseTemplateRule rule)
ILicenseTemplateOutputHandlerbeginOptional in interface ILicenseTemplateOutputHandlerpublic void endOptional(LicenseTemplateRule rule)
ILicenseTemplateOutputHandlerendOptional in interface ILicenseTemplateOutputHandlerpublic boolean matches()
Copyright © 2017 Linux Foundation. All Rights Reserved.