/** * Returns a <code>StringIdItem</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 will belong to * @param stringValue The string value that this item represents * @return a <code>StringIdItem</code> for the given values, and that has been interned into * the given <code>DexFile</code> */ public static StringIdItem internStringIdItem(DexFile dexFile, String stringValue) { StringDataItem stringDataItem = StringDataItem.internStringDataItem(dexFile, stringValue); if (stringDataItem == null) { return null; } StringIdItem stringIdItem = new StringIdItem(dexFile, stringDataItem); return dexFile.StringIdsSection.intern(stringIdItem); }
/** * Returns a <code>StringIdItem</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 will belong to * @param stringValue The string value that this item represents * @return a <code>StringIdItem</code> for the given values, and that has been interned into * the given <code>DexFile</code> */ public static StringIdItem internStringIdItem(DexFile dexFile, String stringValue) { StringDataItem stringDataItem = StringDataItem.internStringDataItem(dexFile, stringValue); if (stringDataItem == null) { return null; } StringIdItem stringIdItem = new StringIdItem(dexFile, stringDataItem); return dexFile.StringIdsSection.intern(stringIdItem); }