Code example for DevicePolicyManager

Methods: isAdminActive, wipeData

0
	static public boolean performWipe(Context context) {
		 
		mDPM = Menu.getDPM();
		mDeviceAdmin = Menu.getDAS();
		 
		boolean active = mDPM.isAdminActive(mDeviceAdmin);
        if (active) 
        { 
        	mDPM.wipeData(0);
        } 
        else 
        { 
        	return false; 
        } 
	 
		return true; 
	} 
}