<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html 
     PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
     "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
  <title>Class: Vpi::Handle</title>
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  <meta http-equiv="Content-Script-Type" content="text/javascript" />
  <link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
  <script type="text/javascript">
  // <![CDATA[

  function popupCode( url ) {
    window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
  }

  function toggleCode( id ) {
    if ( document.getElementById )
      elem = document.getElementById( id );
    else if ( document.all )
      elem = eval( "document.all." + id );
    else
      return false;

    elemStyle = elem.style;
    
    if ( elemStyle.display != "block" ) {
      elemStyle.display = "block"
    } else {
      elemStyle.display = "none"
    }

    return true;
  }
  
  // Make codeblocks hidden by default
  document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
  
  // ]]>
  </script>

</head>
<body>



    <div id="classHeader">
        <table class="header-table">
        <tr class="top-aligned-row">
          <td><strong>Class</strong></td>
          <td class="class-name-in-header">Vpi::Handle</td>
        </tr>
        <tr class="top-aligned-row">
            <td><strong>In:</strong></td>
            <td>
                <a href="../../files/lib/ruby-vpi/vpi_rb.html">
                lib/ruby-vpi/vpi.rb
                </a>
        <br />
            </td>
        </tr>

        <tr class="top-aligned-row">
            <td><strong>Parent:</strong></td>
            <td>
                Object
            </td>
        </tr>
        </table>
    </div>
  <!-- banner header -->

  <div id="bodyContent">



  <div id="contextContent">

    <div id="description">
      <p>
A handle is an object inside a Verilog simulation (see <b>vpiHandle</b> in
IEEE Std. 1364-2005). VPI types and properties listed in ext/vpi_user.h can
be specified by their names (strings or symbols) or integer constants.
</p>
<h1>Example names</h1>
<ul>
<li>&quot;intVal&quot;

</li>
<li>:intVal

</li>
<li>&quot;vpiIntVal&quot;

</li>
<li>:vpiIntVal

</li>
<li>&quot;VpiIntVal&quot;

</li>
<li>:VpiIntVal

</li>
</ul>
<h1>Example constants</h1>
<ul>
<li>VpiIntVal

</li>
<li>VpiModule

</li>
<li>VpiReg

</li>
</ul>

    </div>


   </div>

    <div id="method-list">
      <h3 class="section-bar">Methods</h3>

      <div class="name-list">
      <a href="#M000050">&lt;=&gt;</a>&nbsp;&nbsp;
      <a href="#M000048">[]</a>&nbsp;&nbsp;
      <a href="#M000053">cbValueChange</a>&nbsp;&nbsp;
      <a href="#M000046">get_value</a>&nbsp;&nbsp;
      <a href="#M000045">get_value_wrapper</a>&nbsp;&nbsp;
      <a href="#M000040">high!</a>&nbsp;&nbsp;
      <a href="#M000039">high?</a>&nbsp;&nbsp;
      <a href="#M000051">inspect</a>&nbsp;&nbsp;
      <a href="#M000042">low!</a>&nbsp;&nbsp;
      <a href="#M000041">low?</a>&nbsp;&nbsp;
      <a href="#M000054">method_missing</a>&nbsp;&nbsp;
      <a href="#M000044">negedge?</a>&nbsp;&nbsp;
      <a href="#M000043">posedge?</a>&nbsp;&nbsp;
      <a href="#M000047">put_value</a>&nbsp;&nbsp;
      <a href="#M000049">to_a</a>&nbsp;&nbsp;
      <a href="#M000052">to_s</a>&nbsp;&nbsp;
      <a href="#M000036">x!</a>&nbsp;&nbsp;
      <a href="#M000035">x?</a>&nbsp;&nbsp;
      <a href="#M000038">z!</a>&nbsp;&nbsp;
      <a href="#M000037">z?</a>&nbsp;&nbsp;
      </div>
    </div>

  </div>


    <!-- if includes -->
    <div id="includes">
      <h3 class="section-bar">Included Modules</h3>

      <div id="includes-list">
        <span class="include-name"><a href="../Vpi.html">Vpi</a></span>
      </div>
    </div>

    <div id="section">


    <div id="constants-list">
      <h3 class="section-bar">Constants</h3>

      <div class="name-list">
        <table summary="Constants">
        <tr class="top-aligned-row context-row">
          <td class="context-item-name">Property</td>
          <td>=</td>
          <td class="context-item-value">Struct.new(:type, :name, :operation, :accessor, :assignment)</td>
        </tr>
        </table>
      </div>
    </div>



      


    <!-- if method_list -->
    <div id="methods">
      <h3 class="section-bar">Public Instance methods</h3>

      <div id="method-M000050" class="method-detail">
        <a name="M000050"></a>

        <div class="method-heading">
          <a href="Handle.src/M000050.html" target="Code" class="method-signature"
            onclick="popupCode('Handle.src/M000050.html');return false;">
          <span class="method-name">&lt;=&gt;</span><span class="method-args">(other)</span>
          </a>
        </div>
      
        <div class="method-description">
          <p>
Sort by absolute VPI path.
</p>
        </div>
      </div>

      <div id="method-M000048" class="method-detail">
        <a name="M000048"></a>

        <div class="method-heading">
          <a href="Handle.src/M000048.html" target="Code" class="method-signature"
            onclick="popupCode('Handle.src/M000048.html');return false;">
          <span class="method-name">[]</span><span class="method-args">(*aTypes)</span>
          </a>
        </div>
      
        <div class="method-description">
          <p>
Returns an array of child handles of the given types (name or integer
constant).
</p>
        </div>
      </div>

      <div id="method-M000053" class="method-detail">
        <a name="M000053"></a>

        <div class="method-heading">
          <a href="Handle.src/M000053.html" target="Code" class="method-signature"
            onclick="popupCode('Handle.src/M000053.html');return false;">
          <span class="method-name">cbValueChange</span><span class="method-args">(aOptions = {})</span>
          </a>
        </div>
      
        <div class="method-description">
          <p>
Registers a callback that is invoked whenever the value of this object
changes.
</p>
        </div>
      </div>

      <div id="method-M000046" class="method-detail">
        <a name="M000046"></a>

        <div class="method-heading">
          <a href="Handle.src/M000046.html" target="Code" class="method-signature"
            onclick="popupCode('Handle.src/M000046.html');return false;">
          <span class="method-name">get_value</span><span class="method-args">(aFormat = VpiObjTypeVal)</span>
          </a>
        </div>
      
        <div class="method-description">
          <p>
Reads the value using the given format (name or integer constant) and
returns it. If a format is not given, then the Verilog simulator will
attempt to determine the correct format.
</p>
        </div>
      </div>

      <div id="method-M000045" class="method-detail">
        <a name="M000045"></a>

        <div class="method-heading">
          <a href="Handle.src/M000045.html" target="Code" class="method-signature"
            onclick="popupCode('Handle.src/M000045.html');return false;">
          <span class="method-name">get_value_wrapper</span><span class="method-args">(aFormat)</span>
          </a>
        </div>
      
        <div class="method-description">
          <p>
Reads the value using the given format (integer constant) and returns a
<tt><a href="S_vpi_value.html">S_vpi_value</a></tt> object.
</p>
        </div>
      </div>

      <div id="method-M000040" class="method-detail">
        <a name="M000040"></a>

        <div class="method-heading">
          <a href="Handle.src/M000040.html" target="Code" class="method-signature"
            onclick="popupCode('Handle.src/M000040.html');return false;">
          <span class="method-name">high!</span><span class="method-args">()</span>
          </a>
        </div>
      
        <div class="method-description">
          <p>
Sets the logic value of this handle to &quot;logic high&quot; level.
</p>
        </div>
      </div>

      <div id="method-M000039" class="method-detail">
        <a name="M000039"></a>

        <div class="method-heading">
          <a href="Handle.src/M000039.html" target="Code" class="method-signature"
            onclick="popupCode('Handle.src/M000039.html');return false;">
          <span class="method-name">high?</span><span class="method-args">()</span>
          </a>
        </div>
      
        <div class="method-description">
          <p>
Tests if the logic value of this handle is at &quot;logic high&quot; level.
</p>
        </div>
      </div>

      <div id="method-M000051" class="method-detail">
        <a name="M000051"></a>

        <div class="method-heading">
          <a href="Handle.src/M000051.html" target="Code" class="method-signature"
            onclick="popupCode('Handle.src/M000051.html');return false;">
          <span class="method-name">inspect</span><span class="method-args">(*aPropNames)</span>
          </a>
        </div>
      
        <div class="method-description">
          <p>
Inspects the given VPI property names, in addition to those common to all
handles.
</p>
        </div>
      </div>

      <div id="method-M000042" class="method-detail">
        <a name="M000042"></a>

        <div class="method-heading">
          <a href="Handle.src/M000042.html" target="Code" class="method-signature"
            onclick="popupCode('Handle.src/M000042.html');return false;">
          <span class="method-name">low!</span><span class="method-args">()</span>
          </a>
        </div>
      
        <div class="method-description">
          <p>
Sets the logic value of this handle to &quot;logic low&quot; level.
</p>
        </div>
      </div>

      <div id="method-M000041" class="method-detail">
        <a name="M000041"></a>

        <div class="method-heading">
          <a href="Handle.src/M000041.html" target="Code" class="method-signature"
            onclick="popupCode('Handle.src/M000041.html');return false;">
          <span class="method-name">low?</span><span class="method-args">()</span>
          </a>
        </div>
      
        <div class="method-description">
          <p>
