Remove the cookbook from the store.

 @param [CommunityZero::Cookbook] cookbook
   the cookbook to remove
486751
def remove(cookbook)
      return unless has_cookbook?(cookbook.name, cookbook.version)
      _cookbooks[cookbook.name].delete(cookbook.version)
    end
1334828
function removeHandler(store, name, callback, context) {
  var event = store[name];
  if (
     (!callback || (callback === event.callback || callback === event.callback._callback)) &&
     (!context || (context === event.context))
  ) {
    delete store[name];
    return true;
  }
}
382757
private void clearMenus()
    {
        for (final Featurable menu : menus)
        {
            menu.getFeature(Identifiable.class).destroy();
            handler.remove(menu);
        }
        menus.clear();
    }
1260418
def delete(key)
      @cache.delete(key)
      File.delete(path_to(hash(key))) if disk_cache_enabled?
    end
60203
def cookbook_name(file)
      raise ArgumentError, "File cannot be nil or empty" if file.to_s.empty?

      # Name is a special case as we want to fallback to the cookbook directory
      # name if metadata_field fails
      begin
        metadata_field(file, "name")
      rescue RuntimeError
        until (file.split(File::SEPARATOR) & standard_cookbook_subdirs).empty?
          file = File.absolute_path(File.dirname(file.to_s))
        end
        file = File.dirname(file) unless File.extname(file).empty?
        File.basename(file)
      end
    end
1283571
def create_cookbook(metadata, overrides = {})
        cookbook = Cookbook.new({
          :name        => metadata.name,
          :category    => nil,
          :maintainer  => metadata.maintainer,
          :description => metadata.description,
          :version     => metadata.version
        }.merge(overrides))

        store.add(cookbook)

        cookbook
      end
6470
def __deactivate_recipes(self, plugin, *args, **kwargs):
        
        recipes = self.get()
        for recipe in recipes.keys():
            self.unregister(recipe)
412732
def submit_cookbook(self, cookbook, params={}, _extra_params={}):
        
        self._check_user_parameters(params)
        files = {'cookbook': cookbook}
        return self._submit(params, files, _extra_params=_extra_params)
266721
def remove_instance(self):
        
        with fields.FieldLock(self.related_field):
            related_pks = self()
            for pk in related_pks:

                # get the real related field
                related_instance = self.related_field._model(pk)
                related_field = getattr(related_instance, self.related_field.name)

                # check if we have a dedicated remove method
                remover = getattr(related_field, '_related_remover', None)

                # then remove the instance from the related field
                if remover is not None:
                    # if we have a remover method, it wants the instance as argument
                    # (the related field may be a set/list/sorted_set)
                    getattr(related_field, remover)(self.instance._pk)
                else:
                    # no remover method, simple delete the field
                    related_field.delete()
1165402
def remove_menu(self, name):
        
        if name not in self._menus:
            raise exceptions.MenuNotFound(
                "Menu {!r} was not found. It might be deleted, or belong to another menu manager.".format(name))

        self._menu.removeAction(self._menus[name].menuAction())
        del self._menus[name]
997483
def destroy(self):
        
        pb = self._get_ansible_playbook(self.playbooks.destroy)
        pb.execute()
785696
def remove_widget widget
     if widget.respond_to? :name and !widget.name.nil?
       @by_name.delete(widget.name)
     end
     @focusable_modified = true
     @widgets.delete widget
   end
263794
def save
      unless empty?
        recipes = @recipes.keys.sort
        metadata_content = <<-EOS
description "Automatically generated repo, do not modify"
#{recipes.map { |r| "recipe \"#{COOKBOOK_NAME}::#{r}\", \"RightScript < #{@recipes[r]} >\"" }.join("\n")}
        EOS
        metadata_path = File.join(@cookbook_dir, 'metadata.rb')
        File.open(metadata_path, 'w') { |f| f.puts metadata_content }
      end
      @saved = true
    end
128508
def cookbook_collection(node)
      if chef_run.respond_to?(:run_context)
        chef_run.run_context.cookbook_collection # Chef 11.8+
      elsif node.respond_to?(:run_context)
        node.run_context.cookbook_collection # Chef 11+
      else
        node.cookbook_collection # Chef 10
      end
    end
127075
def add(cookbook)
      cookbook = cookbook.dup
      cookbook.created_at = Time.now
      cookbook.updated_at = Time.now

      entry = _cookbooks[cookbook.name] ||= {}
      entry[cookbook.version] = cookbook
    end
803360
@Override
    public void deleteStoreIfPresent(String storeName) {
        String tableName = storeToCQLName(storeName);
        if (storeExists(tableName)) {
            new CQLSchemaManager(this).dropCQLTable(tableName);
        }
    }
905429
def cookbooks_and_dependencies
        loaded_dependencies = Hash.new(false)

        dependencies = @cookbooks.dup
        dependencies.each do |cookbook|
          loaded_dependencies[cookbook.cookbook_name] = true

          cookbook.metadata.dependencies.keys.each do |dependency_name|
            unless loaded_dependencies[dependency_name]
              dependencies << load_cookbook(dependency_name)
              loaded_dependencies[dependency_name] = true
            end
          end
        end
      end