code
stringlengths
5
1M
repo_name
stringlengths
5
109
path
stringlengths
6
208
language
stringclasses
1 value
license
stringclasses
15 values
size
int64
5
1M
// Databricks notebook source // MAGIC %md // MAGIC ScaDaMaLe Course [site](https://lamastex.github.io/scalable-data-science/sds/3/x/) and [book](https://lamastex.github.io/ScaDaMaLe/index.html) // COMMAND ---------- // MAGIC %md // MAGIC ## Loading data // COMMAND ---------- display(dbutils.fs.ls("/datasets/group1...
lamastex/scalable-data-science
dbcArchives/2021/000_0-sds-3-x-projects/student-project-12_group-CovidPandemic/02_DataPreprocess.scala
Scala
unlicense
10,938
package cc.ferreira.gcal2slack.buildinfo import java.time.LocalDate trait BuildInfo { def name: String def version: String def scalaVersion: String def sbtVersion: String def buildDate: LocalDate }
hugocf/gcal-slack-update
src/main/scala/cc/ferreira/gcal2slack/buildinfo/BuildInfo.scala
Scala
mit
210
/* * Copyright 2001-2013 Artima, 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 agre...
dotty-staging/scalatest
scalatest-test/src/test/scala/org/scalatest/fixture/DeprecatedFeatureSpecSpec.scala
Scala
apache-2.0
80,297
package com.urbanairship.octobot import java.util.HashMap // This class ia a plain object encapsulating information about // a specific queue's configuration. It can be constructed by // specifying the properties as arguments, or via a HashMap. class Queue(val queueType: String, val queueName: String, val host: Stri...
cscotta/Octobot-Scala
src/main/scala/com/urbanairship/octobot/Queue.scala
Scala
bsd-3-clause
1,321
package com.harrys.hyppo.worker.actor.data import java.io.File import java.nio.file.Files import javax.inject.Inject import com.google.inject.assistedinject.Assisted import com.harrys.hyppo.worker.api.proto.RemoteStorageLocation import com.harrys.hyppo.worker.data.{JarFileLoader, LoadedJarFile} import org.apache.comm...
harrystech/hyppo-worker
worker/src/test/scala/com/harrys/hyppo/worker/actor/data/LocalJarFileLoader.scala
Scala
mit
1,729
package dotty.tools.dotc.transform import dotty.tools.dotc.core.Contexts.Context import dotty.tools.dotc.core.Decorators._ import dotty.tools.dotc.core.DenotTransformers.SymTransformer import dotty.tools.dotc.core.Flags._ import dotty.tools.dotc.core.NameKinds._ import dotty.tools.dotc.core.Names._ import dotty.tools....
som-snytt/dotty
compiler/src/dotty/tools/dotc/transform/RenameLifted.scala
Scala
apache-2.0
1,930
package rtmp.amf import akka.util.ByteStringBuilder import rtmp.amf.amf0.{Amf0StringWriter, Amf0Types} /** * Writer for CustomSerializable objects */ class CustomWriter(serializer:Serializer) extends AmfObjectWriter[CustomSerializable] with Amf0StringWriter { override def write(builder: ByteStringBuilder, value:...
vimvim/AkkaTest
src/main/scala/rtmp/amf/CustomWriter.scala
Scala
agpl-3.0
496
package se.joham.funrts.model import se.gigurra.serviceutils.twitter.logging.Logging import se.joham.funrts.model.components.{Acting, BaseInfo} import se.joham.funrts.model.systems.UpdatingSystem /** * Created by johan on 2016-06-11. */ case class GameSimulation(level: Level, players: Se...
GiGurra/fun-rts
src/main/scala/se/joham/funrts/model/GameSimulation.scala
Scala
gpl-2.0
2,608
package com.codacy.client.stash import org.joda.time.DateTime import play.api.libs.functional.syntax._ import play.api.libs.json._ final case class PullRequest( id: Long, title: String, description: Option[String], state: String, createdDate: DateTime, updatedDate: DateTime, sourceReposito...
codacy/stash-scala-client
src/main/scala/com/codacy/client/stash/PullRequest.scala
Scala
apache-2.0
1,268
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may ...
andrewor14/iolap
sql/core/src/test/scala/org/apache/spark/sql/columnar/InMemoryColumnarQuerySuite.scala
Scala
apache-2.0
6,879
/* * Copyright 2019 Frugal Mechanic (http://frugalmechanic.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...
frugalmechanic/fm-serializer
src/main/scala/fm/serializer/jackson/JsonGeneratorOutput.scala
Scala
apache-2.0
8,159
/** * Copyright 2015 Yahoo Inc. Licensed under the Apache License, Version 2.0 * See accompanying LICENSE file. */ package kafka.manager.utils import kafka.manager.{Kafka_0_8_1_1, ClusterConfig} import org.scalatest.{Matchers, FunSuite} /** * @author hiral */ class TestClusterConfig extends FunSuite with Matcher...
jack6215/kafka-manager
test/kafka/manager/utils/TestClusterConfig.scala
Scala
apache-2.0
2,012
/* * Copyright 2022 Typelevel * * 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 in...
typelevel/sbt-typelevel
mergify/src/main/scala/org/typelevel/sbt/mergify/MergifyPrRule.scala
Scala
apache-2.0
992
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may ...
joseph-torres/spark
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/collectionOperations.scala
Scala
apache-2.0
42,293
println(classOf[/* file: package */ Traversable[String]])
JetBrains/intellij-scala
scala/scala-impl/testdata/resolve2/predef/element/TypeAlias.scala
Scala
apache-2.0
58
package com.twitter.gizzard.thrift.conversions import com.twitter.gizzard.shards import com.twitter.gizzard.thrift object ShardId { class RichShardId(shardId: shards.ShardId) { def toThrift = new thrift.ShardId(shardId.hostname, shardId.tablePrefix) } implicit def shardIdToRichShardId(shardId: shards.Shard...
kmiku7/gizzard
src/main/scala/com/twitter/gizzard/thrift/conversions/ShardId.scala
Scala
apache-2.0
591
package io.github.nivox.dandelion.datatxt.nex import akka.NotUsed import akka.http.scaladsl.model._ import akka.stream.Materializer import akka.stream.scaladsl.{Flow, Sink, Source} import io.github.nivox.dandelion.core._ import io.github.nivox.dandelion.datatxt.nex.ResponseModelsCodec._ import io.github.nivox.dandelio...
nivox/dandelion-scala
datatxt-nex/src/main/scala/io/github/nivox/dandelion/datatxt/nex/NexAPI.scala
Scala
mit
3,963
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may ...
maropu/spark
sql/core/src/main/scala/org/apache/spark/sql/execution/ui/SparkPlanGraph.scala
Scala
apache-2.0
8,744
package com.pjanof.io import BasicNetwork._ import akka.actor.{ Actor, ActorSystem, Props } import akka.io.Tcp import akka.testkit.{ TestActorRef, TestKit, ImplicitSender } import akka.util.ByteString import scala.concurrent.duration._ import org.scalatest.WordSpecLike import org.scalatest.Matchers import org.scala...
peterjanovsky/akka-examples
src/test/scala/com/pjanof/io/BasicNetworkSpec.scala
Scala
mit
1,366
// scalac: -Xsource:3 // import java.io as jio import scala.{collection as c} import c.mutable as mut import mut.ArrayBuffer as Buf object O { val x: jio.IOException = ??? val y = Buf(1, 2, 3) type OString = String def foo22(x: Int) = x } class C { import O.{ foo22 as foo, OString as OS } println(foo(2...
lrytz/scala
test/files/pos/import-future.scala
Scala
apache-2.0
549
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may ...
tophua/spark1.52
core/src/main/scala/org/apache/spark/util/ParentClassLoader.scala
Scala
apache-2.0
1,488
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may ...
tophua/spark1.52
mllib/src/test/scala/org/apache/spark/mllib/linalg/MatricesSuite.scala
Scala
apache-2.0
18,545
import scala.reflect.macros.whitebox.Context object UnusedMacro { def macroImpl(c: Context)(body: c.Expr[Int]): c.Tree = { import c.universe._ val _ = body q"42" } }
scala/scala
test/files/pos/t10296-before/UnusedMacro_1.scala
Scala
apache-2.0
184
package com.jinmago.letsmodreboot.proxy class ClientProxy extends CommonProxy { }
Jinmago/LetsModReboot
src/main/scala/com/jinmago/letsmodreboot/proxy/ClientProxy.scala
Scala
gpl-3.0
84
/* * Copyright (c) 2013-2014, ARM Limited * * 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 restriction, including without limitation the rights * to use, copy, modify, merge, p...
Meinersbur/pencil
src/scala/com/arm/carp/apps/optimizer/passes/ConstantPropagation.scala
Scala
mit
10,416
package solution import scala.annotation.tailrec object Functions2 { /** * Retries the given function up to numTimes until it succeeds */ @tailrec def retry[T](numTimes: Int)(f: => T): T = { if (numTimes <= 0) { f } else { try { f } catch { case ex: Excepti...
keshwans/scala-1-day
130.functions/src/main/scala/solution/Functions2.scala
Scala
mit
783
package sttp.client3.testing import org.scalatest._ import org.scalatest.freespec.AsyncFreeSpec import org.scalatest.matchers.should.Matchers import sttp.client3.internal.{Iso88591, Utf8} import sttp.client3.testing.HttpTest.endpoint import sttp.client3.{Response, ResponseAs, SttpBackend, _} import sttp.model.StatusCo...
softwaremill/sttp
core/src/test/scala/sttp/client3/testing/HttpTest.scala
Scala
apache-2.0
22,990
/* * Copyright 2001-2013 Artima, 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 agre...
dotty-staging/scalatest
scalatest-test/src/test/scala/org/scalatest/BeforeAndAfterAsyncSuite.scala
Scala
apache-2.0
8,686
package util import java.io.BufferedReader import java.nio.charset.{Charset, StandardCharsets} import java.nio.file.{Files, Path} /** * <pre> * Created on 2014/11/01 * </pre> * @author K.Sakamoto */ object StaticValue { val defaultCharset: Charset = StandardCharsets.UTF_8 val lineSeparator: String = System....
ktr-skmt/FelisCatusZero
src/main/scala/util/StaticValue.scala
Scala
apache-2.0
436
/* * Copyright 2022 HM Revenue & Customs * * 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...
hmrc/iht-frontend
app/iht/controllers/application/assets/insurancePolicy/InsurancePolicyDetailsJointController.scala
Scala
apache-2.0
3,614
package uk.org.nbn.nbnv.importer.validation import uk.org.nbn.nbnv.importer.spatial.GridRefPatterns import uk.org.nbn.nbnv.importer.fidelity.{ResultLevel, Result} import scala.util.matching.Regex class Nbnv81Validator { def validate(gridReference: String, recordKey: String) = { def success = { ...
JNCC-dev-team/nbn-importer
importer/src/main/scala/uk/org/nbn/nbnv/importer/validation/Nbnv81Validator.scala
Scala
apache-2.0
1,197
package com.github.ligangty.scala.jsoup.parser import com.github.ligangty.scala.jsoup.helper.Strings import com.github.ligangty.scala.jsoup.nodes._ import Token.TokenType._ import com.github.ligangty.scala.jsoup.parser.Token.TokenType.Comment import com.github.ligangty.scala.jsoup.parser.TokeniserState.{Rawtext, Rcdat...
ligangty/scalajsoup
src/main/scala/com/github/ligangty/scala/jsoup/parser/HtmlTreeBuilderState.scala
Scala
mit
57,093
package com.arcusys.learn.controllers.api import com.arcusys.learn.facades.TranscriptPrintFacadeContract import com.arcusys.learn.models.request.{ PrintRequest, PrintActionType } import com.arcusys.valamis.lrs.service.LrsClientManager import com.escalatesoft.subcut.inject.BindingModule import com.arcusys.learn.ioc.Con...
ViLPy/Valamis
learn-portlet/src/main/scala/com/arcusys/learn/controllers/api/TranscriptPrintApiController.scala
Scala
lgpl-3.0
1,759
/* * Copyright 2022 HM Revenue & Customs * * 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...
hmrc/vat-registration-frontend
app/models/CompanyContactDetails.scala
Scala
apache-2.0
2,103
/* * Copyright (c) 2014-2021 by The Monix Project Developers. * See the project homepage at: https://monix.io * * 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...
monixio/monix
monix-tail/shared/src/main/scala/monix/tail/internal/IterantBuffer.scala
Scala
apache-2.0
5,577
package beam.utils.csv.writers import beam.utils.scenario.{PersonId, PlanElement} import org.matsim.api.core.v01.Scenario import org.matsim.api.core.v01.population.{Activity, Leg, Plan, PlanElement => MatsimPlanElement} import scala.collection.JavaConverters._ object PlansCsvWriter extends ScenarioCsvWriter { ove...
colinsheppard/beam
src/main/scala/beam/utils/csv/writers/PlansCsvWriter.scala
Scala
gpl-3.0
3,565
package observatory object Main extends App {}
yurii-khomenko/fpScalaSpec
c5w1observatory/src/main/scala/observatory/Main.scala
Scala
gpl-3.0
47
package delta.write import delta.Projector /** * State wrapper. Encapsulates and transforms * immutable state by applying events. */ final class State[S >: Null, EVT] private[write] ( projector: Projector[S, EVT], private[this] var _state: S) { @inline // Just mutate, don't collect event private[wr...
nilskp/delta
src/main/scala/delta/write/State.scala
Scala
mit
1,143
/****************************************************************************** * Copyright (c) 2014, Equal Experts Ltd * 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 ...
EqualExperts/Midas
src/main/scala/com/ee/midas/pipes/DuplexPipe.scala
Scala
bsd-2-clause
4,348
package com.twitter.finagle.factory import com.twitter.finagle._ import com.twitter.util.{Await, Future, Time, Var, Activity, Promise, Throw, Return} import java.net.{InetSocketAddress, SocketAddress} import org.junit.runner.RunWith import org.mockito.Matchers.any import org.mockito.ArgumentCaptor import org.mockito.M...
JustinTulloss/finagle
finagle-core/src/test/scala/com/twitter/finagle/factory/BindingFactoryTest.scala
Scala
apache-2.0
5,656
package uk.co.seansaville.ninetyninescalaprobs.lists /** * Problem 18: Extract a slice from a list. */ object Problem18 { def slice[T](i: Int, k: Int, list: List[T]): List[T] = { def sliceHelper[U](a: Int, b: Int, ls: List[U], result: List[U]): List[U] = (a, b, ls) match { case (0, 1, h :: t) => (h ::...
seansaville/99scalaprobs
src/main/scala/uk/co/seansaville/ninetyninescalaprobs/lists/Problem18.scala
Scala
mit
607
package be.spidermind.remoteexecutor.remote import java.io.{File, InputStream, OutputStream, PrintWriter} import java.nio.charset.Charset import java.nio.file.{Files, Paths} import java.util.concurrent.TimeUnit import akka.actor._ import be.spidermind.remoteexecutor.RemoteMessages import com.typesafe.config.ConfigFac...
AnOnyme77/RemoteExecutor
src/main/scala/be/spidermind/remoteexecutor/remote/RemoteActor.scala
Scala
mit
7,693
import akka.actor.ActorSystem import akka.testkit.TestKit import akka.util.ByteString import com.bisphone.sarf._ import com.bisphone.sarf.implv1.StatCollector.Ref import com.bisphone.sarf.implv1.util.{StreamConfig, TCPConfigForClient, TCPConfigForServer} import com.bisphone.sarf.implv1.{Service, StatCollector, TCPClien...
khajavi/Toosheh
src/test/scala/CounterTestSuit.scala
Scala
mit
3,380
package com.lucidchart.piezo import java.io.{BufferedReader, FileReader, File} import java.util.concurrent.Semaphore import org.specs2.mutable._ import org.quartz._ import org.quartz.JobBuilder._ import org.quartz.TriggerBuilder._ import org.quartz.SimpleScheduleBuilder._ import org.quartz.impl.StdSchedulerFactory im...
pauldraper/piezo
worker/src/test/scala/com/lucidchart/piezo/WorkerTest.scala
Scala
apache-2.0
3,308
package fpinscala.answers.datastructures sealed trait List[+A] // `List` data type, parameterized on a type, `A` case object Nil extends List[Nothing] // A `List` data constructor representing the empty list /* Another data constructor, representing nonempty lists. Note that `tail` is another `List[A]`, which may be `...
peterbecich/fpinscala
answers/src/main/scala/fpinscala/datastructures/List.scala
Scala
mit
14,406
package spark.jobserver import akka.actor.ActorRef import com.yammer.metrics.core.Meter import ooyala.common.akka.InstrumentedActor import ooyala.common.akka.metrics.YammerMetrics import scala.collection.mutable import scala.util.Try import spark.jobserver.io.{ JobInfo, JobDAO } object JobStatusActor { case class J...
nachiketa-shukla/spark-jobserver
job-server/src/spark.jobserver/JobStatusActor.scala
Scala
apache-2.0
4,438
/* * Copyright (C) 2015 Stratio (http://stratio.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 by app...
fjsc/sparta
plugins/src/main/scala/com/stratio/sparta/plugin/cube/field/geohash/GeoHashField.scala
Scala
apache-2.0
6,819
package org.atnos.eff package addon.scalaz import cats.Eval import scalaz._ object eval extends eval trait eval { def attemptEvalDisjunction[R, U, A](r: Eff[R, A])(implicit m: Member.Aux[Eval, R, U]): Eff[U, Throwable \/ A] = org.atnos.eff.all.attemptEval(r).map(_.fold(\/.left, \/.right)) }
etorreborre/eff
scalaz/src/main/scala/org/atnos/eff/addon/scalaz/eval.scala
Scala
mit
304
package com.mesosphere.cosmos.error import com.mesosphere.cosmos.circe.Encoders._ import io.lemonlabs.uri.Uri import io.netty.handler.codec.http.HttpResponseStatus import io.circe.Encoder import io.circe.JsonObject import io.circe.generic.semiauto.deriveEncoder import org.jboss.netty.handler.codec.http.HttpMethod fin...
dcos/cosmos
cosmos-common/src/main/scala/com/mesosphere/cosmos/error/GenericHttpError.scala
Scala
apache-2.0
840
package io.scalaland.chimney.utils object EitherUtils { implicit class OptionOps[T](val opt: Option[T]) extends AnyVal { def toEither(err: => String): Either[List[String], T] = { opt match { case Some(value) => Right(value) case None => Left(List(err)) } } } }
scalalandio/chimney
chimney/src/test/scala/io/scalaland/chimney/utils/EitherUtils.scala
Scala
apache-2.0
311
package org.example.validation import argonaut.Argonaut._ import argonaut._ import org.example.domain.CodecHelper._ import scalaz.Maybe case class ErrorCode(code: String) object ErrorCode { implicit val strToAPICode : String => ErrorCode= ErrorCode(_) implicit val aeccodec: CodecJson[ErrorCode] = codec( ...
ppurang/composable-validations
src/main/scala/org/example/validation/error.scala
Scala
mit
1,161
package server import org.http4s._ import org.http4s.dsl._ import org.http4s.server.{ServerApp, Server => Http4sServer} import org.http4s.server.blaze._ import scalaz.concurrent.Task import java.io.File object Server extends ServerApp { def server(args: List[String]): Task[Http4sServer] = BlazeBuilder.mountServ...
OlivierBlanvillain/19x19.net
server/src/main/scala/Server.scala
Scala
mit
1,046
/** * Copyright (c) 2014-2016 Snowplow Analytics Ltd. * All rights reserved. * * This program is licensed to you under the Apache License Version 2.0, * and you may not use this file except in compliance with the Apache * License Version 2.0. * You may obtain a copy of the Apache License Version 2.0 at * http:/...
haensel-ams/snowplow
4-storage/kinesis-elasticsearch-sink/src/main/scala/com.snowplowanalytics.snowplow.storage.kinesis/elasticsearch/SnowplowElasticsearchTransformer.scala
Scala
apache-2.0
11,907
import sbt._ object Libraries { def onCompile(dep: ModuleID): ModuleID = dep % "compile" def onTest(dep: ModuleID): ModuleID = dep % "test" object scala { lazy val scalaReflect = "org.scala-lang" % "scala-reflect" % Versions.scalaV lazy val scalap = "org.scala-lang" % "scalap" % Versions.scalaV } ...
47deg/scala-android
project/Libraries.scala
Scala
apache-2.0
2,980
package edu.chop.cbmi.dataExpress.test.dsl import edu.chop.cbmi.dataExpress.test.util.presidents.{KNOWN_SQL_BACKEND, PresidentsSpecWithSourceTarget} import java.io.File import edu.chop.cbmi.dataExpress.backends.file._ import edu.chop.cbmi.dataExpress.test.util.Functions.sqlDateFrom import edu.chop.cbmi.dataExpress.dat...
chop-dbhi/dataexpress
src/test/scala/edu/chop/cbmi/dataExpress/test/dsl/CopyFileSpec.scala
Scala
bsd-2-clause
6,916
package bootstrap.liftweb import net.liftweb.http.{Html5Properties, LiftRules, Req} import net.liftweb.sitemap.{Menu, SiteMap} /** * A class that's instantiated early and run. It allows the application * to modify lift's environment */ class Boot { def boot { // where to search snippet LiftRules.addToPa...
nmarshall23/heroku-lift
src/main/scala/bootstrap/Boot.scala
Scala
mit
595
package almhirt.domain import scala.language.postfixOps import scala.concurrent.ExecutionContext import scala.concurrent.duration._ import scalaz.Validation.FlatMap._ import akka.actor._ import almhirt.common._ import almhirt.aggregates.AggregateRootId import almhirt.snapshots._ import almhirt.tracking._ im...
chridou/almhirt
almhirt-core/src/main/scala/almhirt/domain/AggregateRootHive.scala
Scala
apache-2.0
27,650
import scala.collection.generic.CanBuildFrom import cats._ import cats.arrow.FunctionK import effectful.augments._ import effectful.impl.AbstractComposedMonad import scala.concurrent.Future package object effectful { // todo: figure out how this sugar is declared in emm // type |:[F[_],G[_]] = F[G[_]] // val |: ...
lancegatlin/effectful-demo
src/main/scala/effectful/package.scala
Scala
mit
3,702
package pl.touk.nussknacker.engine.util.metrics.common object naming { val nodeIdTag = "nodeId" val scenarioIdTag = "scenario" }
TouK/nussknacker
utils/utils/src/main/scala/pl/touk/nussknacker/engine/util/metrics/common/naming.scala
Scala
apache-2.0
137
/* * Copyright 2011-2022 GatlingCorp (https://gatling.io) * * 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 appli...
gatling/gatling
gatling-http/src/main/scala/io/gatling/http/request/builder/sse/SseRequestExpressionBuilder.scala
Scala
apache-2.0
1,545
package jp.co.cyberagent.aeromock.core.el import javax.el.ELProcessor import jp.co.cyberagent.aeromock.AeromockELException import jp.co.cyberagent.aeromock.helper._ import jp.co.cyberagent.aeromock.helper.DeepTraversal._ import org.apache.commons.lang3.StringUtils /** * EL(JSR-341) context object. * @author storm...
CyberAgent/aeromock
aeromock-server/src/main/scala/jp/co/cyberagent/aeromock/core/el/ELContext.scala
Scala
mit
1,860
package com.raymanoz.reloaded import java.io.File import com.googlecode.totallylazy.Files.write import com.googlecode.totallylazy.Strings.bytes import com.typesafe.config.ConfigException.UnresolvedSubstitution import org.scalatest.FunSuite import scala.util.Random class FallbackConfigurationLoaderTest extends FunSu...
raymanoz/typesafeconfig-reloaded
src/test/scala/com/raymanoz/reloaded/FallbackConfigurationLoaderTest.scala
Scala
apache-2.0
2,292
package hasheq package immutable import scala.collection.AbstractIterable import scala.language.higherKinds /** Witness that for all types `V`, `M[K, V]` represents an immutable map * with keys of type `K` and values of type `V`. */ trait MapRepr[M[_, _], K] { def empty[V]: M[K, V] def fromIterable[V](col: It...
TomasMikula/hasheq
src/main/scala/hasheq/immutable/MapRepr.scala
Scala
bsd-3-clause
1,599
/* * Copyright 2011-2018 GatlingCorp (http://gatling.io) * * 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 applic...
wiacekm/gatling
gatling-core/src/main/scala/io/gatling/core/controller/inject/Injector.scala
Scala
apache-2.0
5,650
/* * sbt * Copyright 2011 - 2018, Lightbend, Inc. * Copyright 2008 - 2010, Mark Harrah * Licensed under Apache License 2.0 (see LICENSE) */ package sbt import java.io.File import scala.util.control.NonFatal import testing.{ Task => TestTask, _ } import org.scalatools.testing.{ Framework => OldFramework } import ...
xuwei-k/xsbt
testing/src/main/scala/sbt/TestFramework.scala
Scala
apache-2.0
12,409
package chrome.app.window.bindings import scala.scalajs.js object BoundsSpecification { def apply( left: js.UndefOr[Int] = js.undefined, top: js.UndefOr[Int] = js.undefined, width: js.UndefOr[Int] = js.undefined, height: js.UndefOr[Int] = js.undefined, minWidth: js.UndefOr[Int] = js.u...
lucidd/scala-js-chrome
bindings/src/main/scala/chrome/app/window/bindings/BoundsSpecification.scala
Scala
mit
1,219
package com.socrata.balboa.agent import java.util.UUID import javax.jms._ import com.blist.metrics.impl.queue.MetricFileQueue import com.socrata.balboa.agent.CustomMatchers.{haveKey, haveKeyValue} import com.socrata.metrics.{Fluff, MetricIdPart} import org.apache.activemq.ActiveMQConnectionFactory import org.json4s.j...
socrata-platform/balboa
balboa-agent/src/it/scala/com/socrata/balboa/agent/WriteMetricIntegrationTest.scala
Scala
apache-2.0
3,832
/* * Copyright (C) 2012 The Regents of The University California. * All rights reserved. * * 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/LICENS...
sameeragarwal/blinkdb_dev
src/main/scala/shark/api/Row.scala
Scala
apache-2.0
4,885
/* * Copyright 2014–2018 SlamData 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 agr...
jedesah/Quasar
frontend/src/main/scala/quasar/sql/CIName.scala
Scala
apache-2.0
1,169
/*********************************************************************** * Copyright (c) 2013-2020 Commonwealth Computer Research, Inc. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Apache License, Version 2.0 * which accompanies this distribution and...
aheyne/geomesa
geomesa-convert/geomesa-convert-common/src/main/scala/org/locationtech/geomesa/convert2/transforms/ExpressionParser.scala
Scala
apache-2.0
6,041
/* Copyright 2012 Denis Bardadym 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 in ...
Khalith-Basha/demo
src/main/scala/code/snippet/SshKeyUI.scala
Scala
apache-2.0
2,168
/* * Copyright (c) 2021 Couchbase, 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 agr...
couchbaselabs/couchbase-spark-connector
src/main/scala/com/couchbase/spark/DefaultConstants.scala
Scala
apache-2.0
1,600
package fpinscala.answers.streamingio import fpinscala.answers.iomonad.* import language.higherKinds /* * A context in which exceptions can be caught and * thrown. */ trait MonadCatch[F[_]] extends Monad[F]: extension [A](fa: F[A]) def attempt: F[Either[Throwable,A]] def fail[A](t: Throwable): F[A] objec...
fpinscala/fpinscala
src/main/scala/fpinscala/answers/streamingio/MonadCatch.scala
Scala
mit
644
/* * Copyright 2017 HM Revenue & Customs * * 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...
liquidarmour/ct-calculations
src/test/scala/uk/gov/hmrc/ct/BoxValidationFixture.scala
Scala
apache-2.0
2,867
package com.seanshubin.concurrency.samples.statemachine import java.io._ import java.nio.channels.Channel import java.util.{Map, Properties} trait SystemContract { def in: InputStream def out: PrintStream def err: PrintStream def setIn(in: InputStream) def setOut(out: PrintStream) def setErr(err: Pr...
SeanShubin/concurrency-samples
statemachine/src/main/scala/com/seanshubin/concurrency/samples/statemachine/SystemContract.scala
Scala
unlicense
1,536
package com.arcusys.learn.liferay.util import com.liferay.portal.model.Country import java.util.Locale /** * User: Yulia.Glushonkova * Date: 18.08.14 */ object CountryUtilHelper { def getName(country: Country) = country.getName(Locale.getDefault) }
ViLPy/Valamis
learn-liferay620-services/src/main/scala/com/arcusys/learn/liferay/util/CountryUtilHelper.scala
Scala
lgpl-3.0
256
package trainer.modules.msgs import java.nio.ByteBuffer import libgurra.parsing.MessageParser class ShmNotifiationParser extends MessageParser[ShmNotificationMsg](10 * 1024) { override def testBuffer(buffer: ByteBuffer): Either[ShmNotificationMsg, MessageParser.ParseTestErr] = { val initialBufferPos = ...
GiGurra/bms-trainer
trainer-student/src/trainer/modules/msgs/ShmNotifiationParser.scala
Scala
gpl-2.0
1,090
import org.scalatest.funsuite.AnyFunSuite import org.scalatest.matchers.should.Matchers class TestSuite extends AnyFunSuite with Matchers { test("/") { Request("GET", "http://localhost:8080/", Map.empty, None) shouldBe Response( 200, Map("Content-Type" -> "text/html;charset=utf-8"), ...
earldouglas/xsbt-web-plugin
src/sbt-test/scala/3.0/src/test/scala/TestSuite.scala
Scala
bsd-3-clause
479
/* * This file is part of AckCord, licensed under the MIT License (MIT). * * Copyright (c) 2019 Katrix * * 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 restriction, including ...
Katrix-/AckCord
core/src/main/scala/ackcord/ackcord.scala
Scala
mit
3,239
package pl.touk.nussknacker.engine.process.compiler import org.apache.flink.api.common.functions.RuntimeContext import pl.touk.nussknacker.engine.api.JobData import pl.touk.nussknacker.engine.api.runtimecontext.{ContextIdGenerator, IncContextIdGenerator} import pl.touk.nussknacker.engine.flink.api.FlinkEngineRuntimeCo...
TouK/nussknacker
engine/flink/executor/src/main/scala/pl/touk/nussknacker/engine/process/compiler/FlinkEngineRuntimeContextImpl.scala
Scala
apache-2.0
827
package domala.internal.macros.reflect.util import scala.reflect.macros.blackbox import org.seasar.doma.internal.util.AssertionUtil.assertNotNull object ElementUtil { def getTypeElement[C <: blackbox.Context](c: C)(className: String): Option[c.Type] = { assertNotNull(className, c) val parts = className.spli...
bakenezumi/domala
core/src/main/scala/domala/internal/macros/reflect/util/ElementUtil.scala
Scala
apache-2.0
1,055
/******************************************************************************* Copyright (c) 2013, S-Core. All rights reserved. Use is subject to license terms. This distribution may include materials developed by third parties. *********************************************************************...
daejunpark/jsaf
src/kr/ac/kaist/jsaf/analysis/typing/models/Tizen/TIZENNotificationDetailInfo.scala
Scala
bsd-3-clause
4,650
// Generated by the Scala Plugin for the Protocol Buffer Compiler. // Do not edit! // // Protofile syntax: PROTO2 package com.google.protobuf.descriptor /** Describes a value within an enum. */ @SerialVersionUID(0L) final case class EnumValueDescriptorProto( name: _root_.scala.Option[_root_.scala.Predef.String]...
dotty-staging/ScalaPB
scalapb-runtime/non-jvm/src/main/scala/com/google/protobuf/descriptor/EnumValueDescriptorProto.scala
Scala
apache-2.0
9,465
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may ...
ueshin/apache-spark
core/src/test/scala/org/apache/spark/scheduler/dynalloc/ExecutorMonitorSuite.scala
Scala
apache-2.0
24,228
package org.pico.disposal import java.io.Closeable import scala.util.control.NonFatal /** Type class for objects that can be disposed. An instance is provided for AutoCloseable. * Additional instances may be provided for types that are not Closeable, particularly those found * in third-party libraries. * * ...
pico-works/pico-disposal
pico-disposal/src/main/scala/org/pico/disposal/Disposable.scala
Scala
bsd-3-clause
2,692
package scuff.ws import java.net.URL import scuff.geo import scuff.json._ import scuff.io._ import scala.util.Try /** * Retrieve various geo-location information from geo-points. * This class uses the web service at http://www.askgeo.com */ class AskGeo(urlPrefix: String, parser: AskGeo.Parser) { def this(apiI...
nilskp/scuff
src/main/scala/scuff/ws/AskGeo.scala
Scala
mit
1,926
package org.jetbrains.plugins.scala.lang.transformation package calls import com.intellij.psi.PsiElement import org.jetbrains.plugins.scala.extensions.FirstChild import org.jetbrains.plugins.scala.lang.psi.api.expr.{ScBlockExpr, ScInfixExpr} import org.jetbrains.plugins.scala.lang.psi.impl.ScalaCode._ import org.jetbr...
ilinum/intellij-scala
src/org/jetbrains/plugins/scala/lang/transformation/calls/CanonizeInfixCall.scala
Scala
apache-2.0
829
import sbt._ import Keys._ object BannerBuild extends Build { val dragontoolTask = TaskKey[File]("dragontool") val heptagTask = TaskKey[File]("heptag") }
sistanlp/banner
project/Build.scala
Scala
epl-1.0
159
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may ...
WindCanDie/spark
mllib/src/main/scala/org/apache/spark/mllib/clustering/KMeansModel.scala
Scala
apache-2.0
8,166
package com.ezoky.ezmodel.interaction.interpreter.eventsourcing import com.ezoky.ezmodel.interaction.interpreter.Interpreting import shapeless._ /** * @author gweinbach on 09/03/2021 * @since 0.2.0 */ trait EventSourcing extends Interpreting with Projecting with Publishing { /** * This combines...
ezoky/ezmodel
ezmodel-interaction/src/main/scala/com/ezoky/ezmodel/interaction/interpreter/eventsourcing/EventSourcing.scala
Scala
gpl-2.0
6,827
/* * Copyright 2012 Jonathan Anderson * * 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 agre...
nasrallahmounir/Footlights
Client/Core/src/test/scala/me/footlights/core/data/real-files.scala
Scala
apache-2.0
3,428
/* * Copyright 2012-2014 Broad Institute, Inc. * * This file is part of Pilon. * * Pilon is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 * as published by the Free Software Foundation. * * Pilon is distributed in the hope that it will be ...
AbeelLab/pilon
src/main/scala/org/broadinstitute/pilon/GenomeRegion.scala
Scala
gpl-2.0
24,729
package com.landoop.streamreactor.connect.hive.orc.vectors import java.sql.Timestamp import org.apache.hadoop.hive.ql.exec.vector.TimestampColumnVector object TimestampVectorWriter extends OrcVectorWriter[TimestampColumnVector, Timestamp] { override def write(vector: TimestampColumnVector, offset: Int, value: Opti...
datamountaineer/stream-reactor
kafka-connect-hive/src/main/scala/com/landoop/streamreactor/connect/hive/orc/vectors/TimestampVectorWriter.scala
Scala
apache-2.0
576
/* * Copyright 2014-15 Intelix Pty 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 agr...
intelix/eventstreams
es-core/es-api/src/main/scala/eventstreams/core/actors/ActorWithClusterAwareness.scala
Scala
apache-2.0
6,116
package com.sksamuel.elastic4s.requests.analyzers import org.scalatest.matchers.should.Matchers import org.scalatest.wordspec.AnyWordSpec class NGramTokenFilterTest extends AnyWordSpec with TokenFilterApi with Matchers { "NGramTokenFilter builder" should { "not set any defaults" in { ngramTokenFilter("te...
stringbean/elastic4s
elastic4s-tests/src/test/scala/com/sksamuel/elastic4s/requests/analyzers/NGramTokenFilterTest.scala
Scala
apache-2.0
542
package com.github.andriykuba.play.reactivemongo.shortcuts.exceptions import play.api.libs.json.JsObject /** * More than one document found, where only one must exist. */ case class DocumentAlreadyExists(val oldDocument: JsObject) extends Exception(oldDocument.toString())
andriykuba/reactivemongo-shortcuts-play-json
src/main/scala/com/github/andriykuba/play/reactivemongo/shortcuts/exceptions/DocumentAlreadyExists.scala
Scala
mit
279
package org.jetbrains.plugins.scala.lang.psi.api.statements import java.util.concurrent.atomic.AtomicLong import com.intellij.openapi.util.Key import com.intellij.psi.{PsiClass, PsiElement, PsiTypeParameter} import com.intellij.util.containers.ContainerUtil import org.jetbrains.plugins.scala.extensions.{ConcurrentMap...
loskutov/intellij-scala
src/org/jetbrains/plugins/scala/lang/psi/api/statements/params/package.scala
Scala
apache-2.0
2,102
package scala.tools.nsc package backend.jvm package opt import org.junit.Test import org.junit.runner.RunWith import org.junit.runners.JUnit4 import scala.tools.testing.BytecodeTesting._ @RunWith(classOf[JUnit4]) class InlinerSeparateCompilationTest { val args = "-opt:l:classpath" @Test def inlineMixedinMembe...
slothspot/scala
test/junit/scala/tools/nsc/backend/jvm/opt/InlinerSeparateCompilationTest.scala
Scala
bsd-3-clause
2,462
/** * This file is part of the TA Buddy project. * Copyright (c) 2012-2014 Alexey Aksenov [email protected] * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU Affero General Global License version 3 * as published by the Free Software Foundation with the addition...
digimead/digi-TABuddy-desktop
part-logic/src/main/scala/org/digimead/tabuddy/desktop/logic/payload/template/StringType.scala
Scala
agpl-3.0
12,726
package scala.in.programming.traits.stackable /** * @author loustler * @since 03/24/2017 22:01 */ class IncreamentingIntQueue extends BaseIntQueue with Increamenting { }
loustler/scala
src/main/scala/scala/in/programming/traits/stackable/IncreamentingIntQueue.scala
Scala
mit
178