^1682071145153
@
sname
ThingEditor
slabel
ThingEditor
sdescriptors
xworker.lang.MetaDescriptor3
sextends
xworker.swt.Commons
smany
true
seditCols
2
sformNoLabel
false
sinitialization
false
smodifier
public
sinheritDescription
false
sicon
icons/application_side_tree.png
Sdescription
#$@text#$@
<p>事物编辑器，如果在XWorker的事物管理器中事物编辑器使用事物管理器的编辑器，否则使用其它代替（目前用事物浏览代替）。</p>

<p><strong>保存的变量</strong></p>

<p>&nbsp;&nbsp;&nbsp; 默认保存到变量上下文的是编辑器的自己的变量上下文，如果saveActionContainer=true那么保存ActionContainer。</p>

<p><strong>主要变量</strong><br />
&nbsp;&nbsp;&nbsp; 保存的变量上下文中主要的变量有edtiorActions、thingContext(编辑事物的上下文）。</p>

<p><strong>设置和读取事物的方法</strong></p>

<p>&nbsp;&nbsp;&nbsp; 如果saveActionContainer=true，那么不需要&lt;editContext&gt;的前缀，直接xxx.doAction(&quot;xxx&quot;)。</p>

<ul>
	<li><strong>void setThing(Thing thing)</strong><br />
	设置要编辑的事物。<br />
	&nbsp;</li>
	<li><strong>Thing getThing()</strong><br />
	获取正在编辑的事物节点。<br />
	&nbsp;</li>
	<li><strong>Thing getRootThing()</strong><br />
	获取编辑的事物根节点（是编辑的根节点）。<br />
	&nbsp;</li>
	<li><strong>void save()</strong><br />
	保存。<br />
	&nbsp;</li>
	<li><strong>void selectThing(Thing thing)</strong><br />
	选择一个节点。<br />
	&nbsp;</li>
	<li><strong>void setVariablesActionContext(ActionContext variablesActionContext)</strong><br />
	设置代码编辑器辅助工具要显示变量类型时需要的变量上下文。<br />
	&nbsp;</li>
	<li><strong>boolean isModified()</strong><br />
	返回模型是否已经被修改了。</li>
</ul>

<p><strong>事件：</strong></p>

<ul>
	<li><strong>void onNodeSelected(Thing thing)</strong><br />
	编辑器选中了一个节点。<br />
	&nbsp;</li>
	<li><strong>void modify(boolean modified)</strong><br />
	编辑器修改的触发事件，modified=true表示已修改，modified=fasle表示无修改（保存后也是false）。</li>
</ul>

<p><strong>主要变量：</strong></p>

<ul>
	<li><strong>&lt;editorContext&gt;.mainComposite</strong><br />
	编辑器的面板。</li>
</ul>

<p><strong>可以重写的方法：</strong></p>

<ul>
	<li><strong>Object getThing()</strong><br />
	返回事物或事物的路径，默认使用UtilData用thingPath属性获取。<br />
	&nbsp;</li>
	<li><strong>ActionContext getVariablesActionContext()</strong><br />
	如果不为null，那么在事物编辑器中如果有代码编辑等，则会以此上下文作为代码辅助取变量的变量上下文。</li>
</ul>

<p><strong>设置概要栏的方法</strong></p>

<p>&nbsp;&nbsp;&nbsp;&nbsp; 可以参看<a href="javascript:invoke('thing:xworker.swt.ide.worldexplorer.swt.editor.ThingEditorShell/@mainSashForm/@outlinCompoisteParent/@outlineComposite')">ThingEditorShell</a>。</p>

<p>&nbsp;</p>
#$@text#$@
snotXmlAttribute
false
sjson_isArray
false
sjson_attribute
false
  @/@actions
  sname
  actions
  slabel
  actions
  sdescriptors
  xworker.lang.MetaDescriptor3/@actions
  sid
  actions
    @/@actions/@create
    sname
    create
    sisSynchronized
    false
    sthrowException
    true
    suseOtherAction
    false
    suseOuterJava
    true
    souterClassName
    xworker.swt.xworker.ThingEditorCreator
    smethodName
    create
    sdisableGlobalContext
    false
    sdescriptors
    xworker.lang.actions.JavaAction
    sid
    create
    @/@actions/@getThing
    sname
    getThing
    sattributeName
    thingPath
    sinterpretationType
    Self
    sattributeTemplate
    false
    schildsAttributeTemplate
    false
    svarScope
    Local
    sisSynchronized
    false
    sthrowException
    true
    suseOtherAction
    false
    screateLocalVarScope
    false
    ssaveReturn
    false
    sdisableGlobalContext
    false
    sdebugLog
    false
    sdescriptors
    xworker.lang.actions.ActionUtil/@GetData
    sinheritDescription
    false
    sth_createIndex
    false
    sth_registMyChilds
    false
    sth_registDisabled
    false
    sth_mark
    false
    sid
    getThing
    @/@actions/@isUseRootThing
    sname
    isUseRootThing
    sattributeName
    useRootThing
    sinterpretationType
    Self
    sattributeTemplate
    false
    schildsAttributeTemplate
    false
    svarScope
    Local
    sisSynchronized
    false
    sthrowException
    true
    suseOtherAction
    false
    screateLocalVarScope
    false
    ssaveReturn
    false
    sdisableGlobalContext
    false
    sdebugLog
    false
    sdescriptors
    xworker.lang.actions.ActionUtil/@GetBoolean
    sinheritDescription
    false
    sth_createIndex
    false
    sth_registMyChilds
    false
    sth_registDisabled
    false
    sth_mark
    false
    sid
    isUseRootThing
    @/@actions/@modify
    sname
    modify
    sunimplementedException
    false
    sdescriptors
    xworker.lang.actions.Actions/@NOOP
    sinterpretationType
    Self
    sattributeTemplate
    false
    schildsAttributeTemplate
    false
    svarScope
    Local
    sisSynchronized
    false
    sthrowException
    true
    suseOtherAction
    false
    screateLocalVarScope
    false
    ssaveReturn
    false
    sdisableGlobalContext
    false
    sdebugLog
    false
    sinheritDescription
    false
    sth_createIndex
    false
    sth_registMyChilds
    false
    sth_registDisabled
    false
    sth_mark
    false
    sid
    modify
    @/@actions/@getVariablesActionContext
    sname
    getVariablesActionContext
    sattributeName
    variablesActionContext
    sclassName
    org.xmeta.ActionContext
    snotNull
    false
    sinterpretationType
    Self
    sattributeTemplate
    false
    schildsAttributeTemplate
    false
    svarScope
    Local
    sisSynchronized
    false
    sthrowException
    true
    suseOtherAction
    false
    screateLocalVarScope
    false
    ssaveReturn
    false
    sdisableGlobalContext
    false
    sdebugLog
    false
    sdescriptors
    xworker.lang.actions.ActionUtil/@GetObjectByClass
    sinheritDescription
    false
    sth_createIndex
    false
    sth_registMyChilds
    false
    sth_registDisabled
    false
    sth_mark
    false
    sid
    getVariablesActionContext
  @/@VariablesDescs
  sname
  VariablesDescs
  sdescriptors
  xworker.lang.MetaThing/@VariablesDesc
  sinheritDescription
  false
  sth_createIndex
  false
  sth_registMyChilds
  false
  sth_registDisabled
  false
  sth_fileMonitor
  false
  sth_mark
  false
  sid
  VariablesDescs
    @/@VariablesDescs/@var
    sname
    var
    svarName
    _thingName_
    spassive
    false
    stype
    object
    sdescriptors
    xworker.lang.MetaThing/@VariablesDesc/@Object
    sinheritDescription
    false
    sth_createIndex
    false
    sth_registMyChilds
    false
    sth_registDisabled
    false
    sth_fileMonitor
    false
    sth_mark
    false
    sid
    var
      @/@VariablesDescs/@var/@actions
      sname
      actions
      sdescriptors
      xworker.lang.MetaThing/@VariablesDesc/@Object/@actions1
      sinheritDescription
      false
      sth_createIndex
      false
      sth_registMyChilds
      false
      sth_registDisabled
      false
      sth_fileMonitor
      false
      sth_mark
      false
      sid
      actions
        @/@VariablesDescs/@var/@actions/@getType
        sname
        getType
        sisSynchronized
        false
        sthrowException
        true
        suseOtherAction
        false
        svarScope
        Local
        sdisableGlobalContext
        false
        Scode
#$@text#$@
if(thing.getBoolean("saveActionContainer")){
    return "actionContainer";
}else{
    return "thing";
}
#$@text#$@
        sinterpretationType
        Action
        screateLocalVarScope
        false
        ssaveReturn
        false
        sdebugLog
        false
        sdescriptors
        xworker.lang.actions.Actions/@GroovyAction
        sinheritDescription
        false
        sth_createIndex
        false
        sth_registMyChilds
        false
        sth_registDisabled
        false
        sth_fileMonitor
        false
        sth_mark
        false
        sid
        getType
        @/@VariablesDescs/@var/@actions/@getThing
        sname
        getThing
        sisSynchronized
        false
        sthrowException
        true
        suseOtherAction
        false
        svarScope
        Local
        sdisableGlobalContext
        false
        Scode
#$@text#$@
if(thing.getBoolean("saveActionContainer")){
    return world.getThing("xworker.swt.ide.worldexplorer.ThingEditor/@shell/@mainComposite/@actions");
}else{
    return world.getThing("xworker.swt.xworker.ThingEditor");
}
#$@text#$@
        sinterpretationType
        Action
        screateLocalVarScope
        false
        ssaveReturn
        false
        sdebugLog
        false
        sdescriptors
        xworker.lang.actions.Actions/@GroovyAction
        sinheritDescription
        false
        sth_createIndex
        false
        sth_registMyChilds
        false
        sth_registDisabled
        false
        sth_fileMonitor
        false
        sth_mark
        false
        sid
        getThing
  @/@name
  sname
  name
  LvalidateOnBlur
  false
  LallowDecimals
  false
  LallowNegative
  false
  sdescriptors
  xworker.lang.MetaDescriptor3/@attribute
  sid
  name
  @/@label
  sname
  label
  LvalidateOnBlur
  false
  LallowDecimals
  false
  LallowNegative
  false
  sdescriptors
  xworker.lang.MetaDescriptor3/@attribute
  sid
  label
  @/@thingPath
  sname
  thingPath
  sinputtype
  dataSelector
  ssize
  60
  scolspan
  2
  sshowLabel
  true
  sreadOnly
  false
  sinheritDescription
  false
  svalidateAllowBlank
  true
  LvalidateOnBlur
  true
  LallowDecimals
  true
  LallowNegative
  true
  snotXmlAttribute
  false
  sdescriptors
  xworker.lang.MetaDescriptor3/@attribute
  sid
  thingPath
  @/@title
  sname
  title
  sinputtype
  truefalse
  sreadOnly
  false
  sdefault
  true
  sinheritDescription
  false
  svalidateAllowBlank
  true
  LvalidateOnBlur
  true
  LallowDecimals
  true
  LallowNegative
  true
  sdescriptors
  xworker.lang.MetaDescriptor3/@attribute
  sid
  title
  @/@useRootThing
  sname
  useRootThing
  stype
  string
  sinputtype
  truefalse
  sshowLabel
  true
  sreadOnly
  false
  sdefault
  false
  sinheritDescription
  false
  svalidateAllowBlank
  true
  LvalidateOnBlur
  true
  LallowDecimals
  true
  LallowNegative
  true
  snotXmlAttribute
  false
  sdescriptors
  xworker.lang.MetaDescriptor3/@attribute
  sth_createIndex
  false
  sth_registMyChilds
  false
  sth_registDisabled
  false
  sth_mark
  false
  sid
  useRootThing
  @/@saveActionContainer
  sname
  saveActionContainer
  sinputtype
  truefalse
  sshowLabel
  true
  sreadOnly
  false
  sdefault
  false
  sinheritDescription
  false
  svalidateAllowBlank
  true
  LvalidateOnBlur
  true
  LallowDecimals
  true
  LallowNegative
  true
  snotXmlAttribute
  false
  sdescriptors
  xworker.lang.MetaDescriptor3/@attribute
  sth_createIndex
  false
  sth_registMyChilds
  false
  sth_registDisabled
  false
  sth_mark
  false
  sid
  saveActionContainer
  @/@variablesActionContext
  sname
  variablesActionContext
  ssize
  60
  sshowLabel
  true
  sreadOnly
  false
  sinheritDescription
  false
  svalidateAllowBlank
  true
  LvalidateOnBlur
  true
  LallowDecimals
  true
  LallowNegative
  true
  snotXmlAttribute
  false
  sdescriptors
  xworker.lang.MetaDescriptor3/@attribute
  sth_createIndex
  false
  sth_registMyChilds
  false
  sth_registDisabled
  false
  sth_mark
  false
  sid
  variablesActionContext
  @/@description
  sname
  description
  sinputtype
  html
  sshowLabel
  true
  sreadOnly
  false
  sinheritDescription
  false
  svalidateAllowBlank
  true
  LvalidateOnBlur
  true
  LallowDecimals
  true
  LallowNegative
  true
  snotXmlAttribute
  false
  sdescriptors
  xworker.lang.MetaDescriptor3/@attribute
  sth_createIndex
  false
  sth_registMyChilds
  false
  sth_registDisabled
  false
  sth_mark
  false
  sid
  description
  @/@actions1
  sname
  actions
  slabel
  Actions
  sdescriptors
  xworker.lang.MetaDescriptor2/@thing
  sextends
  xworker.lang.actions.Actions
  smany
  true
  seditCols
  2
  Sdescription
#$@text#$@
<p><strong>动作集合</strong></p>

<p>&nbsp;&nbsp;&nbsp; 通过动作可以定义事物的行为，事物的行为即动作，可以用多种语言和方式编写。</p>

<p><strong>self变量</strong></p>

<p>&nbsp;&nbsp;&nbsp; 当一个动作作为一个事物的行为执行时，会把该事物以self变量传给动作。</p>

<p><strong>第一个动作集合生效</strong></p>

<p>&nbsp;&nbsp;&nbsp; 只有事物的第一个actions子节点才被认为是行为的定义集合，第二个及以后不算。</p>
#$@text#$@
  szh_label
  动作
  sinheritDescription
  false
  sth_createIndex
  false
  sth_registMyChilds
  false
  sth_registDisabled
  false
  Sen_description
#$@text#$@
<p><strong>Actions</strong></p>

<p>&nbsp;&nbsp;&nbsp; Use actions can define behaviors of the&nbsp;thing. Behavior is action, can be defined by many program languages or other things.</p>

<p><strong>Variable self</strong></p>

<p>&nbsp;&nbsp;&nbsp; When a action is executed as a behavior, in the actionContext will have a virable named &#39;self&#39;, self like this in java, self is it&#39;s onwer thing.</p>

<p><strong>First actions is validate</strong></p>

<p>&nbsp;&nbsp;&nbsp; Only first actions node is behaviros collections.</p>
#$@text#$@
  sth_mark
  false
  sid
  actions1
    @/@actions1/@name
    sname
    name
    sdescriptors
    xworker.lang.MetaDescriptor2/@attribute
    sid
    name
