< prev index next >

src/jdk.compiler/share/classes/com/sun/tools/javac/util/Name.java

Print this page

        

*** 23,34 **** * questions. */ package com.sun.tools.javac.util; - import com.sun.tools.javac.jvm.ClassFile; - import com.sun.tools.javac.jvm.PoolConstant; import com.sun.tools.javac.util.DefinedBy.Api; /** An abstraction for internal compiler strings. They are stored in * Utf8 format. Names are stored in a Name.Table, and are unique within * that table. --- 23,32 ----
*** 36,46 **** * <p><b>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.</b> */ ! public abstract class Name implements javax.lang.model.element.Name, PoolConstant { public final Table table; protected Name(Table table) { this.table = table; --- 34,44 ---- * <p><b>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.</b> */ ! public abstract class Name implements javax.lang.model.element.Name { public final Table table; protected Name(Table table) { this.table = table;
*** 52,66 **** @DefinedBy(Api.LANGUAGE_MODEL) public boolean contentEquals(CharSequence cs) { return toString().equals(cs.toString()); } - @Override - public int poolTag() { - return ClassFile.CONSTANT_Utf8; - } - /** * {@inheritDoc} */ public int length() { return toString().length(); --- 50,59 ----
*** 193,210 **** /** Get the start offset of this name within its byte array. */ public abstract int getByteOffset(); - public interface NameMapper<X> { - X map(byte[] bytes, int offset, int len); - } - - public <X> X map(NameMapper<X> mapper) { - return mapper.map(getByteArray(), getByteOffset(), getByteLength()); - } - /** An abstraction for the hash table used to create unique Name instances. */ public static abstract class Table { /** Standard name table. */ --- 186,195 ----
< prev index next >