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 controllers import java.nio.file.Paths import javax.inject.{Inject, Named} import controllers.GitHubUser._ import play.api.Logger import play.api.i18n.MessagesApi import play.api.libs.json.Json import play.api.libs.ws.WSClient import play.api.mvc.{Action, Controller} import scala.concurrent.{ExecutionContext...
DmytroOrlov/devgym
server/app/controllers/GitHubUser.scala
Scala
apache-2.0
2,137
/** * Copyright 2013 Gianluca Amato * * This file is part of JANDOM: JVM-based Analyzer for Numerical DOMains * JANDOM is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or ...
rubino22/JDBeta
extended/src/test/ppl/it/unich/jandom/domains/numerical/ppl/BoxDoubleBenchmark.scala
Scala
lgpl-3.0
4,775
/* * Copyright 2008 WorldWide Conferencing, LLC * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable la...
andreum/liftweb
lift/src/main/scala/net/liftweb/http/rest/XMLApiHelper.scala
Scala
apache-2.0
2,859
package text.vector import text.parser.{SentenceSplitter, Tokenizer} import scala.collection.mutable /** * @author ynupc * Created on 2016/05/22 */ object FrequencyVectorGenerator extends VectorGenerator[FrequencyVector] { override def getVectorFromText(text: String): FrequencyVector = { getVecto...
ynupc/scalastringcourseday6
src/main/scala/text/vector/FrequencyVectorGenerator.scala
Scala
apache-2.0
1,493
/* Copyright 2009-2011 Jay Conrod * * This file is part of Tungsten. * * Tungsten 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 of * the License, or (at your option) any late...
jayconrod/tungsten
core/src/main/scala/tungsten/Loader.scala
Scala
gpl-2.0
4,741
package sangria.execution.deferred import java.util.concurrent.atomic.AtomicInteger import sangria.ast import sangria.execution.{DeferredWithInfo, Executor} import sangria.macros._ import sangria.schema._ import sangria.util.{FutureResultSupport, Pos} import sangria.util.SimpleGraphQlSupport._ import scala.concurrent...
sangria-graphql/sangria
modules/core/src/test/scala/sangria/execution/deferred/DeferredResolverSpec.scala
Scala
apache-2.0
9,072
package org.bitcoins.spvnode.serializers.messages.control import org.bitcoins.core.util.BitcoinSUtil import org.scalatest.{FlatSpec, MustMatchers} /** * Created by chris on 8/26/16. */ class RawFilterAddMessageSerializerTest extends FlatSpec with MustMatchers { //https://bitcoin.org/en/developer-reference#filt...
Christewart/bitcoin-s-spv-node
src/test/scala/org/bitcoins/spvnode/serializers/messages/control/RawFilterAddMessageSerializerTest.scala
Scala
mit
909
/** * Copyright 2015 Thomson Reuters * * Licensed under the Apache License, Version 2.0 (the “License”); you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or ag...
nruppin/CM-Well
server/cmwell-grid/src/main/scala/k/grid/monitoring/ActorsCrawler.scala
Scala
apache-2.0
2,005
package org.jetbrains.plugins.scala.testingSupport.scalatest.singleTest import org.jetbrains.plugins.scala.testingSupport.scalatest.generators.FlatSpecGenerator /** * @author Roman.Shein * @since 20.01.2015. */ trait FlatSpecSingleTestTest extends FlatSpecGenerator { val flatSpecTestPath = List("[root]", "FlatSp...
triggerNZ/intellij-scala
test/org/jetbrains/plugins/scala/testingSupport/scalatest/singleTest/FlatSpecSingleTestTest.scala
Scala
apache-2.0
764
/* * 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/test/scala/com/intel/analytics/bigdl/dllib/utils/tf/loaders/SliceLoadTFSpec.scala
Scala
apache-2.0
1,219
/* * Copyright 2011 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applica...
valotrading/zeromq-scala-binding
src/main/scala/org/zeromq/ZeroMQLibrary.scala
Scala
apache-2.0
29,807
package com.softwaremill.macwire.packages.child import com.softwaremill.macwire._ import com.softwaremill.macwire.packages.A trait ChildModule { val a = wire[A] }
guersam/macwire
tests2/src/test/scala/com/softwaremill/macwire/packages/child/ChildModule.scala
Scala
apache-2.0
167
package com.eigengo.lift.exercise import java.nio.ByteBuffer import org.scalatest.{FlatSpec, Matchers} import scodec.bits.ByteVector import scalaz.{-\\/, \\/-} class MultiPacketDecoderTest extends FlatSpec with Matchers { import com.eigengo.lift.exercise.RichArray._ /// writes payload of the given size at sloc...
eigengo/lift
server/exercise/src/test/scala/com/eigengo/lift/exercise/MultiPacketDecoderTest.scala
Scala
apache-2.0
4,354
/*********************************************************************** * Copyright (c) 2013-2017 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 ...
spandanagrawal/geomesa
geomesa-hbase/geomesa-hbase-datastore/src/main/scala/org/locationtech/geomesa/hbase/filters/HBaseZFilters.scala
Scala
apache-2.0
2,222
package blended.jms.bridge.internal import akka.actor.{Actor, ActorRef, ActorSystem, Props} import akka.stream.Materializer import blended.container.context.api.ContainerIdentifierService import blended.jms.bridge._ import blended.jms.bridge.internal.BridgeController.{AddConnectionFactory, RemoveConnectionFactory} imp...
lefou/blended
blended.jms.bridge/src/main/scala/blended/jms/bridge/internal/BridgeController.scala
Scala
apache-2.0
6,045
package test object Main { def main (args: Array[String]) { //server app imitation while (true){ Thread.sleep(1000L) } } }
joescii/sbt-native-packager
src/sbt-test/rpm/test-executableScriptName/src/main/scala/test/Main.scala
Scala
bsd-2-clause
145
/* * Copyright (c) 2012-2019 Snowplow Analytics Ltd. All rights reserved. * * This program is licensed to you under the Apache License Version 2.0, * and you may not use this file except in compliance with the Apache License Version 2.0. * You may obtain a copy of the Apache License Version 2.0 at http://www.apach...
RetentionGrid/snowplow
3-enrich/scala-common-enrich/src/main/scala/com.snowplowanalytics.snowplow.enrich/common/enrichments/registry/WeatherEnrichment.scala
Scala
apache-2.0
7,498
package codecheck.github.transport.asynchttp20 import org.asynchttpclient.{AsyncHttpClient, Response => AsyncHttpResponse, AsyncCompletionHandler, BoundRequestBuilder} import codecheck.github.transport.{Transport, Request, Response, CompletionHandler} class AsyncHttp20Transport(client: AsyncHttpClient) extends Trans...
code-check/github-api-scala
src/main/scala/codecheck/github/transport/asynchttp20/AsyncHttp20Transport.scala
Scala
mit
1,797
/* * 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 ...
sshcherbakov/incubator-geode
gemfire-spark-connector/gemfire-spark-connector/src/test/scala/unittest/io/pivotal/gemfire/spark/connector/GemFireDStreamFunctionsTest.scala
Scala
apache-2.0
3,605
/* * 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 ...
hwstreaming/flink
flink-streaming-scala/src/main/scala/org/apache/flink/streaming/api/scala/function/util/ScalaProcessWindowFunctionWrapper.scala
Scala
apache-2.0
6,014
package org.jetbrains.plugins.scala package debugger.evaluation.evaluator import java.io.File import java.net.URI import java.util import com.intellij.codeInsight.CodeInsightUtilCore import com.intellij.debugger.engine.evaluation._ import com.intellij.debugger.engine.evaluation.expression.{ExpressionEvaluator, Modifi...
triggerNZ/intellij-scala
src/org/jetbrains/plugins/scala/debugger/evaluation/evaluator/ScalaCompilingEvaluator.scala
Scala
apache-2.0
11,631
package typeclass.syntax import typeclass.Functor object functor { // implicit class FunctorOps }
julien-truffaut/Typeclass
exercise/src/main/scala/typeclass/syntax/functor.scala
Scala
mit
101
/* * 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. */ // GENERATED CODE: DO NOT EDIT...
lrytz/scala
src/library/scala/Function16.scala
Scala
apache-2.0
2,241
package pl.touk.nussknacker.engine.api.context.transformation sealed trait NodeDependencyValue case class OutputVariableNameValue(name: String) extends NodeDependencyValue case class TypedNodeDependencyValue(value: Any) extends NodeDependencyValue
TouK/nussknacker
components-api/src/main/scala/pl/touk/nussknacker/engine/api/context/transformation/NodeDependencyValue.scala
Scala
apache-2.0
250
/* * Copyright (c) 2002-2018 "Neo Technology," * Network Engine for Objects in Lund AB [http://neotechnology.com] * * This file is part of Neo4j. * * Neo4j is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundatio...
HuangLS/neo4j
community/cypher/cypher-compiler-2.3/src/main/scala/org/neo4j/cypher/internal/compiler/v2_3/helpers/CollectionSupport.scala
Scala
apache-2.0
3,342
package com.twitter_typesafe.config.impl import org.junit.Assert._ import org.junit.Test class ConfigNodeTest extends TestUtils { private def singleTokenNodeTest(token: Token) { val node = configNodeSingleToken(token); assertEquals(node.render(), token.tokenText()) } private def keyNodeT...
twitter-forks/config
config/src/test/scala/com/typesafe/config/impl/ConfigNodeTest.scala
Scala
apache-2.0
12,100
package org.bowlerframework.view.scalate import reflect.BeanProperty import org.bowlerframework.{RequestScope, Request} import collection.mutable.HashMap /** * Retrieves a Template based on a request and it's contents, headers and/or path. * the order of layouts and templates added matters, as the selectors are hel...
rkpandey/Bowler
core/src/main/scala/org/bowlerframework/view/scalate/TemplateRegistry.scala
Scala
bsd-3-clause
1,134
package com.xenopsconsulting.gamedayapi.batch import org.slf4j.LoggerFactory import net.noerd.prequel._ import net.noerd.prequel.DatabaseConfig import scala.Some import com.xenopsconsulting.gamedayapi.Game object MySQLDatabaseImporter { private val _log = LoggerFactory.getLogger(getClass) val database = Database...
ecopony/scala-gameday-api
src/main/scala/com/xenopsconsulting/gamedayapi/batch/MySQLDatabaseImporter.scala
Scala
mit
5,383
package net.dinkla.lbnn.geom /** * Created by dinkla on 19/06/15. */ trait Point[T] { def dimension(): Int def ith(i: Int): T //type P //val origin: P }
jdinkla/location-based-nearest-neighbours
src/main/scala/net/dinkla/lbnn/geom/Point.scala
Scala
apache-2.0
177
package myUtils import java.util.UUID import com.github.tminglei.slickpg.PgRangeSupportUtils import play.api.data.format.Formats import play.api.data.format.Formatter import play.api.data.FormError import com.vividsolutions.jts.io.{WKTReader, WKTWriter} import com.vividsolutions.jts.geom.Geometry import play.api.libs....
hardmettle/slick-postgress-samples
app/myUtils/MyFormats.scala
Scala
apache-2.0
4,105
package group.matsen import scala.collection.Bag package object phylohmc { type Pattern = Map[Taxon, Int] val Pattern = Map type Patterns = Bag[Pattern] val Patterns = Bag }
armanbilge/phyloHMC
src/main/scala/group/matsen/phylohmc/package.scala
Scala
agpl-3.0
186
/** * 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...
Mszak/kafka
core/src/main/scala/kafka/producer/async/DefaultEventHandler.scala
Scala
apache-2.0
18,171
package edu.gemini.osgi.tools import java.io._ import scala.io.Source object FileUtils { /** List the files immediately contained in a parent directory. */ def listFiles(parentDir: File): List[File] = if (parentDir.isDirectory) parentDir.listFiles.toList else Nil /** List of immediate child directories...
arturog8m/ocs
project/src/main/scala/edu/gemini/osgi/tools/FileUtils.scala
Scala
bsd-3-clause
2,297
package com.wavesplatform.it.sync.transactions import com.typesafe.config.Config import com.wavesplatform.account.AddressScheme import com.wavesplatform.api.http.ApiError.StateCheckFailed import com.wavesplatform.it.NodeConfigs import com.wavesplatform.it.api.SyncHttpApi._ import com.wavesplatform.it.api.TransactionIn...
wavesplatform/Waves
node-it/src/test/scala/com/wavesplatform/it/sync/transactions/ReissueTransactionSuite.scala
Scala
mit
4,650
package com.themillhousegroup.gatsby.stubby import com.dividezero.stubby.core.model.StubExchange import java.util.concurrent.atomic.AtomicBoolean import scala.concurrent.Future import com.typesafe.scalalogging.slf4j.Logging trait CanAddStubExchanges { /** * @return true if the exchange was added */ def addE...
themillhousegroup/gatsby
src/main/scala/com/themillhousegroup/gatsby/stubby/StubbyTraits.scala
Scala
mit
2,002
/* * 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/pensions-lifetime-allowance-frontend
app/config/PlaContext.scala
Scala
apache-2.0
1,188
/* This file is part of Rimbot. Rimbot is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. Rimbot is distributed in the hope...
martijnhoekstra/rimbot
src/main/scala/Colony.scala
Scala
agpl-3.0
4,333
/* * 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 ...
HuaweiBigData/carbondata
integration/spark-common-test/src/test/scala/org/apache/carbondata/integration/spark/testsuite/dataload/TestLoadDataGeneral.scala
Scala
apache-2.0
7,354
package scala.c.engine class RadixSort extends StandardTest { "radix sort test 1" should "print the correct results" in { val code = """ //#include <stdio.h> #include <limits.h> //#include <stdlib.h> typedef unsigned uint; #define swap(a, b) { tmp = a; a = ...
bdwashbu/cEngine
tests/scala/c/engine/SortingTest.scala
Scala
apache-2.0
16,658
/* * @author Genc Mazlami * * Copyright 2013 University of Zurich * * 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...
gmazlami/dcop-maxsum
src/main/scala/com/signalcollect/dcop/evaluation/maxsum/MaxSumConflictAggregationOperation.scala
Scala
apache-2.0
1,914
package pac import im.mange.jetboot.Renderable import im.mange.jetboot.comet.Subscriber import im.mange.jetboot.js.JsCmdFactory import jsa.comet.LoadFromDatabase import jsa.model.Detail import scala.xml.{Elem, Text} object PanelSelectorAgentLocator extends Hashable { val panelSelectorContent = "panelSelectorConten...
gosubpl/justsampleapp
src/main/scala/pac/PanelSelectorAgent.scala
Scala
mit
976
package org.jetbrains.plugins.scala package editor.smartEnter.fixers import com.intellij.openapi.editor.Editor import com.intellij.psi.PsiElement import com.intellij.psi.util.PsiTreeUtil import org.jetbrains.plugins.scala.editor.smartEnter.ScalaSmartEnterProcessor import org.jetbrains.plugins.scala.lang.psi.api.expr.{...
LPTK/intellij-scala
src/org/jetbrains/plugins/scala/editor/smartEnter/fixers/ScalaMissingWhileBodyFixer.scala
Scala
apache-2.0
1,299
package pipelines.text import breeze.linalg.SparseVector import evaluation.MulticlassClassifierEvaluator import loaders.NewsgroupsDataLoader import nodes.learning.NaiveBayesEstimator import nodes.nlp._ import nodes.stats.TermFrequency import nodes.util.{CommonSparseFeatures, MaxClassifier} import org.apache.spark.{Spa...
tomerk/keystone
src/main/scala/pipelines/text/NewsgroupsPipeline.scala
Scala
apache-2.0
2,615
package ch.epfl.yinyang import scala.reflect.macros.blackbox.Context trait YYConfig { val config: Map[String, Any] val direct: Boolean = config("direct").asInstanceOf[Boolean] val debug: Int = config("debug").asInstanceOf[Int] val shortenDSLNames: Boolean = config("shortenDSLNames").asInstanceOf[Boolean] va...
scala-yinyang/scala-yinyang
components/yin-yang/src/YYConfig.scala
Scala
bsd-3-clause
965
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may ...
hhbyyh/spark
sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/optimizer/JoinReorderSuite.scala
Scala
apache-2.0
14,240
package edu.gemini.sp.vcs2 import edu.gemini.pot.sp.version.VersionMap import edu.gemini.sp.vcs2.ProgramLocationSet.{Both, LocalOnly, Neither, RemoteOnly} import edu.gemini.sp.vcs2.VcsAction._ import edu.gemini.sp.vcs2.VcsFailure.NeedsUpdate import edu.gemini.spModel.core.SPProgramID import edu.gemini.spModel.obscomp....
spakzad/ocs
bundle/edu.gemini.sp.vcs/src/test/scala/edu/gemini/sp/vcs2/VcsSpec.scala
Scala
bsd-3-clause
9,725
/* * Copyright 2010 Guardian News and Media * * 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 a...
guardian/guardian-configuration
src/main/scala/com.gu.conf/GuardianConfigurationStrategy.scala
Scala
apache-2.0
3,913
/* Deduction Tactics Copyright (C) 2012-2017 Raymond Dodge 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 progra...
rayrobdod/boardGame
View/src/main/scala/CoordinateFunction.scala
Scala
gpl-3.0
3,806
def rotate[A](startIdx: Int, inputAry: List[A]): List[A] = { val rotatedElems = if (startIdx < 0) inputAry.take(inputAry.size + startIdx) else inputAry.take(startIdx) val nochangeElems = if (startIdx < 0) inputAry.drop(inputAry.size + startIdx) else inputAry.drop(startIdx) nochangeElems ::: rotatedElems } /*...
zuqqhi2/s-99
p19.scala
Scala
bsd-3-clause
1,010
/* * Copyright 2013 http4s.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://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to i...
http4s/http4s
servlet/src/main/scala/org/http4s/servlet/AbstractAsyncListener.scala
Scala
apache-2.0
995
/* * Copyright 2018 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/paac-frontend
app/form/Year2015Form.scala
Scala
apache-2.0
2,264
/* Copyright 2015 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 law or agreed to in writing, software distr...
cchepelov/scalding
scalding-core/src/test/scala/com/twitter/scalding/typed/RequireOrderedSerializationTest.scala
Scala
apache-2.0
2,417
package exam.national_center_test.xml.choice import exam.national_center_test.xml.choice.collcetion.{ChoiceCollection, ChoiceCollectionType, ChoiceSet, ChoiceSingleton} /** * <pre> * Created on 5/24/15. * </pre> * @author K.Sakamoto */ object ChoiceType extends Enumeration { val None, Binary, Image...
ktr-skmt/FelisCatusZero
src/main/scala/exam/national_center_test/xml/choice/ChoiceType.scala
Scala
apache-2.0
4,138
package debop4s.core.utils import java.util.concurrent.atomic.AtomicInteger import java.util.concurrent.{CountDownLatch => JavaCountDownLatch, TimeUnit} import debop4s.core.AbstractCoreFunSuite import debop4s.core.concurrent.Asyncs import org.mockito.Mockito._ import scala.concurrent.ExecutionContext.Implicits.globa...
debop/debop4s
debop4s-core/src/test/scala/debop4s/core/utils/MemorizeFunSuite.scala
Scala
apache-2.0
2,819
package helpers import scala.concurrent._ import scala.concurrent.duration._ import scala.language.postfixOps /** * @author zepeng.li@gmail.com */ trait BootingProcess { def onStart[T](awaitable: Awaitable[T]): T = { Await.result(awaitable, 1 minute) } }
lizepeng/app.io
modules/models/app/helpers/BootingProcess.scala
Scala
apache-2.0
269
package org.bitcoins.core.protocol.ln import org.bitcoins.core.number.{UInt5, UInt8} import org.bitcoins.core.protocol.ln.util.LnUtil import org.bitcoins.core.util.{Bech32, SeqWrapper} import org.bitcoins.crypto.NetworkElement import scodec.bits.ByteVector import scala.annotation.tailrec import scala.collection.mutab...
bitcoin-s/bitcoin-s
core/src/main/scala/org/bitcoins/core/protocol/ln/LnTaggedFields.scala
Scala
mit
5,398
/** * Copyright (c) 2016, Anthony Anderson<Illyohs> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * Redistributions of source code must retain the above copyright notice, this * li...
Illyohs/CivilMagicks
src/main/scala/us/illyohs/civilmagiks/common/core/util/SigilBase.scala
Scala
bsd-2-clause
1,952
package com.giyeok.jparser.examples.metalang3 import com.giyeok.jparser.examples.MetaLang3Example object AllMetaLang3Examples { val examples: Seq[MetaLang3Example] = List( SimpleExamples.examples, JoinExamples.examples, ClassRelExamples.examples, OptionalExamples.examples, PExprExamples.examples...
Joonsoo/moon-parser
examples/src/main/scala/com/giyeok/jparser/examples/metalang3/AllMetaLang3Examples.scala
Scala
mit
379
package com.shocktrade.client.models.contest import com.shocktrade.common.models.contest.PositionLike import scala.scalajs.js /** * Represents a Position model * @author Lawrence Daniels <lawrence.daniels@gmail.com> */ class Position(var _id: js.UndefOr[String], var symbol: js.UndefOr[String], ...
ldaniels528/shocktrade.js
app/client/angularjs/src/main/scala/com/shocktrade/client/models/contest/Position.scala
Scala
apache-2.0
829
package com.socrata.bq.config import com.socrata.datacoordinator.common.DataSourceConfig import com.socrata.thirdparty.typesafeconfig.ConfigClass import com.typesafe.config.{Config, ConfigUtil} import scala.collection.JavaConverters._ class BBQStoreConfig(config: Config, root: String) extends ConfigClass(config, root...
socrata-platform/soql-bigquery-adapter
store-bq/src/main/scala/com/socrata/bq/config/BBQStoreConfig.scala
Scala
apache-2.0
871
package rere.sasl.scram.cache.impl import org.scalatest.{Matchers, WordSpec} class ConcurrentSaltedPasswordCacheTest extends WordSpec with Matchers { "ConcurrentSaltedPasswordCache" should { "cache salted passwords" in { val cache = new ConcurrentSaltedPasswordCache() cache.get("secret", "salt", 4...
pbaun/rere
modules/sasl/src/test/scala/rere/sasl/scram/cache/impl/ConcurrentSaltedPasswordCacheTest.scala
Scala
apache-2.0
677
/** * 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 ...
allenday/adam
adam-core/src/test/scala/org/bdgenomics/adam/rdd/CoverageSuite.scala
Scala
apache-2.0
5,394
import org.apache.spark.{SparkContext, SparkConf} /** * Created by ma on 15-1-27. */ class QueryT22 extends BaseQuery{ System.setProperty("spark.cores.max",String.valueOf(ParamSet.cores)) val conf = new SparkConf() conf.setAppName("TPCH-Q22") val sc = new SparkContext(conf) val sqlContext = new org.ap...
f7753/spark-SQL-tpch-test-tool
QueryT22.scala
Scala
apache-2.0
3,413
/* * Copyright (C) 2005, The Beangle Software. * * 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 3 of the License, or * (at your option) any later version. * * This...
beangle/cdi
spring/src/main/scala/org/beangle/cdi/spring/config/SpringBindRegistry.scala
Scala
lgpl-3.0
8,440
//伴生对象 class Fraction(n: Int, d: Int){ val m = n + d } object Fraction{ //伴生对象的apply方法 def apply(n: Int, d: Int) = new Fraction(n ,d) } object ApplyTest1{ def main(args: Array[String]){ val result1 = Fraction(2,4) val result2 = Fraction(3,5) println(result1.m * result2.m) ...
PengLiangWang/Scala
Apply/ApplyTest1.scala
Scala
gpl-3.0
348
/* * Copyright 2015 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...
liquidarmour/http-verbs
src/main/scala/uk/gov/hmrc/play/http/ws/WSGet.scala
Scala
apache-2.0
1,061
object Dependencies { val akkaV = "2.4.2" val akkaStreamV = "2.4.2" val scalatestV = "2.2.4" }
fehmicansaglam/tepkin
project/Dependencies.scala
Scala
apache-2.0
101
package de.fosd.typechef.typesystem import de.fosd.typechef.featureexpr.FeatureExprFactory import de.fosd.typechef.parser.c._ import org.junit.runner.RunWith import org.scalatest.{Matchers, FunSuite} import org.scalatest.junit.JUnitRunner @RunWith(classOf[JUnitRunner]) class IntegerSecurityTest extends FunSuite with ...
mbeddr/TypeChef
CTypeChecker/src/test/scala/de/fosd/typechef/typesystem/IntegerSecurityTest.scala
Scala
lgpl-3.0
2,901
package org.tinydvr.db import org.squeryl.KeyedEntity import org.squeryl.annotations._ class Configuration extends KeyedEntity[String] { def id = key @Column(name = "key") // the configuration key var key: String = _ @Column(name = "value") // the configuration value var value: String = _ }
lou-k/tinydvr
src/main/scala/org/tinydvr/db/Configuration.scala
Scala
gpl-3.0
307
package com.softwaremill.bootzooka.email.application import org.scalatest.{FlatSpec, Matchers} class EmailTemplatingEngineSpec extends FlatSpec with Matchers { behavior of "splitToContentAndSubject" val engine = new EmailTemplatingEngine it should "throw exception on invalid template" in { intercept[Excep...
aywengo/bootzooka
backend/src/test/scala/com/softwaremill/bootzooka/email/application/EmailTemplatingEngineSpec.scala
Scala
apache-2.0
1,119
package de.htwg.zeta.server.actor import java.util.UUID import java.util.concurrent.TimeUnit import javax.inject.Singleton import scala.collection.concurrent.TrieMap import scala.concurrent.Future import scala.concurrent.duration.Duration import scala.concurrent.ExecutionContext.Implicits.global import scala.util.Fai...
Zeta-Project/zeta
api/server/app/de/htwg/zeta/server/actor/TransientTokenCache.scala
Scala
bsd-2-clause
3,105
package reflectdoc.tools.nsc package doc package html package page package diagram import java.io.InputStream import java.io.OutputStream import java.io.InputStreamReader import java.io.OutputStreamWriter import java.io.BufferedWriter import java.io.BufferedReader import scala.sys.process._ import scala.concurrent.Syn...
VladUreche/reflectdoc
components/core/src/reflectdoc/tools/nsc/doc/html/page/diagram/DotRunner.scala
Scala
bsd-3-clause
7,937
//====================================================================================================================== // Facsimile: A Discrete-Event Simulation Library // Copyright © 2004-2020, Michael J Allen. // // This file is part of Facsimile. // // Facsimile is free software: you can redistribute it and/or mod...
MichaelJAllen/facsimile
facsimile-util/src/test/scala/org/facsim/util/test/Generator.scala
Scala
lgpl-3.0
5,472
package net.chwthewke.scala.protobuf.plugin.templates import net.chwthewke.scala.protobuf.plugin._ import net.chwthewke.scala.protobuf.plugin.interface._ import net.chwthewke.scala.protobuf.plugin.interface.field._ import net.chwthewke.scala.protobuf.plugin.symbols._ import net.chwthewke.scala.protobuf.plugin.syntax._...
chwthewke/scala-protobuf
scala-protobuf-plugin-core/src/main/scala/net/chwthewke/scala/protobuf/plugin/templates/TemplatesProcess.scala
Scala
apache-2.0
4,049
package buck import scala.reflect.macros.blackbox import scala.language.experimental.macros import scala.annotation.StaticAnnotation object helloMacro { def impl(c: blackbox.Context)(annottees: c.Expr[Any]*): c.Expr[Any] = { import c.universe._ import Flag._ val result = { annottees.map(_.tree).to...
raviagarwal7/buck
test/com/facebook/buck/jvm/scala/testdata/scala_macros/Macros.scala
Scala
apache-2.0
721
package at.logic.gapt.prooftool import scala.swing._ import at.logic.gapt.proofs.lk.base._ import java.awt.Color import at.logic.gapt.proofs.lk.{ ExistsRightRule, ForallLeftRule } /** * * Created by marty on 3/26/14. */ class DrawSingleSequentInference( var orientation: Orientation.Value ) extends ScrollPane { ...
gisellemnr/gapt
src/main/scala/at/logic/gapt/prooftool/DrawSingleSequentInference.scala
Scala
gpl-3.0
3,923
/* * 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 ...
SnappyDataInc/spark
core/src/main/scala/org/apache/spark/SparkContext.scala
Scala
apache-2.0
107,961
/* * Copyright (C) 2009-2017 Lightbend Inc. <https://www.lightbend.com> */ package play.api.mvc import java.security.cert.X509Certificate import play.api.http.{ HeaderNames, MediaRange, MediaType } import play.api.i18n.Lang import play.api.libs.typedmap.{ TypedKey, TypedMap } import play.api.mvc.request._ import s...
Shruti9520/playframework
framework/src/play/src/main/scala/play/api/mvc/RequestHeader.scala
Scala
apache-2.0
12,708
/* * Copyright (C) 11/06/13 Romain Reuillon * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Affero General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * This pr...
ISCPIF/PSEExperiments
simpuzzle-src/models/simpoplocal/src/main/scala/fr/geocites/simpoplocal/SimpopLocal.scala
Scala
agpl-3.0
897
/* * 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 ...
ajaysaini725/spark
sql/hive/src/main/scala/org/apache/spark/sql/hive/HiveExternalCatalog.scala
Scala
apache-2.0
56,359
package com.mz.training.common.services.pagination import akka.actor.{Actor, ActorLogging, ActorRef, Props} import com.mz.training.common.repositories.{SelectCount, SelectPaging} import com.mz.training.common.services.{GetAllPagination, GetAllPaginationResult} import com.mz.training.domains.EntityId import scala.conc...
michalzeman/angular2-training
akka-http-server/src/main/scala/com/mz/training/common/services/pagination/GetAllPaginationActor.scala
Scala
mit
3,740
package net.sansa_stack.inference.utils.graph import java.util.Comparator import com.google.common.collect.ComparisonChain import org.apache.jena.graph.Node /** * Definition of edge equivalence used for graph isomorphism detection. * * @author Lorenz Buehmann */ class EdgeEquivalenceComparator extends Compar...
SANSA-Stack/SANSA-RDF
sansa-inference/sansa-inference-common/src/main/scala/net/sansa_stack/inference/utils/graph/EdgeEquivalenceComparator.scala
Scala
apache-2.0
1,180
/* * Copyright 2015 Renaud Bruneliere * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agree...
bruneli/scalaopt
core/src/test/scala/com/github/bruneli/scalaopt/core/linear/PrimalTableauSpec.scala
Scala
apache-2.0
3,992
package org.jetbrains.plugins.scala.settings.annotations import com.intellij.psi.{PsiElement, PsiModifierListOwner} import org.jetbrains.plugins.scala.lang.psi.api.expr.ScUnderscoreSection import org.jetbrains.plugins.scala.lang.psi.api.statements.params.ScParameter import org.jetbrains.plugins.scala.lang.psi.api.stat...
loskutov/intellij-scala
src/org/jetbrains/plugins/scala/settings/annotations/Declaration.scala
Scala
apache-2.0
4,139
/* * Copyright 2014 Cisco 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 law or agr...
foundation-runtime/orchestration
src/test/scala/com/cisco/oss/foundation/orchestration/scope/vmware/VMWareTest.scala
Scala
apache-2.0
11,470
/* * Copyright 2019 Spotify AB. * * 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 ...
regadas/scio
scio-extra/src/main/scala/com/spotify/scio/extra/bigquery/AvroConverters.scala
Scala
apache-2.0
1,821
package org.zouzias.spark.lucenerdd.aws.dfvslucene import org.apache.spark.sql.{Row, SQLContext, SaveMode, SparkSession} import org.apache.spark.SparkConf import org.zouzias.spark.lucenerdd.aws.utils._ import org.zouzias.spark.lucenerdd.facets.FacetedLuceneRDD import org.zouzias.spark.lucenerdd._ import org.apache.spa...
zouzias/spark-lucenerdd-aws
src/main/scala/org/zouzias/spark/lucenerdd/aws/dfvslucene/DataFrameVsLuceneRDDExample.scala
Scala
apache-2.0
2,908
object SCL5661 { val y: String = "text" def failfunc(x: Map[String, Int]) = 1 def failfunc(x: String) = "text" /*start*/failfunc(Map(y -> 1))/*end*/ } //Int
triggerNZ/intellij-scala
testdata/typeInference/bugs5/SCL5661.scala
Scala
apache-2.0
167
/* * 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 ...
jianran/spark
sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/catalog/SessionCatalogSuite.scala
Scala
apache-2.0
59,156
package com.haskforce.codeInsight.visibleModules import com.haskforce.highlighting.annotation.external.GhcMod import com.haskforce.utils.ExecUtil import com.intellij.openapi.module.{Module, ModuleUtilCore} import com.intellij.psi.PsiFile class GhcModVisibleModulesProvider( module: Module, workDir: String ) extend...
carymrobbins/intellij-haskforce
src/com/haskforce/codeInsight/visibleModules/GhcModVisibleModulesProvider.scala
Scala
apache-2.0
874
/* * stateless-future-util * Copyright 2014 深圳岂凡网络有限公司 (Shenzhen QiFun Network Corp., LTD) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LIC...
Atry/stateless-future-util
src/main/scala/com/qifun/statelessFuture/util/CancellablePromise.scala
Scala
apache-2.0
2,805
package stir.pancake sealed trait Direction { val column: Int; val row: Int } case object Up extends Direction { val column: Int = 0; val row: Int = 1 } case object Down extends Direction { val column: Int = 0; val row: Int = -1 } case object Left extends Direction { val column: Int = -1; val row: Int = 0 } c...
zaklogician/silver-pancake
src/stir/pancake/Directions.scala
Scala
bsd-3-clause
475
/** * Copyright (c) 2002-2012 "Neo Technology," * Network Engine for Objects in Lund AB [http://neotechnology.com] * * This file is part of Neo4j. * * Neo4j is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundati...
dksaputra/community
cypher/src/main/scala/org/neo4j/cypher/internal/commands/expressions/Null.scala
Scala
gpl-3.0
1,364
package org.jetbrains.plugins.scala package codeInspection package collections import com.intellij.testFramework.EditorTestUtil.{SELECTION_END_TAG => END, SELECTION_START_TAG => START} /** * Ignat Loskutov */ abstract class ExistsForallReplaceTest extends OperationsOnCollectionInspectionTest { override protect...
JetBrains/intellij-scala
scala/scala-impl/test/org/jetbrains/plugins/scala/codeInspection/collections/ExistsForallReplaceTest.scala
Scala
apache-2.0
1,862
package org.cg.scala.dhc.domelments import java.util.Optional import org.cg.spelstuff.{FilterResult, ParseResult, Spel} import org.springframework.expression.spel.SpelNode import scala.collection.JavaConverters._ case class FlatItemAttributeNSpelItem(refItemName: String, attributeName: String, ln: String, spelIdent...
curiosag/datahubchecker
datahubchecker-utility/src/main/scala/org/cg/scala/dhc/domelments/SpelItem.scala
Scala
unlicense
3,481
package com.sksamuel.scapegoat.inspections.exception import com.sksamuel.scapegoat.InspectionTest /** @author Marconi Lanna */ class CatchFatalTest extends InspectionTest { override val inspections = Seq(new CatchFatal) "catch _ fatal exception" - { "should report warning" in { val code1 = """object ...
sksamuel/scalac-scapegoat-plugin
src/test/scala/com/sksamuel/scapegoat/inspections/exception/CatchFatalTest.scala
Scala
apache-2.0
1,598
import sbt._ import sbt.Keys._ import releaseit.ReleaseItPlugin._ object build extends Build { // ensure we use proper encoding private val encoding: String = sys.props("file.encoding") assert(encoding == "UTF-8", s"File encoding must be UTF-8 but was $encoding") val commonScalacOptions = Seq( "-target:...
pvillega/sbt-template
project/build.scala
Scala
mit
4,786
import core.CultureHubPlugin import models.OrganizationConfiguration import play.api.Play import play.api.Play.current import test.Specs2TestContext import util.OrganizationConfigurationHandler import play.api.test._ import play.api.test.Helpers._ /** * * @author Manuel Bernhardt <bernhardt.manuel@gmail.com> */ c...
delving/culture-hub
test/PlatformSpec.scala
Scala
apache-2.0
877
/* Copyright (C) 2008-2014 University of Massachusetts Amherst. This file is part of "FACTORIE" (Factor graphs, Imperative, Extensible) http://factorie.cs.umass.edu, http://github.com/factorie Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with...
patverga/factorie
src/main/scala/cc/factorie/variable/CategoricalDomain.scala
Scala
apache-2.0
13,974
package com.github.ldaniels528.trifecta.messages.codec import scala.util.Try /** * Message Decoder * @author lawrence.daniels@gmail.com */ trait MessageDecoder[T] { /** * Decodes the binary message into a typed object * @param message the given binary message * @return a decoded message wrapped in a Tr...
ldaniels528/trifecta
src/main/scala/com/github/ldaniels528/trifecta/messages/codec/MessageDecoder.scala
Scala
apache-2.0
574