1 /* 2 * Copyright (c) 2001, 2003, Oracle and/or its affiliates. All rights reserved. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * This code is free software; you can redistribute it and/or modify it 6 * under the terms of the GNU General Public License version 2 only, as 7 * published by the Free Software Foundation. 8 * 9 * This code is distributed in the hope that it will be useful, but WITHOUT 10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 12 * version 2 for more details (a copy is included in the LICENSE file that 13 * accompanied this code). 14 * 15 * You should have received a copy of the GNU General Public License version 16 * 2 along with this work; if not, write to the Free Software Foundation, 17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 18 * 19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 20 * or visit www.oracle.com if you need additional information or have any 21 * questions. 22 */ 23 24 package pkg; 25 26 import java.lang.*; 27 import java.io.*; 28 29 public class TestTagInheritence extends TestAbstractClass implements TestInterface{ 30 31 //This method below tests tag inheritence from a class. 32 33 34 public String testAbstractClass_method1(int p1, int p2) throws java.io.IOException, 35 java.lang.NullPointerException { 36 return null; 37 } 38 39 /** 40 * This method tests @inheritDoc with a class. Here is the inherited comment:<br> 41 * {@inheritDoc} 42 * @param p1 {@inheritDoc} 43 * @param p2 {@inheritDoc} 44 * @return {@inheritDoc} 45 * @throws java.io.IOException {@inheritDoc} 46 * @throws java.lang.NullPointerException {@inheritDoc} 47 */ 48 public String testAbstractClass_method2(int p1, int p2) throws java.io.IOException, 49 java.lang.NullPointerException { 50 return null; 51 } 52 53 public String testInterface_method1(int p1, int p2) throws java.io.IOException, 54 java.lang.NullPointerException 55 { 56 return null; 57 } 58 59 /** 60 * This method tests @inheritDoc with an inteface. Here is the inherited comment:<br> 61 * {@inheritDoc} 62 * @param p1 {@inheritDoc} 63 * @param p2 {@inheritDoc} 64 * @return {@inheritDoc} 65 * @throws java.io.IOException {@inheritDoc} 66 * @throws java.lang.NullPointerException {@inheritDoc} 67 */ 68 public String testInterface_method2(int p1, int p2) throws java.io.IOException, 69 java.lang.NullPointerException { 70 return null; 71 } 72 73 /** 74 * Here is the documentation that I should inherit from 75 * the interface implemented by my superclass. 76 * {@inheritDoc} 77 */ 78 public void methodInTestInterfaceForAbstractClass() {} 79 80 /** 81 * {@inheritDoc} 82 */ 83 public void testSuperSuperMethod() {} 84 85 /** 86 * Test inheritDoc warning message: 87 * {@inheritDoc} 88 */ 89 public void testBadInheritDocTag () {} 90 91 /** 92 * {@inheritDoc} 93 * @param <X> {@inheritDoc} 94 * @param <Y> {@inheritDoc} 95 * @param p1 {@inheritDoc} 96 * @param p2 {@inheritDoc} 97 * @return {@inheritDoc} 98 * @throws java.io.IOException {@inheritDoc} 99 * @throws java.lang.NullPointerException {@inheritDoc} 100 */ 101 public <X,Y> String testSuperSuperMethod(int p1, int p2) { 102 return null; 103 } 104 105 public <X,Y> String testSuperSuperMethod2(int p1, int p2) 106 throws java.io.IOException, java.lang.NullPointerException { 107 return null; 108 } 109 110 }