15
15
import java .util .SortedMap ;
16
16
import java .util .TreeMap ;
17
17
import javax .swing .tree .DefaultMutableTreeNode ;
18
- import org .freeinternals .biv .ui .dex .TreeNodeGenerator ;
19
18
import org .freeinternals .commonlib .core .FileComponent ;
20
19
import org .freeinternals .commonlib .core .FileFormat ;
21
20
import org .freeinternals .commonlib .core .PosByteArrayInputStream ;
22
21
import org .freeinternals .commonlib .core .PosDataInputStream ;
23
22
import org .freeinternals .commonlib .core .BytesTool ;
24
23
import org .freeinternals .commonlib .core .FileFormatException ;
25
- import org .freeinternals .format .dex .HeaderItem .Endian ;
24
+ import org .freeinternals .format .dex .header_item .Endian ;
26
25
27
26
/**
28
27
*
@@ -67,17 +66,16 @@ public class DexFile extends FileFormat {
67
66
/**
68
67
* The file header.
69
68
*/
70
- public HeaderItem header ;
69
+ public header_item header ;
71
70
/**
72
- * String identifiers list, or <code>null</code> if
73
- * {@link HeaderItem#string_ids_off} is <code>0</code>.
71
+ * String identifiers list, or <code>null{@link header_item#string_ids_off} is <code>0
74
72
*/
75
- public StringIdItem [] string_ids ;
76
- public TypeIdItem [] type_ids ;
77
- public ProtoIdItem [] proto_ids ;
78
- public FieldIdItem [] field_ids ;
79
- public MethodIdItem [] method_ids ;
80
- public ClassDefItem [] class_defs ;
73
+ public string_id_item [] string_ids ;
74
+ public type_id_item [] type_ids ;
75
+ public proto_id_item [] proto_ids ;
76
+ public field_id_item [] field_ids ;
77
+ public method_id_item [] method_ids ;
78
+ public class_def_item [] class_defs ;
81
79
// public Dex_ubyte[] data;
82
80
/**
83
81
* The parsed file components.
@@ -172,16 +170,16 @@ private void parse() throws IOException, FileFormatException {
172
170
// Header
173
171
BytesTool .skip (stream , DEX_FILE_MAGIC1 .size ());
174
172
BytesTool .skip (stream , DEX_FILE_MAGIC2 .size ());
175
- this .header = new HeaderItem (stream );
173
+ this .header = new header_item (stream );
176
174
177
175
// string_ids
178
176
if (this .header .string_ids_off .intValue () == 0 ) {
179
177
this .string_ids = null ;
180
178
} else {
181
179
stream .flyTo (this .header .string_ids_off .intValue ());
182
- this .string_ids = new StringIdItem [this .header .string_ids_size .intValue ()];
180
+ this .string_ids = new string_id_item [this .header .string_ids_size .intValue ()];
183
181
for (int i = 0 ; i < this .string_ids .length ; i ++) {
184
- this .string_ids [i ] = new StringIdItem (stream );
182
+ this .string_ids [i ] = new string_id_item (stream );
185
183
todoData .put (this .string_ids [i ].string_data_off .value , StringDataItem .class );
186
184
}
187
185
}
@@ -191,9 +189,9 @@ private void parse() throws IOException, FileFormatException {
191
189
this .type_ids = null ;
192
190
} else {
193
191
stream .flyTo (this .header .type_ids_off .intValue ());
194
- this .type_ids = new TypeIdItem [this .header .type_ids_size .intValue ()];
192
+ this .type_ids = new type_id_item [this .header .type_ids_size .intValue ()];
195
193
for (int i = 0 ; i < this .type_ids .length ; i ++) {
196
- this .type_ids [i ] = new TypeIdItem (stream );
194
+ this .type_ids [i ] = new type_id_item (stream );
197
195
}
198
196
}
199
197
@@ -202,9 +200,9 @@ private void parse() throws IOException, FileFormatException {
202
200
this .proto_ids = null ;
203
201
} else {
204
202
stream .flyTo (this .header .proto_ids_off .intValue ());
205
- this .proto_ids = new ProtoIdItem [this .header .proto_ids_size .intValue ()];
203
+ this .proto_ids = new proto_id_item [this .header .proto_ids_size .intValue ()];
206
204
for (int i = 0 ; i < this .proto_ids .length ; i ++) {
207
- this .proto_ids [i ] = new ProtoIdItem (stream );
205
+ this .proto_ids [i ] = new proto_id_item (stream );
208
206
}
209
207
}
210
208
@@ -213,9 +211,9 @@ private void parse() throws IOException, FileFormatException {
213
211
this .field_ids = null ;
214
212
} else {
215
213
stream .flyTo (this .header .field_ids_off .intValue ());
216
- this .field_ids = new FieldIdItem [this .header .field_ids_size .intValue ()];
214
+ this .field_ids = new field_id_item [this .header .field_ids_size .intValue ()];
217
215
for (int i = 0 ; i < this .field_ids .length ; i ++) {
218
- this .field_ids [i ] = new FieldIdItem (stream );
216
+ this .field_ids [i ] = new field_id_item (stream );
219
217
}
220
218
}
221
219
@@ -224,9 +222,9 @@ private void parse() throws IOException, FileFormatException {
224
222
this .method_ids = null ;
225
223
} else {
226
224
stream .flyTo (this .header .method_ids_off .intValue ());
227
- this .method_ids = new MethodIdItem [this .header .method_ids_size .intValue ()];
225
+ this .method_ids = new method_id_item [this .header .method_ids_size .intValue ()];
228
226
for (int i = 0 ; i < this .method_ids .length ; i ++) {
229
- this .method_ids [i ] = new MethodIdItem (stream );
227
+ this .method_ids [i ] = new method_id_item (stream );
230
228
}
231
229
}
232
230
@@ -235,9 +233,9 @@ private void parse() throws IOException, FileFormatException {
235
233
this .class_defs = null ;
236
234
} else {
237
235
stream .flyTo (this .header .class_defs_off .intValue ());
238
- this .class_defs = new ClassDefItem [this .header .class_defs_size .intValue ()];
236
+ this .class_defs = new class_def_item [this .header .class_defs_size .intValue ()];
239
237
for (int i = 0 ; i < this .class_defs .length ; i ++) {
240
- this .class_defs [i ] = new ClassDefItem (stream );
238
+ this .class_defs [i ] = new class_def_item (stream );
241
239
}
242
240
}
243
241
0 commit comments