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
package scala.collection.immutable import com.rklaehn.persistentsummary.Tree import scala.collection.immutable.{ RedBlackTree => RB } object CollectionTreeUtil { def toGraphVizDot[K](node: TreeSet[K]): String = { val builder = new StringBuilder val tree = treeSet[K] builder.append("digraph G {\\n") ...
rklaehn/persistentsummary
src/test/scala/scala/collection/immutable/CollectionTreeUtil.scala
Scala
apache-2.0
3,526
class DistancesTest extends CustomSpec{ }
fernandoj92/ScalaML
src/test/scala/DistancesTest.scala
Scala
gpl-3.0
44
import scala.tools.nsc.interpreter._ import scala.tools.partest.ReplTest object Test extends ReplTest { def code = """ |import scala.annotation.showAsInfix |class &&[T,U] |def foo: Int && Boolean = ??? |def foo: Int && Boolean && String = ??? |def foo: Int && (Boolean && String) = ??? |@showA...
scala/scala
test/files/run/t4700.scala
Scala
apache-2.0
784
/*********************************************************************** * 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-spark/geomesa-spark-jts/src/main/scala/org/locationtech/geomesa/spark/jts/udf/GeometricAccessorFunctions.scala
Scala
apache-2.0
5,348
package TAPL2.Recon import TAPL2.FullSimple.TypeVar import TAPL2.Lib._ import TAPL2.SimpleBool.Typed import TAPL2.TyArith.TyArith object Recon { trait Parser extends TyArith.Parser with Typed.Parser with TypeVar.Parser { val pReconE: PackratParser[Term] = pTypedE ||| pTyArithE val pReconT: PackratParse...
hy-zhang/parser
Scala/Parser/src/TAPL2/Recon/Recon.scala
Scala
bsd-3-clause
604
package com.geeksville.util import scala.collection.mutable.Queue import java.io.InputStream /** * This is a fairly specialized input stream that pulls data from a scala queue. * If the queue ever becomes empty, available will start returning 0. */ class QueueInputStream(val queue: Queue[java.lang.Byte]) extends I...
geeksville/arduleader
common/src/main/scala/com/geeksville/util/QueueInputStream.scala
Scala
gpl-3.0
488
/* * 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/self-assessment-api
app/router/resources/ReleaseTwoResource.scala
Scala
apache-2.0
2,088
package slinkydemo.http import org.specs._ object ApiTests extends Specification("JSON API Tests") { import _root_.scapps.{Json, Id}, Json._, Id._ import slinkydemo.view.JsonMimeType import spec.HttpService._ import scalaz.http.response._, Status._ lazy val registerEndpoint = "http://localhost:8081/api/reg...
tomjadams/slinky-demo
src/test/scala/slinkydemo/http/ApiTests.scala
Scala
apache-2.0
1,286
/* _ _ _ *\\ ** | (_) | | ** ** ___| |_ __| | ___ clide 2 ** ** / __| | |/ _` |/ _ \\ (c) 2012-2014 Martin Ring ...
martinring/clide2
modules/clide-web/app/clide/web/Global.scala
Scala
lgpl-3.0
2,751
package no.netcompany.testdatagen.aggreg // Copyright (C) 2014 Lars Reed -- GNU GPL 2.0 -- see LICENSE.txt import scala.collection.mutable.{Set => MutableSet} import scala.language.postfixOps import no.netcompany.testdatagen.{Generator, GeneratorImpl} /** * This generator takes two generators as input, it tries to...
lre-mesan/testdata
src/main/scala/no/netcompany/testdatagen/aggreg/UniqueWithFallback.scala
Scala
gpl-2.0
1,803
// Copyright (c) 2016 Yuichiroh Matsubayashi package yuima.nuimo.config case class LedImage(state: Array[Int], tag:String = "", brightness: Int = 75, duration: Int = 10) { def withBrightness(value: Int) = this.copy(brightness = value) def withDuration(value: Int) = this.copy(duration = value) override def toS...
Yuichiroh/nuimo-manager
src/main/scala/yuima/nuimo/config/LedImage.scala
Scala
mit
3,040
/* *\\ ** Squants ** ** ** ** Scala Quantities and Units of Measure Library and DSL ** ** (c) 2013-2015, G...
garyKeorkunian/squants
shared/src/test/scala/squants/space/SolidAngleSpec.scala
Scala
apache-2.0
2,405
/* For `Par`, `filterM` filters a list, applying the functions in parallel; for `Option`, it filters a list, but allows the filtering function to fail and abort the filter computation; for `Gen`, it produces a generator for subsets of the input list, where the function `f` picks a 'weight' for each element (in the f...
ud3sh/coursework
functional-programming-in-scala-textbook/answerkey/monads/06.answer.scala
Scala
unlicense
558
package com.codility.challenge._4_CountingElements import org.scalatest.FunSuite /** * Created by obarros on 31/10/2016. */ class PermCheck$Test extends FunSuite { test("testSolution 1") { assert(PermCheck.solution2(Array(4,1,3,2)) == 1) } test("testSolution 2") { assert(PermCheck.solution2(Array...
Obarros/Codility
src/test/scala-2.11/com/codility/challenge/_4_CountingElements/PermCheck$Test.scala
Scala
mit
343
/** * Copyright (c) 2002-2012 "Neo Technology," * Network Engine for Objects in Lund AB [http://neotechnology.com] * * This file is part of Neo4j. * * Neo4j 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 Foundati...
dksaputra/community
cypher/src/test/scala/org/neo4j/cypher/PathImplTest.scala
Scala
gpl-3.0
5,476
/*********************************************************************** * Copyright (c) 2013-2016 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 is ...
nagavallia/geomesa
geomesa-tools/src/main/scala/org/locationtech/geomesa/tools/data/DeleteCatalogCommand.scala
Scala
apache-2.0
1,482
/* * Copyright 2015 Nicolas Rinaudo * * 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...
nrinaudo/tabulate
core/shared/src/main/scala/kantan/csv/package.scala
Scala
mit
5,665
package de.tu_berlin.impro3.scala.spatio_temporal_dynamics.geo import de.tu_berlin.impro3.scala.spatio_temporal_dynamics._ /** * Geographical location represented as (latitude, longitude) coordinates * in signed degrees format. */ case class Location(lat: Double, lon: Double) { require(validGps(gps), "Invalid GP...
joroKr21/spatio-temporal-dynamics
impro3-ws14-scala/src/main/scala/de/tu_berlin/impro3/scala/spatio_temporal_dynamics/geo/Location.scala
Scala
apache-2.0
1,178
/* * This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ package swave.core.io.files.impl import java.nio.ByteBuffer import java.nio.channels.FileChannel import java....
sirthias/swave
core/src/main/scala/swave/core/io/files/impl/FileDrainStage.scala
Scala
mpl-2.0
3,966
package android import java.io.File import java.net.{HttpURLConnection, URL} import com.android.repository.Revision import com.android.repository.api._ import com.android.repository.impl.generated.generic.v1.GenericDetailsType import com.android.repository.impl.generated.v1._ import com.android.repository.io.FileOp i...
dant3/android-sdk-plugin
src/androidRepo.scala
Scala
bsd-3-clause
18,363
package com.github.j5ik2o.forseti.adaptor.repository import javax.inject.Singleton import com.github.j5ik2o.forseti.adaptor.dao.{AccessTokenDao, AccessTokenRecord} import com.github.j5ik2o.forseti.domain.accessToken.{ AccessToken, AccessTokenId, AccessTokenReader, AccessTokenType } import com.github.j5ik2o.fo...
j5ik2o/forseti
server/server-adaptor-driver/src/main/scala/com/github/j5ik2o/forseti/adaptor/repository/AccessTokenReaderImpl.scala
Scala
mit
2,279
package edu.berkeley.ce.sparkrocks /** * A simple wrapper for parsing command line inputs */ object CommandReader { case class Config( inputFile: String = "", numPartitions: Int = 25, minRadius: Double = 0.0, maxAspectRatio: Double = Double.PositiveInfinity, vtkOut: String = "", jsonOut: St...
cb-geo/spark-rocks
src/main/scala/edu/berkeley/ce/sparkrocks/CommandReader.scala
Scala
gpl-2.0
2,454
package mesosphere.marathon package api.v2.validation import java.util.regex.Pattern import com.wix.accord.Descriptions.{ Generic, Path } import com.wix.accord._ import com.wix.accord.dsl._ import mesosphere.marathon.api.v2.Validation.{ featureEnabled, _ } import mesosphere.marathon.core.externalvolume.ExternalVolume...
janisz/marathon
src/main/scala/mesosphere/marathon/api/v2/validation/AppValidation.scala
Scala
apache-2.0
26,988
package com.github.mrpowers.spark.daria.sql.types import org.apache.spark.sql.types._ import utest._ object StructTypeHelpersTest extends TestSuite { val tests = Tests { 'build - { "creates a StructType" - { val actualSchema = StructTypeHelpers.build( ("some_col", StringType, true), ...
MrPowers/spark-daria
src/test/scala/com/github/mrpowers/spark/daria/sql/types/StructTypeHelpersTest.scala
Scala
mit
1,961
/** * Copyright 2013 amato * * This file is part of JANDOM: JVM-based Analyzer for Numerical DOMains * JANDOM 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 yo...
francescaScozzari/Jandom
core/src/main/scala/it/unich/jandom/ui/gui/SootEditorPane.scala
Scala
lgpl-3.0
10,035
package com.novocode.squery import com.novocode.squery.session.Session import com.novocode.squery.sql.DDLBuilder class DDLInvoker[T](table: Table[T]) { lazy val createTableStatement = new DDLBuilder(table).buildCreateTable def createTable(implicit session: Session) { val st = session.allocPS(createTableStat...
gnufied/squery
src/com/novocode/squery/DDLInvoker.scala
Scala
bsd-2-clause
405
package uk.gov.gds.ier.stubs import com.google.inject.Inject import uk.gov.gds.ier.model._ import scala.util.Random import scala.Some import uk.gov.gds.ier.model.Nino import uk.gov.gds.ier.service.apiservice.{ConcreteIerApiService, IerApiService} import uk.gov.gds.ier.transaction.crown.InprogressCrown import uk.gov.gd...
alphagov/ier-frontend
app/uk/gov/gds/ier/stubs/IerApiServiceWithStripNino.scala
Scala
mit
6,274
/* * Copyright 2011 javaBin * 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...
javaBin/submitit
submitit-webapp/src/main/scala/no/java/submitit/app/pages/LayoutPage.scala
Scala
mit
1,365
/* * 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 ...
hhbyyh/spark
sql/core/src/main/scala/org/apache/spark/sql/SparkSession.scala
Scala
apache-2.0
39,083
/* * 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 ...
Dax1n/spark-core
core/src/main/scala/org/apache/spark/storage/DiskStore.scala
Scala
apache-2.0
5,895
/* * 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 ...
manuzhang/incubator-gearpump
services/js/src/main/scala/org/apache/gearpump/dashboard/DashboardApp.scala
Scala
apache-2.0
1,005
package com.sksamuel.elastic4s.requests.searches.aggs.builders import com.sksamuel.elastic4s.handlers import com.sksamuel.elastic4s.handlers.script.ScriptBuilderFn import com.sksamuel.elastic4s.json.{XContentBuilder, XContentFactory} import com.sksamuel.elastic4s.requests.searches.aggs.AvgAggregation object AvgAggreg...
sksamuel/elastic4s
elastic4s-core/src/main/scala/com/sksamuel/elastic4s/requests/searches/aggs/builders/AvgAggregationBuilder.scala
Scala
apache-2.0
743
package org.littlewings.tweetbot.application.carat.information.config import javax.enterprise.context.ApplicationScoped import com.typesafe.config.{Config, ConfigFactory} import org.littlewings.tweetbot.config.EncryptTwitterConfigSupport @ApplicationScoped class CaratInformationConfig extends EncryptTwitterConfigSup...
kazuhira-r/tweet-bot
src/main/scala/org/littlewings/tweetbot/application/carat/information/config/CaratInformationConfig.scala
Scala
mit
514
package com.github.dzhg.tedis.commands import com.github.dzhg.tedis.protocol.RESP.{ArrayValue, BulkStringValue, IntegerValue, RESPValue} import com.github.dzhg.tedis.TedisStorage /** * @author dzhg 8/11/17 */ trait TedisCommand[T] extends CommandHelper { def exec(storage: TedisStorage): T def execToRESP(stora...
dzhg/tedis
src/main/scala/com/github/dzhg/tedis/commands/TedisCommand.scala
Scala
mit
1,189
/* * 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 ...
darionyaphet/flink
flink-table/flink-table-planner-blink/src/main/scala/org/apache/flink/table/planner/plan/nodes/physical/batch/BatchExecCalc.scala
Scala
apache-2.0
2,873
package edu.mit.csail.sdg.ormolu.rel import edu.mit.csail.sdg.hsqldb.syntax.reference.SchemaRef /** * An AtomSet represents a signature, a named set of Atoms in the Alloy language. */ abstract class AtomSet(val name: String) extends Named(1) { override def toString: String = name override val tableRe...
dlreeves/ormolu
src/edu/mit/csail/sdg/ormolu/rel/AtomSet.scala
Scala
mit
1,831
package entitytled.profile import entitytled.Entitytled import slick.driver.MySQLDriver trait MySQLProfile extends Entitytled { val driver: MySQLDriver = MySQLDriver } object MySQLProfile extends MySQLProfile
RSSchermer/entitytled
core/src/main/scala/entitytled/profile/MySQLProfile.scala
Scala
mit
214
package edu.msstate.dasi.csb.workload.spark import edu.msstate.dasi.csb.workload.Workload import org.apache.spark.graphx.Graph import scala.reflect.ClassTag /** * Counts the number of edges in the graph. */ class CountEdges(engine: SparkEngine) extends Workload { val name = "Count edges" /** * Counts the n...
msstate-dasi/csb
csb/src/main/scala/edu/msstate/dasi/csb/workload/spark/CountEdges.scala
Scala
gpl-3.0
440
/* * Copyright 2012 Comcast Cable Communications Management, 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 require...
Comcast/money
money-core/src/main/scala/com/comcast/money/core/Tracer.scala
Scala
apache-2.0
9,902
object Test extends App { object Foo val foo = "foo" implicitly[ValueOf[1]] implicitly[ValueOf[1L]] implicitly[ValueOf[1.0]] implicitly[ValueOf[1.0F]] implicitly[ValueOf[true]] implicitly[ValueOf['f']] implicitly[ValueOf["foo"]] implicitly[ValueOf[Unit]] implicitly[ValueOf[Foo.type]] implicitly...
som-snytt/dotty
tests/run/sip23-valueof.scala
Scala
apache-2.0
744
package org.bitcoins.core.protocol.script import org.bitcoins.testkitcore.gen.ScriptGenerators import org.scalacheck.{Prop, Properties} /** Created by chris on 6/24/16. */ class P2SHScriptSignatureSpec extends Properties("P2SHScriptSignatureSpec") { property("Symmetrical serialization") = Prop.forAll(ScriptG...
bitcoin-s/bitcoin-s
core-test/src/test/scala/org/bitcoins/core/protocol/script/P2SHScriptSignatureSpec.scala
Scala
mit
846
/* * Copyright (c) 2014-2015 by its authors. Some rights reserved. * See the project homepage at: http://www.monifu.org * * 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://...
virtualirfan/monifu
core/js/src/main/scala/monifu/concurrent/Implicits.scala
Scala
apache-2.0
1,210
package example import org.scalatra.test.scalatest.ScalatraFlatSpec import skinny.micro.WebApp class QueryParamsAccessorSpec extends ScalatraFlatSpec { behavior of "QueryParamsAccessor" class Controller extends WebApp { def single = queryParams.getAs[String]("foo").getOrElse("<empty>") def multi = queryM...
xerial/skinny-micro
micro/src/test/scala/example/QueryParamsAccessorSpec.scala
Scala
bsd-2-clause
1,385
// Databricks notebook source // MAGIC %md // MAGIC // MAGIC # [SDS-2.2, Scalable Data Science](https://lamastex.github.io/scalable-data-science/sds/2/2/) // COMMAND ---------- // MAGIC %md // MAGIC Archived YouTube video of this live unedited lab-lecture: // MAGIC // MAGIC [![Archived YouTube video of this live un...
lamastex/scalable-data-science
db/2/2/038_StructuredStreamingProgGuide.scala
Scala
unlicense
82,536
package com.chrisrebert.lmvtfy.util object IsHtmlish { private val startTag = "<[a-zA-Z]+>".r.unanchored private val endTag = "</[a-zA-Z]+>".r.unanchored def unapply(maybeHtml: String): Boolean = apply(maybeHtml) def apply(maybeHtml: String): Boolean = (maybeHtml matches startTag) && (maybeHtml matches endTag...
cvrebert/lmvtfy
src/main/scala/com/chrisrebert/lmvtfy/util/IsHtmlish.scala
Scala
mit
324
/* * Copyright 2013-2015 Websudos, Limited. * * 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, * this list of c...
analytically/phantom
phantom-dsl/src/test/scala/com/websudos/phantom/builder/query/db/batch/CounterBatchTest.scala
Scala
bsd-2-clause
10,826
package maastar.policy import maastar.agent.Agent import maastar.algorithm.maastar.PolicyEvaluator import maastar.algorithm.policyiteration.MdpPolicyIterationEvaluator import maastar.game.{State, TigerGame} /** * Created by nwertzberger on 6/25/14. */ object PolicyValueOrdering extends Ordering[Policy] { def co...
nwertzberger/maastar
src/main/scala/maastar/policy/PolicyValueOrdering.scala
Scala
apache-2.0
410
import scala.annotation.tailrec import scala.collection.mutable import scala.collection.mutable.ArrayBuffer /** * Created by eklavya on 4/12/13. */ /* a) breadth first search can find shortest paths from a vertex s to all others 1. The initial vertex s is given distance ds = 0 and a weight ws = 1. 2. Every vertex ...
eklavya/findMeAGroup
src/main/scala/Graph.scala
Scala
apache-2.0
7,197
/* # Copyright 2016 Georges Lipka # # 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 wri...
glipka/Easy-React-With-ScalaJS
src/main/scala/com/glipka/easyReactJS/reactBootstrap/PageItem.scala
Scala
apache-2.0
1,001
package im.actor.server.file import java.io.ByteArrayOutputStream import akka.actor.ActorSystem import com.sksamuel.scrimage.nio.{ ImageWriter, JpegWriter, PngWriter } import com.sksamuel.scrimage.{ Image, ParImage, Position } import im.actor.server.acl.ACLUtils import im.actor.server.db.DbExtension import im.actor.s...
EaglesoftZJ/actor-platform
actor-server/actor-core/src/main/scala/im/actor/server/file/ImageUtils.scala
Scala
agpl-3.0
7,259
/** * Licensed to Big Data Genomics (BDG) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The BDG licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you may not use ...
bigdatagenomics/PacMin
pacmin-core/src/main/scala/org/bdgenomics/pacmin/overlapping/MinHashableRead.scala
Scala
apache-2.0
1,968
object Test { case class Tag0[T <: Singleton](a: T) Tag0("a").copy() case class Tag1[T](a: T) Tag1("a").copy() def foo[T <: Singleton](a: T = "a"): T = a val v0: "a" = foo() def bar(a: "a" = "a"): "a" = a val v1: "a" = bar() def baz[T](a: T = "a"): T = a val v2: "a" = baz() def id[T](a: T): T...
scala/scala
test/files/pos/sip23-named-default.scala
Scala
apache-2.0
351
/* * 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 ...
EvilMcJerkface/kudu
java/kudu-spark/src/test/scala/org/apache/kudu/spark/kudu/TestContext.scala
Scala
apache-2.0
6,208
package com.github.zenpie.macrowave import scala.annotation.StaticAnnotation class whiteSpace extends StaticAnnotation
zen-pie/macrowave
src/main/scala/com/github/zenpie/macrowave/whiteSpace.scala
Scala
mit
121
package com.originate.scalypher import com.originate.scalypher.action.Action import com.originate.scalypher.path.Path import com.originate.scalypher.types._ import com.originate.scalypher.where.Where case class MatchQuery(pathMatch: Path, where: Option[Where], action: Action) extends Query { def getReturnColumns: ...
Originate/scalypher
src/main/scala/query/MatchQuery.scala
Scala
mit
959
/* * Copyright 2001-2008 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...
svn2github/scalatest
src/main/scala/org/scalatest/fixture/Spec.scala
Scala
apache-2.0
12,832
package elegans import Cells._ import Constraints._ import z3.scala._ trait Semantics { /** Perform initial work with cells */ def initializeConstraints(cells: List[Cell], scheduleLength: Int): Unit /** Finalize constraints before solver invocation */ def finalizeConstraints(): Unit /** Reset internal sta...
koksal/elegans-popl2013-code
src/main/scala/elegans/Semantics.scala
Scala
bsd-2-clause
1,118
package fi.proweb.train.actor.core import akka.actor.Actor import fi.proweb.train.model.app.Train import akka.actor.ActorRef import fi.proweb.train.actor.component.store.TrainStore import akka.actor.Props import scala.concurrent.duration._ import fi.proweb.train.model.app.TrainStation import akka.actor.ActorLogging im...
roikonen/MissaJuna
app/fi/proweb/train/actor/core/TrainObserver.scala
Scala
apache-2.0
2,175
package io.aos.ebnf.spl.protocol import spray.json._ import io.aos.ebnf.util.JsonUtil object JsonProtocol extends DefaultJsonProtocol { implicit val queryRequest = jsonFormat2(QueryRequest) implicit val metadataRequest = jsonFormat2(MetadataRequest) implicit val helpRequest = jsonFormat1(HelpRequest) impl...
echalkpad/t4f-data
parser/ebnf/src/main/scala/io/aos/ebnf/spl/protocol/JsonProtocol.scala
Scala
apache-2.0
1,188
package models class Week(val number: Integer, val startDate: String, val endDate: String, val url: String)
maxmouchet/vamk-timetables
parsers/src/main/scala/models/Week.scala
Scala
mit
109
/* * Copyright 2016 The BigDL 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 law or agr...
JerryYanWan/BigDL
spark/dl/src/main/scala/com/intel/analytics/bigdl/nn/LSTMPeephole.scala
Scala
apache-2.0
6,671
package gitbucket.core.ssh import gitbucket.core.model.Session import gitbucket.core.plugin.{GitRepositoryRouting, PluginRegistry} import gitbucket.core.service.{RepositoryService, AccountService, SystemSettingsService} import gitbucket.core.servlet.{Database, CommitLogHook} import gitbucket.core.util.{Directory, Cont...
marklacroix/gitbucket
src/main/scala/gitbucket/core/ssh/GitCommand.scala
Scala
apache-2.0
6,684
package mesosphere.marathon import akka.actor.ActorSystem import akka.testkit.{ TestKit, TestProbe } import mesosphere.marathon.Protos.MarathonTask import mesosphere.marathon.core.launchqueue.LaunchQueue import mesosphere.marathon.health.HealthCheckManager import mesosphere.marathon.state.{ AppDefinition, AppRepositor...
sepiroth887/marathon
src/test/scala/mesosphere/marathon/SchedulerActionsTest.scala
Scala
apache-2.0
6,203
package models /* * Copyright 2014 YMC. See LICENSE for details. */ import org.specs2.mutable._ import play.api.test._ import play.api.test.Helpers._ import play.api.cache.Cache import scala.collection.Seq import scala.collection.Map import play.api.Play.current class RegionSpec extends Specification { "Region" ...
Connexity/hannibal
test/models/RegionSpec.scala
Scala
apache-2.0
2,577
/** * Copyright (C) 2010-2011 LShift 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...
0x6e6562/diffa
kernel/src/main/scala/net/lshift/diffa/kernel/frontend/DomainDef.scala
Scala
apache-2.0
926
package chrome.alarms.bindings import scala.scalajs.js @js.native trait Alarm extends js.Object { def name: String = js.native def scheduledTime: Double = js.native def periodInMinutes: js.UndefOr[Double] = js.native }
lucidd/scala-js-chrome
bindings/src/main/scala/chrome/alarms/bindings/Alarm.scala
Scala
mit
229
// Copyright (c) 2012 Cloudera, Inc. 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 // // Unless required by applica...
cloudera/RecordServiceClient
java/spark/src/test/scala/com/cloudera/recordservice/spark/SharedSparkContext.scala
Scala
apache-2.0
1,291
/* * 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
sql/core/src/test/scala/org/apache/spark/sql/execution/QueryExecutionSuite.scala
Scala
apache-2.0
5,360
package com.seanshubin.learn.spark.core import java.io.PrintWriter import java.nio.file.Path class SampleDataGeneratorImpl(wordFactory: WordFactory, fileSystem: FileSystem, sampleDataPath: Path, fileCount: Int, ...
SeanShubin/learn-spark
core/src/main/scala/com/seanshubin/learn/spark/core/SampleDataGeneratorImpl.scala
Scala
unlicense
1,078
/* elm-scala: an implementation of ELM in Scala using MTJ Copyright (C) 2014 Davi Pereira dos Santos 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 yo...
Crespo911/elm-scala
src/main/scala/ml/neural/elm/ConvexIELMTrait.scala
Scala
gpl-3.0
4,559
package com.sksamuel.elastic4s.searches.aggs import com.sksamuel.elastic4s.ScriptBuilder import org.elasticsearch.search.aggregations.AggregationBuilders import org.elasticsearch.search.aggregations.metrics.valuecount.ValueCountAggregationBuilder import scala.collection.JavaConverters._ object ValueCountAggregationB...
aroundus-inc/elastic4s
elastic4s-tcp/src/main/scala/com/sksamuel/elastic4s/searches/aggs/ValueCountAggregationBuilder.scala
Scala
apache-2.0
758
/* * 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/fset-faststream
test/controllers/OnlineTestControllerSpec.scala
Scala
apache-2.0
8,373
import sbt._ import Keys._ import sbtassembly.Plugin._ import AssemblyKeys._ object Build extends Build { val akkaVersion = "2.2-M3" val logbackVersion = "1.0.13" val scalikejdbcVersion = "[1.6,)" val defaultBuildSettings = Seq( version := "0.1.0-SNAPSHOT", organization := "org.nkvoll", scalaVersi...
nkvoll/scala-gpsd
project/build.scala
Scala
mit
1,822
package com.twitter.finagle.exp.pushsession import com.twitter.conversions.time._ import com.twitter.finagle.{Failure, IndividualRequestTimeoutException => FinagleTimeoutException} import com.twitter.finagle.stats.{InMemoryStatsReceiver, NullStatsReceiver} import com.twitter.util.{Await, MockTimer, Promise, Time, Time...
mkhq/finagle
finagle-core/src/test/scala/com/twitter/finagle/exp/pushsession/PipeliningClientPushSessionTest.scala
Scala
apache-2.0
4,349
package org.bizzle.tester.suite import org.scalatest.Suite /** * Created by IntelliJ IDEA. * User: Jason * Date: 1/18/12 * Time: 10:50 PM */ class SuiteReporter[+T <: Suite](val suites: Seq[T] = Seq[Suite]()) { def ++[U >: T <: Suite](that: SuiteReporter[U]) : SuiteReporter[U] = new SuiteReporter[U](suites ...
TheBizzle/Tester
src/main/org/bizzle/tester/suite/SuiteReporter.scala
Scala
bsd-3-clause
338
/* Copyright (c) 2009, 2010 Hanno Braun <mail@hannobraun.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 applicable law or...
hannobraun/ScalableDynamics
src/main/scala/com/hannobraun/sd/collision/test/MovingCircleCircleTest.scala
Scala
apache-2.0
5,537
/* * Scala (https://www.scala-lang.org) * * Copyright EPFL and Lightbend, Inc. * * Licensed under Apache License 2.0 * (http://www.apache.org/licenses/LICENSE-2.0). * * See the NOTICE file distributed with this work for * additional information regarding copyright ownership. */ package scala.tools.nsc packag...
martijnhoekstra/scala
src/compiler/scala/tools/nsc/reporters/Reporter.scala
Scala
apache-2.0
6,546
// Copyright (C) 2014 Open Data ("Open Data" refers to // one or more of the following companies: Open Data Partners LLC, // Open Data Research LLC, or Open Data Capital LLC.) // // This file is part of Hadrian. // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in ...
opendatagroup/hadrian
hadrian/src/main/scala/com/opendatagroup/hadrian/lib/spec.scala
Scala
apache-2.0
12,973
package com.lkroll.ep.mapviewer.data import com.lkroll.ep.mapviewer.datamodel._ import java.util.UUID; import squants._ import squants.space._ import squants.space.{AstronomicalUnits => AU} import squants.time._ import squants.motion._ import Languages._ import Polities.{PlanetaryConsortium => _, _} import Corps._ i...
Bathtor/ep-explorer
src/main/scala/com/lkroll/ep/mapviewer/data/Habitats.scala
Scala
mit
458
package com.github.ldaniels528.trifecta.command /** * Represents a set of Unbounded Parameters * @author lawrence.daniels@gmail.com */ case class UnboundedParams(minimum: Int) extends CommandParameters[Seq[String]] { /** * Validates that the given tokens are acceptable as arguments for the given command * ...
ldaniels528/trifecta
app-modules/core/src/main/scala/com/github/ldaniels528/trifecta/command/UnboundedParams.scala
Scala
apache-2.0
1,061
/* * Copyright 2017 Exon IT * * 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 w...
exon-it/redmine-scala-client
client-core/src/main/scala/by/exonit/redmine/client/managers/impl/MembershipManagerImpl.scala
Scala
apache-2.0
2,917
package org.rogach.scallop.exceptions import reflect.runtime.universe._ /** Parent trait for all not-positive results that can be resulted from this library (including help and exits) */ sealed trait ScallopResult /** Thrown when user requested help output (via "--help") */ case class Help(command: String) extends T...
billonahill/scallop
src/main/scala/org.rogach.scallop/Exceptions.scala
Scala
mit
3,649
package bootstrap.liftweb import net.liftweb._ import util._ import Helpers._ import mapper._ import common._ import http._ import ${organization}.util._ /** * A class that's instantiated early and run. It allows the application * to modify lift's environment */ class Boot { def boot { // where ...
riveramj/liftweb-generator
startingFiles/Boot.scala
Scala
apache-2.0
1,185
package de.hpi.asg.breezetestgen.domain.components import de.hpi.asg.breezetestgen.domain.{DataAcknowledge, PullChannel, _} import de.hpi.asg.breezetestgen.testgeneration.{Follow, Merge, TestOp, constraintsolving} import constraintsolving.{Constraint, ConstraintVariable} import de.hpi.asg.breezetestgen.testing.TestEve...
0x203/BreezeTestGen
src/main/scala/de/hpi/asg/breezetestgen/domain/components/BrzComponentBehaviour.scala
Scala
mit
5,769
package composition.webserviceclients.vrmretentioneligibility import com.tzavellas.sse.guice.ScalaModule import composition.webserviceclients.vrmretentioneligibility.Helper.createResponse import org.mockito.Matchers.any import org.mockito.Mockito.when import org.scalatest.mock.MockitoSugar import play.api.http.Status....
dvla/vrm-retention-online
test/composition/webserviceclients/vrmretentioneligibility/EligibilityWebServiceCallWithSensitiveResponse.scala
Scala
mit
1,595
/** * @author Yuuto */ package yuuto.inventorytools.network import net.minecraftforge.common.DimensionManager import cpw.mods.fml.common.network.simpleimpl.IMessageHandler import net.minecraft.tileentity.TileEntity import cpw.mods.fml.common.network.simpleimpl.IMessage import yuuto.inventorytools.tiles.TileToolBench...
AnimeniacYuuto/InventoryTools
src/main/scala/yuuto/inventorytools/network/MessageToolBenchHandler.scala
Scala
gpl-3.0
1,008
/* * 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 ...
ptkool/spark
core/src/test/scala/org/apache/spark/deploy/StandaloneDynamicAllocationSuite.scala
Scala
apache-2.0
26,212
/** * 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...
robort/kafka
core/src/test/scala/unit/kafka/utils/TestUtils.scala
Scala
apache-2.0
38,898
package com.github.ldaniels528.trifecta.messages import com.github.ldaniels528.trifecta.messages.query.KQLSource /** * This trait should be implemented by classes that are interested in serving as an * input source for reading binary messages * @author lawrence.daniels@gmail.com */ trait MessageInputSource { /...
ldaniels528/trifecta
src/main/scala/com/github/ldaniels528/trifecta/messages/MessageInputSource.scala
Scala
apache-2.0
708
/* * This file is part of pelam-scala-csv * * Copyright Β© Peter Lamberg 2015 (pelam-scala-csv@pelam.fi) * * 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/...
pelamfi/pelam-scala-csv
src/main/scala/fi/pelam/csv/package.scala
Scala
apache-2.0
2,047
package s3.website import s3.website.ErrorReport.errorMessage import s3.website.model._ import com.amazonaws.services.s3.{AmazonS3, AmazonS3Client} import com.amazonaws.services.s3.model._ import scala.collection.JavaConversions._ import scala.concurrent.{ExecutionContextExecutor, Future} import com.amazonaws.services...
SivagnanamCiena/s3_website
src/main/scala/s3/website/S3.scala
Scala
mit
9,634
/** * 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 not...
gf53520/kafka
core/src/test/scala/integration/kafka/api/SaslMultiMechanismConsumerTest.scala
Scala
apache-2.0
3,907
package com.ing.baker.runtime.common import com.ing.baker.runtime.common.LanguageDataStructures.LanguageApi import com.ing.baker.types.Type /** * Provides an implementation for an interaction. */ trait InteractionInstanceDescriptor extends LanguageApi { self => type Ingredient <: IngredientInstance { type Lang...
ing-bank/baker
core/baker-interface/src/main/scala/com/ing/baker/runtime/common/InteractionInstanceDescriptor.scala
Scala
mit
869
/* * The MIT License (MIT) * * Copyright (c) 2014 Heiko Blobner * * 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...
windelknecht/stup-utils
src/main/scala/de/windelknecht/stup/utils/ui/ImageHelper.scala
Scala
mit
4,148
package com.github.vonnagy.service.container.http.routing import akka.actor._ import akka.http.scaladsl.model.{HttpEntity, MediaTypes, StatusCodes} import akka.http.scaladsl.server.{Directives, Route} import akka.testkit.{TestActorRef, TestProbe} import com.github.vonnagy.service.container.Specs2RouteTest import com.g...
vonnagy/service-container
service-container/src/test/scala/com/github/vonnagy/service/container/http/routing/RoutedServiceSpec.scala
Scala
apache-2.0
3,118
/* * 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...
lresende/incubator-toree
kernel/src/main/scala/org/apache/toree/boot/KernelBootstrap.scala
Scala
apache-2.0
6,083
package sc.ala.neo4j.commands import sc.ala.neo4j._ import org.neo4j.kernel.EmbeddedGraphDatabase import org.neo4j.graphdb._ import org.neo4j.graphalgo.GraphAlgoFactory import org.neo4j.kernel.Traversal import scala.collection.mutable.Map import scala.collection.JavaConversions._ import scala.Console.err trait Dijkst...
maiha/neo4j
src/main/scala/sc/ala/neo4j/commands/DijkstraPath.scala
Scala
mit
790
package actors import akka.actor.{ActorRef, Props} import akka.agent.Agent import markets.orders.Order import markets.participants.RandomLiquidityMarketMaker import markets.tickers.Tick import markets.tradables.Tradable import strategies.trading.{ZIMarketOrderTradingStrategy, ZILimitOrderTradingStrategy} import scal...
ScalABM/models-library
london-stock-exchange/src/main/scala-2.11/actors/ZILiquidityMarketMaker.scala
Scala
apache-2.0
2,131
package com.github.diegopacheco.scala.playground.akka.futures import akka.actor.ActorSystem object SimpleFutureApp extends App { import scala.concurrent.{ ExecutionContext, Promise } val system = ActorSystem("futures-system") implicit val ec = system.dispatcher val f = Promise.successful("foo").future ...
diegopacheco/scala-playground
scala-akka-futures/src/main/scala/com/github/diegopacheco/scala/playground/akka/futures/SimpleFutureApp.scala
Scala
unlicense
545
// Project: surf (https://github.com/jokade/surf) // Module: core / shared // Description: A service mixin that executes a function before and after the request is processed. // Copyright (c) 2015 Johannes Kastner <jokade@karchedon.de> // Distributed under the MIT license (see included LICENSE f...
jokade/surf
core/shared/src/main/scala/surf/service/AroundProcess.scala
Scala
mit
1,023