implements deleteAllBag and deleteBag methods