src/share/classes/com/sun/tools/doclets/internal/toolkit/taglets/BasePropertyTaglet.java

Tue, 18 Jun 2013 20:56:04 -0700

author
mfang
date
Tue, 18 Jun 2013 20:56:04 -0700
changeset 1841
792c40d5185a
parent 1751
ca8808c88f94
child 2525
2eb010b6cb22
permissions
-rw-r--r--

8015657: jdk8 l10n resource file translation update 3
Reviewed-by: yhuang

jjg@1606 1 /*
jjg@1606 2 * Copyright (c) 2001, 2013, Oracle and/or its affiliates. All rights reserved.
jjg@1606 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
jjg@1606 4 *
jjg@1606 5 * This code is free software; you can redistribute it and/or modify it
jjg@1606 6 * under the terms of the GNU General Public License version 2 only, as
jjg@1606 7 * published by the Free Software Foundation. Oracle designates this
jjg@1606 8 * particular file as subject to the "Classpath" exception as provided
jjg@1606 9 * by Oracle in the LICENSE file that accompanied this code.
jjg@1606 10 *
jjg@1606 11 * This code is distributed in the hope that it will be useful, but WITHOUT
jjg@1606 12 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
jjg@1606 13 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
jjg@1606 14 * version 2 for more details (a copy is included in the LICENSE file that
jjg@1606 15 * accompanied this code).
jjg@1606 16 *
jjg@1606 17 * You should have received a copy of the GNU General Public License version
jjg@1606 18 * 2 along with this work; if not, write to the Free Software Foundation,
jjg@1606 19 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
jjg@1606 20 *
jjg@1606 21 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
jjg@1606 22 * or visit www.oracle.com if you need additional information or have any
jjg@1606 23 * questions.
jjg@1606 24 */
jjg@1606 25
jjg@1606 26 package com.sun.tools.doclets.internal.toolkit.taglets;
jjg@1606 27
jjg@1606 28 import com.sun.javadoc.Tag;
jjg@1751 29 import com.sun.tools.doclets.internal.toolkit.Content;
jjg@1606 30
jjg@1606 31 /**
jjg@1606 32 * An abstract class that implements the {@link Taglet} interface and
jjg@1606 33 * serves as a base for JavaFX property getter and setter taglets.
jjg@1606 34 *
jjg@1606 35 * <p><b>This is NOT part of any supported API.
jjg@1606 36 * If you write code that depends on this, you do so at your own risk.
jjg@1606 37 * This code and its internal interfaces are subject to change or
jjg@1606 38 * deletion without notice.</b>
jjg@1606 39 *
jjg@1606 40 */
jjg@1606 41 public abstract class BasePropertyTaglet extends BaseTaglet {
jjg@1606 42
jjg@1606 43 public BasePropertyTaglet() {
jjg@1606 44 }
jjg@1606 45
jjg@1606 46 /**
jjg@1606 47 * This method returns the text to be put in the resulting javadoc before
jjg@1606 48 * the property name.
jjg@1606 49 *
jjg@1606 50 * @param tagletWriter the taglet writer for output
jjg@1606 51 * @return the string to be put in the resulting javadoc.
jjg@1606 52 */
jjg@1606 53 abstract String getText(TagletWriter tagletWriter);
jjg@1606 54
jjg@1606 55 /**
jjg@1606 56 * Given the <code>Tag</code> representation of this custom
jjg@1606 57 * tag, return its string representation, which is output
jjg@1606 58 * to the generated page.
jjg@1606 59 * @param tag the <code>Tag</code> representation of this custom tag.
jjg@1606 60 * @param tagletWriter the taglet writer for output.
jjg@1606 61 * @return the TagletOutput representation of this <code>Tag</code>.
jjg@1606 62 */
jjg@1751 63 public Content getTagletOutput(Tag tag, TagletWriter tagletWriter) {
jjg@1749 64 return tagletWriter.propertyTagOutput(tag, getText(tagletWriter));
jjg@1606 65 }
jjg@1606 66
jjg@1606 67 /**
jjg@1606 68 * Will return false because this tag may
jjg@1606 69 * only appear in Methods.
jjg@1606 70 * @return false since this is not a method.
jjg@1606 71 */
jjg@1606 72 public boolean inConstructor() {
jjg@1606 73 return false;
jjg@1606 74 }
jjg@1606 75
jjg@1606 76 /**
jjg@1606 77 * Will return false because this tag may
jjg@1606 78 * only appear in Methods.
jjg@1606 79 * @return false since this is not a method.
jjg@1606 80 */
jjg@1606 81 public boolean inOverview() {
jjg@1606 82 return false;
jjg@1606 83 }
jjg@1606 84
jjg@1606 85 /**
jjg@1606 86 * Will return false because this tag may
jjg@1606 87 * only appear in Methods.
jjg@1606 88 * @return false since this is not a method.
jjg@1606 89 */
jjg@1606 90 public boolean inPackage() {
jjg@1606 91 return false;
jjg@1606 92 }
jjg@1606 93
jjg@1606 94 /**
jjg@1606 95 * Will return false because this tag may
jjg@1606 96 * only appear in Methods.
jjg@1606 97 * @return false since this is not a method.
jjg@1606 98 */
jjg@1606 99 public boolean inType() {
jjg@1606 100 return false;
jjg@1606 101 }
jjg@1606 102
jjg@1606 103 /**
jjg@1606 104 * Will return false because this tag is not inline.
jjg@1606 105 * @return false since this is not an inline tag.
jjg@1606 106 */
jjg@1606 107 public boolean isInlineTag() {
jjg@1606 108 return false;
jjg@1606 109 }
jjg@1606 110
jjg@1606 111 }

mercurial