<html>
<head>
<title>not() ֐</title>
</head>
<body bgcolor="#FFFFFF" text="#000000">
<div id="">
<table cellpadding="0" cellspacing="0" border="0" width="100%" class="main">
<tr>
<td valign="top" class="NAME">not() ֐</td>
<td valign="top" class="COMPATIBILITY">&nbsp;</td>
</tr>
<tr>
<td colspan="2" class="divider"><img src="dwres:18084" width="100%" height="1"></td>
</tr>
<tr>
<td valign="top" colspan="2" class="description">
p[^̔ےԂ܂Bp[^Ƀu[lłȂꍇ́A<span class="LITERAL">boolean()</span> ֐ŐĂKgpău[lɕϊ܂B</td></tr>
<tr>
<td colspan="2" class="CLEARSEPARATION">&nbsp;</td>
</tr>
<tr>
<td colspan="2" class="TITLE"></td>
</tr>
<tr>
<td colspan="2" class="description">
<p>u[lBʓIɂ́Au[l] XPath B</p>
</td>
</tr>
<tr>
<td colspan="2" class="CLEARSEPARATION">&nbsp;</td>
</tr>
<tr>
<td colspan="2" class="TITLE">o</td>
</tr>
<tr>
<td colspan="2" class="description">
<p>
̓p[^ <span class="LITERAL">true</span> łꍇ <span class="LITERAL">false</span>A̓p[^ <span class="LITERAL">false</span> łꍇ <span class="LITERAL">true</span>B</p>
</td>
</tr>
<tr>
<td colspan="2" class="CLEARSEPARATION">&nbsp;</td>
</tr>
<tr>
<td colspan="2" class="TITLE">`</td>
</tr>
<tr>
<td colspan="2" class="description">
<p>XPath 4.3 ߁uBoolean Functionsv</p>
</td>
</tr>
<tr>
<td colspan="2" class="CLEARSEPARATION">&nbsp;</td>
</tr>
<tr>
<td colspan="2" class="TITLE"></td>
</tr>
<tr>
<td colspan="2" class="description">
<p><span class="LITERAL">not()</span> ֐߂ɁA<span class="LITERAL">boolean()</span> ֐Ŏgp̂ƓX^CV[g XML hLggp܂B XML hLĝ͎ƂłB</p>
<span class="PROGRAMLISTING"><pre>
&lt;?xml version="1.0"?&gt;
&lt;test&gt;
&lt;p&gt;This is a test XML document used by several 
of our sample stylesheets.&lt;/p&gt;
&lt;question&gt;
&lt;text&gt;When completed, the Eiffel Tower was the 
tallest building in the world.&lt;/text&gt;
&lt;true&gt;Yes!  The Eiffel Tower was the world's 
tallest building until 1932, when
New York's Empire State Building opened. &lt;/true&gt;
&lt;false&gt;No, the Eiffel Tower was the world's 
tallest building for over 30 years.&lt;/false&gt;
&lt;/question&gt;
&lt;/test&gt;</pre></span>
<p>̃hLg̃X^CV[ggpď܂BX^CV[gł́A<span class="LITERAL">not()</span> gpĂׂĂ <span class="LITERAL">boolean()</span> ֐Ăяoے肵܂B</p>
<span class="PROGRAMLISTING"><pre>
&lt;?xml version="1.0"?&gt;
&lt;xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"&gt;

  &lt;xsl:output method="text"/&gt;

  &lt;xsl:variable name="newline"&gt;
&lt;xsl:text&gt;
&lt;/xsl:text&gt;
  &lt;/xsl:variable&gt;

  &lt;xsl:template match="/"&gt;
    &lt;xsl:value-of select="$newline"/&gt;
    &lt;xsl:text&gt;Tests of the not() function:&lt;/xsl:text&gt;

    &lt;xsl:value-of select="$newline"/&gt;
    &lt;xsl:value-of select="$newline"/&gt;
    &lt;xsl:choose&gt;
      &lt;xsl:when test="not(boolean(true()))"&gt;
        &lt;xsl:text&gt;   "not(boolean(true()))"   returned true!&lt;/xsl:text&gt;
      &lt;/xsl:when&gt;
      &lt;xsl:otherwise&gt;
        &lt;xsl:text&gt;   "not(boolean(true()))"   returned false!&lt;/xsl:text&gt;
      &lt;/xsl:otherwise&gt;
    &lt;/xsl:choose&gt;

    &lt;xsl:value-of select="$newline"/&gt;
    &lt;xsl:choose&gt;
      &lt;xsl:when test="not(boolean(true))"&gt;
        &lt;xsl:text&gt;   "not(boolean(true))"     returned true!&lt;/xsl:text&gt;
      &lt;/xsl:when&gt;
      &lt;xsl:otherwise&gt;
        &lt;xsl:text&gt;   "not(boolean(true))"     returned false!&lt;/xsl:text&gt;
      &lt;/xsl:otherwise&gt;
    &lt;/xsl:choose&gt;

    &lt;xsl:value-of select="$newline"/&gt;
    &lt;xsl:choose&gt;
      &lt;xsl:when test="not(boolean('false'))"&gt;
        &lt;xsl:text&gt;   "not(boolean('false'))"  returned true!&lt;/xsl:text&gt;
      &lt;/xsl:when&gt;
      &lt;xsl:otherwise&gt;
        &lt;xsl:text&gt;   "not(boolean('false'))"  returned false!&lt;/xsl:text&gt;
      &lt;/xsl:otherwise&gt;
    &lt;/xsl:choose&gt;

    &lt;xsl:value-of select="$newline"/&gt;
    &lt;xsl:choose&gt;
      &lt;xsl:when test="not(boolean('7'))"&gt;
        &lt;xsl:text&gt;   "not(boolean('7'))"      returned true!&lt;/xsl:text&gt;
      &lt;/xsl:when&gt;
      &lt;xsl:otherwise&gt;
        &lt;xsl:text&gt;   "not(boolean('7'))"      returned false!&lt;/xsl:text&gt;
      &lt;/xsl:otherwise&gt;
    &lt;/xsl:choose&gt;

    &lt;xsl:value-of select="$newline"/&gt;
    &lt;xsl:choose&gt;
      &lt;xsl:when test="not(boolean(/true))"&gt;
        &lt;xsl:text&gt;   "not(boolean(/true))"    returned true!&lt;/xsl:text&gt;
      &lt;/xsl:when&gt;
      &lt;xsl:otherwise&gt;
        &lt;xsl:text&gt;   "not(boolean(/true))"    returned false!&lt;/xsl:text&gt;
      &lt;/xsl:otherwise&gt;
    &lt;/xsl:choose&gt;

    &lt;xsl:value-of select="$newline"/&gt;
    &lt;xsl:choose&gt;
      &lt;xsl:when test="not(boolean(//true))"&gt;
        &lt;xsl:text&gt;   "not(boolean(//true))"   returned true!&lt;/xsl:text&gt;
      &lt;/xsl:when&gt;
      &lt;xsl:otherwise&gt;
        &lt;xsl:text&gt;   "not(boolean(//true))"   returned false!&lt;/xsl:text&gt;
      &lt;/xsl:otherwise&gt;
    &lt;/xsl:choose&gt;
  &lt;/xsl:template&gt;

&lt;/xsl:stylesheet&gt;</pre></span>
<p>ʂ͎̂ƂłB</p>
<span class="PROGRAMLISTING"><pre>

Tests of the not() function:

   "not(boolean(true()))"   returned false!
   "not(boolean(true))"     returned true!
   "not(boolean('false'))"  returned false!
   "not(boolean('7'))"      returned false!
   "not(boolean(/true))"    returned true!
   "not(boolean(//true))"   returned false!
</pre></span>
<p>̌ʂ́A<span class="LITERAL">boolean()</span> ֐eXgƂ̌ʂƔ΂ɂȂ܂B</p>
</td>
</tr>
</table>
</div>
</body>
</html>
