repo_name stringlengths 7 81 | path stringlengths 4 242 | copies stringclasses 95
values | size stringlengths 1 6 | content stringlengths 3 991k | license stringclasses 15
values |
|---|---|---|---|---|---|
Cognifide/gradle-aem-plugin | src/main/kotlin/com/cognifide/gradle/aem/instance/tasks/InstanceReload.kt | 1 | 1052 | package com.cognifide.gradle.aem.instance.tasks
import com.cognifide.gradle.aem.common.instance.action.AwaitUpAction
import com.cognifide.gradle.aem.common.instance.action.ReloadAction
import com.cognifide.gradle.aem.common.instance.names
import com.cognifide.gradle.aem.common.tasks.Instance
import org.gradle.api.task... | apache-2.0 |
80998062/Fank | presentation/src/main/java/com/sinyuk/fanfou/ui/status/StatusView.kt | 1 | 8490 | /*
*
* * Apache License
* *
* * Copyright [2017] Sinyuk
* *
* * 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
* *... | mit |
TimePath/java-vfs | src/main/kotlin/com/timepath/vfs/provider/jdbc/JDBCTable.kt | 1 | 1410 | package com.timepath.vfs.provider.jdbc
import com.timepath.vfs.MockFile
import com.timepath.vfs.SimpleVFile
import com.timepath.vfs.provider.ProviderStub
import org.jetbrains.annotations.NonNls
import java.sql.SQLException
import java.text.MessageFormat
import java.util.LinkedList
import java.util.logging.Level
/**
... | artistic-2.0 |
adobe/S3Mock | integration-tests/src/test/kotlin/com/adobe/testing/s3mock/its/CopyObjectV1IT.kt | 1 | 17900 | /*
* Copyright 2017-2022 Adobe.
*
* 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 ... | apache-2.0 |
fkorotkov/k8s-kotlin-dsl | DSLs/kubernetes/dsl/src/main/kotlin-gen/com/fkorotkov/kubernetes/nodePublishSecretRef.kt | 1 | 912 | // GENERATED
package com.fkorotkov.kubernetes
import io.fabric8.kubernetes.api.model.CSIPersistentVolumeSource as model_CSIPersistentVolumeSource
import io.fabric8.kubernetes.api.model.CSIVolumeSource as model_CSIVolumeSource
import io.fabric8.kubernetes.api.model.LocalObjectReference as model_LocalObjectReference
imp... | mit |
vector-im/vector-android | vector/src/main/java/im/vector/preference/RoomAvatarPreference.kt | 2 | 1639 | /*
* Copyright 2018 New Vector Ltd
*
* 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 ... | apache-2.0 |
mikepenz/MaterialDrawer | materialdrawer/src/main/java/com/mikepenz/materialdrawer/model/AbstractToggleableDrawerItem.kt | 1 | 3288 | package com.mikepenz.materialdrawer.model
import android.view.View
import android.widget.CompoundButton
import android.widget.ToggleButton
import androidx.annotation.LayoutRes
import com.mikepenz.materialdrawer.R
import com.mikepenz.materialdrawer.interfaces.OnCheckedChangeListener
import com.mikepenz.materialdrawer.m... | apache-2.0 |
aosp-mirror/platform_frameworks_support | room/compiler/src/test/kotlin/androidx/room/processor/RawQueryMethodProcessorTest.kt | 1 | 11947 | /*
* Copyright 2018 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
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applica... | apache-2.0 |
chiken88/passnotes | app/src/main/kotlin/com/ivanovsky/passnotes/presentation/note_editor/view/TextInputLines.kt | 1 | 128 | package com.ivanovsky.passnotes.presentation.note_editor.view
enum class TextInputLines {
SINGLE_LINE,
MULTIPLE_LINES
} | gpl-2.0 |
chiken88/passnotes | app/src/main/kotlin/com/ivanovsky/passnotes/domain/interactor/filepicker/FilePickerInteractor.kt | 1 | 670 | package com.ivanovsky.passnotes.domain.interactor.filepicker
import com.ivanovsky.passnotes.data.entity.FileDescriptor
import com.ivanovsky.passnotes.data.entity.OperationResult
import com.ivanovsky.passnotes.data.repository.file.FileSystemResolver
class FilePickerInteractor(private val fileSystemResolver: FileSystem... | gpl-2.0 |
deltadak/plep | src/main/kotlin/nl/deltadak/plep/ui/taskcell/TaskLayout.kt | 1 | 4729 | package nl.deltadak.plep.ui.taskcell
import javafx.geometry.Pos
import javafx.scene.control.CheckBox
import javafx.scene.control.ComboBox
import javafx.scene.control.Label
import javafx.scene.control.TreeItem
import javafx.scene.layout.HBox
import javafx.scene.layout.Priority
import javafx.scene.layout.Region
import j... | mit |
orgzly/orgzly-android | app/src/main/java/com/orgzly/android/query/QueryTokenizer.kt | 1 | 2478 | package com.orgzly.android.query
class QueryTokenizer(val str: String, private val groupOpen: String, private val groupClose: String) {
val tokens = tokanize(str)
var nextToken = 0
fun hasMoreTokens(): Boolean = nextToken < tokens.size
fun nextToken() = tokens[nextToken++]
private fun tokanize(... | gpl-3.0 |
orgzly/orgzly-android | app/src/main/java/com/orgzly/android/ui/drawer/DrawerNavigationView.kt | 1 | 5383 | package com.orgzly.android.ui.drawer
import android.content.Intent
import android.content.res.Resources
import android.view.Menu
import androidx.lifecycle.Observer
import com.google.android.material.navigation.NavigationView
import com.orgzly.BuildConfig
import com.orgzly.R
import com.orgzly.android.AppIntent
import c... | gpl-3.0 |
Yorxxx/played-next-kotlin | app/src/test/java/com/piticlistudio/playednext/data/entity/mapper/datasources/image/GiantbombImageMapperTest.kt | 1 | 5221 | package com.piticlistudio.playednext.data.entity.mapper.datasources.image
import com.piticlistudio.playednext.data.entity.giantbomb.GiantbombGameImage
import com.piticlistudio.playednext.test.factory.DataFactory
import com.piticlistudio.playednext.test.factory.GameImageFactory.Factory.makeGiantbombGameImage
import org... | mit |
whym/apps-android-commons | app/src/test/kotlin/fr/free/nrw/commons/TestCommonsApplication.kt | 1 | 3762 | package fr.free.nrw.commons
import android.content.ContentProviderClient
import android.content.Context
import android.content.SharedPreferences
import android.support.v4.util.LruCache
import com.nhaarman.mockito_kotlin.mock
import com.squareup.leakcanary.RefWatcher
import fr.free.nrw.commons.auth.AccountUtil
import f... | apache-2.0 |
kmruiz/sonata | frontend/src/main/kotlin/io/sonatalang/snc/frontend/domain/token/NewLineToken.kt | 1 | 324 | package io.sonatalang.snc.frontend.domain.token
object NewLineToken : BasicToken(false), TokenFactory<NewLineToken> {
override fun with(character: Char) = this
override fun toString() = "\n"
override fun isSuitable(character: Char) = character == '\n'
override fun create(character: Char) = NewLineToke... | gpl-2.0 |
OpenConference/OpenConference-android | app/src/main/java/com/openconference/sessiondetails/presentationmodel/SessionDetailsPresentationModelTransformer.kt | 1 | 2271 | package com.openconference.sessiondetails.presentationmodel
import com.openconference.model.Session
import org.threeten.bp.LocalDateTime
import org.threeten.bp.ZoneId
import org.threeten.bp.format.DateTimeFormatter
import org.threeten.bp.format.FormatStyle
import java.util.*
/**
* Responsible to transform a Session ... | apache-2.0 |
google/private-compute-libraries | javatests/com/google/android/libraries/pcc/chronicle/analysis/impl/AnnotationTest.kt | 1 | 3229 | /*
* Copyright 2022 Google LLC
*
* 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 ... | apache-2.0 |
UweTrottmann/SeriesGuide | app/src/main/java/com/battlelancer/seriesguide/traktapi/CheckInDialogFragment.kt | 1 | 1942 | package com.battlelancer.seriesguide.traktapi
import android.content.Context
import android.os.AsyncTask
import android.os.Bundle
import androidx.fragment.app.FragmentManager
import com.battlelancer.seriesguide.provider.SgRoomDatabase.Companion.getInstance
import com.battlelancer.seriesguide.util.TextTools
import com.... | apache-2.0 |
redpen-cc/redpen-intellij-plugin | src/cc/redpen/intellij/StatusWidget.kt | 1 | 5697 | package cc.redpen.intellij
import com.intellij.codeInsight.daemon.DaemonCodeAnalyzer
import com.intellij.icons.AllIcons
import com.intellij.ide.DataManager
import com.intellij.openapi.actionSystem.*
import com.intellij.openapi.actionSystem.LangDataKeys.PSI_FILE
import com.intellij.openapi.actionSystem.impl.SimpleDataC... | apache-2.0 |
ColaGom/KtGitCloner | src/main/kotlin/net/ProjectExtractor.kt | 1 | 1848 | package net
import SearchResponse
import com.google.gson.Gson
import com.google.gson.GsonBuilder
import com.google.gson.reflect.TypeToken
import data.Repository
import java.io.PrintWriter
import java.nio.file.Path
class ProjectExtractor(val savePath: Path, val start:String, val end:String)
{
fun extract(page : In... | apache-2.0 |
duftler/orca | orca-queue-tck/src/main/kotlin/com/netflix/spinnaker/orca/q/ExecutionLatch.kt | 1 | 3713 | /*
* Copyright 2017 Netflix, 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 i... | apache-2.0 |
AndroidX/constraintlayout | demoProjects/ComposeMail/app/src/main/java/com/example/composemail/ui/utils/ConstraintUtils.kt | 2 | 1097 | /*
* Copyright (C) 2022 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
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... | apache-2.0 |
RP-Kit/RPKit | bukkit/rpk-permissions-bukkit/src/main/kotlin/com/rpkit/permissions/bukkit/listener/RPKProfileDeleteListener.kt | 1 | 1264 | /*
* Copyright 2022 Ren Binden
*
* 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 i... | apache-2.0 |
willowtreeapps/assertk | assertk/src/commonTest/kotlin/test/assertk/assertions/MapTest.kt | 1 | 8247 | package test.assertk.assertions
import assertk.assertThat
import assertk.assertions.*
import kotlin.test.Test
import kotlin.test.assertEquals
import kotlin.test.assertFails
class MapTest {
//region contains
@Test fun contains_element_present_passes() {
assertThat(mapOf("one" to 1, "two" to 2)).contain... | mit |
willowtreeapps/assertk | assertk/src/commonTest/kotlin/test/assertk/AssertTest.kt | 1 | 2626 | package test.assertk
import assertk.assertAll
import assertk.assertThat
import assertk.assertions.isEqualTo
import assertk.fail
import kotlin.test.Test
import kotlin.test.assertEquals
import kotlin.test.assertFails
import kotlin.test.assertFalse
class AssertTest {
//region transform
@Test fun transform_that_t... | mit |
RP-Kit/RPKit | bukkit/rpk-permissions-lib-bukkit/src/main/kotlin/com/rpkit/permissions/bukkit/event/group/RPKBukkitGroupUnassignProfileEvent.kt | 1 | 1459 | /*
* Copyright 2020 Ren Binden
*
* 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 i... | apache-2.0 |
janicduplessis/react-native | packages/react-native-gradle-plugin/src/main/kotlin/com/facebook/react/model/ModelCodegenConfigAndroid.kt | 3 | 292 | /*
* Copyright (c) Meta Platforms, Inc. and affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
package com.facebook.react.model
data class ModelCodegenConfigAndroid(val javaPackageName: String?)
| mit |
cketti/k-9 | app/storage/src/main/java/com/fsck/k9/storage/messages/RetrieveFolderOperations.kt | 1 | 7702 | package com.fsck.k9.storage.messages
import android.database.Cursor
import androidx.core.database.getLongOrNull
import com.fsck.k9.Account.FolderMode
import com.fsck.k9.helper.map
import com.fsck.k9.mail.FolderClass
import com.fsck.k9.mail.FolderType
import com.fsck.k9.mailstore.FolderDetailsAccessor
import com.fsck.k... | apache-2.0 |
Naliwe/IntelliJ_WowAddOnSupport | src/org/squarecell/wow/addon_support/builders/AddOnModuleBuilder.kt | 1 | 3241 | package org.squarecell.wow.addon_support.builders
import com.intellij.ide.plugins.PluginManager
import com.intellij.ide.util.PropertiesComponent
import com.intellij.ide.util.projectWizard.ModuleBuilder
import com.intellij.ide.util.projectWizard.ModuleBuilderListener
import com.intellij.ide.util.projectWizard.ModuleWiz... | mit |
google/summit-ast | src/main/javatests/com/google/summit/ast/SourceLocationTest.kt | 1 | 2406 | /*
* Copyright 2022 Google LLC
*
* 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 ... | apache-2.0 |
newbieandroid/AppBase | app/src/main/java/com/fuyoul/sanwenseller/ui/money/SettlementTypeActivity.kt | 1 | 9245 | package com.fuyoul.sanwenseller.ui.money
import android.content.Context
import android.content.Intent
import android.graphics.drawable.Drawable
import android.os.Bundle
import android.support.design.widget.AppBarLayout
import android.support.v7.widget.LinearLayoutManager
import android.support.v7.widget.RecyclerView
i... | apache-2.0 |
commons-app/apps-android-commons | app/src/main/java/fr/free/nrw/commons/actions/PageEditInterface.kt | 5 | 3876 | package fr.free.nrw.commons.actions
import io.reactivex.Observable
import io.reactivex.Single
import org.wikipedia.dataclient.Service
import org.wikipedia.dataclient.mwapi.MwQueryResponse
import org.wikipedia.edit.Edit
import org.wikipedia.wikidata.Entities
import retrofit2.http.*
/**
* This interface facilitates wi... | apache-2.0 |
kittinunf/ReactiveAndroid | reactiveandroid-support-v4/src/main/kotlin/com/github/kittinunf/reactiveandroid/support/v4/widget/SwipeRefreshLayoutProperty.kt | 1 | 959 | package com.github.kittinunf.reactiveandroid.support.v4.widget
import android.support.v4.widget.SwipeRefreshLayout
import com.github.kittinunf.reactiveandroid.MutableProperty
import com.github.kittinunf.reactiveandroid.createMainThreadMutableProperty
//=================================================================... | mit |
zingmars/Cbox-bot | src/BotPlugins/UserCommands.kt | 1 | 1664 | /**
* Checks chat for user written messages and responds to specific queries
* Created by zingmars on 04.10.2015.
*/
package BotPlugins
import Containers.PluginBufferItem
public class UserCommands : BasePlugin()
{
override fun pubInit() :Boolean
{
return true
}
override fun connector(buffer ... | bsd-2-clause |
ujpv/intellij-rust | src/test/kotlin/org/rust/ide/typing/RustEnterInStringLiteralHandlerTest.kt | 1 | 3987 | package org.rust.ide.typing
import org.intellij.lang.annotations.Language
class RustEnterInStringLiteralHandlerTest : RustTypingTestCaseBase() {
override val dataPath = "org/rust/ide/typing/string/fixtures"
fun testSimple() = doTest("""
fn main() {
let lit = "Hello, /*caret*/World";
... | mit |
android/user-interface-samples | WindowManager/app/src/main/java/com/example/windowmanagersample/embedding/SplitActivityD.kt | 1 | 1070 | /*
* Copyright 2021 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 applic... | apache-2.0 |
luxons/seven-wonders | sw-engine/src/main/kotlin/org/luxons/sevenwonders/engine/data/definitions/WonderDefinition.kt | 1 | 1091 | package org.luxons.sevenwonders.engine.data.definitions
import org.luxons.sevenwonders.engine.cards.Requirements
import org.luxons.sevenwonders.engine.wonders.Wonder
import org.luxons.sevenwonders.engine.wonders.WonderStage
import org.luxons.sevenwonders.model.resources.ResourceType
import org.luxons.sevenwonders.mode... | mit |
ujpv/intellij-rust | src/main/kotlin/org/rust/lang/core/psi/impl/mixin/RustExternCrateItemImplMixin.kt | 1 | 1097 | package org.rust.lang.core.psi.impl.mixin
import com.intellij.lang.ASTNode
import com.intellij.psi.PsiElement
import com.intellij.psi.stubs.IStubElementType
import org.rust.lang.core.psi.RustExternCrateItemElement
import org.rust.lang.core.psi.impl.RustPsiImplUtil
import org.rust.lang.core.psi.impl.RustStubbedNamedEle... | mit |
LorittaBot/Loritta | loritta-serializable-commons/src/commonMain/kotlin/net/perfectdreams/loritta/serializable/CustomCommand.kt | 1 | 206 | package net.perfectdreams.loritta.serializable
import kotlinx.serialization.Serializable
@Serializable
class CustomCommand(
val label: String,
val codeType: CustomCommandCodeType,
val code: String
) | agpl-3.0 |
JayNewstrom/Concrete | concrete/src/main/java/com/jaynewstrom/concrete/ConcreteWallContext.kt | 1 | 732 | package com.jaynewstrom.concrete
import android.content.Context
import android.content.ContextWrapper
import android.view.LayoutInflater
internal class ConcreteWallContext<C>(
baseContext: Context,
private val wall: ConcreteWall<C>
) : ContextWrapper(baseContext) {
private var inflater: LayoutInflater? = ... | apache-2.0 |
YounesRahimi/java-utils | src/test/java/ir/iais/utilities/javautils/utils/InsuranceType.kt | 2 | 597 | package ir.iais.utilities.javautils.utils
import com.fasterxml.jackson.annotation.JsonFormat
import com.fasterxml.jackson.annotation.JsonFormat.Shape
import com.fasterxml.jackson.annotation.JsonIgnoreProperties
import ir.iais.utilities.javautils.enums.IOrdinal
/** Created by mgh on 10/15/16. */
@JsonFormat(shape = S... | gpl-3.0 |
NuclearCoder/nuclear-bot | src/nuclearbot/gui/components/chat/LimitedStringList.kt | 1 | 2690 | package nuclearbot.gui.components.chat
import java.util.*
import javax.swing.AbstractListModel
import javax.swing.JList
/*
* Copyright (C) 2017 NuclearCoder
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the... | agpl-3.0 |
carlphilipp/chicago-commutes | android-app/src/main/kotlin/fr/cph/chicago/core/model/Bus.kt | 1 | 786 | /**
* Copyright 2021 Carl-Philipp Harmant
*
*
* 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 la... | apache-2.0 |
maskaravivek/apps-android-commons | app/src/test/kotlin/fr/free/nrw/commons/customselector/helper/ImageHelperTest.kt | 3 | 1651 | package fr.free.nrw.commons.customselector.helper
import android.net.Uri
import fr.free.nrw.commons.customselector.model.Folder
import fr.free.nrw.commons.customselector.model.Image
import org.junit.jupiter.api.Assertions.*
import org.junit.jupiter.api.Test
import org.mockito.Mockito.mock
/**
* Custom Selector Imag... | apache-2.0 |
lanhuaguizha/Christian | app/src/main/java/com/christian/nav/me/HidingGospelFragment.kt | 1 | 7641 | package com.christian.nav.me
import android.os.Bundle
import android.util.Log
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import androidx.annotation.NonNull
import androidx.fragment.app.Fragment
import androidx.recyclerview.widget.RecyclerView
import com.christian.R
import... | gpl-3.0 |
tom-kita/kktAPK | app/src/main/kotlin/com/bl_lia/kirakiratter/data/repository/datasource/auth/AuthService.kt | 3 | 997 | package com.bl_lia.kirakiratter.data.repository.datasource.auth
import io.reactivex.Single
import com.bl_lia.kirakiratter.domain.value_object.AccessToken
import com.bl_lia.kirakiratter.domain.value_object.AppCredentials
import retrofit2.http.Field
import retrofit2.http.FormUrlEncoded
import retrofit2.http.POST
interf... | mit |
EZTEQ/rbtv-firetv | app/src/androidTest/java/de/markhaehnel/rbtv/rocketbeanstv/ExampleInstrumentedTest.kt | 1 | 654 | package de.markhaehnel.rbtv.rocketbeanstv
import androidx.test.InstrumentationRegistry
import androidx.test.runner.AndroidJUnit4
import org.junit.Test
import org.junit.runner.RunWith
import org.junit.Assert.*
/**
* Instrumented test, which will execute on an Android device.
*
* See [testing documentation](http:/... | mit |
facebook/litho | litho-it/src/test/java/com/facebook/litho/DynamicPropsExtensionTest.kt | 1 | 2830 | /*
* Copyright (c) Meta Platforms, Inc. and affiliates.
*
* 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... | apache-2.0 |
AlmasB/FXGLGames | OutRun/src/main/kotlin/com/almasb/fxglgames/outrun/PlayerComponent.kt | 1 | 2726 | /*
* The MIT License (MIT)
*
* FXGL - JavaFX Game Library
*
* Copyright (c) 2015-2016 AlmasB (almaslvl@gmail.com)
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restrictio... | mit |
jdinkla/groovy-java-ray-tracer | src/test/kotlin/net/dinkla/raytracer/math/PolynomialsTest.kt | 1 | 1859 | package net.dinkla.raytracer.math
import org.junit.jupiter.api.Test
import org.junit.jupiter.api.Assertions.assertEquals
class PolynomialsTest {
@Test
@Throws(Exception::class)
fun testSolveQuadric() {
// A*x^2 + B*x + C = 0
val s1 = doubleArrayOf(-16.0, 0.0, 1.0)
val sol = dou... | apache-2.0 |
google/horologist | media-data/src/main/java/com/google/android/horologist/media/data/database/model/PlaylistEntity.kt | 1 | 1047 | /*
* Copyright 2022 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 applic... | apache-2.0 |
brunordg/ctanywhere | app/src/main/java/br/com/codeteam/ctanywhere/ext/ContextExt.kt | 1 | 991 | package br.com.codeteam.ctanywhere.ext
import android.content.Context
import android.content.pm.PackageManager
import android.graphics.drawable.Drawable
import androidx.annotation.ColorRes
import androidx.annotation.DrawableRes
import androidx.core.app.ActivityCompat
import androidx.core.content.ContextCompat
/**
* ... | mit |
Zhuinden/simple-stack | tutorials/tutorial-sample/src/main/java/com/zhuinden/simplestacktutorials/steps/step_7/features/profile/ProfileFragment.kt | 1 | 549 | package com.zhuinden.simplestacktutorials.steps.step_7.features.profile
import android.os.Bundle
import android.view.View
import android.widget.Toast
import com.zhuinden.simplestackextensions.fragments.KeyedFragment
import com.zhuinden.simplestacktutorials.R
class ProfileFragment : KeyedFragment(R.layout.step7_profil... | apache-2.0 |
JavaEden/OrchidCore | plugins/OrchidSwiftdoc/src/main/kotlin/com/eden/orchid/swiftdoc/menu/SwiftdocMenuItem.kt | 1 | 1467 | package com.eden.orchid.swiftdoc.menu
import com.eden.orchid.api.OrchidContext
import com.eden.orchid.api.options.annotations.Description
import com.eden.orchid.api.options.annotations.Option
import com.eden.orchid.api.theme.menus.OrchidMenuFactory
import com.eden.orchid.api.theme.menus.MenuItem
import com.eden.orchid... | mit |
pyamsoft/home-button | app/src/main/java/com/pyamsoft/homebutton/main/ToolbarViewState.kt | 1 | 1066 | /*
* Copyright 2021 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... | apache-2.0 |
westoncb/HNDesktop | src/main/java/App.kt | 1 | 17053 | import com.google.gson.JsonElement
import com.google.gson.JsonObject
import com.google.gson.JsonParser
import com.google.gson.JsonPrimitive
import javafx.application.Platform
import javafx.embed.swing.JFXPanel
import javafx.scene.Scene
import javafx.scene.web.WebView
import javax.swing.*
import java.net.URL
import java... | mit |
vase4kin/TeamCityApp | app/src/main/java/com/github/vase4kin/teamcityapp/favorites/presenter/FavoritesPresenterImpl.kt | 1 | 3588 | /*
* Copyright 2020 Andrey Tolpeev
*
* 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... | apache-2.0 |
rozyhead/haru | haru-worker/src/main/kotlin/haru/worker/domain/model/processor/TaskProcessingParams.kt | 1 | 78 | package haru.worker.domain.model.processor
interface TaskProcessingParams {
} | apache-2.0 |
talhacohen/android | app/src/main/java/com/etesync/syncadapter/log/PlainTextFormatter.kt | 1 | 1903 | /*
* Copyright © 2013 – 2016 Ricki Hirner (bitfire web engineering).
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the GNU Public License v3.0
* which accompanies this distribution, and is available at
* http://www.gnu.org/licenses/gpl.html
*/
package ... | gpl-3.0 |
google/ksp | compiler-plugin/src/main/kotlin/com/google/devtools/ksp/symbol/impl/java/KSClassDeclarationJavaImpl.kt | 1 | 6743 | /*
* Copyright 2020 Google LLC
* Copyright 2010-2020 JetBrains s.r.o. and Kotlin Programming Language contributors.
*
* 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.apac... | apache-2.0 |
macleod2486/AndroidSwissKnife | app/src/main/java/com/macleod2486/androidswissknife/components/Flashlight.kt | 1 | 3071 | /*
AndroidSwissKnife
Copyright (C) 2016 macleod2486
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
... | gpl-3.0 |
wuseal/JsonToKotlinClass | src/main/kotlin/wu/seal/jsontokotlin/InsertKotlinClassAction.kt | 1 | 8218 | package wu.seal.jsontokotlin
import com.google.gson.Gson
import com.intellij.openapi.actionSystem.AnAction
import com.intellij.openapi.actionSystem.AnActionEvent
import com.intellij.openapi.actionSystem.PlatformDataKeys
import com.intellij.openapi.editor.Caret
import com.intellij.openapi.editor.Document
import com.int... | gpl-3.0 |
mg6maciej/fluffy-octo-rotary-phone | app/src/main/java/pl/mg6/likeornot/grid/LikableService.kt | 1 | 712 | package pl.mg6.likeornot.grid
import io.reactivex.Single
import io.reactivex.Single.zip
import io.reactivex.functions.BiFunction
import pl.mg6.likeornot.grid.api.LikableApi
import pl.mg6.likeornot.grid.api.LikableFromApi
import pl.mg6.likeornot.grid.entity.Likable
fun getLikables(api: LikableApi, callLocalLikes: () -... | apache-2.0 |
jtransc/jtransc | benchmark_kotlin_mpp/wip/jzlib/GZIPInputStream.kt | 1 | 4000 | /* -*-mode:java; c-basic-offset:2; indent-tabs-mode:nil -*- */ /*
Copyright (c) 2011 ymnk, JCraft,Inc. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the... | apache-2.0 |
Fitbit/MvRx | mock_generation/ShellAccess.kt | 1 | 5910 | #!/usr/bin/env kscript
/**
* Functions for executing shell commands and receiving the result.
*/
import java.io.BufferedReader
import java.io.File
import java.io.IOException
import java.lang.ProcessBuilder.Redirect
import java.util.concurrent.TimeUnit
import kotlin.system.exitProcess
/**
* Executes the receiving s... | apache-2.0 |
dataloom/conductor-client | src/main/kotlin/com/openlattice/auditing/AuditingManager.kt | 1 | 121 | package com.openlattice.auditing
interface AuditingManager {
fun recordEvents(events: List<AuditableEvent>): Int
} | gpl-3.0 |
jtransc/jtransc | jtransc-core/src/com/jtransc/ast/dependency/analyzer.kt | 1 | 7670 | /*
* Copyright 2016 Carlos Ballesteros Velasco
*
* 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 l... | apache-2.0 |
avast/android-lectures | Lecture 2/Demo-app/app/src/androidTest/java/com/avast/mff/lecture2/ExampleInstrumentedTest.kt | 1 | 671 | package com.avast.mff.lecture2
import androidx.test.platform.app.InstrumentationRegistry
import androidx.test.ext.junit.runners.AndroidJUnit4
import org.junit.Test
import org.junit.runner.RunWith
import org.junit.Assert.*
/**
* Instrumented test, which will execute on an Android device.
*
* See [testing document... | apache-2.0 |
http4k/http4k | http4k-format/gson/src/test/kotlin/org/http4k/contract/GsonJsonErrorResponseRendererTest.kt | 1 | 190 | package org.http4k.contract
import com.google.gson.JsonElement
import org.http4k.format.Gson
class GsonJsonErrorResponseRendererTest : JsonErrorResponseRendererContract<JsonElement>(Gson)
| apache-2.0 |
squins/ooverkommelig | jvm-reflect/src/main/kotlin/org/ooverkommelig/jvmreflect/retrievabledefinitions/ObjectType.kt | 1 | 274 | package org.ooverkommelig.jvmreflect.retrievabledefinitions
import kotlin.reflect.jvm.reflect
@Suppress("CAST_NEVER_SUCCEEDS", "UNCHECKED_CAST")
fun <T> t() = null as T
internal fun <T> (() -> T).asKType() =
reflect()?.returnType ?: throw IllegalStateException()
| mit |
premisedata/cameraview | demo/src/main/kotlin/com/otaliastudios/cameraview/demo/MessageView.kt | 1 | 1057 | package com.otaliastudios.cameraview.demo
import android.content.Context
import android.util.AttributeSet
import android.view.View
import android.view.ViewGroup
import android.widget.LinearLayout
import android.widget.TextView
class MessageView @JvmOverloads constructor(
context: Context,
attrs: Attri... | apache-2.0 |
dreis2211/spring-boot | spring-boot-project/spring-boot-docs/src/main/kotlin/org/springframework/boot/docs/web/servlet/springmvc/Customer.kt | 10 | 699 | /*
* Copyright 2012-2022 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
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by a... | apache-2.0 |
msebire/intellij-community | plugins/groovy/groovy-psi/src/org/jetbrains/plugins/groovy/lang/resolve/GrCodeReferenceResolver.kt | 1 | 10648 | // Copyright 2000-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 org.jetbrains.plugins.groovy.lang.resolve
import com.intellij.psi.*
import com.intellij.psi.scope.PsiScopeProcessor
import com.intellij.psi.util.parentOfType
import org.j... | apache-2.0 |
square/duktape-android | zipline-cli/src/test/kotlin/app/cash/zipline/cli/GenerateKeyPairTest.kt | 1 | 2477 | /*
* Copyright (C) 2022 Block, 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 agree... | apache-2.0 |
Paulloz/godot | platform/android/java/lib/src/org/godotengine/godot/vulkan/VkSurfaceView.kt | 6 | 4790 | /*************************************************************************/
/* VkSurfaceView.kt */
/*************************************************************************/
/* This file is part of: */
/* ... | mit |
square/duktape-android | zipline-loader/src/commonTest/kotlin/app/cash/zipline/loader/internal/fetcher/HttpFetcherTest.kt | 1 | 3505 | /*
* Copyright (C) 2022 Block, 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 agree... | apache-2.0 |
kannix68/advent_of_code_2016 | day11/src_kotlin/Day11a.kt | 1 | 11501 | import java.security.* // MessageDigest
import java.math.* // BigInteger
import AocBase
/**
* AoC2016 Day11a main class.
* Run with:
*
* ```
* run.sh
* ```
*
* Document with:
* `java -jar dokka-fatjar.jar day13a.kt -format html -module "aoc16 day11a" -nodeprecated`
*/
class Day11a : AocBase() {
val maxro... | mit |
LordAkkarin/Beacon | ui/src/main/kotlin/tv/dotstart/beacon/ui/repository/model/Service.kt | 1 | 3682 | /*
* Copyright (C) 2019 Johannes Donath <johannesd@torchmind.com>
* and other copyright owners as documented in the project's IP log.
*
* 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
*
... | apache-2.0 |
prfarlow1/nytc-meet | app/src/main/kotlin/org/needhamtrack/nytc/database/NytcDatabase.kt | 1 | 446 | package org.needhamtrack.nytc.database
import android.arch.persistence.room.Database
import android.arch.persistence.room.RoomDatabase
import android.arch.persistence.room.TypeConverters
import org.needhamtrack.nytc.models.LongJumpRecord
@Database(entities = arrayOf(LongJumpRecord::class), version = 1)
@TypeConverter... | mit |
cemrich/zapp | app/src/main/java/de/christinecoenen/code/zapp/app/mediathek/ui/list/adapter/FooterLoadStateAdapter.kt | 1 | 800 | package de.christinecoenen.code.zapp.app.mediathek.ui.list.adapter
import android.view.LayoutInflater
import android.view.ViewGroup
import androidx.paging.LoadState
import androidx.paging.LoadStateAdapter
import de.christinecoenen.code.zapp.databinding.FragmentMediathekListItemFooterBinding
class FooterLoadStateAdapt... | mit |
infinum/android_dbinspector | dbinspector/src/main/kotlin/com/infinum/dbinspector/domain/history/interactors/RemoveExecutionInteractor.kt | 1 | 1116 | package com.infinum.dbinspector.domain.history.interactors
import com.infinum.dbinspector.data.Sources
import com.infinum.dbinspector.data.models.local.proto.input.HistoryTask
import com.infinum.dbinspector.data.models.local.proto.output.HistoryEntity
import com.infinum.dbinspector.domain.Interactors
internal class R... | apache-2.0 |
matkoniecz/StreetComplete | app/src/main/java/de/westnordost/streetcomplete/quests/max_height/MaxHeightAnswer.kt | 2 | 228 | package de.westnordost.streetcomplete.quests.max_height
sealed class MaxHeightAnswer
data class MaxHeight(val value: HeightMeasure) : MaxHeightAnswer()
data class NoMaxHeightSign(val isTallEnough: Boolean) : MaxHeightAnswer()
| gpl-3.0 |
tokenbrowser/token-android-client | app/src/main/java/com/toshi/model/local/ConversationObservables.kt | 1 | 1063 | /*
* Copyright (c) 2017. Toshi Inc
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This ... | gpl-3.0 |
rafaelwkerr/duplicate-user | app/src/test/java/ninenine/com/duplicateuser/presenter/UserPresenterTest.kt | 1 | 1695 | package ninenine.com.duplicateuser.presenter
import ninenine.com.duplicateuser.domain.User
import ninenine.com.duplicateuser.initMocks
import ninenine.com.duplicateuser.repository.UserRepository
import ninenine.com.duplicateuser.view.UserContractView
import org.junit.Assert
import org.junit.Before
import org.junit.Tes... | mit |
matkoniecz/StreetComplete | app/src/main/java/de/westnordost/streetcomplete/quests/railway_crossing/AddRailwayCrossingBarrierForm.kt | 1 | 620 | package de.westnordost.streetcomplete.quests.railway_crossing
import de.westnordost.streetcomplete.quests.AImageListQuestAnswerFragment
import de.westnordost.streetcomplete.quests.railway_crossing.RailwayCrossingBarrier.*
class AddRailwayCrossingBarrierForm : AImageListQuestAnswerFragment<RailwayCrossingBarrier, Rail... | gpl-3.0 |
akvo/akvo-flow-mobile | domain/src/main/java/org/akvo/flow/domain/interactor/DownloadDataPoints.kt | 1 | 3117 | /*
* Copyright (C) 2017-2018 Stichting Akvo (Akvo Foundation)
*
* This file is part of Akvo Flow.
*
* Akvo Flow is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at... | gpl-3.0 |
kiesproject/prepass-speedtest | app/src/test/java/kies/prepass/speedtest/ExampleUnitTest.kt | 1 | 387 | package kies.prepass.speedtest
import org.junit.Test
import org.junit.Assert.*
/**
* Example local unit test, which will execute on the development machine (host).
*
* @see [Testing documentation](http://d.android.com/tools/testing)
*/
class ExampleUnitTest {
@Test
@Throws(Exception::class)
fun addit... | apache-2.0 |
android/topeka | quiz/src/main/java/com/google/samples/apps/topeka/widget/quiz/FillTwoBlanksQuizView.kt | 1 | 2908 | /*
* Copyright 2017 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 ... | apache-2.0 |
andersonlucasg3/SpriteKit-Android | SpriteKitLib/src/main/java/br/com/insanitech/spritekit/easing/Quint.kt | 1 | 871 | package br.com.insanitech.spritekit.easing
object Quint {
fun easeIn(t: Float, b: Float, c: Float, d: Float): Float {
var t = t
val tLambda = { a: Float -> Float
t = a
t
}
return c * (tLambda(t / d)) * t * t * t * t + b
}
fun easeOut(t:... | bsd-3-clause |
LanternPowered/LanternServer | src/main/kotlin/org/lanternpowered/server/network/vanilla/command/argument/ArgumentTypes.kt | 1 | 2839 | /*
* Lantern
*
* Copyright (c) LanternPowered <https://www.lanternpowered.org>
* Copyright (c) SpongePowered <https://www.spongepowered.org>
* Copyright (c) contributors
*
* This work is licensed under the terms of the MIT License (MIT). For
* a copy, see 'LICENSE.txt' or <https://opensource.org/licenses/MIT>.
... | mit |
Kotlin/kotlinx.serialization | formats/json-tests/commonTest/src/kotlinx/serialization/json/JsonUnionEnumTest.kt | 1 | 842 | /*
* Copyright 2017-2019 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license.
*/
package kotlinx.serialization.json
import kotlinx.serialization.*
import kotlin.test.Test
import kotlin.test.assertEquals
class JsonUnionEnumTest : JsonTestBase() {
enum class SomeEnum { ALPHA, BETA, GA... | apache-2.0 |
Kotlin/kotlinx.serialization | formats/protobuf/commonTest/src/kotlinx/serialization/protobuf/ProtobufPrimitiveWrappersTest.kt | 1 | 2133 | /*
* Copyright 2017-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license.
*/
package kotlinx.serialization.protobuf
import kotlinx.serialization.*
import kotlin.test.*
/*
* TODO improve these tests:
* * All primitive types
* * All nullable types
* * Built-in types (TBD)
* * P... | apache-2.0 |
k0kubun/github-ranking | worker/src/main/kotlin/com/github/k0kubun/gitstar_ranking/db/PaginatedUsers.kt | 2 | 1044 | package com.github.k0kubun.gitstar_ranking.db
import com.github.k0kubun.gitstar_ranking.core.StarsCursor
import com.github.k0kubun.gitstar_ranking.core.User
import org.jooq.DSLContext
private const val PAGE_SIZE = 5000
// This class does cursor-based-pagination for users order by stargazers_count DESC.
class Paginat... | mit |
debop/debop4k | debop4k-timeperiod/src/main/kotlin/debop4k/timeperiod/timeranges/HourRangeCollection.kt | 1 | 2365 | /*
* Copyright (c) 2016. Sunghyouk Bae <sunghyouk.bae@gmail.com>
* 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... | apache-2.0 |
jaredsburrows/gradle-license-plugin | gradle-license-plugin/src/main/kotlin/com/jaredsburrows/license/LicensePlugin.kt | 1 | 673 | package com.jaredsburrows.license
import org.gradle.api.Plugin
import org.gradle.api.Project
/** A [Plugin] which grabs the POM.xml files from maven dependencies. */
class LicensePlugin : Plugin<Project> {
override fun apply(project: Project) {
project.extensions.add("licenseReport", LicenseReportExtension::cla... | apache-2.0 |
Geobert/radis | app/src/main/kotlin/fr/geobert/radis/tools/PauseHandler.kt | 1 | 1797 | package fr.geobert.radis.tools
import android.app.Activity
import android.os.Handler
import android.os.Message
import java.util.*
/**
* Message Handler class that supports buffering up of messages when the activity is paused i.e. in the background.
*/
public abstract class PauseHandler : Handler() {
/**
*... | gpl-2.0 |
ntlv/BasicLauncher2 | app/src/main/java/se/ntlv/basiclauncher/image/MemoryLruCache.kt | 1 | 38 | package se.ntlv.basiclauncher.image
| mit |
areguig/sauron | src/test/kotlin/io/github/areguig/sauron/SauronApplicationTests.kt | 1 | 322 | package io.github.areguig.sauron
import org.junit.Test
import org.junit.runner.RunWith
import org.springframework.boot.test.context.SpringBootTest
import org.springframework.test.context.junit4.SpringRunner
@RunWith(SpringRunner::class)
@SpringBootTest
class SauronApplicationTests {
@Test
fun contextLoads() {
}
... | apache-2.0 |
Mauin/detekt | detekt-api/src/main/kotlin/io/gitlab/arturbosch/detekt/api/Entity.kt | 2 | 775 | package io.gitlab.arturbosch.detekt.api
import org.jetbrains.kotlin.com.intellij.psi.PsiElement
import org.jetbrains.kotlin.psi.KtElement
/**
* Stores information about a specific code fragment.
*
* @author Artur Bosch
*/
data class Entity(val name: String,
val className: String,
val signature: String... | apache-2.0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.