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
/* * 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 ...
Intel-bigdata/OAP
oap-cache/oap/src/main/scala/org/apache/spark/sql/execution/datasources/orc/ReadOnlyNativeOrcFileFormat.scala
Scala
apache-2.0
1,764
package org.elasticmq.rest.sqs import xml.NodeSeq import Constants.IdSubParameter import java.util.regex.Pattern import org.elasticmq.Limits import scala.concurrent.Future trait BatchRequestsModule { this: SQSLimitsModule with ActorSystemModule => def batchParametersMap(prefix: String, parameters: Map[String, ...
adamw/elasticmq
rest/rest-sqs/src/main/scala/org/elasticmq/rest/sqs/BatchRequestsModule.scala
Scala
apache-2.0
2,508
/* * 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 agreed to in writ...
scalatest/scalatest
jvm/scalatest-test/src/test/scala/org/scalatest/EveryShouldContainAtMostOneOfLogicalOrSpec.scala
Scala
apache-2.0
43,608
// Copyright (c) 2013, Johns Hopkins University. All rights reserved. // This software is released under the 2-clause BSD license. // See /LICENSE.txt // Travis Wolfe, twolfe18@gmail.com, 30 July 2013 package edu.jhu.hlt.parma.annotation import edu.jhu.hlt.parma.types._ import edu.jhu.hlt.parma.util._ import edu.jhu...
hltcoe/parma
src/main/scala/edu/jhu/hlt/parma/annotation/TurkerScorer.scala
Scala
bsd-2-clause
11,777
package lila.pref import lila.db.JsTube import lila.db.JsTube.Helpers._ import lila.user.User case class Pref( _id: String, // user id dark: Boolean, transp: Boolean, bgImg: Option[String], is3d: Boolean, theme: String, pieceSet: String, theme3d: String, pieceSet3d: String, sou...
JimmyMow/lila
modules/pref/src/main/Pref.scala
Scala
mit
7,855
package akka.contrib.persistence.mongodb class ScalaDriverTaggingSpec extends JournalTaggingSpec(classOf[ScalaDriverPersistenceExtension], "official-scala-tagging") class ScalaDriverSuffixTaggingSpec extends JournalTaggingSpec(classOf[ScalaDriverPersistenceExtension], "official-scala-tagging-suffix", SuffixCollec...
JeanFrancoisGuena/akka-persistence-mongo
scala/src/test/scala/akka/contrib/persistence/mongodb/ScalaDriverTaggingSpec.scala
Scala
apache-2.0
350
/* * 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 ...
zzcclp/carbondata
integration/spark-common-cluster-test/src/test/scala/org/apache/carbondata/cluster/sdv/generated/InvertedindexTestCase.scala
Scala
apache-2.0
32,893
package com.googlecode.kanbanik.integration import org.junit.runner.RunWith import org.scalatest.BeforeAndAfter import org.scalatest.FlatSpec import org.scalatest.junit.JUnitRunner import com.googlecode.kanbanik.builders.{TaskBuilder, WorkflowitemTestManipulation, ProjectBuilder} import com.googlecode.kanbanik.command...
aymenhs/kanbanik
kanbanik-server/src/test/scala/com/googlecode/kanbanik/integration/IntegrationTest.scala
Scala
apache-2.0
9,136
/* * 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 ...
jkbradley/spark
core/src/test/scala/org/apache/spark/deploy/LogUrlsStandaloneSuite.scala
Scala
apache-2.0
3,032
package com.sksamuel.elastic4s.search.aggs import com.sksamuel.elastic4s.RefreshPolicy import com.sksamuel.elastic4s.testkit.DockerTests import org.scalatest.{FreeSpec, Matchers} import scala.util.Try class AvgAggregationHttpTest extends FreeSpec with DockerTests with Matchers { Try { client.execute { d...
Tecsisa/elastic4s
elastic4s-tests/src/test/scala/com/sksamuel/elastic4s/search/aggs/AvgAggregationHttpTest.scala
Scala
apache-2.0
1,270
import scala.reflect.runtime.universe._ import scala.reflect.runtime.{universe => ru} import scala.reflect.runtime.{currentMirror => cm} import scala.tools.reflect.ToolBox import scala.tools.reflect.Eval object Test extends dotty.runtime.LegacyApp { val code = reify { object C { def qwe = 4 } case class C(fo...
folone/dotty
tests/disabled/macro/run/t5271_3.scala
Scala
bsd-3-clause
475
package com.wallace.demo.app.topKDemo import java.io._ import com.wallace.demo.app.common.LogSupport import scala.collection.{immutable, mutable} import scala.util.{Failure, Success, Try} /** * Created by 10192057 on 2018/8/8 0008. */ object BigDataTopNDemo extends LogSupport { private val splitNum = 10240 ...
BiyuHuang/CodePrototypesDemo
demo/ScalaDemo/src/main/scala/com/wallace/demo/app/topKDemo/BigDataTopNDemo.scala
Scala
apache-2.0
2,361
/* * 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 ...
zzcclp/carbondata
integration/spark/src/test/scala/org/apache/carbondata/spark/testsuite/booleantype/BooleanDataTypesLoadTest.scala
Scala
apache-2.0
31,817
class Foo(@Named s: String) object Test { def main(args: Array[String]): Unit = { val ctor = classOf[Foo].getDeclaredConstructors()(0) val annots = ctor.getParameterAnnotations()(0) assert(annots.length == 1, annots.length) } }
som-snytt/dotty
tests/run/i8531/Test.scala
Scala
apache-2.0
245
package com.azavea.server import geotrellis.spark.io.kryo.KryoRegistrator import geotrellis.spark.io.hadoop._ import geotrellis.spark.io.s3._ import akka.actor.ActorSystem import akka.event.Logging import akka.http.scaladsl.Http import akka.stream.ActorMaterializer import org.apache.hadoop.conf.Configuration // impor...
geotrellis/geotrellis-pointcloud-demo
src/app-backend/server/src/main/scala/com/azavea/server/Main.scala
Scala
apache-2.0
1,985
/** * Copyright (C) 2010 Orbeon, Inc. * * This program is free software; you can redistribute it and/or modify it under the terms of the * GNU Lesser General Public License as published by the Free Software Foundation; either version * 2.1 of the License, or (at your option) any later version. * * This program i...
ajw625/orbeon-forms
src/main/scala/org/orbeon/oxf/xforms/analysis/DumbXPathDependencies.scala
Scala
lgpl-2.1
2,273
package org.example.slate.lib object SlateLibrary { def createMessageFor(name: String) = s"hello, $name!" }
x7c1/Slate
slate-application/slate-lib/src/main/scala/org/example/slate/lib/SlateLibrary.scala
Scala
mit
112
/* * MIT License * * Copyright (c) 2017 Gonçalo Marques * * 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, ...
gonmarques/slick-repo
src/test/scala/com/byteslounge/slickrepo/test/mysql/MySQLRepositoryLifecycleEventsTest.scala
Scala
mit
1,369
def flatMap[B](f: A => Optioon[B]): Optioon[B] = this match { case Noone => Noone case Soome(a) => f(a) }
grzegorzbalcerek/scala-exercises
Optioon/stepOptioonFlatMap.scala
Scala
bsd-2-clause
110
package controllers.s_employment import org.specs2.mutable._ import play.api.test.FakeRequest import play.api.test.Helpers._ import models.domain._ import models.view.CachedClaim import utils.WithApplication class GPensionAndExpensesSpec extends Specification { val iterationID = "Dummy job ID" section("unit", mo...
Department-for-Work-and-Pensions/ClaimCapture
c3/test/controllers/s_employment/GPensionAndExpensesSpec.scala
Scala
mit
2,813
package org.sackfix.tester.simplefix import org.sackfix.tester.simplefix.config.TestConfig import org.sackfix.tester.simplefix.message.{FixTags, MsgTypes, SessMessages} import org.sackfix.tester.simplefix.message.{MsgTypes, SessMessages} import scala.annotation.tailrec /** * Created by Jonathan during 2017. */ o...
PendaRed/sackfixtests
sf-fix-tester/src/main/scala/org/sackfix/tester/simplefix/SoakTester.scala
Scala
mit
1,507
package santa.ping import net.minecraftforge.common.MinecraftForge import net.minecraftforge.fml.common.Mod import net.minecraftforge.fml.common.event.{FMLInitializationEvent, FMLPreInitializationEvent} @Mod(name = "Ping!", modid = "chatping", version = "3.0.9", acceptedMinecraftVersions = "[1.9,1.12.2]", modLanguage...
elifoster/Ping
src/main/scala/santa/ping/Ping.scala
Scala
mit
719
package cucumber.runtime.scala.test import _root_.cucumber.api.scala._ import _root_.junit.framework.Assert._ object RpnCalculatorStepDefinitions extends ScalaDsl with EN { Given("""^I have (\\d+) "([^"]*)" in my belly$"""){ (howMany:Int, what:String) => } } class ThenDefs extends ScalaDsl with EN { Then(...
nilswloka/cucumber-jvm
scala/src/test/scala/cucumber/runtime/scala/test/StepDefs.scala
Scala
mit
366
/* * 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
sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/parser/TableSchemaParserSuite.scala
Scala
apache-2.0
3,192
package scaladci package examples import org.specs2.mutable.Specification import org.specs2.specification.Scope import scala.collection.mutable /* Shopping cart example (version 7), contributed by Mathew Browne This is a new version based on version 5. The main changes are the removal of the customerDepartment role ...
DCI/scaladci
examples/src/test/scala/scaladci/examples/ShoppingCart7.scala
Scala
apache-2.0
11,419
/* * 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 ma...
GitOutATown/killrweather
killrweather-clients/src/main/scala/com/datastax/killrweather/KillrWeatherClientApp.scala
Scala
apache-2.0
5,382
package gapt.testing import ammonite.ops.FilePath import gapt.expr.formula.hol.containsQuantifierOnLogicalLevel import gapt.formats.tptp.TptpImporter import gapt.proofs.context.mutable.MutableContext import gapt.proofs.expansion.ExpansionProofToLK import gapt.proofs.expansion.deskolemizeET import gapt.proofs.lk.LKProo...
gapt/gapt
testing/src/main/scala/testLKToND.scala
Scala
gpl-3.0
4,364
// scalac: -Xasync import scala.tools.testkit.async.Async._ import scala.concurrent._ import scala.concurrent.duration._ import ExecutionContext.Implicits._ object Test extends App { def stackDepth = Thread.currentThread().getStackTrace.length val future = async { val thread1 = Thread.currentThread val ...
scala/scala
test/async/jvm/syncOptimization.scala
Scala
apache-2.0
570
package com.seanshubin.scala.training.web import com.seanshubin.scala.training.core.file_system.{FileSystem, FileSystemImpl} import com.seanshubin.scala.training.core.{DataLoader, DataLoaderImpl, ItemCatalogCoreWiring} import com.seanshubin.scala.training.web.http.client.{HttpClient, HttpClientImpl} import com.seanshu...
SeanShubin/scala-training
web/src/main/scala/com/seanshubin/scala/training/web/ItemCatalogWebWiring.scala
Scala
unlicense
1,528
package example import com.typesafe.config.ConfigFactory import spray.routing.authentication._ import spray.routing.directives.LogEntry import akka.event.Logging._ import scala.concurrent.ExecutionContext.Implicits.global case class User(userName: String, token: String) {} trait ClientAuthentication { val conf =...
johanprinsloo/akka-cassandra-cluster-test
src/main/scala/example/ClientAuthentication.scala
Scala
apache-2.0
582
package org.openmole.plugin.method.sensitivity import org.scalatest.{ FlatSpec, Matchers } import org.openmole.core.workflow.test._ import scala.util.Random import org.openmole.core.dsl._ import org.openmole.core.dsl.extension._ import org.openmole.plugin.domain.collection._ import org.scalatest._ import org.openmol...
openmole/openmole
openmole/plugins/org.openmole.plugin.method.sensitivity/src/test/scala/org/openmole/plugin/method/sensitivity/SaltelliSpec.scala
Scala
agpl-3.0
1,461
package com.twitter.finagle.redis.integration import com.twitter.conversions.time._ import com.twitter.finagle.Service import com.twitter.finagle.builder.{ClientBuilder, ServerBuilder} import com.twitter.finagle.redis._ import com.twitter.finagle.redis.protocol._ import com.twitter.finagle.redis.util._ import com.twit...
stevegury/finagle
finagle-redis/src/test/scala/com/twitter/finagle/redis/integration/ClientServerIntegrationSpec.scala
Scala
apache-2.0
29,466
package org.jetbrains.plugins.scala package codeInsight.unwrap import java.util import com.intellij.codeInsight.CodeInsightBundle import com.intellij.psi.PsiElement import org.jetbrains.plugins.scala.lang.psi.api.expr.ScBlock import org.jetbrains.plugins.scala.lang.psi.api.toplevel.templates.ScTemplateBody /** * Ni...
loskutov/intellij-scala
src/org/jetbrains/plugins/scala/codeInsight/unwrap/ScalaBracesUnwrapper.scala
Scala
apache-2.0
1,322
package pl.project13.scala.akka.raft.protocol import pl.project13.scala.akka.raft.model.Term import akka.actor.ActorRef private[protocol] trait InternalProtocol extends Serializable { // just some types to make it more clear when these messages are sent, not actualy used (could be stripped) sealed trait Internal...
ktoso/akka-raft
src/main/scala/pl/project13/scala/akka/raft/protocol/InternalProtocol.scala
Scala
apache-2.0
2,145
/** * */ package plainer.utils /** * @author eddie * */ class ListExtended(val l: List[Int]) { def hasNegatives: Boolean = l.exists(_ < 0) implicit def listToListExtended(list: List[Int]) = { new ListExtended(list) } }
zeroed/plainer.scala
src/plainer/utils/ListExtended.scala
Scala
gpl-3.0
228
/* * 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 ...
dotunolafunmiloye/spark
core/src/main/scala/org/apache/spark/deploy/client/AppClient.scala
Scala
apache-2.0
6,781
package controllers import java.util.concurrent._ import javax.inject.{Singleton, Inject} import play.api.mvc._ import play.mvc.Http import play.api.libs.json.Json import models._ import scala.concurrent.{Future, ExecutionContext} @Singleton() class Application @Inject() (fortunesDAO: FortunesDAO, worldDAO: WorldDAO,...
treefrogframework/FrameworkBenchmarks
frameworks/Scala/play2-scala/play2-scala-slick/app/controllers/Application.scala
Scala
bsd-3-clause
2,295
package com.igumnov.top3000words import java.util.concurrent.{Executors, ThreadPoolExecutor} import org.jsoup.Jsoup import scala.io.Source import net.ruippeixotog.scalascraper.browser.Browser import net.ruippeixotog.scalascraper.dsl.DSL._ import net.ruippeixotog.scalascraper.dsl.DSL.Extract._ import net.ruippeixotog...
evgenyigumnov/top3000words
src/main/scala-2.11/OxfordSite.scala
Scala
agpl-3.0
2,281
/* * 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 ...
jongwook/incubator-s2graph
s2counter_core/src/main/scala/org/apache/s2graph/counter/core/v2/RankingStorageGraph.scala
Scala
apache-2.0
14,290
/*********************************************************************** * Copyright (c) 2013-2018 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...
ddseapy/geomesa
geomesa-index-api/src/main/scala/org/locationtech/geomesa/index/iterators/IteratorCache.scala
Scala
apache-2.0
3,741
/* * Copyright (c) 2018. Yuriy Stul */ package com.stulsoft.ysps.pforcomprehansion import scala.util.{Failure, Success, Try} /** * @author Yuriy Stul */ object Example6 extends App { test1() test2() test3() test4() def test1(): Unit = { println("==>test1") val result = for { _ <- f1(f...
ysden123/ysps
src/main/scala/com/stulsoft/ysps/pforcomprehansion/Example6.scala
Scala
mit
1,289
/* * 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/LICENSE-2.0 * ...
KrishnaVamsiKV/Shark
src/tachyon_enabled/scala/shark/tachyon/TachyonOffHeapTableWriter.scala
Scala
apache-2.0
2,105
/* * Copyright (c) 2014 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://www.apache.or...
jramos/iglu-scala-client
project/IgluScalaClientBuild.scala
Scala
apache-2.0
1,606
/*********************************************************************** * Copyright (c) 2013-2022 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...
locationtech/geomesa
geomesa-geojson/geomesa-geojson-rest/src/main/scala/org/locationtech/geomesa/geojson/servlet/GeoJsonServlet.scala
Scala
apache-2.0
8,035
package sc.ala.http.mock class ExpectBodiesSpec extends TestHelper { val url : String = s"http://127.0.0.1:$testPort" describe("bodies") { it("set") { HttpMock.run(testPort) { server => post(url, "body") post(url, "body2") post(url, "body", headers = Map("X-CID" -> "10")) ...
xuwei-k/http-mock
src/test/scala/sc/ala/http/mock/ExpectBodiesSpec.scala
Scala
mit
1,756
package kotlin import Keys._ import sbt._ import sbt.Keys._ import sbt.plugins.JvmPlugin /** * @author pfnguyen */ object KotlinPlugin extends AutoPlugin { override def trigger = allRequirements override def requires = JvmPlugin override def projectConfigurations = KotlinInternal :: Nil override def globa...
pfn/kotlin-plugin
src/main/scala/KotlinPlugin.scala
Scala
mit
3,377
package org.scalameta.adt import scala.language.experimental.macros import scala.reflect.macros.blackbox.Context import org.scalameta.adt.Metadata.Adt import org.scalameta.adt.{Reflection => AdtReflection} // Implementation of the scala.reflect.api.Universe#Liftable interface for adts. trait Liftables { val u: scal...
scalameta/scalameta
scalameta/common/shared/src/main/scala/org/scalameta/adt/Liftables.scala
Scala
bsd-3-clause
5,393
package me.hawkweisman.alexandria package model import scala.language.{implicitConversions, postfixOps} import scala.util.{ Try, Success, Failure } import dispatch._, Defaults._ import me.hawkweisman.util.collection.RepeatableSeq import me.hawkweisman.util.concurrent.tryToFuture import org.json4s.JsonAST.JValue imp...
alexandrialibrary/Alexandria
src/main/scala/me/hawkweisman/alexandria/model/ISBN.scala
Scala
mit
6,140
/* * Copyright (c) 2015-2022 "Neo Technology," * Network Engine for Objects in Lund AB [http://neotechnology.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.ap...
opencypher/openCypher
tools/tck-api/src/main/scala/org/opencypher/tools/tck/values/CypherValueParser.scala
Scala
apache-2.0
6,093
/* * 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 ...
zzcclp/carbondata
integration/spark/src/main/scala/org/apache/spark/sql/execution/command/index/IndexRepairCommand.scala
Scala
apache-2.0
4,761
package org.duhemm.parsermacro import scala.reflect.api.Universe trait UniverseUtils { val universe: Universe import universe._ /** * Computes the correct name for the object that holds the implementation we're looking for. */ def erasedName(sym: Symbol): String = { def rootOrEmpty(sym: Symbol) = ...
Duhemm/parsermacros
plugin/src/main/scala/org/duhemm/parsermacro/UniverseUtils.scala
Scala
bsd-3-clause
841
package mesosphere.marathon.core.appinfo import mesosphere.marathon.core.task.Task import mesosphere.marathon.health.Health import mesosphere.marathon.state.PathId case class EnrichedTask( appId: PathId, task: Task, healthCheckResults: Seq[Health], servicePorts: Seq[Int] = Nil)
ss75710541/marathon
src/main/scala/mesosphere/marathon/core/appinfo/EnrichedTask.scala
Scala
apache-2.0
289
package scala.slick.ast import scala.slick.ast.Util._ import scala.slick.ast.TypeUtil._ import scala.slick.SlickException /** * An operation which is expected to be run on the client side. */ trait ClientSideOp { def nodeMapServerSide(keepType: Boolean, r: Node => Node): Node } object ClientSideOp { /** Perfor...
dvinokurov/slick
src/main/scala/scala/slick/ast/ClientSideOp.scala
Scala
bsd-2-clause
4,170
package org.jetbrains.plugins.scala package lang package transformation package calls /** * @author Pavel Fatin */ class ExpandApplyCallTest extends TransformerTest(new ExpandApplyCall()) { override protected val header: String = """ object O { def apply(p: A) {} def apply(p1: A, p2: A) {...
ilinum/intellij-scala
test/org/jetbrains/plugins/scala/lang/transformation/calls/ExpandApplyCallTest.scala
Scala
apache-2.0
1,230
package net.node3.scalabot import akka.actor.{ Actor, ActorRef, Props } import akka.io.{ IO, Tcp } import akka.util.{ ByteString, ByteStringBuilder } import java.net.InetSocketAddress object IRC { def props(remote: InetSocketAddress, replies: ActorRef) = Props(classOf[IRC], remote, replies) } sealed trait IrcE...
nadams/scalabot
src/main/scala/IRC.scala
Scala
mit
1,744
package dispatch.github.specs import org.specs2.mutable._ import org.specs2.execute.Pending import dispatch._ import dispatch.github._ class GhCommitSpec extends Specification { "When retrieving github commits" should { "return something (not null) when the commits request is invoked" in { val commitsRes ...
andreazevedo/dispatch-github
src/test/scala/GhCommitSpec.scala
Scala
mit
3,759
package im.actor.server.persist import com.google.protobuf.ByteString import im.actor.server.db.ActorPostgresDriver.api._ import im.actor.server.model.DeviceFeature final class DeviceFeatureTable(tag: Tag) extends Table[DeviceFeature](tag, "device_features") { def authId = column[Long]("auth_id", O.PrimaryKey) d...
ljshj/actor-platform
actor-server/actor-persist/src/main/scala/im/actor/server/persist/DeviceFeatureRepo.scala
Scala
mit
1,170
package io.buoyant.linkerd.telemeter import com.fasterxml.jackson.annotation.JsonAutoDetect.Visibility import com.fasterxml.jackson.annotation.JsonInclude.Include import com.fasterxml.jackson.annotation.{JsonIgnore, PropertyAccessor} import com.fasterxml.jackson.core.JsonFactory import com.fasterxml.jackson.databind.O...
denverwilliams/linkerd
linkerd/core/src/main/scala/io/buoyant/linkerd/telemeter/UsageDataTelemeter.scala
Scala
apache-2.0
8,602
package org.jetbrains.plugins.scala.annotator import org.intellij.lang.annotations.Language import org.jetbrains.plugins.scala.ScalaBundle import org.jetbrains.plugins.scala.base.SimpleTestCase import org.jetbrains.plugins.scala.extensions.PsiElementExt import org.jetbrains.plugins.scala.lang.psi.api.ScalaFile /** ...
jastice/intellij-scala
scala/scala-impl/test/org/jetbrains/plugins/scala/annotator/AbsentTypeArgumentAnnotatorTest.scala
Scala
apache-2.0
3,744
package scala.slick.jdbc.meta import scala.slick.jdbc.PositionedResult /** * A qualified name with an optional catalog and schema. */ case class MQName(catalog: Option[String], schema: Option[String], name: String) { override def toString = "MQName(" + catalog.map(_ + ".").getOrElse("") + schema.map(_ + ".").getO...
boldradius/slick
src/main/scala/scala/slick/jdbc/meta/MQName.scala
Scala
bsd-2-clause
748
/* * 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 ...
Panos-Bletsos/spark-cost-model-optimizer
repl/scala-2.11/src/test/scala/org/apache/spark/repl/ReplSuite.scala
Scala
apache-2.0
17,989
/* * 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 ...
practice-vishnoi/dev-spark-1
sql/hive-thriftserver/src/main/scala/org/apache/spark/sql/hive/thriftserver/SparkSQLDriver.scala
Scala
apache-2.0
3,288
package lila.game import com.github.blemale.scaffeine.LoadingCache import scala.concurrent.duration._ import lila.db.dsl._ import lila.memo.{ CacheApi, MongoCache } import lila.user.User final class Cached( gameRepo: GameRepo, cacheApi: CacheApi, mongoCache: MongoCache.Api )(implicit ec: scala.concurrent...
luanlv/lila
modules/game/src/main/Cached.scala
Scala
mit
1,797
package myform case class MyAuthorizeAdminFormData( var password: String = "" ) class MyAuthorizeAdminForm() extends MyForm { val d = MyAuthorizeAdminFormData() errors += ("password" -> "") def bind: Any = { d.password = extractString("password", Some(MyForm.passwordVerifier)) if (haserrors) return th...
serversideapps/silhmojs
server/app/myforms/MyAuthorizeAdminForm.scala
Scala
apache-2.0
334
/* * 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 ...
aosagie/spark
core/src/test/scala/org/apache/spark/scheduler/TaskDescriptionSuite.scala
Scala
apache-2.0
4,329
/* * Copyright (c) 2018 OVO Energy * * 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, publish,...
ovotech/comms-kafka-messages
modules/core/src/test/scala/com/ovoenergy/comms/model/LoggableEventSpec.scala
Scala
mit
16,866
/** * Copyright 2011-2012 eBusiness Information, Groupe Excilys (www.excilys.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 * * U...
Tjoene/thesis
Case_Programs/gatling-1.4.0/gatling-charts/src/main/scala/com/excilys/ebi/gatling/charts/result/reader/stats/PercentilesHelper.scala
Scala
gpl-2.0
1,447
package timerset /*************************************************************************************************** Name: TimerSet.scala Author: Brendan Furey Date: 22-Oct-2016 Scala component of polyglot project: a simple file-reading and group-counting module, with main prog...
BrenPatF/polyglot_group
Scala/Utility/src/timerset/TimerSet.scala
Scala
gpl-3.0
7,939
import sbt._ import com.decodified.scalassh.{Command => SshCommand, _} import scala.Console.{RED, GREEN, YELLOW, BLUE, MAGENTA, CYAN, WHITE} object Utils { type Log = String => Unit def job(body: => Boolean) { if (!body) sys.error("Did not succeed") } def runCommands(host: String, state: State, commands...
stepover/zzb
project/Utils.scala
Scala
mit
3,316
import de.tototec.sbuild._ import de.tototec.sbuild.ant._ import de.tototec.sbuild.ant.tasks._ import org.apache.tools.ant.taskdefs._ @classpath("http://repo1.maven.org/maven2/org/apache/ant/ant/1.8.3/ant-1.8.3.jar") class SBuild(implicit P: Project) { // SchemeHandler("mvn", new MvnSchemeHandler())) // SchemeHan...
SBuild-org/sbuild
de.tototec.sbuild.test1/SBuild.scala
Scala
apache-2.0
1,109
/* * Copyright (C) 2016 Department for Business, Energy and Industrial Strategy * * 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) an...
UKGovernmentBEIS/rifs-business
src/main/scala/rifs/business/models/package.scala
Scala
gpl-3.0
909
package mock import com.github.kompot.play2sec.authentication.service.UserService import model.{Await, RemoteUserProvider, User, RemoteUser} import com.github.kompot.play2sec.authentication.user.{NameIdentity, ExtendedIdentity, AuthUserIdentity, AuthUser} import play.api.mvc.Request import scala.concurrent.{ExecutionC...
kompot/play2sec
test/mock/UserStore.scala
Scala
apache-2.0
5,073
package com.twitter.finagle.redis.integration import com.twitter.finagle.redis.naggati.RedisClientTest import com.twitter.finagle.redis.tags.{RedisTest, ClientTest} import com.twitter.util.Await import com.twitter.finagle.redis.util.{CBToString, StringToChannelBuffer} import org.junit.Ignore import org.junit.runner.Ru...
liamstewart/finagle
finagle-redis/src/test/scala/com/twitter/finagle/redis/commands/hash/HashClientIntegrationSuite.scala
Scala
apache-2.0
5,452
/* * Copyright 2021 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/simple-reactivemongo
src/main/scala/uk/gov/hmrc/mongo/json/JsonExtensions.scala
Scala
apache-2.0
949
/* * 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 ...
gioenn/xSpark
sql/core/src/test/scala/org/apache/spark/sql/execution/benchmark/SortBenchmark.scala
Scala
apache-2.0
5,356
package scalasearch import org.scalatest.funsuite.AnyFunSuite class FileUtilTest extends AnyFunSuite { /*************************************************************************** * getExtension tests **************************************************************************/ test("test get txt extension"...
clarkcb/xsearch
scala/scalasearch/src/test/scala/scalasearch/FileUtilTest.scala
Scala
mit
2,874
package co.technius.scalajs.mithril import org.scalajs.dom.XMLHttpRequest import scala.concurrent.Future import scala.scalajs.js class XHROptions[T]( var url: String, var method: js.UndefOr[String] = js.undefined, var data: js.UndefOr[js.Object] = js.undefined, var async: js.UndefOr[Boolean] = js.undefined, ...
Technius/scalajs-mithril
core/src/main/scala/co/technius/scalajs/mithril/Request.scala
Scala
mit
1,035
/* * ReActiveMQExtension.scala * * Updated: Feb 19, 2015 * * Copyright (c) 2015, CodeMettle */ package com.codemettle.reactivemq import com.codemettle.reactivemq.ReActiveMQExtensionImpl.ConnectionFactoryHolder import com.codemettle.reactivemq.ReActiveMQMessages.{AutoConnect, ConnectionEstablished} import com.cod...
CodeMettle/reactivemq
src/main/scala/com/codemettle/reactivemq/ReActiveMQExtension.scala
Scala
apache-2.0
3,465
/* * RunningMin.scala * (FScape) * * Copyright (c) 2001-2022 Hanns Holger Rutz. All rights reserved. * * This software is published under the GNU Affero General Public License v3+ * * * For further information, please contact Hanns Holger Rutz at * contact@sciss.de */ package de.sciss.fscape package s...
Sciss/FScape-next
core/shared/src/main/scala/de/sciss/fscape/stream/RunningMin.scala
Scala
agpl-3.0
1,835
package me.michaelgagnon.pets.web.filters // Taken from https://github.com/wunderteam/battle-pets-api/blob/master/app/web/filters/AuthFilter.scala import javax.inject.Inject import akka.stream.Materializer import play.api.Configuration import play.api.mvc._ import scala.concurrent.{ExecutionContext, Future} object...
mikegagnon/battle-pets-arena
app/web/filters/AuthFilter.scala
Scala
mit
1,021
package org.scalatest.tools.scalasbt import org.scalatest.FunSuite class SampleSuite extends FunSuite { test("test 1") { } test("test 2") { } test("test 3") { } }
svn2github/scalatest
src/test/scala/org/scalatest/tools/scalasbt/SampleSuite.scala
Scala
apache-2.0
197
/* * Copyright 2016 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 applicable l...
trask/glowroot
agent/plugins/play-plugin/src/test/app-2.5.x-scala/scala/controllers/AsyncController.scala
Scala
apache-2.0
1,408
package rocks.muki.graphql.releasenotes import sangria.schema.SchemaChange class MarkdownReleaseNotes extends ReleaseNotes { /** * Build the release changes * * @param changes the schema changes * @return human readable changelist as markdown */ override def generateReleaseNotes(changes: Vecto...
muuki88/sbt-graphql
src/main/scala/rocks/muki/graphql/releasenotes/MarkdownReleaseNotes.scala
Scala
apache-2.0
938
package toplev import utils.FileUtils import exceptions.UnreachableException /* * This is a class that provides a base class for * all passes. * * Passes from (say) AST -> AST should have * InputType = OutputType = AST. */ object Pass { var passNumber = 0; } abstract class Pass[InputType, OutputType <: Gen...
j-c-w/mlc
src/main/scala/Pass.scala
Scala
gpl-3.0
1,652
/* * Copyright (C) Lightbend Inc. <https://www.lightbend.com> */ package play.api.libs.ws.ahc.cache import org.specs2.mutable.Specification import play.shaded.ahc.io.netty.handler.codec.http.HttpHeaders.Names._ import play.shaded.ahc.org.asynchttpclient.DefaultAsyncHttpClientConfig class CacheableResponseSpec exte...
playframework/play-ws
play-ahc-ws-standalone/src/test/scala/play/api/libs/ws/ahc/cache/CacheableResponseSpec.scala
Scala
apache-2.0
1,588
package planstack.anml.model import planstack.anml.{ANMLException, parser} import scala.collection.JavaConversions._ import scala.collection.mutable /** Representation of an ANML function. * * @param name Name of the function. the function name can be of the form `functionName` if it is defined at the root of ...
planstack/anml
src/main/scala/planstack/anml/model/FunctionManager.scala
Scala
apache-2.0
9,399
/* * Distributed as part of the Stanford Topic Modeling Toolbox. * Copyright (c) 2009- The Board of Trustees of the Leland * Stanford Junior University. * * 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 Softw...
quhfus/DoSeR
Stanford Topic Model/src/main/scala/edu/stanford/nlp/tmt/data/concurrent/package.scala
Scala
gpl-2.0
2,223
/* * Created on 2010/10/14 * Copyright (c) 2010-2014, Wei-ju Wu. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * Redistributions of source code must retain the above copyright notice, ...
weiju/zmpp2
zmpp-tads3/src/main/scala/org/zmpp/tads3/BigNumber.scala
Scala
bsd-3-clause
3,587
package com.twitter.finagle import com.twitter.conversions.DurationOps._ import com.twitter.finagle.client.utils.StringClient import com.twitter.finagle.server.utils.StringServer import com.twitter.util._ import java.net.{InetAddress, InetSocketAddress} import org.scalatest.FunSuite class ResolutionRaceTest extends F...
luciferous/finagle
finagle-core/src/test/scala/com/twitter/finagle/ResolutionRaceTest.scala
Scala
apache-2.0
1,353
package com.socrata.tileserver import scala.language.implicitConversions import org.scalacheck.Arbitrary import org.scalacheck.Gen import com.socrata.http.server.responses._ import util.CoordinateMapper.Size // scalastyle:off import.grouping package object gen { object ShortStrings { case class ShortString(u...
socrata-platform/tileserver
src/test/scala/com.socrata.tileserver/implicits/package.scala
Scala
apache-2.0
6,713
package ar.com.crypticmind.swagger.modelgen import scala.reflect.macros.Context class TypeHelper[C <: Context](val c: C) { import c.universe._ def getPath(t: c.Type): List[String] = if (t.typeSymbol == c.universe.rootMirror.RootClass) Nil else t.typeSymbol.asType.name.decoded :: getPath(t.asI...
swagger-api/scala-swagger-modelgen
macros/src/main/scala_2.10/ar/com/crypticmind/swagger/modelgen/TypeHelper.scala
Scala
mit
841
/** * Copyright 2015 Thomson Reuters * * 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 ag...
dudi3001/CM-Well
tools/importTool/src/main/scala/OffsetFileHandler.scala
Scala
apache-2.0
1,171
package org.jetbrains.plugins.scala.lang.refactoring.changeSignature import java.util import java.util.Comparator import com.intellij.openapi.project.Project import com.intellij.refactoring.RefactoringHelper import com.intellij.usageView.UsageInfo /** * Nikolay.Tropin * 12-Jan-17 */ class ScalaChangeSignatureR...
ilinum/intellij-scala
src/org/jetbrains/plugins/scala/lang/refactoring/changeSignature/ScalaChangeSignatureRefactoringHelper.scala
Scala
apache-2.0
982
/* * 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 ...
mylog00/flink
flink-yarn-tests/src/test/scala/org/apache/flink/yarn/TestingYarnTaskManager.scala
Scala
apache-2.0
3,772
/* * Copyright 2014–2017 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...
drostron/quasar
frontend/src/main/scala/quasar/sql/Statement.scala
Scala
apache-2.0
4,693
package tags import org.scalatest.Tag object TestTypeTag { object FunctionalTest extends Tag("com.github.notyy.codeAnalyzer.FunctionalTest") }
notyy/CodeAnalyzerTutorial
src/test/scala/tags/TestTypeTag.scala
Scala
apache-2.0
147
package akka.persistence.hbase.journal import akka.actor.{ Actor, ActorLogging } import akka.persistence.hbase.common.{ AsyncBaseUtils, HBaseSerialization } import org.hbase.async.{ HBaseClient, KeyValue } import org.apache.hadoop.conf.Configuration // TODO: split into one API classes and register the impls as extens...
hossx/akka-persistence-hbase
src/main/scala/akka/persistence/hbase/journal/HBaseJournalBase.scala
Scala
apache-2.0
789
package troy.tast import java.util.UUID sealed trait Term sealed trait Constant extends Term sealed trait FloatNum extends Constant sealed trait FloatConstant[Value <: Float] extends FloatNum sealed trait NaN extends FloatNum sealed trait Infinity extends FloatNum sealed trait IntegerConstant[Value <: Int] extends...
schemasafe/troy
typelevel-ast/src/main/scala/troy/tast/Term.scala
Scala
apache-2.0
1,399
package se.gigurra.leavu3 import com.badlogic.gdx.ApplicationListener import com.badlogic.gdx.backends.lwjgl.{LwjglApplication, LwjglApplicationConfiguration} import com.twitter.util.{Duration, JavaTimer} import se.gigurra.leavu3.gfx.Drawable import se.gigurra.leavu3.util.DefaultTimer import com.github.gigurra.service...
GiGurra/leavu3
src/main/scala/se/gigurra/leavu3/DynamicFpsLwjglApplication.scala
Scala
mit
977
// Copyright: 2010 - 2016 https://github.com/ensime/ensime-server/graphs // Licence: http://www.gnu.org/licenses/gpl-3.0.en.html package org.ensime.sexp import collection.breakOut import scala.collection.immutable.ListMap /** * An S-Expression is either * * 1. an atom (i.e. symbol, string, number) * 2. of the for...
d1egoaz/ensime-sbt
src/sbt-test/sbt-ensime/ensime-server/s-express/src/main/scala/org/ensime/sexp/Sexp.scala
Scala
apache-2.0
3,812