Path: blob/aarch64-shenandoah-jdk8u272-b10/langtools/src/share/classes/com/sun/javadoc/ExecutableMemberDoc.java
38890 views
/*1* Copyright (c) 1998, 2013, Oracle and/or its affiliates. All rights reserved.2* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.3*4* This code is free software; you can redistribute it and/or modify it5* under the terms of the GNU General Public License version 2 only, as6* published by the Free Software Foundation. Oracle designates this7* particular file as subject to the "Classpath" exception as provided8* by Oracle in the LICENSE file that accompanied this code.9*10* This code is distributed in the hope that it will be useful, but WITHOUT11* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or12* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License13* version 2 for more details (a copy is included in the LICENSE file that14* accompanied this code).15*16* You should have received a copy of the GNU General Public License version17* 2 along with this work; if not, write to the Free Software Foundation,18* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.19*20* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA21* or visit www.oracle.com if you need additional information or have any22* questions.23*/2425package com.sun.javadoc;2627/**28* Represents a method or constructor of a java class.29*30* @since 1.231* @author Robert Field32*/33public interface ExecutableMemberDoc extends MemberDoc {3435/**36* Return exceptions this method or constructor throws.37* If the type of the exception is a type variable, return the38* <code>ClassDoc</code> of its erasure.39*40* <p> <i>The <code>thrownExceptions</code> method cannot41* accommodate certain generic type constructs. The42* <code>thrownExceptionTypes</code> method should be used43* instead.</i>44*45* @return an array of ClassDoc[] representing the exceptions46* thrown by this method.47* @see #thrownExceptionTypes48*/49ClassDoc[] thrownExceptions();5051/**52* Return exceptions this method or constructor throws.53*54* @return an array representing the exceptions thrown by this method.55* Each array element is either a <code>ClassDoc</code> or a56* <code>TypeVariable</code>.57* @since 1.558*/59Type[] thrownExceptionTypes();6061/**62* Return true if this method is native63*/64boolean isNative();6566/**67* Return true if this method is synchronized68*/69boolean isSynchronized();7071/**72* Return true if this method was declared to take a variable number73* of arguments.74*75* @since 1.576*/77public boolean isVarArgs();7879/**80* Get argument information.81*82* @see Parameter83*84* @return an array of Parameter, one element per argument85* in the order the arguments are present.86*/87Parameter[] parameters();8889/**90* Get the receiver type of this executable element.91*92* @return the receiver type of this executable element.93* @since 1.894*/95Type receiverType();9697/**98* Return the throws tags in this method.99*100* @return an array of ThrowTag containing all <code>@exception</code>101* and <code>@throws</code> tags.102*/103ThrowsTag[] throwsTags();104105/**106* Return the param tags in this method, excluding the type107* parameter tags.108*109* @return an array of ParamTag containing all <code>@param</code> tags110* corresponding to the parameters of this method.111*/112ParamTag[] paramTags();113114/**115* Return the type parameter tags in this method.116*117* @return an array of ParamTag containing all <code>@param</code> tags118* corresponding to the type parameters of this method.119* @since 1.5120*/121ParamTag[] typeParamTags();122123/**124* Get the signature. It is the parameter list, type is qualified.125* For instance, for a method <code>mymethod(String x, int y)</code>,126* it will return <code>(java.lang.String,int)</code>.127*/128String signature();129130/**131* get flat signature. all types are not qualified.132* return a String, which is the flat signiture of this member.133* It is the parameter list, type is not qualified.134* For instance, for a method <code>mymethod(String x, int y)</code>,135* it will return <code>(String, int)</code>.136*/137String flatSignature();138139/**140* Return the formal type parameters of this method or constructor.141* Return an empty array if this method or constructor is not generic.142*143* @return the formal type parameters of this method or constructor.144* @since 1.5145*/146TypeVariable[] typeParameters();147}148149150