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 com.github.golem.test.model import com.github.golem.test.GolemUnitSpec import com.github.golem.model._ import com.github.golem.model.Board._ import com.github.golem.model.Engine import com.github.golem.model.Put import com.github.golem.model.Board.Coords import com.github.golem.model.Board.Stone import com.git...
pjarosik/golem
src/test/scala/com/github/golem/test/model/basic_rules_game_get_endangered_stones.scala
Scala
gpl-2.0
1,634
package net.hotelling.harold.audiowidget import java.awt._ import javax.swing._ /** * Use Swing to display a graph in a window. */ class GraphWindow(val mixerNames: Array[String]) { @volatile var oscilloscope: Option[Graph] = None @volatile var intensity: Option[Graph] = None @volatile var zScore...
haroldl/audiowidget
src/main/scala/net/hotelling/harold/audiowidget/GraphWindow.scala
Scala
apache-2.0
4,463
package edu.gemini.pit.ui.robot import scalaz.Lens import edu.gemini.gsa.client.api.{GsaResult, GsaParams} import edu.gemini.gsa.client.impl.GsaClientImpl import edu.gemini.model.p1.immutable.{ObservationMeta, Observation} object GsaRobot extends ObservationMetaRobot[GsaParams, Int] { protected val valueLens: Lens...
spakzad/ocs
bundle/edu.gemini.pit/src/main/scala/edu/gemini/pit/ui/robot/GsaRobot.scala
Scala
bsd-3-clause
728
package spire.macros import spire.macros.compat.{termName, freshTermName, resetLocalAttrs, Context, setOrig} import scala.language.higherKinds object Ops extends machinist.Ops { def uesc(c: Char): String = "$u%04X".format(c.toInt) val operatorNames: Map[String, String] = machinist.DefaultOps.operatorNames ...
kevinmeredith/spire
macros/src/main/scala/spire/macros/Syntax.scala
Scala
mit
7,955
/* * 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 ...
apache/zeppelin
spark/scala-2.11/src/main/scala/org/apache/zeppelin/spark/SparkScala211Interpreter.scala
Scala
apache-2.0
7,464
/* * 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/help-to-save-frontend
test/uk/gov/hmrc/helptosavefrontend/models/TestData.scala
Scala
apache-2.0
4,843
package agilesitesng.deploy.model import agilesitesng.deploy.model.SpoonModel.DeployObjects /** * A spooler class to collect object and serialize them in priority order * * @param map */ case class Spooler(val map: Map[String, List[SpoonModel]] = Map.empty) { def push(i: Int, obj: SpoonModel) = { val pri =...
agilesites/agilesites2-build
src/main/scala/agilesitesng/deploy/model/Spooler.scala
Scala
mit
1,507
package views.html package account import lila.api.Context import lila.app.templating.Environment._ import lila.app.ui.ScalatagsTemplate._ import controllers.routes object email { def apply(form: play.api.data.Form[_])(implicit ctx: Context) = account.layout( title = trans.changeEmail.txt(), activ...
luanlv/lila
app/views/account/email.scala
Scala
mit
761
/*********************************************************************** * 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-kafka/geomesa-kafka-datastore/geomesa-kafka-09-datastore/src/test/scala/org/locationtech/geomesa/kafka09/MockKafka.scala
Scala
apache-2.0
10,454
/* * 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/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis/AnsiTypeCoercion.scala
Scala
apache-2.0
12,719
package io.buoyant.router import com.twitter.finagle.client.StackClient import com.twitter.finagle.http.{HeaderMap, Request, Response, TlsFilter} import com.twitter.finagle.http.service.HttpResponseClassifier import com.twitter.finagle.param.{ProtocolLibrary, ResponseClassifier} import com.twitter.finagle.server.Stack...
linkerd/linkerd
router/http/src/main/scala/io/buoyant/router/Http.scala
Scala
apache-2.0
4,208
package calculator sealed abstract class Expr final case class Literal(v: Double) extends Expr final case class Ref(name: String) extends Expr final case class Plus(a: Expr, b: Expr) extends Expr final case class Minus(a: Expr, b: Expr) extends Expr final case class Times(a: Expr, b: Expr) extends Expr final case clas...
thiagosqr/coursera-reactive
calculator/src/main/scala/calculator/Calculator.scala
Scala
apache-2.0
1,188
/******************************************************************************* * Copyright (c) 2019. Carl Minden * * 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 ...
carlminden/anathema-roguelike
src/com/anathema_roguelike/entities/characters/player/perks/abilities/techniques/Technique.scala
Scala
gpl-3.0
1,237
package arqbrowser.lib import java.io.DataInput import java.io.IOException class ArqTree(val children: List[Tuple2[String, ArqTreeNode]]) { } object ArqTree { private def readNameAndNode(stream: DataInput): Tuple2[String, ArqTreeNode] = { val name = Utils.readStringWithIsNotNullHeader(stream); val node = A...
pauldoo/scratch
ArqBrowser/src/arqbrowser/lib/ArqTree.scala
Scala
isc
2,239
object B { val x: Int = A.m }
dotty-staging/dotty
sbt-test/source-dependencies/struct-projection/B.scala
Scala
apache-2.0
32
// AORTA is copyright (C) 2012 Dustin Carlino, Mike Depinet, and Piyush // Khandelwal of UT Austin // License: GNU GPL v2 package utexas.aorta.map.make import scala.collection.mutable import utexas.aorta.map.Coordinate import utexas.aorta.common.Util class Pass1(fn: String, whitelist_ways: Option[Set[String]]) { ...
dabreegster/aorta
utexas/aorta/map/make/Pass1.scala
Scala
gpl-2.0
5,709
package extruder.system import extruder.map.MapDataSource package object systemproperties extends SystemPropertiesEncoder with SystemPropertiesDecoder with MapDataSource with SystemPropertiesDecoderInstances with SystemPropertiesEncoderInstances { object decoder extends SystemPropertiesDecoder wi...
janstenpickle/extruder
system-sources/src/main/scala/extruder/system/systemproperties/package.scala
Scala
mit
505
/* * Copyright 2014–2018 SlamData Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agr...
jedesah/Quasar
frontend/src/test/scala/quasar/matchers.scala
Scala
apache-2.0
1,382
package alternating import util.CCPropertiesImmutable import org.apache.spark.SparkContext._ import org.apache.spark.SparkContext import org.apache.spark.rdd.RDD import util.CCUtil import cracker.CrackerStats @serializable class AlternatingStats(property : CCPropertiesImmutable, util : CCUtil, spark : SparkContext) {...
hpclab/cracker
src/alternating/AlternatingStats.scala
Scala
mit
1,395
package us.newsrdr.servlet import org.scalatra._ import scalate.ScalateSupport import us.newsrdr.models._ import us.newsrdr.tasks._ import slick.jdbc.JdbcBackend.{Database, Session} // JSON-related libraries import org.json4s.{DefaultFormats, Formats} // JSON-related libraries import org.json4s.{DefaultFormats, For...
tmiw/newsrdr
src/main/scala/us/newsrdr/servlet/PostServlet.scala
Scala
bsd-3-clause
8,064
package de.tototec.cmvn import org.scalatest.FreeSpec import de.tobiasroeser.lambdatest.TempFile._ import de.tobiasroeser.lambdatest.FunctionWithException import java.io.File import org.scalatest.Matchers import de.tototec.cmvn.configfile.bndlike.ConfigFileReaderImpl import scala.collection.JavaConverters._ class Pro...
ToToTec/cmvn
de.tototec.cmvn/src/test/scala/de/tototec/cmvn/ProjectReaderTest.scala
Scala
apache-2.0
1,883
package com.julianpeeters.avro.annotations package provider import org.apache.avro.Schema import org.apache.avro.Schema.Type.{ARRAY, ENUM, RECORD, UNION} import scala.collection.JavaConverters._ object NestedSchemaExtractor { // if a record is found, extract nested RECORDs and ENUMS (i.e. top-level types) def ge...
iulianu/avro-scala-macro-annotations
macros/src/main/scala/avro/scala/macro/annotations/provider/NestedSchemaExtractor.scala
Scala
apache-2.0
1,434
/* Copyright (c) 2016, Rice University Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. 2....
agrippa/spark-swat
swat/src/test/scala/org/apache/spark/rdd/cl/tests/ClassExternalFunctionTest.scala
Scala
bsd-3-clause
2,414
package org.http4s package parser import java.nio.CharBuffer import scala.io.Codec class QueryParserSpec extends Http4sSpec { def parseQueryString(str: String): ParseResult[Query] = QueryParser.parseQueryString(str) "The QueryParser" should { "correctly extract complete key value pairs" in { pars...
ZizhengTai/http4s
tests/src/test/scala/org/http4s/parser/QueryParserSpec.scala
Scala
apache-2.0
2,978
/*********************************************************************** * 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-utils/src/main/scala/org/locationtech/geomesa/utils/geotools/NameableFeatureTypeFactory.scala
Scala
apache-2.0
2,757
package com.mbesida.dribble.rest import com.mbesida.dribble.model.DribbbleJsonProtocol import com.mbesida.dribble.service.DribbbleService import spray.http.MediaTypes import spray.httpx.SprayJsonSupport import spray.json._ import spray.routing.{HttpService, HttpServiceActor, Route} class DribbbleStatHttpServiceActor(...
mbesida/dribble-stats
src/main/scala/com/mbesida/dribble/rest/DribbbleStatHttpService.scala
Scala
apache-2.0
1,245
/* * Copyright (c) 2015. * Created by MrTJP. * All rights reserved. */ package mrtjp.core.fx.particles import com.mojang.blaze3d.vertex.IVertexBuilder import mrtjp.core.fx.ParticleAction import net.minecraft.client.particle.{IParticleRenderType, Particle} import net.minecraft.client.renderer.{ActiveRenderInfo, Buf...
MrTJP/MrTJPCore
src/main/scala/mrtjp/core/fx/particles/CoreParticle.scala
Scala
lgpl-3.0
2,068
/* * 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 ...
goldmedal/spark
sql/core/src/main/scala/org/apache/spark/sql/util/QueryExecutionListener.scala
Scala
apache-2.0
5,618
package jessitron import org.scalatest._ class NotTooRandom_UT extends FunSpec with ShouldMatchers { import NotTooRandom._ describe("An even distribution of fixed length") { it("Uses the two extremes as the first two") { val two = fixedLength(2).toList two should contain(1.0) two sh...
jessitron/NotTooRandom
src/test/scala/NotTooRandom_UT.scala
Scala
unlicense
2,212
/* * Copyright (c) 2013 Scott Abernethy. * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * This program is d...
scott-abernethy/opener-of-the-way
app/model/Cultist.scala
Scala
gpl-3.0
6,192
package org.tearne.crosser import org.tearne.crosser.plant.PlantFactory import org.tearne.crosser.plant.ChromosomeFactory import org.tearne.crosser.plant.Gameter import org.tearne.crosser.plant.ChromosomeCrosser import org.tearne.crosser.cross.Crosser import org.tearne.crosser.distribution.PlantEmpiricalFactory import...
tearne/Crosser
src/main/scala/org/tearne/crosser/Services.scala
Scala
apache-2.0
1,417
/* * Copyright (c) 2014-2021 by The Monix Project Developers. * See the project homepage at: https://monix.io * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache...
monifu/monix
monix-execution/shared/src/main/scala/monix/execution/cancelables/SingleAssignCancelable.scala
Scala
apache-2.0
4,548
package euler package til40 object Euler32 extends EulerProblem { override def result = { val prods = for (a <- Range(1, 100).view; b <- Range(1, 10000).view if a * b < 9876) yield (a * b, "" + a + b + (a * b)) prods.filter(x => x._2.length == 9 && !x._2.contains('0') && x._2.toSet.size == 9).map(_._1)...
TrustNoOne/Euler
scala/src/main/scala/euler/til40/Euler32.scala
Scala
mit
337
package org.jetbrains.plugins.scala package lang package psi package api package statements import com.intellij.psi.{PsiClass, PsiElement} import org.jetbrains.plugins.scala.lang.psi.api.base.types.ScTypeElement import org.jetbrains.plugins.scala.lang.psi.api.statements.params.ScTypeParam import org.jetbrains.plugins....
JetBrains/intellij-scala-historical
src/org/jetbrains/plugins/scala/lang/psi/api/statements/ScTypeAliasDefinition.scala
Scala
apache-2.0
3,868
/* * 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 ...
bravo-zhang/spark
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/util/ArrayData.scala
Scala
apache-2.0
5,592
package pl.touk.nussknacker.ui.security.dummy import com.typesafe.config.Config import pl.touk.nussknacker.ui.security.api.{AuthenticationProvider, AuthenticationResources, FrontendStrategySettings} import sttp.client.{NothingT, SttpBackend} import scala.concurrent.{ExecutionContext, Future} class DummyAuthenticatio...
TouK/nussknacker
security/src/main/scala/pl/touk/nussknacker/ui/security/dummy/DummyAuthenticationProvider.scala
Scala
apache-2.0
682
/** Copyright 2015 TappingStone, 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 ...
ydanilenko/PredictionIO
core/src/main/scala/io/prediction/core/BaseEvaluator.scala
Scala
apache-2.0
1,599
package ir.xamin.packet.reply import ir.xamin.Appliance import scala.xml._ import scala.collection.mutable.MutableList import org.jivesoftware.smack.packet.{Packet, IQ} class Search extends IQ { private var packages:MutableList[Appliance] = _ // set type of iq setType(IQ.Type.RESULT) /** setter for Applianc...
XaminProject/peace
src/main/scala/ir/xamin/packet/reply/Search.scala
Scala
mit
1,938
/* * ScalaCL - putting Scala on the GPU with JavaCL / OpenCL * http://scalacl.googlecode.com/ * * Copyright (c) 2009-2013, Olivier Chafik (http://ochafik.com/) * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following ...
nativelibs4java/Scalaxy
Components/src/main/scala/scalaxy/components/TreeBuilders.scala
Scala
bsd-3-clause
13,320
package io.eels.component.parquet import io.eels.Row import io.eels.schema.{DecimalType, Field, StructType} import org.apache.hadoop.conf.Configuration import org.apache.hadoop.fs.Path import org.scalatest.FunSuite import scala.math.BigDecimal.RoundingMode class DecimalWriterTest extends FunSuite { test("negative...
eel-lib/eel
eel-core/src/test/scala/io/eels/component/parquet/DecimalWriterTest.scala
Scala
mit
2,144
package com.example.domain import com.mongodb._ import org.bson.Document /** * Quick and ugly DAO implementation over Mongo */ abstract class BulletinMongoRepository extends AbstractRepository[Bulletin] { import BulletinMongoRepository._ val collectionPath: String val mongoClient: MongoClient override...
btrofimov/spark-enterprise-example
nonblocking-bulletinboard/bl-processor/src/main/scala/com/example/domain/BulletinMongoRepository.scala
Scala
apache-2.0
1,469
package mesosphere.marathon package api import javax.servlet.http.HttpServletRequest import javax.ws.rs.core.Response import mesosphere.UnitTest import mesosphere.marathon.plugin.auth.{ Authenticator, Authorizer, Identity } import mesosphere.marathon.plugin.http.{ HttpRequest, HttpResponse } import scala.concurrent....
natemurthy/marathon
src/test/scala/mesosphere/marathon/api/AuthResourceTest.scala
Scala
apache-2.0
2,261
package com.twitter.util.validation.internal.validators import com.twitter.util.validation.constraints.InvalidConstraint import jakarta.validation.{ConstraintValidator, ConstraintValidatorContext} import scala.util.control.NoStackTrace class InvalidConstraintValidator extends ConstraintValidator[InvalidConstraint, An...
twitter/util
util-validator/src/test/scala/com/twitter/util/validation/internal/validators/InvalidConstraintValidator.scala
Scala
apache-2.0
507
package fr.renoux.gaston.command import java.nio.file.Paths import org.scalatest.flatspec.AnyFlatSpec import org.scalatest.matchers.should.Matchers import scala.concurrent.duration._ class CommandLineTest extends AnyFlatSpec with Matchers { def parse(str: String*): CommandLine = CommandLine.parse(str) "--from...
gaelrenoux/gaston
src/test/scala/fr/renoux/gaston/command/CommandLineTest.scala
Scala
apache-2.0
837
import scala.quoted._ inline def old(inline x: Int): Int = ${ oldImpl(x) } // error private def oldImpl(x: Int): Expr[Int] = ??? inline def `new`(inline x: Int): Int = ${ newImpl('x) } private def newImpl(x: Expr[Int]): Expr[Int] = ???
som-snytt/dotty
tests/neg/old-inline-param-macro.scala
Scala
apache-2.0
246
package com.typesafe.sbt package packager package debian import Keys._ import sbt._ import sbt.Keys.{ mappings, target, name, mainClass, normalizedName } import linux.LinuxPackageMapping import linux.LinuxSymlink import linux.LinuxFileMetaData import com.typesafe.sbt.packager.Hashing import com.typesafe.sbt...
yanns/sbt-native-packager
src/main/scala/com/typesafe/sbt/packager/debian/DebianPlugin.scala
Scala
bsd-2-clause
8,751
/* * 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 ...
bravo-zhang/spark
sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/plans/JoinTypesTest.scala
Scala
apache-2.0
1,970
package io.grhodes.mcm.server.gcm trait GCMMessageStore { def shutdown(): Unit def storeMessage(regId: String, message: String): Boolean }
grahamar/mcm-server
src/main/scala/io/grhodes/mcm/server/gcm/GCMMessageStore.scala
Scala
mit
144
package scala.collection.mutable import scala.collection.{IterableFactory, IterableOnce} import scala.language.higherKinds /** Base trait for mutable sets */ trait Set[A] extends Iterable[A] with collection.Set[A] with SetOps[A, Set, Set[A]] { override def iterableFactory: IterableFactory[IterableCC] = S...
rorygraves/perf_tester
corpus/scala-library/src/main/scala/collection/mutable/Set.scala
Scala
apache-2.0
3,122
package models import fr.njin.playoauth.common.domain.OauthToken import org.joda.time.DateTime import play.api.libs.json._ import play.api.libs.functional.syntax._ import scalikejdbc._ import scalikejdbc.async._ import scala.concurrent.Future import scala.concurrent.duration.DurationInt import scala.language.postfixO...
njin-fr/play-oauth
play-oauth-server/app/models/AuthToken.scala
Scala
apache-2.0
5,751
package io.eels.component.hive import io.eels.Row import io.eels.schema.StructType /** * Will align a row with the given hive file schema. This means it will strip out of the row any fields/values * which are not in the given file schena, * If eel.hive.sink.pad-with-null is true, it will pad any fields missing ...
stheppi/eel
eel-hive/src/main/scala/io/eels/component/hive/RowNormalizerFn.scala
Scala
apache-2.0
1,691
package breakpoints import Helper._ class Breakpoints { def simple1() { var x = 0 while (x < 4) { noop(None) x += 1 noop(None) } x = 0 } def fors() { for (i <- 1 to 3) { noop(None) noop(None) } for (i <- 1 to 3) { noop(None) noop(None) ...
jacobono/ensime-server
testing/debug/src/main/scala/breakpoints/Breakpoints.scala
Scala
gpl-3.0
584
/* * Copyright (c) 1995, 2008, Oracle and/or its affiliates. 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 * no...
scala/scala-swing
examples/src/main/scala/scala/swing/examples/tutorials/components/ListDemo.scala
Scala
apache-2.0
5,837
package com.trafficland.augmentsbt.git case class InvalidCommitMessageException() extends Exception("git-commit requires a single, double-quoted commit message.")
trafficland/augment-sbt
src/main/scala/com/trafficland/augmentsbt/git/InvalidCommitMessageException.scala
Scala
apache-2.0
166
/* * 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...
hubertp/scalatest
src/main/scala/org/scalatest/Informer.scala
Scala
apache-2.0
4,043
package com.example import akka.actor.{Actor, ActorLogging, Props} class LoggingActor extends Actor with ActorLogging { var counter = 0 val pongActor = context.actorOf(PongActor.props, "pongActor") def receive = { case x => log.info("LoggingActor received event: {}", x.toString) } } object Loggi...
jasongoodwin/learning-akka
ch9/akka-logging/src/main/scala/com/example/LoggingActor.scala
Scala
apache-2.0
429
package org.squbs.sample import akka.actor.{ActorSystem, Props} import akka.testkit.{ImplicitSender, TestKit} import org.scalatest.{FlatSpecLike, Matchers} import scala.concurrent.duration._ import scala.language.postfixOps class SampleActorSpec extends TestKit(ActorSystem()) with FlatSpecLike with Matchers with Imp...
keshin/squbs-seed
src/test/scala/org/squbs/sample/SampleActorSpec.scala
Scala
apache-2.0
1,245
package de.semkath.symspell import java.util.logging.Logger import de.semkath.symspell.cleaning.{LegalFormRemoval, NameNormalization} import de.semkath.symspell.spellcheck.{SpellingCorrection, SpellingDictionary, SpellingErrors} import scala.collection.mutable object Main extends App { /* val companyFile = ...
semkath/symspell
src/main/scala/de/semkath/symspell/Main.scala
Scala
lgpl-3.0
1,477
package stgy import core.host.HostPool import core.observerPattern.{Observable, Observer} import core.provider.Provider import core.spatial.Zone import play.api.libs.json.{JsArray, Json} import stgy.StgyTypes.Color import scala.util.Random class StgyProvider extends Provider[StgyClientView] { val HP = HostPool...
DeltaIMT/Delta
stgy_server/src/main/scala/stgy/StgyProvider.scala
Scala
mit
1,946
/* * 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 ...
rekhajoshm/spark
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis/DecimalPrecision.scala
Scala
apache-2.0
14,964
package models import java.util.Date import javax.inject.{Inject, Singleton} import scala.concurrent.Future import play.api.libs.json.JsValue.jsValueToJsLookup import play.api.libs.json.{JsFalse, JsObject} import models.JsonFormat.taskStatusFormat import services.AuditedModel import org.elastic4play.JsonFormat.dat...
CERT-BDF/TheHive
thehive-backend/app/models/Task.scala
Scala
agpl-3.0
2,403
import definiti.native._ import java.time.LocalDateTime package object my { case class Parent(date: LocalDateTime, child: Child) object Parent { val verification: Verification[Parent] = Verification.all(Verification.all(Child.verification).from[Parent](_.child, "child")) def universe(now: LocalDateTime): V...
definiti/definiti-scala-model
src/test/resources/samples/specific/dependentVerification/traverse/output.scala
Scala
mit
1,339
package com.twitter.scalding.db.macros.impl import scala.annotation.tailrec import scala.language.experimental.macros import scala.reflect.macros.Context import scala.util.{ Success, Failure } import com.twitter.bijection.macros.impl.IsCaseClassImpl import com.twitter.scalding.db.{ ColumnDefinition, ColumnDefinitionP...
tdyas/scalding
scalding-db/src/main/scala/com/twitter/scalding/db/macros/impl/ColumnDefinitionProviderImpl.scala
Scala
apache-2.0
14,079
/* * 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 ...
hequn8128/flink
flink-table/flink-table-planner-blink/src/test/scala/org/apache/flink/table/planner/plan/batch/sql/CalcTest.scala
Scala
apache-2.0
4,748
package ar.edu.unq.tip.qsim.state /** * Copyright 2014 Tatiana Molinari. * Copyright 2014 Susana Rosito * * 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 * ...
molinarirosito/QSim
src/main/scala/ar/edu/unq/tip/qsim/state/Estado.scala
Scala
gpl-3.0
1,582
package org.flagz.testclasses import org.flagz._ object TestObjectOne extends FlagContainer { @FlagInfo(name = "test_one_int", help = "One's int") final val flagInt = ScalaFlagz.valueOf(300) }
mwitkow/java-flagz
flagz-scala/src/test/scala/org/flagz/testclasses/TestObjectOne.scala
Scala
mit
201
package com.thetestpeople.trt.utils.http import java.net.URI object AlwaysFailingHttp extends Http { @throws[HttpException] def get(url: URI, basicAuthOpt: Option[Credentials] = None): HttpResponse = throw new HttpException @throws[HttpException] def post(url: URI, basicAuthOpt: Option[Credentials] = None, ...
thetestpeople/trt
test/com/thetestpeople/trt/utils/http/AlwaysFailingHttp.scala
Scala
mit
404
/* * 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...
intel-analytics/BigDL
scala/dllib/src/main/scala/com/intel/analytics/bigdl/dllib/keras/layers/ResizeBilinear.scala
Scala
apache-2.0
2,694
package cromwell.services.healthmonitor import java.util.concurrent.TimeoutException import akka.actor.{Actor, Scheduler, Status, Timers} import akka.pattern.{after, pipe} import cromwell.util.GracefulShutdownHelper.ShutdownCommand import com.typesafe.scalalogging.LazyLogging import scala.concurrent.{ExecutionContex...
ohsu-comp-bio/cromwell
services/src/main/scala/cromwell/services/healthmonitor/HealthMonitorServiceActor.scala
Scala
bsd-3-clause
6,161
import sbt._ import sbt.Keys._ object GdalBuild extends Build { val scalaOptions = Seq( "-deprecation", "-unchecked", "-Yclosure-elim", "-Yinline-warnings", "-optimize", "-language:implicitConversions", "-language:postfixOps", "-language:existentials", ...
geotrellis/gdal-scala
project/Build.scala
Scala
mit
947
package agilesitesng.deploy.spoon import agilesites.annotations.Site import agilesitesng.deploy.model.{Spooler, SpoonModel, Uid} import spoon.processing.AbstractAnnotationProcessor import spoon.reflect.declaration.CtClass /** * Created by msciab on 06/08/15. */ class SiteAnnotationProcessor extends AbstractAnnotati...
agilesites/agilesites2-build
src/main/scala/agilesitesng/deploy/spoon/SiteAnnotationProcessor.scala
Scala
mit
597
package es.weso.utils import com.hp.hpl.jena.rdf.model.LiteralRequiredException import com.hp.hpl.jena.rdf.model.Model import com.hp.hpl.jena.rdf.model.ModelFactory import com.hp.hpl.jena.rdf.model.Resource import com.hp.hpl.jena.rdf.model.ResourceRequiredException import com.hp.hpl.jena.rdf.model.Statement import jav...
labra/wiGenerator
src/main/scala/es/weso/utils/JenaUtils.scala
Scala
mit
10,069
/********************************************************************************************************************** * This file is part of Scrupal, a Scalable Reactive Web Application Framework for Content Management * * ...
scrupal/scrupal
scrupal-storage/src/main/scala/scrupal/storage/api/SchemaDesign.scala
Scala
apache-2.0
4,300
object SubC
typesafehub/sbteclipse
src/sbt-test/sbteclipse/04-dependency-options/subc/src/main/scala/SubC.scala
Scala
apache-2.0
12
/* sbt -- Simple Build Tool * Copyright 2011 Mark Harrah */ package sbt import java.io.File import java.net.URI import Load.{BuildUnit, LoadBuildConfiguration, PartBuild} import BuildLoader._ import Alternatives._ import Types.{const,idFun} final class MultiHandler[S,T](builtIn: S=>Option[T], root: Option[S =...
kuochaoyi/xsbt
main/BuildLoader.scala
Scala
bsd-3-clause
5,848
/* * 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/table/CarbonExplainCommand.scala
Scala
apache-2.0
3,303
package com.avsystem.commons package redis.examples import akka.actor.ActorSystem import akka.util.ByteString import com.avsystem.commons.redis._ import com.avsystem.commons.serialization.GenCodec /** * Example which shows how to customize your Redis API in order to use types different from the default ones used ...
AVSystem/scala-commons
commons-redis/src/test/scala/com/avsystem/commons/redis/examples/ApiCustomizationExample.scala
Scala
mit
1,963
/* * Copyright (C) 2013 Alcatel-Lucent. * * See the NOTICE file distributed with this work for additional * information regarding copyright ownership. * Licensed to you 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 cop...
molecule-labs/molecule
molecule-core/src/main/scala/molecule/process/CoreProcess.scala
Scala
apache-2.0
3,316
package roomvalidationtest import play.api.test.PlaySpecification import validations.RoomValidation /** * Created by ka-son on 6/6/15. */ object CheckLogin extends PlaySpecification with RoomValidation { "checkLogin(None) mustEqual " + "Right(\\"No login is found\\")" in { checkLogin(None) mustEqual Righ...
KasonChan/play-chat-api
test/roomvalidationtest/CheckLogin.scala
Scala
mit
1,177
/* * 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
mimir/src/main/scala/quasar/mimir/DAGTransform.scala
Scala
apache-2.0
4,176
/* * 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
sql/catalyst/src/test/scala/org/apache/spark/sql/types/StructTypeSuite.scala
Scala
apache-2.0
3,027
package chandu0101.scalajs.react.components.util import japgolly.scalajs.react.TopNode import org.scalajs.dom.Event import scala.scalajs.js import scala.scalajs.js.Dynamic.{global => g} /** * Created by chandrasekharkode . */ object CssEvents { def testSupportedProps(props: Map[String, String]) = { val el =...
coreyauger/scalajs-react-components
core/src/main/scala/chandu0101/scalajs/react/components/util/CssEvents.scala
Scala
apache-2.0
1,184
/* * 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 ...
zuotingbing/spark
sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/expressions/IntervalExpressionsSuite.scala
Scala
apache-2.0
9,309
package sp.domain.logic import java.time._ import sp.domain._ import play.api.libs.json._ import play.api.libs.json.Reads.verifying object JsonLogic extends JsonImplicit trait JsonImplicit extends JsonDerived { def writeJson[T](x: T)(implicit fjs: JSWrites[T]) = { Json.stringify(Json.toJson(x)) } // ...
sequenceplanner/sp-domain
src/main/scala/sp/domain/logic/JsonLogic.scala
Scala
mit
24,666
package reactivemongo.api import scala.language.higherKinds import scala.collection.generic.CanBuildFrom import scala.collection.mutable.Builder import scala.concurrent.{ ExecutionContext, Future } private[api] trait CursorCompat[T] { _: Cursor[T] with CursorCompatAPI[T] => import Cursor.{ Cont, ErrorHandler } ...
ornicar/ReactiveMongo
driver/src/main/scala-2.13-/api/CursorCompat.scala
Scala
apache-2.0
686
package model import anorm._ import org.joda.time.DateTime import play.api.libs.json.Json import common.JsonFormatHelpers._ case class Entry( id: Pk[Long], creatorId: Long, stateId: Long, groupId: Long, created: DateTime, content: String ) { def this(creatorId: Long, stateId: Long, groupId: Long, conte...
mikegirkin/papersheet
src/app/model/Entry.scala
Scala
mit
476
package io.skysail.app.demo.domain import javax.validation.constraints._ import com.fasterxml.jackson.annotation._ import java.util.Date import scala.annotation.meta.field import scala.beans.BeanProperty import io.skysail.core.html._ import io.skysail.core.domain.ScalaEntity @BeanProperty case class Todo ( var ...
evandor/skysail-notes
skysail.app.demo/src/io/skysail/app/demo/domain/Todo.scala
Scala
apache-2.0
475
package com.markfeeney.circlet import java.util.Locale sealed trait Scheme object Scheme { case object Http extends Scheme case object Https extends Scheme def parse(s: String): Scheme = { s.toLowerCase(Locale.ENGLISH) match { case "http" => Http case "https" => Https case other => sys.er...
overthink/circlet
src/main/scala/com/markfeeney/circlet/Scheme.scala
Scala
mit
388
package models.hms import play.api.libs.json._ /** * author: cvandrei * since: 2016-02-18 */ case class JobResult(ID: Long, Result: String, VerboseResult: Option[String] ) object JobResult { implicit val reads = Json.reads[JobResult] implicit va...
indarium/hbbTVPlugin
app/models/hms/JobResult.scala
Scala
agpl-3.0
356
/* * 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...
wangyixiaohuihui/spark2-annotation
core/src/main/scala/org/apache/spark/shuffle/ShuffleBlockResolver.scala
Scala
apache-2.0
1,616
package net.sansa_stack.query.spark.ontop import net.sansa_stack.query.spark.api.domain.ResultSetSpark import net.sansa_stack.query.spark.api.impl.{QueryExecutionSparkBase, ResultSetSparkImpl} import org.aksw.jenax.arq.connection.core.QueryExecutionFactory import org.aksw.jenax.arq.util.binding.ResultSetUtils import o...
SANSA-Stack/SANSA-RDF
sansa-query/sansa-query-spark/src/main/scala/net/sansa_stack/query/spark/ontop/QueryExecutionSparkOntop.scala
Scala
apache-2.0
1,330
package chandu0101.scalajs.react.components package materialui import chandu0101.macros.tojs.JSMacro import japgolly.scalajs.react._ import japgolly.scalajs.react.raw.React import japgolly.scalajs.react.vdom.VdomNode import org.scalajs.dom import scala.scalajs.js import scala.scalajs.js.`|` /** * This file is gene...
rleibman/scalajs-react-components
core/src/main/scala/chandu0101/scalajs/react/components/materialui/MuiSubheader.scala
Scala
apache-2.0
1,087
/* * 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/utils/Logging.scala
Scala
apache-2.0
711
package com.twitter_typesafe.config.impl import org.junit.Assert._ import org.junit._ import org.junit.BeforeClass import java.net.URL import com.twitter_typesafe.config.ConfigFactory import com.twitter_typesafe.config.ConfigParseOptions import com.twitter_typesafe.config.ConfigSyntax import com.twitter_typesafe.confi...
twitter-forks/config
config/src/test/scala/com/typesafe/config/impl/HttpTest.scala
Scala
apache-2.0
5,164
/* * Copyright (c) 2014-2020 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...
alexandru/monifu
monix-reactive/shared/src/main/scala/monix/reactive/internal/operators/FoldWhileLeftObservable.scala
Scala
apache-2.0
2,497
/* * Copyright 2020 Precog Data * * 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 ...
djspiewak/quasar
ejson/src/main/scala/quasar/ejson/Common.scala
Scala
apache-2.0
3,799
package notebook.util import play.api.libs.json._ /** * Pluggable interface for completing Strings. */ case class Match(matchedValue: String, metadata: Map[String, String]) { def toJson = JsString(matchedValue) } object Match { def apply(matchedValue: String): Match = Match(matchedValue, Map()) } trait Strin...
vitan/spark-notebook
modules/common/src/main/scala/notebook/util/StringCompletor.scala
Scala
apache-2.0
398
/* __ *\ ** ________ ___ / / ___ Scala API ** ** / __/ __// _ | / / / _ | (c) 2006-2010, LAMP/EPFL ** ** __\ \/ /__/ __ |/ /__/ __ | http://scala-lang.org/ ** ** /____/\___/_/ |_/...
cran/rkafkajars
java/scala/collection/immutable/NumericRange.scala
Scala
apache-2.0
8,009
package scala.meta.tests package io import java.io.File import java.net.URI import org.scalatest.FunSuite import scala.meta._ class MultipathSuite extends FunSuite { val tmp: File = File.createTempFile("src", "main") assert(tmp.delete()) assert(tmp.mkdirs()) val files = List("a", "b") files.foreach(file => ...
DavidDudson/scalameta
tests/jvm/src/test/scala/scala/meta/tests/io/MultipathSuite.scala
Scala
bsd-3-clause
1,405
package uk.co.morleydev.ghosthunt.controller.impl.game import uk.co.morleydev.ghosthunt.controller.Controller import uk.co.morleydev.ghosthunt.model.net.{NetworkMessage, game} import scala.concurrent.duration.Duration import scala.concurrent.duration import uk.co.morleydev.ghosthunt.model.GameTime import uk.co.morleyd...
MorleyDev/GhostHunt
src/main/scala/uk/co/morleydev/ghosthunt/controller/impl/game/ClientRequestGameTimeController.scala
Scala
mit
1,787