repo_name stringlengths 4 116 | path stringlengths 4 379 | size stringlengths 1 7 | content stringlengths 3 1.05M | license stringclasses 15
values |
|---|---|---|---|---|
MarikMayhem/Software-University | Javascript - Front End/Exam 2.12.2017!!!/events.js | 4059 | let punshes = {
0: {
name: "One Punsh Man",
type: "Strong",
contents: "Very little Vodka, Very little Brendy, Very little Wine, Very little Whiskey, Very little Tequila and a lot of Watermelon Juice.",
description: "This punsh was discovered in an unknown house party, when there was ... | mit |
jessadayim/findtheroom | web/datagrid-backend/datagrid/modules/jscalendar/lang/calendar-tr.js | 1795 | //////////////////////////////////////////////////////////////////////////////////////////////
// Turkish Translation by Nuri AKMAN
// Location: Ankara/TURKEY
// e-mail : nuriakman@hotmail.com
// Date : April, 9 2003
//
// Note: if Turkish Characters does not shown on you screen
// please include falowing line your ... | mit |
okfn/json-table-schema-py | tests/test_schema_constraint_field_type.py | 5705 | # -*- coding: utf-8 -*-
from __future__ import (absolute_import, division, print_function,
unicode_literals)
import io
import json
import os
import pytest
from tableschema import Schema, exceptions, validate
# Tests on built-in constraints - field type consistency
CONSTRAINT_FIELDTYPE_TESTC... | mit |
le-serf/le-serf | bin/le-serf-docked-ships.js | 289 | 'use strict'
let program = require('commander')
let _ = require('lodash')
let runner = require('../lib/cli/task-runner')
program
.option('-p --planet <name>', 'planet(s) to look at')
.parse(process.argv)
let options = _.pick(program, ['planet'])
runner.run('docked-ships', options)
| mit |
UKHomeOffice/passports-prototype | routes/prototype_161124/uploadphoto/index.js | 336 | var app = require('express')(),
wizard = require('hmpo-form-wizard'),
steps = require('./steps'),
fields = require('./fields');
app.use(require('hmpo-template-mixins')(fields, { sharedTranslationKey: 'prototype' }));
app.use(wizard(steps, fields, { templatePath: 'prototype_161124/uploadphoto' }));
module... | mit |
twitchyliquid64/CNC | src/github.com/twitchyliquid64/CNC/data/entity/model.go | 2303 | package entity
import (
"time"
)
var DEFAULT_APIKEY_SIZE = 10
type Entity struct {
ID uint `gorm:"primary_key"`
CreatedAt time.Time
UpdatedAt time.Time
DeletedAt *time.Time
Icon string
CreatorUserID int `sql:"index"`
Name ... | mit |
epsilonz/pretty.rs | benches/trees.rs | 3817 | use std::io;
use criterion::{criterion_group, criterion_main, Bencher, Criterion};
use crate::trees::Tree;
use pretty::{Arena, BoxAllocator};
#[path = "../examples/trees.rs"]
mod trees;
macro_rules! bench_trees {
($b:expr, $out:expr, $allocator:expr, $size:expr) => {{
let arena = typed_arena::Arena::new... | mit |
prvacy/Vk.Api.Schema | src/Vk.Api.Schema/Enums/User/Personal/RelationshipStatus.cs | 1118 |
namespace Vk.Api.Schema.Enums.User
{
/// <summary>
/// Семейное положение
/// </summary>
public enum RelationshipStatus
{
/// <summary>
/// Не указано
/// </summary>
Unknown,
/// <summary>
/// Не женат/замужем
/// </summary>
Single,
... | mit |
Kaltiz/CharacterCards | src/com/kaltiz/cc/character/RpChar.java | 2003 | package com.kaltiz.cc.character;
import java.util.Collections;
import java.util.HashMap;
import java.util.Map;
import com.kaltiz.cc.CharacterCards;
import com.kaltiz.cc.character.field.Field;
import org.bukkit.OfflinePlayer;
public class RpChar
{
private final CharacterCards plugin;
private final OfflinePlayer pla... | mit |
yogeshsaroya/new-cdnjs | ajax/libs/fuelux/2.6.4/all.js | 131 | version https://git-lfs.github.com/spec/v1
oid sha256:26614bda348d8aa968362f9e75138db03e9a8a84544cb32c2aa1438489b67931
size 182558
| mit |
likr/eg-graph | transformer/cycle-removal.js | 486 | const accessor = require('../utils/accessor')
const {CycleRemoval} = require('../layouter/sugiyama/cycle-removal')
const privates = new WeakMap()
class CycleRemovalTransformer {
constructor () {
privates.set(this, {
cycleRemoval: new CycleRemoval()
})
}
transform (graph) {
this.cycleRemoval()... | mit |
haziqhafizuddin/rubocop | spec/rubocop/cop/lint/unified_integer_spec.rb | 1967 | # frozen_string_literal: true
RSpec.describe RuboCop::Cop::Lint::UnifiedInteger do
subject(:cop) { described_class.new(config) }
let(:config) { RuboCop::Config.new }
shared_examples 'registers an offence' do |klass|
context "when #{klass}" do
context 'without any decorations' do
let(:source) ... | mit |
leog/epsilon-root | test/requireConfig.js | 1300 | var tests = [];
for (var file in window.__karma__.files) {
if (window.__karma__.files.hasOwnProperty(file)) {
if (/\.spec\.js$/.test(file)) {
tests.push(file);
}
}
}
requirejs.config({
// Karma serves files from '/base'
baseUrl: '/base/src',
paths: {
// Bower li... | mit |
erykpiast/appetite | node_modules/mathjs/lib/function/trigonometry/sec.js | 1684 | module.exports = function (math) {
var util = require('../../util/index.js'),
Complex = require('../../type/Complex.js'),
Unit = require('../../type/Unit.js'),
collection = require('../../type/collection.js'),
isNumBool = util.number.isNumBool,
isComplex = Complex.isComplex,
isUn... | mit |
chschtsch/kiuss | manage.py | 248 | #!/usr/bin/env python
import os
import sys
if __name__ == "__main__":
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "kiuss.settings")
from django.core.management import execute_from_command_line
execute_from_command_line(sys.argv)
| mit |
darshanhs90/Java-Coding | src/May2021PrepLeetcode/_0013RomanToInteger.java | 1211 | package May2021PrepLeetcode;
public class _0013RomanToInteger {
public static void main(String[] args) {
System.out.println(romanToInt("III"));
System.out.println(romanToInt("IV"));
System.out.println(romanToInt("IX"));
System.out.println(romanToInt("LVIII"));
System.out.println(romanToInt("MCMXCIV"));
}
... | mit |
KhronosGroup/COLLADA-CTS | StandardDataSets/1_5/collada/library_lights/point/point_linear_attenuation_light/point_linear_attenuation_light.py | 4288 |
# Copyright (c) 2012 The Khronos Group Inc.
# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and /or associated documentation files (the "Materials "), to deal in the Materials without restriction, including without limitation the rights to use, copy, modify, merge, publ... | mit |
grunskis/senic-hub | senic_hub/backend/views/setup_config.py | 508 | from cornice.service import Service
from ..commands import create_configuration_files_and_restart_apps_
from ..config import path
from ..supervisor import stop_program
configuration_service = Service(
name='configuration_create',
path=path('setup/config'),
renderer='json',
accept='application/json',
... | mit |
rockmacaca/fabric.js | src/brushes/base_brush.class.js | 2360 | /**
* BaseBrush class
* @class fabric.BaseBrush
* @see {@link http://fabricjs.com/freedrawing|Freedrawing demo}
*/
fabric.BaseBrush = fabric.util.createClass(/** @lends fabric.BaseBrush.prototype */ {
/**
* Color of a brush
* @type String
* @default
*/
color: 'rgb(0, 0, 0)',
/**
* ... | mit |
thest1/Android-VKontakte-SDK | AndroidVkSdkSample/src/com/perm/kate/api/sample/LoginActivity.java | 2450 | package com.perm.kate.api.sample;
import com.perm.kate.api.Auth;
import android.app.Activity;
import android.content.Intent;
import android.graphics.Bitmap;
import android.os.Bundle;
import android.util.Log;
import android.webkit.CookieManager;
import android.webkit.CookieSyncManager;
import android.webkit.WebView;
im... | mit |
panurg/thinking-in-java | access.06/src/App.java | 233 | class Test {
protected int field = 42;
}
public class App {
public static void main(String[] args) {
Test test = new Test();
System.out.println("Test's field: " + test.field);
test.field = 0;
}
}
| mit |
adnanmuhammad/centosnodeoracle | myapp/node_modules/loopback-datasource-juggler/lib/datasource.js | 65582 | // Copyright IBM Corp. 2013,2016. All Rights Reserved.
// Node module: loopback-datasource-juggler
// This file is licensed under the MIT License.
// License text available at https://opensource.org/licenses/MIT
// Turning on strict for this file breaks lots of test cases;
// disabling strict for this file
/* eslint-d... | mit |
pkgodara/Rocket.Chat | packages/rocketchat-smarsh-connector/server/settings.js | 1271 | import moment from 'moment';
import 'moment-timezone';
RocketChat.settings.addGroup('Smarsh', function addSettings() {
this.add('Smarsh_Enabled', false, {
type: 'boolean',
i18nLabel: 'Smarsh_Enabled',
enableQuery: {
_id: 'From_Email',
value: {
$exists: 1,
$ne: '',
},
},
});
this.add('Smarsh... | mit |
jeraldfeller/jbenterprises | google-adwords/vendor/googleads/googleads-php-lib/src/Google/AdsApi/AdWords/v201705/cm/QuotaCheckError.php | 1152 | <?php
namespace Google\AdsApi\AdWords\v201705\cm;
/**
* This file was generated from WSDL. DO NOT EDIT.
*/
class QuotaCheckError extends \Google\AdsApi\AdWords\v201705\cm\ApiError
{
/**
* @var string $reason
*/
protected $reason = null;
/**
* @param string $fieldPath
* @param \Goo... | mit |
jackfrancis/acs-engine | pkg/api/agentPoolOnlyApi/v20180331/merge_test.go | 7234 | // Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT license.
package v20180331
import (
"testing"
"github.com/Azure/acs-engine/pkg/helpers"
)
func TestMerge_DNSPrefix(t *testing.T) {
newMC := &ManagedCluster{
Properties: &Properties{
DNSPrefix: "newprefix",
},
}
exist... | mit |
brunolauze/openpegasus-providers-old | src/Providers/UNIXProviders/IndicatorLEDCapabilities/UNIX_IndicatorLEDCapabilities.cpp | 3369 | //%LICENSE////////////////////////////////////////////////////////////////
//
// Licensed to The Open Group (TOG) under one or more contributor license
// agreements. Refer to the OpenPegasusNOTICE.txt file distributed with
// this work for additional information regarding copyright ownership.
// Each contributor lice... | mit |
iivchenko/Learning-WCF | WCF/Basics of WFC for .net 3.5 Samples/Chapter_2/Sample_6/Client/Service References/Learning_WCF/Reference.cs | 6591 | //------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.42000
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//--... | mit |
enettolima/magento-training | magento2ce/app/code/Magento/Sales/Test/Unit/Model/Order/Email/Sender/InvoiceSenderTest.php | 9166 | <?php
/**
* Copyright © 2016 Magento. All rights reserved.
* See COPYING.txt for license details.
*/
namespace Magento\Sales\Test\Unit\Model\Order\Email\Sender;
use Magento\Sales\Model\Order\Email\Sender\InvoiceSender;
class InvoiceSenderTest extends AbstractSenderTest
{
/**
* @var \Magento\Sales\Model\Or... | mit |
Azure/azure-sdk-for-java | sdk/resourcemanagerhybrid/azure-resourcemanager-compute/src/main/java/com/azure/resourcemanager/compute/models/BootDiagnostics.java | 2889 | // Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// Code generated by Microsoft (R) AutoRest Code Generator.
package com.azure.resourcemanager.compute.models;
import com.azure.core.annotation.Fluent;
import com.azure.core.util.logging.ClientLogger;
import com.fasterxml.j... | mit |
Bo98/DarkRP | gamemode/modules/fadmin/fadmin/changelevel/cl_changelevelgui.lua | 3182 | local PANEL = {}
AccessorFunc(PANEL, "gamemodeList", "GamemodeList")
AccessorFunc(PANEL, "mapList", "MapList")
function PANEL:Init()
self:SetMouseInputEnabled(true)
self:SetKeyboardInputEnabled(false)
self:SetDeleteOnClose(false)
self:SetTitle("Change level")
self:SetSize(630, ScrH() * 0.8)
... | mit |
AnonymousSheep/BlueSheep | BlueSheep/Common/Protocol/types/game/actions/fight/FightTemporarySpellBoostEffect.cs | 1317 |
// Generated on 12/11/2014 19:02:02
using System;
using System.Collections.Generic;
using System.Linq;
using BlueSheep.Common.IO;
namespace BlueSheep.Common.Protocol.Types
{
public class FightTemporarySpellBoostEffect : FightTemporaryBoostEffect
{
public new const short ID = 207;
public override ... | mit |
enettolima/magento-training | magento2ce/app/code/Magento/Indexer/Cron/ClearChangelog.php | 630 | <?php
/**
* Copyright © 2016 Magento. All rights reserved.
* See COPYING.txt for license details.
*/
namespace Magento\Indexer\Cron;
class ClearChangelog
{
/**
* @var \Magento\Indexer\Model\Processor
*/
protected $processor;
/**
* @param \Magento\Indexer\Model\Processor $processor
*... | mit |
bburnichon/PHPExiftool | lib/PHPExiftool/Driver/Tag/Sony/AFStatus76E10.php | 1073 | <?php
/*
* This file is part of the PHPExifTool package.
*
* (c) Alchemy <support@alchemy.fr>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPExiftool\Driver\Tag\Sony;
use JMS\Serializer\Annotation\ExclusionPolicy;
... | mit |
Yashi100/rhodes3.3.2 | platform/android/Rhodes/jni/src/rhodes.cpp | 9797 | /*------------------------------------------------------------------------
* (The MIT License)
*
* Copyright (c) 2008-2011 Rhomobile, 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 ... | mit |
yogeshsaroya/new-cdnjs | ajax/libs/codemirror/4.8.0/mode/textile/test.min.js | 129 | version https://git-lfs.github.com/spec/v1
oid sha256:04159566a26e0495d9f437d85412831df7325c72e5b86a7b6fbd9a34e117693d
size 6956
| mit |
zrusev/SoftwareUniversity2016 | 12. ExpressJS Fundamentals - Jan 2019/02. NodeJS Web Server Dev Tools/ExerciseNodeMovieDB/handlers/home.js | 855 | const url = require('url');
const fs = require('fs');
const path = require('path');
module.exports = (req, res) => {
req.pathname = req.pathname || url.parse(req.url).pathname;
if (req.pathname === '/' && req.method === 'GET') {
let filePath = path.normalize(path.join(__dirname, '../views/home.html'))... | mit |
Koheron/zynq-sdk | examples/alpha250/phase-noise-analyzer/web/dds.ts | 440 | // Interface for DDS driver
// (c) Koheron
class DDS {
private driver: Driver;
private id: number;
private cmds: Commands;
constructor (private client: Client) {
this.driver = this.client.getDriver('Dds');
this.id = this.driver.id;
this.cmds = this.driver.getCmds();
}
setDDSFreq(channel: numb... | mit |
nevercast/OpenModsLib | src/main/java/openmods/entity/DelayedEntityLoadManager.java | 1401 | package openmods.entity;
import java.util.*;
import net.minecraft.entity.Entity;
import net.minecraft.world.World;
import net.minecraftforge.event.entity.EntityJoinWorldEvent;
import com.google.common.base.Supplier;
import com.google.common.collect.Multimap;
import com.google.common.collect.Multimaps;
import com.goo... | mit |
seferov/request-to-entity-bundle | Event/EntityNotFoundEvent.php | 644 | <?php
namespace Seferov\Bundle\RequestToEntityBundle\Event;
use Symfony\Component\EventDispatcher\Event;
/**
* Class EntityNotFoundEvent.
*/
class EntityNotFoundEvent extends Event
{
const NAME = 'request_to_entity.entity_not_found';
/**
* @var string
*/
private $entity;
public function... | mit |
chhe/livestreamer-twitch-gui | src/test/tests/services/i18n/system-locale.js | 1132 | import { module, test } from "qunit";
import systemLocaleInjector from "inject-loader!services/i18n/system-locale";
module( "services/i18n/system-locale" );
test( "Supported locales", function( assert ) {
const { default: systemLocale } = systemLocaleInjector({
"config": {
locales: {
locales: {
"de... | mit |
cflipse/rom-sql | lib/rom/sql/commands_ext/postgres.rb | 521 | require 'rom/sql/commands/create'
require 'rom/sql/commands/update'
module ROM
module SQL
module Commands
module Postgres
module Create
def insert(tuples)
tuples.map do |tuple|
relation.dataset.returning(*relation.columns).insert(tuple)
end.flatten
... | mit |
smithab/azure-sdk-for-node | lib/services/devTestLabs/lib/operations/costOperations.js | 28419 | /*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is
* regenerated.
*/
... | mit |
sameg14/pagekit | app/system/modules/editor/app/components/image.js | 2799 | /**
* Editor Image plugin.
*/
var Picker = Vue.extend(require('./image-picker.vue'));
module.exports = {
plugin: true,
created: function () {
var vm = this, editor = this.$parent.editor;
if (!editor || !editor.htmleditor) {
return;
}
this.images = [];
... | mit |
cerad/app_account | src/Cerad/Bundle/AccountBundle/Functions/Guid.php | 717 | <?php
namespace Cerad\Bundle\AccountBundle\Functions;
/* ==================================
* Copied from the php manual which in turn copied from some package
* Returns 40 char string
* 5BBD0493-8C84-4036-829F-046E230F7225
*/
class Guid
{
static public function gen()
{
if (function_exists(... | mit |
yogeshsaroya/new-cdnjs | ajax/libs/ace/1.1.3/snippets/text.js | 128 | version https://git-lfs.github.com/spec/v1
oid sha256:c07b4293db68cb30ef9e7ed2e395688602f0979ca858379daee8e91b89ea6cb7
size 111
| mit |
mandino/hotelmilosantabarbara.com | wp-content/plugins/accelerated-mobile-pages/includes/admin-script.js | 4499 | jQuery(function($) {
var reduxOptionSearch = function(){
jQuery('.redux_field_search').typeWatch({
callback:function( searchString ){
searchString = searchString.toLowerCase();
var searchArray = searchString.split(' ');
var pare... | mit |
lowsky/spectacle | src/components/image.test.js | 407 | import React from 'react';
import { mount } from 'enzyme';
import Image from './image';
describe('<Image />', () => {
test('should render correctly.', () => {
const context = { styles: { components: { image: {} } } };
const wrapper = mount(
<Image src="foo.png" display="inline-block" width={2560} heigh... | mit |
rayleyva/zerorpc-python | test/test_reqstream.py | 861 | # -*- coding: utf-8 -*-
# Started by François-Xavier Bourlet <fx@dotcloud.com>, Jan 2012.
from nose.tools import assert_raises
import gevent
from zerorpc import zmq
import zerorpc
def test_rcp_streaming():
endpoint = 'ipc://test_rcp_streaming'
class MySrv(zerorpc.Server):
@zerorpc.rep
def r... | mit |
Azure/azure-sdk-for-net | sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/ManagementPolicySnapShot.Serialization.cs | 2839 | // Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// <auto-generated/>
#nullable disable
using System.Text.Json;
using Azure.Core;
namespace Azure.ResourceManager.Storage.Models
{
public partial class ManagementPolicySnapShot : IUtf8JsonSerializable
{
vo... | mit |
tzpBingo/github-trending | codespace/python/telegram/inline/inlinequeryresultdocument.py | 6083 | #!/usr/bin/env python
#
# A library that provides a Python interface to the Telegram Bot API
# Copyright (C) 2015-2022
# Leandro Toledo de Souza <devs@python-telegram-bot.org>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser Public License as published by
#... | mit |
rafiqsaleh/VERCE | liferay-plugins-sdk-6.1.0/portlets/forward-modelling-portlet/docroot/js/src/GeoExt/data/reader/WmsCapabilities.js | 8515 | /*
* Copyright (c) 2008-2014 The Open Source Geospatial Foundation
*
* Published under the BSD license.
* See https://github.com/geoext/geoext2/blob/master/license.txt for the full
* text of the license.
*/
/*
* @include OpenLayers/Format/WMSCapabilities.js
* @include OpenLayers/Layer/WMS.js
* @include OpenLa... | mit |
vonji/vonji-api | models/request.go | 335 | package models
import "github.com/jinzhu/gorm"
type Request struct {
gorm.Model
Post
Title string
Responses []Response
Views uint
Tags []Tag `gorm:"many2many:request_tags;"`
Status string
Duration uint
Frequency uint
FrequencyUnit string
PeriodStart string
PeriodEnd string
Location... | mit |
aaraashkhan/OmniknightApp | app/src/main/java/app/arsh/omniknightapp/model/injection/ConductorModule.java | 359 | package app.arsh.omniknightapp.model.injection;
import app.arsh.omniknightapp.model.conductor.Conductor;
import dagger.Module;
import dagger.Provides;
import javax.inject.Singleton;
/**
* Created by arash on 1/31/17.
*/
@Module
public class ConductorModule {
@Provides
@Singleton Conductor getConductor() {
... | mit |
wjingzhe/CPP_lab | SB-WinSrc/examples/src/chapt02/bounce/bounce.cpp | 3597 | // Bounce.cpp
// Demonstrates a simple animated rectangle program with GLUT
// OpenGL SuperBible, 3rd Edition
// Richard S. Wright Jr.
// rwright@starstonesoftware.com
#include "../../shared/gltools.h" // OpenGL toolkit
// Initial square position and size
GLfloat x = 0.0f;
GLfloat y = 0.0f;
GLfloat rsize = 25;
// S... | mit |
MOOtaku/nyancoin | src/util.cpp | 36639 | // Copyright (c) 2009-2010 Satoshi Nakamoto
// Copyright (c) 2009-2012 The Bitcoin developers
// Copyright (c) 2011-2012 Litecoin Developers
// Distributed under the MIT/X11 software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "util.h"
#include "sync.h"... | mit |
brianmains/Nucleo.NET | src/Nucleo.OnlineMVPTests/Scenarios/Tabs/FirstTab.ascx.designer.cs | 768 | //------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//----------------------------------------... | mit |
oliviertassinari/material-ui | packages/mui-icons-material/lib/SignalCellular2BarOutlined.js | 1848 | "use strict";
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = void 0;
var React = _interopRequireWildcard(require("react"));
var _createSvgIcon = _interopRequireDefault(require("./utils/createSvg... | mit |
BusTicker/BusTicker-Server | providers/bustime.js | 12725 | var when = require('when');
var rest = require('rest');
var fs = require('fs');
var haversine = require('haversine');
//// Utility Methods ////
var qs = function(params) {
var pairs = [];
var keys = Object.keys(params);
for (var i=0;i<keys.length;i++) {
var key = keys[i];
pairs.push(encode... | mit |
zfinder/zfinder | src/common/store/base.js | 846 | import EventEmitter from 'wolfy87-eventemitter';
import lang from 'zero-lang';
class Store extends EventEmitter {
constructor(options) {
super();
const me = this;
lang.extend(me, options);
me.storage = me.storage || {};
}
get(name, defaultValue) {
const value = this.storage[name];
return... | mit |
PaveWei/nacha | ach/data_types.py | 25698 | import math
import re
import string
from datetime import datetime
"""
Collection of classes that comprise the row type objects
in a nacha file
"""
class AchError(Exception):
pass
class Ach(object):
"""
Base class for ACH record fields
"""
def make_space(self, spaces=1):
"""
Ret... | mit |
totemo/watson | src/watson/model/AnvilBlockModel.java | 1121 | package watson.model;
import watson.db.BlockType;
// --------------------------------------------------------------------------
/**
* Render a stylised wireframe anvil.
*/
public class AnvilBlockModel extends BlockModel
{
// --------------------------------------------------------------------------
/**
* Def... | mit |
chhe/livestreamer-twitch-gui | src/app/utils/node/fs/mkdirp.js | 340 | import { promises as fsPromises } from "fs";
const { mkdir } = fsPromises;
/**
* @param {string} path
* @param {Object?} options
* @param {(string|number)?} options.mode
* @returns {Promise}
*/
export default async function mkdirp( path, options = {} ) {
return mkdir( path, Object.assign( {}, options, { recur... | mit |
guillaumemonet/Rad | src/Rad/Route/Router.php | 5879 | <?php
/*
* The MIT License
*
* Copyright 2017 Guillaume Monet.
*
* 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... | mit |
mmkassem/gitlabhq | spec/lib/gitlab/ci/config/entry/script_spec.rb | 2610 | # frozen_string_literal: true
require 'spec_helper'
RSpec.describe Gitlab::Ci::Config::Entry::Script do
let(:entry) { described_class.new(config) }
describe 'validations' do
context 'when entry config value is array of strings' do
let(:config) { %w(ls pwd) }
describe '#value' do
it 'retu... | mit |
xsthunder/acm | old/week1/02_ac/02.cc | 2310 | const bool test=1;
#include<iostream>
#include<cctype>
#include<algorithm>
#include<cstdio>
#include<cstdlib>
#include<vector>
#include<map>
#include<queue>
#include<set>
#include<cctype>
#include<cstring>
#include<utility>
#include<cmath>
const int inf=0x7fffffff;
#define IF if(test)
#define FI if(!test)
#define gts(s... | mit |
kristianmandrup/pencil | lib/pencil/nodes/tag.js | 3506 |
/*!
* pencil
* Copyright(c) 2013 Gabriele Di Stefano <gabriele.ds@gmail.com>
* MIT Licensed
*/
/**
* Module dependencies.
*/
var pencil = require('../../pencil')
, util = require('../utils')
;
/**
* Expose `Tag`.
*
* @api public
*/
var Tag = module.exports = pencil.define('pencil.tag', {
extend: ... | mit |
AvaloniaUI/AvaloniaEdit | src/AvaloniaEdit/Utils/Deque.cs | 4973 | // Copyright (c) 2014 AlphaSierraPapa for the SharpDevelop Team
//
// 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, co... | mit |
BorealianStudio/OpenSpaceTycoon | Code/Src/OSTData/Universe.cs | 12387 | using System;
using System.Collections.Generic;
namespace OSTData {
/// <summary>
/// Cette classe represente l'univers du jeu. Tout dans le jeu survient dans un univers
/// L'univer est capable de se serialiser pour etre sauve ou construit a partir d'un fichier
/// </summary>
[Serializab... | mit |
LucasYuNju/leanote-desktop-lite | devServer.js | 790 | const express = require('express'); // eslint-disable-line import/no-extraneous-dependencies
const webpack = require('webpack'); // eslint-disable-line import/no-extraneous-dependencies
const path = require('path');
const webpackDevMiddleware = require('webpack-dev-middleware'); // eslint-disable-line import/no-extran... | mit |
veyndan/reddit-client | app/src/main/java/com/veyndan/paper/reddit/api/reddit/model/Comment.java | 1761 | package com.veyndan.paper.reddit.api.reddit.model;
import android.support.annotation.IntRange;
import android.support.annotation.Nullable;
import com.squareup.moshi.Json;
import static com.google.common.base.Preconditions.checkNotNull;
public class Comment extends Submission {
@Json(name = "link_id") private S... | mit |
trivial-space/renderer | .eslintrc.js | 1789 | module.exports = {
env: {
browser: true,
es6: true,
node: true,
},
parser: '@typescript-eslint/parser',
parserOptions: {
project: 'tsconfig.json',
sourceType: 'module',
},
plugins: ['import', '@typescript-eslint', 'prettier'],
extends: [
'plugin:@typescript-eslint/eslint-recommended',
'plugin:@type... | mit |
code42day/dataset | test/index.js | 703 | var dataset = require('dataset');
var ann = document.getElementById('ann'),
bob = document.getElementById('bob');
function equals(actual, expected) {
if (actual !== expected) {
throw new Error(actual + ' is not ' + expected);
}
}
equals(dataset(ann, 'age'), '24');
equals(dataset(ann, 'firstName'), 'Ann');
da... | mit |
darrelljefferson/themcset.com | bin/test/n/d/n.php | 37 | <?php
namespace test\n\d;
class n { } | mit |
Ketler13/ng | src/app/user-list/user-item/user-item.component.spec.ts | 647 | import { async, ComponentFixture, TestBed } from '@angular/core/testing';
import { UserItemComponent } from './user-item.component';
describe('UserItemComponent', () => {
let component: UserItemComponent;
let fixture: ComponentFixture<UserItemComponent>;
beforeEach(async(() => {
TestBed.configureTestingMod... | mit |
Gersom/express-webpack-boilerplate | dist/main.js | 1495 | /******/ (function(modules) { // webpackBootstrap
/******/ // The module cache
/******/ var installedModules = {};
/******/ // The require function
/******/ function __webpack_require__(moduleId) {
/******/ // Check if module is in cache
/******/ if(installedModules[moduleId])
/******/ return installedModu... | mit |
multigraph/js-multigraph | src/parser/json/grid.js | 1007 | var Grid = require('../../core/grid.js');
// "grid": { "color": "#ff00ff", visible: true }
Grid.parseJSON = function (json) {
var grid = new Grid(),
RGBColor = require('../../math/rgb_color.js'),
parseAttribute = require('../../util/parsingFunctions.js').parseAttribute,
... | mit |
Weisses/Ebonheart-Mods | ViesCraft/Archived/1.7.10 - 1558/src/main/java/com/viesis/viescraft/client/entity/render/projectile/v1/RenderItemAirshipOrange.java | 4022 | package com.viesis.viescraft.client.entity.render.projectile.v1;
import net.minecraft.client.Minecraft;
import net.minecraft.client.renderer.GlStateManager;
import net.minecraft.client.renderer.Tessellator;
import net.minecraft.client.renderer.VertexBuffer;
import net.minecraft.client.renderer.entity.Render;
import ne... | mit |
dafe/Sentiment | storage/src/main/java/com/gofish/sentiment/storage/package-info.java | 192 | /**
* @author Luke Herron
*/
@ModuleGen(groupPackage = "com.gofish.sentiment.storage", name = "storage")
package com.gofish.sentiment.storage;
import io.vertx.codegen.annotations.ModuleGen; | mit |
inventree/InvenTree | InvenTree/company/tests.py | 6607 | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.test import TestCase
from django.core.exceptions import ValidationError
import os
from decimal import Decimal
from .models import Company, Contact, ManufacturerPart, SupplierPart
from .models import rename_company_image
from part.models impo... | mit |
pranas/carrierwave-aws | lib/carrierwave/support/uri_filename.rb | 203 | module CarrierWave
module Support
module UriFilename
def self.filename(url)
path = url.split('?').first
URI.decode(path).gsub(/.*\/(.*?$)/, '\1')
end
end
end
end
| mit |
jaredhanson/jsmt | test/data/commonjs/programs/increment/increment.js | 94 | var add = require('math').add;
exports.increment = function(val) {
return add(val, 1);
};
| mit |
ensemblr/llvm-project-boilerplate | include/llvm/tools/clang/lib/Serialization/ASTWriterStmt.cpp | 87992 | //===--- ASTWriterStmt.cpp - Statement and Expression Serialization -------===//
//
// The LLVM Compiler Infrastructure
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===-------------------------------------------------------... | mit |
snphq/generator-sp | generators/app/templates/webpack/_postcss.js | 798 | const webpack = require('webpack');
const defaultPlugins = [
require('postcss-import')({
addDependencyTo: webpack,
}),
require('postcss-size'),
require('postcss-svgo'),
require('postcss-assets')({
basePath: 'app/',
loadPaths: ['images/'],
}),
require('postcss-bem')({
style: 'suit',
se... | mit |
smatyas/symfony | src/Symfony/Component/Form/Tests/Extension/Validator/Type/FormTypeValidatorExtensionTest.php | 6038 | <?php
/*
* This file is part of the Symfony package.
*
* (c) Fabien Potencier <fabien@symfony.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Symfony\Component\Form\Tests\Extension\Validator\Type;
use Symfony\Brid... | mit |
purnama/birokrazy | src/main/java/id/birokrazy/Application.java | 10536 | package id.birokrazy;
import id.birokrazy.service.CsrfHeaderFilter;
import id.birokrazy.service.CustomUserDetailsService;
import id.birokrazy.service.DatabaseCsrfTokenService;
import org.apache.catalina.Context;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.SpringApplic... | mit |
Libaier/Courses | 算法/剑指offer/22.cpp | 1687 | class Solution {
public:
bool IsPopOrder(vector<int> pushV,vector<int> popV) {
int push_size = pushV.size();
int pop_size = popV.size();
if (push_size!=pop_size||push_size==0)
{
return false;
}
stack<int> stk;
int j = 0;
for (int i = 0; i < push_siz... | mit |
OndraM/steward | src/Console/CommandEvents.php | 1719 | <?php declare(strict_types=1);
namespace Lmc\Steward\Console;
/**
* Contains all events dispatched by a Command.
*/
final class CommandEvents
{
/**
* The CONFIGURE event allows you to attach listeners right after any command is
* configured. It allows you to add options or arguments to the command.
... | mit |
Azure/azure-sdk-for-net | sdk/hdinsight/Microsoft.Azure.Management.HDInsight/src/Generated/VirtualMachinesOperations.cs | 30050 | // <auto-generated>
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for
// license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is
// re... | mit |
rclai/meteor-collection-hooks | tests/update_local.js | 3795 | var Collection = typeof Mongo !== "undefined" && typeof Mongo.Collection !== "undefined" ? Mongo.Collection : Meteor.Collection;
Tinytest.addAsync("update - local collection documents should have extra property added before being updated", function (test, next) {
var collection = new Collection(null);
function st... | mit |
jamet-julien/generator-web | generators/app/templates/canvas/webpack.config.js | 1622 | var path = require('path');
var root = path.resolve( __dirname);
var webpack = require('webpack');
var SWPrecacheWebpackPlugin = require('sw-precache-webpack-plugin');
var production = process.argv.indexOf("--prod") > -1
module.exports = {
entry :{
app : [ "babel-polyfill", 'babel-regenerator-runtime... | mit |
bookshelf/bookshelf | docs/scripts/main.js | 452 | (function() {
var navbarHeight = document.querySelector('.main-navbar').offsetHeight;
function scrollWithOffset() {
var targetElement = document.querySelector(':target');
window.scroll({top: targetElement.offsetTop - navbarHeight});
}
window.addEventListener('hashchange', scrollWithOffset, false);
w... | mit |
SUSE/azure-sdk-for-python | azure-graphrbac/azure/graphrbac/operations/objects_operations.py | 7002 | # coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes ... | mit |
starspire/payu | vendor/league/uri/src/Interfaces/UriPart.php | 1444 | <?php
/**
* League.Uri (http://uri.thephpleague.com)
*
* @package League.uri
* @author Ignace Nyamagana Butera <nyamsprod@gmail.com>
* @copyright 2013-2015 Ignace Nyamagana Butera
* @license https://github.com/thephpleague/uri/blob/master/LICENSE (MIT License)
* @version 4.1.1
* @link https://gith... | mit |
ifrsrg/projens-apl | site/application/classes/controller/ajax.php | 17991 | <?php defined('SYSPATH') or die('No direct script access.');
class Controller_Ajax extends ControllerFront {
public function loadInformacoes()
{
$this->info->paginaHTTPS = isHTTPS();
}
public function action_cidade() {
$id = $this->request->post('id_estado');
$selecione = $this->request->post('selecione')... | mit |
iancarnation/AIE_Physics | PhysX-3.2.4_PC_SDK_Core/Samples/SampleFramework/renderer/src/gxm/GXMRenderer.cpp | 30707 | /*
* Copyright 2008-2012 NVIDIA Corporation. All rights reserved.
*
* NOTICE TO USER:
*
* This source code is subject to NVIDIA ownership rights under U.S. and
* international Copyright laws. Users and possessors of this source code
* are hereby granted a nonexclusive, royalty-free license to use this code
* ... | mit |
DimitarSD/Telerik-Academy | 01. Programming/04. High-Quality Code [C#, JavaScript]/10. Unit Testing/SantaseGameEngine.Deck.NUnitTests/DeckNUnitTests.cs | 1939 | using NUnit.Framework;
using Santase.Logic.Cards;
namespace SantaseGameEngine.Deck.NUnitTests
{
[TestFixture]
public class DeckNUnitTests
{
[TestCase(0)]
[TestCase(1)]
[TestCase(2)]
[TestCase(3)]
[TestCase(4)]
[TestCase(5)]
[TestCase(6)]
[Tes... | mit |
bburnichon/PHPExiftool | lib/PHPExiftool/Driver/Tag/XMPXmpMM/ManagedFromVersionID.php | 837 | <?php
/*
* This file is part of the PHPExifTool package.
*
* (c) Alchemy <support@alchemy.fr>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPExiftool\Driver\Tag\XMPXmpMM;
use JMS\Serializer\Annotation\ExclusionPoli... | mit |
47deg/scala-sqlite-droid | core/src/main/scala/com/fortysevendeg/mvessel/statement/PreparedStatement.scala | 11570 | /*
* The MIT License (MIT)
*
* Copyright (C) 2012 47 Degrees, LLC http://47deg.com hello@47deg.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 with... | mit |
guixiaoyuan/workspace | exchange/view/zxing/decoding/DecodeThread.java | 2723 | /*
* Copyright (C) 2008 ZXing authors
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agr... | mit |
esergion/parse-ruby-client | lib/parse/cloud.rb | 516 | # -*- encoding : utf-8 -*-
module Parse
module Cloud
class Function
attr_accessor :function_name
attr_accessor :client
def initialize(function_name, client = nil)
@function_name = function_name
@client = client || Parse.client
end
def uri
Protocol.cloud_func... | mit |