<?xml version="1.0" encoding="Windows-1255" ?><Interface name="KitChannels" alias="$ENV" id="core.env:KitChannels" sort="23" urn="core.env:extensions.KitChannels.js" toc="\Extension Points"><Summary>Extension point for defining kit channels.</Summary><Copyright>(c) SAP AG 2003-2006. All rights reserved.</Copyright>
<Topics>
<Property name="channel1" type="GkbChannel!" access="RO" typeRef="&lt;q ref=&quot;core.env:GkbChannel&quot;&gt;GkbChannel&lt;/q&gt;" sortGroup="true" scope="public" id="core.env:KitChannels!channel1" sort="34" group="Properties" seq="0000"><Summary>The primary Visual Composer channel through which the current model is read and written.</Summary></Property>
<Property name="channel2" type="GkbChannel!" access="RO" typeRef="&lt;q ref=&quot;core.env:GkbChannel&quot;&gt;GkbChannel&lt;/q&gt;" sortGroup="true" scope="public" id="core.env:KitChannels!channel2" sort="34" group="Properties" seq="0001"><Summary>The secondary Visual Composer channel through which services outside of the current model scope are invoked.</Summary></Property>
<Method name="defineChannel" sortGroup="true" scope="public" id="core.env:KitChannels!defineChannel" sort="35" group="Methods" seq="0002"><Summary>Defines a new channel.</Summary><Parameters signature="method:: &lt;i&gt;$ENV&lt;/i&gt;.&lt;b&gt;defineChannel&lt;/b&gt;(&lt;i&gt;className&lt;/i&gt;, &lt;i&gt;args...&lt;/i&gt;) &amp;rarr; &lt;q ref=&quot;core.env:BaseChannel&quot;&gt;BaseChannel&lt;/q&gt;"><Param name="className" type="String">The name of the channel implementation class (must be a class inherited from &lt;q ref=&quot;core.env:BaseChannel&quot;&gt;BaseChannel&lt;/q&gt;).</Param><Param name="args..." type="Arguments">A variable list of arguments to pass to the channel class constructor.</Param></Parameters><Return type="BaseChannel!" typeRef="&lt;q ref=&quot;core.env:BaseChannel&quot;&gt;BaseChannel&lt;/q&gt;">The newly defined channel, or &lt;code&gt;null&lt;/code&gt; in case of any error.</Return><Remarks>The channel object must have an &lt;code&gt;id&lt;/code&gt; property (either declared as a property in the class, or initialized by the Arguments collection)
    - the &lt;code&gt;id&lt;/code&gt; must be prefixed with namespace e.g. com.sap.mypackage:id
   &lt;h2&gt;Xml definition of a channel in a configuration file&lt;/h2&gt;
   &lt;pre&gt;
   &amp;lt;CONFIGURE type=&amp;quot;CHANNELS&amp;quot;&amp;gt;
   ?  &amp;lt;HEADER&amp;gt;
   ?     &amp;lt;PRAGMA&amp;gt;# Pragmas section&amp;lt;/PRAGMA&amp;gt;
   ?     &amp;lt;SCRIPT&amp;gt;# Code section. Place here functions\variables
                   which you want to address from within the channel tags
         &amp;lt;/SCRIPT&amp;gt;
      &amp;lt;/HEADER&amp;gt;
      &amp;lt;CHANNELS&amp;gt;
   +     &amp;lt;CHANNEL&amp;gt;
           &amp;lt;PROPERTIES&amp;gt;
              &amp;lt;classname&amp;gt;# The name of the channel implementation class
              &amp;lt;/classname&amp;gt;
           &amp;lt;/PROPERTIES&amp;gt;
            &amp;lt;ARGS&amp;gt;
   *          &amp;lt;arg&amp;gt;# An argument to pass to the channel class constructor.
                     (1) The argument can be defined in the script section,
                         and used here (see example).
                     (2) If the argument is of type string, add type=string
                         to the arg tag (see example).
                     (3) The order of the args should match the
                         order of the arguments in the channel constructor
              &amp;lt;/arg&amp;gt;
            &amp;lt;/ARGS&amp;gt;
         &amp;lt;/CHANNEL&amp;gt;
      &amp;lt;/CHANNELS&amp;gt;
   &amp;lt;/CONFIGURE&amp;gt;
   &lt;/pre&gt;
   &lt;h2&gt;Example&lt;/h2&gt;
   &lt;pre&gt;
   &amp;lt;CONFIGURE type=&amp;quot;CHANNELS&amp;quot;&amp;gt;
      &amp;lt;HEADER&amp;gt;
         &amp;lt;SCRIPT&amp;gt;var array = new Array(2);
                 array[0]=&amp;quot;elem1&amp;quot;;
                 array[1]=&amp;quot;elem2&amp;quot;;
         &amp;lt;/SCRIPT&amp;gt;
      &amp;lt;/HEADER&amp;gt;
      &amp;lt;CHANNELS&amp;gt;
         &amp;lt;CHANNEL&amp;gt;
            &amp;lt;PROPERTIES&amp;gt;
               &amp;lt;classname&amp;gt;core.env:myChannelClass&amp;lt;/classname&amp;gt;
            &amp;lt;/PROPERTIES&amp;gt;
            &amp;lt;ARGS&amp;gt;
               &amp;lt;arg type=&amp;quot;string&amp;quot;&amp;gt;myChannel&amp;lt;/arg&amp;gt;
               &amp;lt;arg&amp;gt;[elem1, elem2, elem3]&amp;lt;/arg&amp;gt;
               &amp;lt;arg&amp;gt;array&amp;lt;/arg&amp;gt;
            &amp;lt;/ARGS&amp;gt;
         &amp;lt;/CHANNEL&amp;gt;
      &amp;lt;/CHANNELS&amp;gt;
   &amp;lt;/CONFIGURE&amp;gt;
   &lt;/pre&gt;</Remarks></Method>
