This file is indexed.

/usr/share/mozart/doc/cpitut/node14.html is in mozart-doc 1.4.0-8ubuntu1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

1
2
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD><TITLE>A Definition Class for Real-Interval Constraints</TITLE><LINK href="ozdoc.css" rel="stylesheet" type="text/css"></HEAD><BODY><TABLE align="center" border="0" cellpadding="6" cellspacing="6" class="nav"><TR bgcolor="#DDDDDD"><TD><A href="node13.html">- Up -</A></TD><TD><A href="node15.html#ct.casestudy.impl.profilewakeup">Next &gt;&gt;</A></TD></TR></TABLE><DIV id="ct.casestudy.impl.ridef"><H4><A name="ct.casestudy.impl.ridef">A Definition Class for Real-Interval Constraints</A></H4><P>The class <CODE>RIDefinition</CODE> is derived from the C<SPAN class="allcaps">PI</SPAN> class <CODE>OZ_CtDefinition</CODE>. It gathers all information needed to handle real-interval constraints properly by the runtime system. It allows the runtime system to distinguish real-interval constraint from other constraints by calling the member function <CODE>getKind()</CODE>. Note that <CODE>_kind</CODE> is static and to obtain a unique identifier the function <CODE>OZ_getUniqueId()</CODE> is recommended to be used. For testing Oz values to be compatible with real-intervals <CODE>isValidValue()</CODE>, is to be defined appropriately. </P><P>Further, <CODE>RIDefinition</CODE> allows the runtime system to determine the number of possible events causing suspending computation to be woken up. There are two possible events for which a suspending computation may want to be notified: the lower bound is increased or the upper bound is decreased (or both). Therefore, two wake-up lists are used (see <CODE>getNoOfWakeUpLists()</CODE>). </P><BLOCKQUOTE class="linenumbers"><PRE><SPAN class="keyword">class</SPAN>&nbsp;<SPAN class="type">RIDefinition</SPAN>&nbsp;:&nbsp;<SPAN class="keyword">public</SPAN>&nbsp;<SPAN class="type">OZ_CtDefinition</SPAN>&nbsp;{<BR><SPAN class="keyword">private</SPAN>:<BR>&nbsp;&nbsp;<SPAN class="keyword">static</SPAN>&nbsp;<SPAN class="type">int</SPAN>&nbsp;<SPAN class="variablename">_kind</SPAN>;&nbsp;&nbsp;<BR>&nbsp;<BR><SPAN class="keyword">public</SPAN>:&nbsp;&nbsp;<BR>&nbsp;&nbsp;<SPAN class="keyword">virtual</SPAN>&nbsp;<SPAN class="type">int</SPAN>&nbsp;<SPAN class="functionname">getKind</SPAN>(<SPAN class="type">void</SPAN>)&nbsp;{&nbsp;<SPAN class="keyword">return</SPAN>&nbsp;_kind;&nbsp;}<BR>&nbsp;&nbsp;<SPAN class="keyword">virtual</SPAN>&nbsp;<SPAN class="type">char</SPAN>&nbsp;*&nbsp;<SPAN class="functionname">getName</SPAN>(<SPAN class="type">void</SPAN>)&nbsp;{&nbsp;<SPAN class="keyword">return</SPAN>&nbsp;<SPAN class="string">&quot;real&nbsp;interval&quot;</SPAN>;&nbsp;}<BR>&nbsp;&nbsp;<SPAN class="keyword">virtual</SPAN>&nbsp;<SPAN class="type">int</SPAN>&nbsp;<SPAN class="functionname">getNoOfWakeUpLists</SPAN>(<SPAN class="type">void</SPAN>)&nbsp;{&nbsp;<SPAN class="keyword">return</SPAN>&nbsp;2;&nbsp;}<BR>&nbsp;&nbsp;<SPAN class="keyword">virtual</SPAN>&nbsp;<SPAN class="type">char</SPAN>&nbsp;**&nbsp;<SPAN class="functionname">getNamesOfWakeUpLists</SPAN>(<SPAN class="type">void</SPAN>)&nbsp;{<BR>&nbsp;&nbsp;&nbsp;&nbsp;<SPAN class="keyword">static</SPAN>&nbsp;<SPAN class="type">char</SPAN>&nbsp;*&nbsp;<SPAN class="variablename">names</SPAN>[2]&nbsp;=&nbsp;{<SPAN class="string">&quot;lower&quot;</SPAN>,&nbsp;<SPAN class="string">&quot;upper&quot;</SPAN>};<BR>&nbsp;&nbsp;&nbsp;&nbsp;<SPAN class="keyword">return</SPAN>&nbsp;names;<BR>&nbsp;&nbsp;}<BR>&nbsp;&nbsp;<SPAN class="keyword">virtual</SPAN>&nbsp;<SPAN class="type">OZ_Ct</SPAN>&nbsp;*&nbsp;<SPAN class="functionname">leastConstraint</SPAN>(<SPAN class="type">void</SPAN>)&nbsp;{<BR>&nbsp;&nbsp;&nbsp;&nbsp;<SPAN class="keyword">return</SPAN>&nbsp;<SPAN class="reference">RI</SPAN>::leastConstraint();<BR>&nbsp;&nbsp;}<BR>&nbsp;&nbsp;<SPAN class="keyword">virtual</SPAN>&nbsp;<SPAN class="type">OZ_Boolean</SPAN>&nbsp;<SPAN class="functionname">isValidValue</SPAN>(<SPAN class="type">OZ_Term</SPAN>&nbsp;<SPAN class="variablename">f</SPAN>)&nbsp;{<BR>&nbsp;&nbsp;&nbsp;&nbsp;<SPAN class="keyword">return</SPAN>&nbsp;<SPAN class="reference">RI</SPAN>::isValidValue(f);<BR>&nbsp;&nbsp;}&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<BR>};<BR>&nbsp;<BR><SPAN class="type">int</SPAN>&nbsp;<SPAN class="reference">RIDefinition</SPAN>::<SPAN class="variablename">_kind</SPAN>&nbsp;=&nbsp;OZ_getUniqueId();<BR></PRE></BLOCKQUOTE><P> </P><P>The function <CODE>leastConstraint()</CODE> is required to enable the runtime system to constrain a variable to a real-interval with greatest possible width, i.&nbsp;e., ranging from <CODE>RI_FLOAT_MIN</CODE> to <CODE>RI_FLOAT_MAX</CODE>. For example this is necessary when nested variables are to be constrained. </P></DIV><TABLE align="center" border="0" cellpadding="6" cellspacing="6" class="nav"><TR bgcolor="#DDDDDD"><TD><A href="node13.html">- Up -</A></TD><TD><A href="node15.html#ct.casestudy.impl.profilewakeup">Next &gt;&gt;</A></TD></TR></TABLE><HR><ADDRESS><A href="http://www.ps.uni-sb.de/~tmueller/">Tobias&nbsp;Müller</A><BR><SPAN class="version">Version 1.4.0 (20110908185330)</SPAN></ADDRESS></BODY></HTML>