This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns patterns.decorator.core | |
(:require [clojure.data.json :as json] | |
[clojure.string :as str] | |
[patterns.util :refer [to-xml]])) | |
;; Record impl | |
(defprotocol IRenderable | |
(render [this])) | |
(defrecord WebService [data] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(definterface IBigInt | |
(add this y) | |
(subtract this y) | |
(multiply this y) | |
(divide this y)) | |
(defprotocol BigInt [signum magnitude] | |
IBigInt | |
(add (add this y)) | |
(subtract (sub this y)) |