<Method name="getChannel" sortGroup="true" scope="public" id="core.env:KitChannels!getChannel" sort="35" group="Methods" seq="0003"><Summary>Returns a specified channel.</Summary><Parameters signature="method:: &lt;i&gt;$ENV&lt;/i&gt;.&lt;b&gt;getChannel&lt;/b&gt;(&lt;i&gt;id&lt;/i&gt;) &amp;rarr; &lt;q ref=&quot;core.env:BaseChannel&quot;&gt;BaseChannel&lt;/q&gt;"><Param name="id" type="QName">The channel id.</Param></Parameters><Return type="BaseChannel!" typeRef="&lt;q ref=&quot;core.env:BaseChannel&quot;&gt;BaseChannel&lt;/q&gt;">The requested channel object.</Return></Method>
<Method name="getChannelsTable" sortGroup="true" scope="public" id="core.env:KitChannels!getChannelsTable" sort="35" group="Methods" seq="0004"><Summary>Returns the complete channels table.</Summary><Parameters signature="method:: &lt;i&gt;$ENV&lt;/i&gt;.&lt;b&gt;getChannelsTable&lt;/b&gt;() &amp;rarr; &lt;q ref=&quot;core.env:BaseChannel&quot;&gt;BaseChannel&lt;/q&gt;[id]"></Parameters><Return type="BaseChannel![id]" typeRef="&lt;q ref=&quot;core.env:BaseChannel&quot;&gt;BaseChannel&lt;/q&gt;[id]">Table of channel objects, indexed by channel id.</Return><Remarks>Channel id's are stored in uppercase. Use &lt;q ref=&quot;core.lib:Basic!UPPER&quot;&gt;UPPER&lt;/q&gt; macro to convert the channel name to uppercase
before using it as the index in this table.</Remarks></Method>
<Method name="removeChannel" sortGroup="true" scope="public" id="core.env:KitChannels!removeChannel" sort="35" group="Methods" seq="0005"><Summary>Removes a specified channel.</Summary><Parameters signature="method:: &lt;i&gt;$ENV&lt;/i&gt;.&lt;b&gt;removeChannel&lt;/b&gt;(&lt;i&gt;id&lt;/i&gt;) &amp;rarr; void"><Param name="id" type="QName">The id of the channel to remove.</Param></Parameters><Return></Return></Method>
<Event name="onChannelConnect" sortGroup="true" scope="public" id="core.env:KitChannels!onChannelConnect" sort="36" group="Events" seq="0006"><Summary>Fires whenever a channel is connected/disconnected.</Summary><Parameters signature="event:: &lt;b&gt;onChannelConnect&lt;/b&gt; &amp;rarr; {&lt;i&gt;channel&lt;/i&gt;, &lt;i&gt;online&lt;/i&gt;}"><Param name="channel" type="String">The channel Id.</Param><Param name="online" type="Boolean">The new channel status.</Param></Parameters></Event>
</Topics>
</Interface>