feat: Implement public functions in client.clj using api namespace calls
This commit is contained in:
@@ -3,33 +3,33 @@
|
|||||||
|
|
||||||
(defn send! [client topic msg & {:keys [qos retain]
|
(defn send! [client topic msg & {:keys [qos retain]
|
||||||
:or {qos 1 retain false}}]
|
:or {qos 1 retain false}}]
|
||||||
...)
|
(api/send! client topic msg :qos qos :retain retain))
|
||||||
|
|
||||||
(defn get! [client topic & options]
|
(defn get! [client topic & options]
|
||||||
...)
|
(api/get! client topic options))
|
||||||
|
|
||||||
(defn get-raw! [client topic & options]
|
(defn get-raw! [client topic & options]
|
||||||
...)
|
(api/get-raw! client topic options))
|
||||||
|
|
||||||
(defn open-channel!
|
(defn open-channel!
|
||||||
[client topic & {:keys [buffer-size qos retain]
|
[client topic & {:keys [buffer-size qos retain]
|
||||||
:or {buffer-size 1
|
:or {buffer-size 1
|
||||||
qos 1
|
qos 1
|
||||||
retain false}}]
|
retain false}}]
|
||||||
...)
|
(api/open-channel! client topic :buffer-size buffer-size :qos qos :retain retain))
|
||||||
|
|
||||||
(defn subscribe!
|
(defn subscribe!
|
||||||
[client topic & {:keys [buffer-size qos]
|
[client topic & {:keys [buffer-size qos]
|
||||||
:or {buffer-size 1
|
:or {buffer-size 1
|
||||||
qos 1}}]
|
qos 1}}]
|
||||||
...)
|
(api/subscribe! client topic :buffer-size buffer-size :qos qos))
|
||||||
|
|
||||||
(defn connect!
|
(defn connect!
|
||||||
[& {:keys [host port scheme verbose]
|
[& {:keys [host port scheme verbose]
|
||||||
:or {verbose false
|
:or {verbose false
|
||||||
scheme :tcp}
|
scheme :tcp}
|
||||||
:as opts}]
|
:as opts}]
|
||||||
...)
|
(api/connect! :host host :port port :scheme scheme :verbose verbose))
|
||||||
|
|
||||||
(defn connect-json! [& args]
|
(defn connect-json! [& args]
|
||||||
...)
|
(apply api/connect-json! args))
|
||||||
|
|||||||
Reference in New Issue
Block a user