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

org.zkoss.bind.init.WebAppInit Maven / Gradle / Ivy

There is a newer version: 10.0.0-jakarta
Show newest version
/* WebAppInit.java

	Purpose:
		
	Description:
		
	History:
		Fri May 17 09:53:37 CST 2019, Created by rudyhuang

Copyright (C) 2019 Potix Corporation. All Rights Reserved.
*/
package org.zkoss.bind.init;

import org.zkoss.bind.callback.DestroyCallback;
import org.zkoss.zk.ui.WebApp;
import org.zkoss.zk.ui.util.Configuration;

/**
 * The initialization of zkbind.
 *
 * @author rudyhuang
 * @since 8.6.2
 */
public class WebAppInit implements org.zkoss.zk.ui.util.WebAppInit {
	public void init(WebApp wapp) throws Exception {
		// ZK-1148: @Destroy support
		Configuration conf = wapp.getConfiguration();
		if (!conf.hasCallBack("destroy")) {
			conf.registerCallBack("destroy", new DestroyCallback());
		}
	}
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy