<?xml version='1.0' encoding='ISO-8859-1' standalone='no'?>
<!DOCTYPE interface-description SYSTEM 'file:///usr/pkgsrc/lang/oo2c/work.macaroon/oo2c_32-2.0.11/rsrc/OOC/xml/interface-description.dtd'>
<interface-description name='IO:Buffer' id=''>
  <import-decl name='SYSTEM' id='SYSTEM' export='no' module='SYSTEM'/>
  <import-decl name='Ascii' id='Ascii' export='no' module='Ascii'/>
  <import-decl name='Object' id='Object' export='no' module='Object'/>
  <import-decl name='IO' id='IO' export='no' module='IO'/>
  <import-decl name='-RT0' id='-RT0' export='no' module='RT0'/>
  <import-decl name='-Object' id='-Object' export='no' module='Object'/>
  <import-decl name='-Exception' id='-Exception' export='no' module='Exception'/>
  <class name='Channel'>
    <type-decl name='Channel' id='Channel' export='yes'>
      <type>
        <pointer>
          <pointer-base>
            <type-name name='ChannelDesc' href='#ChannelDesc'/>
          </pointer-base>
        </pointer>
      </type>
    </type-decl>
    <type-decl name='ChannelDesc' id='ChannelDesc' export='no'>
      <type>
        <record>
          <field-decl name='base' id='ChannelDesc.base' export='read-only'>
            <type>
              <type-name module='IO' name='ByteChannel' href='IO#ByteChannel'/>
            </type>
          </field-decl>
        </record>
      </type>
    </type-decl>
    <procedure name='Open' id='Open' export='yes'>
      <formal-parameters>
        <parameter-decl name='base' id='Open.base' export='no' variable-parameter='no'>
          <type>
            <type-name module='IO' name='ByteChannel' href='IO#ByteChannel'/>
          </type>
        </parameter-decl>
        <result-type>
          <type-name name='Channel' href='#Channel'/>
        </result-type>
      </formal-parameters>
    </procedure>
    <procedure name='Flush' id='ChannelDesc.Flush' export='yes'>
      <doc-inherited-from module='IO' name='Flush' class='ByteChannel' href='IO#ByteChannelDesc.Flush'/>
      <oberon-doc>
        <summary>Flush all buffers associated with channel <oberon-param href='#ChannelDesc.Flush.ch'>ch</oberon-param>.</summary>
        <p pad-after='yes' no-indent='yes'>Flush all buffers associated with channel <oberon-param href='#ChannelDesc.Flush.ch'>ch</oberon-param>.</p>
      </oberon-doc>
      <formal-parameters>
        <receiver-decl name='ch' id='ChannelDesc.Flush.ch' export='no' variable-parameter='no'>
          <type>
            <type-name name='Channel' href='#Channel'/>
          </type>
        </receiver-decl>
        <exceptions>
          <type-name module='IO' name='Error' href='IO#Error'/>
        </exceptions>
      </formal-parameters>
      <redefined-method module='IO' name='Flush' class='ByteChannel' href='IO#ByteChannelDesc.Flush'/>
    </procedure>
    <procedure name='SetPos' id='ChannelDesc.SetPos' export='yes'>
      <doc-inherited-from module='IO' name='SetPos' class='Channel' href='IO#ChannelDesc.SetPos'/>
      <oberon-doc>
        <summary>Change the channels position to <oberon-param href='#ChannelDesc.SetPos.pos'>pos</oberon-param>.</summary>
        <p pad-after='yes' no-indent='yes'>Change the channels position to <oberon-param href='#ChannelDesc.SetPos.pos'>pos</oberon-param>.</p>
      </oberon-doc>
      <formal-parameters>
        <receiver-decl name='ch' id='ChannelDesc.SetPos.ch' export='no' variable-parameter='no'>
          <type>
            <type-name name='Channel' href='#Channel'/>
          </type>
        </receiver-decl>
        <parameter-decl name='pos' id='ChannelDesc.SetPos.pos' export='no' variable-parameter='no'>
          <type>
            <type-name module='#predef' name='LONGINT'/>
          </type>
        </parameter-decl>
        <exceptions>
          <type-name module='IO' name='Error' href='IO#Error'/>
        </exceptions>
      </formal-parameters>
      <redefined-method module='IO' name='SetPos' class='Channel' href='IO#ChannelDesc.SetPos'/>
      <redefined-method module='IO' name='SetPos' class='Channel' href='IO#ChannelDesc.SetPos'/>
    </procedure>
    <procedure name='Read' id='ChannelDesc.Read' export='yes'>
      <doc-inherited-from module='IO' name='Read' class='ByteChannel' href='IO#ByteChannelDesc.Read'/>
      <oberon-doc>
        <summary>Read a sequence of bytes from the channel into the buffer.</summary>
        <p pad-after='yes' no-indent='yes'>Read a sequence of bytes from the channel into the buffer.</p>
        <p pad-after='yes' no-indent='no'>An attempt is made to read up to <oberon-param href='#ChannelDesc.Read.length'>length</oberon-param> bytes from the channel.  The bytes are written to <oberon-param href='#ChannelDesc.Read.buffer'>buffer</oberon-param>, starting at position <oberon-param href='#ChannelDesc.Read.start'>start</oberon-param>.  Result is the number of bytes actually read, or <samp>-1</samp> if the read position is at the end of the channel, and <oberon-param href='#ChannelDesc.Read.length'>length</oberon-param> is not zero.</p>
        <p pad-after='yes' no-indent='no'>A read operation might not read <oberon-param href='#ChannelDesc.Read.length'>length</oberon-param> bytes, and in fact it might not read any bytes at all.  Whether or not it does so depends upon the nature and state of the channel.  A socket channel in non-blocking mode, for example, cannot read any more bytes than are immediately available from the socket's input buffer; similarly, a file channel cannot read any more bytes than remain in the file.  It is guaranteed, however, that if a channel is in blocking mode and there is at least one byte remaining in the buffer then this method will block until at least one byte is read.</p>
        <pre-cond pad-after='yes'>
          <p pad-after='no' no-indent='yes'><samp>0 &lt;= <oberon-param href='#ChannelDesc.Read.start'>start</oberon-param> &lt;= <oberon-param href='#ChannelDesc.Read.start'>start</oberon-param>+<oberon-param href='#ChannelDesc.Read.length'>length</oberon-param> &lt;= LEN(<oberon-param href='#ChannelDesc.Read.buffer'>buffer</oberon-param>)</samp> and <samp><oberon-param href='#ChannelDesc.Read.length'>length</oberon-param> &gt;= 0</samp>.</p>
        </pre-cond>
      </oberon-doc>
      <formal-parameters>
        <receiver-decl name='ch' id='ChannelDesc.Read.ch' export='no' variable-parameter='no'>
          <type>
            <type-name name='Channel' href='#Channel'/>
          </type>
        </receiver-decl>
        <parameter-decl name='buffer' id='ChannelDesc.Read.buffer' export='no' variable-parameter='yes'>
          <type>
            <array>
              <element-type>
                <type-name module='SYSTEM' name='BYTE' href='SYSTEM#BYTE'/>
              </element-type>
            </array>
          </type>
        </parameter-decl>
        <parameter-decl name='start' id='ChannelDesc.Read.start' export='no' variable-parameter='no'>
          <type>
            <type-name module='#predef' name='LONGINT'/>
          </type>
        </parameter-decl>
        <parameter-decl name='length' id='ChannelDesc.Read.length' export='no' variable-parameter='no'>
          <type>
            <type-name module='#predef' name='LONGINT'/>
          </type>
        </parameter-decl>
        <result-type>
          <type-name module='#predef' name='LONGINT'/>
        </result-type>
        <exceptions>
          <type-name module='IO' name='Error' href='IO#Error'/>
        </exceptions>
      </formal-parameters>
      <redefined-method module='IO' name='Read' class='ByteChannel' href='IO#ByteChannelDesc.Read'/>
    </procedure>
    <procedure name='ReadLineLF' id='ChannelDesc.ReadLineLF' export='yes'>
      <oberon-doc>
        <summary>Read one entire line from the channel.</summary>
        <p pad-after='yes' no-indent='yes'>Read one entire line from the channel.  The line after the first line-feed character (<oberon-const href='Ascii#lf'>Ascii.lf</oberon-const>; that is, a trailing line-feed is kept in the string.  If the channel ends with an incomplete line, then the line-feed character is absent from the last line.  <code>NIL</code> is returned after the last line of the channel has been read.</p>
        <p pad-after='yes' no-indent='no'>Note: The returned string contains null characters (<samp>0X</samp>) if they occurred in the input.</p>
      </oberon-doc>
      <formal-parameters>
        <receiver-decl name='ch' id='ChannelDesc.ReadLineLF.ch' export='no' variable-parameter='no'>
          <type>
            <type-name name='Channel' href='#Channel'/>
          </type>
        </receiver-decl>
        <result-type>
          <type-name module='Object' name='String8' href='Object#String8'/>
        </result-type>
        <exceptions>
          <type-name module='IO' name='Error' href='IO#Error'/>
        </exceptions>
      </formal-parameters>
    </procedure>
    <procedure name='Write' id='ChannelDesc.Write' export='yes'>
      <doc-inherited-from module='IO' name='Write' class='ByteChannel' href='IO#ByteChannelDesc.Write'/>
      <oberon-doc>
        <summary>Write a sequence of bytes to this channel from the buffer.</summary>
        <p pad-after='yes' no-indent='yes'>Write a sequence of bytes to this channel from the buffer.</p>
        <p pad-after='yes' no-indent='no'>An attempt is made to write up to <oberon-param href='#ChannelDesc.Write.length'>length</oberon-param> bytes to the channel.  The bytes are taken from <oberon-param href='#ChannelDesc.Write.buffer'>buffer</oberon-param>, beginning at position <oberon-param href='#ChannelDesc.Write.start'>start</oberon-param>.</p>
        <p pad-after='yes' no-indent='no'>A write operation can return after writing less than <oberon-param href='#ChannelDesc.Write.length'>length</oberon-param> bytes.  That is, some types of channels, depending upon their state, may write only some of the bytes or possibly none at all.  A socket channel in non-blocking mode, for example, cannot write any more bytes than are free in the socket's output buffer.  Result is the number of bytes actually written.</p>
        <pre-cond pad-after='yes'>
          <p pad-after='no' no-indent='yes'><samp>0 &lt;= <oberon-param href='#ChannelDesc.Write.start'>start</oberon-param> &lt;= <oberon-param href='#ChannelDesc.Write.start'>start</oberon-param>+<oberon-param href='#ChannelDesc.Write.length'>length</oberon-param> &lt;= LEN(<oberon-param href='#ChannelDesc.Write.buffer'>buffer</oberon-param>)</samp> and <samp><oberon-param href='#ChannelDesc.Write.length'>length</oberon-param> &gt;= 0</samp>.</p>
        </pre-cond>
      </oberon-doc>
      <formal-parameters>
        <receiver-decl name='ch' id='ChannelDesc.Write.ch' export='no' variable-parameter='no'>
          <type>
            <type-name name='Channel' href='#Channel'/>
          </type>
        </receiver-decl>
        <parameter-decl name='buffer' id='ChannelDesc.Write.buffer' export='no' variable-parameter='no'>
          <type>
            <array>
              <element-type>
                <type-name module='SYSTEM' name='BYTE' href='SYSTEM#BYTE'/>
              </element-type>
            </array>
          </type>
        </parameter-decl>
        <parameter-decl name='start' id='ChannelDesc.Write.start' export='no' variable-parameter='no'>
          <type>
            <type-name module='#predef' name='LONGINT'/>
          </type>
        </parameter-decl>
        <parameter-decl name='length' id='ChannelDesc.Write.length' export='no' variable-parameter='no'>
          <type>
            <type-name module='#predef' name='LONGINT'/>
          </type>
        </parameter-decl>
        <result-type>
          <type-name module='#predef' name='LONGINT'/>
        </result-type>
        <exceptions>
          <type-name module='IO' name='Error' href='IO#Error'/>
        </exceptions>
      </formal-parameters>
      <redefined-method module='IO' name='Write' class='ByteChannel' href='IO#ByteChannelDesc.Write'/>
    </procedure>
    <procedure name='SetBlocking' id='ChannelDesc.SetBlocking' export='yes'>
      <doc-inherited-from module='IO' name='SetBlocking' class='Channel' href='IO#ChannelDesc.SetBlocking'/>
      <oberon-doc>
        <summary>Change the channel's blocking mode.</summary>
        <p pad-after='yes' no-indent='yes'>Change the channel's blocking mode.  Channels typically default to blocking mode on creation.</p>
        <p pad-after='yes' no-indent='no'>If a channel does not support non-blocking operation, then any call to this method is ignored.  Rider implementations from <oberon-module href='IO:BinaryRider#'>IO:BinaryRider</oberon-module> and <oberon-module href='IO:TextRider#'>IO:TextRider</oberon-module> only work with blocking channels.</p>
      </oberon-doc>
      <formal-parameters>
        <receiver-decl name='ch' id='ChannelDesc.SetBlocking.ch' export='no' variable-parameter='no'>
          <type>
            <type-name name='Channel' href='#Channel'/>
          </type>
        </receiver-decl>
        <parameter-decl name='block' id='ChannelDesc.SetBlocking.block' export='no' variable-parameter='no'>
          <type>
            <type-name module='#predef' name='BOOLEAN'/>
          </type>
        </parameter-decl>
        <exceptions>
          <type-name module='IO' name='Error' href='IO#Error'/>
        </exceptions>
      </formal-parameters>
      <redefined-method module='IO' name='SetBlocking' class='Channel' href='IO#ChannelDesc.SetBlocking'/>
      <redefined-method module='IO' name='SetBlocking' class='Channel' href='IO#ChannelDesc.SetBlocking'/>
    </procedure>
    <procedure name='FileDescriptor' id='ChannelDesc.FileDescriptor' export='yes'>
      <doc-inherited-from module='IO' name='FileDescriptor' class='Channel' href='IO#ChannelDesc.FileDescriptor'/>
      <oberon-doc>
        <summary>Return the file descriptor of the channel.</summary>
        <p pad-after='yes' no-indent='yes'>Return the file descriptor of the channel.  This is the integer number that is used to identify the channel on the level of the C library.  If the channel is not associated with a file descriptor, result is <samp>-1</samp>.</p>
      </oberon-doc>
      <formal-parameters>
        <receiver-decl name='ch' id='ChannelDesc.FileDescriptor.ch' export='no' variable-parameter='no'>
          <type>
            <type-name name='Channel' href='#Channel'/>
          </type>
        </receiver-decl>
        <result-type>
          <type-name module='IO' name='FileDescriptor' href='IO#FileDescriptor'/>
        </result-type>
      </formal-parameters>
      <redefined-method module='IO' name='FileDescriptor' class='Channel' href='IO#ChannelDesc.FileDescriptor'/>
      <redefined-method module='IO' name='FileDescriptor' class='Channel' href='IO#ChannelDesc.FileDescriptor'/>
    </procedure>
    <procedure name='Close' id='ChannelDesc.Close' export='yes'>
      <doc-inherited-from module='IO' name='Close' class='Channel' href='IO#ChannelDesc.Close'/>
      <oberon-doc>
        <summary>Cancel all selection keys registered for the channel <oberon-param href='#ChannelDesc.Close.ch'>ch</oberon-param> and close the channel.</summary>
        <p pad-after='yes' no-indent='yes'>Cancel all selection keys registered for the channel <oberon-param href='#ChannelDesc.Close.ch'>ch</oberon-param> and close the channel.</p>
      </oberon-doc>
      <formal-parameters>
        <receiver-decl name='ch' id='ChannelDesc.Close.ch' export='no' variable-parameter='no'>
          <type>
            <type-name name='Channel' href='#Channel'/>
          </type>
        </receiver-decl>
        <exceptions>
          <type-name module='IO' name='Error' href='IO#Error'/>
        </exceptions>
      </formal-parameters>
      <redefined-method module='IO' name='Close' class='Channel' href='IO#ChannelDesc.Close'/>
      <redefined-method module='IO' name='Close' class='Channel' href='IO#ChannelDesc.Close'/>
    </procedure>
    <procedure name='CloseAndRegister' id='ChannelDesc.CloseAndRegister' export='yes'>
      <doc-inherited-from module='IO' name='CloseAndRegister' class='Channel' href='IO#ChannelDesc.CloseAndRegister'/>
      <oberon-doc>
        <summary>Like <oberon-proc href='IO#ChannelDesc.Close'>Channel.Close</oberon-proc>, but register the channel's target with its naming service once done.</summary>
        <p pad-after='yes' no-indent='yes'>Like <oberon-proc href='IO#ChannelDesc.Close'>Channel.Close</oberon-proc>, but register the channel's target with its naming service once done.  Right now, only <oberon-module href='IO:FileChannel#'>IO:FileChannel</oberon-module> supports this feature; see <oberon-const href='IO:FileChannel#tmpFile'>IO:FileChannel.tmpFile</oberon-const> for details.  By default, this method simply calls <oberon-proc href='IO#ChannelDesc.Close'>Channel.Close</oberon-proc>.</p>
      </oberon-doc>
      <formal-parameters>
        <receiver-decl name='ch' id='ChannelDesc.CloseAndRegister.ch' export='no' variable-parameter='no'>
          <type>
            <type-name name='Channel' href='#Channel'/>
          </type>
        </receiver-decl>
        <exceptions>
          <type-name module='IO' name='Error' href='IO#Error'/>
        </exceptions>
      </formal-parameters>
      <redefined-method module='IO' name='CloseAndRegister' class='Channel' href='IO#ChannelDesc.CloseAndRegister'/>
      <redefined-method module='IO' name='CloseAndRegister' class='Channel' href='IO#ChannelDesc.CloseAndRegister'/>
    </procedure>
    <base-class module='IO' class='ByteChannel' href='IO#ByteChannel'>
      <inherited-method module='IO' name='Flush' class='ByteChannel' href='IO#ByteChannelDesc.Flush'/>
      <inherited-method module='IO' name='Read' class='ByteChannel' href='IO#ByteChannelDesc.Read'/>
      <inherited-method module='IO' name='TransferTo' class='ByteChannel' href='IO#ByteChannelDesc.TransferTo'/>
      <inherited-method module='IO' name='Write' class='ByteChannel' href='IO#ByteChannelDesc.Write'/>
      <base-class module='IO' class='Channel' href='IO#Channel'>
        <inherited-method module='IO' name='Close' class='Channel' href='IO#ChannelDesc.Close'/>
        <inherited-method module='IO' name='CloseAndRegister' class='Channel' href='IO#ChannelDesc.CloseAndRegister'/>
        <inherited-method module='IO' name='FileDescriptor' class='Channel' href='IO#ChannelDesc.FileDescriptor'/>
        <inherited-method module='IO' name='KeyForSelector' class='Channel' href='IO#ChannelDesc.KeyForSelector'/>
        <inherited-method module='IO' name='RegisterWithSelector' class='Channel' href='IO#ChannelDesc.RegisterWithSelector'/>
        <inherited-method module='IO' name='SetBlocking' class='Channel' href='IO#ChannelDesc.SetBlocking'/>
        <inherited-method module='IO' name='SetPos' class='Channel' href='IO#ChannelDesc.SetPos'/>
        <inherited-field module='IO' name='readyOps' class='Channel' href='IO#ChannelDesc.readyOps'/>
      </base-class>
    </base-class>
  </class>
  <module-ref name='Ascii'>
    <ref-target type='html' relative-uri='../Ascii.html'/>
  </module-ref>
  <module-ref name='IO:FileChannel'>
    <ref-target type='html' relative-uri='FileChannel.html'/>
  </module-ref>
  <module-ref name='IO'>
    <ref-target type='html' relative-uri='../IO.html'/>
  </module-ref>
  <module-ref name='IO:BinaryRider'>
    <ref-target type='html' relative-uri='BinaryRider.html'/>
  </module-ref>
  <module-ref name='Object'>
    <ref-target type='html' relative-uri='../Object.html'/>
  </module-ref>
  <module-ref name='IO:TextRider'>
    <ref-target type='html' relative-uri='TextRider.html'/>
  </module-ref>
</interface-description>
