You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: cookies_consent.rb
    path of file: ./repos/openfoodnetwork/engines/web/lib/web
    
    the code of the file until where you have to start completion: # frozen_string_literal: true

module Web
  class CookiesConsent
    COOKIE_NAME = 'cookies_consent'

    def initialize(cookies, domain)
      @cookies = cookies
      @domain = domain
    end

    def exists?
      cookies.key?(COOKIE_NAME)
    end

    def destroy
      cookies.delete(COOKIE_NAME, domain:)
    end

    def set
      cookies[COOKIE_NAME] = {
        value: COOKIE_NAME,
 
    
    def initialize(cookies, domain)
      @cookies = cookies
      @domain = domain
    end

    def exists?
      cookies.key?(COOKIE_NAME)
    end

    def destroy
      cookies.delete(COOKIE_NAME, domain:)
    end

    def set
      cookies[COOKIE_NAME] = {
        value: COOKIE_NAME,
        expires: 1.year.from_now,
        domain:,
        httponly: true
      }
    end

    private

    attr_reader :cookies, :domain
  end
end