TagStackEntry |
TagStack.back() |
Alias to the last element on the tag stack.
|
void |
AMPHtmlHandler.cdata(String text) |
Callback for cdata.
|
CdataMatcher |
TagStack.cdataMatcher() |
Returns the cdata matcher for the tag currently on the stack.
|
ChildTagMatcher |
ParsedTagSpec.childTagMatcher() |
If tag has a child_tag spec, returns a ChildTagMatcher, else null.
|
boolean |
TagStack.countDocCssBytes() |
Returns true if this within lt;style amp-custom gt;.
|
void |
ReferencePointMatcher.exitParentTag(Context context,
dev.amp.validator.ValidatorProtos.ValidationResult.Builder result) |
This method gets invoked when we're done with processing all the
child tags, so now we can determine whether any reference points
remain unsatisfied or duplicate.
|
void |
ChildTagMatcher.exitTag(Context context,
dev.amp.validator.ValidatorProtos.ValidationResult.Builder result) |
Exit tag.
|
void |
TagStack.exitTag(Context context,
dev.amp.validator.ValidatorProtos.ValidationResult.Builder result) |
Upon exiting a tag, validation for the current child tag matcher is
triggered, e.g.
|
ParsedTagSpec |
ParsedValidatorRules.getByTagSpecId(int id) |
Returns the ParsedTagSpec given the tag spec id.
|
ParsedTagSpec |
ParsedValidatorRules.getByTagSpecId(String specName) |
Return the ParsedTagSpec given the reference point spec name.
|
String |
ParsedValidatorRules.getReferencePointName(dev.amp.validator.ValidatorProtos.ReferencePoint referencePoint) |
Computes the name for a given reference point.
|
int |
AMPValidatorManager.getTagSpecIdByReferencePointTagSpecName(String specName) |
Returns the specId for given the tag spec name of the reference point.
|
int |
ParsedValidatorRules.getTagSpecIdByReferencePointTagSpecName(String tagName) |
Returns the tag spec id by reference point tag spec name.
|
boolean |
TagStack.hasAncestorMarker(dev.amp.validator.ValidatorProtos.AncestorMarker.Marker query) |
Returns true if the current tag has an ancestor which set the given marker.
|
boolean |
TagStack.isScriptTypeJsonChild() |
Returns true if this within script type=application/json.
|
void |
CdataMatcher.match(String cdata,
Context context,
dev.amp.validator.ValidatorProtos.ValidationResult.Builder validationResult) |
Matches the provided cdata against what this CdataMatcher expects.
|
void |
ChildTagMatcher.matchChildTagName(ParsedHtmlTag encounteredTag,
Context context,
dev.amp.validator.ValidatorProtos.ValidationResult.Builder result) |
Matching child tag name.
|
void |
TagStack.matchChildTagName(ParsedHtmlTag encounteredTag,
Context context,
dev.amp.validator.ValidatorProtos.ValidationResult.Builder result) |
This method is called as we're visiting a tag; so the matcher we
need here is the one provided/specified for the tag parent.
|
void |
ParsedValidatorRules.maybeEmitAlsoRequiresTagValidationErrors(Context context,
dev.amp.validator.ValidatorProtos.ValidationResult.Builder validationResult) |
Emits errors for tags that specify that another tag is also required or
a condition is required to be satisfied.
|
void |
ParsedValidatorRules.maybeEmitCssLengthSpecErrors(Context context,
dev.amp.validator.ValidatorProtos.ValidationResult.Builder validationResult) |
Emits errors for css size limitations across entire document.
|
void |
ParsedValidatorRules.maybeEmitGlobalTagValidationErrors(Context context,
dev.amp.validator.ValidatorProtos.ValidationResult.Builder validationResult) |
Emits any validation errors which require a global view
(mandatory tags, tags required by other tags, mandatory alternatives).
|
void |
ParsedValidatorRules.maybeEmitMandatoryAlternativesSatisfiedErrors(Context context,
dev.amp.validator.ValidatorProtos.ValidationResult.Builder validationResult) |
Emits errors for tags that are specified as mandatory alternatives.
|
void |
ParsedValidatorRules.maybeEmitMandatoryTagValidationErrors(Context context,
dev.amp.validator.ValidatorProtos.ValidationResult.Builder validationResult) |
Emits errors for tags that are specified to be mandatory.
|
void |
ParsedValidatorRules.maybeEmitValueSetMismatchErrors(Context context,
dev.amp.validator.ValidatorProtos.ValidationResult.Builder validationResult) |
Emits errors when there is a ValueSetRequirement with no matching
ValueSetProvision in the document.
|
int |
TagStack.parentChildCount() |
The number of children that have been discovered up to now by traversing
the stack.
|
boolean |
TagStack.parentHasChildWithLastChildRule() |
|
boolean |
TagStack.parentHasChildWithNoSiblingRule() |
|
Locator |
TagStack.parentLastChildErrorLineCol() |
Returns the Locator of the tag that set the 'last child' rule.
|
String |
TagStack.parentLastChildTagName() |
|
String |
TagStack.parentLastChildUrl() |
|
Locator |
TagStack.parentOnlyChildErrorLineCol() |
Returns the parent only child error line col.
|
String |
TagStack.parentOnlyChildTagName() |
|
ReferencePointMatcher |
TagStack.parentReferencePointMatcher() |
Returns the parent stack entry reference point matcher.
|
TagStackEntry |
TagStack.parentStackEntry() |
The parent of the current stack entry.
|
String |
TagStack.parentTagName() |
The name of the parent of the current tag.
|
String |
TagStack.parentTagSpecName() |
The spec_name of the parent of the current tag if one exists, otherwise the
tag_name.
|
ReferencePointMatcher |
ParsedTagSpec.referencePointMatcher(ParsedValidatorRules rules,
Locator lineCol) |
If tag has a reference_point spec, returns a ReferencePointMatcher,
else null.
|
void |
TagStack.setCdataMatcher(CdataMatcher matcher) |
Sets the cdata matcher for the tag currently on the stack.
|
void |
TagStack.setChildTagMatcher(ChildTagMatcher matcher) |
Sets the child tag matcher for the tag currently on the stack.
|
void |
TagStack.setDescendantConstraintList(ParsedTagSpec parsedTagSpec,
ParsedValidatorRules parsedRules) |
Setting the descendant constraint list.
|
void |
TagStack.setReferencePointMatcher(ReferencePointMatcher matcher) |
Sets the reference point matcher for the tag currently on the stack.
|
void |
TagStack.tellParentImTheLastChild(String tagName,
String url,
Locator lineCol) |
Tells the parent of the current stack entry that its last child must be me
(the current stack entry).
|
void |
TagStack.tellParentNoSiblingsAllowed(String tagName,
Locator lineCol) |
Tells the parent of the current stack entry that it can only have 1 child
and that child must be me (the current stack entry).
|
void |
Context.updateFromTagResults(ParsedHtmlTag encounteredTag,
ValidateTagResult referencePointResult,
ValidateTagResult tagResult) |
Given the tagResult from validating a single tag, update the overall
result as well as the Context state to affect later validation.
|
void |
TagStack.updateFromTagResults(ParsedHtmlTag encounteredTag,
ValidateTagResult referencePointResult,
ValidateTagResult tagResult,
ParsedValidatorRules parsedRules,
Locator lineCol) |
Update tagstack state after validating an encountered tag.
|
void |
TagStack.updateStackEntryFromTagResult(ValidateTagResult result,
ParsedValidatorRules parsedRules,
Locator lineCol) |
Given a ValidateTagResult, update the tag stack entry at the top of the
tag stack to add any constraints from the spec.
|
ValidateTagResult |
ReferencePointMatcher.validateTag(ParsedHtmlTag tag,
Context context) |
This method gets invoked when matching a child tag of the parent
that is specifying / requiring the reference points.
|