```java.lang.ClassCastException: tornadofx.Scope c...
# tornadofx
a
Copy code
java.lang.ClassCastException: tornadofx.Scope cannot be cast to knote.tornadofx.model.NotebookScope
	at knote.tornadofx.view.NotebookSpace.<init>
c
How is NotebookScope defined? If it is
NotebookScope: Scope
then you're trying to cast parent to child, which can't work, as child is more specific and there are no garantees that parent will satisfy child spec. With casting you can only lower specificity, casting from child to parent, not the other way around.
👍 1
o
So you might want to call on you version of the scope
super.scope as NotebookScope
to
super.notebookScope as NotebookScope
?
a
ahhhhh you know what - I may have notebook scope defined wrong
thanks for the call out guys, I appreciate it
🙂 1