<?xml version="1.0" encoding="utf-8" ?>
<!DOCTYPE erlref SYSTEM "erlref.dtd">

<erlref>
  <header>
    <copyright>
      <year>1997</year>
      <year>2016</year>
      <holder>Ericsson AB, All Rights Reserved</holder>
    </copyright>
    <legalnotice>
  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at
 
      http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.

  The Initial Developer of the Original Code is Ericsson AB.
    </legalnotice>

    <title>CosNaming_BindingIterator</title>
    <prepared></prepared>
    <docno></docno>
    <checked></checked>
    <date>1997-06-10</date>
    <rev>A</rev>
  </header>
  <module>CosNaming_BindingIterator</module>
  <modulesummary>This interface supports iteration over a name binding list.</modulesummary>
  <description>
    <p>This interface allows a client to iterate over the Bindinglist it has been
      initiated with.</p>
    <p>The type <c>NameComponent</c> used below is defined as:</p>
    <code type="none">
      -record('CosNaming_NameComponent', {id, kind=""}).
    </code>
    <p><c>id</c> and <c>kind</c> are strings. </p>
    <p>The type <c>Binding</c> used below is defined as:</p>
    <code type="none">
      -record('CosNaming_Binding', {binding_name, binding_type}).
    </code>
    <p><c>binding_name</c> is a <c>Name = [NameComponent]</c> and
      <c>binding_type</c> is an enum which 
      has the values <c>nobject</c> and <c>ncontext</c>.</p>
    <p>Both these records are defined in the file <c>CosNaming.hrl</c> and it 
      is included with:</p>
    <code type="none">
      -include_lib("orber/COSS/CosNaming/CosNaming.hrl").
    </code>
  </description>
  <funcs>
    <func>
      <name>next_one(BindinIterator) -> Return</name>
      <fsummary>Return a binding</fsummary>
      <type>
        <v>BindingIterator = #objref</v>
        <v>Return = {bool(), Binding}</v>
      </type>
      <desc>
        <p>This operation returns the next binding and a boolean. The latter
          is set to true if the binding is valid otherwise false. If the boolean
          is false there are no more bindings to retrieve.</p>
      </desc>
    </func>
    <func>
      <name>next_n(BindinIterator, HowMany) -> Return</name>
      <fsummary>Return a binding list</fsummary>
      <type>
        <v>BindingIterator = #objref</v>
        <v>HowMany = int()</v>
        <v>BindingList = [Binding]</v>
        <v>Return = {bool(), BindingList}</v>
      </type>
      <desc>
        <p>This operation returns a binding list with at most HowMany bindings.
          If there are no more bindings it returns false otherwise true.</p>
      </desc>
    </func>
    <func>
      <name>destroy(BindingIterator) -> Return</name>
      <fsummary>Destroy the iterator object</fsummary>
      <type>
        <v>BindingIterator = #objref</v>
        <v>Return = ok</v>
      </type>
      <desc>
        <p>This operation destroys the binding iterator.</p>
      </desc>
    </func>
  </funcs>
  
</erlref>

