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 scala.meta.tests package trees import munit._ import scala.meta._ class TreeSuite extends FunSuite { test("Name.unapply") { assert(Name.unapply(q"a").contains("a")) assert(Name.unapply(t"a").contains("a")) } }
scalameta/scalameta
tests/shared/src/test/scala/scala/meta/tests/trees/TreeSuite.scala
Scala
bsd-3-clause
232
package io.scalac.amqp.impl import com.google.common.primitives.Ints.saturatedCast import com.rabbitmq.client._ import io.scalac.amqp.Delivery import org.reactivestreams.{Subscriber, Subscription} import scala.annotation.tailrec import scala.collection.immutable.Queue import scala.concurrent.ExecutionContext.Implicit...
ScalaConsultants/reactive-rabbit
src/main/scala/io/scalac/amqp/impl/QueueSubscription.scala
Scala
apache-2.0
4,097
package org.jetbrains.plugins.scala.extensions import com.intellij.psi.PsiElement /** * Pavel Fatin */ object Children { def unapplySeq(e: PsiElement): Some[Seq[PsiElement]] = Some(e.getChildren.toSeq) }
ilinum/intellij-scala
src/org/jetbrains/plugins/scala/extensions/Children.scala
Scala
apache-2.0
209
package mesosphere.marathon package core.task.jobs import java.time.Clock import mesosphere.marathon.core.leadership.LeadershipModule import mesosphere.marathon.core.task.jobs.impl.{ ExpungeOverdueLostTasksActor, OverdueTasksActor } import mesosphere.marathon.core.task.termination.KillService import mesosphere.marath...
guenter/marathon
src/main/scala/mesosphere/marathon/core/task/jobs/TaskJobsModule.scala
Scala
apache-2.0
1,263
package knot.core.dispatch import scala.concurrent.{ExecutionContext, ExecutionContextExecutorService} object ForkJoinDispatcher { def apply(): Dispatcher = { implicit val ec: ExecutionContextExecutorService = ExecutionContext.fromExecutorService(null) new AbstractDispatcher() {} } }
defvar/knot
knot-core/src/main/scala/knot/core/dispatch/ForkJoinDispatcher.scala
Scala
mit
299
package com.github.novamage.svalidator.validation.simple.internals case class SimpleValidationRuleStructureContainer[A, B](validationExpression: (B, A) => Boolean, conditionalValidation: Option[A => Boolean], ...
NovaMage/SValidator
src/main/scala/com/github/novamage/svalidator/validation/simple/internals/SimpleValidationRuleStructureContainer.scala
Scala
mit
556
/* * Copyright 2017 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 ...
paypal/squbs
squbs-unicomplex/src/test/scala/org/squbs/unicomplex/MultipleUnicomplexTest.scala
Scala
apache-2.0
4,540
package org.bowlerframework.view.scuery import org.bowlerframework.view.scalate.ClasspathTemplateResolver import xml.{XML, NodeSeq} import java.io.{IOException, StringReader} import java.util.concurrent.ConcurrentHashMap import org.bowlerframework.{RequestResolver, RequestScope} /** * Created by IntelliJ IDEA. * Us...
rkpandey/Bowler
core/src/main/scala/org/bowlerframework/view/scuery/MarkupContainer.scala
Scala
bsd-3-clause
3,084
/* * 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-2.0 * ...
adarro/ddo-calc
subprojects/common/ddo-core/src/main/scala/io/truthencode/ddo/model/effect/EffectParameterBuilder.scala
Scala
apache-2.0
5,734
package lcs import leon._ import mem._ import lang._ import annotation._ import instrumentation._ import invariant._ import collection._ /** * A memoized implementation of computing the length of the * longest common subsequence between two sequences. Here, * the sequences are represented as integer arrays * whose ...
regb/leon
testcases/benchmarks/steps/LongestCommonSubsequence.scala
Scala
gpl-3.0
4,137
package com.akka.ui.chat.server class ChatServer { }
DuCalixte/LearningScalaWithNetworking
SimpleUIClientServerChat/src/com/akka/ui/chat/server/ChatServer.scala
Scala
mit
54
/** * 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...
roadboy/KafkaACL
core/src/main/scala/kafka/admin/PreferredReplicaLeaderElectionCommand.scala
Scala
apache-2.0
7,479
object Test { private case object FooA def main(argv : Array[String]) : Unit = { Console.println(FooA) } }
som-snytt/dotty
tests/run/t601.scala
Scala
apache-2.0
118
/*********************************************************************** * Copyright (c) 2013-2016 Commonwealth Computer Research, Inc. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Apache License, Version 2.0 * which accompanies this distribution and is ...
MutahirKazmi/geomesa
geomesa-tools/src/test/scala/org/locationtech/geomesa/tools/export/DelimitedExportImportTest.scala
Scala
apache-2.0
5,574
package it.codingjam.lagioconda.config import it.codingjam.lagioconda.{ChromosomeOps, GeneMapping} import it.codingjam.lagioconda.ChromosomeOps.CombineChromosome import it.codingjam.lagioconda.ga.{CrossoverPointLike, MutationPointLike, RandomCrossoverPoint, RandomMutationPoint} import it.codingjam.lagioconda.populatio...
coding-jam/lagioconda
common/src/main/scala/it/codingjam/lagioconda/Config.scala
Scala
apache-2.0
4,168
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may ...
cloudera/spark
core/src/main/scala/org/apache/spark/util/random/RandomSampler.scala
Scala
apache-2.0
3,033
package dregex import dregex.impl.RegexTree import dregex.impl.CharInterval import dregex.impl.Normalization import scala.collection.immutable.Seq /** * The purpose of this class is to enforce that set operation between regular expressions are only done when it is * legal to do so, that is, when the regex are co...
marianobarrios/dregex
src/main/scala/dregex/Universe.scala
Scala
bsd-2-clause
2,701
package org.jetbrains.sbt package project.data.service import java.io.File import java.util import com.intellij.openapi.externalSystem.model.DataNode import com.intellij.openapi.externalSystem.model.project.ProjectData import com.intellij.openapi.externalSystem.service.project.IdeModifiableModelsProvider import com.i...
jastice/intellij-scala
scala/integration/android/src/org/jetbrains/sbt/project/data/service/AndroidFacetDataService.scala
Scala
apache-2.0
3,718
package artisanal.pickle.maker import models._ import parser._ import org.specs2._ import mutable._ import specification._ import scala.reflect.internal.pickling.ByteCodecs import scala.tools.scalap.scalax.rules.scalasig._ import com.novus.salat.annotations.util._ import scala.reflect.ScalaSignature class Nothin...
julianpeeters/artisanal-pickle-maker
src/test/scala/singleValueMember/NothingSpec.scala
Scala
apache-2.0
894
/* * Copyright (C) 2009-2017 Lightbend Inc. <https://www.lightbend.com> */ package play.docs import java.io.File import java.util.concurrent.Callable import play.api._ import play.api.http.FileMimeTypes import play.api.mvc._ import play.api.routing.Router import play.core._ import play.core.server._ import scala.c...
ktoso/playframework
framework/src/play-docs/src/main/scala/play/docs/DocServerStart.scala
Scala
apache-2.0
2,408
/* __ *\\ ** ________ ___ / / ___ Scala API ** ** / __/ __// _ | / / / _ | (c) 2006-2013, LAMP/EPFL ** ** __\\ \\/ /__/ __ |/ /__/ __ | http://scala-lang.org/ ** ** /____/\\___/_/...
felixmulder/scala
src/library/scala/collection/generic/OrderedTraversableFactory.scala
Scala
bsd-3-clause
957
/* * Grammar of Graphics in Scala * Copyright (c) 2011, ggscala.org */ package org.ggscala.model import scala.reflect.ClassTag import org.ggscala.model.TypeCode._ import org.ggscala.model.Factor._ object DataColumn { /** * Associates a name (id) and type code with a DataVector. Provides * column metada...
drkeoni/ggscala
src/main/scala/org/ggscala/model/DataColumn.scala
Scala
mit
3,818
package com.socrata.tileserver package util import scala.collection.JavaConverters._ import scala.language.implicitConversions import com.rojoma.json.v3.io.JsonReader.fromString import com.vividsolutions.jts.geom.{Coordinate, Geometry, GeometryFactory} import no.ecc.vectortile.VectorTileDecoder import org.apache.comm...
socrata-platform/tileserver
src/test/scala/com.socrata.tileserver/util/TileEncoderTest.scala
Scala
apache-2.0
4,276
/* * EtherNet/IP * Copyright (C) 2014 Kevin Herron * * 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. * *...
digitalpetri/scala-ethernet-ip
enip-core/src/test/scala/com/digitalpetri/ethernetip/encapsulation/commands/UnRegisterSessionTest.scala
Scala
apache-2.0
1,086
/* * Copyright 2001-2015 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...
SRGOM/scalatest
scalactic/src/main/scala/org/scalactic/equalities/RecursiveMapEquality.scala
Scala
apache-2.0
2,008
/* * 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 ...
ptkool/spark
sql/core/src/test/scala/org/apache/spark/sql/execution/PlannerSuite.scala
Scala
apache-2.0
40,579
/*** * Copyright 2014 Rackspace US, 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 applica...
wdschei/api-checker
core/src/main/scala/com/rackspace/com/papi/components/checker/step/XSDStringValidator.scala
Scala
apache-2.0
3,058
package org.smackscalahelpers import org.jivesoftware._ import smack._ import smackx._ import smackx.pubsub._ import smackx.pubsub.FormType import smackx.pubsub.LeafNode import smackx.packet._ import smackx.packet.DataForm import scala.collection.JavaConversions._ class StorageNode( val name:String, val leafNode:Leaf...
flosse/smackScalaHelpers
src/main/scala/org/smackscalahelpers/PubSubStorage.scala
Scala
mit
2,870
package roles import models.{User, UserScope} import play.api.libs.concurrent.Execution.Implicits.defaultContext import scalikejdbc.async.AsyncDBSession import utils.Route import utils.exceptions.{AccessForbidden, ResourceNotFound} import scala.concurrent.Future trait AuthorizedUser { this: User => def checkSc...
KIWIKIGMBH/kiwierp
kiwierp-backend/app/roles/AuthorizedUser.scala
Scala
mpl-2.0
615
package domino.service_providing import domino.capsule.CapsuleContext import org.osgi.framework.BundleContext import domino.OsgiContext /** * A class that mixes in the [[ServiceProviding]] trait. Use this if you want to use a class instead of a trait. */ class SimpleServiceProviding( protected val capsuleContex...
helgoboss/domino
src/main/scala/domino/service_providing/SimpleServiceProviding.scala
Scala
mit
501
package com.zobot.client.packet.definitions.clientbound.login import com.zobot.client.packet.Packet case class LoginSuccess(uuid: Any, username: String) extends Packet { override lazy val packetId = 0x02 override lazy val packetData: Array[Byte] = fromAny(uuid) ++ fromVarString(username) }
BecauseNoReason/zobot
src/main/scala/com/zobot/client/packet/definitions/clientbound/login/LoginSuccess.scala
Scala
mit
306
package taczombie.model import scala.Array.canBuildFrom import scala.collection.immutable.HashSet import scala.io.Source import scala.collection.mutable.HashMap import taczombie.model.util.LevelCreator import scala.concurrent.Lock object GameFactory { var counter : Int = 1 val generateIdLock : Lock = new Lock(...
mahieke/TacZombie
model/src/main/scala/taczombie/model/GameFactory.scala
Scala
gpl-2.0
5,470
package org.jetbrains.plugins.scala.editor.todo /** tests [[ScalaIndexPatternBuilder]] */ class ScalaTodoIndexerTest extends ScalaTodoItemsTestBase { def testTodo_LineComment(): Unit = testTodos( s"""// ${start}TODO: do something$end |// unrelated comment line |val x = 42 |""".stripMargin ...
JetBrains/intellij-scala
scala/scala-impl/test/org/jetbrains/plugins/scala/editor/todo/ScalaTodoIndexerTest.scala
Scala
apache-2.0
3,614
package org.jetbrains.jps.incremental.scala package local import java.io.File import org.jetbrains.jps.incremental.ModuleLevelBuilder.ExitCode import org.jetbrains.jps.incremental.scala.data._ import xsbti.compile.AnalysisStore import sbt.internal.inc.FileAnalysisStore /** * @author Pavel Fatin */ class LocalServer...
triplequote/intellij-scala
scala/compiler-jps/src/org/jetbrains/jps/incremental/scala/local/LocalServer.scala
Scala
apache-2.0
1,558
/* * 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 ...
starpit/openwhisk
common/scala/src/main/scala/org/apache/openwhisk/core/containerpool/ContainerClient.scala
Scala
apache-2.0
1,295
package toguru.toggles import play.api.mvc.{Result, Results} import toguru.toggles.ToggleActor.{PersistFailed, ToggleDoesNotExist} trait ToggleActorResponses extends Results with JsonResponses { type ResponseHandler = Any => Result type HandlerDecorator = ResponseHandler => ResponseHandler def both(left: Han...
andreas-schroeder/toguru
app/toguru/toggles/ToggleActorResponses.scala
Scala
mit
1,059
/* * Copyright (c) 2013 Aviat Networks. * This file is part of DocReg+Web. Please refer to the NOTICE.txt file for license details. */ package vvv.docreg.backend import org.specs2.mutable._ import org.specs2.mock._ import vvv.docreg.db.{TestDbScope, TestDbVendor} import vvv.docreg.model.{UserLookupProvider, Subscr...
scott-abernethy/docreg-web
src/test/scala/vvv/docreg/backend/SubscriptionReconcileTest.scala
Scala
gpl-3.0
8,950
package org.jetbrains.plugins.scala.project.template import com.intellij.facet.impl.ui.libraries.LibraryOptionsPanel import com.intellij.framework.library.FrameworkLibraryVersionFilter import com.intellij.openapi.roots.ui.configuration.projectRoot.LibrariesContainer import com.intellij.ui.components.{ComponentsKt, JBT...
JetBrains/intellij-scala
scala/scala-impl/src/org/jetbrains/plugins/scala/project/template/ScalaSDKStepLike.scala
Scala
apache-2.0
1,996
/* * Copyright (C) 2014 - 2017 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)...
Tensei-Data/tensei-agent
src/test/scala/com/wegtam/tensei/agent/DummyActor.scala
Scala
agpl-3.0
1,370
package edu.gemini.model.p1.immutable import edu.gemini.model.p1.{ mutable => M } object GmosSBlueprintLongslit { def apply(m: M.GmosSBlueprintLongslit) = new GmosSBlueprintLongslit( m.getDisperser, m.getFilter, m.getFpu) } case class GmosSBlueprintLongslit(disperser: GmosSDisperser, filter: GmosSFilte...
arturog8m/ocs
bundle/edu.gemini.model.p1/src/main/scala/edu/gemini/model/p1/immutable/GmosSBlueprintLongslit.scala
Scala
bsd-3-clause
843
/* * ApplyFactory.scala * Description needed * * Created By: Glenn Takata (gtakata@cra.com) * Creation Date: Dec 15, 2014 * * Copyright 2014 Avrom J. Pfeffer and Charles River Analytics, Inc. * See http://www.cra.com or email figaro@cra.com for information. * * See http://www.github.com/p2t2/figaro ...
jyuhuan/figaro
Figaro/src/main/scala/com/cra/figaro/algorithm/factored/factors/factory/ApplyFactory.scala
Scala
bsd-3-clause
10,398
/* * 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...
keithhall/ct-calculations
src/main/scala/uk/gov/hmrc/ct/ct600a/v3/formats/Loans.scala
Scala
apache-2.0
1,117
/* 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 not use this f...
mandar2812/DynaML
dynaml-examples/src/main/scala/io/github/tailhq/dynaml/examples/AbottPowerPlantNN.scala
Scala
apache-2.0
7,373
package de.vorb.vision.binarization import javax.imageio.ImageIO import java.io.File import java.awt.image.BufferedImage import java.awt.image.BufferedImageOp import java.awt.image.ColorConvertOp object BinarizationTest extends App { print("Reading image... "); val color = ImageIO.read(new File("src/test/resource...
pvorb/image-binarization
src/test/scala/de/vorb/vision/binarization/BinarizationTest.scala
Scala
mit
1,076
/* * 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 ...
christobill/spark-cassandra-connector
project/Settings.scala
Scala
apache-2.0
14,345
/* * 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 ...
himanshudhami/PredictionIO
tools/src/main/scala/org/apache/predictionio/tools/RunWorkflow.scala
Scala
apache-2.0
3,461
/* * Copyright 2015 ligaDATA * * 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 ...
traytonwhite/Kamanja
trunk/Pmml/PmmlUdfs/src/test/scala/com/ligadata/pmml/udfs/TestCustomUdfs.scala
Scala
apache-2.0
3,579
/* * 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/test/scala/tomtom/splitter/layer7/LoadTest.scala
Scala
apache-2.0
5,886
package cn.gridx.scala.lang.generics.TypeParameterization /** * Created by tao on 11/23/15. */ class Apple extends Fruit { def name: String = "apple" }
TaoXiao/Scala
lang/src/main/scala/cn/gridx/scala/lang/generics/TypeParameterization/Apple.scala
Scala
apache-2.0
159
package com.sksamuel.elastic4s import java.util.UUID import com.sksamuel.elastic4s.admin._ import com.sksamuel.elastic4s.mappings.FieldType._ import com.sksamuel.elastic4s.mappings._ import scala.concurrent.duration._ import scala.concurrent.{Await, Future} /** @author Stephen Samuel */ trait ElasticDsl extends I...
alexander-svendsen/elastic4s
elastic4s-core/src/main/scala/com/sksamuel/elastic4s/ElasticDsl.scala
Scala
apache-2.0
30,368
/*********************************************************************** * 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...
ronq/geomesa
geomesa-accumulo/geomesa-accumulo-tools/src/main/scala/org/locationtech/geomesa/accumulo/tools/status/AccumuloVersionRemoteCommand.scala
Scala
apache-2.0
1,254
/* * Copyright 2013 The SIRIS 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 applica...
simulator-x/feature
src/simx/components/ai/feature/FeatureBase.scala
Scala
apache-2.0
5,093
package main import java.awt.geom.{Ellipse2D, Line2D, Path2D} import java.awt.{BasicStroke, Color, Graphics2D, RenderingHints} import utilities.{CubicCurve, MyMath, Vec2} /** * Created by weijiayi on 2/29/16. */ class CurveDrawer(g2d: Graphics2D, pointTransform: Vec2 => Vec2, widthScale: Double, ...
MrVPlusOne/Muse-CGH
src/main/CurveDrawer.scala
Scala
mit
4,599
package com.virdis import java.util.regex.Pattern /** * Created by sandeep on 11/3/15. */ trait TweetCleanUp { val nonAscii = "[^\\p{ASCII}]+" val newLineOrTab = "\\\n|\\\t" val backSlash = "\\\\" val p = Pattern.compile(nonAscii) private var unicodeCounter: Long = 0L /* Check non ascii chara...
virdis/data-challenge
src/main/scala/com/virdis/TweetCleanUp.scala
Scala
apache-2.0
957
/* * 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 ...
lincoln-lil/flink
flink-table/flink-table-planner/src/main/scala/org/apache/flink/table/planner/plan/nodes/physical/stream/StreamPhysicalOverAggregate.scala
Scala
apache-2.0
2,230
package models import play.api.db._ import play.api.Play.current import play.api.i18n.Lang import anorm._ import anorm.SqlParser._ import java.util.Date import play.Logger case class Gallerys( id: Pk[Long] , filename: Option[String] , default: Boolean , position: Long , cat_id: Long , caption: Optio...
musethno/MGS
app/models/Exhibition.scala
Scala
mit
24,732
/* * Scala (https://www.scala-lang.org) * * Copyright EPFL and Lightbend, Inc. * * Licensed under Apache License 2.0 * (http://www.apache.org/licenses/LICENSE-2.0). * * See the NOTICE file distributed with this work for * additional information regarding copyright ownership. */ package scala package tools.ns...
martijnhoekstra/scala
src/compiler/scala/tools/nsc/symtab/classfile/ClassfileParser.scala
Scala
apache-2.0
56,118
package edu.gemini.phase2.skeleton.auxfile import java.io.File object FileError { def apply(file: File, msg: String): FileError = FileError(file, new RuntimeException(msg)) } case class FileError(file: File, exception: Exception)
spakzad/ocs
bundle/edu.gemini.phase2.skeleton.servlet/src/main/scala/edu/gemini/phase2/skeleton/auxfile/FileError.scala
Scala
bsd-3-clause
238
// tells Scala where to find the TMT classes import scalanlp.io._; import scalanlp.stage._; import scalanlp.stage.text._; import scalanlp.text.tokenize._; import scalanlp.pipes.Pipes.global._; import edu.stanford.nlp.tmt.stage._; import edu.stanford.nlp.tmt.model.lda._; if ( args.length < 2 ) { System.err.println...
StanfordHCI/termite
pipeline/stmt/lda-learn.scala
Scala
bsd-3-clause
3,232
package com.ignition.frame.mllib import scala.xml.{ Elem, Node } import org.apache.spark.mllib.stat.Statistics import org.apache.spark.rdd.RDD.rddToPairRDDFunctions import org.apache.spark.sql.{ DataFrame, Row } import org.apache.spark.sql.types.StructType import org.json4s.JValue import org.json4s.JsonDSL._ import o...
uralian/ignition
src/main/scala/com/ignition/frame/mllib/Correlation.scala
Scala
apache-2.0
3,699
package com.ftchinese.jobs.common /** * Task case class * Created by wanbo on 16/3/23. * * @param production: Default is true, if false the task just for testing. * @param createTime: The time millis when task was created. */ case class TaskMessage(message: String = "", sound: String = "", action: String = "", l...
FTChinese/push
src/main/scala/com/ftchinese/jobs/common/TaskMessage.scala
Scala
mit
414
/** * 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 ...
erictu/adam
adam-core/src/main/scala/org/bdgenomics/adam/rdd/Coverage.scala
Scala
apache-2.0
9,435
package org.shelmet.heap import org.scalatest._ class CommandLineTest extends FlatSpec { "A command line parser" should "parse default options" in { Main.parser.parse(Seq("test.bin"),new Config()) map { config => assert(config.port === Config.DEFAULT_HTTP_PORT) assert(config.dumpFile.getNa...
rorygraves/shelmet
src/test/scala/org/shelmet/heap/CommandLineTest.scala
Scala
gpl-2.0
480
/* * Copyright 2001-2008 Artima, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agre...
svn2github/scalatest
src/test/scala/org/scalatest/junit/JUnitSuiteSpec.scala
Scala
apache-2.0
6,145
package net.slozzer.babel final case class Translation[+A](locale: Locale, value: A) { def map[B](f: A => B): Translation[B] = copy(value = f(value)) def as[B](value: B): Translation[B] = map(_ => value) def mapWithLocale[B](f: (Locale, A) => B): Translation[B] = copy(value = f(locale, value)) def toTuple: ...
Taig/lokal
modules/core/src/main/scala/net/slozzer/babel/Translation.scala
Scala
mit
408
/* * This file is part of AckCord, licensed under the MIT License (MIT). * * Copyright (c) 2019 Katrix * * 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 ...
Katrix-/AckCord
core/src/main/scala/ackcord/cachehandlers/CacheSnapshotBuilder.scala
Scala
mit
4,398
package com.realizationtime.btdogg import akka.actor.{Actor, ActorLogging, ActorRef, DeadLetter, Props} import com.realizationtime.btdogg.RootActor._ import com.realizationtime.btdogg.dhtmanager.DhtsManager import com.realizationtime.btdogg.dhtmanager.DhtsManager.{NodeReady, Shutdown} import com.realizationtime.btdogg...
bwrega/btdogg
src/main/scala/com/realizationtime/btdogg/RootActor.scala
Scala
mit
2,499
package com.rasterfoundry.database import java.util.UUID import com.rasterfoundry.common.ast.MapAlgebraAST import com.rasterfoundry.common.ast.MapAlgebraAST.{LayerRaster, ProjectRaster} import com.rasterfoundry.common.ast.codec.MapAlgebraCodec import com.rasterfoundry.datamodel._ import com.rasterfoundry.common.Gener...
azavea/raster-foundry
app-backend/db/src/test/scala/com/azavea/rf/database/ExportDaoSpec.scala
Scala
apache-2.0
6,612
//package xi.armatweet.nlp // //import edu.stanford.nlp.ling.{CoreAnnotations, CoreLabel} //import edu.stanford.nlp.simple.Document // //import scala.collection.JavaConversions._ // ///** // * Created by alberto on 16/08/16. // */ //object SparkOpenIE { // // def getOffsets(tweet: Tweet, comp: Seq[CoreLabel]) = { //...
eXascaleInfolab/2016-armatweet
NLP/src/main/scala/xi/armatweet/nlp/SparkOpenIE.scala
Scala
mit
3,362
package org.greencheek.web.filter.memcached.servlets import javax.servlet.http.{HttpServletResponse, HttpServletRequest, HttpServlet} import java.io.IOException import javax.servlet.ServletException /** * Created by dominictootell on 01/05/2014. */ class SayHelloServletIT extends HttpServlet { @throws(classOf[IO...
tootedom/tomcat-memcached-response-filter
src/integration-test/scala/org/greencheek/web/filter/memcached/servlets/SayHelloServletIT.scala
Scala
apache-2.0
546
package openscad trait Vec[Self] { this : Self => def *(t: Double) : Self def +(other: Self) : Self def -(other: Self) : Self } case class Vec3(x : Double, y : Double, z : Double) extends Vec[Vec3] { def toDegrees = Vec3(math.toDegrees(x), math.toDegrees(y), math.toDegrees(z)) def normalized() = { v...
mikea/3d-bookmark
src/main/scala/openscad/vectors.scala
Scala
apache-2.0
1,486
/* * Part of NDLA learningpath-api. * Copyright (C) 2018 NDLA * * See LICENSE */ package db.migration import no.ndla.learningpathapi.UnitSuite class V7__MovePublishedExternToUnlistedTest extends UnitSuite { val migration = new V7__MovePublishedExternToUnlisted() test("extern learningpaths with PUBLISHED sh...
NDLANO/learningpath-api
src/test/scala/db/migration/V7__MovePublishedExternToUnlistedTest.scala
Scala
gpl-3.0
1,319
/* * Copyright (c) 2014, Cloudera, Inc. All Rights Reserved. * * Cloudera, Inc. licenses this file to you under the Apache License, * Version 2.0 (the "License"). You may not use this file except in * compliance with the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICE...
SevenYoung/oryx
framework/oryx-api/src/main/scala/com/cloudera/oryx/api/serving/ScalaServingModelManager.scala
Scala
apache-2.0
1,569
/* * This file is part of Kiama. * * Copyright (C) 2013-2015 Anthony M Sloane, Macquarie University. * * Kiama 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 ...
adeze/kiama
library/src/org/kiama/util/Counter.scala
Scala
gpl-3.0
2,095
/* * 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 ...
spotify/scio
scio-google-cloud-platform/src/main/scala/com/spotify/scio/bigquery/types/package.scala
Scala
apache-2.0
1,438
/* Copyright 2014, 2015 Richard WiedenhΓΆft <richard@wiedenhoeft.xyz> * * 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...
Richard-W/scalacrypt
src/main/scala/util/PBKDF2Easy.scala
Scala
apache-2.0
2,908
object test { abstract class Foo; object o extends Foo }
yusuke2255/dotty
tests/untried/pos/t439.scala
Scala
bsd-3-clause
61
import scala.language.implicitConversions class A class B extends A trait Y { def value: String } trait X[-T] { def y(t: T): Y } object XA extends X[A] { def y(a: A) = new Y { def value = s"${a.getClass}: AValue" } } object XB extends X[B] { def y(b: B) = new Y { def value = s"${b.getClass}: BValue" } } o...
martijnhoekstra/scala
test/files/run/t2509-1.scala
Scala
apache-2.0
592
package models.product import play.api.libs.json.Json case class ProductOption( name: String, description: Option[String], priceInCent: Int ) object ProductOption { implicit val jsonFormat = Json.format[ProductO...
leanovate/microzon-web
app/models/product/ProductOption.scala
Scala
mit
328
package at.fh.swengb.resifo_android import android.content.Intent import android.os.Bundle import android.support.v7.app.AppCompatActivity import android.view.View import android.widget.{EditText, Toast} class Formular08Activity extends AppCompatActivity { var bundle: Bundle = _ var intent: Intent = _ overrid...
FlorianReinprecht/resifo-android
app/src/main/scala/at/fh/swengb/resifo_android/Formular08Activity.scala
Scala
gpl-3.0
2,971
package goggles.macros.interpret case class OpticInfo[+Type]( label: String, sourceType: Type, targetType: Type, opticType: OpticType, compositeOpticType: OpticType) { def map[U](f: Type => U): OpticInfo[U] = { copy(sourceType = f(sourceType), targetType = f(targetType)) } }
kenbot/goggles
macros/src/main/scala/goggles/macros/interpret/OpticInfo.scala
Scala
mit
302
/* * Copyright 2016 Dennis Vriend * * 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...
gavares/akka-persistence-jdbc
src/main/scala/akka/persistence/jdbc/util/BlockingOps.scala
Scala
apache-2.0
1,071
package io.rout.example.incomplete import scala.collection.mutable case class Todo(id: Int, title: String, completed: Boolean, order: Option[Int], daysToComplete: Int,relatedTodos: Option[Seq[Int]], advisor: Option[String]) object Todo { private[this] val db: mutable.Map[Int, Todo] = mutable.Map.e...
teodimoff/rOut
examples/src/io/rout/incomplete/Todo.scala
Scala
apache-2.0
708
/* * 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/ct600e/v2/E13.scala
Scala
apache-2.0
1,020
/* * Copyright 2018 Aman Mehara * * 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 ...
amanmehara/programming-app-data
Scala/Create List/CreateList.scala
Scala
apache-2.0
834
/* * Copyright 2001-2013 Stephen Colebourne * * 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...
aparo/scalajs-joda
src/main/scala/org/joda/time/chrono/GJMonthOfYearDateTimeField.scala
Scala
apache-2.0
1,863
/* * The MIT License (MIT) * * Copyright (c) 2014 yetu AG * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal * in the Software without restriction, including without limitation the rights * to use, copy...
yetu/siren-scala
src/main/scala/com/yetu/siren/model/package.scala
Scala
mit
10,650
package es.juanc.katas.mocking object Main extends App { Greeting { new FileOutput }.message("eoo!!!") }
juancsch/katas
scala/SimpleKatas/src/test/scala/es/juanc/katas/mocking/Main.scala
Scala
unlicense
111
/* * Copyright (c) 2012 Roberto Tyley * * This file is part of 'BFG Repo-Cleaner' - a tool for removing large * or troublesome blobs from Git repositories. * * BFG Repo-Cleaner is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Fr...
rtyley/bfg-repo-cleaner
bfg-library/src/test/scala/com/madgag/git/bfg/cleaner/RepoRewriteSpec.scala
Scala
gpl-3.0
7,179
/* * Copyright (c) 2013 original 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 a...
eigengo/monitor
example-spray/src/main/scala/org/eigengo/monitor/example/spray/Main.scala
Scala
apache-2.0
891
package org.daydev.scala.bb.rewrite.config import org.scalatest.FunSuite import org.daydev.scala.bb.model.BbTag import scala.xml.Text import scala.xml.NodeSeq class HtmlRewriteConfigSpec extends FunSuite { val dummyRuleMap = Map[String, RewriteRule[NodeSeq]]( "a" -> { (_, content) => <a>{ content }</a> ...
daydev/bbcode-scala
src/test/scala/org/daydev/scala/bb/rewrite/config/HtmlRewriteConfigSpec.scala
Scala
mit
1,421
import bio._ import org.scalatest.FlatSpec import org.scalatest.matchers.ShouldMatchers package bio.test { import bio.DNA._ class RemoveSparseSpec extends FlatSpec with ShouldMatchers { "An alignment" should "remove sparse columns" in { // this also tests removeSparseRows and transpose val s1 = ...
shamim8888/bioscala
src/test/scala/bio/alignment/actions/sparsealignment_spec.scala
Scala
bsd-2-clause
881
package com.aslepakurov.spark.maxnumber import com.aslepakurov.spark.common.CommonSparkContext import com.aslepakurov.spark.maxnumber.MaxNumberService._ object MaxNumberJob { def main(args: Array[String]): Unit = { val context = new MaxNumberContext(args.toList) .builder .initContext .initSQL ...
aslepakurov/common-spark-template
src/main/java/com/aslepakurov/spark/maxnumber/MaxNumberJob.scala
Scala
mit
996
package mimir.algebra import java.io.File import org.specs2.mutable._ import org.specs2.specification._ import mimir.parser._ import mimir.algebra._ import mimir.algebra.function.FunctionRegistry import mimir.optimizer._ import mimir.optimizer.expression._ import mimir.test._ object DateSpec extends SQLTestSpecifi...
UBOdin/mimir
src/test/scala/mimir/algebra/DateSpec.scala
Scala
apache-2.0
854
/** * MergeSort.scala --- Recursive merge sort with pattern matching * * Copyright (C) 2014 Aaron S. Hawley * * 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 Licen...
ashawley/algs
src/main/scala/org/ninthfloor/users/ashawley/algs/sort/MergeSort.scala
Scala
gpl-3.0
2,559
package knot.core.stream.dsl import java.nio.file.StandardOpenOption.{CREATE, TRUNCATE_EXISTING, WRITE} import java.nio.file.{OpenOption, Path} import knot.core.Done import knot.core.stream.graphs.{GraphMaterializer, SourceGraph} import knot.core.stream.{Flow, Sink} import knot.data.ByteNode trait ByteNodeSourceSynt...
defvar/knot
knot-core/src/main/scala/knot/core/stream/dsl/ByteNodeSourceSyntax.scala
Scala
mit
899
package scalajsclient.jswidgets import org.scalajs.dom import scala.scalajs.js import scala.scalajs.js.timers._ import scala.scalajs.js.Dynamic.global import org.singlespaced.d3js.d3 import org.singlespaced.d3js.Ops._ import scalajsclient._ import scalajsclient.ScalaJSUtils._ class JSCombo( setid: String, opt...
serversideapps/silhmojs
client/src/main/scala/scalajsclient/jswidgets/jscombo.scala
Scala
apache-2.0
6,612
package nest.sparkle.loader.kafka import scala.concurrent.duration._ import spray.http.StatusCodes._ import spray.http.MediaTypes.`application/json` import spray.testkit.ScalatestRouteTest import akka.actor.ActorRefFactory import spray.json._ import nest.sparkle.measure.MeasurementToTsvFile import nest.sparkle.uti...
mighdoll/sparkle
kafka/src/it/scala/nest/sparkle/loader/kafka/TestKafkaLoaderBaseAdminService.scala
Scala
apache-2.0
3,723
package org.http4s import scala.collection.generic.CanBuildFrom import scala.collection.immutable.{BitSet, IndexedSeq} import scala.collection.mutable.ListBuffer import scala.collection.{ IndexedSeqOptimized, mutable } import cats.implicits._ import org.http4s.Query._ import org.http4s.parser.QueryParser import org.h...
ZizhengTai/http4s
core/src/main/scala/org/http4s/Query.scala
Scala
apache-2.0
5,843
/* * Copyright 2017 Mediative * * 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...
muuki88/sbt-graphql
src/test/scala/rocks/muki/graphql/codegen/style/sangria/BlogCodegenSpec.scala
Scala
apache-2.0
705