Home
last modified time | relevance | path

Searched refs:sourceFile (Results 1 – 22 of 22) sorted by relevance

/tools/metalava/metalava-model-turbine/src/main/java/com/android/tools/metalava/model/turbine/
DTurbineFileLocation.kt33 private val sourceFile: TurbineSourceFile, constant in com.android.tools.metalava.model.turbine.TurbineFileLocation
39 get() = sourceFile.path
42 get() = sourceFile.lineForPosition(position)
50 fun forTree(sourceFile: TurbineSourceFile?): FileLocation { in forTree()
51 sourceFile ?: return UNKNOWN in forTree()
52 return createLocation(sourceFile.path) in forTree()
56 fun forTree(sourceFile: TurbineSourceFile, tree: Tree?): FileLocation { in forTree()
57 tree ?: return forTree(sourceFile) in forTree()
58 return TurbineFileLocation(sourceFile, tree.position()) in forTree()
66 val sourceFile = classItem.sourceFile() as? TurbineSourceFile ?: return UNKNOWN in forTree() constant
[all …]
DTurbineAnnotationFactory.kt69 ?.let { sourceFile -> sourceFileCache.turbineSourceFile(sourceFile) } in <lambda>() method
70 ?.let { sourceFile -> TurbineFileLocation.forTree(sourceFile, tree) } in <lambda>() method
DTurbineSourceFileCache.kt46 internal fun turbineSourceFile(sourceFile: SourceFile): TurbineSourceFile = in <lambda>()
47 turbineSourceFiles.computeIfAbsent(sourceFile.path()) { path -> in <lambda>()
DTurbineClassBuilder.kt133 val sourceFile = in <lambda>() constant
139 sourceFile != null -> TurbineFileLocation.forTree(sourceFile, decl) in <lambda>()
192 source = sourceFile, in <lambda>()
/tools/metalava/metalava-model-psi/src/test/java/com/android/tools/metalava/model/psi/
DPsiMethodItemTest.kt59 val sourceFile = in method return type is non-null() constant
68 runCodebaseTest(sourceFile) { in method return type is non-null()
93 val sourceFile = in child method does not need to be added to signature file if super method is concrete() constant
106 runCodebaseTest(sourceFile) { in child method does not need to be added to signature file if super method is concrete()
118 val sourceFile = in child method only needs to be added to signature file if all multiple direct super methods requires override() constant
134 runCodebaseTest(sourceFile) { in child method only needs to be added to signature file if all multiple direct super methods requires override()
146 val sourceFile = in child method does not need to be added to signature file if override requiring super method is hidden() constant
163 runCodebaseTest(sourceFile) { in child method does not need to be added to signature file if override requiring super method is hidden()
171 val sourceFile = in child method need to be added to signature file if extending Object method and return type changes() constant
180 runCodebaseTest(sourceFile) { in child method need to be added to signature file if extending Object method and return type changes()
[all …]
DPsiParameterItemTest.kt89 val actualFile = codebase.assertClass("ActualKt").sourceFile() in actuals get params from expects()
107 assertEquals(actualFile, classItem.sourceFile()) in actuals get params from expects()
/tools/metalava/metalava-model-testsuite/src/main/java/com/android/tools/metalava/model/testsuite/sourcefile/
DCommonSourceFileTest.kt103 val sourceFile = classItem.sourceFile()!! in test() constant
119 val allImports = sourceFile.getImports() in test()
126 val notHiddenImports = sourceFile.getImports(FilterHidden()) in test()
152 val sourceFile = classItem.sourceFile()!! in test sourcefile imports from classpath() constant
156 val allImports = sourceFile.getImports() in test sourcefile imports from classpath()
191 val sourceFile = classItem.sourceFile()!! in test sourcefile classes() constant
193 assertEquals(listOf(classItem, outerClassItem), sourceFile.classes().toList()) in test sourcefile classes()
/tools/metalava/metalava/src/main/java/com/android/tools/metalava/stub/
DStubWriter.kt77 val sourceFile = File(getPackageDir(pkg), "overview.html") in writeDocOverview() constant
80 PrintWriter(BufferedWriter(FileWriter(sourceFile))) in writeDocOverview()
82 reporter.report(Issues.IO_ERROR, sourceFile, "Cannot open file for write.") in writeDocOverview()
100 val sourceFile = File(getPackageDir(pkg), "package-info.java") in writePackageInfo() constant
103 PrintWriter(BufferedWriter(FileWriter(sourceFile))) in writePackageInfo()
105 reporter.report(Issues.IO_ERROR, sourceFile, "Cannot open file for write.") in writePackageInfo()
184 val sourceFile = getClassFile(cls) in visitClass() constant
187 PrintWriter(BufferedWriter(FileWriter(sourceFile))) in visitClass()
189 reporter.report(Issues.IO_ERROR, sourceFile, "Cannot open file for write.") in visitClass()
209 cls.sourceFile()?.getHeaderComments()?.let { textWriter.println(it) } in visitClass()
DJavaStubWriter.kt55 cls.sourceFile()?.getImports()?.let { in <lambda>()
/tools/metalava/metalava/src/test/java/com/android/tools/metalava/compatibility/
DFastPathTest.kt84 sourceFile: TestFile, in checkFastPath()
98 val sourceFiles = arrayOf(sourceFile) in checkFastPath()
143 sourceFile = java(SOURCE_FILE_CONTENTS), in Check fast path taken()
154 sourceFile = java(SOURCE_FILE_CONTENTS), in Check fast path not taken()
164 sourceFile = java(SOURCE_FILE_CONTENTS), in Check fast path taken for removed()
176 sourceFile = java(SOURCE_FILE_CONTENTS), in Check fast path not taken for removed()
/tools/tradefederation/core/src/com/android/tradefed/targetprep/
DGsiDeviceFlashPreparer.java340 ITestDevice device, String requestedFileName, File sourceFile, File tmpDir) in getRequestedFile() argument
343 if (sourceFile.getName().endsWith(".zip")) { in getRequestedFile()
346 FileUtil.createTempDir(FileUtil.getBaseName(sourceFile.getName()), tmpDir); in getRequestedFile()
347 ZipUtil2.extractZip(sourceFile, destDir); in getRequestedFile()
351 String.format("Fail to get %s from %s", requestedFileName, sourceFile), in getRequestedFile()
355 } else if (sourceFile.isDirectory()) { in getRequestedFile()
356 requestedFile = FileUtil.findFile(sourceFile, requestedFileName); in getRequestedFile()
358 requestedFile = sourceFile; in getRequestedFile()
364 requestedFileName, sourceFile), in getRequestedFile()
DGkiDeviceFlashPreparer.java883 ITestDevice device, String requestedFileName, File sourceFile, File tmpDir) in getRequestedFile() argument
889 if (sourceFile.getName().endsWith(".zip")) { in getRequestedFile()
890 try (ZipFile sourceZipFile = new ZipFile(sourceFile)) { in getRequestedFile()
893 tmpDir, FileUtil.getBaseName(sourceFile.getName()) + "_zip"); in getRequestedFile()
917 String.format("Fail to get %s from %s", requestedFileName, sourceFile), in getRequestedFile()
921 } else if (sourceFile.isDirectory()) { in getRequestedFile()
922 requestedFile = FileUtil.findFile(sourceFile, requestedFileName); in getRequestedFile()
924 requestedFile = sourceFile; in getRequestedFile()
930 requestedFileName, sourceFile), in getRequestedFile()
/tools/metalava/metalava-model-testsuite/src/main/java/com/android/tools/metalava/model/testsuite/
DBootstrapSourceModelProviderTest.kt909 val sourceFile = classItem.sourceFile()!! in 240 test documentations() constant
931 sourceFile, in 240 test documentations()
932 innerClassItem.sourceFile(), in 240 test documentations()
935 assertEquals(headerComment, sourceFile.getHeaderComments()) in 240 test documentations()
941 assertEquals(classItem.sourceFile(), classItem1.sourceFile()) in 240 test documentations()
/tools/treble/hacksaw/workspace/
Dcopier.go195 sourceFile, err := os.Open(sourcePath)
199 defer sourceFile.Close()
207 _, err = io.Copy(destFile, sourceFile)
/tools/tradefederation/core/javatests/com/android/tradefed/device/metric/
DBaseDeviceMetricCollectorTest.java612 File sourceFile = FileUtil.createTempFile(fileName, null, hostTestCasesDir); in testResolveRelativeFilePath_withDeviceBuildInfo() local
614 fileName = sourceFile.getName(); in testResolveRelativeFilePath_withDeviceBuildInfo()
623 sourceFile.getAbsolutePath(), in testResolveRelativeFilePath_withDeviceBuildInfo()
647 File sourceFile = FileUtil.createTempFile(fileName, null, hostTestCasesDir); in testUnableResolveRelativeFilePath_withDeviceBuildInfo() local
649 fileName = sourceFile.getName(); in testUnableResolveRelativeFilePath_withDeviceBuildInfo()
659 sourceFile.getAbsolutePath(), in testUnableResolveRelativeFilePath_withDeviceBuildInfo()
683 File sourceFile = FileUtil.createTempFile(fileName, null, hostTestCasesDir); in testResolveRelativeFilePath_fromModule() local
685 fileName = sourceFile.getName(); in testResolveRelativeFilePath_fromModule()
695 sourceFile.getAbsolutePath(), in testResolveRelativeFilePath_fromModule()
/tools/metalava/metalava-model-psi/src/main/java/com/android/tools/metalava/model/psi/
DPsiClassItem.kt82 override fun sourceFile(): SourceFile? { in psi() method
85 return containingClass()?.sourceFile() in psi()
/tools/tradefederation/core/javatests/com/android/tradefed/targetprep/
DPushFilePreparerTest.java324 File sourceFile = FileUtil.createTempFile(fileName, null, hostTestCasesDir); in testResolveRelativeFilePath_withDeviceBuildInfo() local
326 fileName = sourceFile.getName(); in testResolveRelativeFilePath_withDeviceBuildInfo()
332 sourceFile.getAbsolutePath(), in testResolveRelativeFilePath_withDeviceBuildInfo()
357 File sourceFile = FileUtil.createTempFile(fileName, null, hostTestCasesDir); in testResolveRelativeFilePath_withDeviceBuildInfo_remoteZip() local
360 fileName = sourceFile.getName() + "-2"; in testResolveRelativeFilePath_withDeviceBuildInfo_remoteZip()
365 .thenReturn(sourceFile); in testResolveRelativeFilePath_withDeviceBuildInfo_remoteZip()
368 sourceFile.getAbsolutePath(), in testResolveRelativeFilePath_withDeviceBuildInfo_remoteZip()
/tools/metalava/metalava-model/src/main/java/com/android/tools/metalava/model/item/
DDefaultClassItem.kt101 override fun sourceFile() = source ?: containingClass?.sourceFile() in <lambda>() method
/tools/metalava/metalava-model/src/main/java/com/android/tools/metalava/model/visitors/
DFilteringApiVisitor.kt195 override fun sourceFile() = delegate.sourceFile()?.let { FilteringSourceFile(it) } in <lambda>() method
/tools/tradefederation/core/common_util/com/android/tradefed/util/
DFileUtil.java645 public static String readStringFromFile(File sourceFile) throws IOException { in readStringFromFile() argument
646 return readStringFromFile(sourceFile, 0, 0); in readStringFromFile()
658 public static String readStringFromFile(File sourceFile, long startOffset, long length) in readStringFromFile() argument
660 try (FileInputStream is = new FileInputStream(sourceFile)) { in readStringFromFile()
664 long fileLength = sourceFile.length(); in readStringFromFile()
/tools/metalava/metalava-model/src/main/java/com/android/tools/metalava/model/
DClassItem.kt454 fun sourceFile(): SourceFile? in <lambda>() method
/tools/metalava/metalava-model/src/main/java/com/android/tools/metalava/model/snapshot/
DCodebaseSnapshotTaker.kt230 source = cls.sourceFile(), in <lambda>()