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 homework import homework.State._ import homework.RNG._ trait RNG { def nextInt: (Int, RNG) } case class SimpleRNG(seed: Long) extends RNG { def nextInt: (Int, RNG) = { val newSeed = (seed * 0x5DEECE66DL + 0xBL) & 0xFFFFFFFFFFFFL val nextRNG = SimpleRNG(newSeed) val n = (newSeed >>> 16).toInt ...
laser/fp-in-scala
src/main/scala/homework/Random.scala
Scala
mit
2,421
package com.arcusys.valamis.certificate.storage.repository import com.arcusys.valamis.certificate.model.goal.{GoalType, PackageGoal} import com.arcusys.valamis.certificate.storage.schema.PackageGoalTableComponent import com.arcusys.valamis.certificate.storage.{CertificateGoalRepository, PackageGoalStorage} import com....
igor-borisov/valamis
valamis-certificate/src/main/scala/com/arcusys/valamis/certificate/storage/repository/PackageGoalStorageImpl.scala
Scala
gpl-3.0
2,353
/** * Copyright (C) 2009-2011 the original author or authors. * See the notice.md file distributed with this work for additional * information regarding copyright ownership. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * Yo...
dnatic09/scalate
scalate-tool/src/main/scala/org/fusesource/scalate/tool/commands/ConfluenceExport.scala
Scala
apache-2.0
8,684
/* * 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/test/scala/org/apache/spark/status/api/v1/sql/SqlResourceWithActualMetricsSuite.scala
Scala
apache-2.0
5,343
package io.github.tpartyka.testapp.api /** * Created by tpartyka on 24.05.2017. */ case class CalculationRequest(expression: String)
tpartyka/test-app
src/main/scala/io/github/tpartyka/testapp/api/CalculationRequest.scala
Scala
mit
138
package net.jcazevedo.moultingyaml import com.github.nscala_time.time.Imports._ trait BasicFormats { implicit object IntYamlFormat extends YamlFormat[Int] { def write(x: Int) = YamlNumber(x) def read(value: YamlValue) = value match { case v @ YamlNumber(x) => v.num.toInt(x) case x => de...
DDuarte/moultingyaml
src/main/scala/net/jcazevedo/moultingyaml/BasicFormats.scala
Scala
mit
4,347
package com.ing.baker.runtime.akka.actor.process_instance import akka.actor._ import akka.event.{DiagnosticLoggingAdapter, Logging} import akka.persistence.{DeleteMessagesFailure, DeleteMessagesSuccess} import cats.effect.IO import cats.syntax.apply._ import com.ing.baker.il.petrinet.Transition import com.ing.baker.pe...
ing-bank/baker
core/akka-runtime/src/main/scala/com/ing/baker/runtime/akka/actor/process_instance/ProcessInstance.scala
Scala
mit
18,994
package lila.game import chess.{ Color, Status } import org.joda.time.DateTime import play.api.libs.json._ import lila.db.api._ import lila.user.User object Query { import Game.{ BSONFields => F } val all: JsObject = $select.all val rated: JsObject = Json.obj(F.rated -> true) def rated(u: String): JsObje...
Enigmahack/lila
modules/game/src/main/Query.scala
Scala
mit
2,393
package json.bench.handwritten import com.fasterxml.jackson.core._ import com.fasterxml.jackson.core.io.{IOContext, SegmentedStringWriter} import com.fasterxml.jackson.core.json.WriterBasedJsonGenerator import com.fasterxml.jackson.core.util.BufferRecycler import com.fasterxml.jackson.databind.ObjectMapper import _roo...
tethys-json/tethys
modules/benchmarks/src/main/scala/json/bench/handwritten/HandwrittenBench.scala
Scala
apache-2.0
10,988
package controllers import javax.inject.Inject import models._ import play.api.mvc.Results._ import play.api.mvc._ import scalikejdbc.DB import scala.concurrent.ExecutionContext.Implicits.global import scala.concurrent.{ ExecutionContext, Future } import scala.reflect.{ ClassTag, classTag } import jp.t2v.lab.play2.a...
t2v/play2-auth
social-sample/app/controllers/Application.scala
Scala
apache-2.0
6,810
package org.hammerlab.guacamole.variants import java.io.OutputStream import org.apache.avro.generic.GenericDatumWriter import org.apache.avro.io.EncoderFactory import org.apache.hadoop.conf.Configuration import org.apache.hadoop.fs.{ FileSystem, Path } import org.apache.hadoop.mapred.FileAlreadyExistsException import...
hammerlab/guacamole
src/main/scala/org/hammerlab/guacamole/variants/GenotypeOutputArgs.scala
Scala
apache-2.0
5,173
package monocle import java.net.URI import java.util.UUID import org.scalacheck.Arbitrary._ import org.scalacheck.rng.Seed import org.scalacheck.{Arbitrary, Cogen, Gen} import org.scalactic.Equality import cats._ import cats.free.Cofree import cats.syntax.eq._ import scala.collection.immutable.ListMap trait TestIn...
aoiroaoino/Monocle
test/shared/src/test/scala/monocle/TestInstances.scala
Scala
mit
4,078
package pl.umk.bugclassification.scmparser.git.parsers import org.junit.runner.RunWith import org.scalatest.FunSuite import org.scalatest.junit.JUnitRunner @RunWith(classOf[JUnitRunner]) class CommitParserSuite extends FunSuite { test("parsing correct log") { val log = """commit b15d78fd348c963d5df649a98...
mfejzer/CommitClassification
src/test/scala/pl/umk/bugclassification/scmparser/git/parsers/CommitParserSuite.scala
Scala
bsd-3-clause
13,136
package poly.util.typeclass import poly.util.formatter._ import poly.util.typeclass.ops._ /** * @author Tongfei Chen (ctongfei@gmail.com). */ object TypeclassTest extends App { assert(3.str == "3") assert("ABCDE".str == "ABCDE") assert(1023.str(IntFormatter.radix(2)) == "1111111111") assert(4.deepCopy == ...
ctongfei/poly-util
src/test/scala/poly/util/typeclass/TypeclassTest.scala
Scala
mit
440
package ingraph.compiler.cypher2gplan import java.io.ByteArrayInputStream import ingraph.compiler.exceptions.CompilerException import org.apache.log4j.{Level, Logger} import org.eclipse.emf.common.util.URI import org.eclipse.emf.ecore.resource.Resource import org.eclipse.xtext.diagnostics.Severity import org.eclipse....
FTSRG/ingraph
compiler/src/main/scala/ingraph/compiler/cypher2gplan/CypherParser.scala
Scala
epl-1.0
2,456
/* * Copyright (C) 2009-2017 Lightbend Inc. <https://www.lightbend.com> */ package scalaguide.tests.specs2 // #scalatest-examplecontrollerspec import javax.inject.Inject import play.api.i18n.Messages import play.api.mvc._ import play.api.test._ import scala.concurrent.Future class ExampleControllerSpec extends Pl...
Shruti9520/playframework
documentation/manual/working/scalaGuide/main/tests/code/specs2/ExampleControllerSpec.scala
Scala
apache-2.0
3,121
/** * Copyright: Copyright (C) 2016, Jaguar Land Rover * License: MPL-2.0 */ package org.genivi.sota.core.rvi import java.util.UUID import akka.actor.{ActorRef, ActorSystem} import akka.event.Logging import akka.http.scaladsl.model.Uri import akka.http.scaladsl.server.Directives import akka.http.scaladsl.util.Fast...
PDXostc/rvi_sota_server
core/src/main/scala/org/genivi/sota/core/rvi/SotaServices.scala
Scala
mpl-2.0
5,308
/*********************************************************************** * 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-utils/src/main/scala/org/locationtech/geomesa/utils/io/fs/package.scala
Scala
apache-2.0
3,451
package ha.library.math object arithmetic { def gcd(a: BigInt, b: BigInt): BigInt = if (b == 0) a else gcd(b, a % b) def gcd(nums: Iterable[BigInt]): BigInt = nums.reduce(gcd) def lcm(a: BigInt, b: BigInt): BigInt = if (a == 0 || b == 0) 0 else a * b / gcd(a, b) def lcm(nums: Iterable[BigInt]): BigInt = num...
jjcipher/hackerarena
library/src/main/scala/ha/library/math/arithmetic.scala
Scala
apache-2.0
2,985
package ua.org.yozh import org.slf4j.LoggerFactory import org.tmatesoft.svn.core.internal.io.dav.DAVRepositoryFactory import org.tmatesoft.svn.core.internal.io.svn.SVNRepositoryFactoryImpl import org.tmatesoft.svn.core.io.SVNRepositoryFactory import org.tmatesoft.svn.core.{SVNLogEntryPath, SVNLogEntry, SVNNodeKind, SV...
artem-karpenko/svn-search
svn-indexer/src/main/scala/ua/org/yozh/LogHistoryTraversal.scala
Scala
gpl-2.0
2,172
package io.github.lucapinouk.trturtle object Hoover { /* Creates a new Hoover in the given position, and starts it up so it cleans on the spot */ def initialPosition(position: (Int, Int), dirtSpots: Set[(Int, Int)]) = HooverImpl(position, 0).cleanSpot(dirtSpots) } /* The Hoover keeps track of the hoover...
lucapinouk/teenage-roomba-turtle
src/main/scala/io/github/lucapinouk/trturtle/Hoover.scala
Scala
mit
1,187
/** * Copyright (C) 2016 Miguel Osorio. All rights reserved. */ package models import java.util.UUID import play.api.libs.json.Json /** * Object used to store links to object translations. * * @param language: Translation language. * @param id: The id of the object. */ case class Translation (language:...
migue48/bbg-vintage-racing
app/models/Translation.scala
Scala
apache-2.0
416
package TAPLcomp2.recon import scala.util.parsing.combinator.{ImplicitConversions, PackratParsers} import scala.util.parsing.combinator.syntactical.StandardTokenParsers sealed trait Ty case class TyVar(id: String) extends Ty case class TyArr(t1: Ty, t2: Ty) extends Ty case object TyBool extends Ty case object TyN...
hy-zhang/parser
Scala/Parser/src/TAPLcomp2/recon/parser.scala
Scala
bsd-3-clause
2,999
/* * Copyright 2014 Twitter 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 l...
tresata/storehaus
storehaus-core/src/main/scala/com/twitter/storehaus/FutureOps.scala
Scala
apache-2.0
4,520
/* * Copyright (c) 2014-2018 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...
Wogan/monix
monix-reactive/shared/src/main/scala/monix/reactive/internal/operators/DownstreamTimeoutObservable.scala
Scala
apache-2.0
4,746
package lila.bot import scala.concurrent.duration._ import lila.common.Bus import lila.hub.actorApi.socket.ApiUserIsOnline import lila.memo.ExpireCallbackMemo import lila.socket.IsOnline final class OnlineApiUsers( isOnline: IsOnline, scheduler: akka.actor.Scheduler )(implicit ec: scala.concurrent.ExecutionC...
luanlv/lila
modules/bot/src/main/OnlineApiUsers.scala
Scala
mit
1,054
package at.logic.gapt.expr package object schema { type SchemaExpression = LambdaExpression type IntegerTerm = LambdaExpression type IntConst = Const type SchemaFormula = HOLFormula type fo2Var = Var type IntVar = Var }
loewenheim/gapt
src/main/scala/at/logic/gapt/expr/schema/package.scala
Scala
gpl-3.0
234
package client.handler import diode.{ActionHandler, ActionResult, ModelRW} import shared.models.ConnectionsModel import client.rootmodel.ConnectionsRootModel import shared.dtos._ // Actions //scalastyle:off case class UpdateConnections(newConnectionModel: Seq[ConnectionsModel]) class ConnectionHandler[M](modelRW: M...
LivelyGig/ProductWebUI
client/src/main/scala/client/handler/ConnectionHandler.scala
Scala
apache-2.0
886
/* * 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 ...
yanboliang/spark
core/src/main/scala/org/apache/spark/deploy/SparkSubmitArguments.scala
Scala
apache-2.0
25,519
package excavators.odesk.db import java.sql.Timestamp import java.util.Date import util.logging.LoggerDBProvider import util.db.DBProvider import util.parameters.ParametersMap import util.structures._ import scala.slick.driver.H2Driver.simple._ import scala.slick.jdbc.StaticQuery /** * Provide DB access for oDesk exc...
AlexCAB/FreelanceAnalytics
src/excavators/odesk/db/ODeskExcavatorsDBProvider.scala
Scala
mit
23,137
/* * * * Copyright 2015 Skymind,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 * * * * U...
Mageswaran1989/aja
src/main/scala/org/aja/dhira/src/main/scala/org/dhira/core/optimize/stepfunctions/StepFunctions.scala
Scala
apache-2.0
1,676
/* * 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...
bravo-zhang/spark
sql/core/src/main/scala/org/apache/spark/sql/execution/ColumnarBatchScan.scala
Scala
apache-2.0
6,955
package lab01 import common.las.Method import math._ case class SqRoot(L: Array[Array[Double]], r: Array[Double]) extends Method(L, r) { val d = Array.ofDim[Double](dim, dim) val s = Array.ofDim[Double](dim, dim) val std = Array.ofDim[Double](dim, dim) val y = Array.ofDim[Double](dim) def D = println(mat...
dnoskov/cm
src/main/scala/lab01/SqRoot.scala
Scala
mit
1,158
package scala.meta.intellij import com.intellij.openapi.project.Project import org.jetbrains.plugins.scala.lang.psi.api.expr.ScAnnotation import scala.meta.trees.TreeConverter class IDEAContext(project: =>Project) extends TreeConverter { override def getCurrentProject: Project = project // annotations filterin...
jastice/intellij-scala
scala/scala-impl/src/scala/meta/intellij/IDEAContext.scala
Scala
apache-2.0
421
//:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: /** @author John Miller * @builder scalation.util.bld.BldMM_Array * @version 1.2 * @date Thu Sep 24 14:03:17 EDT 2015 * @see LICENSE (MIT style license file). * * @see www.programering.com/a/MDO2cjNwATI.html */ packa...
mvnural/scalation
src/main/scala/scalation/util/MM_ArrayD.scala
Scala
mit
7,276
/* Scala.js compiler * Copyright 2013 LAMP/EPFL * @author Tobias Schlatter */ package scala.scalajs.compiler import scala.annotation.tailrec /** * Prepare export generation * * Helpers for transformation of @JSExport annotations */ trait PrepJSExports { this: PrepJSInterop => import global._ import js...
swhgoon/scala-js
compiler/src/main/scala/scala/scalajs/compiler/PrepJSExports.scala
Scala
bsd-3-clause
6,857
/* * Copyright (c) 2012-2017 by its authors. Some rights reserved. * See the project homepage at: https://github.com/monix/shade * * Licensed under the MIT License (the "License"); you may not use this * file except in compliance with the License. You may obtain a copy * of the License at: * * https://github.co...
zaneli/shade
src/test/scala/shade/testModels/Session.scala
Scala
mit
698
package org.danielnixon.progressive import org.scalajs.dom.window import org.danielnixon.progressive.shared.Wart import scala.collection.immutable.Seq import scala.scalajs.js /** * Entry point for Progressive. */ class Progressive { /** * Initialize Progressive. Call this once per page load. * @param ...
danielnixon/progressive
client/src/main/scala/org/danielnixon/progressive/Progressive.scala
Scala
gpl-3.0
859
package org.jetbrains.plugins.scala.lang.resolve2 /** * Pavel.Fatin, 02.02.2010 */ class ElementClashTest extends ResolveTestBase { override def folderPath: String = { super.folderPath + "element/clash/" } //TODO classes clash // def testClass = doTest //TODO classes clash // def testCaseClass = doT...
ilinum/intellij-scala
test/org/jetbrains/plugins/scala/lang/resolve2/ElementClashTest.scala
Scala
apache-2.0
1,270
package glint.models.server import breeze.linalg.{DenseMatrix, Matrix} import glint.messages.server.request.{PullMatrix, PullMatrixRows, PushMatrixFloat} import glint.messages.server.response.{ResponseFloat, ResponseRowsFloat} import glint.partitioning.Partition import spire.implicits._ /** * A partial matrix holdi...
rjagerman/glint
src/main/scala/glint/models/server/PartialMatrixFloat.scala
Scala
mit
1,098
package com.twitter.finatra.json.internal.caseclass.validation.validators import com.twitter.finatra.json.internal.caseclass.validation.validators.NotEmptyValidator._ import com.twitter.finatra.validation.{ErrorCode, NotEmpty, ValidationMessageResolver, ValidationResult, Validator} private[finatra] object NotEmptyVal...
syamantm/finatra
jackson/src/main/scala/com/twitter/finatra/json/internal/caseclass/validation/validators/NotEmptyValidator.scala
Scala
apache-2.0
1,502
/* * 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-native-sql/core/src/main/scala/org/apache/spark/sql/execution/adaptive/QueryStageExec.scala
Scala
apache-2.0
8,984
package com.mtraina.ps object Chapter12 { /** * Traits * they can't be instantiated but a class can extend any of them */ trait Philosophical { def philosophize() = { println("I consume memory, therefore I am!") } } class Frog extends Philosophical { override def toString = "gre...
mtraina/programming-in-scala
src/main/scala/com/mtraina/ps/Chapter12.scala
Scala
mit
3,794
package com.rouesnel.typedsql.examples import com.rouesnel.typedsql.DataSource.Strategy._ import com.rouesnel.typedsql._, core._ import com.twitter.scalding._ import org.apache.commons.configuration.Configuration import org.apache.hadoop.hive.conf.HiveConf import org.slf4j.LoggerFactory @SqlQuery object ComplexExamp...
laurencer/typedsql
examples/src/main/scala/com/rouesnel/typedsql/examples/ComplexExample.scala
Scala
apache-2.0
2,236
package ipfix.ie sealed trait Semantics case object Default extends Semantics case object Quantity extends Semantics case object TotalCounter extends Semantics case object DeltaCounter extends Semantics case object Identifier extends Semantics case object Flags extends Semantics case object NoSemantics extends Semanti...
ConnorDillon/ipfix
src/main/scala/ipfix/ie/Semantics.scala
Scala
gpl-3.0
322
import scala.reflect.internal.pickling.ByteCodecs._ object Test { def test8to7(xs: Array[Byte]) { val ys = encode8to7(xs) decode7to8(ys, ys.length) assert(ys.take(xs.length).deep == xs.deep, "test8to7("+xs.deep+") failed, result = "+ys.take(xs.length).deep) } def testAll(xs: Array[Byte])...
felixmulder/scala
test/files/run/bytecodecs.scala
Scala
bsd-3-clause
952
import sbt._ import Keys._ object Root extends Build { lazy val root = Project( id = "root", base = file("."), aggregate = Seq(polarity, twitter_cruncher) ) lazy val polarity = Project( id = "polarity", base = file("polarity") ) lazy val twitter_cruncher = Project( id = "twitter_cr...
AustinBGibbons/emoticat
project/Build.scala
Scala
bsd-3-clause
465
// - Project: angulate2 (https://github.com/jokade/angulate2) // Description: sbt plugin for angulate2 // // Distributed under the MIT License (see included file LICENSE) // Copyright (c) 2016 Johannes.Kastner <jokade@karchedon.de> // Distributed under the MIT License (see included LICENSE file) packag...
jokade/angulate2
plugin/src/main/scala/de/surfice/angulate2/sbtplugin/Angulate2Plugin.scala
Scala
mit
5,008
package com.twitter.finagle.exception import com.fasterxml.jackson.databind.ObjectMapper import com.fasterxml.jackson.module.scala.DefaultScalaModule import com.twitter.util.Time private object JsonGenerator { private[this] val writer = { val mapper = new ObjectMapper mapper.registerModule(DefaultScalaModul...
travisbrown/finagle
finagle-exception/src/main/scala/com/twitter/finagle/exception/ServiceException.scala
Scala
apache-2.0
2,691
/* * Copyright 2016 Heiko Seeberger * * 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...
strobe/sbt-fresh
src/main/scala/de/heikoseeberger/sbtfresh/Template.scala
Scala
apache-2.0
10,340
import org.scalacheck.Prop.forAll import org.scalacheck.Properties object NumericSupportSpecification extends Properties("NumericSupport") { import NumbersDomain._ import pl.iterators.kebs.support._ property("sum of List[TaggedBigDecimal]") = forAll { (bigDecimalList: List[BigDecimal]) => bigDecimalList.ma...
theiterators/kebs
macro-utils/src/test/scala/NumericSupportSpecification.scala
Scala
mit
576
/** * 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...
kavink92/kafka-0.8.0-beta1-src
core/src/main/scala/kafka/server/AbstractFetcherThread.scala
Scala
apache-2.0
10,411
/* * 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 ...
ytchen0323/cloud-scale-bwamem
src/main/scala/cs/ucla/edu/bwaspark/commandline/BWAMEMCommand.scala
Scala
apache-2.0
3,639
package org.openurp.edu.eams.teach.election.web.action.constraint import java.util.Date import org.apache.commons.collections.CollectionUtils import org.apache.commons.collections.ListUtils import org.apache.commons.collections.MapUtils import org.apache.commons.lang3.ArrayUtils import org.beangle.commons.collection....
openurp/edu-eams-webapp
election/src/main/scala/org/openurp/edu/eams/teach/election/web/action/constraint/StdCourseCountConstraintAction.scala
Scala
gpl-3.0
21,293
package io.github.jamespic.ethereum_tools.decompiler.control_flow import scala.collection.immutable.SortedSet import scala.util.control.NoStackTrace object Func { case class FuncEntry(address: Int, inputs: Int, outputs: Int) { override def toString = f"FuncEntry($address%x, $inputs%d, $outputs%d" def effect...
jamespic/ethereum-tools
src/main/scala/io.github.jamespic.ethereum_tools/decompiler/control_flow/Func.scala
Scala
mit
11,531
package ru.yandex.mysqlDiff package script import model._ import Implicits._ class Script(val stmts: Seq[ScriptElement]) { def statements = stmts.flatMap { case s: ScriptStatement => Some(s) case _ => None } def ddlStatements = statements.flatMap { case s: DdlStatement => Som...
hkerem/mysql-diff
src/main/scala/ru/yandex/mysqlDiff/script/script.scala
Scala
bsd-3-clause
9,592
class A { self : B => val y = f } trait B(x: Int) { // error def f: Int = x } class C extends A with B(20)
som-snytt/dotty
tests/init/neg/override20.scala
Scala
apache-2.0
115
package scorex.network import akka.pattern.{ask, pipe} import akka.util.Timeout import scorex.app.Application import scorex.block.Block import scorex.block.Block.BlockId import scorex.consensus.mining.BlockGeneratorController.{LastBlockChanged, StartGeneration} import scorex.crypto.EllipticCurveImpl import scorex.cryp...
B83YPoj/Waves
src/main/scala/scorex/network/Coordinator.scala
Scala
apache-2.0
11,267
/* * The Bluejelly project, Copyright 2012. * * This source code is distributed under the terms of * the BSD license, see the LICENSE file for details. */ package bluejelly.bjc.common import scala.text.{DocGroup,DocNil} import scala.text.Document import scala.text.Document.{_} import java.io.StringWriter import ...
ppedemon/Bluejelly
bluejelly-bjc/src/main/scala/bluejelly/bjc/common/PrettyPrintable.scala
Scala
bsd-3-clause
3,040
/* * Copyright 2014 Treode, 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...
Treode/store
cluster/src/com/treode/cluster/ClusterPicklers.scala
Scala
apache-2.0
890
package sbt import Load._ import Project._ import Scoped._ import Keys._ import Configurations.Runtime import java.io.File import org.apache.ivy.core.module.{descriptor, id} import descriptor.ModuleDescriptor, id.ModuleRevisionId object GlobalPlugin { // constructs a sequence of settings that may be appende...
kuochaoyi/xsbt
main/GlobalPlugin.scala
Scala
bsd-3-clause
3,267
package xitrum.local import xitrum.{Cache, Config} import xitrum.util.LocalLruCache /** * Config in xitrum.conf: * * {{{ * xitrum { * cache { * "xitrum.local.LruCache" { * maxElems = 10000 * } * } * } * }}} */ class LruCache extends Cache { private[this] val cache = { val className...
xitrum-framework/xitrum
src/main/scala/xitrum/local/LruCache.scala
Scala
mit
2,227
package net.spals.appbuilder.app.finatra.modules import java.util.concurrent.atomic.AtomicReference import com.google.inject.matcher.Matchers.subclassesOf import com.google.inject.spi.ProvisionListener import com.twitter.finatra.http.routing.HttpRouter import com.twitter.inject.TwitterModule import io.opentracing.Tra...
spals/appbuilder
app-finatra/src/main/scala/net/spals/appbuilder/app/finatra/modules/FinatraMonitorModule.scala
Scala
bsd-3-clause
1,404
/* * 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/ml/util/ReadWrite.scala
Scala
apache-2.0
23,731
/** * Copyright 2009 Jorge Ortiz * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to i...
jorgeortiz85/scala-javautils
src/main/scala/org/scala_tools/javautils/j2s/JMapWrapper.scala
Scala
apache-2.0
1,084
/* * Copyright (C) 2014 - 2019 Dennis Vriend <https://github.com/dnvriend> * Copyright (C) 2019 - 2021 Lightbend Inc. <https://www.lightbend.com> */ package akka.persistence.jdbc.state.scaladsl import scala.concurrent.{ ExecutionContext, Future } import scala.concurrent.duration._ import scala.util.Try import sli...
dnvriend/akka-persistence-jdbc
core/src/main/scala/akka/persistence/jdbc/state/scaladsl/JdbcDurableStateStore.scala
Scala
apache-2.0
8,365
package io.cloudslang.content.google.actions.compute.compute_engine.instances import java.util import com.hp.oo.sdk.content.annotations.{Action, Output, Param, Response} import com.hp.oo.sdk.content.plugin.ActionMetadata.{MatchType, ResponseType} import io.cloudslang.content.constants.OutputNames.{EXCEPTION, RETURN_C...
victorursan/cs-actions
cs-google/src/main/scala/io/cloudslang/content/google/actions/compute/compute_engine/instances/InstancesDetachDisk.scala
Scala
apache-2.0
5,483
import scala.quoted._ class Test { def f[T](t: Type[T], x: Expr[T])(using QuoteContext) = '{ val z2 = $x // error // error: wrong staging level } def g[T](implicit t: Type[T], x: Expr[T], qctx: QuoteContext) = '{ val z2 = $x // ok } }
som-snytt/dotty
tests/neg/quote-1.scala
Scala
apache-2.0
257
/* * Copyright 2001-2009 Stephen Colebourne * * 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...
aparo/scalajs-joda
src/main/scala/org/joda/time/format/ISODateTimeFormat.scala
Scala
apache-2.0
60,768
/* * 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 ...
brad-kaiser/spark
sql/core/src/test/scala/org/apache/spark/sql/SQLQueryTestSuite.scala
Scala
apache-2.0
11,907
/** * 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...
brunobuzzi/orbeon-forms
xforms/jvm/src/main/scala/org/orbeon/oxf/xforms/action/actions/XFormsRefreshAction.scala
Scala
lgpl-2.1
2,000
/* * 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/ScalaReflectionSuite.scala
Scala
apache-2.0
21,181
package com.neilconcepts.battlespace.domain import com.neilconcepts.battlespace.domain.Board.BattleSpaceBoard import org.scalatest._ class BoardSpec extends WordSpec with Matchers { val mx = Board.maxDimensions var gb: Option[BattleSpaceBoard] = None "A Board" when { "Generating a board" should { s"c...
bneil/battlespace
src/test/scala/com/neilconcepts/battlespace/domain/BoardSpec.scala
Scala
mit
515
/* * 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-charts/src/main/scala/io/gatling/charts/report/Container.scala
Scala
apache-2.0
2,352
package com.esri.gdb import java.nio.ByteBuffer import org.apache.spark.sql.types.{FloatType, Metadata} /** */ class FieldFloat32(name: String, nullValueAllowed: Boolean, metadata: Metadata) extends Field(name, FloatType, nullValueAllowed, metadata) { override def readValue(byteBuffer: ByteBuffer, oid: Int) =...
mraad/spark-gdb
src/main/scala/com/esri/gdb/FieldFloat32.scala
Scala
apache-2.0
353
/** * Copyright (C) 2014 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...
brunobuzzi/orbeon-forms
src/main/scala/org/orbeon/oxf/xml/JXQName.scala
Scala
lgpl-2.1
1,241
package controllers import play.api.http.ContentTypes import scala.util.chaining._ import views._ import lila.api.Context import lila.app._ import lila.game.Pov final class Tv( env: Env, apiC: => Api, gameC: => Game ) extends LilaController(env) { def index = onChannel(lila.tv.Tv.Channel.Best.key) ...
luanlv/lila
app/controllers/Tv.scala
Scala
mit
4,347
package extracells.integration.mekanism import appeng.api.config.Actionable import appeng.api.networking.security.IActionSource import appeng.api.storage.data.{IAEFluidStack, IItemList} import appeng.api.storage.IMEInventory import extracells.api.IExternalGasStorageHandler import extracells.api.gas.IAEGasStack import ...
ExtraCells/ExtraCells2
src/main/scala/extracells/integration/mekanism/HandlerMekanismGasTank.scala
Scala
mit
2,619
package org.json4s import org.scalatest.wordspec.AnyWordSpec import org.scalatestplus.scalacheck.Checkers class JsonDSLSpec extends AnyWordSpec with JValueGen with Checkers { "JSON DSL Specification" should { "build Json" in { import JsonDSL._ check { (intValue: Int, strValue: String) => ((...
json4s/json4s
ast/shared/src/test/scala/org/json4s/JsonDSLSpec.scala
Scala
apache-2.0
1,791
package akka.contrib.persistence.mongodb class RxMongoPersistentFsmSpec extends PersistentFsmSpec(classOf[RxMongoPersistenceExtension], "rxmongo-fsm")
scullxbones/akka-persistence-mongo
rxmongo/src/test/scala/akka/contrib/persistence/mongodb/RxMongoPersistentFsmSpec.scala
Scala
apache-2.0
152
/* * 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...
yiheng/BigDL
spark/dl/src/test/scala/com/intel/analytics/bigdl/nn/SqueezeSpec.scala
Scala
apache-2.0
1,171
/* * 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 ...
VigneshMohan1/spark-branch-2.3
project/SparkBuild.scala
Scala
apache-2.0
32,427
package com.github.pedrovgs.kuronometer import cats.Eval import cats.implicits._ import cats.free.Free import com.github.pedrovgs.kuronometer.KuronometerResults.{ ConnectionError, KuronometerResult, UnknownError } import com.github.pedrovgs.kuronometer.free.algebra.{ReporterOps, ViewOps} import com.github.pedrov...
pedrovgs/Kuronometer
kuronometer-core/src/main/scala/com/github/pedrovgs/kuronometer/Kuronometer.scala
Scala
apache-2.0
4,302
package pl.newicom.dddd.test.support import com.typesafe.config.{Config, ConfigFactory} import akka.actor.ActorSystem object TestConfig { val config = ConfigFactory.parseString( """akka.loglevel = DEBUG |akka.loggers = ["akka.event.slf4j.Slf4jLogger"] |akka.logging-filter = "akka.event.slf4j.Slf4jLo...
odd/akka-ddd
akka-ddd-test/src/main/scala/pl/newicom/dddd/test/support/TestConfig.scala
Scala
mit
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 ...
techaddict/spark
external/kafka-0-10-sql/src/test/scala/org/apache/spark/sql/kafka010/KafkaRelationSuite.scala
Scala
apache-2.0
15,548
/* * Copyright 2017 PayPal * * 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 ...
az-qbradley/squbs
squbs-pattern/src/test/scala/org/squbs/pattern/orchestration/OrchestratorSpec.scala
Scala
apache-2.0
26,707
package slate package util import cats.{Monoid, ~>} import fastparse.all.Parsed import japgolly.scalajs.react.extra.Reusability import japgolly.scalajs.react.vdom.TagMod import japgolly.scalajs.react.CallbackTo import monix.eval.Task import monix.execution.{CancelableFuture, Scheduler} import monix.reactive.Observable...
edmundnoble/dashboarder
ui/src/main/scala/slate/util/Util.scala
Scala
mit
2,193
/* * 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 ...
esi-mineset/spark
sql/hive/src/main/scala/org/apache/spark/sql/hive/execution/ScriptTransformationExec.scala
Scala
apache-2.0
16,492
package com.shocktrade.server.dao.securities import com.shocktrade.common.models.contest.OrderLike import io.scalajs.npm.mongodb._ import scala.concurrent.{ExecutionContext, Future} import scala.scalajs.js /** * Securities Snapshot DAO * @author Lawrence Daniels <lawrence.daniels@gmail.com> */ @js.native trait...
ldaniels528/shocktrade.js
app/server/dao/src/main/scala/com/shocktrade/server/dao/securities/SecuritiesSnapshotDAO.scala
Scala
apache-2.0
1,979
/* * 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 ...
BryanCutler/spark
sql/core/src/test/scala/org/apache/spark/sql/DatasetSuite.scala
Scala
apache-2.0
75,158
/* * 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 ...
witgo/spark
core/src/main/scala/org/apache/spark/storage/BlockManagerDecommissioner.scala
Scala
apache-2.0
18,489
package com.wavesplatform.transaction trait VersionedTransaction { def version: TxVersion }
wavesplatform/Waves
node/src/main/scala/com/wavesplatform/transaction/VersionedTransaction.scala
Scala
mit
95
package de.tokamak.easy.csv import scala.io.Source class CSV(path: String, delimiter: String) { private lazy val lines = Source.fromFile(path).getLines() lazy val rows = lines.map(_.split(delimiter).toList).toList lazy val columns = CSV.transpose(rows) lazy val mapping = map private def map: Map[String, L...
tGrottker/easyCSV
src/main/scala/de/tokamak/easy/csv/CSV.scala
Scala
mit
828
/* * 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...
jjlopezm/crossdata
core/src/main/scala/com/stratio/crossdata/connector/interfaces.scala
Scala
apache-2.0
4,820
/* * 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...
qiuxin2012/BigDL
spark/dl/src/test/scala/com/intel/analytics/bigdl/utils/tf/loaders/Conv3DBackpropInputV2Spec.scala
Scala
apache-2.0
2,692
/* * Copyright (C) 2014 - 2019 Dennis Vriend <https://github.com/dnvriend> * Copyright (C) 2019 - 2021 Lightbend Inc. <https://www.lightbend.com> */ package akka.persistence.jdbc package query import akka.actor.{ Actor, ActorLogging, Props, Status, Timers } import akka.pattern.pipe import akka.persistence.jdbc.con...
dnvriend/akka-persistence-jdbc
core/src/main/scala/akka/persistence/jdbc/query/JournalSequenceActor.scala
Scala
apache-2.0
7,953
/* * 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
monifu/shared/src/test/scala/monifu/reactive/internals/builders/FromFutureSuite.scala
Scala
apache-2.0
3,524
package api import akka.actor.{Actor, ActorLogging, ActorRef, Props} import com.softwaremill.macwire.tagging.@@ import core.UserActor.{GetUserResult, GetUsersResult} import core.UserTag import core.model.{OperationError, OperationSuccess, ServiceInternalError, UserCreated} import spray.http.HttpHeaders.Location import...
DamianJureczko/user-service
src/main/scala/api/UserRequestActor.scala
Scala
apache-2.0
1,830
package com.shocktrade.client import com.shocktrade.client.discover.QuoteService import com.shocktrade.common.models.quote.CompleteQuote import io.scalajs.dom.html.browser.console import io.scalajs.npm.angularjs.AngularJsHelper._ import io.scalajs.npm.angularjs._ import io.scalajs.util.DurationHelper._ import io.scala...
ldaniels528/shocktrade.js
app/client/angularjs/src/main/scala/com/shocktrade/client/QuoteCache.scala
Scala
apache-2.0
2,607
package com.evojam.mongodb.client.model.result import scala.collection.JavaConversions._ import scala.language.implicitConversions import com.mongodb.bulk.{BulkWriteResult => MongoBulkWriteResult} import com.mongodb.client.result.{UpdateResult => MongoUpdateResult} import org.bson.codecs.Codec import com.evojam.mong...
evojam/mongodb-driver-scala
src/main/scala/com/evojam/mongodb/client/model/result/UpdateResult.scala
Scala
apache-2.0
2,079