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 gitbucket.core.util import gitbucket.core.service.RepositoryService import org.eclipse.jgit.api.Git import Directory._ import StringUtil._ import ControlUtil._ import scala.annotation.tailrec import scala.collection.JavaConverters._ import org.eclipse.jgit.lib._ import org.eclipse.jgit.revwalk._ import org.ecl...
intermezzo-fr/gitbucket
src/main/scala/gitbucket/core/util/JGitUtil.scala
Scala
apache-2.0
34,662
package by.pavelverk.hardwrite.http.routes import akka.http.scaladsl.model.StatusCodes import akka.http.scaladsl.server.Directives._ import by.pavelverk.hardwrite.core.auth.AuthService import de.heikoseeberger.akkahttpcirce.FailFastCirceSupport import io.circe.generic.auto._ import io.circe.syntax._ import scala.conc...
VerkhovtsovPavel/BSUIR_Labs
Master/back/akka-http-rest-master/src/main/scala/by/pavelverk/hardwrite/http/routes/AuthRoute.scala
Scala
mit
1,387
package myexample import com.example.protos.demo._ import org.apache.spark.SparkConf import org.apache.spark.SparkContext import org.apache.spark.sql.DataFrame import org.apache.spark.sql.Dataset import org.apache.spark.sql.SparkSession import org.apache.spark.sql.SQLContext import org.apache.spark.rdd.RDD import sca...
thesamet/sparksql-scalapb-test
src/main/scala/RunDemo.scala
Scala
apache-2.0
1,748
package com.eharmony.aloha.dataset import scala.language.implicitConversions package object implicits { implicit def any2string(a: Any): String = a.toString implicit def opt2string(a: Option[Any]): String = a.getOrElse("").toString }
eHarmony/aloha
aloha-core/src/main/scala/com/eharmony/aloha/dataset/implicits/package.scala
Scala
mit
244
package org.jetbrains.plugins.scala package codeInspection package packageNameInspection import com.intellij.codeInspection.{LocalQuickFix, ProblemDescriptor} import com.intellij.openapi.project.Project import org.jetbrains.plugins.scala.lang.psi.api.ScalaFile import org.jetbrains.plugins.scala.util.ScalaUtils impor...
triggerNZ/intellij-scala
src/org/jetbrains/plugins/scala/codeInspection/packageNameInspection/ScalaRenamePackageQuickFix.scala
Scala
apache-2.0
913
import breeze.linalg.DenseVector import com.jmatio.types.MLDouble import io.github.mandar2812.dynaml.DynaMLPipe.identityPipe import io.github.mandar2812.dynaml.analysis.{DifferentiableMap, PartitionedVectorField, PushforwardMap, VectorField} import io.github.mandar2812.dynaml.dataformat.MAT import io.github.mandar2812....
mandar2812/PlasmaML
vanAllen/scripts/testPSDModel.scala
Scala
lgpl-2.1
3,838
/** * Copyright 2013-2015 PayPal * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in ...
2rs2ts/cascade
http/src/test/scala/com/paypal/cascade/http/tests/resource/DevNullActor.scala
Scala
apache-2.0
835
package endpoints package documented package delegate /** * Interpreter for [[algebra.Assets]] that ignores information related * to documentation and delegates to another [[endpoints.algebra.Assets]] interpreter. */ trait Assets extends algebra.Assets with Endpoints { val delegate: endpoints.algebra.As...
Krever/endpoints
openapi/openapi/src/main/scala/endpoints/documented/delegate/Assets.scala
Scala
mit
760
package fs2 package io package file import scala.concurrent.ExecutionContext import java.nio.ByteBuffer import java.nio.channels.{AsynchronousFileChannel, FileChannel, FileLock} import cats.effect.{Effect, Sync} import cats.implicits._ /** * Provides the ability to read/write/lock/inspect a file in the effect `F`...
zaneli/fs2
io/src/main/scala/fs2/io/file/FileHandle.scala
Scala
mit
6,584
package com.getjenny.starchat.services import akka.event.{Logging, LoggingAdapter} import com.getjenny.analyzer.entities.{AnalyzersDataInternal, Context} import com.getjenny.starchat.SCActorSystem import com.getjenny.starchat.analyzer.analyzers.StarChatAnalyzer import com.getjenny.starchat.entities.io.{BayesOperatorCa...
GetJenny/starchat
src/main/scala/com/getjenny/starchat/services/BayesOperatorCacheService.scala
Scala
gpl-2.0
5,854
package mqfiletransfercoordinator.actors import java.util.UUID import scala.collection.mutable.Map import akka.actor.Actor import akka.actor.ActorLogging import akka.actor.ActorRef import akka.actor.actorRef2Scala import akka.event.LoggingReceive import mqfiletransfercoordinator.messages.CancelTransfer import mqfiletr...
antongerbracht/MQFileTransfer
MQFileTransferCoordinator/src/main/scala/mqfiletransfercoordinator/actors/TransferCoordinator.scala
Scala
apache-2.0
3,189
object test { def foo(x: Int, y: Int) = new Object } object test2 { import test.{foo => bar} val x = bar(<caret>) } //x: Int, y: Int
ilinum/intellij-scala
testdata/parameterInfo/functionParameterInfo/simple/AliasedMethod.scala
Scala
apache-2.0
140
/** * 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...
SumoLogic/shellbase
shellbase-core/src/main/scala/com/sumologic/shellbase/interrupts/KillableSingleThread.scala
Scala
apache-2.0
2,094
/* * Copyright 2014-2021 Netflix, 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...
brharrington/atlas
atlas-wiki/src/main/scala/com/netflix/atlas/wiki/pages/DesEpicViz.scala
Scala
apache-2.0
1,509
package org.libss.lift.util import net.liftweb.http.js.JsCmd /** * Created by Kaa * on 30.08.2016 at 00:35. */ trait HeadComponentsLoadable { /** * @return the map of key of pack of libraries to list of library resources to be loaded */ def headComponents: Map[String, List[String]] /** * @re...
kanischev/libss
libss-web/src/main/scala/org/libss/lift/util/HeadComponentsLoadable.scala
Scala
apache-2.0
752
/* * Scala.js (https://www.scala-js.org/) * * Copyright EPFL. * * Licensed under Apache License 2.0 * (https://www.apache.org/licenses/LICENSE-2.0). * * See the NOTICE file distributed with this work for * additional information regarding copyright ownership. */ package org.scalajs.testsuite.compiler import...
nicolasstucki/scala-js
test-suite/shared/src/test/scala/org/scalajs/testsuite/compiler/LongTest.scala
Scala
apache-2.0
145,155
package com.tvunetworks.test /** * @author RichardYao * @date 2017?4?22? */ object UseObject { def main(args: Array[String]) { println(ExtractorTest.unapply("richardyao")) val obj = UseObject(5) println(obj) obj match { /** * 当在提取器对象中使用match语句时,unapply将自动执行 */ ...
richard-yao/ScalaTest
ScalaTest/src/main/scala/com/tvunetworks/test/UseObject.scala
Scala
apache-2.0
576
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may ...
witgo/spark
core/src/test/scala/org/apache/spark/util/collection/ExternalAppendOnlyMapSuite.scala
Scala
apache-2.0
19,891
package com.twitter.util.reflect import com.twitter.util.Memoize import java.lang.reflect.{ParameterizedType, TypeVariable, Type => JavaType} import scala.reflect.api.TypeCreator import scala.reflect.runtime.universe._ object Types { private[this] val PRODUCT: Type = typeOf[Product] private[this] val OPTION: Type...
twitter/util
util-reflect/src/main/scala/com/twitter/util/reflect/Types.scala
Scala
apache-2.0
4,678
package chrome.storage.bindings import chrome.events.bindings.Event import scala.scalajs.js.annotation.JSName import scala.scalajs.js class StorageChange extends js.Object { val oldValue: js.UndefOr[js.Any] = js.native val newValue: js.UndefOr[js.Any] = js.native } class StorageArea extends js.Object { def...
amsayk/scala-js-chrome
bindings/src/main/scala/chrome/storage/bindings/Storage.scala
Scala
mit
1,106
class A { def m() { var x = new (,) } } object Main { def main(args: Array[String]) { } }
tobast/compil-petitscala
tests/syntax/bad/testfile-expr10-1.scala
Scala
gpl-3.0
90
/** * Copyright 2017 ZuInnoTe (Jörn Franke) <[email protected]> * * 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...
ZuInnoTe/spark-hadoopcryptoledger-ds
src/main/scala/org/zuinnote/spark/ethereum/block/package.scala
Scala
apache-2.0
1,527
/*********************************************************************** * 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...
jahhulbert-ccri/geomesa
geomesa-utils/src/main/scala/org/locationtech/geomesa/utils/geotools/GeometryUtils.scala
Scala
apache-2.0
5,904
package org.apache.spark.ml.tuning import com.github.fommil.netlib.F2jBLAS import org.apache.spark.annotation.Experimental import org.apache.spark.ml.evaluation.Evaluator import org.apache.spark.ml.param._ import org.apache.spark.ml.util.Identifiable import org.apache.spark.ml.{Estimator, Model} import org.apache.spar...
saurfang/spark-knn
spark-knn-examples/src/main/scala/org/apache/spark/ml/tuning/Benchmarker.scala
Scala
apache-2.0
4,878
/* * 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 ...
mahak/spark
sql/core/src/test/scala/org/apache/spark/sql/execution/ReferenceSort.scala
Scala
apache-2.0
2,677
package com.sksamuel.elastic4s import com.fasterxml.jackson.databind.ObjectMapper import com.fasterxml.jackson.module.scala.DefaultScalaModule import com.fasterxml.jackson.module.scala.experimental.ScalaObjectMapper import org.scalatest.Matchers import org.scalatest.matchers.{Matcher, MatchResult} trait JsonSugar ext...
ulric260/elastic4s
elastic4s-core-tests/src/test/scala/com/sksamuel/elastic4s/JsonSugar.scala
Scala
apache-2.0
1,665
/* * Copyright (C) 2014 - 2020 Contributors as noted in the AUTHORS.md file * * 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)...
DFASDL/dfasdl-utils
src/main/scala/org/dfasdl/utils/ElementType.scala
Scala
agpl-3.0
997
/* * The MIT License (MIT) * <p> * Copyright (c) 2017-2021 * <p> * 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,...
amannocci/streamy
core/src/test/scala/io/techcode/streamy/pipeline/PipelineManagerSpec.scala
Scala
mit
1,489
package io.getquill.context.cassandra.encoding import io.getquill.MappedEncoding trait CassandraMapperConversions extends CassandraMapperConversionsLowPriorityImplicits { implicit def cassandraIdentityMapper[Cas](implicit cas: CassandraType[Cas]): CassandraMapper[Cas, Cas] = CassandraMapper(identity) implic...
mentegy/quill
quill-cassandra/src/main/scala/io/getquill/context/cassandra/encoding/CassandraMapperConversions.scala
Scala
apache-2.0
1,105
/* * 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
core/src/main/scala/org/apache/spark/executor/CoarseGrainedExecutorBackend.scala
Scala
apache-2.0
17,168
package com.arcusys.valamis.slide.service.export import java.io.{ ByteArrayInputStream, File, FileInputStream, InputStream } import com.arcusys.learn.liferay.services.FileEntryServiceHelper import com.arcusys.valamis.file.service.FileService import com.arcusys.valamis.lesson.generator.tincan.file.TinCanRevealJSPackage...
icacic/Valamis
valamis-slide/src/main/scala/com/arcusys/valamis/slide/service/export/SlideSetPublisher.scala
Scala
gpl-3.0
16,176
/* * 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
couchbase/src/main/scala/quasar/physical/couchbase/planner/ReduceFuncPlanner.scala
Scala
apache-2.0
1,634
import sbt._ object Dependencies { val resolutionRepos = Seq( "spray repo" at "http://repo.spray.io/", "Sonatype OSS Snapshots" at "https://oss.sonatype.org/content/repositories/snapshots" ) //Versions val myScalaVersion = "2.10.4" val akkaVersion = "2.2.0-RC1" val sprayVersion = "1.2-M8" val s...
MagnusAk78/dynamic-checklist-server
tools/project/Dependencies.scala
Scala
gpl-3.0
1,971
/* Copyright 2016 Tunalytics Foundation 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...
tunalytics/loader
transformer/src/main/scala/org/tunalytics/loader/transformer/topology/signals/Signal.scala
Scala
apache-2.0
948
/* * Part of NDLA learningpath-api. * Copyright (C) 2016 NDLA * * See LICENSE * */ package no.ndla.learningpathapi.integration import com.zaxxer.hikari.{HikariConfig, HikariDataSource} import no.ndla.learningpathapi.LearningpathApiProperties._ trait DataSource { val dataSource: HikariDataSource } object Dat...
NDLANO/learningpath-api
src/main/scala/no/ndla/learningpathapi/integration/DataSource.scala
Scala
gpl-3.0
761
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may ...
Intel-bigdata/OAP
oap-native-sql/core/src/test/scala/org/apache/spark/sql/execution/datasources/parquet/ParquetIOSuite.scala
Scala
apache-2.0
44,035
package com.arcusys.valamis.lesson.generator.util object ResourceHelpers { def fetchResources(sourceText: String) = { // extract all images from question text ("""(?i)(?<=SCORMData/)(.+?)(?=")""".r findAllIn sourceText).toArray } def skipContextPathURL(source: String) = { // skip context-path ""...
ViLPy/Valamis
valamis-lesson-generator/src/main/scala/com/arcusys/valamis/lesson/generator/util/ResourceHelpers.scala
Scala
lgpl-3.0
533
package tu.model.knowledge.domain import tu.model.knowledge._ import tu.model.knowledge.annotator.AnnotatedPhrase import tu.exception.UnexpectedException import org.slf4j.LoggerFactory /** * @author max * Date: 8/30/12 * Time: 7:54 AM */ class ConceptTag(val _content: TypedKLine[Concept], ...
keskival/2
model.knowledge/src/main/scala/tu/model/knowledge/domain/ConceptTag.scala
Scala
gpl-3.0
2,469
package pl.touk.nussknacker.engine.management.streaming import org.apache.flink.api.scala._ import org.scalatest.{FunSuite, Matchers} import pl.touk.nussknacker.engine.{ModelData, ProcessingTypeConfig} import pl.touk.nussknacker.engine.api.ProcessVersion import pl.touk.nussknacker.engine.api.process.{ProcessId, Proces...
TouK/nussknacker
engine/flink/management/src/it/scala/pl/touk/nussknacker/engine/management/streaming/FlinkStreamingDeploymentManagerQueryableStateTest.scala
Scala
apache-2.0
2,377
/* * Copyright 2015 Tsukasa Kitachi * * 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...
kxbmap/sbt-jooq
codegen/src/main/scala/sbtjooq/codegen/internal/VariableExpander.scala
Scala
apache-2.0
1,262
package com.tritondigital.counters import java.util.concurrent.TimeUnit import _root_.akka.actor.{Actor, ActorSystem, Props} import _root_.akka.pattern.Patterns import com.codahale.metrics._ import com.tritondigital.counters.codahale.CodahaleMetricsConverters import scala.collection.JavaConverters._ import scala.con...
tritondigital/tritondigital-counters
src/main/scala/com/tritondigital/counters/SimpleMetrics.scala
Scala
apache-2.0
5,463
object Test { val LIMIT = 10 def test1: Unit = { var d = 2 var i = 0 // avoid infinite loops while (d < LIMIT && i < LIMIT) { lazy val b = d + 1 d = b i += 1 println("test1: " + d) } } def test2: Unit = { var d = 2 var i = 0 while (true) { lazy val b =...
yusuke2255/dotty
tests/run/t3877.scala
Scala
bsd-3-clause
1,284
/* * Copyright 2016 Combined Conditional Access Development, 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 requir...
ccadllc/cedi-config
core/src/test/scala/com/ccadllc/cedi/config/CompilationTest.scala
Scala
apache-2.0
1,420
package ee.cone.c4gate import com.typesafe.scalalogging.LazyLogging import ee.cone.c4actor.Types.SrcId import ee.cone.c4actor._ import ee.cone.c4actor.QProtocol.S_Firstborn import ee.cone.c4assemble.Types.{Each, Values} import ee.cone.c4assemble._ import ee.cone.c4di.c4multi import ee.cone.c4proto.ToByteString @c4ass...
conecenter/c4proto
base_examples/src/main/scala/ee/cone/c4gate/HiRateTxApp.scala
Scala
apache-2.0
1,477
package com.gilt.handlebars.scala.parser import scala.util.parsing.combinator._ import scala.util.parsing.input.CharSequenceReader object HandlebarsGrammar { protected val grammar = new HandlebarsGrammar(("{{","}}")) def apply(input: String): grammar.ParseResult[Program] = grammar(input) def path(input: String)...
QiaoBuTang/handlebars.scala
src/main/scala/com/gilt/handlebars/scala/parser/HandlebarsGrammar.scala
Scala
apache-2.0
4,992
/*********************************************************************** * Copyright (c) 2013-2019 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...
elahrvivaz/geomesa
geomesa-utils/src/main/scala/org/locationtech/geomesa/utils/cache/SoftThreadLocalCache.scala
Scala
apache-2.0
1,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 ...
wgpshashank/spark
core/src/main/scala/spark/package.scala
Scala
apache-2.0
1,597
/* * 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 ...
irudyak/ignite
modules/scalar/src/test/scala/org/apache/ignite/scalar/tests/ScalarAffinityRoutingSpec.scala
Scala
apache-2.0
2,521
/*********************************************************************** * Copyright (c) 2013-2022 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...
locationtech/geomesa
geomesa-utils/src/main/scala/org/locationtech/geomesa/utils/io/fs/FileSystemDelegate.scala
Scala
apache-2.0
4,225
/* * 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
frontend/src/main/scala/quasar/sql/ScopedExpr.scala
Scala
apache-2.0
1,904
package com.asto.dop.core.module.collect import com.asto.dop.core.entity.VisitEntity import scala.collection.mutable /** * 访问实体保存事件 */ class VisitEntitySaveEvent extends mutable.Publisher[VisitEntity]{ def pub(entity:VisitEntity) = publish(entity) }
zj-lingxin/dop-core
src/main/scala/com/asto/dop/core/module/collect/CollectEvent.scala
Scala
mit
274
/*********************************************************************** * Copyright (c) 2013-2019 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...
elahrvivaz/geomesa
geomesa-index-api/src/main/scala/org/locationtech/geomesa/index/api/QueryPlan.scala
Scala
apache-2.0
9,301
package in.suhj.eridown import org.scalatest.FunSuite class ListTest extends FunSuite { test("A paragraph\\nwith two lines.\\n\\n indented code\\n\\n> A block quote.") { assert(Parser.render("""A paragraph |with two lines. | ...
raon0211/eridown
src/test/scala/in/suhj/eridown/ListTest.scala
Scala
mit
14,697
/* * 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 ...
irudyak/ignite
modules/spark/src/test/scala/org/apache/ignite/spark/IgniteOptimizationStringFuncSpec.scala
Scala
apache-2.0
10,284
package edu.gemini.ags.conf import edu.gemini.ags.api.AgsMagnitude.{MagnitudeCalc, MagnitudeTable} import edu.gemini.ags.gems.GemsMagnitudeTable import edu.gemini.spModel.core.Site import edu.gemini.spModel.core.Site.{GN, GS} import edu.gemini.spModel.gemini.altair.AltairParams.Mode._ import edu.gemini.spModel.gemini...
arturog8m/ocs
bundle/edu.gemini.ags/src/main/scala/edu/gemini/ags/conf/ProbeLimitsTable.scala
Scala
bsd-3-clause
3,595
package scalan.graphs import scalan.primitives.PrimitiveExamples /** * Created by afilippov on 2/17/15. */ trait GraphExamples extends GraphsDsl with PrimitiveExamples { lazy val fromAndToAdj = fun { in: Rep[(NestedCollectionFlat[Int],NestedCollectionFlat[Double])] => val links = in._1 val edge_vals...
scalan/scalan
graphs/src/test/scala/scalan/graphs/GraphExamples.scala
Scala
apache-2.0
7,583
/* * Copyright 2015 Webtrends (http://www.webtrends.com) * * See the LICENCE.txt file distributed with this work for additional * information regarding copyright ownership. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * Yo...
mjwallin1/wookiee-spray
src/test/scala/com/webtrends/harness/component/spray/directive/MetricsDirectivesSpec.scala
Scala
apache-2.0
1,896
/** * Copyright (c) 2013-2015 Patrick Nicolas - Scala for Machine Learning - All rights reserved * * The source code in this file is provided by the author for the sole purpose of illustrating the * concepts and algorithms presented in "Scala for Machine Learning". It should not be used to * build commercial ap...
batermj/algorithm-challenger
books/cs/machine-learning/scala-for-machine-learning/1rst-edition/original-src-from-the-book/src/main/scala/org/scalaml/workflow/module/package.scala
Scala
apache-2.0
1,120
package com.tutuur.ducksoup.meta /** * @author Zale */ case class Image(id: String, md5: String, width: Int, height: Int, format: String) { assert(format == format.toUpperCase) assert(id.length == 8) } object Image { val IdLength = 8 def tupled = Function.tupled(Image.apply _) }
Thiross/ducksoup
web/src/main/scala/com/tutuur/ducksoup/meta/Image.scala
Scala
gpl-3.0
308
/* * Copyright 2013 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...
Hocdoc/sandoc
src/main/scala/laika/io/Input.scala
Scala
apache-2.0
3,593
package singleton import java.util.UUID /** * Lazy Singleton class * @author lmignot */ class LazySingleton private extends Singleton { private val id: String = UUID.randomUUID.toString override def getId: String = id } /** * LazySingleton concept * <p> * The private instance is initialised as null ...
BBK-PiJ-2015-67/sdp-portfolio
exercises/week07/src/main/scala/singleton/LazySingleton.scala
Scala
unlicense
544
/* * 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 ...
dotunolafunmiloye/spark
core/src/test/scala/org/apache/spark/scheduler/TaskResultGetterSuite.scala
Scala
apache-2.0
4,571
package records.benchmark import org.scalameter.api._ import scala.tools.nsc.util._ import records.Rec object RecordsCompileTimeBenhcmark extends RecordsBenchmarkSuite with TypecheckingBenchmarkingSuite { // rec is referenced from the generated code val rec = Create.Rec(Create.maxSize) def source(fPos: Int) = ...
scala-records/scala-records-benchmarks
src/test/scala/records/benchmark/RecordsCompileTimeBenchmark.scala
Scala
bsd-3-clause
987
package org.jetbrains.plugins.scala package codeInspection.etaExpansion import com.intellij.codeInspection.{ProblemHighlightType, ProblemsHolder} import com.intellij.openapi.project.Project import com.intellij.psi.PsiElement import com.intellij.psi.util.PsiTreeUtil import org.jetbrains.plugins.scala.codeInspection.col...
double-y/translation-idea-plugin
src/org/jetbrains/plugins/scala/codeInspection/etaExpansion/ConvertibleToMethodValueInspection.scala
Scala
apache-2.0
4,485
package moe.pizza.evewho import org.http4s.client.blaze.PooledHttp1Client /** * Created by Andi on 20/01/2016. */ object EvewhoExample extends App { val evewho = new Evewho() implicit val client = PooledHttp1Client() val paistis = evewho.allianceList(1983809465).unsafePerformSync println(paistis) prin...
xxpizzaxx/pizza-eveapi
src/main/scala/moe/pizza/evewho/EvewhoExample.scala
Scala
mit
389
package edu.neu.coe.scala.numerics /** * @author scalaprof */ trait Valuable[X] { def get: X }
rchillyard/Scalaprof
Numerics/src/main/scala/edu/neu/coe/scala/numerics/Valuable.scala
Scala
gpl-2.0
99
/* * ****************************************************************************** * * Copyright (C) 2013 Christopher Harris (Itszuvalex) * * [email protected] * * * * This program is free software; you can redistribute it and/or * * modify it under the terms of the GNU General Public License * * as p...
Itszuvalex/Femtocraft-alpha-1
src/main/java/com/itszuvalex/femtocraft/common/gui/DisplaySlot.scala
Scala
gpl-2.0
1,614
/* * FolderFrameImpl.scala * (Mellite) * * Copyright (c) 2012-2022 Hanns Holger Rutz. All rights reserved. * * This software is published under the GNU Affero General Public License v3+ * * * For further information, please contact Hanns Holger Rutz at * [email protected] */ package de.sciss.mellite.im...
Sciss/Mellite
app/src/main/scala/de/sciss/mellite/impl/document/FolderFrameImpl.scala
Scala
agpl-3.0
6,567
/* * Copyright 2015 * * 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, ...
TouK/influxdb-reporter
core/src/main/scala/influxdbreporter/core/metrics/push/Timer.scala
Scala
apache-2.0
2,018
object Spawn { def main(args: Array[String]): Unit = System.exit(1) }
mdedetrich/sbt
sbt/src/sbt-test/run/error/changes/RunExplicitFailure.scala
Scala
bsd-3-clause
71
package scryetek.vecmath @inline final class Vec3(var x: Float, var y: Float, var z: Float) { @inline def this() = this(0, 0, 0) @inline def set(x: Float = this.x, y: Float = this.y, z: Float = this.z) = { this.x = x this.y = y this.z = z this } @inline def set(v: Vec3): Vec3 = set(...
mseddon/vecmath
shared/src/main/scala/scryetek/vecmath/Vec3.scala
Scala
bsd-3-clause
4,971
/* * Copyright 2015 Netflix, 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 t...
rspieldenner/atlas
atlas-chart/src/main/scala/com/netflix/atlas/chart/graphics/TimeSeriesSpan.scala
Scala
apache-2.0
1,219
package spray.servlet31 import spray.servlet.{Initializer, ConnectorSettings} import javax.servlet.http.{HttpServlet, HttpServletResponse, HttpServletRequest} import akka.actor.{ActorRef, ActorSystem} import akka.event.{Logging, LoggingAdapter} import akka.spray.RefUtils import javax.servlet.{AsyncEvent, AsyncListener...
lukiano/spray-servlet31
src/main/scala/spray/servlet31/Servlet31ConnectorServlet.scala
Scala
mit
4,272
package ca.uwaterloo.gsd.rangeFix import java.io.OutputStreamWriter import java.lang.Runtime import java.io.InputStreamReader import java.io.BufferedReader import java.io.BufferedWriter import java.io.Writer import java.io.FileWriter import scala.collection._ trait TraceWriter { def write(content:String...
matachi/rangeFix
src/main/scala/fixGeneration/Z3.scala
Scala
mit
7,603
package tryp import macros._ import annotation.StaticAnnotation class export extends StaticAnnotation { def macroTransform(annottees: Any*) = macro ExportAnn.process } class exportNames extends StaticAnnotation { def macroTransform(annottees: Any*) = macro ExportNamesAnn.process } class exportTypes extends Sta...
tek/pulsar
macros/src/annotations.scala
Scala
mit
844
package models import models.daos._ import play.api.db.slick.DatabaseConfigProvider import javax.inject.Inject import scala.concurrent.Future class AdminUsers @Inject()(protected val dbConfigProvider: DatabaseConfigProvider) extends DAOSlick { import driver.api._ private val Users = slickUsers def all() = db...
hectorgool/fara
app/models/AdminUsers.scala
Scala
apache-2.0
343
/* * This file is part of the ToolXiT project. * * 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 t...
gnieh/toolxit-bibtex
src/main/scala/toolxit/bibtex/StringUtils.scala
Scala
apache-2.0
5,091
package hoconspring import java.{lang => jl, util => ju} import com.typesafe.config._ import org.springframework.beans.factory.annotation.Qualifier import org.springframework.beans.factory.config.ConstructorArgumentValues.ValueHolder import org.springframework.beans.factory.config.{BeanDefinitionHolder, ConstructorAr...
ghik/hocon-spring
src/main/scala/hoconspring/HoconBeanDefinitionReader.scala
Scala
apache-2.0
15,143
package com.avsystem.scex.parsing import com.avsystem.commons.misc.{AbstractValueEnum, AbstractValueEnumCompanion, EnumCtx} import scala.annotation.tailrec import scala.collection.immutable.SortedMap final class Binding(implicit enumCtx: EnumCtx) extends AbstractValueEnum object Binding extends AbstractValueEnumComp...
AVSystem/scex
scex-core/src/main/scala/com/avsystem/scex/parsing/PString.scala
Scala
mit
3,411
/* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you ...
GJL/flink
flink-table/flink-table-planner-blink/src/test/scala/org/apache/flink/table/planner/runtime/stream/sql/OverWindowITCase.scala
Scala
apache-2.0
36,421
package de.uniulm.dds.defaultimpl import java.util.Comparator import de.uniulm.dds.base.Variable /** * The parameter type for contexts in defaultimpl * Created by Felix on 03.06.2014. * * @param variableOrder the comparator that specifies variable order. For variables <code>a</code> and <code>b</code>, ...
uulm-ai/scadd
src/main/scala/de/uniulm/dds/defaultimpl/Parameters.scala
Scala
mit
1,039
package TAPL import TAPL.Lib._ trait KParser[K] { val pK: Parser[K] } trait ETKParser[E, T, K] extends ETParser[E, T] with KParser[K] object Omega { trait Alg[E, T, K] { def KnStar(): K def KnArr(k1: K, k2: K): K def TyAll(x: String, k: K, t: T): T def TySome(x: String, k: K, t: T): T ...
hy-zhang/parser
Scala/Parser/src/TAPL/FullOmega.scala
Scala
bsd-3-clause
3,154
package org.hammerlab.guacamole.reads import htsjdk.samtools.SAMRecord import org.hammerlab.genomics.reference.{ContigName, Locus} /** * Details of the mate read alignment * @param contigName Contig/chromosome of the mate read * @param start 0-based start position of the mate read * @param inferredInsertSize Inse...
hammerlab/guacamole
src/main/scala/org/hammerlab/guacamole/reads/MateAlignmentProperties.scala
Scala
apache-2.0
1,306
package mesosphere.marathon package raml /** * Conversion from [[mesosphere.marathon.state.KillSelection]] to [[mesosphere.marathon.raml.KillSelection]] and vice versa. */ trait KillSelectionConversion { implicit val ramlKillSelectionRead = Reads[KillSelection, state.KillSelection] { case KillSelection.Olde...
guenter/marathon
src/main/scala/mesosphere/marathon/raml/KillSelectionConversion.scala
Scala
apache-2.0
1,088
package com.twitter.zipkin.sampler import java.util.Random import com.twitter.app.App import com.twitter.finagle.Service import com.twitter.util.Await.{ready, result} import com.twitter.util.Future import com.twitter.util.Time.now import com.twitter.zipkin.Constants import com.twitter.zipkin.common.{Annotation, Endpo...
prat0318/zipkin
zipkin-sampler/src/test/scala/com/twitter/zipkin/sampler/AdaptiveSamplerTest.scala
Scala
apache-2.0
4,062
package com.joescii.typeprog object TList2Spec { type Nat1 = NatN[Nat0] type Nat2 = NatN[Nat1] type Nat3 = NatN[Nat2] type Nat6 = NatN[NatN[NatN[Nat3]]] type L = Nat1 :: Nat2 :: Nat3 :: TNil implicitly[L#reduce =:= Nat6] }
joescii/type-prog-impress
src/test/scala/com.joescii.typeprog/TList2Spec.scala
Scala
apache-2.0
237
/* Copyright 2012-2015 Micronautics Research Corporation. * * 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...
mslinn/awslib_scala
src/main/scala/com/micronautics/aws/CloudFront.scala
Scala
mit
15,266
import wop.game.{Point, WopState} import wop.game.WopState.{InProgress, Player} import wop.game.ai.WopSolver import scala.annotation.tailrec object RunSolver extends App { implicit case object Time extends WopState.TimeProvider { def currentTime: Long = 0 } @tailrec def loop(state: WopState, whoAI: Player)...
ognick/wizards-of-portal
core/src/main/scala/RunSolver.scala
Scala
gpl-3.0
1,688
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may ...
EvilMcJerkface/kudu
java/kudu-backup/src/main/scala/org/apache/kudu/backup/KuduBackupRDD.scala
Scala
apache-2.0
6,093
/* * Copyright 2016 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...
ahudspith-equalexperts/ct-calculations
src/main/scala/uk/gov/hmrc/ct/ct600/v2/B8.scala
Scala
apache-2.0
894
/* * 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 ...
apache/flink
flink-table/flink-table-planner/src/main/scala/org/apache/flink/table/planner/expressions/ordering.scala
Scala
apache-2.0
1,643
package debop4s.core import java.lang.{Double => JDouble, Float => JFloat, Integer => JInt, Long => JLong} import debop4s.core.utils.Strings /** * CorePackageFunSuite * @author [email protected] */ class CorePackageFunSuite extends AbstractCoreFunSuite { test("int convert") { "1".asInt shouldBe 1 ...
debop/debop4s
debop4s-core/src/test/scala/debop4s/core/CorePackageFunSuite.scala
Scala
apache-2.0
2,721
package com.jancy.mateusz.sug.free import com.jancy.mateusz.sug.free.impl.custom.{Registration, Runner} object Main extends App { val result = Runner.run(Registration.createAccount("mateusz", "jancy")) println(result) }
mateuszjancy/scalaz-free-in-example
src/main/scala/com/jancy/mateusz/sug/free/Main.scala
Scala
apache-2.0
226
package com.cloudray.scalapress.plugin.ecommerce.controller.admin import org.springframework.stereotype.Controller import org.springframework.web.bind.annotation.{ModelAttribute, RequestMethod, RequestMapping} import org.springframework.beans.factory.annotation.Autowired import scala.Array import javax.servlet.http.Ht...
vidyacraghav/scalapress
src/main/scala/com/cloudray/scalapress/plugin/ecommerce/controller/admin/ShoppingPluginController.scala
Scala
apache-2.0
1,642
/* * Copyright 2015 PayPal * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in ...
tutufool/squbs
squbs-httpclient/src/main/scala/org/squbs/httpclient/package.scala
Scala
apache-2.0
1,462
package de.fuberlin.wiwiss.silk.execution import de.fuberlin.wiwiss.silk.entity.{Path, Link, Index, Entity} import de.fuberlin.wiwiss.silk.linkagerule.LinkageRule import de.fuberlin.wiwiss.silk.cache.Partition import de.fuberlin.wiwiss.silk.util.DPair import methods.MultiBlock import scala.math.{min, max, abs} /** *...
fusepoolP3/p3-silk
silk-core/src/main/scala/de/fuberlin/wiwiss/silk/execution/ExecutionMethod.scala
Scala
apache-2.0
1,537
package com.webtrends.harness.http import java.net.{HttpURLConnection, URL} import akka.actor.{Props, ActorSystem} import akka.testkit.TestKit import com.webtrends.harness.TestKitSpecificationWithJUnit class InternalHttpSpec extends TestKitSpecificationWithJUnit(ActorSystem("test")) with InternalHttpClient { val p...
davis20/wookiee
wookiee-core/src/test/scala/com/webtrends/harness/http/InternalHttpSpec.scala
Scala
apache-2.0
859
import org.scalatest.{Matchers, FunSuite} /** @version 1.0.0 */ class EtlTest extends FunSuite with Matchers { test("a single letter") { Etl.transform(Map(1 -> Seq("A"))) should be(Map("a" -> 1)) } test("single score with multiple letters") { pending Etl.transform(Map(1 -> Seq("A", "E", "I", "O", "...
exercism/xscala
exercises/practice/etl/src/test/scala/EtlTest.scala
Scala
mit
1,218
/* * konpare * Copyright (C) 2015 Alexander Fefelov <https://github.com/alexanderfefelov> * * 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 ...
alexanderfefelov/konpare
src/main/scala/com/github/alexanderfefelov/konpare/syntax/subject/config/JumboFrame.scala
Scala
gpl-3.0
1,410
package ecommerce.sales.app import akka.actor._ import akka.japi.Util.immutableSeq import scala.collection.immutable.Seq import scala.concurrent.duration.{FiniteDuration, MILLISECONDS} trait SalesFrontConfiguration { this: Actor => object httpService { val interface = appConfig.getString("http-service.int...
odd/ddd-leaven-akka-v2
sales/write-front/src/main/scala/ecommerce/sales/app/SalesFrontConfiguration.scala
Scala
mit
714