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
/* * Copyright (C) 2016-2019 Lightbend Inc. <https://www.lightbend.com> */ package com.lightbend.lagom.internal.api.tools import com.lightbend.lagom.internal.spi.{ ServiceAcl, ServiceDescription, ServiceDiscovery } import com.typesafe.config.ConfigFactory import play.api._ import play.api.libs.functional.syntax._ i...
rstento/lagom
api-tools/src/main/scala/com/lightbend/lagom/internal/api/tools/ServiceDetector.scala
Scala
apache-2.0
2,442
/* __ *\ ** ________ ___ / / ___ __ ____ Scala.js tools ** ** / __/ __// _ | / / / _ | __ / // __/ (c) 2013-2014, LAMP/EPFL ** ** __\ \/ /__/ __ |/ /__/ __ |/_// /_\ \ http://scala-js.org/ ** ** /____/\___/_/ |_/...
mdedetrich/scala-js
tools/shared/src/main/scala/org/scalajs/core/tools/linker/ClearableLinker.scala
Scala
bsd-3-clause
2,581
package org.jetbrains.plugins.scala package codeInsight.generation /** * Nikolay.Tropin * 2014-09-18 */ class ScalaGeneratePropertyAction extends ScalaBaseGenerateAction(new ScalaGeneratePropertyHandler)
triggerNZ/intellij-scala
src/org/jetbrains/plugins/scala/codeInsight/generation/ScalaGeneratePropertyAction.scala
Scala
apache-2.0
207
package controllers import akka.actor.ActorSystem import javax.inject._ import models.Message import play.api._ import play.api.libs.json.Json import play.api.mvc._ import scala.concurrent.{ ExecutionContext, Future, Promise } import scala.concurrent.duration._ /** * This controller creates an `Action` that demonstr...
kbedel/play-swagger
example/app/controllers/AsyncController.scala
Scala
apache-2.0
1,480
package skinny.assets import java.io.{ ByteArrayInputStream, IOException, InputStreamReader } import skinny.util.LoanPattern._ import skinny.{ ClassPathResourceLoader, ScalaVersion } import scala.sys.process._ import org.slf4j.LoggerFactory import skinny.exception.AssetsPrecompileFailureException import org.mozilla....
seratch/skinny-framework
assets/src/main/scala/skinny/assets/ReactJSXCompiler.scala
Scala
mit
3,709
/* Title: Pure/General/bytes.scala Author: Makarius Immutable byte vectors versus UTF8 strings. */ package isabelle import java.io.{File => JFile, ByteArrayOutputStream, ByteArrayInputStream, OutputStream, InputStream, FileInputStream, FileOutputStream} import java.net.URL import java.util.Base64 i...
larsrh/libisabelle
modules/pide/2018/src/main/scala/General/bytes.scala
Scala
apache-2.0
5,589
package cromwell.core import wom.graph.CallNode trait CallKey extends JobKey { def node: CallNode }
ohsu-comp-bio/cromwell
core/src/main/scala/cromwell/core/CallKey.scala
Scala
bsd-3-clause
104
/* * Copyright (c) 2010-2011 Belmont Technology Pty Ltd. 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 * * U...
GrahamLea/SodaTest
sodatest-runtime/src/test/scala/org/sodatest/runtime/processing/running/testFixtures/ExceptionDuringCreationTestFixture.scala
Scala
apache-2.0
969
/* * 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 ...
DieBauer/flink
flink-libraries/flink-table/src/main/scala/org/apache/flink/table/plan/nodes/datastream/DataStreamAggregate.scala
Scala
apache-2.0
10,584
package io.vamp.pulse import java.time.OffsetDateTime import java.time.format.DateTimeFormatter import akka.actor.Actor import io.vamp.common.{ ClassMapper, Config, ConfigMagnet, Namespace } import io.vamp.common.http.OffsetEnvelope import io.vamp.common.json.{ OffsetDateTimeSerializer, SerializationFormat } import i...
magneticio/vamp
elasticsearch/src/main/scala/io/vamp/pulse/ElasticsearchPulseActor.scala
Scala
apache-2.0
9,938
package com.timushev.sbt.updates.metadata import com.timushev.sbt.updates.versions.Version import sbt._ import scala.concurrent.Future trait MetadataLoader { def getVersions(module: ModuleID): Future[Seq[Version]] }
rtimush/sbt-updates
src/main/scala/com/timushev/sbt/updates/metadata/MetadataLoader.scala
Scala
bsd-3-clause
221
/* * Copyright 2021 HM Revenue & Customs * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or a...
hmrc/ct-calculations
src/test/scala/uk/gov/hmrc/ct/ct600/accounts/AC8023Spec.scala
Scala
apache-2.0
11,893
package simba.titan100.connector import java.util import com.thinkaurelius.titan.core.{TitanFactory, TitanGraph} import org.apache.spark.rdd.RDD import org.apache.spark.{Partition, SparkContext, TaskContext} import org.apache.tinkerpop.gremlin.process.traversal.dsl.graph.GraphTraversal import org.apache.tinke...
cas-bigdatalab/simba
src/main/scala/simba/titan100/connector/TitanRDD.scala
Scala
bsd-2-clause
5,174
package com.hyenawarrior.OldNorseGrammar.grammar.nouns.stemclasses import com.hyenawarrior.OldNorseGrammar.grammar.enums.Case._ import com.hyenawarrior.OldNorseGrammar.grammar.enums.GNumber._ import com.hyenawarrior.OldNorseGrammar.grammar.nouns.NounType import com.hyenawarrior.OldNorseGrammar.grammar.nouns.stemclasse...
HyenaSoftware/IG-Dictionary
OldNorseGrammarEngine/src/main/scala/com/hyenawarrior/OldNorseGrammar/grammar/nouns/stemclasses/StrongStemClassFeminineA.scala
Scala
lgpl-3.0
835
package org.jetbrains.plugins.scala.failed.typeInference import org.jetbrains.plugins.scala.PerfCycleTests import org.jetbrains.plugins.scala.lang.typeInference.TypeInferenceTestBase import org.junit.experimental.categories.Category /** * Created by mucianm on 22.03.16. */ @Category(Array(classOf[PerfCycleTests])...
jeantil/intellij-scala
test/org/jetbrains/plugins/scala/failed/typeInference/PatternsTest.scala
Scala
apache-2.0
890
/* * Copyright University of Basel, Graphics and Vision Research Group * * 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 ...
unibas-gravis/scalismo-faces
src/main/scala/scalismo/faces/io/GravisArrayIO.scala
Scala
apache-2.0
6,622
package org.jetbrains.plugins.scala.failed.resolve import org.intellij.lang.annotations.Language import org.jetbrains.plugins.scala.annotator.AnnotatorHolderMock import org.jetbrains.plugins.scala.annotator.element.ElementAnnotator import org.jetbrains.plugins.scala.base.SimpleTestCase import org.jetbrains.plugins.sca...
JetBrains/intellij-scala
scala/scala-impl/test/org/jetbrains/plugins/scala/failed/resolve/ArgumentTypeMismatchTest.scala
Scala
apache-2.0
2,092
package com.twitter.concurrent import org.junit.runner.RunWith import org.scalatest.WordSpec import org.scalatest.junit.JUnitRunner import org.scalatest.mock.MockitoSugar import com.twitter.util.{Promise, Return} @RunWith(classOf[JUnitRunner]) class FutureOfferTest extends WordSpec with MockitoSugar { "Future.toO...
travisbrown/util
util-core/src/test/scala/com/twitter/util/FutureOfferTest.scala
Scala
apache-2.0
762
package redis import akka.util.ByteString import redis.protocol._ import redis.util.CRC16 trait RedisCommand[RedisReplyT <: RedisReply, +T] { val isMasterOnly: Boolean val encodedRequest: ByteString def decodeReply(r: RedisReplyT): T val decodeRedisReply: PartialFunction[ByteString, DecodeResult[RedisReply...
mspielberg/rediscala
src/main/scala/redis/RedisCommand.scala
Scala
apache-2.0
4,352
/*********************************************************************** * 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 ...
tkunicki/geomesa
geomesa-tools/src/main/scala/org/locationtech/geomesa/tools/export/formats/DelimitedExporter.scala
Scala
apache-2.0
3,264
// Copyright: 2010 - 2017 https://github.com/ensime/ensime-server/graphs // License: http://www.apache.org/licenses/LICENSE-2.0 package org.ensime.api import java.io.File final case class EnsimeConfig( @deprecating("rootDir is no longer used except in testing") rootDir: File, cacheDir: File, javaHome: File, n...
hzenginx/ensime-server
api/src/main/scala/org/ensime/api/config.scala
Scala
gpl-3.0
852
package metal package immutable import scala.reflect.{classTag, ClassTag} final class WrappedBuffer[V](val w: metal.immutable.Buffer[V]) extends scala.collection.immutable.IndexedSeq[V] with scala.collection.IndexedSeqOptimized[V, WrappedBuffer[V]] { import w.ctV def apply(idx: Int): V = w(idx) def l...
denisrosset/ptrcoll
library/src/main/scala/metal/immutable/Buffer.scala
Scala
mit
1,982
package rere.ql.options import rere.ql.queries.values trait InterleaveOptions { sealed trait InterleaveOptions extends ComposableOptions case object Mix extends InterleaveOptions with DefaultOption case object PreventMixing extends InterleaveOptions with NonDefaultOption { def view = "interleave" -> valu...
pbaun/rere
modules/ql/src/main/scala/rere/ql/options/InterleaveOptions.scala
Scala
apache-2.0
541
package org.apress.prospark import java.util.concurrent.atomic.AtomicLong import org.apache.spark.SparkConf import org.apache.spark.SparkContext import org.apache.spark.streaming.Seconds import org.apache.spark.streaming.StreamingContext import org.json4s.DefaultFormats import org.json4s.jvalue2extractable import org...
ZubairNabi/prosparkstreaming
Chap6/src/main/scala/org/apress/prospark/L6-22Counters.scala
Scala
apache-2.0
2,428
/* * 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 ...
bwsw/sj-platform
core/sj-common/src/main/scala/com/bwsw/sj/common/si/model/module/ModuleMetadata.scala
Scala
apache-2.0
5,633
package com.productfoundry.akka.cqrs.publish import akka.actor.Props import akka.testkit.TestProbe import com.productfoundry.akka.cqrs.publish.FanoutPublisher.Subscribe import com.productfoundry.akka.cqrs.{DummyConfirmable, Fixtures} import com.productfoundry.akka.messaging.Confirmable import com.productfoundry.akka.m...
odd/akka-cqrs
core/src/test/scala/com/productfoundry/akka/cqrs/publish/FanoutPublisherSpec.scala
Scala
apache-2.0
3,896
package scalaSci.jplot /** * Bins for a histogram. These can be implicitly constructed from: * <pre> * x : HistogramBins = 10 // 10 dynamically determined histogram bins * x : HistogramBins = Array(1.0,2.0,3.2) // five buckets wit the given splits * x : HistogramBins = (0,100,10) // ten bins evenly dividing 0 ...
scalalab/scalalab
source/src/main/scala/scalaSci/jplot/HistogramBins.scala
Scala
mit
1,678
package org.jetbrains.plugins.scala.lang.transformation package calls import org.jetbrains.plugins.scala.lang.psi.api.expr.{ScBlockExpr, ScInfixExpr, ScMethodCall} import org.jetbrains.plugins.scala.lang.psi.impl.ScalaCode._ /** * @author Pavel Fatin */ object CanonizeBlockArgument extends AbstractTransformer { ...
whorbowicz/intellij-scala
src/org/jetbrains/plugins/scala/lang/transformation/calls/CanonizeBlockArgument.scala
Scala
apache-2.0
626
class E[F] class A class B class C trait TypeMember { type X // This call throws an AbstractMethodError, because it invokes the erasure of // consume(X): Unit that is consume(Object): Unit. But the corresponding // bridge method is not generated. consume(value) def value: X def consume(x: X): Unit } o...
felixmulder/scala
test/files/run/t8575.scala
Scala
bsd-3-clause
622
package com.monsanto.arch.cloudformation.model.resource import com.monsanto.arch.cloudformation.model.{ConditionRef, ResourceRef, Token, `Fn::GetAtt`} import com.monsanto.arch.cloudformation.model.Token.TokenSeq import spray.json.{DefaultJsonProtocol, JsString, JsValue, JsonFormat} import DefaultJsonProtocol._ case c...
MonsantoCo/cloudformation-template-generator
src/main/scala/com/monsanto/arch/cloudformation/model/resource/ApiGateway.scala
Scala
bsd-3-clause
19,494
/* * 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 ...
u2009cf/spark-radar
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/catalog/ExternalCatalogUtils.scala
Scala
apache-2.0
5,755
package org.eso.ias.supervisor.test import java.nio.file.FileSystems import org.eso.ias.cdb.CdbReader import org.eso.ias.cdb.json.{CdbJsonFiles, JsonReader} import org.eso.ias.dasu.publisher.{DirectInputSubscriber, ListenerOutputPublisherImpl, OutputListener, OutputPublisher} import org.eso.ias.logging.IASLogger impo...
IntegratedAlarmSystem-Group/ias
Supervisor/src/test/scala/org/eso/ias/supervisor/test/SupervisorTest.scala
Scala
lgpl-3.0
8,620
/* __ *\\ ** ________ ___ / / ___ Scala API ** ** / __/ __// _ | / / / _ | (c) 2005-2010, LAMP/EPFL ** ** __\\ \\/ /__/ __ |/ /__/ __ | http://scala-lang.org/ ** ** /____/\\___/_/...
cran/rkafkajars
java/scala/actors/MessageQueue.scala
Scala
apache-2.0
7,304
/* * Copyright 2001-2013 Artima, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agre...
svn2github/scalatest
src/main/scala/org/scalatest/words/BeWord.scala
Scala
apache-2.0
18,528
package com.arcusys.valamis.certificate.repository import javax.inject.Inject import com.arcusys.valamis.certificate.model.goal.PackageGoal import com.arcusys.valamis.certificate.schema.PackageGoalTableComponent import com.arcusys.valamis.certificate.storage.PackageGoalStorage import com.arcusys.valamis.core.{SlickDB...
ViLPy/Valamis
valamis-slick-persistence/src/main/scala/com/arcusys/valamis/certificate/repository/PackageGoalStorageImpl.scala
Scala
lgpl-3.0
3,093
/* * 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.reflect.reify pa...
scala/scala
src/compiler/scala/reflect/reify/codegen/GenAnnotationInfos.scala
Scala
apache-2.0
2,306
package net.fehmicansaglam.tepkin.protocol.result import net.fehmicansaglam.bson.BsonDocument protected[result] trait Result case class CountResult(missing: Option[Boolean] = None, n: Int, ok: Boolean) extends Result { /** Alias for n **/ def count: Int = n } case class DeleteResult(ok: Boolean, ...
cancobanoglu/tepkin
tepkin/src/main/scala/net/fehmicansaglam/tepkin/protocol/result/Result.scala
Scala
apache-2.0
1,081
package org.jetbrains.sbt package project.data.service import com.intellij.openapi.externalSystem.model.DataNode import com.intellij.openapi.externalSystem.model.project.ProjectData import com.intellij.openapi.externalSystem.service.project.IdeModifiableModelsProvider import com.intellij.openapi.module.Module import c...
JetBrains/intellij-scala
scala/integration/android/src/org/jetbrains/sbt/project/data/service/SbtAndroidFacetDataService.scala
Scala
apache-2.0
3,222
package io.swagger.client.model case class ValueObject ( /* Timestamp for the measurement event in epoch time (unixtime) */ timestamp: Long, /* Measurement value */ value: Double, /* Optional note to include with the measurement */ note: String)
QuantiModo/QuantiModo-SDK-Scala
src/main/scala/io/swagger/client/model/ValueObject.scala
Scala
gpl-2.0
265
package edu.neu.coe.csye._7200 import scala.math.pow import scala.annotation.tailrec /** * @author scalaprof */ case class Rational(n: Long, d: Long) extends Numeric[Rational] { // Pre-conditions require(Rational.gcd(math.abs(n),math.abs(d))==1,s"Rational($n,$d): arguments have common factor: ${Rational.gcd(...
rchillyard/Scalaprof
FunctionalProgramming/src/main/scala/edu/neu/coe/csye/_7200/Rational.scala
Scala
gpl-2.0
4,919
trait FOO[B, m[A <: B]] trait FOO2[A <: B, B] trait FOO3[m[A <: B], B] class Test { def foo[a[x]] = "a" } //trait Idiom[idi[x]] { def foo: idi[Int]}
yusuke2255/dotty
tests/untried/pos/tcpoly_param_scoping.scala
Scala
bsd-3-clause
152
/* * Copyright 2018 Vladimir Konstantinov * * 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 ...
yet-another-cafebabe/http
src/main/scala/com/github/illfaku/korro/config/HttpInstruction.scala
Scala
lgpl-3.0
1,922
/* * 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/hive/src/test/scala/org/apache/spark/sql/hive/execution/HiveDDLSuite.scala
Scala
apache-2.0
84,759
/* * 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 ...
caneGuy/spark
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/catalog/SessionCatalog.scala
Scala
apache-2.0
62,007
package utilTests import org.junit.Test import xyz.nabijaczleweli.scala_game_of_life.util.NumberUtil import scala.annotation.tailrec import NumberUtil._ import scala.util.Random /** @author JΔ™drzej * @since 26.04.14 */ class NumberUtilBinDecTest { val rand = new Random @Test def recursive() { rec(0, 10000,...
nabijaczleweli/Scala-Game-of-Life
src/test/scala/utilTests/NumberUtilBinDecTest.scala
Scala
mit
648
package org.jetbrains.plugins.scala.lang.resolve.testAllResolve package generated class TestAllResolveSelfTest extends TestAllResolveTestBase { //This class was generated by build script, please don't change this override def folderPath: String = super.folderPath + "self/" def testSelf() = doTest() }
ilinum/intellij-scala
test/org/jetbrains/plugins/scala/lang/resolve/testAllResolve/generated/TestAllResolveSelfTest.scala
Scala
apache-2.0
309
package lila.tournament import org.joda.time.DateTime import reactivemongo.api.ReadPreference import scala.concurrent.duration._ import chess.variant.{ Variant, Standard, FromPosition } import lila.db.dsl._ import lila.user.{ User, UserRepo } import Schedule.{ Freq, Speed } case class Winner( tourId: String, use...
clarkerubber/lila
modules/tournament/src/main/WinnersApi.scala
Scala
agpl-3.0
4,499
/** * 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 ap...
darroyocazorla/spark-mongodb
spark-mongodb/src/test/scala/com/stratio/datasource/mongodb/writer/MongodbWriterIT.scala
Scala
apache-2.0
8,163
/* * Copyright 2012 Arktekk AS * * 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...
arktekk/scala-atom
src/test/scala/no/arktekk/atom/ExtensionSpec.scala
Scala
apache-2.0
2,058
package uk.gov.gds.ier.transaction.crown.confirmation import uk.gov.gds.ier.test._ import uk.gov.gds.ier.model._ import uk.gov.gds.ier.transaction.crown.InprogressCrown import uk.gov.gds.ier.transaction.shared.{BlockContent, BlockError} class ConfirmationMustacheTest extends MustacheTestSuite with MockitoHelpers ...
alphagov/ier-frontend
test/uk/gov/gds/ier/transaction/crown/confirmation/ConfirmationMustacheTest.scala
Scala
mit
47,660
/* * Copyright (c) 2010 e.e d3si9n * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal * in the Software without restriction, including without limitation the rights * to use, copy, modify, merge, publish...
Fayho/scalaxb
cli/src/main/scala/scalaxb/compiler/xsd/GenSource.scala
Scala
mit
46,048
package io.mca.twitter.rest.statuses import io.mca.twitter.rest.RESTApiRequest // https://dev.twitter.com/docs/api/1.1/get/statuses/show/%3Aid case class Show(token: String, tokenSecret: String, id: String, trimUser: Option[Boolean] = None, includeMyRetweet: Option[Boolean] = None, includeEntities: O...
mmacaulay/scala-twitter-api
src/main/scala/io/mca/twitter/rest/statuses/Show.scala
Scala
mit
661
/* * 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/test/scala/com/intel/analytics/bigdl/nn/ConvLSTMPeepholeSpec.scala
Scala
apache-2.0
50,632
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may ...
zzcclp/carbondata
integration/spark/src/test/scala/org/apache/carbondata/integration/spark/testsuite/complexType/TestAdaptiveEncodingUnsafeHeapColumnPageForComplexDataType.scala
Scala
apache-2.0
1,949
/* * SPDX-License-Identifier: Apache-2.0 * * Copyright 2015-2021 Andre White. * * 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 * * https://www.apache.org/licenses/LICENSE...
adarro/ddo-calc
subprojects/common/ddo-core/src/specs/scala/io/truthencode/ddo/model/feats/RaceSupport.scala
Scala
apache-2.0
1,839
package org.raisercostin.jedi import java.io.File import java.io.InputStream import java.nio.file.Path import scala.language.implicitConversions import scala.language.reflectiveCalls import org.raisercostin.jedi.impl.{ FileSystemFormatter, JediFileSystem } import org.raisercostin.jedi.impl.Predef2 /** ...
raisercostin/jedi-io
src/main/scala/org/raisercostin/jedi/Locations.scala
Scala
apache-2.0
3,106
package mesosphere.raml.ir case class ObjectT( name: String, fields: Seq[FieldT], parentType: Option[String], comments: Seq[String], childTypes: Seq[ObjectT] = Nil, discriminator: Option[String] = None, discriminatorValue: Option[String] = None, serializeOnly: Boolean = false, paren...
mesosphere/marathon
type-generator/src/main/scala/mesosphere/raml/ir/ObjectT.scala
Scala
apache-2.0
534
/* * Level.scala * * Updated: Apr 27, 2015 * * Copyright (c) 2015, CodeMettle */ package com.github.pimterry.loglevel import scala.scalajs.js import scala.scalajs.js.annotation.JSGlobal /** * @author steven * */ @js.native trait Level extends js.Object @JSGlobal("log.levels") @js.native object Level extends...
CodeMettle/scalajs-loglevel
src/main/scala/com/github/pimterry/loglevel/Level.scala
Scala
mit
527
package example import org.scalatest.FunSuite import org.junit.runner.RunWith import org.scalatest.junit.JUnitRunner /** * This class implements a ScalaTest test suite for the methods in object * `Lists` that need to be implemented as part of this assignment. A test * suite is simply a collection of individual te...
dawid-swist/discover-scala
Coursera/Progfun1/Week1/src/test/scala/example/ListsSuite.scala
Scala
gpl-3.0
4,040
package wakfutcp.protocol.messages.client import wakfutcp.protocol.{ClientMessage, Codec} final case class RemoveIgnoreMessage( ignoreName: String ) extends ClientMessage { override val id = 3135 override val arch = 4 } object RemoveIgnoreMessage { import Codec._ import cats.syntax.invariant._ implicit ...
OpenWakfu/wakfutcp
protocol/src/main/scala/wakfutcp/protocol/messages/client/RemoveIgnoreMessage.scala
Scala
mit
415
package com.sksamuel.elastic4s.analyzers import org.elasticsearch.common.xcontent.{XContentBuilder, XContentFactory} import scala.collection.JavaConverters._ trait AnalyzerFilter { def name: String } case class PredefinedTokenFilter(name: String) extends TokenFilter case class PredefinedCharFilter(name: String) e...
aroundus-inc/elastic4s
elastic4s-core/src/main/scala/com/sksamuel/elastic4s/analyzers/analyzerFilters.scala
Scala
apache-2.0
1,435
package org.openapitools.client.model case class DiskSpaceMonitorDescriptorDiskSpace ( _class: Option[String], _timestamp: Option[Integer], _path: Option[String], _size: Option[Integer] ) object DiskSpaceMonitorDescriptorDiskSpace { def toStringBody(var_class: Object, var_timestamp: Object, var_p...
cliffano/swaggy-jenkins
clients/scala-gatling/generated/src/gatling/scala/org/openapitools/client/model/DiskSpaceMonitorDescriptorDiskSpace.scala
Scala
mit
506
/******************************************************************************* * Copyright 2017 Capital One Services, LLC and Bitwise, 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...
capitalone/Hydrograph
hydrograph.engine/hydrograph.engine.spark/src/main/scala/hydrograph/engine/spark/components/InputHiveComponent.scala
Scala
apache-2.0
3,070
/** * @author δΊ”ηΎ– chi.lchenchi@alibaba-inc.com * @version 10/15/15 11:24 PM */ def factorial(n: Int): Int = n match { case 0 => 1 case x if x > 0 => factorial(n - 1) * n } println(factorial(0)) println(factorial(3))
momo9/seven-lang
scala/src/pattern.scala
Scala
mit
232
package htwg.scalmon.controller import org.scalatest._ import htwg.scalmon.model._; class ControllerSpec extends FlatSpec with Matchers with GivenWhenThen { val playerA = new Player("P_A", List("A1", "A2").map(name => new Animal(name)).toArray) val playerB = new Player("P_B", List("B1", "B2").map(name => new Ani...
themerius/scalmon
src/test/scala/htwg/scalmon/controller/ControllerSpec.scala
Scala
lgpl-3.0
5,573
package se.citerus.dddsample.interfaces.booking.facade.dto case class LocationDTO(val unlocode:String, val name:String)
oluies/ddd-sample-scala
src/main/scala/se/citerus/dddsample/interfaces/booking/facade/dto/LocationDTO.scala
Scala
mit
123
/* * Dice heroes is a turn based rpg-strategy game where characters are dice. * Copyright (C) 2016 Vladislav Protsenko * * 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...
ratrecommends/dice-heroes
helpers/src/RewardGen.scala
Scala
gpl-3.0
1,320
package client.modals import client.components.Bootstrap.Modal import client.components.GlobalStyles import client.components.Icon import shared.models.{ EmailValidationModel, UserModel } import client.LGMain.{ Loc } import scala.util.{ Failure, Success } import scalacss.ScalaCssReact._ import japgolly.scalajs.react._...
LivelyGig/ProductWebUI
client/src/main/scala/client/modalpopups/CopyrightModal.scala
Scala
apache-2.0
3,138
import scala.reflect.ClassTag object Solution { sealed class LinkedStack[T] (implicit t2o: T => Ordered[T]) { private sealed case class Node( value: T ) { var prev: Option[Node] = None var prevMax: Option[T] = None def max(): T = prevMax filter {_ > value} getOrElse value } ...
marcos-sb/hacker-rank
data-structures/stacks/maximum-element/Solution.scala
Scala
apache-2.0
1,168
/* * 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
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/plans/logical/statsEstimation/EstimationUtils.scala
Scala
apache-2.0
4,587
/** Copyright 2014 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 ...
TheDataShed/PredictionIO
core/src/main/scala/controller/java/JavaWorkflow.scala
Scala
apache-2.0
3,144
package services import com.google.inject.{Inject, Singleton} import config.ApplicationConfig import connectors.GameConnector import handlers.ServerRequestHandler import models.UserModel import org.spongepowered.api.entity.living.player.Player import keys.PermissionKeys._ import scala.collection.JavaConverters._ impo...
jameshforster/ToL-Scout-Plugin
src/main/scala/services/UserService.scala
Scala
apache-2.0
1,088
package cn.changhong.spliter.demo // (Source.fromURL(new URL("http://apps.wandoujia.com/api/v1/apps?tag=η›ΈζœΊ&max=60&start=100")).getLines().foreach(println)) // val doc=Jsoup.parse(new URL("http://www.wandoujia.com/apps"),1000) // val li=doc.select("li.parent-cate") // li.toArray()foreach{e=>println(e)} // val i...
guoyang2011/myfinagle
spliter/src/main/scala/cn/changhong/spliter/demo/Start.scala
Scala
apache-2.0
1,142
package app import com.google.inject.Guice import com.mohiva.play.silhouette.api.{Logger, SecuredSettings} import controllers.routes import play.api.GlobalSettings import play.api.i18n.{Lang, Messages} import play.api.mvc.Results._ import play.api.mvc.{RequestHeader, Result} import utils.di.SilhouetteModule import sc...
ibnuda/hasembuh
app/Global.scala
Scala
apache-2.0
2,030
package java.lang import scala.scalajs.js class Throwable(s: String, private var e: Throwable) extends Object with java.io.Serializable { def this() = this(null, null) def this(s: String) = this(s, null) def this(e: Throwable) = this(null, e) private[this] var stackTrace: Array[StackTraceElement] = _ fill...
swhgoon/scala-js
javalib/source/src/java/lang/Throwables.scala
Scala
bsd-3-clause
10,049
/** * File classes/ex1.scala */ // 2D Point class Point2D(x: Int, y: Int) { println("Point2D Constructed: " + x + ", " + y) } object Point2DDemo { def main(args: Array[String]) { val p1 = new Point2D(10, 2) } }
michaelflowersky/geekingspree
classes/ex1.scala
Scala
mit
234
package com.sageserpent.plutonium abstract class AbstractedHistory extends History { override type Id = String def property: Int def property_=(value: Int): Unit }
sageserpent-open/open-plutonium
src/test/scala/com/sageserpent/plutonium/AbstractedHistory.scala
Scala
mit
180
/** * 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...
pugna0/kafka
core/src/test/scala/unit/kafka/server/ThrottledResponseExpirationTest.scala
Scala
apache-2.0
3,252
package com.twitter.finagle.http2 import com.twitter.finagle.http.AbstractEndToEndTest import com.twitter.finagle import org.junit.runner.RunWith import org.scalatest.junit.JUnitRunner @RunWith(classOf[JUnitRunner]) class ClientFailUpgradeTest extends AbstractEndToEndTest { def implName: String = "http/2 client, ht...
BuoyantIO/finagle
finagle-http2/src/test/scala/com/twitter/finagle/http2/ClientFailUpgradeTest.scala
Scala
apache-2.0
779
package uk.gov.gds.ier.model import uk.gov.gds.ier.test.UnitTestSuite class PossibleContactAddressesTests extends UnitTestSuite { it should "generate the expected payload with postcode in the correct format" in { val possibleAddress = PossibleContactAddresses( contactAddressType = Some("uk"), ukAdd...
michaeldfallen/ier-frontend
test/uk/gov/gds/ier/model/PossibleContactAddressesTests.scala
Scala
mit
630
package org.gg.play.authentication.auth import org.specs2.mutable._ import org.gg.play.authentication.misc.Loggable import auth.BaseSpec import play.api.mvc._ import play.api.mvc.Results._ import play.api.test.Helpers._ import play.api.test.{WithApplication, FakeRequest} import play.api.test.FakeApplication /** * U...
gigiigig/play2-authentication
test/auth/OAuthSpec.scala
Scala
gpl-3.0
2,909
package akashic.storage trait Syntax { def using[A <: AutoCloseable, B](resource: A)(f: A => B): B = { try { f(resource) } finally { resource.close } } }
akiradeveloper/akashic-storage
src/main/scala/akashic/storage/Syntax.scala
Scala
apache-2.0
183
object CookieParty { def main(args: Array[String]) { val sc = new java.util.Scanner (System.in) val n = sc.nextInt() val m = sc.nextInt() val lowestMultiplier = (m.toDouble / n).ceil.toLong val result = (lowestMultiplier * n - m).abs println(result) } }
PaulNoth/hackerrank
contest/week_of_code_22/CookieParty.scala
Scala
mit
284
package scaladci package semantics import util._ class RoleBody extends DCIspecification { "Can define role method(s)" >> { @context case class Context(myRole: Data) { def trigger = myRole.bar role myRole { def bar = 2 * baz def baz = 3 * buz def buz = 4 * myRole.i ...
DCI/scaladci
coretest/src/test/Scala/scaladci/semantics/RoleBody.scala
Scala
apache-2.0
4,361
package org.jetbrains.plugins.scala package project import com.intellij.openapi.roots.libraries.PersistentLibraryKind /** * @author Pavel Fatin */ object ScalaLibraryKind extends PersistentLibraryKind[ScalaLibraryProperties]("Scala") { def createDefaultProperties() = new ScalaLibraryProperties() }
ilinum/intellij-scala
src/org/jetbrains/plugins/scala/project/ScalaLibraryKind.scala
Scala
apache-2.0
304
package play.api.mvc import java.util.UUID import org.specs2.mutable._ object BindersSpec extends Specification { val uuid = UUID.randomUUID "UUID path binder" should { val subject = implicitly[PathBindable[UUID]] "Unbind UUID as string" in { subject.unbind("key", uuid) must be_==(uuid.toString) ...
noel-yap/setter-for-catan
play-2.1.1/framework/src/play/src/test/scala/play/mvc/BindersSpec.scala
Scala
apache-2.0
1,515
package fr.igpolytech.bernads import fr.igpolytech.bernads.runtyme.BernadsApp import org.apache.log4j.{Level, Logger} import org.apache.spark.sql.SparkSession.Builder import org.apache.spark.sql.functions.desc class SandboxAnalysis(dataPath: String) extends BernadsApp { override def configure(builder: Builder): Bu...
bern-ads/DataAnalyser
src/main/scala/fr/igpolytech/bernads/SandboxAnalysis.scala
Scala
mit
2,105
package epic.sequences import epic.trees.Span import nak.data.Example /** * A tagged sequence has a sequence of tags and a sequence of words that are in * one-to-one correspondence. think POS tags etc. * @author dlwh */ case class TaggedSequence[+L, +W](tags: IndexedSeq[L], words: ...
followyourheart/epic
src/main/scala/epic/sequences/TaggedSequence.scala
Scala
apache-2.0
801
package gitbucket.core.service import gitbucket.core.model.Priority import gitbucket.core.model.Profile._ import gitbucket.core.model.Profile.profile.blockingApi._ trait PrioritiesService { def getPriorities(owner: String, repository: String)(implicit s: Session): List[Priority] = Priorities.filter(_.byReposit...
xuwei-k/gitbucket
src/main/scala/gitbucket/core/service/PrioritiesService.scala
Scala
apache-2.0
3,187
package regolic package dpllt import scala.reflect.ClassTag trait TheoryComponent { implicit val literalClassTag: ClassTag[Literal] type Literal <: AbstractLiteral abstract class AbstractLiteral { val id: Int val polInt: Int def polarity: Boolean = polInt == 1 //returns the positive literal...
regb/scabolic
src/main/scala/regolic/dpllt/TheoryComponent.scala
Scala
mit
1,784
/* * 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 ...
ahnqirage/spark
sql/core/src/main/scala/org/apache/spark/sql/streaming/DataStreamWriter.scala
Scala
apache-2.0
16,038
package monad /** * Created by ariwaranosai on 16/8/26. * */ trait Functor[F[_]] { def map[A, B](fa: F[A])(f: A => B): F[B] def distribute[A, B](fab: F[(A, B)]): (F[A], F[B]) = (map(fab)(_._1), map(fab)(_._2)) def codistribute[A, B](e: Either[F[A], F[B]]): F[Either[A, B]] = e match { case L...
ariwaranosai/FPinScala
src/main/scala/monad/Functor.scala
Scala
mit
540
package com.citypay.pan.search.nio import java.io.File import org.scalatest.FlatSpec class NioFileSystemScannerSpec extends FlatSpec { "A file path has excludes" should "exclude files in path" in { val ns = new NioFileSystemScanner(Nil, "**", exclude = List("/Users/*/Library/Application Support/Googl...
citypay/citypay-pan-search
src/test/scala/com/citypay/pan/search/nio/NioFileSystemScannerSpec.scala
Scala
mit
786
package sudoku final case class SudokuField(sudoku: Int) // This form compiles only when package.scala is commented. // This form compiles with error when package.scala is uncommented. implicit class SudokuFieldOps(val sudokuField: SudokuField) extends AnyVal { def foo: Int = ??? }
dotty-staging/dotty
tests/pos/i9290/Test.scala
Scala
apache-2.0
286
package lists import org.scalatest.FunSuite import org.junit.runner.RunWith import org.scalatest.junit.JUnitRunner /** * This class implements a ScalaTest test suite for the methods in object * `MaximumPathSum` that need to be implemented as part of this assignment. A test * suite is simply a collection of indivi...
ysalmin/scala-dynamic-programming
src/test/scala/lists/MaximumPathSumSuite.scala
Scala
gpl-2.0
1,870
/* * 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
external/docker-integration-tests/src/test/scala/org/apache/spark/sql/jdbc/v2/PostgresIntegrationSuite.scala
Scala
apache-2.0
3,340
// // Copyright 2014-2020 Paytronix Systems, 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 ...
paytronix/utils-open
interchange/json/src/main/scala/com/paytronix/utils/interchange/format/json/container.scala
Scala
apache-2.0
51,908
package com.arcusys.valamis.web.servlet.user import com.arcusys.learn.liferay.LiferayClasses.LUser import com.arcusys.valamis.certificate.model.CertificateStatuses import com.arcusys.valamis.certificate.model.goal.GoalStatistic import com.arcusys.valamis.gradebook.model.{CourseGrade, Statistic} import com.arcusys.vala...
arcusys/Valamis
valamis-portlets/src/main/scala/com/arcusys/valamis/web/servlet/user/UserResponse.scala
Scala
gpl-3.0
3,581
/** * 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 ...
tdanford/bdg-utils
utils-io/src/main/scala/org/bdgenomics/utils/io/HTTPRangedByteAccess.scala
Scala
apache-2.0
6,683
import sbt._ object LibDependencies { def apply(): Seq[ModuleID] = compile ++ test private val play26Version = "2.6.25" private val play27Version = "2.7.9" private val play28Version = "2.8.7" private val compile: Seq[ModuleID] = PlayCrossCompilation.dependencies( shared = Seq( "uk.gov.hmrc" %% "...
hmrc/mongo-lock
project/LibDependencies.scala
Scala
apache-2.0
1,644