All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.jk.web.faces.renderers.JKPreRenderer Maven / Gradle / Ivy

There is a newer version: 5.4.7-R2
Show newest version
package com.jk.web.faces.renderers;

import java.io.IOException;

import javax.faces.FacesException;
import javax.faces.component.UIComponent;
import javax.faces.context.FacesContext;
import javax.faces.event.AbortProcessingException;
import javax.faces.event.PreRenderComponentEvent;
import javax.faces.event.SystemEvent;
import javax.faces.event.SystemEventListener;

import org.omnifaces.component.output.Cache;
import org.primefaces.component.cache.UICache;


public class JKPreRenderer implements SystemEventListener {

	@Override
	public void processEvent(SystemEvent event) throws AbortProcessingException {
//		if (event instanceof PreRenderComponentEvent) {
//			if(FacesContext.getCurrentInstance().isPostback()){
//				PreRenderComponentEvent preRenderComponentEvent = (PreRenderComponentEvent) event;
//				
//				UIComponent component = preRenderComponentEvent.getComponent();				
//			}
			
//		}
	}

	@Override
	public boolean isListenerForSource(Object source) {
//		if(source instanceof UICache ) {
//			UICache cache=(UICache) source;
//			//cache.clearInitialState();
//			return true;
//		}
//		return false;
		return true;
	}

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy