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 models import play.Logger import play.api.libs.json.Json import reactivemongo.bson._ // necessaire (implict ... Json.format) import play.modules.reactivemongo.json.BSONFormats.BSONObjectIDFormat /** * User: Louis TOURNAYRE */ case class Site(id: Option[BSONObjectID], name: String, activity: String, adress: ...
louidji/eventual
app/models/Site.scala
Scala
gpl-3.0
1,376
/* * 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 ...
gyfora/flink
flink-table/flink-table-planner/src/test/scala/org/apache/flink/table/runtime/batch/sql/TableSourceITCase.scala
Scala
apache-2.0
3,434
/* * Copyright (c) 2013 Scott Abernethy. * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * This program is d...
scott-abernethy/opener-of-the-way
app/gate/Presenter.scala
Scala
gpl-3.0
3,467
package de.tu_berlin.impro3.spark.spatio_temporal_dynamics.parsers import java.util.Date import de.tu_berlin.impro3.spark.spatio_temporal_dynamics._ import model.Tweet import org.junit.runner.RunWith import org.scalatest._ import org.scalatest.junit.JUnitRunner import org.scalatest.prop.PropertyChecks @RunWith(clas...
joroKr21/spatio-temporal-dynamics
impro3-ws14-spark/src/test/scala/de/tu_berlin/impro3/spark/spatio_temporal_dynamics/parsers/ParserSpec.scala
Scala
apache-2.0
2,820
package br.gov.lexml.swing.componentes import br.gov.lexml.swing.componentes.models.ListChoiceActionApprover class DefaultListChoiceActionApprover[T] extends ListChoiceActionApprover[T] { override def additionApproved(e : T) = true override def removalApproved(e : T, p : Int) = true override def moveApprove...
lexml/lexml-swing-componentes
src/main/scala/br/gov/lexml/swing/componentes/DefaultListChoiceActionApprover.scala
Scala
gpl-2.0
347
package core import akka.actor.Actor import com.datastax.driver.core.{BoundStatement, Cluster, Row} import domain.Tweet import core.TweetReaderActor.{CountAll, FindAll} import com.datastax.driver.core.querybuilder.QueryBuilder object TweetReaderActor { case class FindAll(maximum: Int = 100) case object CountAll }...
eigengo/activator-akka-cassandra
src/main/scala/core/tweetread.scala
Scala
apache-2.0
1,226
/** * 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...
WillCh/cs286A
dataMover/kafka/core/src/test/scala/unit/kafka/integration/AutoOffsetResetTest.scala
Scala
bsd-2-clause
4,385
package com.tribbloids.spookystuff.utils.lifespan import com.tribbloids.spookystuff.utils.{CommonUtils, IDMixin} import org.apache.spark.TaskContext import scala.util.Try /** * Java Deserialization only runs constructor of superclass */ //CAUTION: keep the empty constructor in subclasses! // Without it Kryo dese...
tribbloid/spookystuff
mldsl/src/main/scala/com/tribbloids/spookystuff/utils/lifespan/Lifespan.scala
Scala
apache-2.0
3,727
package metal package generic import scala.reflect.ClassTag import spire.util.Opt abstract class Map2[K, V1, V2] extends Defaults with Enumerable with Searchable[K] with Values1[V1] with Values2[V2] with NElements3[K, V1, V2] { lhs => implicit def ctK: ClassTag[K] implicit def K: MetalTa...
denisrosset/ptrcoll
library/src/main/scala/metal/generic/Map2.scala
Scala
mit
2,559
/* * 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/test/scala/com/spotify/scio/bigquery/BigQueryClientTest.scala
Scala
apache-2.0
1,382
/* * 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/package.scala
Scala
apache-2.0
1,842
package scala package tools.nsc package interpreter /** * Subclass to access some hidden things I need and also some custom behavior. */ class HackIMain(settings: Settings, out: JPrintWriter) extends IMain(settings, out) { def previousRequests = prevRequestList override protected def parentClassLoader = settings...
minyk/spark-notebook
modules/spark/src/main/scala_2.11/spark-pre1.5/HackIMain.scala
Scala
apache-2.0
349
package gitbucket.core.controller import gitbucket.core.api._ import gitbucket.core.issues.html import gitbucket.core.model.Issue import gitbucket.core.service.IssuesService._ import gitbucket.core.service._ import gitbucket.core.util.ControlUtil._ import gitbucket.core.util.Implicits._ import gitbucket.core.util._ im...
snowgooseyk/gitbucket
src/main/scala/gitbucket/core/controller/IssuesController.scala
Scala
apache-2.0
20,647
package crdts import org.scalatest.{Matchers, FlatSpec} import scala.collection.SortedMap class HandOffSpec extends FlatSpec with Matchers { import HandOff._ "A Node" should "join nicely" in { val i = Node("i", 2, sck = 2, values = SortedMap("i" -> 9)) val j = Node("j", 1, dck = 5, ...
maylencita/counters
src/test/scala/crdts/HandOffSpec.scala
Scala
cc0-1.0
536
/*********************************************************************** * Copyright (c) 2013-2020 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...
aheyne/geomesa
geomesa-utils/src/main/scala/org/locationtech/geomesa/utils/cache/FilePersistence.scala
Scala
apache-2.0
1,627
package com.eevolution.context.dictionary.infrastructure.repository import com.eevolution.context.dictionary.domain.model.InfoColumnTrl import com.eevolution.context.dictionary.infrastructure.db.DbContext._ /** * Copyright (C) 2003-2017, e-Evolution Consultants S.A. , http://www.e-evolution.com * This program is ...
adempiere/ADReactiveSystem
dictionary-impl/src/main/scala/com/eevolution/context/dictionary/infrastructure/repository/InfoColumnTrlMapping.scala
Scala
gpl-3.0
1,756
package com.twitter.finagle import com.twitter.conversions.DurationOps._ import com.twitter.util.{Await, Return} import org.scalacheck.Gen import org.scalatest.concurrent.{Eventually, IntegrationPatience} import org.scalatestplus.junit.AssertionsForJUnit import org.scalatestplus.scalacheck.ScalaCheckDrivenPropertyChec...
twitter/finagle
finagle-core/src/test/scala/com/twitter/finagle/StatusTest.scala
Scala
apache-2.0
2,669
/* * Copyright 2017 Datamountaineer. * * 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...
CodeSmell/stream-reactor
kafka-connect-elastic6/src/test/scala/com/datamountaineer/streamreactor/connect/elastic6/TestElasticsSinkConnector.scala
Scala
apache-2.0
1,379
/** * Copyright (C) 2012 Orbeon, Inc. * * This program is free software; you can redistribute it and/or modify it under the terms of the * GNU Lesser General Public License as published by the Free Software Foundation; either version * 2.1 of the License, or (at your option) any later version. * * This program i...
wesley1001/orbeon-forms
src/main/scala/org/orbeon/oxf/util/Logging.scala
Scala
lgpl-2.1
2,994
/* This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ package scaps.nucleus.indexing import java.util.regex.Pattern import scaps.nucleus.Contravariant import scaps.nuc...
scala-search/scaps
nucleus/src/main/scala/scaps/nucleus/indexing/TypeNormalization.scala
Scala
mpl-2.0
2,665
package fpinscala.datastructures sealed trait Tree[+A] case class Leaf[A](value: A) extends Tree[A] case class Branch[A](left: Tree[A], right: Tree[A]) extends Tree[A] object Tree { def size[A](t: Tree[A]): Int = t match { case Leaf(_) => 1 case Branch(l, r) => size(l) + size(r) + 1 } val tt = B...
svenski/fpinscala
exercises/src/main/scala/fpinscala/datastructures/Tree.scala
Scala
mit
922
/* * * 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/utils/collection/immutable/UniqueSeqMap.scala
Scala
apache-2.0
1,188
package models.export.format import akka.stream.scaladsl.Source import akka.util.ByteString import java.io.{ByteArrayOutputStream,FilterOutputStream,OutputStream} import models.export.rows.Rows /** Provides a java.io.OutputStream-friendly streaming format. * * Implementors will decide upon a Context class (for i...
overview/overview-server
web/app/models/export/format/WriteBasedFormat.scala
Scala
agpl-3.0
3,435
/*********************************************************************** * Copyright (c) 2013-2020 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...
aheyne/geomesa
geomesa-kudu/geomesa-kudu-tools/src/main/scala/org/locationtech/geomesa/kudu/tools/status/KuduDescribeSchemaCommand.scala
Scala
apache-2.0
1,351
package metronome.chrono /** * The Minguo calendar system. * <p> * This chronology defines the rules of the Minguo calendar system. * This calendar system is primarily used in the Republic of China, often known as Taiwan. * Dates are aligned such that {@code 0001-01-01 (Minguo)} is {@code 1912-01-01 (ISO)}. * <p...
javierg1975/metronome
src/main/scala/metronome/chrono/Minguo.scala
Scala
gpl-2.0
22,271
enum Bool { case True case False } import Bool.* type Not[B <: Bool] = B match { case True.type => False.type case False.type => True.type } val t: True.type = True val f: False.type = False val g: Not[False.type] = t val t1: Not[f.type] = t // transitivity val f1: Not[t.type] = f // transitivity val t2: ...
lampepfl/dotty
tests/pos/i10511.scala
Scala
apache-2.0
402
package sample.cluster.simple import com.typesafe.config.ConfigFactory import akka.actor.ActorSystem import akka.actor.Props object SimpleClusterApp { def main(args: Array[String]): Unit = { if (args.isEmpty) startup(Seq("2551", "2552", "0")) else startup(args) } def startup(ports: Seq[Stri...
linearregression/social_data_collector
src/main/scala/sample/cluster/simple/SimpleClusterApp.scala
Scala
cc0-1.0
777
package com.twitter.algebird import scala.collection.immutable.SortedMap object SpaceSaver { /** * Construct SpaceSaver with given capacity containing a single item. * This is the public api to create a new SpaceSaver. */ def apply[T](capacity: Int, item: T): SpaceSaver[T] = SSOne(capacity, item) priv...
avibryant/algebird
algebird-core/src/main/scala/com/twitter/algebird/SpaceSaver.scala
Scala
apache-2.0
6,476
package com.cterm2.miniflags.common // Design Parameters object Metrics { final val Space = 0.125f // Margin from default block bound final val InvSpace = 1.0f - Space // Inverted margin from default block bound final val BaseHeight = 0.125f // Flag Base Height final val Pole = 0.5f - 1.5f / 16.0f // Ma...
Pctg-x8/miniflags
src/common/metrics.scala
Scala
lgpl-2.1
400
/** * This file is part of the TA Buddy project. * Copyright (c) 2012-2014 Alexey Aksenov [email protected] * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU Affero General Global License version 3 * as published by the Free Software Foundation with the addition...
digimead/digi-TABuddy-desktop
part-model-definition/src/main/scala/org/digimead/tabuddy/desktop/model/definition/ui/dialog/eltemed/ColumnGroup.scala
Scala
agpl-3.0
4,568
//https://www.hackerrank.com/challenges/swap-nodes object SwapNodes extends App { sealed trait Tree { def inOrder: List[Int] = this match { case Empty => Nil case Node(left, value, right) => left.inOrder ++ (value :: right.inOrder) //case Node(left, value, right) => (value :: left.preOrder) ++ right.preOr...
flopezlasanta/hackerrank
src/functional_programming/functional_structures/SwapNodes.scala
Scala
mit
1,915
package io.buoyant.config import com.fasterxml.jackson.databind.ObjectMapper import com.fasterxml.jackson.databind.jsontype.NamedType trait ConfigInitializer { def configClass: Class[_] def configId: String = configClass.getName lazy val namedType = new NamedType(configClass, configId) def registerSubtypes...
denverwilliams/linkerd
config/src/main/scala/io/buoyant/config/ConfigInitializer.scala
Scala
apache-2.0
392
package lore.compiler.build import lore.compiler.core.Position import lore.compiler.feedback.{Feedback, Reporter} import java.nio.file.{Files, Path} object SdkDirectory { case class SdkNotFound(path: Path) extends Feedback.Error(Position.unknown) { override def message: String = s"The SDK path `$path` does no...
marcopennekamp/lore
compiler/src/lore/compiler/build/SdkDirectory.scala
Scala
mit
1,318
package tool.swf import java.io._ import com.jpexs.decompiler.flash.tags.{DefineSpriteTag, PlaceObject2Tag} import models.db.CellPosition import scala.collection.JavaConverters._ import scala.collection.breakOut case class MapData(bytes: Array[Byte], cells: Seq[Cell]) object MapData { def fromFile(file: File): O...
Moesugi/MFG
server/app/tool/swf/MapData.scala
Scala
mit
1,494
/* * Copyright 2017 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...
pncampbell/ct-calculations
src/test/scala/uk/gov/hmrc/ct/accounts/approval/accountsApproval/accountsApproval/AC8091Spec.scala
Scala
apache-2.0
1,908
package org.jetbrains.plugins.scala.lang.parameterInfo.functionParameterInfo class FunctionParameterInfoUpdateTest extends FunctionParameterInfoTestBase { override def getTestDataPath: String = s"${super.getTestDataPath}update/" def testGenericUpdate() = doTest() def testNoUpdate() = doTest() def testU...
ilinum/intellij-scala
test/org/jetbrains/plugins/scala/lang/parameterInfo/functionParameterInfo/FunctionParameterInfoUpdateTest.scala
Scala
apache-2.0
344
package org.scalacvx import org.scalacvx.atoms.affine.AddAtom import org.scalacvx.atoms._ import org.scalatest.{Matchers, FlatSpec} /** * Created by lorenzo on 9/6/15. */ class ExpressionTests extends FlatSpec with Matchers { "The sum of two affine expression" should "be an affine expression" in { val x = V...
lorenzolucido/ScalaCVX
src/test/scala/org/scalacvx/ExpressionTests.scala
Scala
mit
925
package controllers import javax.inject.Inject import controllers.conversion._ import controllers.conversion.Converter._ import org.scalarules.engine.{Context, FactEngine} import org.scalarules.facts.Fact import org.scalarules.service.dsl.BusinessService import play.api.data.validation.ValidationError import play.api...
scala-rules/rule-rest
app/controllers/RestController.scala
Scala
mit
10,737
package com.sksamuel.elastic4s.indexes import com.sksamuel.elastic4s.JsonSugar import com.sksamuel.elastic4s.analyzers.{CustomAnalyzerDefinition, KeywordTokenizer, LowercaseTokenFilter} import com.sksamuel.elastic4s.http.ElasticDsl import org.elasticsearch.common.settings.Settings import org.scalatest.{Matchers, WordS...
aroundus-inc/elastic4s
elastic4s-tests/src/test/scala/com/sksamuel/elastic4s/indexes/CreateIndexTemplateDefinitionShowTest.scala
Scala
apache-2.0
1,328
package mesosphere.marathon package core.readiness import mesosphere.UnitTest import mesosphere.marathon.core.instance.TestTaskBuilder import mesosphere.marathon.core.task.Task import mesosphere.marathon.core.task.state.NetworkInfo import mesosphere.marathon.state.{ AppDefinition, PathId, PortDefinition } class Readi...
Caerostris/marathon
src/test/scala/mesosphere/marathon/core/readiness/ReadinessCheckSpecTest.scala
Scala
apache-2.0
5,410
package controllers.stateless import controllers.BaseAuthConfig import play.api.mvc.RequestHeader import play.api.mvc.Results._ import scala.concurrent.{Future, ExecutionContext} import com.github.tototoshi.play2.auth.{CookieIdContainer, AsyncIdContainer} trait AuthConfigImpl extends BaseAuthConfig { def loginSuc...
tototoshi/play2-auth
sample/app/controllers/stateless/AuthConfigImpl.scala
Scala
apache-2.0
785
package mesosphere.mesos import mesosphere.UnitTest import org.apache.mesos class VolumeProfileMatcherTest extends UnitTest { "matchesProfileName" should { "match disk with profile if that profile is required" in { val disk = diskResource(profile = Some("profile")) VolumeProfileMatcher.matchesProfil...
gsantovena/marathon
src/test/scala/mesosphere/mesos/VolumeProfileMatcherTest.scala
Scala
apache-2.0
1,686
/** * Copyright © 2013, Adam Retter * 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 condi...
adamretter/Skullfuck
src/main/scala/skullfuck/BrainfuckVM.scala
Scala
bsd-3-clause
1,721
package com.geeksville.apiproxy import java.util.UUID import com.geeksville.dapi.Envelope /** * These are low level routines called by the GCS to hook into the proxy. When * the proxy calls in the expected sequence of operations are: * * loginUser * * setVehicleId (must be done before any data is sent from that...
geeksville/arduleader
common/src/main/scala/com/geeksville/apiproxy/GCSHooks.scala
Scala
gpl-3.0
2,668
/* * 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 ...
fhueske/flink
flink-table/flink-table-planner-blink/src/main/scala/org/apache/flink/table/planner/plan/schema/FlinkTable.scala
Scala
apache-2.0
1,764
/* * Copyright (C) 2015 DANS - Data Archiving and Networked Services ([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 ...
DANS-KNAW/easy-deposit
src/test/scala/nl.knaw.dans.easy.sword2/ResolveFetchItemsSpec.scala
Scala
apache-2.0
7,232
package com.karasiq.shadowcloud.api import akka.util.ByteString import com.karasiq.common.encoding.Base64 import com.karasiq.shadowcloud.model.utils.IndexScope import com.karasiq.shadowcloud.model.{File, Path} import scala.language.higherKinds object SCApiEncoding { def toUrlSafe(data: ByteString): String = Ba...
Karasiq/shadowcloud
server/autowire-api/src/main/scala/com/karasiq/shadowcloud/api/SCApiEncoding.scala
Scala
apache-2.0
1,045
package io.vamp.common.config import io.vamp.common.util.ObjectUtil import io.vamp.common.{ Config, ConfigFilter, Namespace, NamespaceProvider } import org.json4s.{ DefaultFormats, Formats } import org.junit.runner.RunWith import org.scalatest.junit.JUnitRunner import org.scalatest.{ BeforeAndAfterEach, FlatSpec, Matc...
magneticio/vamp
common/src/test/scala/io/vamp/common/config/ConfigSpec.scala
Scala
apache-2.0
11,268
/* * 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 ...
jasonpet/openwhisk
core/monitoring/user-events/src/main/scala/org/apache/openwhisk/core/monitoring/metrics/OpenWhiskEvents.scala
Scala
apache-2.0
2,919
package scala.slick.compiler import scala.collection.immutable.HashMap import scala.slick.SlickException import scala.slick.util.Logging import scala.slick.ast.{SymbolNamer, Node} /** An immutable, stateless query compiler consisting of a series of phases */ class QueryCompiler(val phases: Vector[Phase]) extends Logg...
retronym/slick
src/main/scala/scala/slick/compiler/QueryCompiler.scala
Scala
bsd-2-clause
5,528
/* * 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 ...
manuzhang/incubator-gearpump
core/src/main/scala/org/apache/gearpump/cluster/worker/Worker.scala
Scala
apache-2.0
21,904
/* * 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/ui/AllExecutionsPageSuite.scala
Scala
apache-2.0
5,799
/* * 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/transformers/SplitTest.scala
Scala
agpl-3.0
9,825
package core import core.rendering.ViewType import eu.delving.schema.SchemaVersion import models.OrganizationConfiguration import play.api.mvc.RequestHeader /** * * @author Manuel Bernhardt <[email protected]> */ trait RecordResolverService { /** * Retrieves a record given a global hubId * * @...
delving/culture-hub
web-core/app/core/RecordResolverService.scala
Scala
apache-2.0
982
package com.mesosphere.cosmos.error import cats.data.Ior import com.mesosphere.universe.common.circe.Encoders._ import com.netaporter.uri.Uri import io.circe.JsonObject import io.circe.syntax._ final case class RepositoryNotPresent(nameOrUri: Ior[String, Uri]) extends CosmosError { override def data: Option[JsonObj...
takirala/cosmos
cosmos-common/src/main/scala/com/mesosphere/cosmos/error/RepositoryNotPresent.scala
Scala
apache-2.0
906
package eu.stratosphere.peel.datagen.flink import eu.stratosphere.peel.datagen.flink.Distributions._ import eu.stratosphere.peel.datagen.util.RanHash import org.apache.flink.api.scala._ import org.apache.flink.core.fs.FileSystem import org.apache.flink.util.NumberSequenceIterator object WordGenerator { val SEED = ...
carabolic/peel-wordcount-bundle
peel-wordcount-flink-datagens/src/main/scala/eu/stratosphere/peel/datagen/flink/WordGenerator.scala
Scala
apache-2.0
2,183
/* __ *\\ ** ________ ___ / / ___ __ ____ Scala.js API ** ** / __/ __// _ | / / / _ | __ / // __/ (c) 2013-2015, LAMP/EPFL ** ** __\\ \\/ /__/ __ |/ /__/ __ |/_// /_\\ \\ http://scala-js.org/ ** ** /____/\\___/...
lrytz/scala-js
library/src/main/scala/scala/scalajs/js/annotation/JSFullName.scala
Scala
bsd-3-clause
763
import org.automanlang.adapters.mturk.DSL._ import org.automanlang.core.logging.LogLevelDebug import org.automanlang.core.policy.aggregation.UserDefinableSpawnPolicy object SimpleCheckboxProgram extends App { val opts = Utilities.unsafe_optparse(args, "simple_checkbox_program") implicit val a = mturk ( access...
dbarowy/AutoMan
apps/simple/SimpleCheckboxProgram/src/main/scala/SimpleCheckboxProgram.scala
Scala
gpl-2.0
1,227
/** * Copyright (C) 2012 Typesafe, Inc. <http://www.typesafe.com> */ package org.pantsbuild.zinc.compiler import java.io.File import java.nio.file.attribute.BasicFileAttributes import java.nio.file.{FileVisitResult, Files, Path, Paths, SimpleFileVisitor} import java.util.jar.{JarEntry, JarInputStream, JarOutputStre...
twitter/pants
src/scala/org/pantsbuild/zinc/compiler/OutputUtils.scala
Scala
apache-2.0
3,830
package co.ledger.wallet.web.ripple.i18n import scala.scalajs.js /** * * TranslateProvider * ledger-wallet-ripple-chrome * * Created by Pierre Pollastri on 02/06/2016. * * The MIT License (MIT) * * Copyright (c) 2016 Ledger * * Permission is hereby granted, free of charge, to any person obtainin...
LedgerHQ/ledger-wallet-ripple
src/main/scala/co/ledger/wallet/web/ripple/i18n/TranslateProvider.scala
Scala
mit
1,912
/*********************************************************************** * Copyright (c) 2013-2015 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 ...
giserh/geomesa
geomesa-jobs/src/main/scala/org/locationtech/geomesa/jobs/scalding/taps/AccumuloLocalTap.scala
Scala
apache-2.0
6,453
package gapt.proofs.lk.rules import gapt.expr.Expr import gapt.expr.formula.Formula import gapt.proofs.HOLSequent import gapt.proofs.Sequent import gapt.proofs.context.Context import gapt.proofs.context.facet.ProofNames case class ProofLink( referencedProof: Expr, referencedSequent: Sequent[Formula] ) extends Initial...
gapt/gapt
core/src/main/scala/gapt/proofs/lk/rules/ProofLink.scala
Scala
gpl-3.0
727
package jigg.ml.keras /* Copyright 2013-2015 Hiroshi Noji 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/licencses/LICENSE-2.0 Unless required by applicabl...
tomeken-yoshinaga/jigg
src/main/scala/jigg/ml/keras/Flatten.scala
Scala
apache-2.0
901
/* * 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 ...
lvdongr/spark
sql/core/src/main/scala/org/apache/spark/sql/DataFrameReader.scala
Scala
apache-2.0
33,845
/* * Copyright 2014 The Guardian * * 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...
rtyley/play-git-hub
src/main/scala/com/madgag/time/Implicits.scala
Scala
gpl-3.0
2,330
package net.tobysullivan.shorturl.test import net.tobysullivan.shorturl._ object Configuration { val MYSQL_HOSTNAME: String = "192.168.33.10" val MYSQL_USERNAME: String = "root" val MYSQL_PASSWORD: String = "root" val MYSQL_DATABASE: String = "shorturl" // You can optionally use the following InMemory stor...
tobyjsullivan/shorturl
src/test/scala/net/tobysullivan/shorturl/test/Configuration.scala
Scala
mit
686
package net.sansa_stack.owl.spark.rdd import com.typesafe.scalalogging.{Logger => ScalaLogger} import net.sansa_stack.owl.common.parsing.{RDFXMLSyntaxParsing, RDFXMLSyntaxPrefixParsing} import org.apache.hadoop.io.Text import org.apache.hadoop.mapred.JobConf import org.apache.log4j.{Level, Logger => Log4JLogger} impor...
SANSA-Stack/SANSA-RDF
sansa-owl/sansa-owl-spark/src/main/scala/net/sansa_stack/owl/spark/rdd/RDFXMLSyntaxOWLExpressionsRDDBuilder.scala
Scala
apache-2.0
4,438
/** * Copyright (c) 2014 MongoDB, Inc. * * 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 Licen...
antonnik/code-classifier
naive_bayes/resources/scala/MongoScalaBuild.scala
Scala
apache-2.0
5,718
package views.html import play.templates._ import play.templates.TemplateMagic._ import play.api.templates._ import play.api.templates.PlayMagic._ import models._ import controllers._ import java.lang._ import java.util._ import scala.collection.JavaConversions._ import scala.collection.JavaConverters._ import play....
eduardgamiao/Mepedia
target/scala-2.10/src_managed/main/views/html/Devault.template.scala
Scala
gpl-3.0
2,541
package cromwell.core.retry import cromwell.core.retry.Retry._ import cromwell.core.{CromwellFatalException, TestKitSuite} import org.scalatest.concurrent.ScalaFutures import org.scalatest.time.{Millis, Seconds, Span} import org.scalatest.{FlatSpecLike, Matchers} import scala.concurrent.Future class RetrySpec extend...
ohsu-comp-bio/cromwell
core/src/test/scala/cromwell/core/retry/RetrySpec.scala
Scala
bsd-3-clause
2,604
package com.productfoundry.akka.cqrs.process import com.productfoundry.akka.serialization.Persistable case class DeduplicationEntry(deduplicationId: String) extends Persistable
Product-Foundry/akka-cqrs
core/src/main/scala/com/productfoundry/akka/cqrs/process/DeduplicationEntry.scala
Scala
apache-2.0
179
package io.getquill.context.jasync import com.github.jasync.sql.db.Connection import scala.concurrent.ExecutionContext case class TransactionalExecutionContext(ec: ExecutionContext, conn: Connection) extends ExecutionContext { def execute(runnable: Runnable): Unit = ec.execute(runnable) def reportFailure...
getquill/quill
quill-jasync/src/main/scala/io/getquill/context/jasync/TransactionalExecutionContext.scala
Scala
apache-2.0
377
package utils import java.io.File import breeze.linalg._ import scala.reflect.ClassTag import scala.util.Random /** * A collection of utilities useful for matrices. */ object MatrixUtils extends Serializable { /** * Converts a matrix to an array of row arrays. * @param mat Input matrix. * @return Arr...
o0neup/keystone
src/main/scala/utils/MatrixUtils.scala
Scala
apache-2.0
2,184
package fly.play.aws import java.net.URLEncoder import java.util.{Calendar, Date, TimeZone} import akka.util.ByteString import fly.play.s3.S3SpecSetup import play.api.libs.ws.{BodyWritable, InMemoryBody, WSRequest} import play.api.test.WsTestClient import scala.collection.mutable import scala.language.reflectiveCall...
Rhinofly/play-s3
src/test/scala/fly/play/aws/Aws4SignerSpec.scala
Scala
mit
16,832
package blended.activemq.brokerstarter.internal import org.apache.activemq.broker.region.Destination import org.apache.activemq.broker.region.policy.DeadLetterStrategy import org.apache.activemq.broker.{BrokerPluginSupport, ProducerBrokerExchange} import org.apache.activemq.command.{ActiveMQDestination, ActiveMQMessag...
woq-blended/blended
blended.activemq.brokerstarter/src/main/scala/blended/activemq/brokerstarter/internal/TTLEnforcingBrokerPlugin.scala
Scala
apache-2.0
1,852
package filodb.standalone import scala.concurrent.duration._ import akka.actor.ActorRef import akka.remote.testkit.MultiNodeConfig import com.typesafe.config.{Config, ConfigFactory} import org.scalatest.concurrent.ScalaFutures import org.scalatest.time.{Millis, Seconds, Span} import filodb.coordinator._ import filod...
velvia/FiloDB
standalone/src/multi-jvm/scala/filodb/standalone/ClusterSingletonFailoverSpec.scala
Scala
apache-2.0
10,685
package com.github.mdr.graphospasm.grapheditor.actions import org.eclipse.gef.ui.actions.Clipboard import org.eclipse.gef.ui.actions.SelectionAction import org.eclipse.ui.ISharedImages import org.eclipse.ui.IWorkbenchPart import org.eclipse.ui.PlatformUI import org.eclipse.ui.actions.ActionFactory import scala.collect...
mdr/graphospasm
com.github.mdr.graphospasm.grapheditor/src/main/scala/com/github/mdr/graphospasm/grapheditor/actions/CopyAction.scala
Scala
mit
1,800
/* * 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 u...
spark0001/spark2.1.1
sql/core/src/main/scala/org/apache/spark/sql/execution/streaming/HDFSMetadataLog.scala
Scala
apache-2.0
17,869
/* * 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 ...
zuotingbing/spark
external/avro/src/main/scala/org/apache/spark/sql/avro/AvroOutputWriter.scala
Scala
apache-2.0
3,197
package scl import java.awt class SwHsep(h:Int=10) extends swing.Separator(swing.Orientation.Horizontal) { maximumSize = new swing.Dimension(Integer.MAX_VALUE, h) } object SwUtil { val svgColors = Map("black"->"#000000","navy"->"#000080","darkblue"->"#00008B","mediumblue"->"#0000CD","blue"->"#0000FF", ...
tardigrade888/scsvlog
repo/src/scl/SwUtil.scala
Scala
mit
9,420
package mist.api import mist.api.data.JsMap import mist.api.encoding.JsSyntax._ import org.scalatest.{FunSpec, Matchers} import shadedshapeless.HNil class WithArgsScalaSpec extends FunSpec with Matchers { import mist.api.ArgsInstances._ import mist.api.encoding.defaults._ import WithArgsScala._ it("should a...
Hydrospheredata/mist
mist-lib/src/test/scala/mist/api/WithArgsScalaSpec.scala
Scala
apache-2.0
1,535
/* * 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 ...
BryanCutler/spark
sql/core/src/main/scala/org/apache/spark/sql/execution/command/ddl.scala
Scala
apache-2.0
37,460
package ir.ast import ir._ import ir.interpreter.Interpreter.ValueMap import lift.arithmetic.Cst /** * Indexed array UnsafeArrayAccess pattern * * Code for this pattern can be generated */ case class UnsafeArrayAccess(index: Expr) extends Pattern(arity = 1) { override def checkType(argType: Type, ...
lift-project/lift
src/main/ir/ast/UnsafeArrayAccess.scala
Scala
mit
855
/***************************************** Emitting Generated Code *******************************************/ class Snippet extends ((Int)=>(Int)) { def apply(x0:Int): Int = { val x1 = x0 == 0 val x3 = if (x1) { val x2 = if (x1) { 0 } else { 2 } x2 } else { ...
RomanTsegelskyi/lms-truffle
src/out/dynvar0.check.scala
Scala
gpl-2.0
451
package tin import bin.A import bin.B import bin.C import bin.D import bon.G class FixImport extends G { val x = new /*ref*/E } /* package tin import bin._ import _root_.tin.bon.G class FixImport extends G { val x = new E } */
advancedxy/intellij-scala
testdata/autoImport/fixingImport/FixImport.scala
Scala
apache-2.0
234
/* * Copyright 2018 Analytics Zoo 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...
intel-analytics/analytics-zoo
zoo/src/main/scala/com/intel/analytics/zoo/pipeline/api/keras/layers/Embedding.scala
Scala
apache-2.0
6,041
/* SyncQueue.scala * * Copyright (c) 2013 bizo.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 applica...
lpryor/squishy
src/main/scala/squishy/SyncQueue.scala
Scala
apache-2.0
8,569
package com.softwaremill.codebrag.service.email.sender case class AttachmentDescription(content: Array[Byte], filename: String, contentType: String)
softwaremill/codebrag
codebrag-service/src/main/scala/com/softwaremill/codebrag/service/email/sender/AttachmentDescription.scala
Scala
agpl-3.0
150
package scalanlp.classify import scalanlp.data.Example import scalala.tensor.Counter import scalala.generic.collection.CanCreateZerosLike import scalala.operators._ /** * * @author dlwh */ @serializable trait Perceptron[L,-T] extends Classifier[L,T]; object Perceptron { class Trainer[L,T](maxPasses: Int = 20)(...
MLnick/scalanlp-core
learn/src/main/scala/scalanlp/classify/Perceptron.scala
Scala
apache-2.0
1,406
/** * (C) Copyright IBM Corp. 2015 - 2017 * * 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 applicabl...
ecurtin/spark-bench
cli/src/main/scala/com/ibm/sparktc/sparkbench/workload/exercise/SparkPi.scala
Scala
apache-2.0
2,470
package fpinscala.chap04.errorhandling import scala.util.{Try, Success, Failure} object Parsing { /** * Traverse a list and apply a function that can fail to each element. * * Take a list, apply a function which returns an Option * to each element of the list and if none are None, * return an Op...
grscheller/scheller-linux-archive
grok/Scala2/fpinscala/src/main/scala/fpinscala/errorhandling/exerciseCode/scalaErrorhandling.scala
Scala
bsd-3-clause
3,602
/** * 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...
stealthly/kafka
core/src/test/scala/unit/kafka/server/LeaderElectionTest.scala
Scala
apache-2.0
7,066
/* * Copyright 2008-present MongoDB, 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 ag...
rozza/mongo-scala-driver
driver/src/test/scala/org/mongodb/scala/DistinctObservableSpec.scala
Scala
apache-2.0
2,896
package io.netflow package flows.cflow import java.net.{ InetAddress, InetSocketAddress } import java.util.UUID import com.datastax.driver.core.utils.UUIDs import com.twitter.util.Future import io.netflow.actors.SenderWorker import io.netflow.flows.cflow.TemplateFields._ import io.netflow.lib._ import io.netty.buffer...
ayscb/netflow
netflow1/netflow-master/src/main/scala/io/netflow/flows/cflow/NetFlowV9.scala
Scala
apache-2.0
11,680
package adni import com.tencent.angel.worker.storage.MemoryDataBlock import com.tencent.angel.worker.task.{BaseTask, TaskContext} import org.apache.commons.logging.LogFactory import org.apache.hadoop.io.{LongWritable, Text} import structures.{CSRMatrix, Row} import scala.language.implicitConversions /** * Created by...
LiteML/EmbedLib
src/main/scala/adni/AdTrainTask.scala
Scala
apache-2.0
2,164
package knot.data.buffers import java.nio.ByteOrder import scala.annotation.tailrec class DefaultBufferInput(sink: InputSink) extends BufferInput { private[this] val _order: ByteOrder = ByteOrder.nativeOrder() private[this] var _buffer: UnsafeArrayBuffer = _ /** * read position of "current buffer" */ ...
defvar/knot
knot-data/src/main/scala/knot/data/buffers/DefaultBufferInput.scala
Scala
mit
2,701
package gitbucket.core.service import gitbucket.core.GitBucketCoreModule import gitbucket.core.util.{DatabaseConfig, FileUtil} import gitbucket.core.util.SyntaxSugars._ import io.github.gitbucket.solidbase.Solidbase import liquibase.database.core.H2Database import liquibase.database.jvm.JdbcConnection import gitbucket...
x-way/gitbucket
src/test/scala/gitbucket/core/service/ServiceSpecBase.scala
Scala
apache-2.0
3,508
// Copyright: 2010 - 2018 https://github.com/ensime/ensime-server/graphs // License: http://www.gnu.org/licenses/gpl-3.0.en.html package org.ensime.model import org.ensime.api import org.ensime.api._ import org.ensime.core.{ FqnToSymbol, RichPresentationCompiler } import org.ensime.indexer.MethodName import org.ensime...
yyadavalli/ensime-server
core/src/main/scala/org/ensime/model/ModelBuilders.scala
Scala
gpl-3.0
13,317
package org.jetbrains.plugins.scala package refactoring.introduceVariable import com.intellij.openapi.editor.Editor import com.intellij.openapi.project.Project import com.intellij.openapi.util.TextRange import com.intellij.psi.PsiElement import com.intellij.psi.util.PsiTreeUtil import org.jetbrains.plugins.scala.lang....
LPTK/intellij-scala
test/org/jetbrains/plugins/scala/refactoring/introduceVariable/IntroduceVariableTestUtil.scala
Scala
apache-2.0
3,342
package benchmark import tiscaf._ object ServerOk extends HServer { def main(args: Array[String]): Unit = { try { new HStop("localhost", 8911) stop } catch { case _: Exception => } Thread.sleep(600) start } protected def ports = Set(8910) protected lazy val apps = List(theApp) override protec...
gnieh/tiscaf
core/src/test/scala/benchmark/ServerOk.scala
Scala
lgpl-3.0
1,425