commit stringlengths 40 40 | old_file stringlengths 4 236 | new_file stringlengths 4 236 | old_contents stringlengths 1 3.26k | new_contents stringlengths 16 4.43k | subject stringlengths 16 624 | message stringlengths 17 3.29k | lang stringclasses 5
values | license stringclasses 13
values | repos stringlengths 5 91.5k |
|---|---|---|---|---|---|---|---|---|---|
c0b285fb8e1617eda7cc4550ce7b90ca0ef2d289 | meshui/src/main/java/io/particle/mesh/ui/setup/ScanCommissionerCodeFragment.kt | meshui/src/main/java/io/particle/mesh/ui/setup/ScanCommissionerCodeFragment.kt | package io.particle.mesh.ui.setup
import androidx.fragment.app.FragmentActivity
import com.squareup.phrase.Phrase
import io.particle.android.sdk.cloud.ParticleCloudSDK
import io.particle.mesh.setup.BarcodeData.CompleteBarcodeData
import io.particle.mesh.setup.flow.FlowRunnerUiListener
import io.particle.mesh.ui.R
impo... | package io.particle.mesh.ui.setup
import androidx.fragment.app.FragmentActivity
import com.squareup.phrase.Phrase
import io.particle.android.sdk.cloud.ParticleCloudSDK
import io.particle.mesh.setup.BarcodeData.CompleteBarcodeData
import io.particle.mesh.setup.flow.FlowRunnerUiListener
import io.particle.mesh.ui.R
impo... | Remove unnecessary code for formatting these strings now that they're static | Remove unnecessary code for formatting these strings now that they're static
| Kotlin | apache-2.0 | spark/photon-tinker-android,spark/photon-tinker-android |
64bee71e255b0e0f5359bf63fd4b8e26408b613c | subprojects/integ-test/integ-test.gradle.kts | subprojects/integ-test/integ-test.gradle.kts | import org.gradle.gradlebuild.test.integrationtests.IntegrationTest
import org.gradle.gradlebuild.testing.integrationtests.cleanup.WhenNotEmpty
import org.gradle.gradlebuild.unittestandcompile.ModuleType
plugins {
gradlebuild.classycle
}
repositories {
mavenLocal()
}
dependencies {
integTestCompile(libra... | import org.gradle.gradlebuild.test.integrationtests.IntegrationTest
import org.gradle.gradlebuild.testing.integrationtests.cleanup.WhenNotEmpty
import org.gradle.gradlebuild.unittestandcompile.ModuleType
plugins {
gradlebuild.classycle
}
dependencies {
integTestCompile(library("groovy"))
integTestCompile(... | Remove usage of `mavenLocal()` from `:integTest` | Remove usage of `mavenLocal()` from `:integTest`
| Kotlin | apache-2.0 | blindpirate/gradle,gradle/gradle,robinverduijn/gradle,robinverduijn/gradle,blindpirate/gradle,robinverduijn/gradle,gradle/gradle,gradle/gradle,robinverduijn/gradle,blindpirate/gradle,robinverduijn/gradle,robinverduijn/gradle,robinverduijn/gradle,gradle/gradle,blindpirate/gradle,robinverduijn/gradle,blindpirate/gradle,g... |
584a35aee0cea57e939e83fd86b5a58240c15846 | models/src/main/java/com/vimeo/networking2/FeaturesConfiguration.kt | models/src/main/java/com/vimeo/networking2/FeaturesConfiguration.kt | package com.vimeo.networking2
/**
* Based on CAPABILITY_PLATFORM_CONFIGS_OTA_FEATURES.
*/
data class FeaturesConfiguration(
/**
* The Chromecast receiver app ID.
*/
val chromecastAppId: String?,
/**
* Is Comscore enabled for iOS?
*/
val comscore: Boolean?,
/**
* Does t... | package com.vimeo.networking2
/**
* Based on CAPABILITY_PLATFORM_CONFIGS_OTA_FEATURES.
*/
data class FeaturesConfiguration(
/**
* The Chromecast receiver app ID.
*/
val chromecastAppId: String?,
/**
* Is Comscore enabled?
*/
val comscore: Boolean?,
/**
* Does the user ... | Add play tracking enabled field to feature config | Add play tracking enabled field to feature config
| Kotlin | mit | vimeo/vimeo-networking-java,vimeo/vimeo-networking-java,vimeo/vimeo-networking-java |
6e568247a13d29f9a795d337c6e613f20e42a72c | backend.native/tests/stdlib_external/utils.kt | backend.native/tests/stdlib_external/utils.kt | /*
* Copyright 2010-2018 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license
* that can be found in the LICENSE file.
*/
package test
import kotlin.test.*
public actual fun assertTypeEquals(expected: Any?, actual: Any?) {
if (expected != null && actual != null) {
assertEqual... | /*
* Copyright 2010-2018 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license
* that can be found in the LICENSE file.
*/
package test
import kotlin.test.*
public actual fun assertTypeEquals(expected: Any?, actual: Any?) {
if (expected != null && actual != null) {
assertTrue(... | Fix assertTypeEquals to check subtypes | Fix assertTypeEquals to check subtypes
| Kotlin | apache-2.0 | JetBrains/kotlin-native,JetBrains/kotlin-native,JetBrains/kotlin-native,JetBrains/kotlin-native,JetBrains/kotlin-native,wiltonlazary/kotlin-native,wiltonlazary/kotlin-native,wiltonlazary/kotlin-native,JetBrains/kotlin-native,wiltonlazary/kotlin-native,JetBrains/kotlin-native,JetBrains/kotlin-native,JetBrains/kotlin-nat... |
5a8a5d35cfcf91312acbbd5177671a240474c3dd | src/main/kotlin/me/elsiff/morefish/fishing/FishType.kt | src/main/kotlin/me/elsiff/morefish/fishing/FishType.kt | package me.elsiff.morefish.fishing
import me.elsiff.morefish.announcement.PlayerAnnouncement
import me.elsiff.morefish.fishing.catchhandler.CatchHandler
import me.elsiff.morefish.fishing.condition.FishCondition
import org.bukkit.inventory.ItemStack
import kotlin.math.floor
import kotlin.random.Random
/**
* Created b... | package me.elsiff.morefish.fishing
import me.elsiff.morefish.announcement.PlayerAnnouncement
import me.elsiff.morefish.fishing.catchhandler.CatchHandler
import me.elsiff.morefish.fishing.condition.FishCondition
import org.bukkit.inventory.ItemStack
import kotlin.math.floor
import kotlin.math.max
import kotlin.math.min... | Change the way to calculate length on generating fish | Change the way to calculate length on generating fish
This change is for fish having special length like 3.14.
| Kotlin | mit | elsiff/MoreFish |
e247e0bcdae8efd2485195ab6253eebe87161dd7 | settings.gradle.kts | settings.gradle.kts | // Require Java 10 or higher
val javaVersion = JavaVersion.current()
require(javaVersion.isJava10Compatible) {
"The JUnit 5 build requires Java 10 or higher. Currently executing with Java ${javaVersion.majorVersion}."
}
rootProject.name = "junit5"
include("documentation")
include("junit-jupiter-api")
include("junit-... | // Require Java 10 or higher
val javaVersion = JavaVersion.current()
require(javaVersion.isJava10Compatible) {
"The JUnit 5 build requires Java 10 or higher. Currently executing with Java ${javaVersion.majorVersion}."
}
rootProject.name = "junit5"
include("documentation")
include("junit-jupiter-api")
include("junit-... | Enable use of Kotlin DSL for subproject build scripts | Enable use of Kotlin DSL for subproject build scripts
| Kotlin | epl-1.0 | sbrannen/junit-lambda,junit-team/junit-lambda |
6142f5996021eb7199f520bdeb5243321edd65f9 | integration-tests/gradle/projects/it-multiplatform-0/build.gradle.kts | integration-tests/gradle/projects/it-multiplatform-0/build.gradle.kts | import org.jetbrains.dokka.gradle.DokkaTask
plugins {
kotlin("multiplatform")
id("org.jetbrains.dokka")
}
apply(from = "../template.root.gradle.kts")
kotlin {
jvm()
linuxX64("linux")
macosX64("macos")
sourceSets {
named("commonMain") {
dependencies {
implem... | import org.jetbrains.dokka.gradle.DokkaTask
plugins {
kotlin("multiplatform")
id("org.jetbrains.dokka")
}
apply(from = "../template.root.gradle.kts")
kotlin {
jvm()
linuxX64("linux")
macosX64("macos")
js()
sourceSets {
named("commonMain") {
dependencies {
... | Add js target back to Multiplatform0GradleIntegrationTest | Add js target back to Multiplatform0GradleIntegrationTest
| Kotlin | apache-2.0 | Kotlin/dokka,Kotlin/dokka,Kotlin/dokka,Kotlin/dokka,Kotlin/dokka,Kotlin/dokka |
659aff7e8db35668b2fca94ebb6cafd0942a6eda | kotlin-eclipse-ui/src/org/jetbrains/kotlin/wizards/WizardType.kt | kotlin-eclipse-ui/src/org/jetbrains/kotlin/wizards/WizardType.kt | /*******************************************************************************
* Copyright 2000-2014 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.a... | /*******************************************************************************
* Copyright 2000-2014 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.a... | Fix creation of enum class by wizard | Fix creation of enum class by wizard
#KT-14170 Fixed
| Kotlin | apache-2.0 | noemus/kotlin-eclipse,noemus/kotlin-eclipse |
e393bbc3a6cd9ec19a331593ef527864c328979c | app/src/main/java/org/stepik/android/view/course/mapper/DisplayPriceMapper.kt | app/src/main/java/org/stepik/android/view/course/mapper/DisplayPriceMapper.kt | package org.stepik.android.view.course.mapper
import android.content.Context
import org.stepic.droid.R
import javax.inject.Inject
class DisplayPriceMapper
@Inject
constructor(
private val context: Context
) {
companion object {
private const val RUB_FORMAT = "RUB"
private const val USD_FORMAT ... | package org.stepik.android.view.course.mapper
import android.content.Context
import org.stepic.droid.R
import javax.inject.Inject
class DisplayPriceMapper
@Inject
constructor(
private val context: Context
) {
companion object {
private const val RUB_FORMAT = "RUB"
private const val USD_FORMAT ... | Trim trailing zeroes in display prices | Trim trailing zeroes in display prices
| Kotlin | apache-2.0 | StepicOrg/stepic-android,StepicOrg/stepik-android,StepicOrg/stepik-android,StepicOrg/stepic-android,StepicOrg/stepik-android,StepicOrg/stepic-android |
4152ee0ff189b752cd520c3968def11a2336ee7b | droidbox/src/main/java/com/github/jackparisi/droidbox/binding/ViewAdapters.kt | droidbox/src/main/java/com/github/jackparisi/droidbox/binding/ViewAdapters.kt | package com.github.jackparisi.droidbox.binding
import android.databinding.BindingAdapter
import android.graphics.Rect
import android.util.Base64
import android.view.MotionEvent
import android.view.View
import android.view.animation.Animation
import android.view.animation.LinearInterpolator
import android.view.animatio... | package com.github.jackparisi.droidbox.binding
import android.databinding.BindingAdapter
import android.view.View
/**
* Created by Giacomo Parisi on 02/07/2017.
* https://github.com/JackParisi
*/
/**
* Update the visibility of te view status VISIBLE/GONE based on boolean value
*
* @param view The view that ne... | Add docs for viewAdapter + methods refactor | Add docs for viewAdapter + methods refactor
| Kotlin | apache-2.0 | JackParisi/DroidBox |
7e7dba7b6cf6982c49d904672d425b1959c9fa25 | pydroid/src/main/java/com/pyamsoft/pydroid/about/AboutLibrariesPresenter.kt | pydroid/src/main/java/com/pyamsoft/pydroid/about/AboutLibrariesPresenter.kt | /*
* Copyright 2017 Peter Kenji Yamanaka
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or a... | /*
* Copyright 2017 Peter Kenji Yamanaka
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or a... | Change presenter method to inline | Change presenter method to inline
| Kotlin | apache-2.0 | pyamsoft/pydroid |
7c56b96b85ce704d54322a043dd7fd6a13b2f01e | desktop/src/main/kotlin/com/seventh_root/guildfordgamejam/desktop/DesktopLauncher.kt | desktop/src/main/kotlin/com/seventh_root/guildfordgamejam/desktop/DesktopLauncher.kt | package com.seventh_root.guildfordgamejam.desktop
import com.badlogic.gdx.backends.lwjgl.LwjglApplication
import com.badlogic.gdx.backends.lwjgl.LwjglApplicationConfiguration
import com.seventh_root.guildfordgamejam.GuildfordGameJam
fun main(arg: Array<String>) {
val config = LwjglApplicationConfiguration()
c... | package com.seventh_root.guildfordgamejam.desktop
import com.badlogic.gdx.backends.lwjgl.LwjglApplication
import com.badlogic.gdx.backends.lwjgl.LwjglApplicationConfiguration
import com.seventh_root.guildfordgamejam.GuildfordGameJam
import java.awt.GraphicsEnvironment
fun main(arg: Array<String>) {
val config = L... | Make game start in full screen mode | Make game start in full screen mode
| Kotlin | apache-2.0 | alyphen/guildford-game-jam-2016 |
e68fb9c0b3bd3a765abdc3299f793baa6c493eb4 | src/lang-xpath/main/uk/co/reecedunn/intellij/plugin/xpath/lang/refactoring/XPathRefactoringSupportProvider.kt | src/lang-xpath/main/uk/co/reecedunn/intellij/plugin/xpath/lang/refactoring/XPathRefactoringSupportProvider.kt | /*
* Copyright (C) 2021 Reece H. Dunn
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed t... | /*
* Copyright (C) 2021 Reece H. Dunn
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed t... | Use VariableInplaceRenameHandler for XpmVariableDefinition elements. | Use VariableInplaceRenameHandler for XpmVariableDefinition elements.
| Kotlin | apache-2.0 | rhdunn/xquery-intellij-plugin,rhdunn/xquery-intellij-plugin |
8e3f0b516896cd8148409d713a8cbe4cd2bddacd | bridgesample/src/main/java/com/livefront/bridgesample/app/BridgeSampleApplication.kt | bridgesample/src/main/java/com/livefront/bridgesample/app/BridgeSampleApplication.kt | package com.livefront.bridgesample.app
import android.app.Application
import android.os.Bundle
import com.evernote.android.state.StateSaver
import com.livefront.bridge.Bridge
import com.livefront.bridge.SavedStateHandler
class BridgeSampleApplication : Application() {
override fun onCreate() {
super.onCre... | package com.livefront.bridgesample.app
import android.app.Application
import android.os.Bundle
import android.os.Parcelable
import android.view.View
import com.evernote.android.state.StateSaver
import com.livefront.bridge.Bridge
import com.livefront.bridge.SavedStateHandler
import com.livefront.bridge.ViewSavedStateHa... | Allow the sample app to save the state of Views | Allow the sample app to save the state of Views
| Kotlin | apache-2.0 | livefront/bridge,livefront/bridge |
8d4f9f09408fc74fa8617dc3eea9ae0b488af817 | languageExtensions/OrchidWritersBlocks/src/test/kotlin/com/eden/orchid/writersblocks/tags/SpotifyTagTest.kt | languageExtensions/OrchidWritersBlocks/src/test/kotlin/com/eden/orchid/writersblocks/tags/SpotifyTagTest.kt | package com.eden.orchid.writersblocks.tags
import com.eden.orchid.impl.generators.HomepageGenerator
import com.eden.orchid.strikt.asHtml
import com.eden.orchid.strikt.innerHtmlMatches
import com.eden.orchid.strikt.pageWasRendered
import com.eden.orchid.strikt.select
import com.eden.orchid.testhelpers.OrchidIntegrati... | package com.eden.orchid.writersblocks.tags
import com.eden.orchid.impl.generators.HomepageGenerator
import com.eden.orchid.testhelpers.OrchidIntegrationTest
import com.eden.orchid.testhelpers.TestGeneratorModule
import com.eden.orchid.testhelpers.pageWasRendered
import com.eden.orchid.writersblocks.WritersBlocksModule... | Update PR to be based off master | Update PR to be based off master
| Kotlin | mit | JavaEden/Orchid-Core,JavaEden/Orchid-Core |
ef1c2cec41d65bccb39613c9141f47d517f5ba03 | data/src/main/java/com/edreams/android/workshops/kotlin/data/venues/remote/ExploreVenuesNetController.kt | data/src/main/java/com/edreams/android/workshops/kotlin/data/venues/remote/ExploreVenuesNetController.kt | package com.edreams.android.workshops.kotlin.data.venues.remote
import com.edreams.android.workshops.kotlin.data.common.remote.FoursquareService
import com.edreams.android.workshops.kotlin.data.venues.remote.response.VenueResponse
import javax.inject.Inject
import javax.inject.Singleton
private const val RESULTS_LIMI... | package com.edreams.android.workshops.kotlin.data.venues.remote
import com.edreams.android.workshops.kotlin.data.common.remote.FoursquareService
import com.edreams.android.workshops.kotlin.data.venues.remote.response.VenueResponse
import retrofit2.HttpException
import java.io.IOException
import javax.inject.Inject
imp... | Handle exception on net controller when api request fails | Handle exception on net controller when api request fails
| Kotlin | apache-2.0 | nico-gonzalez/K-Places,nico-gonzalez/K-Places |
231bb86f03a5f3122dc671d31a5faa1d83e4e833 | kotlin/src/com/s13g/aoc/aoc2020/Day15.kt | kotlin/src/com/s13g/aoc/aoc2020/Day15.kt | package com.s13g.aoc.aoc2020
import com.s13g.aoc.Result
import com.s13g.aoc.Solver
/**
* --- Day 15: Rambunctious Recitation ---
* https://adventofcode.com/2020/day/15
*/
class Day15 : Solver {
override fun solve(lines: List<String>): Result {
val input = lines[0].split(',').map { it.toInt() }
return Re... | package com.s13g.aoc.aoc2020
import com.s13g.aoc.Result
import com.s13g.aoc.Solver
/**
* --- Day 15: Rambunctious Recitation ---
* https://adventofcode.com/2020/day/15
*/
class Day15 : Solver {
override fun solve(lines: List<String>): Result {
val input = lines[0].split(',').map { it.toInt() }
return Re... | Speed up AoC 2020.15 further. Not keeping a list, just the prev found index. | Speed up AoC 2020.15 further. Not keeping a list, just the prev found index.
| Kotlin | apache-2.0 | shaeberling/euler,shaeberling/euler,shaeberling/euler,shaeberling/euler |
75225516f9f7aed2f0e38794b3316747efc5b557 | src/test/kotlin/RemoteToLocalFileTranslatorTest.kt | src/test/kotlin/RemoteToLocalFileTranslatorTest.kt | import com.elpassion.intelijidea.configuration.RemoteToLocalFileTranslator
import com.intellij.testFramework.fixtures.LightPlatformCodeInsightFixtureTestCase
import org.junit.Assert
class RemoteToLocalFileTranslatorTest : LightPlatformCodeInsightFixtureTestCase() {
fun testShouldTranslateRemoteFileNameToLocal() {... | import com.elpassion.intelijidea.configuration.RemoteToLocalFileTranslator
import com.intellij.openapi.project.Project
import com.nhaarman.mockito_kotlin.doReturn
import com.nhaarman.mockito_kotlin.mock
import org.junit.Assert.assertEquals
import org.junit.Test
class RemoteToLocalFileTranslatorTest {
private val ... | Rewrite test to pure junit | Rewrite test to pure junit
| Kotlin | apache-2.0 | elpassion/mainframer-intellij-plugin,elpassion/mainframer-intellij-plugin,elpassion/mainframer-intellij-plugin |
c2cb2ba803ce335eb5fabd972901e90f0c6933b1 | app/src/androidTest/kotlin/com/felipecosta/kotlinrxjavasample/di/TestApplicationModule.kt | app/src/androidTest/kotlin/com/felipecosta/kotlinrxjavasample/di/TestApplicationModule.kt | package com.felipecosta.kotlinrxjavasample.di
import android.content.Context
import android.support.test.InstrumentationRegistry
import dagger.Module
import dagger.Provides
import javax.inject.Singleton
@Module
class TestApplicationModule {
@Singleton
@Provides
fun providesApplicationContext(): Context =... | package com.felipecosta.kotlinrxjavasample.di
import android.content.Context
import android.support.test.InstrumentationRegistry
import dagger.Module
import dagger.Provides
import javax.inject.Singleton
@Module
class TestApplicationModule {
@Singleton
@Provides
fun providesApplicationContext(): Context =... | Use the target context in the instrumentation test module | Use the target context in the instrumentation test module
| Kotlin | mit | fcostaa/kotlin-rxjava-android,fcostaa/kotlin-rxjava-android |
18d18f424b35b2c8df1ba44fdf6cf791865db9f5 | src/main/kotlin/views/BaseView.kt | src/main/kotlin/views/BaseView.kt | package views
/**
* Created by allen on 3/31/17.
*/
abstract class BaseView {
fun uriEncode(s: String): String{
return s.replace("%", "%25").replace(" ", "%20")
}
} | package views
/**
* Created by allen on 3/31/17.
*/
abstract class BaseView {
//based on: https://en.wikipedia.org/wiki/Percent-encoding
fun uriEncode(s: String): String{
return s
.replace("%", "%25")
.replace(" ", "%20")
.replace("!", "%21")
... | Add more characters to be escaped by uriencode | Add more characters to be escaped by uriencode
| Kotlin | mit | allen-garvey/photog-spark,allen-garvey/photog-spark,allen-garvey/photog-spark |
9f32525cdf0ab9d1ebafe788a0c5968a71fa2e47 | src/main/kotlin/me/mrkirby153/KirBot/command/args/elements/NumberElement.kt | src/main/kotlin/me/mrkirby153/KirBot/command/args/elements/NumberElement.kt | package me.mrkirby153.KirBot.command.args.elements
import me.mrkirby153.KirBot.command.args.ArgumentList
import me.mrkirby153.KirBot.command.args.ArgumentParseException
import me.mrkirby153.KirBot.command.args.CommandElement
class NumberElement(private val min: Double, private val max: Double) : CommandElement<Double... | package me.mrkirby153.KirBot.command.args.elements
import me.mrkirby153.KirBot.command.args.ArgumentList
import me.mrkirby153.KirBot.command.args.ArgumentParseException
import me.mrkirby153.KirBot.command.args.CommandElement
class NumberElement(private val min: Double, private val max: Double) : CommandElement<Double... | Fix try/catch block when parsing numbers | Fix try/catch block when parsing numbers
| Kotlin | mit | mrkirby153/KirBot |
44a279fc49b69c64e25ebc59fd4e7a58e599095f | jupyter-lib/api/src/main/kotlin/org/jetbrains/kotlinx/jupyter/api/fieldsHandling.kt | jupyter-lib/api/src/main/kotlin/org/jetbrains/kotlinx/jupyter/api/fieldsHandling.kt | package org.jetbrains.kotlinx.jupyter.api
import kotlin.reflect.KClass
import kotlin.reflect.KProperty
import kotlin.reflect.KType
import kotlin.reflect.full.isSubtypeOf
import kotlin.reflect.full.starProjectedType
typealias VariableDeclarationCallback<T> = KotlinKernelHost.(T, KProperty<*>) -> Unit
typealias FieldN... | package org.jetbrains.kotlinx.jupyter.api
import kotlin.reflect.KClass
import kotlin.reflect.KProperty
import kotlin.reflect.KType
import kotlin.reflect.full.isSubtypeOf
import kotlin.reflect.full.starProjectedType
typealias VariableDeclarationCallback<T> = KotlinKernelHost.(T, KProperty<*>) -> Unit
typealias Variab... | Rename 'FieldName' to 'VariableName' type alias | Rename 'FieldName' to 'VariableName' type alias
| Kotlin | apache-2.0 | ligee/kotlin-jupyter |
5314e08bc9ad0b09950643c097d06a659bb5c125 | subprojects/workers/build.gradle.kts | subprojects/workers/build.gradle.kts | plugins {
id("gradlebuild.distribution.api-java")
}
description = "Infrastructure for running worker processes"
dependencies {
implementation(project(":base-services"))
implementation(project(":messaging"))
implementation(project(":logging"))
implementation(project(":process-services"))
implem... | plugins {
id("gradlebuild.distribution.api-java")
}
description = "Infrastructure for starting and managing worker processes"
dependencies {
implementation(project(":base-services"))
implementation(project(":messaging"))
implementation(project(":logging"))
implementation(project(":process-services... | Clarify description of workers project | Clarify description of workers project | Kotlin | apache-2.0 | blindpirate/gradle,blindpirate/gradle,gradle/gradle,gradle/gradle,blindpirate/gradle,blindpirate/gradle,blindpirate/gradle,gradle/gradle,blindpirate/gradle,gradle/gradle,blindpirate/gradle,blindpirate/gradle,gradle/gradle,gradle/gradle,gradle/gradle,gradle/gradle,gradle/gradle,blindpirate/gradle,blindpirate/gradle,grad... |
c31ae715cbba04b6d8a366b53cd101c0bad92159 | sample/src/androidTest/kotlin/com/agoda/sample/PickersTest.kt | sample/src/androidTest/kotlin/com/agoda/sample/PickersTest.kt | package com.agoda.sample
| package com.agoda.sample
import androidx.test.internal.runner.junit4.AndroidJUnit4ClassRunner
import androidx.test.rule.ActivityTestRule
import com.agoda.kakao.screen.Screen
import com.agoda.sample.screen.PickersActivityScreen
import org.junit.Rule
import org.junit.Test
import org.junit.runner.RunWith
@RunWith(Androi... | Add test for picker dialogs | Add test for picker dialogs
| Kotlin | apache-2.0 | agoda-com/Kakao |
ab9bcc534768e9886a308bd567219cd8a3208bb1 | plugins/build.gradle.kts | plugins/build.gradle.kts | subprojects {
apply {
plugin("maven-publish")
plugin("com.jfrog.bintray")
}
dependencies {
compileOnly(project(":core"))
implementation(kotlin("stdlib-jdk8"))
implementation(kotlin("stdlib"))
implementation(kotlin("reflect"))
testImplementation(proje... | import org.gradle.api.tasks.testing.logging.TestExceptionFormat
subprojects {
apply {
plugin("maven-publish")
plugin("com.jfrog.bintray")
}
dependencies {
compileOnly(project(":core"))
implementation(kotlin("stdlib-jdk8"))
implementation(kotlin("stdlib"))
im... | Change test logging to show only skipped and failed ones, show full stacktraces | Change test logging to show only skipped and failed ones, show full stacktraces
| Kotlin | apache-2.0 | Kotlin/dokka,Kotlin/dokka,Kotlin/dokka,Kotlin/dokka,Kotlin/dokka,Kotlin/dokka |
511bc32dc756da929efab3b4904947d37c5a41e1 | buildSrc/build.gradle.kts | buildSrc/build.gradle.kts | import org.gradle.kotlin.dsl.plugins.precompiled.PrecompiledScriptPlugins
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
buildscript {
val pluginsExperiments = "gradle.plugin.org.gradle.kotlin:gradle-kotlin-dsl-plugins-experiments:0.1.10"
dependencies {
classpath(pluginsExperiments)
}
... | import org.gradle.kotlin.dsl.plugins.dsl.ProgressiveModeState
import org.gradle.kotlin.dsl.plugins.precompiled.PrecompiledScriptPlugins
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
buildscript {
val pluginsExperiments = "gradle.plugin.org.gradle.kotlin:gradle-kotlin-dsl-plugins-experiments:0.1.10"
... | Enable progressive kotlin-dsl on buildSrc | Enable progressive kotlin-dsl on buildSrc
Signed-off-by: Paul Merlin <a027184a55211cd23e3f3094f1fdc728df5e0500@gradle.com>
| Kotlin | apache-2.0 | robinverduijn/gradle,robinverduijn/gradle,gradle/gradle,robinverduijn/gradle,robinverduijn/gradle,robinverduijn/gradle,gradle/gradle,blindpirate/gradle,blindpirate/gradle,gradle/gradle,robinverduijn/gradle,gradle/gradle-script-kotlin,gradle/gradle,robinverduijn/gradle,gradle/gradle,blindpirate/gradle,blindpirate/gradle... |
8f15aaaa97c543496d7e934d1c16a0ceab49f342 | shims/build.gradle.kts | shims/build.gradle.kts | // See https://blog.gradle.org/mrjars and https://github.com/melix/mrjar-gradle for more on multi release jars
sourceSets {
create("java11") {
java {
srcDir("src/java11/main")
}
}
}
tasks.named<JavaCompile>("compileJava11Java") {
// Arrays.equals exists since JDK9, but the inte... | // See https://blog.gradle.org/mrjars and https://github.com/melix/mrjar-gradle for more on multi release jars
sourceSets {
create("java11") {
java {
srcDir("src/java11/main")
}
}
}
tasks.named<JavaCompile>("compileJava11Java") {
// Arrays.equals exists since JDK9, but we make ... | Tweak shims build to include shims in all cases | Tweak shims build to include shims in all cases
| Kotlin | apache-2.0 | lemire/RoaringBitmap,lemire/RoaringBitmap,lemire/RoaringBitmap,lemire/RoaringBitmap |
aa24f748cf3c101e3b7ef16ad7a204de522da5ca | arl/src/main/kotlin/Main.kt | arl/src/main/kotlin/Main.kt |
import machine.learning.ARL
import java.io.File
import java.util.*
fun main(args : Array<String>) {
// we open the .dat file located in data
val myFile = File("data/EURUSD.dat").inputStream()
val array2 : ArrayList<Double> = arrayListOf()
myFile.bufferedReader().useLines { lines -> lines.forEach {
... |
import machine.learning.ARL
import java.io.File
import java.util.*
fun main(args : Array<String>) {
// we open the .dat file located in data
val myFile = File("data/EURUSD.dat").inputStream()
val array2 : ArrayList<Double> = arrayListOf()
myFile.bufferedReader().useLines { lines -> lines.forEach {
... | Add a test loop in the main | Add a test loop in the main
| Kotlin | mit | mencattini/eMuLATe,mencattini/eMuLATe,mencattini/eMuLATe,mencattini/eMuLATe |
2bfbf65050aaca0dc45970f8e1a7bc0400581f73 | android/src/main/java/cn/qiuxiang/react/amap3d/AMapOverlay.kt | android/src/main/java/cn/qiuxiang/react/amap3d/AMapOverlay.kt | package cn.qiuxiang.react.amap3d
import android.content.Context
import com.facebook.react.views.view.ReactViewGroup
class AMapOverlay(context: Context) : ReactViewGroup(context) {
private var updateHandler: (() -> Unit)? = null
fun onUpdate(handler: () -> Unit) {
updateHandler = handler
}
fu... | package cn.qiuxiang.react.amap3d
import android.content.Context
import com.facebook.react.views.view.ReactViewGroup
class AMapOverlay(context: Context) : ReactViewGroup(context) {
private var updateHandler: (() -> Unit)? = null
fun onUpdate(handler: () -> Unit) {
updateHandler = handler
}
fu... | Fix android InfoWindow layout bug | Fix android InfoWindow layout bug
| Kotlin | mit | qiuxiang/react-native-amap3d,qiuxiang/react-native-amap3d,qiuxiang/react-native-amap3d,qiuxiang/react-native-amap3d,qiuxiang/react-native-amap3d,qiuxiang/react-native-amap3d |
c77275013aa97afe930a8d1b4044bd04143b265f | ktor-core/src/org/jetbrains/ktor/content/Templating.kt | ktor-core/src/org/jetbrains/ktor/content/Templating.kt | package org.jetbrains.ktor.content
import org.jetbrains.ktor.application.*
import org.jetbrains.ktor.routing.*
import kotlin.reflect.*
interface TemplateEngine<C : Any, R> where R : StreamContent, R : HasContentType {
val contentClass: KClass<C>
fun process(content: C): R
}
inline fun <reified C : Any> Appli... | package org.jetbrains.ktor.content
import org.jetbrains.ktor.application.*
import org.jetbrains.ktor.interception.*
import org.jetbrains.ktor.routing.*
import kotlin.reflect.*
interface TemplateEngine<C : Any, R> where R : StreamContent, R : HasContentType {
val contentClass: KClass<C>
fun process(content: C)... | Unify interception using InterceptApplicationCall (former InterceptableWithContext) | Unify interception using InterceptApplicationCall (former InterceptableWithContext)
| Kotlin | apache-2.0 | ktorio/ktor,ktorio/ktor,ktorio/ktor,ktorio/ktor |
c0eacaf340309a9a85cfd9c88a95f9ca458ce0e2 | src/main/kotlin/com/github/kerubistan/kerub/utils/AnyUtils.kt | src/main/kotlin/com/github/kerubistan/kerub/utils/AnyUtils.kt | package com.github.kerubistan.kerub.utils
fun <T> T.equalsAnyOf(vararg others: T) = others.any { this == it }
fun String.equalsAnyIgnoreCase(vararg others: String) = others.any { it.equals(this, ignoreCase = true) }
/**
* Proudly and intentionally doing nothing.
*/
inline fun NOP(): Unit {}
| package com.github.kerubistan.kerub.utils
fun <T> T.equalsAnyOf(vararg others: T) = others.any { this == it }
fun String.equalsAnyIgnoreCase(vararg others: String) = others.any { it.equals(this, ignoreCase = true) }
/**
* Proudly and intentionally doing nothing.
*/
inline fun NOP(): Unit { /*the expected nothing, ... | Comment on why the NOP method is empty (sonar auto-bugs) | Comment on why the NOP method is empty
(sonar auto-bugs)
Signed-off-by: Laszlo Hornyak <b67b79795179d8ff38e8fa896b513991ab7f1811@gmail.com>
| Kotlin | apache-2.0 | K0zka/kerub,kerubistan/kerub,kerubistan/kerub,kerubistan/kerub,K0zka/kerub,K0zka/kerub |
550eaed89935300b8581ed77290925eda2fb8aeb | build-logic-commons/gradle-plugin/build.gradle.kts | build-logic-commons/gradle-plugin/build.gradle.kts | plugins {
`kotlin-dsl`
}
group = "gradlebuild"
description = "Provides plugins used to create a Gradle plugin with Groovy or Kotlin DSL within build-logic builds"
java {
sourceCompatibility = JavaVersion.VERSION_11
targetCompatibility = JavaVersion.VERSION_11
}
dependencies {
compileOnly("com.gradle... | plugins {
`kotlin-dsl`
}
group = "gradlebuild"
description = "Provides plugins used to create a Gradle plugin with Groovy or Kotlin DSL within build-logic builds"
java {
sourceCompatibility = JavaVersion.VERSION_11
targetCompatibility = JavaVersion.VERSION_11
}
dependencies {
compileOnly("com.gradle... | Remove Kotlin <> 1.7 branching in build logic | Remove Kotlin <> 1.7 branching in build logic
Signed-off-by: Paul Merlin <a027184a55211cd23e3f3094f1fdc728df5e0500@gradle.com>
| Kotlin | apache-2.0 | gradle/gradle,gradle/gradle,gradle/gradle,gradle/gradle,gradle/gradle,gradle/gradle,gradle/gradle,gradle/gradle,gradle/gradle,gradle/gradle |
8a566b2bf58f7ab72f1528ad0e1bc91410e62150 | gradle/init-scripts/build-scan.init.gradle.kts | gradle/init-scripts/build-scan.init.gradle.kts | /*
* This is an init script for internal usage at Gradle Inc.
*/
initscript {
repositories {
gradlePluginPortal()
}
dependencies {
classpath("com.gradle:build-scan-plugin:1.13")
}
}
if (!gradle.startParameter.systemPropertiesArgs.containsKey("disableScanPlugin")) {
rootProject {
... | /*
* This is an init script for internal usage at Gradle Inc.
*/
if (!gradle.startParameter.systemPropertiesArgs.containsKey("disableScanPlugin")) {
rootProject {
pluginManager.withPlugin("com.gradle.build-scan") {
extensions["buildScan"].withGroovyBuilder {
if (gradle.startPar... | Remove unused repository declaration in build-scan-init | Remove unused repository declaration in build-scan-init
| Kotlin | apache-2.0 | robinverduijn/gradle,blindpirate/gradle,blindpirate/gradle,robinverduijn/gradle,lsmaira/gradle,gradle/gradle,gradle/gradle,gradle/gradle,lsmaira/gradle,lsmaira/gradle,robinverduijn/gradle,gradle/gradle,blindpirate/gradle,gradle/gradle,lsmaira/gradle,blindpirate/gradle,robinverduijn/gradle,lsmaira/gradle,robinverduijn/g... |
1e4986369c00ca4bbccff88d57eea64b1808cb00 | src/main/kotlin/ml/duncte123/skybot/commands/essentials/UpdateCommand.kt | src/main/kotlin/ml/duncte123/skybot/commands/essentials/UpdateCommand.kt | package ml.duncte123.skybot.commands.essentials
import ml.duncte123.skybot.objects.command.Command
import ml.duncte123.skybot.objects.command.CommandCategory
import ml.duncte123.skybot.utils.AirUtils
import ml.duncte123.skybot.utils.Settings
import net.dv8tion.jda.core.events.message.guild.GuildMessageReceivedEvent
im... | package ml.duncte123.skybot.commands.essentials
import ml.duncte123.skybot.objects.command.Command
import ml.duncte123.skybot.objects.command.CommandCategory
import ml.duncte123.skybot.utils.AirUtils
import ml.duncte123.skybot.utils.Settings
import net.dv8tion.jda.core.events.message.guild.GuildMessageReceivedEvent
im... | Use ✔ instead of ❌ on update | Use ✔ instead of ❌ on update
| Kotlin | agpl-3.0 | duncte123/SkyBot,duncte123/SkyBot,duncte123/SkyBot,duncte123/SkyBot |
7f0a8333481d55f0e808eaaa7ad6f8049f1d0d57 | test/org/intellij/markdown/MarkdownTestUtil.kt | test/org/intellij/markdown/MarkdownTestUtil.kt | package org.intellij.markdown
import java.io.File
import kotlin.test.fail
import com.intellij.rt.execution.junit.FileComparisonFailure
import junit.framework.TestCase
val INTELLIJ_MARKDOWN_TEST_KEY = "Intellij.markdown.home"
public fun TestCase.assertSameLinesWithFile(filePath: String, text: String) {
val file =... | package org.intellij.markdown
import java.io.File
import com.intellij.rt.execution.junit.FileComparisonFailure
import junit.framework.AssertionFailedError
import junit.framework.TestCase
val INTELLIJ_MARKDOWN_TEST_KEY = "Intellij.markdown.home"
public fun TestCase.assertSameLinesWithFile(filePath: String, text: Stri... | Fix compilation: remove dependency from kotlin.test.fail | Fix compilation: remove dependency from kotlin.test.fail
| Kotlin | apache-2.0 | ilya-g/intellij-markdown,valich/intellij-markdown,valich/intellij-markdown,ilya-g/intellij-markdown,ilya-g/intellij-markdown,ilya-g/intellij-markdown,valich/intellij-markdown,valich/intellij-markdown |
8cbba42c7db9234f23a3ae45f419322ac4587e4a | core/src/main/java/io/plaidapp/core/designernews/data/api/DesignerNewsSearchService.kt | core/src/main/java/io/plaidapp/core/designernews/data/api/DesignerNewsSearchService.kt | /*
* Copyright 2018 Google, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to... | /*
* Copyright 2018 Google, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to... | Remove search result type query param | Remove search result type query param
- we always want story, no need to expose this in our API
| Kotlin | apache-2.0 | nickbutcher/plaid,nickbutcher/plaid,nickbutcher/plaid,nickbutcher/plaid |
902637275fb5f0cae0aefa59729eb528917c57cc | app/src/main/java/io/particle/android/sdk/ui/devicelist/DeviceFilterFragment.kt | app/src/main/java/io/particle/android/sdk/ui/devicelist/DeviceFilterFragment.kt | package io.particle.android.sdk.ui.devicelist
import android.os.Bundle
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import androidx.fragment.app.Fragment
import io.particle.sdk.app.R
class DeviceFilterFragment : Fragment() {
companion object {
fun newInstance... | package io.particle.android.sdk.ui.devicelist
import android.os.Bundle
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import androidx.fragment.app.Fragment
import io.particle.sdk.app.R
import kotlinx.android.synthetic.main.fragment_filter_fragment.*
class DeviceFilterFragme... | Make the buttons do something for now | Make the buttons do something for now
| Kotlin | apache-2.0 | spark/photon-tinker-android,spark/photon-tinker-android |
fecebca80bb359e701094026f6f5ea3ec3a49ed5 | src/main/kotlin/me/serce/solidity/ide/inspections/SelfdestructRenameInspection.kt | src/main/kotlin/me/serce/solidity/ide/inspections/SelfdestructRenameInspection.kt | package me.serce.solidity.ide.inspections
import com.intellij.codeInspection.LocalInspectionTool
import com.intellij.codeInspection.LocalInspectionToolSession
import com.intellij.codeInspection.ProblemsHolder
import com.intellij.psi.PsiElementVisitor
import me.serce.solidity.ide.inspections.fixes.RenameFix
import me.s... | package me.serce.solidity.ide.inspections
import com.intellij.codeInspection.LocalInspectionTool
import com.intellij.codeInspection.LocalInspectionToolSession
import com.intellij.codeInspection.ProblemsHolder
import com.intellij.psi.PsiElementVisitor
import me.serce.solidity.ide.inspections.fixes.RenameFix
import me.s... | Add id to a local inspection to simplify disabling | Add id to a local inspection to simplify disabling
| Kotlin | mit | intellij-solidity/intellij-solidity,intellij-solidity/intellij-solidity,intellij-solidity/intellij-solidity,intellij-solidity/intellij-solidity |
98daa4f2e208ed74a45c6f1584a89f89538326d7 | build.gradle.kts | build.gradle.kts | plugins {
val kotlinVersion = "1.3.71"
kotlin("js") version kotlinVersion apply false
kotlin("jvm") version kotlinVersion apply false
kotlin("multiplatform") version kotlinVersion apply false
kotlin("plugin.spring") version kotlinVersion apply false
id("org.jetbrains.kotlin.plugin.serialization"... | plugins {
val kotlinVersion = "1.3.71"
kotlin("js") version kotlinVersion apply false
kotlin("jvm") version kotlinVersion apply false
kotlin("multiplatform") version kotlinVersion apply false
kotlin("plugin.spring") version kotlinVersion apply false
id("org.jetbrains.kotlin.plugin.serialization"... | Remove personal bintray repo now that jcenter sync works | Remove personal bintray repo now that jcenter sync works
| Kotlin | mit | luxons/seven-wonders,luxons/seven-wonders,luxons/seven-wonders |
f90abc630ddc3b568f8b588b3fa9d30573a5d2f4 | webclient/src/main/kotlin/client/ButtonBar.kt | webclient/src/main/kotlin/client/ButtonBar.kt | package client
import client.component.flaticon
import client.component.visible
import net.yested.core.html.*
import net.yested.core.properties.*
import net.yested.ext.bootstrap3.*
import net.yested.ext.bootstrap3.ButtonLook
import net.yested.ext.bootstrap3.ButtonSize
import org.w3c.dom.HTMLElement
/**
* Support for... | package client
import client.component.flaticon
import client.component.visible
import net.yested.core.properties.*
import net.yested.ext.bootstrap3.*
import net.yested.ext.bootstrap3.ButtonLook
import net.yested.ext.bootstrap3.ButtonSize
import org.w3c.dom.HTMLElement
/**
* Support for undoing user actions.
* @aut... | Make UndoComponent use 10/12 of the screen. | Make UndoComponent use 10/12 of the screen.
| Kotlin | apache-2.0 | epabst/kotlin-showcase,epabst/kotlin-showcase,epabst/kotlin-showcase,epabst/kotlin-showcase |
43f640a7b16a61c9d5003b2ceea4d8b6c7bceafe | src/main/kotlin/com/github/libkt/LibKt.kt | src/main/kotlin/com/github/libkt/LibKt.kt | package com.github.libkt
import org.bstats.Metrics
import org.bukkit.plugin.java.JavaPlugin
/**
* The main plugin class for libkt.
*/
class LibKt : JavaPlugin() {
/**
* Returns the build number of the libkt plugin
*
* @since b1
*/
val buildNumber: Int by lazy {
try {
... | package com.github.libkt
import org.bstats.Metrics
import org.bukkit.plugin.java.JavaPlugin
/**
* The main plugin class for libkt.
*/
class LibKt : JavaPlugin() {
/**
* Returns the build number of the libkt plugin
*
* @since b1
*/
val buildNumber: Int by lazy {
try {
... | Add warning when build number not present. | Add warning when build number not present.
| Kotlin | mit | libkt/libkt |
8fc520df627566b2bc75e9971d9381f2d1cb5135 | aconite-core/src/io/aconite/Exceptions.kt | aconite-core/src/io/aconite/Exceptions.kt | package io.aconite
/**
* Throws if something go wrong with HTTP interfaces. Most of the time this
* exception means, that the interface is not satisfy some constraints.
*/
open class AconiteException(message: String? = null, cause: Throwable? = null): RuntimeException(message, cause)
open class HttpException(val c... | package io.aconite
/**
* Throws if something go wrong with HTTP interfaces. Most of the time this
* exception means, that the interface is not satisfy some constraints.
*/
open class AconiteException(message: String? = null, cause: Throwable? = null): RuntimeException(message, cause)
open class HttpException(val c... | Add toString() implementation to HttpException | Add toString() implementation to HttpException
| Kotlin | mit | AcapellaSoft/Aconite,AcapellaSoft/Aconite |
5f2e84a7d00f9bfb8364ee0913aecd23b6dca647 | src/orbit-commons/src/main/kotlin/orbit/common/collections/GraphTraverser.kt | src/orbit-commons/src/main/kotlin/orbit/common/collections/GraphTraverser.kt | /*
Copyright (C) 2015 - 2019 Electronic Arts Inc. All rights reserved.
This file is part of the Orbit Project <https://www.orbit.cloud>.
See license in LICENSE.
*/
package orbit.common.collections
class GraphTraverser<T>(val getChildren: (T) -> Sequence<T>) {
fun traverse(initial: T): Sequence<Pair<T>> {
... | /*
Copyright (C) 2015 - 2019 Electronic Arts Inc. All rights reserved.
This file is part of the Orbit Project <https://www.orbit.cloud>.
See license in LICENSE.
*/
package orbit.common.collections
class GraphTraverser<T>(val getChildren: (T) -> Sequence<T>) {
fun traverse(initial: T): Sequence<ParentChild<T>... | Change "Pair" class in Graph Traverser to ParentChild to avoid conflict with built-in type. | Change "Pair" class in Graph Traverser to ParentChild to avoid conflict with built-in type.
| Kotlin | bsd-3-clause | orbit/orbit,orbit/orbit |
c7b60080e3bd026ec75721c98e2df356bf22f026 | code-sample-kotlin/src/codesample/kotlin/sandbox/classes/ClassesSortOfMultipleInheritance.kt | code-sample-kotlin/src/codesample/kotlin/sandbox/classes/ClassesSortOfMultipleInheritance.kt | package codesample.kotlin.sandbox.classes
interface One {
fun doSomething() {
println("One flying!")
}
}
interface Two {
fun doSomething() {
println("Two flying!")
}
}
/**
* If both interfaces have a method with the same signature, you ccan override it once.
* You can also call res... | package codesample.kotlin.sandbox.classes
interface One {
fun doSomething() {
println("One flying!")
}
}
interface Two {
fun doSomething() {
println("Two flying!")
}
}
/**
* If both interfaces have a method with the same signature, you ccan override it once.
* You can also call res... | Add kotlin object/function extension example | Add kotlin object/function extension example
| Kotlin | mit | aquatir/remember_java_api,aquatir/remember_java_api,aquatir/remember_java_api,aquatir/remember_java_api |
fb48d22406b279c8262ab53a3165d1d46c19bb46 | android/koin-androidx-navigation/src/main/java/org/koin/androidx/navigation/NavGraphExt.kt | android/koin-androidx-navigation/src/main/java/org/koin/androidx/navigation/NavGraphExt.kt | package org.koin.androidx.navigation
import androidx.annotation.IdRes
import androidx.fragment.app.Fragment
import androidx.fragment.app.viewModels
import androidx.lifecycle.ViewModel
import androidx.navigation.NavBackStackEntry
import androidx.navigation.fragment.findNavController
import org.koin.android.ext.android.... | package org.koin.androidx.navigation
import androidx.annotation.IdRes
import androidx.fragment.app.Fragment
import androidx.fragment.app.viewModels
import androidx.lifecycle.ViewModel
import androidx.navigation.NavBackStackEntry
import androidx.navigation.fragment.findNavController
import org.koin.android.ext.android.... | Fix Nav Graph scope resolution | Fix Nav Graph scope resolution
| Kotlin | apache-2.0 | InsertKoinIO/koin,InsertKoinIO/koin,InsertKoinIO/koin |
c2cdbe3f1f64efc143e369b6623e519c1c9d3524 | buildSrc/subprojects/profiling/profiling.gradle.kts | buildSrc/subprojects/profiling/profiling.gradle.kts | dependencies {
implementation("me.champeau.gradle:jmh-gradle-plugin:0.5.0-rc-2")
implementation("org.jsoup:jsoup:1.11.3")
implementation("com.gradle:build-scan-plugin:2.4")
implementation(project(":configuration"))
implementation(project(":kotlinDsl"))
implementation(project(":plugins"))
imp... | dependencies {
implementation("me.champeau.gradle:jmh-gradle-plugin:0.5.0-rc-2")
implementation("org.jsoup:jsoup:1.11.3")
implementation("com.gradle:build-scan-plugin:2.4.1-rc-1-20190819151105-release")
implementation(project(":configuration"))
implementation(project(":kotlinDsl"))
implementatio... | Use latest Scan plugin 2.4.1-rc-1 | Use latest Scan plugin 2.4.1-rc-1
| Kotlin | apache-2.0 | gradle/gradle,robinverduijn/gradle,blindpirate/gradle,gradle/gradle,robinverduijn/gradle,robinverduijn/gradle,robinverduijn/gradle,robinverduijn/gradle,robinverduijn/gradle,robinverduijn/gradle,blindpirate/gradle,blindpirate/gradle,gradle/gradle,robinverduijn/gradle,blindpirate/gradle,gradle/gradle,robinverduijn/gradle... |
8b0de1afa8898250d52b3006df23afefcdee5882 | platform/platform-impl/src/com/intellij/openapi/updateSettings/impl/UpdateOptions.kt | platform/platform-impl/src/com/intellij/openapi/updateSettings/impl/UpdateOptions.kt | // Copyright 2000-2019 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package com.intellij.openapi.updateSettings.impl
import com.intellij.openapi.components.BaseState
import com.intellij.openapi.components.ReportValue
import com.intellij.util.xmlb... | // Copyright 2000-2019 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package com.intellij.openapi.updateSettings.impl
import com.intellij.openapi.components.BaseState
import com.intellij.openapi.components.ReportValue
import com.intellij.util.xmlb... | Send update check timestamp as relative hours, not as absolute value (IDEA-CR-60741) | Send update check timestamp as relative hours, not as absolute value (IDEA-CR-60741)
GitOrigin-RevId: b70c4fcd2494af776d26a2b9e32f2d7cd2536675 | Kotlin | apache-2.0 | allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/int... |
1d6a5e62a181d2772ac1c3c1f831158e35895ada | integration-tests/resteasy-reactive-kotlin/standard/src/main/kotlin/io/quarkus/it/resteasy/reactive/kotlin/ReactiveGreetingResource.kt | integration-tests/resteasy-reactive-kotlin/standard/src/main/kotlin/io/quarkus/it/resteasy/reactive/kotlin/ReactiveGreetingResource.kt | package io.quarkus.it.resteasy.reactive.kotlin
import kotlinx.coroutines.delay
import java.io.BufferedReader
import java.io.InputStreamReader
import java.net.URL
import javax.inject.Inject
import javax.ws.rs.GET
import javax.ws.rs.Path
import javax.ws.rs.Produces
import javax.ws.rs.core.MediaType
@Path("/hello-restea... | package io.quarkus.it.resteasy.reactive.kotlin
import kotlinx.coroutines.delay
import java.io.BufferedReader
import java.io.InputStreamReader
import java.net.URL
import javax.inject.Inject
import javax.ws.rs.GET
import javax.ws.rs.Path
import javax.ws.rs.Produces
import javax.ws.rs.core.MediaType
@Path("/hello-restea... | Remove blocking call from coroutine execution | Remove blocking call from coroutine execution
| Kotlin | apache-2.0 | quarkusio/quarkus,quarkusio/quarkus,quarkusio/quarkus,quarkusio/quarkus,quarkusio/quarkus |
819181798aa2f4a773564d70242df247a37afdcd | telegram-bot-bumblebee-core/src/main/java/com/github/bumblebee/command/start/StartCommand.kt | telegram-bot-bumblebee-core/src/main/java/com/github/bumblebee/command/start/StartCommand.kt | package com.github.bumblebee.command.start
import com.github.telegram.api.BotApi
import com.github.telegram.domain.ParseMode
import com.github.telegram.domain.Update
import org.apache.commons.io.FileUtils
import org.springframework.core.io.ClassPathResource
import org.springframework.stereotype.Component
import com.gi... | package com.github.bumblebee.command.start
import com.github.bumblebee.bot.consumer.UpdateHandler
import com.github.telegram.api.BotApi
import com.github.telegram.domain.ParseMode
import com.github.telegram.domain.Update
import org.apache.commons.io.IOUtils
import org.springframework.core.io.ClassPathResource
import o... | Fix start command cannot read file on classpath with executable boot jar. | Fix start command cannot read file on classpath with executable boot jar.
| Kotlin | mit | fare1990/telegram-bot-bumblebee,fare1990/telegram-bot-bumblebee,fare1990/telegram-bot-bumblebee,denzelby/telegram-bot-bumblebee |
a08590d78a92fecaeb9499bc997286edb38825a9 | colorpickerview/src/main/java/com/skydoves/colorpickerview/kotlin/ColorPickerDialogExtension.kt | colorpickerview/src/main/java/com/skydoves/colorpickerview/kotlin/ColorPickerDialogExtension.kt | /*
* Designed and developed by 2017 skydoves (Jaewoong Eum)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by appl... | /*
* Designed and developed by 2017 skydoves (Jaewoong Eum)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by appl... | Make inline function for the colorPickerDialog() extension | Make inline function for the colorPickerDialog() extension
| Kotlin | apache-2.0 | skydoves/ColorPickerView,skydoves/ColorPickerView |
aa9a77c33014faaf53ab390d971334ade1d3b7af | buildSrc/subprojects/profiling/profiling.gradle.kts | buildSrc/subprojects/profiling/profiling.gradle.kts | import org.gradle.kotlin.dsl.plugins.precompiled.PrecompiledScriptPlugins
plugins {
`java-gradle-plugin`
}
apply(plugin = "org.gradle.kotlin.kotlin-dsl")
apply<PrecompiledScriptPlugins>()
dependencies {
implementation("me.champeau.gradle:jmh-gradle-plugin:0.4.7")
implementation("org.jsoup:jsoup:1.11.2")
... | import org.gradle.kotlin.dsl.plugins.precompiled.PrecompiledScriptPlugins
plugins {
`java-gradle-plugin`
}
apply(plugin = "org.gradle.kotlin.kotlin-dsl")
apply<PrecompiledScriptPlugins>()
dependencies {
implementation("me.champeau.gradle:jmh-gradle-plugin:0.4.7")
implementation("org.jsoup:jsoup:1.11.2")
... | Use the 'proper' version for the 1.16-rc-1 plugin | Use the 'proper' version for the 1.16-rc-1 plugin
-- Enterprise releases are 10% more releasey
| Kotlin | apache-2.0 | lsmaira/gradle,gradle/gradle,gradle/gradle,blindpirate/gradle,lsmaira/gradle,lsmaira/gradle,blindpirate/gradle,gradle/gradle,gradle/gradle,lsmaira/gradle,lsmaira/gradle,gradle/gradle,blindpirate/gradle,lsmaira/gradle,robinverduijn/gradle,robinverduijn/gradle,blindpirate/gradle,robinverduijn/gradle,blindpirate/gradle,ro... |
0a7812bb2c73b3b54e1c61eb8d2c5e081f274a9d | app/src/main/java/exh/metadata/models/PervEdenGalleryMetadata.kt | app/src/main/java/exh/metadata/models/PervEdenGalleryMetadata.kt | package exh.metadata.models
import android.net.Uri
import timber.log.Timber
//TODO Add artificial artist tag
class PervEdenGalleryMetadata : SearchableGalleryMetadata() {
var url: String? = null
var thumbnailUrl: String? = null
var artist: String? = null
var type: String? = null
var rating: Flo... | package exh.metadata.models
import android.net.Uri
class PervEdenGalleryMetadata : SearchableGalleryMetadata() {
var url: String? = null
var thumbnailUrl: String? = null
var artist: String? = null
var type: String? = null
var rating: Float? = null
var status: String? = null
var lang: ... | Remove old debugging code and useless comments. | Remove old debugging code and useless comments.
| Kotlin | apache-2.0 | NerdNumber9/TachiyomiEH,NerdNumber9/TachiyomiEH |
60727619c6a5a2028ca4ee48f663fa30df3be8f1 | tasks/src/main/java/app/tivi/tasks/ShowTasksImpl.kt | tasks/src/main/java/app/tivi/tasks/ShowTasksImpl.kt | /*
* Copyright 2018 Google, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to... | /*
* Copyright 2018 Google, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to... | Set tasks to clear any pending | Set tasks to clear any pending
| Kotlin | apache-2.0 | chrisbanes/tivi,chrisbanes/tivi |
b3ce0f6be56ce9679af54edd43e00a61d70368f0 | library/src/main/java/com/chibatching/remotekonfig/KonfigModel.kt | library/src/main/java/com/chibatching/remotekonfig/KonfigModel.kt | package com.chibatching.remotekonfig
import java.util.*
open class KonfigModel {
internal var isRegistered: Boolean = false
internal var defaultsMap: MutableMap<String, Any>? = null
get() = if (!isRegistered) {
field ?: HashMap<String, Any>()
} else {
null
}
... | package com.chibatching.remotekonfig
import java.util.*
open class KonfigModel {
internal var isRegistered: Boolean = false
internal var defaultsMap: MutableMap<String, Any>? = null
get() = if (!isRegistered) {
field ?: run {
field = HashMap<String, Any>()
... | Fix field value update missing | Fix field value update missing
| Kotlin | apache-2.0 | chibatching/remote-konfig,chibatching/remote-konfig |
ad1858046886fc58cc6b57240726e2ce59abfcd4 | build.gradle.kts | build.gradle.kts | plugins {
id("com.diffplug.gradle.spotless")
}
apply(from = "$rootDir/gradle/travis-ci.gradle.kts")
apply(from = "$rootDir/gradle/lgtm.gradle.kts")
allprojects {
apply(plugin = "com.diffplug.gradle.spotless")
repositories {
mavenCentral()
}
spotless {
kotlinGradle {
k... | plugins {
id("com.diffplug.gradle.spotless")
id("com.github.ben-manes.versions") version "0.27.0"
}
apply(from = "$rootDir/gradle/travis-ci.gradle.kts")
apply(from = "$rootDir/gradle/lgtm.gradle.kts")
allprojects {
apply(plugin = "com.diffplug.gradle.spotless")
apply(plugin = "com.github.ben-manes.ver... | Add Gradle Task to Check Dependency Updates | Add Gradle Task to Check Dependency Updates
Can be run as:
- `./gradlew addOns:ascanrules:dependencyUpdates`
- `./gradlew dependencyUpdates`
Signed-off-by: kingthorin <83ea41af2b636790c02743e48206546e1fa891e4@users.noreply.github.com> | Kotlin | apache-2.0 | thc202/zap-extensions,secdec/zap-extensions,zaproxy/zap-extensions,secdec/zap-extensions,zapbot/zap-extensions,zaproxy/zap-extensions,veggiespam/zap-extensions,denniskniep/zap-extensions,psiinon/zap-extensions,secdec/zap-extensions,denniskniep/zap-extensions,veggiespam/zap-extensions,veggiespam/zap-extensions,veggiespa... |
b3d56e078f37d4ea467d8c74d0a12894ed052581 | subprojects/kotlin-dsl-provider-plugins/kotlin-dsl-provider-plugins.gradle.kts | subprojects/kotlin-dsl-provider-plugins/kotlin-dsl-provider-plugins.gradle.kts | /*
* Copyright 2018 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applica... | /*
* Copyright 2018 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applica... | Remove `integTestRuntimeOnly` references from `kotlinDslProviderPlugins` | Remove `integTestRuntimeOnly` references from `kotlinDslProviderPlugins`
The project no longer has integration tests.
| Kotlin | apache-2.0 | robinverduijn/gradle,blindpirate/gradle,robinverduijn/gradle,gradle/gradle,gradle/gradle,robinverduijn/gradle,gradle/gradle,gradle/gradle,gradle/gradle,gradle/gradle,robinverduijn/gradle,blindpirate/gradle,robinverduijn/gradle,robinverduijn/gradle,blindpirate/gradle,blindpirate/gradle,blindpirate/gradle,robinverduijn/g... |
7e04a015950609bdd16ec89aa5b42f858fb04c04 | opacclient/libopac/src/main/java/de/geeksfactory/opacclient/utils/KotlinUtils.kt | opacclient/libopac/src/main/java/de/geeksfactory/opacclient/utils/KotlinUtils.kt | package de.geeksfactory.opacclient.utils
import org.json.JSONArray
import org.json.JSONObject
import org.jsoup.Jsoup
import org.jsoup.nodes.Document
import org.jsoup.nodes.Element
import org.jsoup.nodes.TextNode
import org.jsoup.select.Elements
val String.html: Document
get() = Jsoup.parse(this)
val String.jsonO... | package de.geeksfactory.opacclient.utils
import org.json.JSONArray
import org.json.JSONObject
import org.jsoup.Jsoup
import org.jsoup.nodes.Document
import org.jsoup.nodes.Element
import org.jsoup.nodes.TextNode
import org.jsoup.select.Elements
val String.html: Document
get() = Jsoup.parse(this)
val String.jsonO... | Fix array index range of JSONArray extension functions | Fix array index range of JSONArray extension functions
The rangeTo operator ".." includes the end element which leads to an array index
out of range error. The "until" function does not include the end element.
see https://kotlinlang.org/docs/reference/ranges.html
| Kotlin | mit | raphaelm/opacclient,opacapp/opacclient,opacapp/opacclient,opacapp/opacclient,opacapp/opacclient,raphaelm/opacclient,opacapp/opacclient,raphaelm/opacclient |
70fe91b673e11c72863e46c3e3c1449315ae332d | buildSrc/subprojects/plugins/src/main/kotlin/org/gradle/gradlebuild/UpdateBranchStatus.kt | buildSrc/subprojects/plugins/src/main/kotlin/org/gradle/gradlebuild/UpdateBranchStatus.kt | /*
* Copyright 2019 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applica... | /*
* Copyright 2019 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applica... | Use branch instead of tag for green branch | Use branch instead of tag for green branch
| Kotlin | apache-2.0 | blindpirate/gradle,blindpirate/gradle,gradle/gradle,blindpirate/gradle,blindpirate/gradle,gradle/gradle,gradle/gradle,blindpirate/gradle,gradle/gradle,gradle/gradle,blindpirate/gradle,gradle/gradle,gradle/gradle,gradle/gradle,blindpirate/gradle,blindpirate/gradle,blindpirate/gradle,gradle/gradle,gradle/gradle,blindpira... |
f9f268fd483be1e75a04cd7e74dd726a2dccf814 | src/test/kotlin/com/demonwav/mcdev/framework/ProjectBuilderTest.kt | src/test/kotlin/com/demonwav/mcdev/framework/ProjectBuilderTest.kt | /*
* Minecraft Dev for IntelliJ
*
* https://minecraftdev.org
*
* Copyright (c) 2017 minecraft-dev
*
* MIT License
*/
package com.demonwav.mcdev.framework
import com.intellij.openapi.roots.ModuleRootModificationUtil
import com.intellij.testFramework.fixtures.LightCodeInsightFixtureTestCase
abstract class Proj... | /*
* Minecraft Dev for IntelliJ
*
* https://minecraftdev.org
*
* Copyright (c) 2017 minecraft-dev
*
* MIT License
*/
package com.demonwav.mcdev.framework
import com.intellij.openapi.application.runWriteAction
import com.intellij.openapi.roots.ModuleRootModificationUtil
import com.intellij.testFramework.fixtur... | Remove content root again after test to dispose added content entries | Remove content root again after test to dispose added content entries
| Kotlin | mit | DemonWav/MinecraftDev,minecraft-dev/MinecraftDev,DemonWav/IntelliJBukkitSupport,DemonWav/MinecraftDevIntelliJ,DemonWav/MinecraftDev,DemonWav/MinecraftDev,DemonWav/MinecraftDevIntelliJ,minecraft-dev/MinecraftDev,DemonWav/MinecraftDevIntelliJ,minecraft-dev/MinecraftDev |
9777f001eb46f16747f12141c7fc5e14e6130424 | test/v_builders/_38_The_Function_Apply.kt | test/v_builders/_38_The_Function_Apply.kt | package v_builders.examples
import org.junit.Assert.assertEquals
import org.junit.Test
import java.util.*
class _38_The_Function_Apply {
@Test fun testBuildString() {
val expected = buildString()
val actual = StringBuilder().apply {
append("Numbers: ")
for (i in 1..10) {
... | package v_builders.examples
import org.junit.Assert.assertEquals
import org.junit.Test
import java.util.*
class _38_The_Function_Apply {
@Test fun testBuildString() {
val expected = StringBuilder().apply {
append("Numbers: ")
for (i in 1..10) {
append(i)
... | Fix inconsistent unit tests for 38 (The Function Apply) suite. | Fix inconsistent unit tests for 38 (The Function Apply) suite.
Reason: Expected and actual are mixed up.
| Kotlin | mit | Kotlin/kotlin-koans,wickedwukong/kotlin-koans,wickedwukong/kotlin-koans,Carighan/kotlin-koans,enchf/kotlin-koans,zyallday/kotlin-koans,Riccorl/kotlin-koans,TheCoinTosser/Kotlin-Koans---Solutions,Carighan/kotlin-koans,JetBrains/workshop-jb,Riccorl/kotlin-koans,JetBrains/workshop-jb,hughandrewarch/kotlin-koans,trmollet/t... |
77b2bcdf937c8cc8aa4f12071fd191d59af4bb25 | klaxon/src/test/kotlin/com/beust/klaxon/Issue167Test.kt | klaxon/src/test/kotlin/com/beust/klaxon/Issue167Test.kt | package com.beust.klaxon
import org.testng.annotations.Test
data class TestObject(val a: Int, val b: String, val c: Float)
@Test
class Issue167Test {
fun issue167() {
val aJsonObject = json {
obj("a" to 1, "b" to "value")
}
println("Json object: ${aJsonObject.toJsonString()}")... | package com.beust.klaxon
import org.testng.annotations.Test
data class TestObject(val a: Int, val b: String, val c: Float)
@Test
class Issue167Test {
fun issue167() {
val aJsonObject = json {
obj("a" to 1, "b" to "value")
}
println("Json object: ${aJsonObject.toJsonString()}")... | Add output and comment to test | Add output and comment to test
| Kotlin | apache-2.0 | cbeust/klaxon,cbeust/klaxon,cbeust/klaxon |
c1318e4382fbb955bbd78e6ec8e6ea86f3844188 | util/src/main/kotlin/io/sweers/catchup/util/StringExt.kt | util/src/main/kotlin/io/sweers/catchup/util/StringExt.kt | /*
* Copyright (c) 2017 Zac Sweers
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed t... | /*
* Copyright (c) 2017 Zac Sweers
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed t... | Add String.ifNotEmpty helper for later | Add String.ifNotEmpty helper for later
| Kotlin | apache-2.0 | hzsweers/CatchUp,hzsweers/CatchUp,hzsweers/CatchUp,hzsweers/CatchUp |
7eb207867ed81c6a427e7f886e34eda6af8c5854 | library/src/main/kotlin/me/proxer/library/enums/Medium.kt | library/src/main/kotlin/me/proxer/library/enums/Medium.kt | package me.proxer.library.enums
import com.squareup.moshi.Json
import com.squareup.moshi.JsonClass
/**
* Enum holding the available mediums.
*
* @author Ruben Gees
*/
@JsonClass(generateAdapter = false)
enum class Medium {
@Json(name = "animeseries")
ANIMESERIES,
@Json(name = "movie")
MOVIE,
... | package me.proxer.library.enums
import com.squareup.moshi.Json
import com.squareup.moshi.JsonClass
/**
* Enum holding the available mediums.
*
* @author Ruben Gees
*/
@JsonClass(generateAdapter = false)
enum class Medium {
@Json(name = "animeseries")
ANIMESERIES,
@Json(name = "movie")
MOVIE,
... | Add support for visual novels | Add support for visual novels
| Kotlin | mit | proxer/ProxerLibJava |
1f89d17a16789768c72b02415f2319150a0b9ab3 | app/src/test/java/lt/vilnius/tvarkau/dagger/module/TestAnalyticsModule.kt | app/src/test/java/lt/vilnius/tvarkau/dagger/module/TestAnalyticsModule.kt | package lt.vilnius.tvarkau.dagger.module
import android.app.Application
import com.nhaarman.mockito_kotlin.mock
import dagger.Module
import dagger.Provides
import lt.vilnius.tvarkau.analytics.Analytics
import javax.inject.Singleton
/**
* @author Martynas Jurkus
*/
@Module
class TestAnalyticsModule {
@Provides
... | package lt.vilnius.tvarkau.dagger.module
import android.app.Application
import com.mixpanel.android.mpmetrics.MixpanelAPI
import com.nhaarman.mockito_kotlin.mock
import dagger.Module
import dagger.Provides
import lt.vilnius.tvarkau.analytics.Analytics
import javax.inject.Singleton
/**
* @author Martynas Jurkus
*/
@... | Add mock method for MixPanel | Add mock method for MixPanel
| Kotlin | mit | vilnius/tvarkau-vilniu,vilnius/tvarkau-vilniu |
b519e0e4f3c795efba1eb6632d6440d142340bb8 | core/src/main/kotlin/Kotlin/KotlinElementSignatureProvider.kt | core/src/main/kotlin/Kotlin/KotlinElementSignatureProvider.kt | package org.jetbrains.dokka
import com.intellij.psi.PsiElement
import com.intellij.psi.PsiMember
import com.intellij.psi.PsiPackage
import org.jetbrains.kotlin.asJava.elements.KtLightElement
import org.jetbrains.kotlin.descriptors.DeclarationDescriptor
import org.jetbrains.kotlin.name.FqName
import org.jetbrains.kotli... | package org.jetbrains.dokka
import com.intellij.psi.PsiElement
import com.intellij.psi.PsiMember
import com.intellij.psi.PsiPackage
import org.jetbrains.kotlin.asJava.classes.KtLightClassForFacade
import org.jetbrains.kotlin.asJava.elements.KtLightElement
import org.jetbrains.kotlin.descriptors.DeclarationDescriptor
i... | Fix NPE after release 0.9.18 | Fix NPE after release 0.9.18
| Kotlin | apache-2.0 | Kotlin/dokka,Kotlin/dokka,Kotlin/dokka,Kotlin/dokka,Kotlin/dokka,Kotlin/dokka |
202f5ca2d63f9d7e044a2721a054ae6833b00eb2 | rxadapter/src/main/kotlin/xyz/marcb/rxadapter/Section.kt | rxadapter/src/main/kotlin/xyz/marcb/rxadapter/Section.kt | package xyz.marcb.rxadapter
import android.support.v7.widget.RecyclerView
import rx.Observable
class Section: AdapterPart {
private val parts = ArrayList<AdapterPart>()
fun <VH: RecyclerView.ViewHolder> addItem(vhClass: Class<VH>): Item<VH> {
return add(Item(vhClass))
}
fun <I, VH: Recycler... | package xyz.marcb.rxadapter
import android.support.v7.widget.RecyclerView
import rx.Observable
class Section: AdapterPart {
private val parts = ArrayList<AdapterPart>()
fun <VH: RecyclerView.ViewHolder> addItem(vhClass: Class<VH>): Item<VH> {
return add(Item(vhClass))
}
fun <I, VH: Recycler... | Add list of items to a section | Add list of items to a section
| Kotlin | mit | marcbaldwin/RxAdapter,marcbaldwin/RxAdapter |
55f55589e5fc8538fdc05366445d7d12437ae1f6 | viewdsl-appcompat-styles/src/main/java/splitties/viewdsl/appcompat/styles/StyledProgressBars.kt | viewdsl-appcompat-styles/src/main/java/splitties/viewdsl/appcompat/styles/StyledProgressBars.kt | /*
* Copyright (c) 2018. Louis Cognault Ayeva Derman
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable ... | /*
* Copyright (c) 2018. Louis Cognault Ayeva Derman
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable ... | Add largeProgressBar in View DSL AppCompat styles | Add largeProgressBar in View DSL AppCompat styles
| Kotlin | apache-2.0 | LouisCAD/Splitties,LouisCAD/Splitties,LouisCAD/Splitties |
79f0a3e9d8b8d70ba87363889b9e34ece9495c2d | src/main/kotlin/KafkaConsumer.kt | src/main/kotlin/KafkaConsumer.kt | package franz.internal
import org.apache.kafka.clients.consumer.KafkaConsumer
private fun defaultsFromEnv() = System.getenv("KAFKA_HOST").let {
if (it == null || it.length < 1)
emptyMap()
else
mapOf("bootstrap.servers" to listOf(it))
}
private val sensibleDefaults = mapOf(
"key.deseri... | package franz.internal
import org.apache.kafka.clients.consumer.KafkaConsumer
private fun defaultsFromEnv() = System.getenv("KAFKA_HOST").let {
if (it == null || it.length < 1)
emptyMap()
else
mapOf("bootstrap.servers" to listOf(it))
}
private val sensibleDefaults = mapOf(
"key.deseri... | Remove config options that shouldn't be there | Remove config options that shouldn't be there
This closes #1
| Kotlin | mit | zensum/franz,zensum/franz |
f61f9b443540a8dbe7971b53c7d023140d000191 | server/build.gradle.kts | server/build.gradle.kts | import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
plugins {
id("org.springframework.boot") version "2.3.4.RELEASE"
id("io.spring.dependency-management") version "1.0.10.RELEASE"
kotlin("jvm") version "1.3.72"
kotlin("plugin.spring") version "1.3.72"
}
group = "com.sebastiansokolowski"
version = "0.0.1-SNAPSH... | import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
plugins {
id("org.springframework.boot") version "2.3.4.RELEASE"
id("io.spring.dependency-management") version "1.0.10.RELEASE"
kotlin("jvm") version "1.3.72"
kotlin("plugin.spring") version "1.3.72"
}
group = "com.sebastiansokolowski"
version = "0.0.1-SNAPSH... | Add spring boot mail dependency. | Add spring boot mail dependency.
| Kotlin | apache-2.0 | sebastiansokolowski/AuctionHunter---Allegro |
b60a24436e890f685cf0b4489eb2e04ce5b2edda | preferences/src/main/java/splitties/preferences/experimental/SuspendPrefsAccessor.kt | preferences/src/main/java/splitties/preferences/experimental/SuspendPrefsAccessor.kt | /*
* Copyright (c) 2018. Louis Cognault Ayeva Derman
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable ... | /*
* Copyright (c) 2018. Louis Cognault Ayeva Derman
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable ... | Remove no longer needed not UI thread check | Remove no longer needed not UI thread check
| Kotlin | apache-2.0 | LouisCAD/Splitties,LouisCAD/Splitties,LouisCAD/Splitties |
17ca2a06c01c6bc01ab69dd1ab53c54096b9f6ba | backend/src/main/kotlin/com/github/davinkevin/podcastserver/extension/java/net/URI.kt | backend/src/main/kotlin/com/github/davinkevin/podcastserver/extension/java/net/URI.kt | package com.github.davinkevin.podcastserver.extension.java.net
import org.apache.commons.io.FilenameUtils
import java.net.URI
/**
* Created by kevin on 12/07/2020
*/
fun URI.extension(): String = FilenameUtils
.getExtension(this.toASCIIString())
.let { if (it.isEmpty()) "jpg" else it.substringBefore... | package com.github.davinkevin.podcastserver.extension.java.net
import java.net.URI
/**
* Created by kevin on 12/07/2020
*/
fun URI.extension(): String {
val path = this.path
if(!path.contains(".")) {
return "jpg"
}
return path.substringAfterLast(".")
}
| Remove usage of apache commons for file extension extraction | refactor(backend): Remove usage of apache commons for file extension extraction
| Kotlin | apache-2.0 | davinkevin/Podcast-Server,davinkevin/Podcast-Server,davinkevin/Podcast-Server,davinkevin/Podcast-Server,davinkevin/Podcast-Server |
e45eb30ada06bcb68c54ff9c630c60cf3813a4fc | junit-bom/junit-bom.gradle.kts | junit-bom/junit-bom.gradle.kts | description = "${rootProject.description} (Bill of Materials)"
apply(from = "$rootDir/gradle/publishing.gradle.kts")
dependencies {
constraints {
val mavenizedProjects: List<Project> by rootProject.extra
mavenizedProjects.sorted()
.filter { it.name != "junit-platform-console-standalone" }
.forEach { api(... | description = "${rootProject.description} (Bill of Materials)"
apply(from = "$rootDir/gradle/publishing.gradle.kts")
dependencies {
constraints {
val mavenizedProjects: List<Project> by rootProject.extra
mavenizedProjects.sorted()
.filter { it.name != "junit-platform-console-standalone" }
.forEach { api(... | Add sanity checks for BOM generation | Add sanity checks for BOM generation
| Kotlin | epl-1.0 | sbrannen/junit-lambda,junit-team/junit-lambda |
4b79fab19bd04a81f528b25f35aec85d9dd0d63d | plugin-dotnet-server/src/main/kotlin/jetbrains/buildServer/dotnet/DotnetToolTypeAdapter.kt | plugin-dotnet-server/src/main/kotlin/jetbrains/buildServer/dotnet/DotnetToolTypeAdapter.kt | package jetbrains.buildServer.dotnet
import jetbrains.buildServer.tools.ToolTypeAdapter
class DotnetToolTypeAdapter : ToolTypeAdapter() {
override fun getType(): String {
return DotnetConstants.PACKAGE_TYPE
}
override fun getDisplayName(): String {
return DotnetConstants.PACKAGE_TOOL_TYPE... | package jetbrains.buildServer.dotnet
import jetbrains.buildServer.tools.ToolTypeAdapter
class DotnetToolTypeAdapter : ToolTypeAdapter() {
override fun getType(): String {
return DotnetConstants.PACKAGE_TYPE
}
override fun getDisplayName(): String {
return DotnetConstants.PACKAGE_TOOL_TYPE... | Update .NET Integration tool description | Update .NET Integration tool description
Issue: #92
| Kotlin | apache-2.0 | JetBrains/teamcity-dnx-plugin |
c036b3fd0f4d82f1b6a069cd48a1cdfdada54bbd | sample/src/androidMain/kotlin/com/louiscad/splittiessample/extensions/coroutines/Racing.kt | sample/src/androidMain/kotlin/com/louiscad/splittiessample/extensions/coroutines/Racing.kt | /*
* Copyright 2019 Louis Cognault Ayeva Derman. Use of this source code is governed by the Apache 2.0 license.
*/
package com.louiscad.splittiessample.extensions.coroutines
import kotlinx.coroutines.CoroutineScope
import kotlinx.coroutines.CoroutineStart
import kotlinx.coroutines.Deferred
import kotlinx.coroutines... | /*
* Copyright 2019 Louis Cognault Ayeva Derman. Use of this source code is governed by the Apache 2.0 license.
*/
package com.louiscad.splittiessample.extensions.coroutines
import kotlinx.coroutines.CoroutineScope
import kotlinx.coroutines.CoroutineStart
import kotlinx.coroutines.Deferred
import kotlinx.coroutines... | Simplify raceOf implementation and remove useless inline. | Simplify raceOf implementation and remove useless inline.
| Kotlin | apache-2.0 | LouisCAD/Splitties,LouisCAD/Splitties,LouisCAD/Splitties |
60add831225bc748c4e226ac260861d8bf63cbff | app/src/main/java/net/squanchy/schedule/view/EventViewHolder.kt | app/src/main/java/net/squanchy/schedule/view/EventViewHolder.kt | package net.squanchy.schedule.view
import android.support.v7.widget.RecyclerView
import net.squanchy.schedule.domain.view.Event
class EventViewHolder(itemView: EventItemView) : RecyclerView.ViewHolder(itemView) {
fun updateWith(event: Event, listener: ScheduleViewPagerAdapter.OnEventClickedListener?) {
... | package net.squanchy.schedule.view
import android.support.v7.widget.RecyclerView
import net.squanchy.schedule.domain.view.Event
class EventViewHolder(itemView: EventItemView) : RecyclerView.ViewHolder(itemView) {
fun updateWith(event: Event, listener: ScheduleViewPagerAdapter.OnEventClickedListener?) {
... | Rewrite setOnClickListener on a single line | Rewrite setOnClickListener on a single line
| Kotlin | apache-2.0 | squanchy-dev/squanchy-android,squanchy-dev/squanchy-android,squanchy-dev/squanchy-android |
d1cabe515d473b6f2766c06d9e1b74efd0f14c89 | kakao/src/main/kotlin/com/agoda/kakao/delegate/Delegate.kt | kakao/src/main/kotlin/com/agoda/kakao/delegate/Delegate.kt | package com.agoda.kakao.delegate
import com.agoda.kakao.intercept.Interceptor
/**
* Base delegate interface.
*
* Provides functionality of aggregating interceptors and invoking them on `check`
* and `perform` invocations.
*
* @see Interceptor
*/
interface Delegate<T, C, P> {
var interaction: T
fun vie... | package com.agoda.kakao.delegate
import com.agoda.kakao.intercept.Interceptor
/**
* Base delegate interface.
*
* Provides functionality of aggregating interceptors and invoking them on `check`
* and `perform` invocations.
*
* @see Interceptor
*/
interface Delegate<T, C, P> {
var interaction: T
fun vie... | Remove return type form aggregation function | Remove return type form aggregation function
| Kotlin | apache-2.0 | agoda-com/Kakao |
3cd46be440460cb2776aa9441a56b2bc607b60ef | src/main/kotlin/com/github/shiraji/Extensions.kt | src/main/kotlin/com/github/shiraji/Extensions.kt | package com.github.shiraji
import git4idea.GitCommit
import java.math.BigInteger
import java.security.MessageDigest
fun String.toMd5() = BigInteger(1, MessageDigest.getInstance("MD5").digest(this.toByteArray())).toString(16)
fun String.subtract(text: String) = this.replace(text, "")
fun GitCommit.getPullRequestNum... | package com.github.shiraji
import git4idea.GitCommit
import java.math.BigInteger
import java.security.MessageDigest
fun String.toMd5() = BigInteger(1, MessageDigest.getInstance("MD5").digest(this.toByteArray())).toString(16)
fun String.subtract(text: String) = this.replace(text, "")
fun GitCommit.getPullRequestNum... | Add extensions for GitCommit for finding squashed pull request commit | Add extensions for GitCommit for finding squashed pull request commit
| Kotlin | apache-2.0 | shiraji/find-pull-request |
c18a78dfc85aefdabba6ee0d01bea1067ece150f | kotlin/src/com/s13g/aoc/aoc2020/Day15.kt | kotlin/src/com/s13g/aoc/aoc2020/Day15.kt | package com.s13g.aoc.aoc2020
import com.s13g.aoc.Result
import com.s13g.aoc.Solver
import java.util.*
/**
* --- Day 15: Rambunctious Recitation ---
* https://adventofcode.com/2020/day/15
*/
class Day15 : Solver {
override fun solve(lines: List<String>): Result {
val input = lines[0].split(',').map { it.toIn... | package com.s13g.aoc.aoc2020
import com.s13g.aoc.Result
import com.s13g.aoc.Solver
/**
* --- Day 15: Rambunctious Recitation ---
* https://adventofcode.com/2020/day/15
*/
class Day15 : Solver {
override fun solve(lines: List<String>): Result {
val input = lines[0].split(',').map { it.toInt() }
return Re... | Speed up solution. No need for a TreeSet, items are added in increasing order anyway. | Speed up solution. No need for a TreeSet, items are added in increasing order anyway.
| Kotlin | apache-2.0 | shaeberling/euler,shaeberling/euler,shaeberling/euler,shaeberling/euler |
d215913d0ba8493b8255207f1938a1a086f91021 | rider/src/main/kotlin/com/jetbrains/rider/plugins/unity/ideaInterop/fileTypes/asmdef/AsmDefActionCallPolicy.kt | rider/src/main/kotlin/com/jetbrains/rider/plugins/unity/ideaInterop/fileTypes/asmdef/AsmDefActionCallPolicy.kt | package com.jetbrains.rider.plugins.unity.ideaInterop.fileTypes.asmdef
import com.intellij.openapi.actionSystem.IdeActions
import com.intellij.psi.PsiElement
import com.jetbrains.rdclient.hyperlinks.FrontendCtrlClickHost
import com.jetbrains.rider.actions.RiderActionCallStrategy
import com.jetbrains.rider.actions.Ride... | package com.jetbrains.rider.plugins.unity.ideaInterop.fileTypes.asmdef
import com.intellij.openapi.actionSystem.IdeActions
import com.intellij.psi.PsiElement
import com.jetbrains.rdclient.hyperlinks.FrontendCtrlClickHost
import com.jetbrains.rider.actions.RiderActionCallStrategy
import com.jetbrains.rider.actions.Ride... | Fix missing rename asmdef action in Rider | Fix missing rename asmdef action in Rider
| Kotlin | apache-2.0 | JetBrains/resharper-unity,JetBrains/resharper-unity,JetBrains/resharper-unity |
3f296b1f7b3a7aad3643a7d925676909658cabe4 | src/main/kotlin/ee/mcdimus/matewp/service/FileSystemService.kt | src/main/kotlin/ee/mcdimus/matewp/service/FileSystemService.kt | package ee.mcdimus.matewp.service
import java.nio.file.Files
import java.nio.file.Path
import java.nio.file.Paths
import java.util.*
/**
* @author Dmitri Maksimov
*/
class FileSystemService {
companion object {
private const val HOME = "HOME"
}
fun getHomeDirectory(): Path {
val homeDirectoryPath = ... | package ee.mcdimus.matewp.service
import java.nio.file.Files
import java.nio.file.Path
import java.nio.file.Paths
import java.util.*
/**
* @author Dmitri Maksimov
*/
class FileSystemService {
companion object {
private const val USER_HOME = "user.home"
}
fun getHomeDirectory(): Path {
val homeDirect... | Use system property 'user.home' instead of environment variable HOME, which is available only on Linux. | Use system property 'user.home' instead of environment variable HOME, which is available only on Linux.
| Kotlin | mit | mcdimus/mate-wp,mcdimus/mate-wp |
fd868b2adcb79dcae2500d84bbf3f28adf17a0c8 | ktor-core/src/org/jetbrains/ktor/http/RequestConnectionPoint.kt | ktor-core/src/org/jetbrains/ktor/http/RequestConnectionPoint.kt | package org.jetbrains.ktor.http
/**
* Represents request address information is used to make a call.
* There are at least two possible instances: "local" is how we see request at the server application and
* "actual" is what we can recover from proxy provided headers.
*/
interface RequestConnectionPoint {
/**
... | package org.jetbrains.ktor.http
/**
* Represents request address information is used to make a call.
* There are at least two possible instances: "local" is how we see request at the server application and
* "actual" is what we can recover from proxy provided headers.
*/
interface RequestConnectionPoint {
/**
... | Add documentation to a `version` property | Add documentation to a `version` property
| Kotlin | apache-2.0 | ktorio/ktor,ktorio/ktor,ktorio/ktor,ktorio/ktor |
8f52e9b8a31e6cc5c5d9c105bab34b57d5fe3d5b | kotpref/src/main/kotlin/com/chibatching/kotpref/KotprefPreferences.kt | kotpref/src/main/kotlin/com/chibatching/kotpref/KotprefPreferences.kt | package com.chibatching.kotpref
import android.annotation.TargetApi
import android.content.SharedPreferences
import android.os.Build
import com.chibatching.kotpref.pref.StringSetPref
import java.util.*
internal class KotprefPreferences(val preferences: SharedPreferences) : SharedPreferences by preferences {
ove... | package com.chibatching.kotpref
import android.annotation.TargetApi
import android.content.SharedPreferences
import android.os.Build
import com.chibatching.kotpref.pref.StringSetPref
import java.util.*
internal class KotprefPreferences(val preferences: SharedPreferences) : SharedPreferences by preferences {
ove... | Fix NoClassDefFoundError when using blockingBulk on API <= 6.0 | Fix NoClassDefFoundError when using blockingBulk on API <= 6.0
| Kotlin | apache-2.0 | chibatching/Kotpref |
8b270f187396ff93aaefce24102511af002e2b43 | app/src/main/java/pl/mg6/likeornot/GridActivity.kt | app/src/main/java/pl/mg6/likeornot/GridActivity.kt | package pl.mg6.likeornot
import android.os.Bundle
import android.support.v4.view.ViewPager
import android.support.v7.app.AppCompatActivity
class GridActivity : AppCompatActivity() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContentView(R.layout.gri... | package pl.mg6.likeornot
import android.os.Bundle
import android.support.v4.view.ViewPager
import android.support.v7.app.AppCompatActivity
import android.util.Log
class GridActivity : AppCompatActivity() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
set... | Use bound callable references as Consumers. | [refactoring] Use bound callable references as Consumers.
| Kotlin | apache-2.0 | mg6maciej/fluffy-octo-rotary-phone,mg6maciej/fluffy-octo-rotary-phone,mg6maciej/fluffy-octo-rotary-phone |
8199c1792228a3159707a333172430a81fb80ed2 | src/main/java/uk/co/reecedunn/intellij/plugin/marklogic/query/MimeTypes.kt | src/main/java/uk/co/reecedunn/intellij/plugin/marklogic/query/MimeTypes.kt | /*
* Copyright (C) 2017 Reece H. Dunn
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed t... | /*
* Copyright (C) 2017 Reece H. Dunn
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed t... | Create a MimeType base class for QueryType. | Create a MimeType base class for QueryType.
| Kotlin | apache-2.0 | rhdunn/marklogic-intellij-plugin |
1c14c4ac824f2242cc8beeb14f836ee4a9e030cc | src/main/kotlin/main/main.kt | src/main/kotlin/main/main.kt | package main
/**
* Created by allen on 7/28/16.
*/
import spark.Spark.*
import com.google.gson.Gson
import controllers.SqliteController
import models.User
import spark.ModelAndView
import spark.template.handlebars.HandlebarsTemplateEngine
import java.util.*
fun main(args : Array<String>) {
port(3000)
stati... | package main
/**
* Created by allen on 7/28/16.
*/
import spark.Spark.*
import com.google.gson.Gson
import controllers.SqliteController
import models.User
import spark.ModelAndView
import spark.template.handlebars.HandlebarsTemplateEngine
import java.util.*
fun main(args : Array<String>) {
port(3000)
stati... | Edit routes to allow matches with trailing slash | Edit routes to allow matches with trailing slash
| Kotlin | mit | allen-garvey/photog-spark,allen-garvey/photog-spark,allen-garvey/photog-spark |
ac74d575e8d9fed8b35abf2ff3526e9ad55f8879 | buildSrc/build.gradle.kts | buildSrc/build.gradle.kts | import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
buildscript {
val pluginsExperiments by extra(
"org.gradle.kotlin:gradle-kotlin-dsl-conventions:0.2.0"
)
dependencies {
classpath(pluginsExperiments)
}
configure(listOf(repositories, project.repositories)) {
gradlePlu... | import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
buildscript {
val kotlinDslConventions by extra("org.gradle.kotlin:gradle-kotlin-dsl-conventions:0.2.0")
dependencies {
classpath(kotlinDslConventions)
}
configure(listOf(repositories, project.repositories)) {
gradlePluginPortal(... | Rename extra property to better reflect new meaning | Rename extra property to better reflect new meaning
Signed-off-by: Paul Merlin <a027184a55211cd23e3f3094f1fdc728df5e0500@gradle.com>
| Kotlin | apache-2.0 | robinverduijn/gradle,blindpirate/gradle,blindpirate/gradle,robinverduijn/gradle,gradle/gradle,blindpirate/gradle,gradle/gradle,robinverduijn/gradle,gradle/gradle,gradle/gradle,gradle/gradle,robinverduijn/gradle,robinverduijn/gradle,blindpirate/gradle,blindpirate/gradle,robinverduijn/gradle,gradle/gradle,robinverduijn/g... |
6c10419b473bafb52fadab257c1b5af743d33aaa | core/src/main/java/fr/masciulli/drinks/core/drinks/DrinksRepository.kt | core/src/main/java/fr/masciulli/drinks/core/drinks/DrinksRepository.kt | package fr.masciulli.drinks.core.drinks
class DrinksRepository(private val remoteSource: DrinksSource) : DrinksSource {
override fun getDrinks() = remoteSource.getDrinks()
override fun getDrink(id: String) = remoteSource.getDrink(id)
} | package fr.masciulli.drinks.core.drinks
import rx.Observable
class DrinksRepository(private val remoteSource: DrinksSource) : DrinksSource {
private val cachedDrinks: MutableMap<String, Drink> = LinkedHashMap()
private var cached = false
override fun getDrinks(): Observable<List<Drink>> {
if (cac... | Add cache to drinks repository | Add cache to drinks repository
| Kotlin | apache-2.0 | amasciul/Drinks,amasciul/Drinks,amasciul/Drinks |
4813b5f89baa6914efa41e1a735668f4a915ec1c | app/src/main/kotlin/com/octo/mob/octomeuh/countdown/utils/SecondCountDownTimer.kt | app/src/main/kotlin/com/octo/mob/octomeuh/countdown/utils/SecondCountDownTimer.kt | package com.octo.mob.octomeuh.countdown.utils
import android.os.CountDownTimer
interface CountDownListener {
fun onValueUpdated(countValueInSeconds: Long)
fun onCountDownOver()
}
open class SecondCountDownTimer(val secondsToCount: Int, val countDownListener: CountDownListener) : CountDownTimer((secondsToCo... | package com.octo.mob.octomeuh.countdown.utils
import android.os.CountDownTimer
interface CountDownListener {
fun onValueUpdated(countValueInSeconds: Long)
fun onCountDownOver()
}
open class SecondCountDownTimer(secondsToCount: Int, val countDownListener: CountDownListener) :
CountDownTimer... | Decrease contdown refresh interval in order to have a smoother display | Decrease contdown refresh interval in order to have a smoother display
| Kotlin | mit | rpradal/OCTOMeuh |
ec7d24a6f8d67e1ce43f29c59994ff686020c2b9 | modules/kobalt-plugin-api/src/main/kotlin/com/beust/kobalt/SystemProperties.kt | modules/kobalt-plugin-api/src/main/kotlin/com/beust/kobalt/SystemProperties.kt | package com.beust.kobalt
class SystemProperties {
companion object {
val javaBase =
System.getenv("JAVA_HOME")
?: System.getProperty("java.home")
?: throw IllegalArgumentException("JAVA_HOME not defined")
val javaVersion = System.getProperty("java.ver... | package com.beust.kobalt
class SystemProperties {
companion object {
val javaBase : String
get() {
val jh = System.getenv("JAVA_HOME")
?: System.getProperty("java.home")
?: throw IllegalArgumentException("JAVA_HOME not defined")
... | Make sure JAVA_HOME points to the JDK and not the JRE. | Make sure JAVA_HOME points to the JDK and not the JRE.
Should fix https://github.com/cbeust/kobalt/issues/428.
| Kotlin | apache-2.0 | cbeust/kobalt,ethauvin/kobalt,ethauvin/kobalt,cbeust/kobalt,ethauvin/kobalt,ethauvin/kobalt,cbeust/kobalt |
9e79968a4a77d5f1fcf482b94294880bc0a6b964 | platform/lang-api/src/com/intellij/codeInsight/completion/ml/MLFeatureValue.kt | platform/lang-api/src/com/intellij/codeInsight/completion/ml/MLFeatureValue.kt | // Copyright 2000-2019 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package com.intellij.codeInsight.completion.ml
sealed class MLFeatureValue
class BinaryValue private constructor(val value: Boolean) : MLFeatureValue() {
companion object {
... | // Copyright 2000-2019 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package com.intellij.codeInsight.completion.ml
sealed class MLFeatureValue
class BinaryValue private constructor(val value: Boolean) : MLFeatureValue() {
companion object {
... | Add @JvmStatic to simplify usages in scala | [stats-collector] Add @JvmStatic to simplify usages in scala
GitOrigin-RevId: ce190ca00f1a74518a30b79269178dc95254fbaa | Kotlin | apache-2.0 | allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/int... |
a252a8acee8c26ce8ca39f1ae8758d5ed2af0c8e | app/src/main/java/eu/kanade/tachiyomi/util/system/MiuiUtil.kt | app/src/main/java/eu/kanade/tachiyomi/util/system/MiuiUtil.kt | package eu.kanade.tachiyomi.util.system
import android.annotation.SuppressLint
import timber.log.Timber
object MiuiUtil {
fun isMiui(): Boolean {
return getSystemProperty("ro.miui.ui.version.name")?.isNotEmpty() ?: false
}
@SuppressLint("PrivateApi")
fun isMiuiOptimizationDisabled(): Boolean... | package eu.kanade.tachiyomi.util.system
import android.annotation.SuppressLint
import timber.log.Timber
object MiuiUtil {
fun isMiui(): Boolean {
return getSystemProperty("ro.miui.ui.version.name")?.isNotEmpty() ?: false
}
@SuppressLint("PrivateApi")
fun isMiuiOptimizationDisabled(): Boolean... | Update detection of disabled MIUI Optimization | Update detection of disabled MIUI Optimization
| Kotlin | apache-2.0 | CarlosEsco/tachiyomi,inorichi/tachiyomi,inorichi/mangafeed,inorichi/mangafeed,inorichi/tachiyomi |
6d570725ccc941762c710f35f9af47a1b31f406f | src/main/kotlin/com/reduks/reduks/combine_reducers/CombineReducers.kt | src/main/kotlin/com/reduks/reduks/combine_reducers/CombineReducers.kt | package com.reduks.reduks.combine_reducers
import com.reduks.reduks.Action
/**
* Created by bloder on 18/02/18.
*/
class CombineReducers<State>(private val reducers: Array<out (State, Action<State>) -> State>) {
fun combine() : (State, Action<State>) -> State = fun (initialState: State, action: Action<State>)... | package com.reduks.reduks.combine_reducers
import com.reduks.reduks.Action
/**
* Created by bloder on 18/02/18.
*/
class CombineReducers<State>(private val reducers: Array<out (State, Action<State>) -> State>) {
fun combine() : (State, Action<State>) -> State = fun (initialState: State, action: Action<State>)... | Decrease combine reducers solution size with fold | Decrease combine reducers solution size with fold
| Kotlin | mit | Reduks/Reduks |
aaaa2af3a91a6df16c90cdc2ca301982c3bc5db3 | app/src/main/java/chat/rocket/android/chatdetails/viewmodel/ChatDetailsViewModel.kt | app/src/main/java/chat/rocket/android/chatdetails/viewmodel/ChatDetailsViewModel.kt | package chat.rocket.android.chatdetails.viewmodel
import androidx.lifecycle.LiveData
import androidx.lifecycle.MutableLiveData
import androidx.lifecycle.Transformations
import androidx.lifecycle.ViewModel
import chat.rocket.android.chatdetails.domain.ChatDetails
import chat.rocket.android.db.ChatRoomDao
class ChatDet... | package chat.rocket.android.chatdetails.viewmodel
import androidx.lifecycle.LiveData
import androidx.lifecycle.MutableLiveData
import androidx.lifecycle.Transformations
import androidx.lifecycle.ViewModel
import chat.rocket.android.chatdetails.domain.ChatDetails
import chat.rocket.android.db.ChatRoomDao
class ChatDet... | Fix a null pointer exeption. | Fix a null pointer exeption.
| Kotlin | mit | RocketChat/Rocket.Chat.Android,RocketChat/Rocket.Chat.Android.Lily,RocketChat/Rocket.Chat.Android.Lily,RocketChat/Rocket.Chat.Android |
641e9341d54e0b4c7e71bef861750b91d07e47e5 | Owl/app/src/main/java/com/example/owl/ui/utils/Scrim.kt | Owl/app/src/main/java/com/example/owl/ui/utils/Scrim.kt | /*
* Copyright 2020 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applica... | /*
* Copyright 2020 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applica... | Update scrim to use `drawWithCache` | [Owl] Update scrim to use `drawWithCache`
Change-Id: I157671de17dd51a9e5031d07f49eb6ccf5b7d1b9
| Kotlin | apache-2.0 | android/compose-samples,android/compose-samples |
8c31d1261589283f1b4690283e840059e6068c36 | thirtyinch-kotlin/src/test/java/net/grandcentrix/thirtyinch/kotlin/TiPresenterTest.kt | thirtyinch-kotlin/src/test/java/net/grandcentrix/thirtyinch/kotlin/TiPresenterTest.kt | package net.grandcentrix.thirtyinch.kotlin
import com.nhaarman.mockito_kotlin.mock
import com.nhaarman.mockito_kotlin.verify
import net.grandcentrix.thirtyinch.TiPresenter
import net.grandcentrix.thirtyinch.TiView
import org.junit.Test
import org.junit.runner.RunWith
import org.junit.runners.JUnit4
@RunWith(JUnit4::c... | package net.grandcentrix.thirtyinch.kotlin
import com.nhaarman.mockito_kotlin.*
import net.grandcentrix.thirtyinch.TiPresenter
import net.grandcentrix.thirtyinch.TiView
import org.junit.*
import org.junit.runner.*
import org.junit.runners.*
@RunWith(JUnit4::class)
class TiPresenterTest {
interface View : TiView ... | Add test for deliverToView without view | Add test for deliverToView without view
| Kotlin | apache-2.0 | grandcentrix/ThirtyInch,grandcentrix/ThirtyInch |
e8738d5d6f503bc85d6d97605673a2f7783c285a | src/main/java/pink/madis/agptweeter/checker.kt | src/main/java/pink/madis/agptweeter/checker.kt | package pink.madis.agptweeter
import java.nio.charset.StandardCharsets.UTF_8
import java.io.IOException
fun isNewRemoteVersion(remoteVersion: Version, local: Fetcher): Boolean {
val localVersion = local.latestVersion() ?: return true // no local, so definitely later
return remoteVersion > localVersion
}
fun che... | package pink.madis.agptweeter
import java.nio.charset.StandardCharsets.UTF_8
import java.io.IOException
fun isNewRemoteVersion(remoteVersion: Version, local: Fetcher): Boolean {
val localVersion = local.latestVersion() ?: return true // no local, so definitely later
return remoteVersion > localVersion
}
fun che... | Update local cache after miss | Update local cache after miss
| Kotlin | mit | madisp/agp-tweeter |
1b05252823cad785c3064bd1fcdfe5956dad3f04 | src/test/java/com/masahirosaito/spigot/homes/tests/Permission.kt | src/test/java/com/masahirosaito/spigot/homes/tests/Permission.kt | package com.masahirosaito.spigot.homes.tests
enum class Permission(val permission: String) {
HOME_DEFAULT("homes.command"),
HOME_NAME("homes.command.name"),
HOME_PLAYER("homes.command.player"),
HOME_PLAYER_NAME("homes.command.player.name"),
HOME_SET("homes.command.set"),
HOME_SET_NAME("homes.... | package com.masahirosaito.spigot.homes.tests
enum class Permission(val permission: String) {
HOME_DEFAULT("homes.command"),
HOME_NAME("homes.command.name"),
HOME_PLAYER("homes.command.player"),
HOME_PLAYER_NAME("homes.command.player.name"),
HOME_SET("homes.command.set"),
HOME_SET_NAME("homes.... | Add two permissions for private command | Add two permissions for private command
| Kotlin | apache-2.0 | Homes-MinecraftServerMod/Homes,Homes-MinecraftServerMod/Homes |
a5adf4035b6c2ab39dbf889bbb4955c926adb360 | app/src/main/java/pl/mg6/likeornot/commons/Collections.kt | app/src/main/java/pl/mg6/likeornot/commons/Collections.kt | package pl.mg6.likeornot.commons
fun <T> List<T>.batch(chunkSize: Int): List<List<T>> {
if (chunkSize <= 0) {
throw IllegalArgumentException("chunkSize must be greater than 0")
}
val capacity = (size + chunkSize - 1) / chunkSize
val list = ArrayList<ArrayList<T>>(capacity)
for (i in 0 until... | package pl.mg6.likeornot.commons
fun <T> List<T>.batch(chunkSize: Int): List<List<T>> {
require(chunkSize > 0) { "chunkSize must be greater than 0" }
val chunksCount = (size + chunkSize - 1) / chunkSize
val chunkedList = ArrayList<List<T>>(chunksCount)
for (i in 0 until size step chunkSize) {
c... | Use subList instead of creating new List objects for chunks. | [optimization] Use subList instead of creating new List objects for chunks.
| Kotlin | apache-2.0 | mg6maciej/fluffy-octo-rotary-phone,mg6maciej/fluffy-octo-rotary-phone,mg6maciej/fluffy-octo-rotary-phone |
209434dd2803345d75cd56c51e4ea0257e22a532 | app/src/main/java/com/doctoror/particleswallpaper/data/config/HardwareCanvasBlacklist.kt | app/src/main/java/com/doctoror/particleswallpaper/data/config/HardwareCanvasBlacklist.kt | package com.doctoror.particleswallpaper.data.config
object HardwareCanvasBlacklist {
private val blackList = hashSetOf(
"bullhead",
"dreamlte",
"gemini",
"HWANE",
"HWCMR09",
"joan",
"polaris",
"wayne",
"why... | package com.doctoror.particleswallpaper.data.config
object HardwareCanvasBlacklist {
private val blackList = hashSetOf(
"bullhead",
"degaswifiue",
"dreamlte",
"gemini",
"grandneove3g",
"heroqlteaio",
"HWANE",
"HWCMR09"... | Add devices to hardware canvas blacklist | Add devices to hardware canvas blacklist
| Kotlin | apache-2.0 | Doctoror/ParticleConstellationsLiveWallpaper,Doctoror/ParticleConstellationsLiveWallpaper |
73628ef6acb75c8df19a3e42fd56decaa2b06570 | .teamcity/src/main/kotlin/util/WarmupEc2Agent.kt | .teamcity/src/main/kotlin/util/WarmupEc2Agent.kt | package util
import common.Os
import common.buildToolGradleParameters
import common.gradleWrapper
import jetbrains.buildServer.configs.kotlin.v2019_2.BuildType
import jetbrains.buildServer.configs.kotlin.v2019_2.Requirement
import jetbrains.buildServer.configs.kotlin.v2019_2.RequirementType
import jetbrains.buildServe... | package util
import common.Os
import common.buildToolGradleParameters
import common.gradleWrapper
import jetbrains.buildServer.configs.kotlin.v2019_2.BuildType
import jetbrains.buildServer.configs.kotlin.v2019_2.Requirement
import jetbrains.buildServer.configs.kotlin.v2019_2.RequirementType
import jetbrains.buildServe... | Use lenient dependency verification for EC2 warmup builds | Use lenient dependency verification for EC2 warmup builds
We run a `resolveAllDependencies` build to warm up the EC2 agent image.
However, sometimes the build fails with dependency verification failures,
which is not required because we just want to download all artifacts.
| Kotlin | apache-2.0 | blindpirate/gradle,blindpirate/gradle,gradle/gradle,blindpirate/gradle,gradle/gradle,gradle/gradle,blindpirate/gradle,blindpirate/gradle,gradle/gradle,gradle/gradle,gradle/gradle,gradle/gradle,blindpirate/gradle,blindpirate/gradle,gradle/gradle,blindpirate/gradle,blindpirate/gradle,blindpirate/gradle,gradle/gradle,grad... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.