File: examples.clj

package info (click to toggle)
clojure1.6 1.6.0%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 3,608 kB
  • ctags: 5,838
  • sloc: java: 27,336; xml: 498; sh: 69; makefile: 45
file content (19 lines) | stat: -rw-r--r-- 463 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
(ns clojure.test-clojure.protocols.examples)

(defprotocol ExampleProtocol
  "example protocol used by clojure tests"

  (foo [a] "method with one arg")
  (bar [a b] "method with two args")
  (^String baz [a] [a b] "method with multiple arities")
  (with-quux [a] "method name with a hyphen"))

(defprotocol MarkerProtocol
  "a protocol with no methods")

(defprotocol MarkerProtocol2)

(definterface ExampleInterface
  (hinted [^int i])
  (hinted [^String s]))