本文整理匯總了Java中org.jf.dexlib.EncodedValue.AnnotationEncodedSubValue類的典型用法代碼示例。如果您正苦於以下問題:Java AnnotationEncodedSubValue類的具體用法?Java AnnotationEncodedSubValue怎麽用?Java AnnotationEncodedSubValue使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
AnnotationEncodedSubValue類屬於org.jf.dexlib.EncodedValue包,在下文中一共展示了AnnotationEncodedSubValue類的7個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: AnnotationItem
import org.jf.dexlib.EncodedValue.AnnotationEncodedSubValue; //導入依賴的package包/類
/**
* Creates a new <code>AnnotationItem</code> with the given values
* @param dexFile The <code>DexFile</code> that this item belongs to
* @param visibility The visibility of this annotation
* @param annotationValue The value of this annotation
*/
private AnnotationItem(DexFile dexFile, AnnotationVisibility visibility,
AnnotationEncodedSubValue annotationValue) {
super(dexFile);
this.visibility = visibility;
this.annotationValue = annotationValue;
}
示例2: writeTo
import org.jf.dexlib.EncodedValue.AnnotationEncodedSubValue; //導入依賴的package包/類
public static void writeTo(IndentingWriter writer, AnnotationEncodedSubValue encodedAnnotation)
throws IOException {
writer.write(".subannotation ");
ReferenceFormatter.writeTypeReference(writer, encodedAnnotation.annotationType);
writer.write('\n');
writeElementsTo(writer, encodedAnnotation);
writer.write(".end subannotation");
}
示例3: writeElementsTo
import org.jf.dexlib.EncodedValue.AnnotationEncodedSubValue; //導入依賴的package包/類
public static void writeElementsTo(IndentingWriter writer, AnnotationEncodedSubValue encodedAnnotation)
throws IOException {
writer.indent(4);
for (int i=0; i<encodedAnnotation.names.length; i++) {
writer.write(encodedAnnotation.names[i].getStringValue());
writer.write(" = ");
EncodedValueAdaptor.writeTo(writer, encodedAnnotation.values[i]);
writer.write('\n');
}
writer.deindent(4);
}
示例4: readItem
import org.jf.dexlib.EncodedValue.AnnotationEncodedSubValue; //導入依賴的package包/類
/** {@inheritDoc} */
protected void readItem(Input in, ReadContext readContext) {
visibility = AnnotationVisibility.fromByte(in.readByte());
annotationValue = new AnnotationEncodedSubValue(dexFile, in);
}
示例5: getEncodedAnnotation
import org.jf.dexlib.EncodedValue.AnnotationEncodedSubValue; //導入依賴的package包/類
/**
* @return The encoded annotation value of this annotation
*/
public AnnotationEncodedSubValue getEncodedAnnotation() {
return annotationValue;
}
示例6: internAnnotationItem
import org.jf.dexlib.EncodedValue.AnnotationEncodedSubValue; //導入依賴的package包/類
/**
* Returns an <code>AnnotationItem</code> for the given values, and that has been interned into the given
* <code>DexFile</code>
* @param dexFile The <code>DexFile</code> that this item belongs to
* @param visibility The visibility of this annotation
* @param annotationValue The value of this annotation
* @return an <code>AnnotationItem</code> for the given values, and that has been interned into the given
* <code>DexFile</code>
*/
public static AnnotationItem internAnnotationItem(DexFile dexFile, AnnotationVisibility visibility,
AnnotationEncodedSubValue annotationValue) {
AnnotationItem annotationItem = new AnnotationItem(dexFile, visibility, annotationValue);
return dexFile.AnnotationsSection.intern(annotationItem);
}
示例7: getInternedAnnotationItem
import org.jf.dexlib.EncodedValue.AnnotationEncodedSubValue; //導入依賴的package包/類
/**
* Returns an <code>AnnotationItem</code> for the given values, and that has been interned into the given
* <code>DexFile</code>
* @param dexFile The <code>DexFile</code> that this item belongs to
* @param visibility The visibility of this annotation
* @param annotationValue The value of this annotation
* @return an <code>AnnotationItem</code> for the given values, and that has been interned into the given
* <code>DexFile</code>
*/
public static AnnotationItem getInternedAnnotationItem(DexFile dexFile, AnnotationVisibility visibility,
AnnotationEncodedSubValue annotationValue) {
AnnotationItem annotationItem = new AnnotationItem(dexFile, visibility, annotationValue);
return dexFile.AnnotationsSection.intern(annotationItem);
}