Skip to content

Instantly share code, notes, and snippets.

@pjstadig
Created February 25, 2022 14:18
Show Gist options
  • Save pjstadig/ceda404c0f750ec09b449a58c3aa45de to your computer and use it in GitHub Desktop.
Save pjstadig/ceda404c0f750ec09b449a58c3aa45de to your computer and use it in GitHub Desktop.
Protocol + client + multimethod
(ns stadig.storage.protocol
(:refer-clojure :exclude [get]))
(defprotocol IStorage
(get [this bucket key])
(put [this bucket key value])
(delete [this bucket key])
(close [this]))
(defmulti connect :backend)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment