Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Modifiers | Name | Description |
---|---|---|
static int |
ANNOTATION_TARGET |
|
static int |
CONSTRUCTOR_TARGET |
|
static int |
FIELD_TARGET |
|
static int |
LOCAL_VARIABLE_TARGET |
|
static int |
METHOD_TARGET |
|
static int |
PACKAGE_TARGET |
|
static int |
PARAMETER_TARGET |
|
static int |
TYPE_TARGET |
Constructor and description |
---|
AnnotationNode
(ClassNode classNode) |
Type | Name and description |
---|---|
void |
addMember(String name, Expression value) |
ClassNode |
getClassNode() |
Expression |
getMember(String name) |
Map<String, Expression> |
getMembers() |
boolean |
hasClassRetention() Flag corresponding to RetentionPolicy.CLASS . |
boolean |
hasRuntimeRetention() Flag corresponding to RetentionPolicy . |
boolean |
hasSourceRetention() Flag corresponding to RetentionPolicy.SOURCE . |
boolean |
isBuiltIn() |
boolean |
isTargetAllowed(int target) |
void |
setAllowedTargets(int bitmap) |
void |
setClassRetention(boolean flag) Sets the internal flag if the current annotation has RetentionPolicy.CLASS . |
void |
setMember(String name, Expression value) |
void |
setRuntimeRetention(boolean flag) Sets the internal flag of this annotation runtime retention policy. |
void |
setSourceRetention(boolean flag) Sets the internal flag if the current annotation has RetentionPolicy.SOURCE . |
static String |
targetToName(int target) |
Methods inherited from class | Name |
---|---|
class ASTNode |
copyNodeMetaData, getColumnNumber, getLastColumnNumber, getLastLineNumber, getLineNumber, getNodeMetaData, getNodeMetaData, getText, putNodeMetaData, removeNodeMetaData, setColumnNumber, setLastColumnNumber, setLastLineNumber, setLineNumber, setNodeMetaData, setSourcePosition, visit |
class Object |
wait, wait, wait, equals, toString, hashCode, getClass, notify, notifyAll |
Flag corresponding to RetentionPolicy.CLASS
.
Flag corresponding to RetentionPolicy
.
Flag corresponding to RetentionPolicy.SOURCE
.
Sets the internal flag if the current annotation has
RetentionPolicy.CLASS
.
Sets the internal flag of this annotation runtime retention policy.
If the current annotation has
RetentionPolicy.RUNTIME
or if false
if the RetentionPolicy.CLASS
.
flag
- if true then current annotation is marked as having
RetentionPolicy.RUNTIME
. If false then
the annotation has RetentionPolicy.CLASS
. Sets the internal flag if the current annotation has
RetentionPolicy.SOURCE
.
Copyright © 2003-2015 The Apache Software Foundation. All rights reserved.