private boolean checkIfParentShouldBeEncodedAndBuildPath(StringBuilder thePathBuilder, boolean theStarPass) { Set<String> encodeElements = myEncodeElements; if (encodeElements != null && encodeElements.isEmpty() == false) { if (isEncodeElementsAppliesToChildResourcesOnly() && !mySubResource) { encodeElements = null; } } return checkIfPathMatchesForEncoding(thePathBuilder, theStarPass, myEncodeElementsAppliesToResourceTypes, encodeElements, true); }
private boolean checkIfParentShouldBeEncodedAndBuildPath() { List<ElementsPath> encodeElements = myEncodeElements; String currentResourceName = myEncodeContext.getResourcePath().get(myEncodeContext.getResourcePath().size() - 1).getName(); if (myEncodeElementsAppliesToResourceTypes != null && !myEncodeElementsAppliesToResourceTypes.contains(currentResourceName)) { encodeElements = null; } boolean retVal = checkIfPathMatchesForEncoding(encodeElements, true); /* * We force the meta tag to be encoded even if it's not specified as an element in the * elements filter, specifically because we'll need it in order to automatically add * the SUBSETTED tag */ if (!retVal) { if ("meta".equals(myEncodeContext.getLeafResourcePathFirstField()) && shouldAddSubsettedTag(myEncodeContext)) { // The next element is a child of the <meta> element retVal = true; } else if ("meta".equals(myDef.getElementName()) && shouldAddSubsettedTag(myEncodeContext)) { // The next element is the <meta> element retVal = true; } } return retVal; }
private boolean checkIfParentShouldNotBeEncodedAndBuildPath() { return checkIfPathMatchesForEncoding(myDontEncodeElements, false); }
private boolean checkIfParentShouldNotBeEncodedAndBuildPath(StringBuilder thePathBuilder, boolean theStarPass) { return checkIfPathMatchesForEncoding(thePathBuilder, theStarPass, null, myDontEncodeElements, false); }