code
stringlengths
3
1.05M
repo_name
stringlengths
4
116
path
stringlengths
4
991
language
stringclasses
9 values
license
stringclasses
15 values
size
int32
3
1.05M
<?php use Stecman\Passnote\Object\ReadableEncryptedContent; use Stecman\Passnote\Object\ReadableEncryptedContentTrait; class ObjectController extends ControllerBase { public static function getObjectUrl(StoredObject $object) { return 'object/' . $object->getUuid(); } public function indexActi...
stecman/passnote
app/controllers/ObjectController.php
PHP
mit
6,009
import { globalShortcut } from 'electron' import playbackControls from '../actions/playbackControls' function initGlobalShortcuts () { globalShortcut.register('MediaNextTrack', playbackControls.clickNextSong) globalShortcut.register('MediaPreviousTrack', playbackControls.clickPreviousSong) globalShortcut.registe...
ashokfernandez/kiste
src/shortcuts/initGlobalShortcuts.js
JavaScript
mit
483
// Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. // Code generated by Microsoft (R) AutoRest Code Generator. package com.azure.resourcemanager.automation.models; import com.azure.core.annotation.Fluent; import com.azure.core.util.logging.ClientLogger; import com.azure.re...
Azure/azure-sdk-for-java
sdk/automation/azure-resourcemanager-automation/src/main/java/com/azure/resourcemanager/automation/models/ConnectionListResult.java
Java
mit
2,244
# # The MIT License(MIT) # # Copyright(c) 2016 Copyleaks LTD (https://copyleaks.com) # # 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 t...
Copyleaks/Ruby-Plagiarism-Checker
lib/copyleaks/models/exceptions/auth_exipred_exception.rb
Ruby
mit
1,349
<?php /** * Přidá parametr lang=LANG_CODE za každý odkaz na stránce * * @param String $link upravovaný odkaz * @return String upravený $link */ function icom_edit_permalink($link) { if (icom_is_permalink_struct()) { return ICOM_ABSPATH . icom_current_lang() . "/" . str_replace(ICOM_ABSPATH, "", $link);...
idiomaCoLtd/StreamAPI-wordpress-plugin
stream-api_loading_pages.php
PHP
mit
15,619
/** * @package EntegreJS * @subpackage Widgets * @subpackage fontawesome * @author James Linden <kodekrash@gmail.com> * @copyright 2016 James Linden * @license MIT */ E.widget.fontawesome = class extends E.factory.node { constructor( icon ) { super( 'i' ); this.attr( 'class', `fa fa-${icon.toString().toLo...
entegreio/entegre-js
src/widget/fontawesome.js
JavaScript
mit
1,327
import unittest from app.commands.file_command import FileCommand class TestFileCommand(unittest.TestCase): def setUp(self): self.window = WindowSpy() self.settings = PluginSettingsStub() self.sublime = SublimeSpy() self.os_path = OsPathSpy() # SUT self.command = ...
ldgit/remote-phpunit
tests/app/commands/test_file_command.py
Python
mit
7,821
<?php /** * Created by PhpStorm. * User: Lien * Date: 27/04/2017 * Time: 16:43 */ use app\models\ModelEvents; class ModelEventsTest extends PHPUnit_Framework_TestCase { }
Alevyr/WebAdvancedCodeIgniter2017
application/test/models/ModelEventsTest.php
PHP
mit
179
//https://omegaup.com/arena/problem/El-Arreglo-de-Nieves #include <cstdio> #include <iostream> #include <stack> using namespace std; struct inf { int p, v; }; int nums, totes, mint, stval; int nlist[1000005], tol[1000005], tor[1000005], seen[1000005]; inf lastnp[1000005]; int main() { scanf("%d", &nums); ...
JFAlexanderS/Contest-Archive
OmegaUp/El-Arreglo-de-Nieves.cpp
C++
mit
1,363
/* * Class Name: Constantes * Name: Daniel Arevalo * Date: 13/03/2016 * Version: 1.0 */ package co.edu.uniandes.ecos.tarea4.util; /** * Clase utilitaria de constantes * @...
darevalor/Ecos-Tarea4
src/main/java/co/edu/uniandes/ecos/tarea4/util/Constantes.java
Java
mit
600
<?php if (!class_exists('Paymentwall_Config')) include(getcwd() . '/components/gateways/lib/paymentwall-php/lib/paymentwall.php'); /** * Paymentwall * * @copyright Copyright (c) 2015, Paymentwall, Inc. * @link http://www.paymentwall.com/ Paymentwall */ class Brick extends NonmerchantGateway { ...
paymentwall/module-blesta
src/components/gateways/nonmerchant/brick/brick.php
PHP
mit
16,335
package org.butioy.framework.security; import org.apache.commons.lang3.StringEscapeUtils; import org.apache.commons.lang3.StringUtils; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletRequestWrapper; /** * Created with IntelliJ IDEA. * Author butioy * Date 2015-09-18 2...
butioy/webIM
butioy-framework-src/org/butioy/framework/security/XSSHttpServletRequestWrapper.java
Java
mit
2,507
#include <Esp.h> #include "FS.h" #ifdef ESP32 #include <SPIFFS.h> #endif #include "iotsaFilesUpload.h" #ifdef IOTSA_WITH_WEB void IotsaFilesUploadMod::setup() { } static File _uploadFile; static bool _uploadOK; void IotsaFilesUploadMod::uploadHandler() { if (needsAuthentication("uploadfiles")) return; HTTPUpload...
cwi-dis/iotsa
src/iotsaFilesUpload.cpp
C++
mit
2,362
<?php declare(strict_types=1); /* * This file is part of the humbug/php-scoper package. * * Copyright (c) 2017 Théo FIDRY <theo.fidry@gmail.com>, * Pádraic Brady <padraic.brady@gmail.com> * * For the full copyright and license information, please view the LICENSE * file that was distributed ...
webmozart/php-scoper
specs/static-method/namespace-two-parts-with-single-level-use.php
PHP
mit
2,100
<?php class Auth_Model extends CoreApp\DataModel { public function __construct() { parent::__construct(); $this->PDO = $this->database->PDOConnection(CoreApp\AppConfig::getData("database=>autchenticationDB")); $this->database->PDOClose(); } public function get...
LetsnetHungary/letsnet
App/_models/Auth_Model.php
PHP
mit
1,452
package lua type lValueArraySorter struct { L *LState Fn *LFunction Values []LValue } func (lv lValueArraySorter) Len() int { return len(lv.Values) } func (lv lValueArraySorter) Swap(i, j int) { lv.Values[i], lv.Values[j] = lv.Values[j], lv.Values[i] } func (lv lValueArraySorter) Less(i, j int) bool {...
evanphx/gopher-lua
table.go
GO
mit
4,410
require("kaoscript/register"); var Type = require("@kaoscript/runtime").Type; module.exports = function() { var Shape = require("../export/export.class.default.ks")().Shape; function foobar() { if(arguments.length === 1 && Type.isString(arguments[0])) { let __ks_i = -1; let x = arguments[++__ks_i]; if(x ==...
kaoscript/kaoscript
test/fixtures/compile/export/export.filter.func.import.js
JavaScript
mit
914
/** * Node class * @param {object} value * @constructor */ class Node { constructor(value) { this._data = value; } value() { return this._data; } } export default Node;
jvalen/dstruct-algorithms-examples-js
src/Node/Node.js
JavaScript
mit
190
<!DOCTYPE html> <html lang="en"> <head> @include('includes.head') </head> <body> <div id="wrapper"> <header> @include('includes.navbar') </header> <div class="container"> <div class="row"> <!-- main content --> <div id="content" class="col-md-9"> @...
GrupaZero/platform_l4
app/views/layouts/sidebarRight.blade.php
PHP
mit
671
import URL from 'url'; import * as packageCache from '../../util/cache/package'; import { GitlabHttp } from '../../util/http/gitlab'; import type { GetReleasesConfig, ReleaseResult } from '../types'; import type { GitlabTag } from './types'; const gitlabApi = new GitlabHttp(); export const id = 'gitlab-tags'; export ...
singapore/renovate
lib/datasource/gitlab-tags/index.ts
TypeScript
mit
1,669
var AllDrinks = [{"drinkName": "Alexander", "recipe": "Shake all ingredients with ice and strain contents into a cocktail glass. Sprinkle nutmeg on top and serve.", "image": "https://upload.wikimedia.org/wikipedia/commons/thumb/a/ac/Gin_Alexander_%284371721753%29.jpg/220px-Gin_Alexander_%284371721753%29.jpg...
srs1212/drinkSync
AllDrinks.js
JavaScript
mit
69,466
// // Copyright (c) 2009-2021 Krueger Systems, Inc. // // 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, modify,...
praeclarum/sqlite-net
src/SQLite.cs
C#
mit
158,773
<?xml version="1.0" ?><!DOCTYPE TS><TS language="nl" version="2.1"> <context> <name>AboutDialog</name> <message> <location filename="../forms/aboutdialog.ui" line="+14"/> <source>About IadixCoin</source> <translation>Over IadixCoin</translation> </message> <message> <loca...
iadix/iadixcoin
src/qt/locale/bitcoin_nl.ts
TypeScript
mit
126,834
;(function(){ 'use strict'; angular.module('TTT') .config(function($routeProvider){ $routeProvider .when('/emu',{ templateUrl: 'views/emu.html', controller: 'emuController', controllerAs: 'emu' }); }); })();
beck410/GJ_Timetravel
app/js/config/emu.config.js
JavaScript
mit
247
<?php namespace EloquentJs\ScriptGenerator\Model; class Metadata { /** * @var string */ public $name; /** * @var string */ public $endpoint; /** * @var array */ public $dates; /** * @var array */ public $scopes; /** * @var array ...
parsnick/eloquentjs
src/ScriptGenerator/Model/Metadata.php
PHP
mit
772
@extends('admin.layout') @section('title') Payment @endsection @section('content') <a href="/admin/ff/payment/create/{{$pledge->id}}" class="ui teal button right floated">New Payment</a> <h1 class="ui header">Payments</h1> <div class="ui horizontal divider">{{$pledge->name}}'s <br> Summary </div> <table class="ui un...
yilliot/souls
resources/views/admin/ff/payment_index.blade.php
PHP
mit
3,322
module ActiveSurvey class Visitor def visit_items(items) res = items.map { |item| item.accept(self) } after_visit_items(items, res) end def after_visit_items(items, result) result end def visit_question(item) end def visit_section(item) self.visit_items item.item...
bcardiff/active_survey
lib/active_survey/visitor.rb
Ruby
mit
378
/* The main entry point for the client side of the app */ // Create the main app object this.App = {}; // Create the needed collections on the client side this.Surprises = new Meteor.Collection("surprises"); // Subscribe to the publishes in server/collections Meteor.subscribe('surprises'); // Start the app M...
angelwong/giftedfromus
client/js/main.js
JavaScript
mit
405
// -*- coding: utf-8 -*- // Copyright (C) 2016 Laboratoire de Recherche et Développement // de l'Epita (LRDE). // // This file is part of Spot, a model checking library. // // Spot 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...
mcc-petrinets/formulas
spot/tests/core/parity.cc
C++
mit
16,809
namespace Meeko { partial class Form1 { /// <summary> /// Required designer variable. /// </summary> private System.ComponentModel.IContainer components = null; /// <summary> /// Clean up any resources being used. /// </summary> /// <param name="...
henrikac/Me-e-ko
Meeko/Meeko/Form1.Designer.cs
C#
mit
1,734
// Copyright (c) 2016, Frappe Technologies and contributors // For license information, please see license.txt frappe.ui.form.on('Address Template', { refresh: function(frm) { if(frm.is_new() && !frm.doc.template) { // set default template via js so that it is translated frappe.call({ method: 'frappe.geo....
rohitwaghchaure/frappe
frappe/geo/doctype/address_template/address_template.js
JavaScript
mit
488
using System.Web; using System.Web.Optimization; namespace InsectCatalog { public class BundleConfig { // For more information on bundling, visit http://go.microsoft.com/fwlink/?LinkId=301862 public static void RegisterBundles(BundleCollection bundles) { bundles.A...
NewEvolution/InsectCatalog
InsectCatalog/App_Start/BundleConfig.cs
C#
mit
1,459
class NdlStatAccept < ActiveRecord::Base default_scope :order => :region belongs_to :ndl_statistic attr_accessible :donation, :production, :purchase, :region, :item_type item_type_list = ['book', 'magazine', 'other_micro', 'other_av', 'other_file'] region_list = ['domestic', 'foreign', 'none'] validat...
MiraitSystems/enju_trunk_statistics
app/models/ndl_stat_accept.rb
Ruby
mit
462
<?php defined('BASEPATH') OR exit('No direct script access allowed'); class User extends CI_Controller { public function __construct(){ parent:: __construct(); $this->load->model('engine_model'); } public function add_url(){ $url = $_POST['url']; $id = $_POST['id']; $this->engine_model->add_user_url($...
dav34111/bookmarks
application/controllers/user.php
PHP
mit
591
require "day/tracker/version" module Day module Tracker class Cli < Thor FILE_PATH = File.expand_path("~/.day-tracker") def initialize(*args) super FileUtils.touch FILE_PATH end desc "list", "list recorded days" def list puts File.read(FILE_PATH) end desc "add PROJECT_NAM...
opsb/day-tracker
lib/day/tracker.rb
Ruby
mit
1,005
<?php defined('C5_EXECUTE') or die("Access Denied."); global $c; // grab all the collections belong to the collection type that we're looking at Loader::model('collection_types'); $ctID = $c->getCollectionTypeID(); $ct = CollectionType::getByID($ctID); $cList = $ct->getPages(); ?> <div class="ccm-ui"> <form method="...
tayeke/Klein-Instruments
concrete/elements/block_master_collection_alias.php
PHP
mit
2,644
<?php use yii\helpers\Html; /* @var $this yii\web\View */ /* @var $model AlexanderEmelyanov\yii\modules\articles\models\Article */ $this->title = Yii::t('app', 'Update {modelClass}: ', [ 'modelClass' => 'Article', ]) . ' ' . $model->article_id; $this->params['breadcrumbs'][] = ['label' => Yii::t('app', '...
alexander-emelyanov/yii2-articles-module
views/articles/update.php
PHP
mit
682
<?php use Illuminate\Database\Schema\Blueprint; use Illuminate\Database\Migrations\Migration; class CreateRoadblockTagAndContextTables extends Migration { /** * Run the migrations. * * @return void */ public function up() { if (!Schema::hasTable('roadblocks')) { ...
BBBThunda/projectify
app/database/migrations/2014_09_04_132444_create_roadblock_tag_and_context_tables.php
PHP
mit
3,901
#include <cstdio> #include <algorithm> using namespace std; const int maxn = 111; int arr[maxn]; int main() { //freopen("in.txt", "r", stdin); int n, m; while(2 == scanf("%d%d", &n, &m) && !(n==0 && m==0)) { for(int i = 0; i < n; ++i) scanf("%d", &arr[i]); arr[n] = m; s...
bashell/oj
hdu/2019.cpp
C++
mit
485
using System; using System.Collections.Generic; using System.Linq; using System.Net; using System.Net.Http; using System.Web.Http; namespace ContosoUniversity.WebApi.Controllers { public class ValuesController : ApiController { // GET api/values public IEnumerable<string> Get() { ...
ChauThan/WebApi101
src/ContosoUniversity.WebApi/Controllers/ValuesController.cs
C#
mit
791
/** * A debounce method that has a sliding window, there's a minimum and maximum wait time **/ module.exports = function (cb, min, max, settings) { var ctx, args, next, limit, timeout; if (!settings) { settings = {}; } function fire() { limit = null; cb.apply(settings.context || ctx, args); } function ...
b-heilman/bmoor
src/flow/window.js
JavaScript
mit
935
# -*- coding: utf-8 -*- from flask import Blueprint from jotonce.api import route from jotonce.passphrases.models import Passphrase bp = Blueprint('passphrase', __name__, url_prefix='/passphrase') @route(bp, '/') def get(): p = Passphrase.get_random() return {"results": p}
nficano/jotonce.com
jotonce/api/passphrases.py
Python
mit
285
package ru.lanbilling.webservice.wsdl; import java.util.ArrayList; import java.util.List; import javax.annotation.Generated; import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.XmlRootElement; ...
kanonirov/lanb-client
src/main/java/ru/lanbilling/webservice/wsdl/GetVgroupsAddonsStaffResponse.java
Java
mit
2,337
class AddIndicesToPartialFlow < ActiveRecord::Migration[5.1] def change add_index :partial_flows, [ :is_syn, :state ] add_index :partial_flows, [ :src_ip, :dst_ip, :src_port, :dst_port, :state ], name: 'identify_index' end end
GetPhage/phage
db/migrate/20171029040306_add_indices_to_partial_flow.rb
Ruby
mit
239
#include "background_extractor.h" namespace TooManyPeeps { BackgroundExtractor::BackgroundExtractor(const cv::Mat& original, cv::Mat& result, int historySize, double threshold) : ProcessFilter(original, result) { backgroundExtractor = cv::createBackgroundSubtractorMOG2(historySize, threshold, TRACK_SHA...
99-bugs/toomanypeeps
opencv_detector/src/lib/filter/background_extractor.cpp
C++
mit
783
<?php namespace App; use Doctrine\ORM\Mapping as ORM; /** * @ORM\MappedSuperclass * @ORM\HasLifecycleCallbacks() */ abstract class Entity { /** * @var integer * * @ORM\Column(name="id", type="integer") * @ORM\Id * @ORM\GeneratedValue(strategy="AUTO") */ private $id; /** ...
Meshredded/slim-framework_doctrine_mini_web-service
src/App/Entity.php
PHP
mit
1,676
using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Windows.Forms; namespace RepertoryGridGUI.ufos { public partial class ufoConstructAlternative : Form { public ufoConstru...
felixlindemann/RepertoryGrid
RepertoryGrid/RepertoryGridGUI/ufos/ufoConstructAlternative.cs
C#
mit
407
using System.ComponentModel.DataAnnotations; using EPiServer; using EPiServer.DataAbstraction; using EPiServer.DataAnnotations; using ImageProcessor.Web.Episerver.UI.Blocks.Business; namespace ImageProcessor.Web.Episerver.UI.Blocks.Models.Blocks { [ContentType(DisplayName = "Detect Edges", GUID = "d490901...
vnbaaij/ImageProcessor.Web.Episerver
src/ImageProcessor.Web.Episerver.UI.Blocks/Models/Blocks/DetectEdgesBlock.cs
C#
mit
1,125
public class Solution { public List<List<Integer>> generate(int numRows) { List<List<Integer>> result = new ArrayList<>(); ArrayList<Integer> tmp = new ArrayList<>(); for (int i = 0; i < numRows; i++) { tmp.add(0, 1); for (int j = 1; j < tmp.size() - 1; j++) { ...
liupangzi/codekata
leetcode/Algorithms/118.Pascal'sTriangle/Solution.java
Java
mit
471
if (typeof window !== 'undefined') { var less = require('npm:less/lib/less-browser/index')(window, window.less || {}) var head = document.getElementsByTagName('head')[0]; // get all injected style tags in the page var styles = document.getElementsByTagName('style'); var styleIds = []; for (va...
Aaike/jspm-less-plugin
less.js
JavaScript
mit
2,820
(function () { "use strict"; angular.module("myApp.components.notifications") .factory("KudosNotificationService", KudosNotificationService); KudosNotificationService.$inject = [ "Transaction" ]; function KudosNotificationService(transactionBackend) { var service = { ...
open-kudos/open-kudos-intern-web
src/app/components/kudos-notifications-transaction/kudos-notification-transaction.service.js
JavaScript
mit
722
import numpy as np from pycqed.analysis import measurement_analysis as ma from pycqed.analysis_v2 import measurement_analysis as ma2 from pycqed.measurement import sweep_functions as swf from pycqed.measurement import detector_functions as det MC_instr = None VNA_instr = None def acquire_single_linear_frequency_span...
DiCarloLab-Delft/PycQED_py3
pycqed/measurement/VNA_module.py
Python
mit
12,353
Template.login.events({ 'submit form': function(){ event.preventDefault(); var email = event.target.email.value; var password = event.target.password.value; //error handling Meteor.loginWithPassword(email, password, function(error){ if (error) { alert(error.reason); } else{ Router.go('/'); ...
quanbinn/healthygeek
client/templates/login.js
JavaScript
mit
336
// Copyright Joyent, Inc. and other Node contributors. // // 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, modi...
MTASZTAKI/ApertusVR
plugins/languageAPI/jsAPI/3rdParty/nodejs/10.1.0/source/test/parallel/test-fs-write.js
JavaScript
mit
4,815
using System; using Microsoft.Extensions.DependencyInjection; using ZptSharp.Dom; using ZptSharp.Hosting; namespace ZptSharp { /// <summary> /// Extension methods for <see cref="IBuildsHostingEnvironment"/> instances. /// </summary> public static class XmlHostingBuilderExtensions { /// <sum...
csf-dev/ZPT-Sharp
DocumentProviders/ZptSharp.Xml/XmlHostingBuilderExtensions.cs
C#
mit
1,301
<?php namespace Brasa\RecursoHumanoBundle\Repository; use Doctrine\ORM\EntityRepository; /** * * This class was generated by the Doctrine ORM. Add your own custom * repository methods below. */ class RhuCapacitacionTipoRepository extends EntityRepository { }
wariox3/brasa
src/Brasa/RecursoHumanoBundle/Repository/RhuCapacitacionTipoRepository.php
PHP
mit
270
var through = require('through2'); var cheerio = require('cheerio'); var gulp = require('gulp'); var url = require('url'); var path = require('path'); var fs = require('fs'); var typeMap = { css: { tag: 'link', template: function(contents, el) { var attribute = el.attr('media'); attribute = attri...
jonnyscholes/gulp-inline
index.js
JavaScript
mit
3,543
package strain type Ints []int type Lists [][]int type Strings []string func (i Ints) Keep(filter func(int) bool) Ints { if i == nil { return nil } filtered := []int{} for _, v := range i { if filter(v) { filtered = append(filtered, v) } } i = filtered return i } func (i Ints) Discard(filter func(int...
rootulp/exercism
go/strain/strain.go
GO
mit
862
package main import ( "fmt" "time" "github.com/kevinburke/rct/genetic" ) func main() { files := genetic.GetOldFiles(1 * time.Hour) for _, file := range files { fmt.Println(file) } }
kevinburke/rct
genetic/get_old_experiments/main.go
GO
mit
193
using System; namespace SampleWebAPIApp.Areas.HelpPage.ModelDescriptions { /// <summary> /// Describes a type model. /// </summary> public abstract class ModelDescription { public string Documentation { get; set; } public Type ModelType { get; set; } public string Name { g...
adzhazhev/ASP.NET-Web-Forms
01. Introduction-to-ASP.NET/01. Sample-ASP.NET-Apps/SampleWebAPIApp/Areas/HelpPage/ModelDescriptions/ModelDescription.cs
C#
mit
338
/******************************************************************************* * * MIT License * * Copyright (c) 2017 Advanced Micro Devices, Inc. * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal * ...
ROCmSoftwarePlatform/MIOpen
src/ocl/rnnocl.cpp
C++
mit
222,865
<?php namespace Renovate\MainBundle\Controller; use Symfony\Bundle\FrameworkBundle\Controller\Controller; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpFoundation\Response; use Renovate\MainBundle\Entity\Vacancy; use Renovate\MainBundle\Entity\Document; class VacanciesController extends Con...
oligarch777/renovate
src/Renovate/MainBundle/Controller/VacanciesController.php
PHP
mit
3,444
class AddMemberAddressFragments < ActiveRecord::Migration def up add_column :members, :street_address, :string add_column :members, :address_locality, :string add_column :members, :address_region, :string add_column :members, :address_country, :string add_column :members, :postal_code, :string ...
theodi/member-directory
db/migrate/20150303135313_add_member_address_fragments.rb
Ruby
mit
889
using System; using System.ComponentModel; using System.Diagnostics; using System.Runtime.InteropServices; // https://stackoverflow.com/a/34384189 namespace PS4Macro.Classes.GlobalHooks { public class GlobalKeyboardHookEventArgs : HandledEventArgs { public GlobalKeyboardHook.KeyboardState Ke...
komefai/PS4Macro
PS4Macro/Classes/GlobalHooks/GlobalKeyboardHook.cs
C#
mit
9,190
module Rapa class AlternateVersion # @return [Hash] attr_reader :source # @param source [Hash] def initialize(source) @source = source end # @return [String] def asin source["ASIN"] end # @return [String] def binding source["Binding"] end # @return...
r7kamura/rapa
lib/rapa/alternate_version.rb
Ruby
mit
384
/** * \file * \brief Implementions of RL domains, Mountain Car (MC), HIV, and Bicycle. * * Copyright (c) 2008-2014 Robert D. Vincent. */ #include <vector> #include <utility> #include <cmath> #include <string.h> using namespace std; #include "domain.h" #include "random.h" /** Returns the sign of a real number. ...
rdvincent/fqi
domain.cpp
C++
mit
13,528
'use strict'; angular.module('app.directives') .directive('questionBlock',function() { return { restrict: 'E', scope: { question:'=' }, templateUrl:'/directives/questions/question-block.html' }; });
pwithers/agrippa
public/js/directives/question-block.js
JavaScript
mit
244
from asyncio import coroutine import pytest from aiohttp import HttpBadRequest, HttpMethodNotAllowed from fluentmock import create_mock from aiohttp_rest import RestEndpoint class CustomEndpoint(RestEndpoint): def get(self): pass def patch(self): pass @pytest.fixture def endpoint(): r...
atbentley/aiohttp-rest
tests/test_endpoint.py
Python
mit
2,542
package main import ( "log" "os" "golang.org/x/net/context" "google.golang.org/grpc" // "google.golang.org/grpc/credentials/oauth" "google.golang.org/grpc/metadata" m "github.com/konjoot/grpc/proto/messages" s "github.com/konjoot/grpc/proto/sessions" ) const sessionAddr = "localhost:50051" const messageAddr...
konjoot/grpc
cmd/messages/client/main.go
GO
mit
1,558
'use strict'; var _ = require('lodash'); var utils = require('../utils'); var d3 = require('d3'); var sunCalc = require('suncalc'); var geocoder = require('geocoder'); var Path = require('svg-path-generator'); var margin = { top: 20, right: 0, bottom: 20, left: 0 }; var dayOfYear = function(d) { ...
mathisonian/sunrise
src/js/viz/viz.js
JavaScript
mit
11,928
// All symbols in the `Runic` script as per Unicode v10.0.0: [ '\u16A0', '\u16A1', '\u16A2', '\u16A3', '\u16A4', '\u16A5', '\u16A6', '\u16A7', '\u16A8', '\u16A9', '\u16AA', '\u16AB', '\u16AC', '\u16AD', '\u16AE', '\u16AF', '\u16B0', '\u16B1', '\u16B2', '\u16B3', '\u16B4', '\u16B5', '\u16B6', '\u...
mathiasbynens/unicode-data
10.0.0/scripts/Runic-symbols.js
JavaScript
mit
1,010
/////////////////////////////////////////////////////////////////////////////// // Copyright (c) Lewis Baker // Licenced under MIT license. See LICENSE.txt for details. /////////////////////////////////////////////////////////////////////////////// #ifndef CPPCORO_TESTS_COUNTED_HPP_INCLUDED #define CPPCORO_TESTS_COUNTE...
lewissbaker/cppcoro
test/counted.hpp
C++
mit
1,141
#! /usr/bin/python # -*- coding: utf-8 -*- """ Created on Fri Jan 27 18:31:59 2017 @author: katsuya.ishiyama """ from numpy import random # Definition of module level constants SUCCESS_CODE = 1 FAILURE_CODE = 0 class Strategy(): def __init__(self, n): _success_probability = _generate_success_proba...
Katsuya-Ishiyama/simulation
strategy/strategy.py
Python
mit
2,013
<?php use Illuminate\Support\Facades\Schema; use Illuminate\Database\Schema\Blueprint; use Illuminate\Database\Migrations\Migration; use Illuminate\Database\Eloquent\SoftDeletes; class CreateImagesTable extends Migration { //use SoftDeletes; /** * Run the migrations. * * @return void */ ...
timitek/GetRealTLanding
database/migrations/2017_10_24_142738_create_images_table.php
PHP
mit
908
package de.v13dev.designpatterns.util; import java.util.List; /** * Created by stebo on 22.03.17. */ public class TestHelper { public static boolean isSortedAscending(List<Integer> list) { if(list.size() < 2) return true; for(int i = 1; i < list.size(); i++) { if(list.get(i - 1) > ...
ste-bo/designpatterns
src/test/java/de/v13dev/designpatterns/util/TestHelper.java
Java
mit
705
import { FormGroup } from '@angular/forms'; export class PasswordMatchValidator { static validate(passwordFormGroup: FormGroup) { const password = passwordFormGroup.controls.password.value; const repeatPassword = passwordFormGroup.controls.password_confirmation.value; if (repeatPassword.length <= ...
aviabird/angularspree
src/app/shared/custom-validator/password-match-validator.ts
TypeScript
mit
475
<?php namespace DTR\CrawlerBundle\Services\Crawler; use DTR\CrawlerBundle\Services\Algorithms\PatternIdentifierInterface; use DTR\CrawlerBundle\Services\Inspectors\ComponentInspector; use Symfony\Component\DomCrawler\Crawler; class MenuCrawler implements CrawlerInterface { /** * @var ComponentInspector ...
nfqakademija/dydis-turi-reiksme
src/DTR/CrawlerBundle/Services/Crawler/MenuCrawler.php
PHP
mit
5,270
module Effective module Providers module Free extend ActiveSupport::Concern def free raise('free provider is not available') unless EffectiveOrders.free? @order ||= Order.find(params[:id]) EffectiveResources.authorize!(self, :update, @order) unless @order.free? ...
code-and-effect/effective_orders
app/controllers/effective/providers/free.rb
Ruby
mit
809
package fr.aumgn.bukkitutils.geom; import fr.aumgn.bukkitutils.geom.direction.VectorDirection; import fr.aumgn.bukkitutils.geom.vector.VectorIterator; import org.apache.commons.lang.builder.HashCodeBuilder; import org.bukkit.Location; import org.bukkit.World; import org.bukkit.block.Block; import org.bukkit.entity.Ent...
aumgn/BukkitUtils
src/main/java/fr/aumgn/bukkitutils/geom/Vector.java
Java
mit
6,906
/** * Central storage with in-memory cache */ const fs = require('fs'); const path = require('path'); const mkdirp = require('mkdirp'); const app = process.type === 'renderer' ? require('electron').remote.app : require('electron').app; const _defaultDir = path.join(app.getPath('userData'), 'data'); const _stora...
scholtzm/punk
src/utils/storage.js
JavaScript
mit
1,642
<?php class HtmlTest extends \Codeception\TestCase\Test { /** * @var \CodeGuy */ protected $codeGuy; public function testSend() { $instance = new \Hahns\Response\Html(); $response = $instance->send('<h1>hello world</h1>'); $this->assertEquals('<h1>hello world</h1>', $r...
pklink/Hahns
tests/unit/Response/HtmlTest.php
PHP
mit
680
require 'spec_helper' describe AdminsController do describe 'attempting to access the admin dashboard when not logged in' do before :each do get :index, {:id => 2} end it 'should redirect to the login page' do response.should be_redirect response.should redirect_to('/logi...
Berkeley-BCEF/IntakeApp
spec/controllers/admin_controller_spec.rb
Ruby
mit
343
<?php header("Access-Control-Allow-Origin:*"); ?> <html> <head> <title>TESTS AJAX</title> <style type="text/css"> .bouton,.obj_prec{ margin-left:4px; color:blue; font-size:14px; font-weight:bold; cursor:pointer; } .bouton:hover{ color:#ccc; } #log{ border:1px solid red...
jc-miralles/WebSymfony
web/tests_ajax.php
PHP
mit
4,802
<?php namespace Nemundo\Package\FontAwesome\Icon; use Nemundo\Package\FontAwesome\AbstractFontAwesomeIcon; class TrashIcon extends AbstractFontAwesomeIcon { public function getContent() { $this->icon = 'trash'; return parent::getContent(); } }
nemundo/framework
src/Package/FontAwesome/Icon/TrashIcon.php
PHP
mit
278
import { Component, Input } from '@angular/core'; import { Character } from '../../../data/models/character'; import { LinkLocation } from '../../directive/insertLinks/insertLinks.directive'; @Component({ selector: 'lc-character', templateUrl: 'character.component.html', styleUrls: [ 'character.component.scss' ]...
manuelhuber/LostColonies
src/app/components/character/character.component.ts
TypeScript
mit
450
// Copyright (c) 2011-2016 The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include "coincontroldialog.h" #include "ui_coincontroldialog.h" #include "addresstablemodel.h" #include "bitcoinunits.h" #i...
trippysalmon/bitcoin
src/qt/coincontroldialog.cpp
C++
mit
29,915
<?php /* Safe sample input : use fopen to read /tmp/tainted.txt and put the first line in $tainted Flushes content of $sanitized if the filter number_float_filter is not applied construction : use of sprintf via a %d with simple quote */ /*Copyright 2015 Bertrand STIVALET Permission is hereby granted, without wri...
stivalet/PHP-Vulnerability-test-suite
Injection/CWE_95/safe/CWE_95__fopen__func_FILTER-VALIDATION-number_float_filter__variable-sprintf_%d_simple_quote.php
PHP
mit
1,502
<?php /* * This file is part of App/Validation. * * (c) Alexandre Gomes Gaigalas <alexandre@gaigalas.net> * * For the full copyright and license information, please view the "LICENSE.md" * file that was distributed with this source code. */ namespace App\Validation\Exceptions; class PostalCodeException extend...
Javier-Solis/admin-project
app/Validation/Exceptions/PostalCodeException.php
PHP
mit
662
<?php /******************************/ /* Submission Form Management */ /******************************/ require_once("../includes/admin_init.php"); require_once("../includes/adminAccount.class.php"); require_once("../includes/subForm.class.php"); require_once("../includes/conference.class.php"); /* Intitalize and ou...
jakkub/Confy
src/admin/conference_subform.php
PHP
mit
3,708
'use strict'; /* global $: true */ /* global animation: true */ /* global boidWeights: true */ //Slider for selecting initial number of boids //--------------------------------------------- $('#numBoidsSlider').slider({ min: 0, max: 400, step: 10, value: animation.numBoids }); $('#numBoidsVal').text(...
johhat/boids
ui-components/ui.js
JavaScript
mit
1,967
package test; /** scala> map res6: java.util.HashMap[String,java.util.List[String]] = {AAA=[BBB, CCC, EEE], CCC=[DDD]} scala> test.Test.printCompany(map) -AAA -BBB -CCC -DDD -EEE */ import java.util.HashMap; import java.util.HashSet; import java.util.List; public class Test { public static void printCompany(...
sadikovi/algorithms
careercup/company-structure.java
Java
mit
1,233
<?php /* @var $this UserController */ /* @var $data User */ ?> <div class="view"> <b><?php echo CHtml::encode($data->getAttributeLabel('id')); ?>:</b> <?php echo CHtml::link(CHtml::encode($data->id), array('view', 'id'=>$data->id)); ?> <br /> <b><?php echo CHtml::encode($data->getAttributeLabel('level_id')); ?>:...
felladrin/joinuo
protected/views/user/_view.php
PHP
mit
1,185
# -*- coding: utf-8 -*- # ----------------------------------------------------------------------------- # Copyright 2015 by PyCLibrary Authors, see AUTHORS for more details. # # Distributed under the terms of the MIT/X11 license. # # The full license is in the file LICENCE, distributed with this software. # -----------...
mrh1997/pyclibrary
pyclibrary/c_parser.py
Python
mit
62,500
package com.slicer.utils; import com.badlogic.gdx.Gdx; import com.badlogic.gdx.audio.Sound; import com.badlogic.gdx.files.FileHandle; import com.badlogic.gdx.graphics.Texture; public class AssetLoader { public static Texture bgGame, bgGameOver, bgFinish, score, soundOn, soundOff; public static Sound gameOver...
burakkose/libgdx-game-slicer
core/src/com/slicer/utils/AssetLoader.java
Java
mit
1,612
/* Copyright (c) 2003-2019, CKSource - Frederico Knabben. All rights reserved. For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license */ CKEDITOR.plugins.setLang( 'iframe', 'ko', { border: '프레임 테두리 표시', noUrl: '아이프레임 주소(URL)를 입력해주세요.', scrolling: '스크롤바 사용', title: '아이프레임 속성', to...
otto-torino/gino
ckeditor/plugins/iframe/lang/ko.js
JavaScript
mit
424
/** * Hydro configuration * * @param {Hydro} hydro */ module.exports = function(hydro) { hydro.set({ suite: 'equals', timeout: 500, plugins: [ require('hydro-chai'), require('hydro-bdd') ], chai: { chai: require('chai'), styles: ['should'], stack: true } }...
jkroso/equals
test/hydro.conf.js
JavaScript
mit
324
# -*- coding: utf-8 -*- from datetime import timedelta, datetime import asyncio import random from .api import every, once_at, JobSchedule, default_schedule_manager __all__ = ['every_day', 'every_week', 'every_monday', 'every_tuesday', 'every_wednesday', 'every_thursday', 'every_friday', 'every_saturday', '...
eightnoteight/aschedule
aschedule/ext.py
Python
mit
3,564
import {QueryContext} from "../common/QueryContext"; import {IBoundQueryPart} from "./IBoundQueryPart"; export interface IQueryPart { toCypher(ctx:QueryContext):IBoundQueryPart }
robak86/neography
lib/cypher/abstract/IQueryPart.ts
TypeScript
mit
183
package com.raymond.entrypoint; import org.springframework.beans.factory.annotation.Qualifier; import org.springframework.http.HttpStatus; import org.springframework.security.core.AuthenticationException; import org.springframework.web.bind.annotation.ExceptionHandler; import org.springframework.web.bind.annotation.Re...
RaymondKwong/raymond_projects
services/jwtauth/src/main/java/com/raymond/entrypoint/GlobalExceptionHandler.java
Java
mit
1,163
require 'spec_helper' describe Dashdog do it 'has a version number' do expect(Dashdog::VERSION).not_to be nil end end
serverworks/dashdog
spec/dashdog_spec.rb
Ruby
mit
127