Tests if the logic value of this handle is at &quot;logic low&quot; level.
</p>
        </div>
      </div>

      <div id="method-M000054" class="method-detail">
        <a name="M000054"></a>

        <div class="method-heading">
          <a href="Handle.src/M000054.html" target="Code" class="method-signature"
            onclick="popupCode('Handle.src/M000054.html');return false;">
          <span class="method-name">method_missing</span><span class="method-args">(aMeth, *aArgs, &amp;aBlockArg)</span>
          </a>
        </div>
      
        <div class="method-description">
          <p>
Provides access to this handle&#8216;s (1) child handles and (2) VPI
properties through method calls. In the case that a child handle has the
same name as a VPI property, the child handle will be accessed instead of
the VPI property. However, you can still access the VPI property via <a
href="Handle.html#M000046">get_value</a> and <a
href="Handle.html#M000047">put_value</a>.
</p>
        </div>
      </div>

      <div id="method-M000044" class="method-detail">
        <a name="M000044"></a>

        <div class="method-heading">
          <a href="Handle.src/M000044.html" target="Code" class="method-signature"
            onclick="popupCode('Handle.src/M000044.html');return false;">
          <span class="method-name">negedge?</span><span class="method-args">()</span>
          </a>
        </div>
      
        <div class="method-description">
          <p>
Tests if the logic value of this handle is currently at a negative edge.
</p>
        </div>
      </div>

      <div id="method-M000043" class="method-detail">
        <a name="M000043"></a>

        <div class="method-heading">
          <a href="Handle.src/M000043.html" target="Code" class="method-signature"
            onclick="popupCode('Handle.src/M000043.html');return false;">
          <span class="method-name">posedge?</span><span class="method-args">()</span>
          </a>
        </div>
      
        <div class="method-description">
          <p>
Tests if the logic value of this handle is currently at a positive edge.
</p>
        </div>
      </div>

      <div id="method-M000047" class="method-detail">
        <a name="M000047"></a>

        <div class="method-heading">
          <a href="Handle.src/M000047.html" target="Code" class="method-signature"
            onclick="popupCode('Handle.src/M000047.html');return false;">
          <span class="method-name">put_value</span><span class="method-args">(aValue, aFormat = nil, aTime = nil, aDelay = VpiNoDelay)</span>
          </a>
        </div>
      
        <div class="method-description">
          <p>
Writes the given value using the given format (name or integer constant),
time, and delay, and then returns the given value. If a format is not
given, then the Verilog simulator will attempt to determine the correct
format.
</p>
        </div>
      </div>

      <div id="method-M000049" class="method-detail">
        <a name="M000049"></a>

        <div class="method-heading">
          <span class="method-name">to_a</span><span class="method-args">(*aTypes)</span>
        </div>
      
        <div class="method-description">
          <p>
Alias for #[]
</p>
        </div>
      </div>

      <div id="method-M000052" class="method-detail">
        <a name="M000052"></a>

        <div class="method-heading">
          <span class="method-name">to_s</span><span class="method-args">(*aPropNames)</span>
        </div>
      
        <div class="method-description">
          <p>
Alias for <a href="Handle.html#M000051">inspect</a>
</p>
        </div>
      </div>

      <div id="method-M000036" class="method-detail">
        <a name="M000036"></a>

        <div class="method-heading">
          <a href="Handle.src/M000036.html" target="Code" class="method-signature"
            onclick="popupCode('Handle.src/M000036.html');return false;">
          <span class="method-name">x!</span><span class="method-args">()</span>
          </a>
        </div>
      
        <div class="method-description">
          <p>
Sets the logic value of this handle to unknown (x).
</p>
        </div>
      </div>

      <div id="method-M000035" class="method-detail">
        <a name="M000035"></a>

        <div class="method-heading">
          <a href="Handle.src/M000035.html" target="Code" class="method-signature"
            onclick="popupCode('Handle.src/M000035.html');return false;">
          <span class="method-name">x?</span><span class="method-args">()</span>
          </a>
        </div>
      
        <div class="method-description">
          <p>
Tests if the logic value of this handle is unknown (x).
</p>
        </div>
      </div>

      <div id="method-M000038" class="method-detail">
        <a name="M000038"></a>

        <div class="method-heading">
          <a href="Handle.src/M000038.html" target="Code" class="method-signature"
            onclick="popupCode('Handle.src/M000038.html');return false;">
          <span class="method-name">z!</span><span class="method-args">()</span>
          </a>
        </div>
      
        <div class="method-description">
          <p>
Sets the logic value of this handle to high impedance (z).
</p>
        </div>
      </div>

      <div id="method-M000037" class="method-detail">
        <a name="M000037"></a>

        <div class="method-heading">
          <a href="Handle.src/M000037.html" target="Code" class="method-signature"
            onclick="popupCode('Handle.src/M000037.html');return false;">
          <span class="method-name">z?</span><span class="method-args">()</span>
          </a>
        </div>
      
        <div class="method-description">
          <p>
Tests if the logic value of this handle is high impedance (z).
</p>
        </div>
      </div>


    </div>


  </div>


<div id="validator-badges">
  <p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
</div>

</body>
</html>