📄 annotatable.java
字号:
// $Id: Annotatable.java,v 1.5 2000/10/10 15:47:49 mdeeds Exp $package java6035.tools.IR;import java.util.Enumeration;/** * annotations are <tag,value> pairs we can attach to things. You * may find this useful for attaching line numbers, or optimizatin * information to your IR tree. **/public interface Annotatable{ /** * Add the annotation @param(data) associated with the tag * @param(tag) **/ public void annotate(int tag, Object data); /** * Return the value associated with @param(tag). If there is no * anotation (data) associated with @param(tag) the behavior of * this function is undefined. It is most likely that it will be * null though. **/ public Object getAnnotation(int tag); /** * Remove the association between @param(tag) and whatever it * is currently associated with. **/ public Object removeAnnotation(int tag); /** * Returns an Enumeration of all the tags which are associated * with values for this object. The values returned by the * Enumeration should be in the form of Integer objects. **/ public Enumeration listTags(); /** * Returns an Enumeration of all the annotations (data) which have * associated tags for this object. The values returned by the * Enumeration are the Objects which were passed in via * setAnnotation. They are not clones. **/ public Enumeration listAnnotations();}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -