Liking cljdoc? Tell your friends :D

io.randomseed.utils.bot

Random utils, bot abstraction.

Random utils, bot abstraction.
raw docstring

bot-nsclj

(bot-ns v id)
source

bot?clj

(bot? v)
source

commandclj

(command wrk command & args)
source

current-ns-strclj

source

generic-controlclj

(generic-control bot-session f wrk req handler-args)

Common tasks which any bot should support.

Common tasks which any bot should support.
sourceraw docstring

generic-data-handlerclj

(generic-data-handler data bot-session)

Handles additional data which are a result of a request. It's like side effect for the request, regardless of its reply. When session object is returned then bot-specific data handlers should not interfere (processing is done) and just replace session with the returned one. When nil is returned then bot-specific data handlers should exit the loop and finish execution. All other data is passed as is.

Handles additional data which are a result of a request. It's like side effect for
the request, regardless of its reply. When session object is returned then
bot-specific data handlers should not interfere (processing is done) and just
replace session with the returned one. When nil is returned then bot-specific data
handlers should exit the loop and finish execution. All other data is passed as
is.
sourceraw docstring

get-configclj

(get-config wrk)
source

get-dataclj

(get-data wrk k & args)
source

get-data!clj

(get-data! wrk k & args)
source

get-sessionclj

(get-session wrk)
source

handle-requestclj

(handle-request bot-session f data-handler wrk req & handler-args)

Handles requests. Returns an Outcome object. Passes control to a chosen request handler f to prepare the response. Updates the returned map with data-handler if data is present in the outcome.

Handles requests. Returns an Outcome object. Passes control to a chosen request
handler f to prepare the response. Updates the returned map with data-handler if
data is present in the outcome.
sourceraw docstring

instance-configclj

(instance-config cfg instance-id)

Creates an instance of a configuration for the given instance (if a bot is instantiable).

Creates an instance of a configuration for the given instance (if a bot is
instantiable).
sourceraw docstring

loadclj

(load config-parser id)
(load config-parser id instance-id)
source

load-configclj

(load-config cfg-parser bot-id)
(load-config cfg-parser config-file bot-id)
source

parse-configclj

(parse-config cfg)
(parse-config cfg instance-id)
source

pauseclj

(pause wrk)
source

pingclj

(ping wrk)
source

run!clj

(run! wrk)
(run! bot-session cfg)
(run! bot-session cfg instance)

Runs a bot by creating a worker thread with communication channels. After bot is successfully created it queries it for its updated configuration and replaces a local one with it.

Runs a bot by creating a worker thread with communication channels. After bot is
successfully created it queries it for its updated configuration and replaces a local
one with it.
sourceraw docstring

stop!clj

(stop! wrk)
source

update-local-config!clj

(update-local-config! wid)
source

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close