Let's consider the following code:
class UseCase() {
suspend operator fun invoke(param1: String) = Unit
}
Common Running Time | |
There are some common running times when analyzing an algorithm: | |
O(1) – Constant Time Constant time means the running time is constant, it’s not affected by the input size. | |
O(n) – Linear Time When an algorithm accepts n input size, it would perform n operations as well. | |
O(log n) – Logarithmic Time Algorithm that has running time O(log n) is slight faster than O(n). Commonly, algorithm divides the problem into sub problems with the same size. Example: binary search algorithm, binary conversion algorithm. |
// Add into root project, make sure you have Gradle Enterprise plugin | |
val buildScanApi = project.extensions.findByName("buildScan") as BuildScanExtension | |
subprojects { | |
// If you want to limit it to certain module(s), wrap it with: if (name == "module-name") { } | |
val fingerprinter = serviceOf<org.gradle.internal.fingerprint.classpath.ClasspathFingerprinter>() | |
tasks.withType(org.jetbrains.kotlin.gradle.dsl.KotlinCompile::class.java).configureEach task@{ | |
doFirst { | |
var classLoader: ClassLoader = [email protected] | |
while (classLoader is java.net.URLClassLoader) { | |
val fingerprints = mutableSetOf<Array<String>>() |