Home
last modified time | relevance | path

Searched refs:file (Results 1 – 25 of 326) sorted by relevance

12345678910>>...14

/dalvik/dexgen/src/com/android/dexgen/util/
DFileUtils.java42 File file = new File(fileName); in readFile() local
43 return readFile(file); in readFile()
53 public static byte[] readFile(File file) { in readFile() argument
54 if (!file.exists()) { in readFile()
55 throw new RuntimeException(file + ": file not found"); in readFile()
58 if (!file.isFile()) { in readFile()
59 throw new RuntimeException(file + ": not a file"); in readFile()
62 if (!file.canRead()) { in readFile()
63 throw new RuntimeException(file + ": file not readable"); in readFile()
66 long longLength = file.length(); in readFile()
[all …]
/dalvik/dx/src/com/android/dx/dex/file/
DHeaderItem.java17 package com.android.dx.dex.file;
50 public void addContents(DexFile file) { in addContents() argument
56 public void writeTo(DexFile file, AnnotatedOutput out) { in writeTo() argument
57 int mapOff = file.getMap().getFileOffset(); in writeTo()
58 Section firstDataSection = file.getFirstDataSection(); in writeTo()
59 Section lastDataSection = file.getLastDataSection(); in writeTo()
64 String magic = file.getDexOptions().getMagic(); in writeTo()
71 Hex.u4(file.getFileSize())); in writeTo()
87 out.writeInt(file.getFileSize()); in writeTo()
100 file.getStringIds().writeHeaderPart(out); in writeTo()
[all …]
DFieldIdItem.java17 package com.android.dx.dex.file;
42 public void addContents(DexFile file) { in addContents() argument
43 super.addContents(file); in addContents()
45 TypeIdsSection typeIds = file.getTypeIds(); in addContents()
60 protected int getTypoidIdx(DexFile file) { in getTypoidIdx() argument
61 TypeIdsSection typeIds = file.getTypeIds(); in getTypoidIdx()
DMethodIdItem.java17 package com.android.dx.dex.file;
42 public void addContents(DexFile file) { in addContents() argument
43 super.addContents(file); in addContents()
45 ProtoIdsSection protoIds = file.getProtoIds(); in addContents()
60 protected int getTypoidIdx(DexFile file) { in getTypoidIdx() argument
61 ProtoIdsSection protoIds = file.getProtoIds(); in getTypoidIdx()
DMemberIdItem.java17 package com.android.dx.dex.file;
52 public void addContents(DexFile file) { in addContents() argument
53 super.addContents(file); in addContents()
55 StringIdsSection stringIds = file.getStringIds(); in addContents()
61 public final void writeTo(DexFile file, AnnotatedOutput out) { in writeTo() argument
62 TypeIdsSection typeIds = file.getTypeIds(); in writeTo()
63 StringIdsSection stringIds = file.getStringIds(); in writeTo()
67 int typoidIdx = getTypoidIdx(file); in writeTo()
90 protected abstract int getTypoidIdx(DexFile file); in getTypoidIdx() argument
DUniformItemSection.java17 package com.android.dx.dex.file;
38 public UniformItemSection(String name, DexFile file, int alignment) { in UniformItemSection() argument
39 super(name, file, alignment); in UniformItemSection()
70 DexFile file = getFile(); in prepare0() local
75 one.addContents(file); in prepare0()
82 DexFile file = getFile(); in writeTo0() local
86 one.writeTo(file, out); in writeTo0()
DDebugInfoItem.java17 package com.android.dx.dex.file;
63 public void addContents(DexFile file) { in addContents() argument
97 public void annotateTo(DexFile file, AnnotatedOutput out, String prefix) { in annotateTo() argument
98 encode(file, prefix, null, out, false); in annotateTo()
113 protected void writeTo0(DexFile file, AnnotatedOutput out) { in writeTo0() argument
121 encode(file, null, null, out, true); in writeTo0()
139 private byte[] encode(DexFile file, String prefix, PrintWriter debugPrint, in encode() argument
141 byte[] result = encode0(file, prefix, debugPrint, out, consume); in encode()
143 if (ENABLE_ENCODER_SELF_CHECK && (file != null)) { in encode()
145 DebugInfoDecoder.validateEncode(result, file, ref, code, in encode()
[all …]
DSection.java17 package com.android.dx.dex.file;
31 private final DexFile file; field in Section
68 public Section(String name, DexFile file, int alignment) { in Section() argument
69 if (file == null) { in Section()
76 this.file = file; in Section()
88 return file; in getFile()
DClassDataItem.java17 package com.android.dx.dex.file;
225 public void addContents(DexFile file) { in addContents() argument
229 field.addContents(file); in addContents()
236 field.addContents(file); in addContents()
243 method.addContents(file); in addContents()
250 method.addContents(file); in addContents()
339 private void encodeOutput(DexFile file, AnnotatedOutput out) { in encodeOutput() argument
347 encodeSize(file, out, "static_fields", staticFields.size()); in encodeOutput()
348 encodeSize(file, out, "instance_fields", instanceFields.size()); in encodeOutput()
349 encodeSize(file, out, "direct_methods", directMethods.size()); in encodeOutput()
[all …]
DItem.java17 package com.android.dx.dex.file;
67 public abstract void addContents(DexFile file); in addContents() argument
79 public abstract void writeTo(DexFile file, AnnotatedOutput out); in writeTo() argument
/dalvik/dexgen/src/com/android/dexgen/dex/file/
DHeaderItem.java17 package com.android.dexgen.dex.file;
60 public void addContents(DexFile file) { in addContents() argument
66 public void writeTo(DexFile file, AnnotatedOutput out) { in writeTo() argument
67 int mapOff = file.getMap().getFileOffset(); in writeTo()
68 Section firstDataSection = file.getFirstDataSection(); in writeTo()
69 Section lastDataSection = file.getLastDataSection(); in writeTo()
79 Hex.u4(file.getFileSize())); in writeTo()
95 out.writeInt(file.getFileSize()); in writeTo()
108 file.getStringIds().writeHeaderPart(out); in writeTo()
109 file.getTypeIds().writeHeaderPart(out); in writeTo()
[all …]
DMethodIdItem.java17 package com.android.dexgen.dex.file;
42 public void addContents(DexFile file) { in addContents() argument
43 super.addContents(file); in addContents()
45 ProtoIdsSection protoIds = file.getProtoIds(); in addContents()
60 protected int getTypoidIdx(DexFile file) { in getTypoidIdx() argument
61 ProtoIdsSection protoIds = file.getProtoIds(); in getTypoidIdx()
DFieldIdItem.java17 package com.android.dexgen.dex.file;
42 public void addContents(DexFile file) { in addContents() argument
43 super.addContents(file); in addContents()
45 TypeIdsSection typeIds = file.getTypeIds(); in addContents()
60 protected int getTypoidIdx(DexFile file) { in getTypoidIdx() argument
61 TypeIdsSection typeIds = file.getTypeIds(); in getTypoidIdx()
DMemberIdItem.java17 package com.android.dexgen.dex.file;
54 public void addContents(DexFile file) { in addContents() argument
55 super.addContents(file); in addContents()
57 StringIdsSection stringIds = file.getStringIds(); in addContents()
63 public final void writeTo(DexFile file, AnnotatedOutput out) { in writeTo() argument
64 TypeIdsSection typeIds = file.getTypeIds(); in writeTo()
65 StringIdsSection stringIds = file.getStringIds(); in writeTo()
69 int typoidIdx = getTypoidIdx(file); in writeTo()
92 protected abstract int getTypoidIdx(DexFile file); in getTypoidIdx() argument
DUniformItemSection.java17 package com.android.dexgen.dex.file;
39 public UniformItemSection(String name, DexFile file, int alignment) { in UniformItemSection() argument
40 super(name, file, alignment); in UniformItemSection()
71 DexFile file = getFile(); in prepare0() local
76 one.addContents(file); in prepare0()
83 DexFile file = getFile(); in writeTo0() local
87 one.writeTo(file, out); in writeTo0()
DDebugInfoItem.java17 package com.android.dexgen.dex.file;
66 public void addContents(DexFile file) { in addContents() argument
100 public void annotateTo(DexFile file, AnnotatedOutput out, String prefix) { in annotateTo() argument
101 encode(file, prefix, null, out, false); in annotateTo()
116 protected void writeTo0(DexFile file, AnnotatedOutput out) { in writeTo0() argument
124 encode(file, null, null, out, true); in writeTo0()
142 private byte[] encode(DexFile file, String prefix, PrintWriter debugPrint, in encode() argument
144 byte[] result = encode0(file, prefix, debugPrint, out, consume); in encode()
146 if (ENABLE_ENCODER_SELF_CHECK && (file != null)) { in encode()
148 DebugInfoDecoder.validateEncode(result, file, ref, code, in encode()
[all …]
DSection.java17 package com.android.dexgen.dex.file;
32 private final DexFile file; field in Section
69 public Section(String name, DexFile file, int alignment) { in Section() argument
70 if (file == null) { in Section()
77 this.file = file; in Section()
89 return file; in getFile()
DClassDataItem.java17 package com.android.dexgen.dex.file;
229 public void addContents(DexFile file) { in addContents() argument
233 field.addContents(file); in addContents()
240 field.addContents(file); in addContents()
247 method.addContents(file); in addContents()
254 method.addContents(file); in addContents()
343 private void encodeOutput(DexFile file, AnnotatedOutput out) { in encodeOutput() argument
351 encodeSize(file, out, "static_fields", staticFields.size()); in encodeOutput()
352 encodeSize(file, out, "instance_fields", instanceFields.size()); in encodeOutput()
353 encodeSize(file, out, "direct_methods", directMethods.size()); in encodeOutput()
[all …]
DMemberIdsSection.java17 package com.android.dexgen.dex.file;
30 public MemberIdsSection(String name, DexFile file) { in MemberIdsSection() argument
31 super(name, file, 4); in MemberIdsSection()
DTypeIdItem.java17 package com.android.dexgen.dex.file;
54 public void addContents(DexFile file) { in addContents() argument
55 file.getStringIds().intern(getDefiningClass().getDescriptor()); in addContents()
60 public void writeTo(DexFile file, AnnotatedOutput out) { in writeTo() argument
63 int idx = file.getStringIds().indexOf(descriptor); in writeTo()
DItem.java17 package com.android.dexgen.dex.file;
67 public abstract void addContents(DexFile file); in addContents() argument
79 public abstract void writeTo(DexFile file, AnnotatedOutput out); in writeTo() argument
/dalvik/dx/tests/131-perf/
DClassGen.java25 for (int file = start; file <= end; file++) { in main()
27 File f = new File("src/Clazz" + file + ".java"); in main()
29 pw.println("class Clazz" + file + " {"); in main()
34 pw.println(" boolean m" + method + "_" + (file%(end/2)) + "() {" in main()
39 + file + ".class + \".method" + method in main()
40 + "() \" + Clazz" + (end-file+1) + ".f1);"); in main()
/dalvik/dx/src/com/android/dx/cf/direct/
DClassPathOpener.java83 void onProcessArchiveStart(File file); in onProcessArchiveStart() argument
142 File file = new File(pathname); in process() local
144 return processOne(file, true); in process()
155 private boolean processOne(File file, boolean topLevel) { in processOne() argument
157 if (file.isDirectory()) { in processOne()
158 return processDirectory(file, topLevel); in processOne()
161 String path = file.getPath(); in processOne()
166 return processArchive(file); in processOne()
169 byte[] bytes = FileUtils.readFile(file); in processOne()
170 return consumer.processFileBytes(path, file.lastModified(), bytes); in processOne()
[all …]
/dalvik/dx/src/com/android/multidex/
DFolderPathElement.java54 for (File file : folder.listFiles()) { in collect()
55 if (file.isDirectory()) { in collect()
56 collect(file, prefix + SEPARATOR_CHAR + file.getName(), result); in collect()
58 result.add(prefix + SEPARATOR_CHAR + file.getName()); in collect()
DPath.java35 static ClassPathElement getClassPathElement(File file) in getClassPathElement() argument
37 if (file.isDirectory()) { in getClassPathElement()
38 return new FolderPathElement(file); in getClassPathElement()
39 } else if (file.isFile()) { in getClassPathElement()
40 return new ArchivePathElement(new ZipFile(file)); in getClassPathElement()
41 } else if (file.exists()) { in getClassPathElement()
42 throw new IOException("\"" + file.getPath() + in getClassPathElement()
45 throw new FileNotFoundException("File \"" + file.getPath() + "\" not found"); in getClassPathElement()

12345678910>>...14