public static void removeLocalBundle(String name, Version version, boolean removePhysical, boolean doubleTap) throws BundleException {
	name = name.trim();
	CFMLEngine engine = CFMLEngineFactory.getInstance();
	CFMLEngineFactory factory = engine.getCFMLEngineFactory();

	BundleFile bf = _getBundleFile(factory, name, version, null);
	if (bf != null) {
	    BundleDefinition bd = bf.toBundleDefinition();
	    if (bd != null) {
		Bundle b = bd.getLocalBundle();
		if (b != null) {
		    stopIfNecessary(b);
		    b.uninstall();
		}
	    }
	}

	if (!removePhysical) return;

	// remove file
	if (bf != null) {
	    if (!bf.getFile().delete() && doubleTap) bf.getFile().deleteOnExit();
	}
    }
public static void removeLocalBundle ( String name , Version version , boolean removePhysical , boolean doubleTap ) throws BundleException { name = name . trim ( ) ; CFMLEngine engine = CFMLEngineFactory . getInstance ( ) ; CFMLEngineFactory factory = engine . getCFMLEngineFactory ( ) ; BundleFile bf = _getBundleFile ( factory , name , version , null ) ; if ( bf != null ) { BundleDefinition bd = bf . toBundleDefinition ( ) ; if ( bd != null ) { Bundle b = bd . getLocalBundle ( ) ; if ( b != null ) { stopIfNecessary ( b ) ; b . uninstall ( ) ; } } } if ( ! removePhysical ) return ; if ( bf != null ) { if ( ! bf . getFile ( ) . delete ( ) && doubleTap ) bf . getFile ( ) . deleteOnExit ( ) ; } }
get local bundle, but does not download from update provider!

@param name
@param version
@return
@throws BundleException