blob: 9717862a5f46c83d15b30153125b96ff1b52ebac [file] [log] [blame]
<!DOCTYPE html
PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "../xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<link rel="stylesheet" type="text/css" href="../css/ot.css" />
<link rel="stylesheet" type="text/css" href="../css/otjld.css" />
<title>OT/J Language Definition v1.3</title>
</head>
<body class="otdt">
<div id="content">
<table class="nav">
<tr>
<td class="back"><a id="top"></a></td>
<td class="top"><a href="index.html" rel="contents">&uarr;&nbsp;Table of Contents&nbsp;&uarr;</a></td>
<td class="next"><a href="sA.1.html" rel="next">&sect;A.1&nbsp;Class definitions&nbsp;&gt;&gt;</a></td>
</tr>
</table>
<div class="breadcrumb"><a class="nav" href="sA.html" rel="section">&sect;A&nbsp;OT/J Syntax</a></div>
<div class="sect depth2" id="sA.0">
<h2 class="sect">&sect;A.0&nbsp;Keywords<a class="img" href="sA.0.html" title="PermaLink to &sect;A.0&nbsp;Keywords"><img style="vertical-align:text-top;margin-left:5px;" src="../images/permalink.png"
alt="" /></a></h2>
<p>The keywords introduced by OT/J have different scopes, which means outside their
given scope these keywords can be used for regular identifiers. Only these names
are keywords unconditionally:
</p>
<div class="listing plain"><pre>readonly, team, within</pre></div>
<div class="sect depth3" id="sA.0.1">
<h3 class="sect">&sect;A.0.1&nbsp;Scoped keywords<a class="img" href="sA.0.1.html"
title="PermaLink to &sect;A.0.1&nbsp;Scoped keywords"><img style="vertical-align:text-top;margin-left:5px;" src="../images/permalink.png"
alt="" /></a><span class="toplink"><a href="#top">&uarr;&nbsp;&sect;A.0</a></span></h3>
<p>The following names are keywords in OT/J only if they appear within a team or role class,
ie., after the keyword <strong class="blue">team</strong> has been recognized:
</p>
<div class="listing plain"><pre>as, base, callin, playedBy, precedence, tsuper, with, when</pre></div>
<p>These names are keywords only in the context of a callin or callout binding
respectively (<a href="sA.3.html" title="&sect;A.3&nbsp;Method bindings" class="sect">&sect;A.3</a>):
</p>
<div class="listing plain"><pre>after, before, replace, get, set</pre></div>
</div>
<div class="sect depth3" id="sA.0.2">
<h3 class="sect">&sect;A.0.2&nbsp;Inheriting scoped keywords<a class="img" href="sA.0.2.html"
title="PermaLink to &sect;A.0.2&nbsp;Inheriting scoped keywords"><img style="vertical-align:text-top;margin-left:5px;" src="../images/permalink.png"
alt="" /></a><span class="toplink"><a href="#top">&uarr;&nbsp;&sect;A.0</a></span></h3>
<p>While regular Java classes may use the scoped keywords
(<a href="#sA.0.1" title="&sect;A.0.1&nbsp;Scoped keywords" class="sect">&sect;A.0.1</a>) of OT/J freely, it is an error if a role class
inherits a feature whose name is a scoped keyword.
</p>
</div>
<div class="sect depth3" id="sA.0.3">
<h3 class="sect">&sect;A.0.3&nbsp;Internal names<a class="img" href="sA.0.3.html"
title="PermaLink to &sect;A.0.3&nbsp;Internal names"><img style="vertical-align:text-top;margin-left:5px;" src="../images/permalink.png"
alt="" /></a><span class="toplink"><a href="#top">&uarr;&nbsp;&sect;A.0</a></span></h3>
<p>Compiler and runtime environment generate internal methods and fields which start with
the prefix <code>_OT$</code>. It is illegal to use any of these methods and fields within client code.
</p>
</div>
</div>
<table class="nav">
<tr>
<td class="back"></td>
<td class="top"><a href="index.html" rel="contents">&uarr;&nbsp;Table of Contents&nbsp;&uarr;</a></td>
<td class="next"><a href="sA.1.html" rel="next">&sect;A.1&nbsp;Class definitions&nbsp;&gt;&gt;</a></td>
</tr>
</table>
<div class="breadcrumb"><a class="nav" href="sA.html" rel="section">&sect;A&nbsp;OT/J Syntax</a></div>
</div>
<div id="footer">
<hr /><a class="w3c img" href="http://jigsaw.w3.org/css-validator/check/referer"
shape="rect"><img src="../images/valid-css2-blue.png" alt="Valid CSS!" height="31" width="88" /></a><a class="w3c img" href="http://validator.w3.org/check?uri=referer" shape="rect"><img src="../images/valid-xhtml10-blue.png" alt="Valid XHTML 1.0 Strict" height="31"
width="88" /></a><address>&copy; Stephan Herrmann, Christine Hundt, Marco Mosconi</address>
OT/J version 1.3 &mdash; last modified: 2011-05-15
</div>
</body>
</html>