Against a snap shot of changes I do not want to lose.

This commit is contained in:
Oliver Burn 2002-09-04 04:04:03 +00:00
parent e55cf9b0bc
commit bfe1cbdbed
3 changed files with 109 additions and 9 deletions

View File

@ -10,7 +10,6 @@
<li><a href="checks_blocks.html">checks_blocks.html</a></li>
<li><a href="checks_reporting.html">checks_reporting.html</a></li>
<li><a href="checks_whitespace.html">checks_whitespace.html</a></li>
<li><a href="checks_header.html">Checks for Headers</a></li>
<li><a href="checks_javadoc.html">Checks for Javadoc comments</a></li>
<li><a href="checks_misc.html">Miscellaneous Checks</a></li>
@ -18,10 +17,11 @@
<li><a href="checks_imports.html">Checks for Imports</a></li>
<li><a href="checks_sizes.html">Checks for sizes</a></li>
<li><a href="checks_modifiers.html">Modifier Checks</a></li>
<li><a href="checks_whitespace.html">Checks for whitespace</a></li>
</ul>
<hr>
<address></address>
<!-- hhmts start --> Last modified: Mon Sep 02 21:47:15 EST 2002 <!-- hhmts end -->
<!-- hhmts start --> Last modified: Wed Sep 04 14:02:11 EST 2002 <!-- hhmts end -->
</body> </html>

View File

@ -1,18 +1,68 @@
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
<head>
<title></title>
<title>Checks for whitespace</title>
<link rel="stylesheet" type="text/css" href="mystyle.css">
</head>
<body>
<h1></h1>
<h1>Checks for whitespace</h1>
<li>checkstyle.allow.tabs"</li>
<li>checkstyle.ignore.whitespace"</li>
<li>checkstyle.ignore.whitespace.cast"</li>
<li>checkstyle.paren.pad"</li>
<li>checkstyle.wrap.operator"</li>
<h2>Tab characters</h2>
<p>The property <span class="code">checkstyle.allow.tabs</span> controls
whether to silently allow lines that contain tab (<code>'\t'</code>)
characters. The property type is
<a href="property_types.html#boolean">boolean</a> and defaults to
<span class="default">false</span>.</p>
<h2>Surrounding Whitespace</h2>
<p>The property <span class="code">checkstyle.ignore.whitespace</span>
controls whether to check whitespace. It overrides all the other properties in
this section. The property type is
<a href="property_types.html#boolean">boolean</a> and defaults to
<span class="default">false</span>.</p>
<p>The following checks are performed:</p>
<ul>
<li>Binary operators are separated from operands by spaces. For example
<span class="code">x = y + 1;</span></li>
<li>Unary operators are not separated by spaces. For example
<span class="code">x = --y + z++;</span></li>
<li>The keywords
<span class="code">if/for/while/do/catch/synchronized/return</span> are
surrounded by spaces.</li>
<li>Casts and commas (',') are followed by whitespace.</li>
<li>Periods ('.') are not surrounded by whitespace.</li>
<li>Correct padding of parenthesises <span class="code">()</span>'s.</li>
</ul>
<p>The property <span class="code">checkstyle.ignore.whitespace.cast</span>
controls whether to ignore checking for whitespace after a cast. The property
type is <a href="property_types.html#boolean">boolean</a> and defaults to
<span class="default">false</span>.</p>
<p>The property <span class="code">checkstyle.paren.pad</span> specifies the
policy on how parenthesises are to be padded. The property type is
<a href="property_types.html#parenPad">pad parenthesis policy</a> and defaults to <span
class="default">nospace</span>.</p>
<h2>Line wrapping on operators</h2>
<p>The property <span class="code">checkstyle.wrap.operator</span> specifies
the policy on how to wrap lines on operators. The property type is <a
href="property_types.html#wrapOp">wrap operator policy</a> and defaults to
<span class="default">nl</span>.</p>
</body>
</html>

View File

@ -46,5 +46,55 @@ parsed using the excellent <a href="http://jakarta.apache.org/regexp">Jakarta
Regexp</a> library.</p>
<h2><a name="parenPad">Pad Parenthesis Policy</a></h2>
<p>This property represents the policy for padding parenthesises. The
following table describes the valid options:</p>
<table border="1" summary="parenthesises padding options">
<tr class="header">
<td>Option</td>
<td>Definition</td>
</tr>
<tr>
<td><span class="code">ignore</span></td>
<td>Ignore the padding.</td>
</tr>
<tr>
<td><span class="code">nospace</span></td>
<td>Do not pad. For example, <span class="code">method(a, b);</span></td>
</tr>
<tr>
<td><span class="code">space</span></td>
<td>Ensure padding. For example, <span class="code">method( a, b );</span></td>
</tr>
</table>
<h2><a name="wrapOp">Operator Wrap Policy</a></h2>
<p>This property represents the policy for wrapping lines on operators. The
following table describes the valid options:</p>
<table border="1" summary="wrap operator options">
<tr class="header">
<td>Option</td>
<td>Definition</td>
</tr>
<tr>
<td><span class="code">ignore</span></td>
<td>Ignore wrapping on an operator.</td>
</tr>
<tr>
<td><span class="code">nl</span></td>
<td>The operator must be on a new line. For example:
<pre>
someVariable = aBigVariableNameToMakeThings + "this may work"
+ lookVeryInteresting;
</pre>
</td>
</tr>
</table>
</body>
</html>