Lines Matching refs:index

32      * >= -1; the constant pool index for {@link #constant}, or
35 private int index;
38 * >= -1; the constant pool index for the class reference in
45 * initially unknown (<code>-1</code>) as is the constant pool index.
63 this.index = -1;
73 if (index >= 0) {
74 result.setIndex(index);
90 if (index >= 0) {
91 result.setIndex(index);
111 * Gets the constant's index. It is only valid to call this after
114 * @return &gt;= 0; the constant pool index
117 if (index < 0) {
118 throw new RuntimeException("index not yet set for " + constant);
121 return index;
125 * Returns whether the constant's index has been set for this instance.
129 * @return <code>true</code> iff the index has been set
132 return (index >= 0);
136 * Sets the constant's index. It is only valid to call this method once
139 * @param index &gt;= 0; the constant pool index
141 public void setIndex(int index) {
142 if (index < 0) {
143 throw new IllegalArgumentException("index < 0");
146 if (this.index >= 0) {
147 throw new RuntimeException("index already set");
150 this.index = index;
154 * Gets the constant's class index. It is only valid to call this after
157 * @return &gt;= 0; the constant's class's constant pool index
161 throw new RuntimeException("class index not yet set");
168 * Returns whether the constant's class index has been set for this
173 * @return <code>true</code> iff the index has been set
180 * Sets the constant's class index. This is the constant pool index
186 * @param index &gt;= 0; the constant's class's constant pool index
188 public void setClassIndex(int index) {
189 if (index < 0) {
190 throw new IllegalArgumentException("index < 0");
194 throw new RuntimeException("class index already set");
197 this.classIndex = index;