我收到此错误:
[OBJRTBLD2] 现有类的任何对象都不能满足 is-a 对象模式的限制。
当我运行以下规则时:
(defrule update_input "Updateinput1"
(object (is-a Shmeio)
(timh ?eis1)
(onoma "Eisodos 1"))
=>
(printout t "htane: " ?eis1))
我的代码如下:
(defclass Shmeio
(is-a USER)
(role abstract)
(single-slot timh
(type INTEGER)
;+ (cardinality 1 1)
(create-accessor read-write))
(single-slot onoma
(type STRING)
;+ (cardinality 1 1)
(create-accessor read-write))
(multislot input_at
(type INSTANCE)
(allowed-classes Eksartima)
(create-accessor read-write)))
(defclass Shmeio_Eisodou
(is-a Shmeio)
(role concrete))
(definstances facts
; ...............
([Kuklomata_Class10] of Shmeio_Eisodou
(input_at [Kuklomata_Class74])
(onoma "Eisodos 1")
(timh 21))
([Kuklomata_Class36] of Shmeio_Eisodou
(input_at [Kuklomata_Class76])
(onoma "Eisodos 2")
(timh 28))
([Kuklomata_Class45] of Shmeio_Eisodou
(input_at [Kuklomata_Class77])
(onoma "Eisodos 3")
(timh 13))
([Kuklomata_Class54] of Shmeio_Eisodou
(input_at [Kuklomata_Class77])
(onoma "Eisodos 4")
(timh 25))
有人可以帮我吗?因为我现在被困了几个小时。