=Namespace Declarations=
The following example uses Java’s {{Mono|Math}} class and returns to return the cosine of an angle.The [[XQuery 3.0|Expanded QNames|Expanded QName]] notation is used to address the{{Mono|cos()}} method , which can be directly called, as it is a {{Mono|static}} method:
<pre class="brush:xquery">declare namespace math = "Q{java:java.lang.Math";math:}cos(xs:double(0))
</pre>