scopes/core basics - work in progress
This commit is contained in:
parent
8611caaa8f
commit
1986c37933
3 changed files with 13 additions and 7 deletions
|
@ -3,15 +3,18 @@
|
|||
(defpackage :scopes/core
|
||||
(:use :common-lisp)
|
||||
(:local-nicknames (:config :scopes/config))
|
||||
(:export #:config
|
||||
(:export #:config #:service-config
|
||||
#:message
|
||||
#:context #:name #:send))
|
||||
|
||||
(in-package :scopes/core)
|
||||
|
||||
(defclass config (config:base)
|
||||
(defclass config (config:root)
|
||||
(services))
|
||||
|
||||
(defclass service-config (config:base)
|
||||
(start))
|
||||
|
||||
(defclass message ()
|
||||
((domain)
|
||||
(action)
|
||||
|
@ -22,7 +25,7 @@
|
|||
(data)))
|
||||
|
||||
(defclass context ()
|
||||
((name :initarg :name :reader name)))
|
||||
((name :reader name :initarg :name)))
|
||||
|
||||
(defgeneric send (rcvr msg)
|
||||
(:method ((rcvr context) msg)
|
||||
|
@ -30,3 +33,6 @@
|
|||
msg))
|
||||
|
||||
(defvar *context* nil)
|
||||
|
||||
(defun printer (name)
|
||||
(make-instance 'context :name name))
|
||||
|
|
|
@ -2,5 +2,5 @@
|
|||
|
||||
(in-package :scopes/test-core)
|
||||
|
||||
(setf *config*
|
||||
(make-instance 'core:config))
|
||||
(setf *config* (make-instance 'core:config))
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue