Liking cljdoc? Tell your friends :D

frereth.cp.message.to-child

Looks like this may not be needed at all

Pretty much everything that might have been interesting really seems to belong in from-parent.

Or in the callback that got handed to message as part of its constructor.

Although there is the bit about closing the pipe to the child at the bottom of each event loop.

Looks like this may not be needed at all

Pretty much everything that might have been interesting really
seems to belong in from-parent.

Or in the callback that got handed to message as part of its constructor.

Although there *is* the bit about closing the pipe to the child at
the bottom of each event loop.
raw docstring

build-gap-bufferclj

(build-gap-buffer)
source

callback-threshold-errorclj

Signal error if calling back to child w/ incoming message takes much too long (in milliseconds)

Signal error if calling back to child w/ incoming message takes much too long (in milliseconds)
sourceraw docstring

callback-threshold-warningclj

Warn if calling back to child w/ incoming message takes too long (in milliseconds)

Warn if calling back to child w/ incoming message takes too long (in milliseconds)
sourceraw docstring

close-parent-input!clj

(close-parent-input! {:keys [:frereth.cp.message.specs/from-parent-trigger
                             :frereth.cp.message.specs/to-child-done?]
                      :as io-handle})
source

consolidate-gap-bufferclj

(consolidate-gap-buffer {{:keys [:frereth.cp.message.specs/gap-buffer]
                          :as incoming}
                           :frereth.cp.message.specs/incoming
                         :keys [:frereth.cp.message.specs/message-loop-name]
                         :as state})
source

consolidate-message-blockclj

(consolidate-message-block
  {{:keys [:frereth.cp.message.specs/->child-buffer
           :frereth.cp.message.specs/gap-buffer
           :frereth.cp.message.specs/contiguous-stream-count]
    :as incoming}
     :frereth.cp.message.specs/incoming
   :keys [:frereth.cp.message.specs/message-loop-name]
   log-state :frereth.weald.specs/state
   :as state}
  k-v-pair)

Move the parts of the gap-buffer that are ready to write to child

Really only meant as a helper refactored out of consolidate-gap-buffer

Move the parts of the gap-buffer that are ready to write to child

Really only meant as a helper refactored out of consolidate-gap-buffer
sourceraw docstring

forward!clj

(forward! {:keys [:frereth.cp.message.specs/from-parent]
           parent-trigger :frereth.cp.message.specs/from-parent-trigger
           :as io-handle}
          {:keys [:frereth.cp.message.specs/message-loop-name]
           original-incoming :frereth.cp.message.specs/incoming
           log-state :frereth.weald.specs/state
           :as state})

Trigger the parent-monitor 'loop'

Trigger the parent-monitor 'loop'
sourceraw docstring

pop-map-firstclj

(pop-map-first associative)

Pop first entry from a map. Only makes sense if sorted

Pop first entry from a map. Only makes sense if sorted
sourceraw docstring

possibly-close-stream!clj

(possibly-close-stream!
  {:keys [:frereth.cp.message.specs/from-parent-trigger] :as io-handle}
  {{:keys [:frereth.cp.message.specs/contiguous-stream-count
           :frereth.cp.message.specs/receive-eof
           :frereth.cp.message.specs/receive-total-bytes
           :frereth.cp.message.specs/receive-written]
    :as incoming}
     :frereth.cp.message.specs/incoming
   log-state :frereth.weald.specs/state
   :as state})

Maybe signal child that it won't receive anything else

Maybe signal child that it won't receive anything else
sourceraw docstring

start-parent-monitor!clj

(start-parent-monitor!
  {:keys [:frereth.weald.specs/logger :frereth.cp.message.specs/child-in
          :frereth.cp.message.specs/message-loop-name]
   trigger-stream :frereth.cp.message.specs/from-parent-trigger
   :as io-handle}
  parent-log
  cb)

This is probably a reasonable default for many/most use cases

This is probably a reasonable default for many/most use cases
sourceraw docstring

trigger-from-parent!clj

(trigger-from-parent! {:keys [:frereth.weald.specs/logger
                              :frereth.cp.message.specs/message-loop-name]
                       :as io-handle}
                      buffer
                      cb
                      {:keys [:frereth.cp.message.to-child/result-writer
                              :frereth.cp.message.specs/bs-or-eof]
                       my-logs :frereth.weald.specs/state
                       :as trigger})

Stream handler for coping with bytes sent by parent

Stream handler for coping with bytes sent by parent
sourceraw docstring

write-bytes-to-child-stream!clj

(write-bytes-to-child-stream! parent-trigger
                              {log-state :frereth.weald.specs/state :as state}
                              buf)

Forward the byte-array inside the buffer

Forward the byte-array inside the buffer
sourceraw docstring

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

× close