cl-chat-web/package.lisp

66 lines
1.7 KiB
Common Lisp
Raw Normal View History

2024-10-11 16:45:22 -04:00
(in-package #:cl-user)
(defpackage #:live-chat-db
(:use #:cl)
(:local-nicknames (#:cl-dbi #:dbi))
(:export #:*db*
#:open-database
#:close-database
#:create-messages-table
#:insert-message
#:fetch-messages
#:clear-messages))
2024-10-11 16:45:22 -04:00
(defpackage #:live-chat-ui
2024-10-11 16:45:22 -04:00
(:use #:cl)
(:local-nicknames (#:cl-who #:cl-who))
(:import-from #:live-chat-db
#:insert-message
#:fetch-messages)
(:export #:set-subpath-prefix
#:render-chat-messages
2024-10-11 16:45:22 -04:00
#:render-chat-ui
#:handle-post-message
#:*messages*))
(defpackage #:live-chat-cgi
(:use #:cl)
(:import-from #:live-chat-ui)
2024-10-11 16:45:22 -04:00
(:export #:cgi-handler))
(defpackage #:live-chat-routes
2024-10-11 16:45:22 -04:00
(:use #:cl)
(:import-from #:live-chat-db
#:insert-message)
(:import-from #:live-chat-ui
2024-10-11 16:45:22 -04:00
#:handle-post-message
#:render-chat-messages
#:render-chat-ui)
(:local-nicknames (#:cl-who #:cl-who)
(#:myway #:myway))
(:export #:app))
(defpackage #:live-chat-ws
(:use #:cl)
(:import-from #:websocket-driver
#:make-client
#:make-server
#:on
#:send
#:start-connection
#:close-connection)
(:export #:make-websocket-server
#:handle-close-connection
#:broadcast-to-room
#:handle-new-connection
#:*connections*))
2024-10-11 16:45:22 -04:00
(uiop:define-package #:live-chat
(:use #:cl)
(:import-from #:clack #:clackup)
(:use-reexport #:live-chat-ui
2024-10-11 16:45:22 -04:00
#:live-chat-db
#:live-chat-routes))
2024-10-11 16:45:22 -04:00
(in-package #:live-chat)