/
throws.scala
28 lines (24 loc) · 1.03 KB
/
throws.scala
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
/* __ *\
** ________ ___ / / ___ Scala API **
** / __/ __// _ | / / / _ | (c) 2002-2007, LAMP/EPFL **
** __\ \/ /__/ __ |/ /__/ __ | http://scala-lang.org/ **
** /____/\___/_/ |_/____/_/ | | **
** |/ **
*/
// $Id$
package scala
/** <p>
* Annotation for specifying the exceptions thrown by a method.
* For example:
* </p><pre>
* <b>class</b> Reader(fname: String) {
* <b>private val</b> in =
* <b>new</b> BufferedReader(<b>new</b> <a class="java/io/FileReader" href="" target="_top">FileReader</a>(fname))
* @throws(classOf[<a class="java/io/IOException" href="" target="_top">IOException</a>])
* <b>def</b> read() = in.read()
* }</pre>
*
* @author Nikolay Mihaylov
* @version 1.0, 19/05/2006
*/
class throws(clazz: java.lang.Class) extends Annotation