Smalltalk 海边-什么';“当直接调用”时,在WA组件中实现“children”的要点是什么;html呈现:";是用“中国制造”的;renderContentOn:html“是吗?”;?

Smalltalk 海边-什么';“当直接调用”时,在WA组件中实现“children”的要点是什么;html呈现:";是用“中国制造”的;renderContentOn:html“是吗?”;?,smalltalk,pharo,seaside,Smalltalk,Pharo,Seaside,在代码的后面,可能会有这样的内容 Whatever >> children ^Array with: oneComponent with: anotherComponent. 既然我显式地调用来呈现这些组件,那么在#children中使用它们又有什么用呢?#children是否用于其他用途?Seaside取决于以下回调是否正确实现了#children: #updateRoot:自定义生成的HTML文档的标题部分 #initialRequest:要在会话开始时初始化

在代码的后面,可能会有这样的内容

Whatever >> children
        ^Array with: oneComponent with: anotherComponent.
既然我显式地调用来呈现这些组件,那么在#children中使用它们又有什么用呢?#children是否用于其他用途?

Seaside取决于以下回调是否正确实现了
#children

  • #updateRoot:
    自定义生成的HTML文档的标题部分
  • #initialRequest:
    要在会话开始时初始化组件
  • #updateUrl:
    要修改当前URL
  • #updateEstates:
    注册对象进行回溯
  • 以及支持助手方法,如
    #states
    #scripts
    、和
    #style

搜索这些方法以了解更多信息。

Lukas非常熟悉需要
#children
的功能(但也应提及嵌入式
WATask
对象)。如果您对实现的更多细节感兴趣,我会在几个月前回答seaside邮件列表上的一个问题时告诉您这一点。@Julian我现在才看到您的评论。有趣!我已经将你添加到我的“关注”博客列表中。
Whatever >> renderContentOn: html
        ...
        html render: oneComponent.
        ...
        html render: anotherComponent.