/usr/share/mozart/doc/base/class.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>9.8 Classes</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="lock.html#section.chunks.locks"><< Prev</A></TD><TD><A href="node11.html">- Up -</A></TD><TD><A href="object.html#section.chunks.objects">Next >></A></TD></TR></TABLE><DIV id="section.chunks.classes"><H2><A name="section.chunks.classes">9.8 Classes</A></H2><P> The module <A name="label649"></A><SPAN class="index"><CODE>Class</CODE></SPAN> contains procedures operating on classes. </P><DL><DT><A name="label650"></A><SPAN class="index"><CODE>IsClass</CODE></SPAN> <A name="label652"></A> </DT><DD><BLOCKQUOTE class="synopsis"><P><CODE>{Class<SPAN class="keyword">.</SPAN>is </CODE><CODE>+<I>X</I></CODE><CODE> </CODE><CODE>?<I>B</I></CODE><CODE>}</CODE> </P></BLOCKQUOTE></DD><DD><P>tests whether <CODE><I>X</I></CODE> is a class. </P></DD><DT><CODE>new</CODE> <A name="label654"></A> </DT><DD><BLOCKQUOTE class="synopsis"><P><CODE>{Class<SPAN class="keyword">.</SPAN>new </CODE><CODE>+<I>ParentKs</I></CODE><CODE> </CODE><CODE>+<I>AttrR</I></CODE><CODE> </CODE><CODE>+<I>FeatR</I></CODE><CODE> </CODE><CODE>+<I>PropAs</I></CODE><CODE> </CODE><CODE>?<I>K</I></CODE><CODE>}</CODE> </P></BLOCKQUOTE></DD><DD><P>creates a new class by inheriting from <CODE><I>ParentKs</I></CODE> with new attributes <CODE><I>AttrR</I></CODE> and new features <CODE><I>FeatR</I></CODE>. The fields with integer features in <CODE><I>AttrR</I></CODE> define the free attributes. The fields with literal features define attributes with initial values, where the feature is the attribute name and the field its initial value. The semantics for <CODE><I>FeatR</I></CODE> is accordingly. The properties of the class to be created are defined by <CODE><I>PropAs</I></CODE> (a list of atoms, valid elements are <CODE>sited</CODE>, <CODE>final</CODE>, and <CODE>locking</CODE>). </P><P> For example, the statement </P><BLOCKQUOTE class="code"><CODE>C={Class<SPAN class="keyword">.</SPAN>new [D E] a(a:1 b) f(f:2 g) [final]}</CODE></BLOCKQUOTE><P> is equivalent to </P><BLOCKQUOTE class="code"><CODE><SPAN class="keyword">class</SPAN> <SPAN class="type">C</SPAN> <SPAN class="keyword">from</SPAN><SPAN class="type"> D E</SPAN> <BR> <SPAN class="keyword">prop</SPAN> final<BR> <SPAN class="keyword">attr</SPAN> a:1 b<BR> <SPAN class="keyword">feat</SPAN> f:2 g<BR><SPAN class="keyword">end</SPAN></CODE></BLOCKQUOTE><P> </P></DD><DT><CODE>getAttr</CODE> <A name="label656"></A> </DT><DD><BLOCKQUOTE class="synopsis"><P><CODE>{Class<SPAN class="keyword">.</SPAN>getAttr </CODE><CODE>+<I>K</I></CODE><CODE> </CODE><CODE>+<I>LI</I></CODE><CODE> </CODE><CODE>?<I>X</I></CODE><CODE>}</CODE> </P></BLOCKQUOTE></DD><DD><P>Returns the initival value <CODE><I>X</I></CODE> for attribute <CODE><I>LI</I></CODE> as defined by the class <CODE><I>K</I></CODE>. </P><P> For example, the statement </P><BLOCKQUOTE class="code"><CODE>{Class<SPAN class="keyword">.</SPAN>getAttr <SPAN class="keyword">class</SPAN> <SPAN class="keyword">attr</SPAN> a:4 <SPAN class="keyword">end</SPAN> a}</CODE></BLOCKQUOTE><P> returns <CODE>4</CODE>. </P></DD></DL><P> </P></DIV><TABLE align="center" border="0" cellpadding="6" cellspacing="6" class="nav"><TR bgcolor="#DDDDDD"><TD><A href="lock.html#section.chunks.locks"><< Prev</A></TD><TD><A href="node11.html">- Up -</A></TD><TD><A href="object.html#section.chunks.objects">Next >></A></TD></TR></TABLE><HR><ADDRESS><A href="http://www.ps.uni-sb.de/~duchier/">Denys Duchier</A>, <A href="http://www.ps.uni-sb.de/~kornstae/">Leif Kornstaedt</A> and <A href="http://www.ps.uni-sb.de/~schulte/">Christian Schulte</A><BR><SPAN class="version">Version 1.4.0 (20110908185330)</SPAN></ADDRESS></BODY></HTML>
|