package cn.shiyanjun.platform.api.utils;

import cn.shiyanjun.platform.api.LifecycleAware;

public class ComponentUtils {

	public static void stopAllQuietly(LifecycleAware... components) {
		if(components != null) {
			for(LifecycleAware c : components) {
				try {
					c.stop();
				} catch (Exception e) {
					// ignore it
				}
			}
		}
	}
}

@@ -116,16 +116,139 @@
 tils %7B%0A%0A
+%09public static void startAll(LifecycleAware... components) %7B%0A%09%09for(LifecycleAware c : components) %7B%0A%09%09%09c.start();%0A%09%09%7D%0A%09%7D%0A%09%0A
 %09public 

Add an utility method 'startAll' to start all components.