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 xmppz.netty import org.jboss.netty.channel.{ DefaultChannelPipeline, Channel, ChannelFuture, ChannelPipeline, Channels, ChannelPipelineFactory, ChannelHandlerContext, SimpleChannelUpstreamHandler, MessageEvent, ChannelStateEvent, ExceptionEvent } import org.jboss.netty.bootstrap.ClientBoo...
vmarquez/xmppz
src/main/scala/xmppz/netty/NettyConnectionPlumber.scala
Scala
lgpl-3.0
4,255
/* * Copyright (C) Lightbend Inc. <https://www.lightbend.com> */ package play.api.data /** * Contains the Format API used by `Form`. * * For example, to define a custom formatter: * {{{ * val signedIntFormat = new Formatter[Int] { * * def bind(key: String, data: Map[String, String]) = { * stringFormat...
mkurz/playframework
core/play/src/main/scala/play/api/data/format/package.scala
Scala
apache-2.0
701
package us.feliscat.util.uima import us.feliscat.types.Time /** * @author K. Sakamoto * Created on 2017/05/25 */ package object time { implicit class TimeUtils(val repr: Time) extends AnyVal { def toYearOpt: Option[Int] = { Option(repr) map { time => time.getYear } } } }
ktr-skmt/FelisCatusZero-multilingual
libraries4jcas/src/main/scala/us/feliscat/util/uima/time/package.scala
Scala
apache-2.0
320
package org.mbari.smith import java.io.{Writer, FileWriter, BufferedWriter, File} import java.time.Instant import scala.reflect.ClassTag import scala.reflect.runtime.{universe => ru} /** * * * @author Brian Schlining * @since 2015-09-11T10:21:00 */ class CaseClassTextFileWriter(file: File, fields: List[String],...
hohonuuli/vars
vars-standalone/src/main/scala/org/mbari/smith/CaseClassTextFileWriter.scala
Scala
lgpl-2.1
903
/* * Copyright (c) 2016, Innoave.com * All rights reserved. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE * DISCLAIMED. IN...
innoave/soda
l10n/src/test/scala/com/innoave/soda/l10n/SyntaxSpec.scala
Scala
apache-2.0
2,725
/* * Copyright 2011 TomTom International BV * * 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 o...
ebowman/splitter
src/main/scala/tomtom/splitter/layer7/ResponseHandlers.scala
Scala
apache-2.0
4,202
/* * 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 ...
shaoxuan-wang/flink
flink-table/flink-table-planner-blink/src/test/scala/org/apache/flink/table/plan/rules/logical/FlinkPruneEmptyRulesTest.scala
Scala
apache-2.0
2,744
package rs.examples.counter import rs.node.core.ClusterNodeActorEvt import rs.testkit.components.TestServiceConsumer.{Open, SendSignal} import rs.testkit.components.{TestServiceConsumer, TestServiceConsumerEvt} import rs.testkit.{ConfigFromContents, ConfigReference, StandardMultiNodeSpec} import scala.concurrent.dura...
intelix/reactiveservices-examples
counter/service/src/test/scala/rs/examples/counter/CounterServiceTest.scala
Scala
apache-2.0
4,856
/* * 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 ...
Dax1n/spark-core
core/src/main/scala/org/apache/spark/shuffle/ShuffleManager.scala
Scala
apache-2.0
2,390
// Write a game that will take a tic-tac-toe board with X, O, and blank characters // and detect the winner or whether there is a tie or no winner yet. Use classes // where appropriate. type TicTacToeBoard = Array[Char] object TicTacToeScorer { private val winners = List( (0, 1, 2), (3, 4, 5), (6, 7, 8)...
ryanplusplus/seven-languages-in-seven-weeks
scala/day1/tic-tac-toe.scala
Scala
mit
806
package com.ing.baker.runtime.common import scala.util.{Failure, Success, Try} sealed abstract class BakerException(val message: String = "An exception occurred at Baker", val enum: Int, val cause: Throwable = null) extends RuntimeException(message, cause) object BakerException { // TODO this has to be rename...
ing-bank/baker
core/baker-interface/src/main/scala/com/ing/baker/runtime/common/BakerException.scala
Scala
mit
2,681
/*********************************************************************** * 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-hbase/geomesa-hbase-datastore/src/main/scala/org/locationtech/geomesa/hbase/data/HBaseConnectionPool.scala
Scala
apache-2.0
6,799
/* * 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/main/scala/io/truthencode/ddo/model/feats/ArtificerKnowledgePrefix.scala
Scala
apache-2.0
1,106
package com.sharpershape.scala.metrics case class MetricName(parts: Seq[String]) { def /(part: String): MetricName = MetricName(parts :+ part) // scalastyle:ignore def /(other: MetricName): MetricName = MetricName(parts ++ other.parts) // scalastyle:ignore } object MetricName { def apply(base: ...
SharperShape/scala-metrics
src/main/scala/com/sharpershape/scala/metrics/MetricName.scala
Scala
mit
402
/* * * 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 * distri...
flaminem/flamy
src/main/scala/com/flaminem/flamy/model/IOFormat.scala
Scala
apache-2.0
3,416
package org.jetbrains.plugins.scala.lang.completion.weighter import com.intellij.codeInsight.completion.{CompletionLocation, CompletionWeigher} import com.intellij.codeInsight.lookup.LookupElement import com.intellij.psi.util.PsiTreeUtil import com.intellij.psi.{PsiClass, PsiElement, PsiNamedElement} import com.intell...
katejim/intellij-scala
src/org/jetbrains/plugins/scala/lang/completion/weighter/ScalaByNameWeigher.scala
Scala
apache-2.0
4,956
package colang.ast.raw.expression import colang.Strategy.Result import colang.Strategy.Result.{Malformed, NoMatch, Success} import colang._ import colang.ast.raw.ParserImpl import colang.ast.raw.ParserImpl.SingleTokenStrategy import colang.issues.{Issue, Issues} import colang.tokens.Associativity.Associativity import ...
merkispavel/colang
src/main/scala/colang/ast/raw/expression/InfixOperator.scala
Scala
mit
3,651
/** * Copyright 2015-2016 Red Hat, Inc. and/or its affiliates * and other contributors as indicated by the @author tags. * * 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://...
jpkrohling/hawkular-inventory
hawkular-inventory-load-tests/src/test/scala/org/hawkular/inventory/loadtest/NTimesHawkularInventory.scala
Scala
apache-2.0
1,934
/********************************************************************************************************************** * This file is part of Scrupal, a Scalable Reactive Web Application Framework for Content Management * * ...
scrupal/scrupal
scrupal-api/src/main/scala/scrupal/api/Response.scala
Scala
apache-2.0
10,664
/* * Shadowsocks - A shadowsocks client for Android * Copyright (C) 2014 <max.c.lv@gmail.com> * * 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 y...
liuminzhi/shadowsocks-android
src/main/scala/com/github/shadowsocks/database/ProfileManager.scala
Scala
gpl-3.0
4,910
/* * 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...
wzhongyuan/BigDL
spark/dl/src/test/scala/com/intel/analytics/bigdl/torch/UnsqueezeSpec.scala
Scala
apache-2.0
5,358
package powercards import org.scalatest._ import powercards.cards.{Estate, Silver, Copper} class PileSpec extends FlatSpec with Matchers { "Pile" should "accept card of the same type" in { val pile = new Pile(() => new Copper, 10) pile.push(new Copper) pile.size shouldBe 11 } "Pile" should "not acc...
whence/powerlife
scala/powercards_oo/src/test/scala/powercards/PileSpec.scala
Scala
mit
950
package fpinscala.errorhandling import scala.{Option => _, Some => _, Either => _, _} // hide std library `Option`, `Some` and `Either`, since we are writing our own in this chapter sealed trait Option[+A] { def map[B](f: A => B): Option[B] = this match { case Some(v) => Some(f(v)) case _ => None } def...
suliatis/fpinscala
exercises/src/main/scala/fpinscala/errorhandling/Option.scala
Scala
mit
1,402
package lib import play.api.data.FormError import play.api.data.format.Formats._ import play.api.data.format.Formatter package object joda { type JodaBase = org.joda.time.base.BaseLocal type Date = org.joda.time.LocalDate type Time = org.joda.time.LocalTime type DateTime = org.joda.time.LocalDateTime laz...
fynnfeldpausch/frame
app/lib/Joda.scala
Scala
mit
3,574
package test import org.specs2.mutable._ import play.api.test._ import play.api.test.Helpers._ import play.api.mvc.Request import models._ import anorm._ class CommentModel extends Specification { "Comment spec" should { /* * MODEL TESTING */ "create" in { val fd = Comment(Id(...
mresposito/flipFeed
test/CommentModel.scala
Scala
apache-2.0
1,995
/* * Copyright (C) 2015 Stratio (http://stratio.com) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by app...
Stratio/spark-mongodb
spark-mongodb/src/main/scala/com/stratio/datasource/util/Config.scala
Scala
apache-2.0
4,678
package com.gilazaria.subsearch.controller import java.util.concurrent.Executors import com.gilazaria.subsearch.SubSearch import com.gilazaria.subsearch.core.{Arguments, AuthoritativeScanner, ZoneTransferScanner} import com.gilazaria.subsearch.core.subdomainscanner.{SubdomainScanner, SubdomainScannerArguments} import...
gavia/subsearch
src/main/scala/com/gilazaria/subsearch/controller/Controller.scala
Scala
gpl-2.0
4,633
package eu.henkelmann.actuarius import org.scalatest.junit.JUnitRunner import org.scalatest.FlatSpec import org.scalatest.matchers.ShouldMatchers import collection.SortedMap import org.junit.runner.RunWith /** * Tests basic parsers that are used by the more complex parsing steps. */ @RunWith(classOf[JUnitRunner]) ...
chenkelmann/actuarius
src/test/scala/eu/henkelmann/actuarius/BaseParsersTest.scala
Scala
bsd-3-clause
2,098
package org.dsa.core import java.text.SimpleDateFormat import java.util.Date import org.apache.log4j.{Level, Logger} import org.apache.spark.{SparkConf, SparkContext} import org.apache.spark.rdd.RDD import org.dsa.core.sa.SWNormal import org.dsa.mediator.ssw.SSWScala import org.dsa.rdd.{AlignmentRecord, AlignmentReco...
xubo245/CloudSW
src/main/scala/org/dsa/core/CloudSWATMWithTop.scala
Scala
gpl-2.0
6,399
package me.reminisce.gameboard.questions import akka.actor.Props import me.reminisce.database.MongoCollections import me.reminisce.gameboard.board.GameboardEntities.{ORDPageLikes, Order, OrderQuestion} import me.reminisce.gameboard.questions.QuestionGenerator._ import reactivemongo.api.DefaultDB import reactivemongo.a...
reminisceme/game-creator
src/main/scala/me/reminisce/gameboard/questions/OrderByPageLikes.scala
Scala
apache-2.0
2,185
/* * Copyright 2014 JHC Systems Limited * * 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...
andrewjskatz/sqlest
src/main/scala/sqlest/untyped/syntax/ColumnFinderSyntax.scala
Scala
apache-2.0
847
/* __ *\ ** ________ ___ / / ___ __ ____ Scala.js Test Suite ** ** / __/ __// _ | / / / _ | __ / // __/ (c) 2013, LAMP/EPFL ** ** __\ \/ /__/ __ |/ /__/ __ |/_// /_\ \ http://scala-js.org/ ** ** /____/\___/_/ |_/...
mdedetrich/scala-js
test-suite/shared/src/test/require-jdk7/org/scalajs/testsuite/javalib/util/concurrent/ThreadLocalRandomTest.scala
Scala
bsd-3-clause
30,836
package app import util.{LockUtil, CollaboratorsAuthenticator, JGitUtil, ReferrerAuthenticator, Notifier, Keys} import util.Directory._ import util.Implicits._ import util.ControlUtil._ import service._ import org.eclipse.jgit.api.Git import jp.sf.amateras.scalatra.forms._ import org.eclipse.jgit.transport.RefSpec imp...
ebostijancic/gitbucket
src/main/scala/app/PullRequestsController.scala
Scala
apache-2.0
20,027
class C { def f = {} } new C()./* line: 2 */f new C /* line: 2 */f println(/* resolved: false */C.f)
ilinum/intellij-scala
testdata/resolve2/qualifier/source/immediate/Class.scala
Scala
apache-2.0
105
/* * Copyright 2013-2015 Websudos, Limited. * * 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 list of c...
dan-mi-sun/phantom
phantom-dsl/src/main/scala/com/websudos/phantom/builder/query/Parts.scala
Scala
bsd-2-clause
5,523
/* * 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 ...
pgandhi999/spark
mllib/src/test/scala/org/apache/spark/ml/classification/MultilayerPerceptronClassifierSuite.scala
Scala
apache-2.0
8,900
package io.reactors package container import java.util.NoSuchElementException import org.scalacheck._ import org.scalacheck.Gen._ import org.scalacheck.Prop._ import org.scalatest._ import io.reactors.test._ import scala.collection._ class RHashMapCheck extends Properties("RHashMap") with ExtendedProperties { v...
storm-enroute/reactors
reactors-container/shared/src/test/scala/io/reactors/container/r-hash-map-tests.scala
Scala
bsd-3-clause
3,922
package scribe.writer import scribe.LogRecord import scribe.output.LogOutput import scribe.output.format.OutputFormat class CacheWriter(max: Int = CacheWriter.DefaultMax) extends Writer { private var recordCache = List.empty[LogRecord[Any]] private var outputCache = List.empty[LogOutput] override def write[M](r...
outr/scribe
core/shared/src/main/scala/scribe/writer/CacheWriter.scala
Scala
mit
782
package com.github.kabdelrahman.transtat.api import akka.actor.ActorRef import akka.http.scaladsl.server.{Route, RouteConcatenation} import com.github.kabdelrahman.transtat.bootstrap.AppConfig._ import com.github.kabdelrahman.transtat.metrics.AppWideMetrics import com.github.kabdelrahman.transtat.persistence.{CacheCon...
kabdelrahman/TranStat
src/main/scala/com/github/kabdelrahman/transtat/api/Api.scala
Scala
mit
1,279
package ch.awae.util.file import annotation.implicitNotFound import java.io.InputStream import java.io.FileInputStream import java.net.URL @implicitNotFound("No member of type class InputLike in scope for ${T}") trait InputLike[T] { def stream(t: T): InputStream } object InputLike { implicit object FileName...
ksmonkey123/mcddpui
src/main/scala/ch/awae/util/file/InputLike.scala
Scala
mit
770
package util import com.google.inject.{ AbstractModule, Provides } import com.mohiva.play.silhouette.api.util._ import com.mohiva.play.silhouette.api.{ Environment, EventBus } import com.mohiva.play.silhouette.impl.authenticators._ import com.mohiva.play.silhouette.impl.providers._ import com.mohiva.play.silhouette.im...
sne11ius/geotracker-service
app/util/GeoTrackerServiceModule.scala
Scala
gpl-3.0
4,204
package org.powlab.jeye.decode.pattern.ternary import scala.collection.mutable.ArrayBuffer import scala.collection.mutable.Map import scala.collection.mutable.Set import org.powlab.jeye.core.Exception import org.powlab.jeye.decode.expression.TernaryExpressionRef import org.powlab.jeye.decode.graph.GroupOpcodeNode imp...
powlab/jeye
src/main/scala/org/powlab/jeye/decode/pattern/ternary/TernaryOperator.scala
Scala
apache-2.0
4,415
/* * Copyright 2019 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/microservice-bootstrap
src/main/scala/uk/gov/hmrc/play/microservice/bootstrap/JsonErrorHandling.scala
Scala
apache-2.0
3,005
/* * Copyright (C) 2017 LREN CHUV for Human Brain Project * * 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...
LREN-CHUV/workflow
src/test/scala/ch/chuv/lren/woken/dao/FeaturesTableRepositoryDAOTest.scala
Scala
apache-2.0
7,066
object Skipped {
sbt/sbt
sbt-app/src/sbt-test/project/scripted-skip-incompatible/changes/Fail.scala
Scala
apache-2.0
17
package algebra package lattice import scala.{specialized => sp} /** * Heyting algebras are bounded lattices that are also equipped with * an additional binary operation `imp` (for implication, also * written as →). * * Implication obeys the following laws: * * - a → a = 1 * - a ∧ (a → b) = a ∧ b * - b ∧ ...
denisrosset/algebra
core/src/main/scala/algebra/lattice/Heyting.scala
Scala
mit
2,658
/* * Copyright 2017-2018 Iaroslav Zeigerman * * 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 ...
akkeeper-project/akkeeper
akkeeper/src/main/scala/akkeeper/container/ContainerInstanceArguments.scala
Scala
apache-2.0
1,192
/* * Copyright 2016 The BigDL Authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agr...
intel-analytics/BigDL
scala/dllib/src/main/scala/com/intel/analytics/bigdl/dllib/keras/layers/ZeroPadding2D.scala
Scala
apache-2.0
3,133
package com.arcusys.learn.controllers.api import com.arcusys.learn.ioc.Configuration import com.arcusys.learn.liferay.permission.{PermissionUtil, PortletName, ViewPermission} import com.arcusys.learn.models.request.{AdminActionType, AdminRequest} import com.arcusys.learn.web.ServletBase import com.arcusys.valamis.lrs....
ViLPy/Valamis
learn-portlet/src/main/scala/com/arcusys/learn/controllers/api/AdminApiController.scala
Scala
lgpl-3.0
3,028
// Copyright (C) 2014 Dmitry Yakimenko (detunized@gmail.com). // Licensed under the terms of the MIT license. See LICENCE for details. package net.detunized.iteratorz import scala.collection.mutable.ArrayBuffer class BufferingIterator[A](source: Iterator[A], bufferSize: Int = 1024) extends Iterator[A] { require(bu...
detunized/iteratorz
src/main/scala/BufferingIterator.scala
Scala
mit
968
/* * 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...
travisbrown/scalatest
examples/src/main/scala/org/scalatest/examples/funspec/ignore/SetSpec.scala
Scala
apache-2.0
1,025
// Copyright 2011 Foursquare Labs Inc. All Rights Reserved. package reactiverogue.core import scala.annotation.implicitNotFound // *************************************************************************** // *** Phantom types // *************************************************************************** sealed tr...
whisklabs/reactiverogue
reactiverogue-core/src/main/scala/reactiverogue/core/PhantomTypes.scala
Scala
apache-2.0
4,990
package concrete.generator.cspompatterns import concrete.CSPOMDriver import concrete.constraint.linear.SumMode._ import concrete.generator.SumGenerator import cspom.CSPOM.{constant, constantSeq, seq2CSPOMSeq} import cspom.{CSPOM, CSPOMConstraint} import cspom.compiler.{ConstraintCompiler, Delta, Functions} import cspo...
concrete-cp/concrete
src/main/scala/concrete/generator/cspompatterns/Reversed.scala
Scala
lgpl-2.1
1,563
package learnemoji import org.apache.spark.mllib.clustering.{DistributedLDAModel, LDA} import org.apache.spark.mllib.linalg.{Vector, Vectors} import org.apache.spark.{SparkConf, SparkContext} import org.apache.spark.rdd.RDD import java.time._ // val today = ZonedDateTime.now(ZoneId.of("UTC")).toString object EmojiLD...
joyoyoyoyoyo/EmojiClusterAnalysis
src/main/scala/learnemoji/EmojiLDA.scala
Scala
apache-2.0
2,986
package sampler.abc.actor.root.state import akka.actor.ActorRef import sampler.abc.actor.children._ import sampler.abc.actor.message.{MixPayload, ScoredParticles, Start, WeighedParticles} import sampler.abc.actor.root.ChildRefs import sampler.abc.actor.root.state.task.egen.{EGenUtil, EvolvingGeneration} import sampler...
tearne/Sampler
sampler-abc/src/main/scala/sampler/abc/actor/root/state/StateUtil.scala
Scala
apache-2.0
5,386
package prv.tr.webmonitor.sample import prv.tr.webmonitor._ class SampleMonitor extends Monitor { override val URL = "http://localhost/home/" private var previousData = "" this.nextInterval = 1 override def onGetResponse(data: String): Option[Notification] = { println("previous:" + previousData + ", cur...
rixiaterurun/WebMonitor
sample/prv/tr/webmonitor/sample/SampleMonitor.scala
Scala
mit
596
package org.jetbrains.plugins.scala.testingSupport.scalatest.generators import org.jetbrains.plugins.scala.testingSupport.scalatest.ScalaTestTestCase /** * @author Roman.Shein * @since 10.02.2015. */ trait FreeSpecPathGenerator extends ScalaTestTestCase { val freeSpecPathClassName = "FreeSpecPathTest" val f...
ilinum/intellij-scala
test/org/jetbrains/plugins/scala/testingSupport/scalatest/generators/FreeSpecPathGenerator.scala
Scala
apache-2.0
865
/* * Copyright 2008-2011 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 applica...
wsaccaco/lift
framework/lift-modules/lift-testkit/src/main/scala/net/liftweb/mocks/MockHttpServletRequest.scala
Scala
apache-2.0
14,912
package org.jetbrains.plugins.scala.failed.resolve import org.jetbrains.plugins.scala.PerfCycleTests import org.jetbrains.plugins.scala.base.ScalaLightCodeInsightFixtureTestAdapter import org.junit.experimental.categories.Category /** * @author Roman.Shein * @since 04.04.2016. */ @Category(Array(classOf[PerfCyc...
jastice/intellij-scala
scala/scala-impl/test/org/jetbrains/plugins/scala/failed/resolve/ClashingCaseClassesTest.scala
Scala
apache-2.0
894
/* __ *\\ ** ________ ___ / / ___ __ ____ Scala.js sbt plugin ** ** / __/ __// _ | / / / _ | __ / // __/ (c) 2013, LAMP/EPFL ** ** __\\ \\/ /__/ __ |/ /__/ __ |/_// /_\\ \\ http://scala-js.org/ ** ** /____/\\___/...
jmnarloch/scala-js
test-adapter/src/main/scala/org/scalajs/sbttestadapter/FrameworkInfo.scala
Scala
bsd-3-clause
1,112
/* * * o o o o o * | o | |\ /| | / * | o-o o--o o-o oo | | O | oo o-o OO o-o o o * | | | | | | | | | | | | | | | | \ | | \ / * O---oo-o o--O | o-o o-o-o o o o-o-o o o o-o o * | * ...
anskarl/LoMRF
src/main/scala/lomrf/util/collection/IndexPartitioned.scala
Scala
apache-2.0
2,238
package com.danielasfregola.twitter4s.http package oauth import akka.http.scaladsl.model._ import akka.http.scaladsl.model.headers.RawHeader import akka.stream.Materializer import com.danielasfregola.twitter4s.entities.{AccessToken, ConsumerToken} import com.danielasfregola.twitter4s.util.{Encoder, UriHelpers} import...
DanielaSfregola/twitter4s
src/main/scala/com/danielasfregola/twitter4s/http/oauth/OAuth1Provider.scala
Scala
apache-2.0
4,548
/* * 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
sql/core/src/main/scala/org/apache/spark/sql/execution/columnar/InMemoryRelation.scala
Scala
apache-2.0
15,399
/* * 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.javalib.util im...
SebsLittleHelpers/scala-js
test-suite/shared/src/test/scala/org/scalajs/testsuite/javalib/util/CollectionsOnCollectionsTest.scala
Scala
apache-2.0
5,459
/* * 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/main/scala/uk/gov/hmrc/ct/accounts/retriever/AccountsBoxRetriever.scala
Scala
apache-2.0
1,354
package jp.seraphr.fpinscala.monoid /** */ object WordCount { sealed trait WC case class Stub(chars: String) extends WC case class Part(lStub: String, words: Int, rStub: String) extends WC def stub(chars: String): WC = Stub(chars) def part(lStub: String, words: Int, rStub: String): WC = Part(lStub, words, ...
seraphr/fpinscala
fp-in-scala/src/main/scala/jp/seraphr/fpinscala/monoid/WordCount.scala
Scala
bsd-2-clause
1,419
import scala.tools.nsc.Settings import scala.tools.partest.ReplTest object Test extends ReplTest { override def transformSettings(s: Settings) = { s.Yreplclassbased.value = true s } def code = """ |sealed abstract class Value; object Value { | final case class Num(value: Double) extends Value ...
scala/scala
test/files/run/repl-class-based-outer-pointers.scala
Scala
apache-2.0
1,154
package hdp.Parameters import hdp.State import libnp.random.variable import libnp.random.resetable import libnp.statistics.SpecialFunctions.logGamma import java.lang.Math.log class massVar(val state: State, var prior: variable[Double], var mass: Double) extends variable[Double] with resetable[Double] { t...
lell/genetics
code/src/hdp/Parameters/massVar.scala
Scala
bsd-2-clause
811
/* * 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 ...
tillrohrmann/flink
flink-table/flink-table-planner/src/main/scala/org/apache/flink/table/planner/plan/schema/LegacyTableSourceTable.scala
Scala
apache-2.0
5,002
package io.fintrospect.util import com.twitter.finagle.Service import com.twitter.finagle.http.{Request, Response} import com.twitter.util.Future import io.fintrospect.ContentType import io.fintrospect.formats.Argo.ResponseBuilder._ import io.fintrospect.parameters.Body import io.fintrospect.renderers.ModuleRenderer i...
daviddenton/fintrospect
core/src/main/scala/io/fintrospect/util/MultiBodyType.scala
Scala
apache-2.0
1,606
package mesosphere.marathon import akka.actor.ActorSystem import akka.testkit.{ TestKit, TestProbe } import com.fasterxml.jackson.databind.ObjectMapper import mesosphere.marathon.Protos.MarathonTask import mesosphere.marathon.health.HealthCheckManager import mesosphere.marathon.state.{ PathId, AppDefinition, AppReposi...
felixb/marathon
src/test/scala/mesosphere/marathon/SchedulerActionsTest.scala
Scala
apache-2.0
4,436
/* * 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 ...
minixalpha/spark
mllib/src/main/scala/org/apache/spark/ml/feature/FeatureHasher.scala
Scala
apache-2.0
8,232
package org.jetbrains.plugins.scala.lang package completion package postfix package templates import com.intellij.codeInsight.template.postfix.templates.PostfixTemplateWithExpressionSelector import com.intellij.openapi.editor.Editor import com.intellij.psi.PsiElement import org.jetbrains.plugins.scala.lang.completion....
JetBrains/intellij-scala
scala/scala-impl/src/org/jetbrains/plugins/scala/lang/completion/postfix/templates/ScalaIntroduceVariablePostfixTemplate.scala
Scala
apache-2.0
1,143
/* * 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 ...
tillrohrmann/flink
flink-table/flink-table-planner/src/test/scala/org/apache/flink/table/planner/expressions/NonDeterministicTests.scala
Scala
apache-2.0
7,513
package org.rebeam.boxes.core import BoxTypes._ import BoxUtils._ import BoxScriptImports._ import org.scalatest.WordSpec import org.scalatest.Matchers._ class PathSpec extends WordSpec { case class End(name: Box[String]) { def asString: BoxScript[String] = name().map("End(" + _ + ")") } object End { ...
trepidacious/boxes-core
src/test/scala/org/rebeam/boxes/core/PathSpec.scala
Scala
gpl-2.0
9,048
package akka.s3 import scala.xml.NodeSeq case class User(id: String, accessKey: String, secretKey: String, name: String, email: String, displayName: String) { def modifyWith(xml: NodeSeq): User = { this.copy( name = (xml \\ "N...
akiradeveloper/FunctionalS3
src/main/scala/akka/s3/admin/User.scala
Scala
apache-2.0
1,160
package sexamples.virtualnetworking.pingpongselectors import io.netty.buffer.ByteBuf import java.net.{InetAddress, UnknownHostException} import java.util.Optional import se.sics.kompics.KompicsEvent import se.sics.kompics.network.Transport import se.sics.kompics.network.netty.serialization.{Serializer, Serializers} o...
kompics/kompics-scala
docs/src/main/scala/sexamples/virtualnetworking/pingpongselectors/NetSerializer.scala
Scala
gpl-2.0
3,778
/** * Copyright 2015 Otto (GmbH & Co KG) * * 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...
utzwestermann/schedoscope
schedoscope-core/src/main/scala/org/schedoscope/scheduler/commandline/SchedoscopeCliCommandRunner.scala
Scala
apache-2.0
8,073
/* * tuProlog - Copyright (C) 2001-2002 aliCE team at deis.unibo.it * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; either * version 2.1 of the License, or (at your option) any l...
zakski/project-soisceal
gospel-core/src/main/scala/com/szadowsz/gospel/core/listener/TheoryListener.scala
Scala
lgpl-3.0
1,891
package at.forsyte.apalache.tla.pp import at.forsyte.apalache.tla.lir.convenience.tla import at.forsyte.apalache.tla.lir._ import at.forsyte.apalache.tla.lir.oper.TlaOper import at.forsyte.apalache.tla.lir.transformations.impl.TrackerWithListeners import at.forsyte.apalache.tla.lir.transformations.standard.Incremental...
konnov/apalache
tla-pp/src/test/scala/at/forsyte/apalache/tla/pp/TestUnroller.scala
Scala
apache-2.0
5,087
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may ...
esi-mineset/spark
sql/core/src/test/scala/org/apache/spark/sql/DataFrameStatSuite.scala
Scala
apache-2.0
18,170
package xyz.hyperreal.bvm class SubSequence(val s: CharSequence, val begin: Int, val end: Int) extends CharSequence { require(0 <= begin, "begin must be greater than or equal to zero") require(begin <= end, "begin must be less than end") require(end <= s.length, "end must be less than or equal to length") def...
edadma/funl
bvm/src/main/scala/xyz/hyperreal/bvm/SubSequence.scala
Scala
mit
920
/** * Copyright 2016, deepsense.io * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed ...
deepsense-io/seahorse-workflow-executor
deeplang/src/it/scala/io/deepsense/deeplang/doperables/spark/wrappers/estimators/DecisionTreeRegressionSmokeTest.scala
Scala
apache-2.0
1,558
package com.socrata.soda.server.util.schema import com.socrata.soda.server.id.ColumnId import com.socrata.soda.server.persistence.ColumnRecordLike import java.security.MessageDigest import java.nio.charset.StandardCharsets.UTF_8 import java.util.Comparator import com.socrata.soql.types.SoQLType object SchemaHash { ...
socrata-platform/soda-fountain
soda-fountain-lib/src/main/scala/com/socrata/soda/server/util/schema/SchemaHash.scala
Scala
apache-2.0
1,612
/* * 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 ...
ArvinDevel/onlineAggregationOnSparkV2
core/src/test/scala/org/apache/spark/CacheManagerSuite.scala
Scala
apache-2.0
4,274
package hevs.especial.generator import hevs.especial.dsl.components.target.stm32stk.{DigitalInput, Stm32stkIO} /** * Command `led1` and `led2` using the same button `btn1`. * The two LEDs are switched ON when the button is pressed. * * @version 1.0 * @author Christopher Metrailler (mei@hevs.ch) */ class Sch1Cod...
hevs-isi/especial-frontend
src/test/scala/hevs/especial/generator/Sch1Code.scala
Scala
mit
898
/* * Copyright (C) 2009-2014 Typesafe Inc. <http://www.typesafe.com> */ package play.core.server.netty import org.jboss.netty.buffer.ChannelBuffers import org.jboss.netty.channel._ import org.jboss.netty.handler.codec.http._ import org.jboss.netty.handler.codec.http.HttpHeaders._ import org.jboss.netty.handler.codec...
jyotikamboj/container
pf-framework/src/play-netty-server/src/main/scala/play/core/server/netty/PlayDefaultUpstreamHandler.scala
Scala
mit
15,026
package com.inocybe.odlexplorer import akka.actor.{Status, ActorLogging, Props, Actor} import com.inocybe.odlexplorer.model.{Project, Feature, Repository} import com.typesafe.config.ConfigFactory object Receptionist { case object Crawl case class Updated(projectToFeatures: Map[String, Set[Feature]]) } // todo me...
jshamash/odl-project-explorer
src/main/scala/com/inocybe/odlexplorer/Receptionist.scala
Scala
mit
1,367
import com.fasterxml.jackson.databind.ObjectMapper import com.fasterxml.jackson.module.scala.DefaultScalaModule import com.twitter.finagle.{Service, SimpleFilter, Http} import com.twitter.finagle.stack.nilStack import com.twitter.finagle.http.{Request, Response, HttpMuxer} import com.twitter.util.{Await, Future} import...
zapov/FrameworkBenchmarks
frameworks/Scala/finagle/src/main/scala/Main.scala
Scala
bsd-3-clause
1,513
/* Copyright 2013 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...
nevillelyh/algebird
algebird-util/src/test/scala/com/twitter/algebird/util/summer/SyncSummingQueueProperties.scala
Scala
apache-2.0
1,662
package play.core.server import org.jboss.netty.channel._ import org.jboss.netty.bootstrap._ import org.jboss.netty.channel.Channels._ import org.jboss.netty.handler.codec.http._ import org.jboss.netty.channel.group._ import org.jboss.netty.handler.ssl._ import java.security._ import java.net.InetSocketAddress import...
vangav/vos_backend
play-2.2.6/framework/src/play/src/main/scala/play/core/server/NettyServer.scala
Scala
mit
12,258
package org.pegdown import java.io.{StringWriter, StringReader} import org.specs2.matcher.MatchResult import org.specs2.mutable.Specification import org.w3c.tidy.Tidy import org.parboiled.common.FileUtils import org.parboiled.support.ToStringFormatter import org.parboiled.trees.GraphUtils import ast.Node abstract cl...
vsch/pegdown
src/test/scala/org/pegdown/AbstractPegDownSpec.scala
Scala
apache-2.0
3,931
package mesosphere.marathon.integration import mesosphere.marathon.api.v2.GroupUpdate import mesosphere.marathon.integration.setup.{ IntegrationHealthCheck, IntegrationFunSuite, SingleMarathonIntegrationTest } import mesosphere.marathon.state.PathId._ import mesosphere.marathon.state.{ AppDefinition, PathId, UpgradeSt...
c089/marathon
src/test/scala/mesosphere/marathon/integration/GroupDeployIntegrationTest.scala
Scala
apache-2.0
13,732
/* * Copyright (c) 2014-2021 by The Monix Project Developers. * See the project homepage at: https://monix.io * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache...
monifu/monifu
monix-reactive/shared/src/main/scala/monix/reactive/internal/operators/DoOnStartOperator.scala
Scala
apache-2.0
2,295
package blended.streams.processor import akka.actor.{Actor, ActorRef, ActorSystem, Props} import akka.stream.scaladsl.Sink import blended.util.logging.Logger import scala.concurrent.{Future, Promise} import scala.reflect.ClassTag import scala.util.Success object Collector { def apply[T]( name: String, onC...
woq-blended/blended
blended.streams/src/main/scala/blended/streams/processor/CollectingActor.scala
Scala
apache-2.0
2,836
class Base[@specialized(Double) A](val a: A) class Derived(override val a: Double) extends Base[Double](a) object Test { def main(args: Array[String]): Unit = { val b: Base[Double] = new Derived(10) b.a println(runtime.BoxesRunTime.doubleBoxCount) val der = new Derived(10) der.a println...
lrytz/scala
test/files/specialized/td3651.scala
Scala
apache-2.0
364
/* * 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...
slamdata/slamengine
ejson/src/main/scala/quasar/ejson/TemporalKeys.scala
Scala
apache-2.0
930
package io.taric import akka.actor.{ ActorRef, Props, ActorSystem } import com.typesafe.config._ import akka.routing.RoundRobinRouter import scala.concurrent.duration._ import akka.routing.Listen /** * User: Magnus Andersson * Date: 2013-01-10 * Time: 22:39 */ object CoreApp extends App { val config = ConfigFact...
magnusart/taric.io
taric-core/src/main/scala/io/taric/CoreApp.scala
Scala
apache-2.0
391
package com.twitter.finagle.netty4.http.handler import com.twitter.finagle.http.headers.Rfc7230HeaderValidation import com.twitter.finagle.http.{BadRequestResponse, Response} import com.twitter.finagle.netty4.http.Bijections import com.twitter.finagle.stats.StatsReceiver import com.twitter.logging.Logger import io.net...
twitter/finagle
finagle-netty4-http/src/main/scala/com/twitter/finagle/netty4/http/handler/BadRequestHandler.scala
Scala
apache-2.0
3,624
/* * 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 * distrib...
fusepoolP3/p3-silk
silk-core/src/main/scala/de/fuberlin/wiwiss/silk/plugins/writer/SparqlWriter.scala
Scala
apache-2.0
5,167