io.appmetrica.gradle.aarcheck.api.parser.Parser.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of aar-check Show documentation
Show all versions of aar-check Show documentation
Provides plugin for check aar
The newest version!
package io.appmetrica.gradle.aarcheck.api.parser
import io.appmetrica.gradle.aarcheck.api.Class
import io.appmetrica.gradle.aarcheck.utils.extractEntry
import java.io.File
import java.util.jar.JarFile
import java.util.zip.ZipFile
abstract class Parser {
abstract fun parseJar(jarFile: JarFile): List
open fun parseJar(jarFile: File): List {
return JarFile(jarFile).use(::parseJar)
}
open fun parseAar(aarFile: File): List {
return ZipFile(aarFile).use { zipFile ->
parseJar(zipFile.extractEntry("classes.jar"))
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy