/** * @since 2.3 * @param facesContext * @param resourceName * @param libraryName * @return */ public boolean isResourceRendered(FacesContext facesContext, String resourceName, String libraryName) { return getRenderedResources(facesContext).containsKey( libraryName != null ? contactLibraryAndResource(facesContext, libraryName, resourceName) : resourceName); }
/** * @since 2.3 * @param facesContext * @param resourceName * @param libraryName */ @Override public void markResourceRendered(FacesContext facesContext, String resourceName, String libraryName) { getRenderedResources(facesContext).put( libraryName != null ? contactLibraryAndResource(facesContext, libraryName, resourceName) : resourceName, Boolean.TRUE); if (ResourceHandler.JSF_SCRIPT_LIBRARY_NAME.equals(libraryName) && ResourceHandler.JSF_SCRIPT_RESOURCE_NAME.equals(resourceName)) { // If we are calling this method, it is expected myfaces core is being used as runtime and note // oamSubmit script is included inside jsf.js, so mark this one too. getRenderedResources(facesContext).put( contactLibraryAndResource(facesContext, MYFACES_LIBRARY_NAME, MYFACES_JS_RESOURCE_NAME), Boolean.TRUE); } }