APIdia Launch Partner
Top Description Fields Constructors Methods
com.sun.tools.javac.code

public Class SymbolMetadata

extends Object
Class Inheritance
Imports
com.sun.tools.javac.code.Attribute.TypeCompound, .Kinds.Kind, com.sun.tools.javac.util.Assert, .List, .ListBuffer, .Pair

Container for all annotations (attributes in javac) on a Symbol. This class is explicitly mutable. Its contents will change when attributes are annotated onto the Symbol. However this class depends on the facts that List (in javac) is immutable. An instance of this class can be in one of three states: NOT_STARTED indicates that the Symbol this instance belongs to has not been annotated (yet). Specifically if the declaration is not annotated this instance will never move past NOT_STARTED. You can never go back to NOT_STARTED. IN_PROGRESS annotations have been found on the declaration. Will be processed later. You can reset to IN_PROGRESS. While IN_PROGRESS you can set the list of attributes (and this moves out of the IN_PROGRESS state). "unnamed" this SymbolMetadata contains some attributes, possibly the final set. While in this state you can only prepend or append to the attributes not set it directly. You can also move back to the IN_PROGRESS state using reset().

This is NOT part of any supported API. If you write code that depends on this, you do so at your own risk. This code and its internal interfaces are subject to change or deletion without notice.

Field Summary

Modifier and TypeField and Description
private List<Attribute.Compound>
private List<Attribute.TypeCompound>
private static final List<Attribute.Compound>
private static final List<Attribute.Compound>
private List<Attribute.TypeCompound>
private final Symbol
private List<Attribute.TypeCompound>

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public SymbolMetadata
public SymbolMetadata
public SymbolMetadata
public SymbolMetadata
private List<Attribute.Compound>
public List<Attribute.TypeCompound>
public List<Attribute.Compound>
public List<Attribute.TypeCompound>
public List<Attribute.TypeCompound>
public boolean
private boolean
public boolean
public boolean
public SymbolMetadata
public void
private List<Attribute.Compound>
public SymbolMetadata
public void
public void
public void
public void
public void
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

attributesback to summary
private List<Attribute.Compound> attributes
clinit_type_attributesback to summary
private List<Attribute.TypeCompound> clinit_type_attributes
DECL_IN_PROGRESSback to summary
private static final List<Attribute.Compound> DECL_IN_PROGRESS
DECL_NOT_STARTEDback to summary
private static final List<Attribute.Compound> DECL_NOT_STARTED
init_type_attributesback to summary
private List<Attribute.TypeCompound> init_type_attributes
symback to summary
private final Symbol sym
type_attributesback to summary
private List<Attribute.TypeCompound> type_attributes

Constructor Detail

SymbolMetadataback to summary
public SymbolMetadata(Symbol sym)

Method Detail

appendback to summary
public SymbolMetadata append(List<Attribute.Compound> l)
appendClassInitTypeAttributesback to summary
public SymbolMetadata appendClassInitTypeAttributes(List<Attribute.TypeCompound> l)
appendInitTypeAttributesback to summary
public SymbolMetadata appendInitTypeAttributes(List<Attribute.TypeCompound> l)
appendUniqueTypesback to summary
public SymbolMetadata appendUniqueTypes(List<Attribute.TypeCompound> l)
filterDeclSentinelsback to summary
private List<Attribute.Compound> filterDeclSentinels(List<Attribute.Compound> a)
getClassInitTypeAttributesback to summary
public List<Attribute.TypeCompound> getClassInitTypeAttributes()
getDeclarationAttributesback to summary
public List<Attribute.Compound> getDeclarationAttributes()
getInitTypeAttributesback to summary
public List<Attribute.TypeCompound> getInitTypeAttributes()
getTypeAttributesback to summary
public List<Attribute.TypeCompound> getTypeAttributes()
isEmptyback to summary
public boolean isEmpty()
isStartedback to summary
private boolean isStarted()
isTypesEmptyback to summary
public boolean isTypesEmpty()
pendingCompletionback to summary
public boolean pendingCompletion()
prependback to summary
public SymbolMetadata prepend(List<Attribute.Compound> l)
removeDeclarationMetadataback to summary
public void removeDeclarationMetadata(Attribute.Compound compound)
removeFromCompoundListback to summary
private List<Attribute.Compound> removeFromCompoundList(List<Attribute.Compound> l, Attribute.Compound compound)
resetback to summary
public SymbolMetadata reset()
setAttributesback to summary
public void setAttributes(SymbolMetadata other)
setClassInitTypeAttributesback to summary
public void setClassInitTypeAttributes(List<Attribute.TypeCompound> a)
setDeclarationAttributesback to summary
public void setDeclarationAttributes(List<Attribute.Compound> a)
setInitTypeAttributesback to summary
public void setInitTypeAttributes(List<Attribute.TypeCompound> a)
setTypeAttributesback to summary
public void setTypeAttributes(List<Attribute.TypeCompound> a)