repo_name stringlengths 4 116 | path stringlengths 4 379 | size stringlengths 1 7 | content stringlengths 3 1.05M | license stringclasses 15
values |
|---|---|---|---|---|
VicAMMON/totaljs-documentation | controllers/default.js | 144 | exports.install = function() {
F.route('/', redirect);
};
function redirect() {
this.redirect('/v' + CONFIG('version') + '/en.html');
} | mit |
tomthebuzz/mix | src/QBasicNodeDefinition.cpp | 1192 | /*
This file is part of cpp-ethereum.
cpp-ethereum 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.
cpp-ethereum is distributed in the... | mit |
ychaim/dark-test-v2 | src/util.cpp | 38557 | // Copyright (c) 2009-2010 Satoshi Nakamoto
// Copyright (c) 2009-2012 The Bitcoin 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"
#include "strlcpy.h"
#include "version.h"
#inc... | mit |
kfatehi/node-protocol-analyzer | client/config_window.js | 5169 | module.exports = ConfigWindow;
var RollupWindow = require('./rollup_window');
var $ = require('jquery');
var EventEmitter = require('node-event-emitter').EventEmitter;
function ConfigWindow(){
this.emitter = new EventEmitter();
this.on = this.emitter.on;
this.emit = this.emitter.emit;
this.$el = $('.configurat... | mit |
naoned/phpoaipmh | src/Phpoaipmh/EndpointInterface.php | 3339 | <?php
/**
* PHPOAIPMH Library
*
* @license http://opensource.org/licenses/MIT
* @link https://github.com/caseyamcl/phpoaipmh
* @version 2.0
* @package caseyamcl/phpoaipmh
* @author Casey McLaughlin <caseyamcl@gmail.com>
*
* For the full copyright and license information, please view the LICENSE
* file that w... | mit |
thiagormoreira/guia-comercial | src/AppBundle/Tests/Controller/StateControllerTest.php | 1903 | <?php
namespace AppBundle\Tests\Controller;
use Symfony\Bundle\FrameworkBundle\Test\WebTestCase;
class StateControllerTest extends WebTestCase
{
/*
public function testCompleteScenario()
{
// Create a new client to browse the application
$client = static::createClient();
// Creat... | mit |
drostar/CrackerBarrel | Assets/ThirdParty/Zenject/OptionalExtras/CommandsAndSignals/Command/Binders/CommandBinder4.cs | 3102 | using System;
namespace Zenject
{
// Four parameters
public class CommandBinder<TCommand, TParam1, TParam2, TParam3, TParam4> : CommandBinderBase<TCommand, Action<TParam1, TParam2, TParam3, TParam4>>
where TCommand : Command<TParam1, TParam2, TParam3, TParam4>
{
public CommandBinder(string... | mit |
CodeForCharlotte/cmpd-holiday-gift-backend | backend/common/src/entities/abstract/user.ts | 654 | import { BaseEntity, PrimaryGeneratedColumn, Column, CreateDateColumn, UpdateDateColumn } from 'typeorm';
export default abstract class extends BaseEntity {
@PrimaryGeneratedColumn() id: number;
@Column('text', { name: 'name_first' })
firstName: string;
@Column('text', { name: 'name_last' })
lastName: stri... | mit |
WeenAFK/core | core/src/com/stabilise/util/annotation/Unguarded.java | 659 | package com.stabilise.util.annotation;
import java.lang.annotation.Documented;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
/**
* Indicates that the state of the specified field is technically unguarde... | mit |
textmagic/textmagic-rest-csharp | TextmagicRest/Model/ContactsResult.cs | 409 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using RestSharp.Deserializers;
namespace TextmagicRest.Model
{
/// <summary>
/// List of Contact objects
/// </summary>
public class ContactsResult: BaseModelList
{
[Deserial... | mit |
svelto/svelto | src/widgets/remote/modal/modal.js | 1076 |
// @require ../remote.js
// @require ../widget/widget.js
// @require widgets/modal/modal.js
(function ( $, _, Svelto, Widgets, Factory, Animations ) {
/* CONFIG */
let config = {
name: 'remoteModal',
templates: {
placeholder: _.template ( `
<div class="modal container <%= o.classes.placeho... | mit |
ben-dent/PythonEditor | tests/spec/python-spec.js | 7897 | // An editor needs to be instantiated *before* the tests are run so the
// snippets are created so they can be referenced within the tests. Yay
// JavaScript. :-(
var faux_editor = pythonEditor('fooeditor');
// Test suite for the pythonEditor object.
describe("An editor for MicroPython on the BBC micro:bit:", functio... | mit |
greevex/mpcmf-web | src/apps/mpcmfWeb/modules/authex/routes.php | 449 | <?php
namespace mpcmf\modules\authex;
use mpcmf\modules\moduleBase\moduleRoutesBase;
use mpcmf\system\pattern\singleton;
/**
* Routes map class
*
* @author Gregory Ostrovsky <greevex@gmail.com>
* @date: 2/27/15 1:41 PM
*/
class routes
extends moduleRoutesBase
{
use singleton;
/**
* Register s... | mit |
nordsieck/wendigo | parser/lex_test.go | 1200 | package parser
import (
"go/token"
"testing"
"github.com/nordsieck/defect"
)
func TestScanner_Scan(t *testing.T) {
s := Scanner{}
expected := map[string][]token.Token{
`package main
`: {token.PACKAGE, token.IDENT, token.SEMICOLON},
`package main
import "fmt"
func main(){
fmt.Println("hello world")
}
`: ... | mit |
StefanSinapov/TelerikAcademy | 16. ASP.NET Web Forms/12. ASP.NET AJAX/02. Web Chat (AJAX)/Account/Manage.aspx.designer.cs | 1762 | //------------------------------------------------------------------------------
// <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 |
zksailor534/react-adminlte-dash | __tests__/navbar_navitem.test.js | 1593 | /* eslint-env jest */
/* eslint-disable react/jsx-filename-extension */
import React from 'react';
import { ThemeProvider } from 'styled-components';
import renderer from 'react-test-renderer';
import { mount } from 'enzyme';
import red from '../src/styles/skin-red';
import NavItem from '../src/components/Navbar/NavIt... | mit |
sanu82624/HealthApp | platforms/android/assets/www/appjs/controllers/vendorModule/vendorRequestController.js | 2494 | 'use strict';
angular.module('cmaManagementApp').controller('vendorRequestController',
function(commonUtility, vendorBusiness, constantLoader, serviceLoader){
var vm = this;
vm.requests = [];
function initialized(){
loadAssignedRequests();
}
function loadAs... | mit |
safris-src/org | libx4j/xsb/compiler/src/main/java/org/libx4j/xsb/compiler/processor/model/element/HasPropertyModel.java | 1505 | /* Copyright (c) 2008 lib4j
*
* 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, merge, publish, distri... | mit |
Coregraph/Ayllu | JigSaw - AYPUY - CS/Ayllu_V0.1/src/co/edu/javeriana/ayllu/agents/sessionmanageragent/SMA_ReceiveCARequestGuard.java | 6281 | /*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package co.edu.javeriana.ayllu.agents.sessionmanageragent;
import BESA.Kernel.Agent.Event.DataBESA;
import BESA.Kernel.Agent.Event.EventBESA;
import BESA.Kernel.Agent.GuardBESA;
import BESA.Kernel.System.Directory.AgHan... | mit |
bus-detective/bus-detective | app/serializers/agency_serializer.rb | 125 | class AgencySerializer < ApplicationSerializer
attributes :id, :remote_id, :name, :url, :fare_url, :phone, :timezone
end
| mit |
shiftkey/SignalR | SignalR/Transports/ITransportHeartBeat.cs | 210 | namespace SignalR.Transports
{
public interface ITransportHeartBeat
{
void AddConnection(ITrackingConnection connection);
void MarkConnection(ITrackingConnection connection);
}
}
| mit |
jeraldfeller/jbenterprises | google-adwords/vendor/googleads/googleads-php-lib/src/Google/AdsApi/AdWords/v201705/o/RelatedToQuerySearchParameter.php | 910 | <?php
namespace Google\AdsApi\AdWords\v201705\o;
/**
* This file was generated from WSDL. DO NOT EDIT.
*/
class RelatedToQuerySearchParameter extends \Google\AdsApi\AdWords\v201705\o\SearchParameter
{
/**
* @var string[] $queries
*/
protected $queries = null;
/**
* @param string $Searc... | mit |
dsherret/type-info-ts | src/binders/ts/base/TsDefaultExpressionedBinder.ts | 528 | import {TsNode} from "./../../../compiler";
import {TsFactory} from "./../../../factories";
import {DefaultExpressionedBinder} from "./../../base";
export class TsDefaultExpressionedBinder extends DefaultExpressionedBinder {
constructor(private readonly factory: TsFactory, private readonly node: TsNode) {
... | mit |
cyeagy/dorm | src/main/java/io/github/yeagy/bss/ConnectionSupplier.java | 351 | package io.github.yeagy.bss;
import javax.sql.DataSource;
import java.sql.Connection;
import java.sql.SQLException;
@FunctionalInterface
public interface ConnectionSupplier {
Connection get() throws SQLException;
default ConnectionSupplier from(DataSource dataSource) throws SQLException {
return data... | mit |
technoweenie/model_stubbing | lib/model_stubbing.rb | 3480 | require 'model_stubbing/extensions'
require 'model_stubbing/definition'
require 'model_stubbing/model'
require 'model_stubbing/stub'
module ModelStubbing
# Gets a hash of all current definitions.
def self.definitions() @definitions ||= {} end
# stores {stub => record_id} so that identical stubs keep the same ID
... | mit |
pennersr/django-allauth | allauth/socialaccount/providers/oauth2/views.py | 5634 | from __future__ import absolute_import
from datetime import timedelta
from requests import RequestException
from django.core.exceptions import PermissionDenied
from django.http import HttpResponseRedirect
from django.urls import reverse
from django.utils import timezone
from allauth.exceptions import ImmediateHttpRe... | mit |
plotly/plotly.py | packages/python/plotly/plotly/graph_objs/scattermapbox/marker/colorbar/title/_font.py | 8624 | from plotly.basedatatypes import BaseTraceHierarchyType as _BaseTraceHierarchyType
import copy as _copy
class Font(_BaseTraceHierarchyType):
# class properties
# --------------------
_parent_path_str = "scattermapbox.marker.colorbar.title"
_path_str = "scattermapbox.marker.colorbar.title.font"
_v... | mit |
marbemac/whoot-symfony2 | web/slir/pel-0.9.2/src/PelIfd.php | 38023 | <?php
/* PEL: PHP Exif Library. A library with support for reading and
* writing all Exif headers in JPEG and TIFF images using PHP.
*
* Copyright (C) 2004, 2005, 2006, 2007, 2008 Martin Geisler.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the G... | mit |
mickaelbaudoin/simple-php | src/Core/Dispatcher.php | 958 | <?php
namespace MickaelBaudoin\SimplePhp;
class Dispatcher{
protected $_request;
protected $_controller;
protected $_view;
public function __construct($request, $view)
{
$this->_request = $request;
$this->_view = $view;
$this->_resolveController();
}
public function getRequest()
{
return $this->... | mit |
CTAPbIuMABP/solaris | assets/js/solaris/models/dwarfs/sedna.js | 670 | define([
"require",
"./dwarf"
],function (require, AbstractPlanet) {
"use strict";
var _ = require("underscore");
var Sedna = function () {
};
Sedna.prototype = new AbstractPlanet();
_.extend(Sedna.prototype, {
_options: {
body: {
fillStyle: "#ff0... | mit |
dharapvj/learning-webpack2 | gen/step-02/e56.js | 142 | let addEmp56 = (employees) => {
employees.push(
{id:56, name: 'Evelyn Becker'}
)
return employees;
};
export {addEmp56};
| mit |
Rainbow-Sprinkles/starter-todo4 | application/views/itemlist.php | 152 | {pagination}
<table class="table">
<tr>
<th>ID</th>
<th>Task</th>
<th>Status</th>
</tr>
{display_tasks}
</table> | mit |
furbrain/Coherence | coherence/upnp/core/test/test_utils.py | 6241 | # -*- coding: utf-8 -*-
# Licensed under the MIT license
# http://opensource.org/licenses/mit-license.php
# Copyright 2008, Frank Scholz <coherence@beebits.net>
"""
Test cases for L{upnp.core.utils}
"""
import os
from twisted.trial import unittest
from twisted.python.filepath import FilePath
from twis... | mit |
ceolter/angular-grid | grid-packages/ag-grid-docs/documentation/src/pages/cell-editing/examples/stop-edit-when-grid-loses-focus/main.js | 2549 | var gridOptions = {
columnDefs: [
{ field: 'athlete', minWidth: 160 },
{ field: 'age' },
{ field: 'country', minWidth: 140 },
{ field: 'year', cellEditor: 'yearCellEditor' },
{ field: 'date', minWidth: 140 },
{ field: 'sport', minWidth: 160 },
{ field: 'gold' ... | mit |
rlugojr/jenkins | core/src/main/java/hudson/model/listeners/ItemListener.java | 9366 | /*
* The MIT License
*
* Copyright (c) 2004-2009, Sun Microsystems, Inc., Kohsuke Kawaguchi
*
* 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 l... | mit |
alphagov/signonotron2 | test/helpers/batch_invitations_helper_test.rb | 1979 | require "test_helper"
class BatchInvitationsHelperTest < ActionView::TestCase
context "#batch_invite_organisation_for_user" do
context "when the batch invitation user raises an invalid slug error when asked for organisation_id" do
setup do
@user = FactoryBot.create(:batch_invitation_user, organisat... | mit |
lsui/zui | src/js/button.js | 3250 | /* ========================================================================
* Bootstrap: button.js v3.0.3
* http://getbootstrap.com/javascript/#buttons
* ========================================================================
* Copyright 2011-2014 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootst... | mit |
huoyaoyuan/osu | osu.Game/Beatmaps/Drawables/UpdateableBeatmapBackgroundSprite.cs | 2436 | // Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using System;
using osu.Framework.Allocation;
using osu.Framework.Bindables;
using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
namespace osu.Game.Be... | mit |
alexanderkenndy/music-soa-api | src/main/java/com/kascend/music2/api3/service/security/UserSecurityService.java | 1929 | package com.kascend.music2.api3.service.security;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import org.apache.log4j.Logger;
import com.kascend.frameworkcommons.config.Configer;
public class UserSecurityService extends SecurityService{
private static final Logger log = Logger
.ge... | mit |
tmcgee/cmv-wab-widgets | wab/2.13/widgets/DistanceAndDirection/nls/ro/strings.js | 6522 | define({
"_widgetLabel": "Distanță și direcție",
"tabLineTitle": "Linie",
"tabCircleTitle": "Cerc",
"tabEllipseTitle": "Elipsă",
"tabRingsTitle": "Inele",
"multipleNotationsMessage": " notaţii care se potrivesc cu introducerea dvs. Confirmaţi ce doriţi să folosiţi:",
"invalidCoordinateMessage": "Coordonat... | mit |
jonathanmarvens/jeeves | test/testCaching.py | 33230 | import unittest
import macropy.activate
from sourcetrans.macro_module import macros, jeeves
import JeevesLib
import operator
@jeeves
class TestClass:
def __init__(self, a, b):
self.a = a
self.b = b
@jeeves
class TestClassMethod:
def __init__(self, a, b):
self.a = a
self.b = b
... | mit |
inikoo/fact | libs/yui/yui-2in3/src/lib/yui/2.9.0pr1.2725/build/tabview/tabview.js | 33686 | /*
Copyright (c) 2011, Yahoo! Inc. All rights reserved.
Code licensed under the BSD License:
http://developer.yahoo.com/yui/license.html
version: 2.9.0pr1
*/
(function() {
/**
* The tabview module provides a widget for managing content bound to tabs.
* @module tabview
* @requires yahoo, dom, event, ... | mit |
EndzoneSoftware/CT-patternlib | vendor/pattern-lab/core/src/PatternLab/PatternData/Rule.php | 5029 | <?php
/*!
* Pattern Data Rule Class
*
* Copyright (c) 2014 Dave Olsen, http://dmolsen.com
* Licensed under the MIT license
*
*/
namespace PatternLab\PatternData;
use \PatternLab\Timer;
class Rule {
protected $depthProp;
protected $extProp;
protected $isDirProp;
protected $isFileProp;
protected $searchP... | mit |
tonysneed/Experimental | vNext/VS2015/AspNet5/HelloAspNet5/src/HelloAspNet5.Web/Controllers/ValuesController.cs | 539 | using System.Collections.Generic;
using Microsoft.AspNet.Mvc;
// For more information on enabling MVC for empty projects, visit http://go.microsoft.com/fwlink/?LinkID=397860
namespace HelloAspNet5.Web.Controllers
{
[Route("api/[controller]")]
public class ValuesController : Controller
{
static re... | mit |
nothing628/manga-titan | app/Events/TagAdded.php | 589 | <?php
namespace App\Events;
use Illuminate\Broadcasting\Channel;
use Illuminate\Queue\SerializesModels;
use Illuminate\Broadcasting\PrivateChannel;
use Illuminate\Broadcasting\PresenceChannel;
use Illuminate\Broadcasting\InteractsWithSockets;
use Illuminate\Contracts\Broadcasting\ShouldBroadcast;
use Illuminate\Datab... | mit |
johan--/blynk-server | server/tcp-server/src/main/java/cc/blynk/server/handlers/app/logic/RefreshTokenLogic.java | 1260 | package cc.blynk.server.handlers.app.logic;
import cc.blynk.common.model.messages.Message;
import cc.blynk.server.dao.UserRegistry;
import cc.blynk.server.exceptions.NotAllowedException;
import cc.blynk.server.model.auth.User;
import io.netty.channel.ChannelHandlerContext;
import static cc.blynk.common.model.messages... | mit |
ericshortcut/IAL-002 | src/aula5/Numeracao1A100.java | 228 | package aula5;
public class Numeracao1A100
{
public static void mostrarNumeros()
{
for (int i = 1; i <= 100; i++)
{
System.out.println(i);
}
}
public static void main(String ...strings)
{
mostrarNumeros();
}
}
| mit |
xtremeraceriv/OpenOBC | lib/SPI/SPI.cpp | 4348 | /*
Copyright (c) 2012 <benemorius@gmail.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 the rights to use,
copy, modi... | mit |
IOCoin/iocoin | src/qt/locale/bitcoin_en.ts | 122293 | <?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE TS>
<TS version="2.1" language="en">
<context>
<name>AboutDialog</name>
<message>
<location filename="../forms/aboutdialog.ui" line="+14"/>
<source>About I/OCoin</source>
<translation>About I/OCoin</translation>
</message>
<message... | mit |
peastman/deepchem | deepchem/models/tests/test_torch_model.py | 14787 | import os
import pytest
import deepchem as dc
import numpy as np
import math
import unittest
try:
import torch
import torch.nn.functional as F
has_pytorch = True
except:
has_pytorch = False
try:
import wandb
has_wandb = True
except:
has_wandb = False
@pytest.mark.torch
def test_overfit_subclass_model(... | mit |
goncalvesjoao/react-to-commonJS | boilerplates/basic/spa/js/routes.js | 680 | import Home from './components/Home';
import Layout from './components/Layout';
import ApiDocs from './components/ApiDocs';
import NotFound from './components/NotFound';
import SetConfigExample from './components/ApiDocs/SetConfigExample';
const routes = {
component: Layout,
childRoutes: [
{ path: '/', compone... | mit |
radical-cybertools/ExTASY | examples/grlsd-on-stampede/extasy_gromacs_lsdmap.py | 13334 | #!/usr/bin/env python
__author__ = "Vivek <vivek.balasubramanian@rutgers.edu>"
__copyright__ = "Copyright 2014, http://radical.rutgers.edu"
__license__ = "MIT"
__use_case_name__ = "'Gromacs + LSDMap' simulation-analysis proof-of-concept (ExTASY)."
from radical.ensemblemd import Kernel
from radic... | mit |
mk12/scribbler-bot | src/scribbler/programs/base.py | 6803 | # Copyright 2014 Mitchell Kember. Subject to the MIT License.
"""Implements common functionality for Scribbler programs."""
import math
from time import time
# Short codes for the parameters of the program.
PARAM_CODES = {
'bl': 'beep_len',
'bf': 'beep_freq',
's': 'speed',
'dtt': 'dist_to_time',
... | mit |
hirsch88/generator-hirsch | app/templates/tasks/install.js | 349 | 'use strict';
var gulp = require('gulp');
var install = require('gulp-install');
/**
* INSTALL
* Automatically install npm and bower packages if package.json or
* bower.json is found in the gulp file stream respectively
*/
gulp.task('install', function () {
return gulp
.src(['./bower.json', './package.json'... | mit |
gxy001/Office365-FiveMinuteMeeting | FiveMinuteMeeting.iOS/NewEventDateViewController.designer.cs | 982 | // WARNING
//
// This file has been generated automatically by Xamarin Studio from the outlets and
// actions declared in your storyboard file.
// Manual changes to this file will not be maintained.
//
using Foundation;
using System;
using System.CodeDom.Compiler;
using UIKit;
namespace FiveMinuteMeeting.iOS
{
[Regis... | mit |
anhstudios/swganh | data/scripts/templates/object/tangible/ship/crafted/reverse_engineering/shared_armor_analysis_tool.py | 491 | #### NOTICE: THIS FILE IS AUTOGENERATED
#### MODIFICATIONS MAY BE LOST IF DONE IMPROPERLY
#### PLEASE SEE THE ONLINE DOCUMENTATION FOR EXAMPLES
from swgpy.object import *
def create(kernel):
result = Tangible()
result.template = "object/tangible/ship/crafted/reverse_engineering/shared_armor_analysis_tool.iff"
re... | mit |
sdgdsffdsfff/websocket-injection | src/views/views.py | 904 | import tornado.gen
from tornado.escape import parse_qs_bytes
from core.base import BaseHandler
from core.exceptions import UnexpectedReuqestDataException, InvalidWebSocketURLException
class SQLMapHandler(BaseHandler):
def get(self):
self.post()
@tornado.gen.coroutine
def post(self):
url =... | mit |
qtto/RuneCord | commands/user/sinkhole.js | 555 | module.exports = {
desc: 'Tells you when the next Sinkhole D&D will be.',
cooldown: 5,
task(bot, msg) {
let d = new Date();
let secondsUntil = 3600 - (d.getUTCMinutes() + 30) % 60 * 60 - d.getUTCSeconds();
let minutesUntil = Math.floor(secondsUntil / 60);
let timestr = '';
if (minutesUntil === 0) {
tim... | mit |
szymach/admin-bundle | spec/FSi/Bundle/AdminBundle/Factory/Worker/RequestStackWorkerSpec.php | 675 | <?php
namespace spec\FSi\Bundle\AdminBundle\Factory\Worker;
use FSi\Bundle\AdminBundle\spec\fixtures\Admin\RequestStackAwareElement;
use PhpSpec\ObjectBehavior;
use Symfony\Component\HttpFoundation\RequestStack;
class RequestStackWorkerSpec extends ObjectBehavior
{
public function let(RequestStack $requestStack)... | mit |
kbase/kbase-ui | src/client/modules/lib/kb_lib/props.ts | 5233 |
type PropPath = Array<string> | string;
export function getProp<T>(obj: any, propPath: PropPath): T | undefined {
if (typeof propPath === 'string') {
propPath = propPath.split('.');
} else if (!(propPath instanceof Array)) {
throw new TypeError('Invalid type for key: ' + (typeof propPath));
... | mit |
kataras/gapi | _examples/file-server/basic/main.go | 2385 | package main
import (
"github.com/kataras/iris/v12"
)
func newApp() *iris.Application {
app := iris.New()
app.Favicon("./assets/favicon.ico")
// first parameter is the request path
// second is the system directory
//
// app.HandleDir("/css", iris.Dir("./assets/css"))
// app.HandleDir("/js", iris.Dir("./as... | mit |
seekmas/makoto.local | vendor/sonata-project/formatter-bundle/Resources/public/vendor/ckeditor/plugins/placeholder/lang/pl.js | 436 | /*
Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved.
For licensing, see LICENSE.md or http://ckeditor.com/license
*/
CKEDITOR.plugins.setLang("placeholder","pl",{title:"Właściwości wypełniacza",toolbar:"Utwórz wypełniacz",name:"Nazwa wypełniacza",invalidName:"Wypełniacz nie może być pus... | mit |
radamanthus/bayes_motel | lib/bayes_motel/memory_interface.rb | 2765 | module BayesMotel
module Persistence
class MemoryInterface
def initialize(name)
@classifier = {:name=>name,:data=>{},:total_count=>0}
@documents = {}
end
def delete
@classifier = {:name=>'',:data=>{},:total_count=>0}
end
def increment_total
@classifie... | mit |
alexko13/block-and-frame | app/components/Footer.js | 2464 | import React, { Component } from 'react';
class Footer extends Component {
render() {
return (
<div className="ui vertical footer inverted segment" id="footer">
<div className="ui center aligned container">
<div className="ui inverted stackable divided grid">
... | mit |
vickeetran/hackd.in | compiled/client/lib/lodash/fp/subtract.js | 830 | 'use strict';
var convert = require('./convert'),
func = convert('subtract', require('../subtract'));
func.placeholder = require('./placeholder');
module.exports = func;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL2NsaWVudC9saWIvbG9kYXNoL2ZwL3N1YnRyYWN0Lm... | mit |
oliviertassinari/material-ui | packages/mui-icons-material/lib/esm/TransgenderSharp.js | 592 | import createSvgIcon from './utils/createSvgIcon';
import { jsx as _jsx } from "react/jsx-runtime";
export default createSvgIcon( /*#__PURE__*/_jsx("path", {
d: "M12 8c1.93 0 3.5 1.57 3.5 3.5S13.93 15 12 15s-3.5-1.57-3.5-3.5S10.07 8 12 8zm4.53.38 3.97-3.96V7h2V1h-6v2h2.58l-3.97 3.97C14.23 6.36 13.16 6 12 6s-2.23.36-3... | mit |
3b-fly/controlsjs-jsdoc | node_modules/less/lib/less/tree/paren.js | 590 | "use strict";
Object.defineProperty(exports, "__esModule", { value: true });
var tslib_1 = require("tslib");
var node_1 = tslib_1.__importDefault(require("./node"));
var Paren = function (node) {
this.value = node;
};
Paren.prototype = Object.assign(new node_1.default(), {
type: 'Paren',
genCSS: function (c... | mit |
reneepadgham/diverseui | static/scripts/menu.js | 444 | var menuButton = document.querySelector('.mobile-menu-button');
if (menuButton) {
menuButton.addEventListener('click', function() {
if (document.body.className === 'site') {
document.body.className = 'site open';
} else {
document.body.className = 'site';
}
});
}
var hamburger = document.q... | mit |
sanity-io/sanity | dev/test-studio/parts/tools/css-variables/propertyPreview.js | 2710 | import PropTypes from 'prop-types'
import React from 'react'
import styles from './propertyPreview.css'
// eslint-disable-next-line complexity
export function ThemePropertyPreview({property}) {
if (property.type === 'color') {
return (
<div
className={styles.root}
data-type={property.type}... | mit |
Microsoft/ChakraCore | test/Lib/tostring.js | 5754 | //-------------------------------------------------------------------------------------------------------
// Copyright (C) Microsoft. All rights reserved.
// Licensed under the MIT license. See LICENSE.txt file in the project root for full license information.
//------------------------------------------------------... | mit |
Kiandr/CrackingCodingInterview | Java_SecondVersion/Ch 16. Moderate/Q16_16_Sub_Sort/QuestionB.java | 1038 | package Q16_16_Sub_Sort;
public class QuestionB {
public static int findRightSequenceStart(int[] array) {
int max = Integer.MIN_VALUE;
int lastNo = 0;
for (int i = 0; i < array.length; i++) {
if (max > array[i]) {
lastNo = i;
}
max = Math.max(array[i], max);
}
return lastNo;
}
public stat... | mit |
MrOrz/rumors-api | src/graphql/dataLoaders/__fixtures__/analyticsLoaderFactory.js | 8489 | export default {
'/analytics/doc/article_article0_2019-12-10': {
date: '2019-12-10T00:00:00.000+08:00',
docId: 'article0',
type: 'article',
stats: { webVisit: 1, webUser: 1, lineVisit: 1, lineUser: 1 },
},
'/analytics/doc/article_article0_2019-12-11': {
date: '2019-12-11T00:00:00.000+08:00',
... | mit |
terraswat/hexagram | www/imports/mapPage/shortlist/ShortEntryPres_forBarCharts.js | 5161 | // Presentational component for the short list entry.
import React from 'react';
import PropTypes from 'prop-types';
//import Slider, { Range } from 'rc-slider';
// We can just import Slider or Range to reduce bundle size
// import Slider from 'rc-slider/lib/Slider';
// import Range from 'rc-slider/lib/Range';
//impor... | mit |
ericlink/adms-server | playframework-dist/1.1-src/framework/src/play/mvc/results/RenderTemplate.java | 960 | package play.mvc.results;
import java.util.Map;
import play.exceptions.UnexpectedException;
import play.libs.MimeTypes;
import play.mvc.Http.Request;
import play.mvc.Http.Response;
import play.templates.Template;
/**
* 200 OK with a template rendering
*/
public class RenderTemplate extends Result {
private St... | mit |
YogiAi/site | resources/views/admin/partials/departments-selector.blade.php | 371 | <select name="departments[]" id="departments" multiple="true" class="form-control">
@foreach($departments as $department)
<option value="{{ $department->id }}" {{ in_array($department->id, old('departments', [])) || (isset($object) && $object->departments->contains($department)) ? 'selected' : '' }}>{{ $dep... | mit |
Bugfry/exercises | codeeval/ruby/racing.rb | 201 | last = nil
symbols = ["\\", "|", "/"]
IO.foreach(ARGV[0]){|line|
index = line.index("C") || line.index("_")
line[index] = last.nil? ? "|" : symbols[(last <=> index)+1]
puts line
last = index
}
| mit |
KaloyanchoSt/Telerik-Academy-HW | 1. Programming C#/2. CSharp-Part-2/02. Multidimensional-Arrays/07. LargestAreaInMatrix/Properties/AssemblyInfo.cs | 1446 | using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("07... | mit |
headwayio/voyage | lib/voyage/templates/api_users_controller.rb | 1480 | module Api
module V1
class UsersController < BaseApiController
# Warning:
# By default the ability to create an account via API is left wide open
load_and_authorize_resource except: [:create]
skip_authorization_check only: [:create]
skip_before_action :authenticate_user!, only: [:cre... | mit |
maurer/tiamat | samples/Juliet/testcases/CWE134_Uncontrolled_Format_String/s02/CWE134_Uncontrolled_Format_String__char_environment_printf_83_goodG2B.cpp | 1612 | /* TEMPLATE GENERATED TESTCASE FILE
Filename: CWE134_Uncontrolled_Format_String__char_environment_printf_83_goodG2B.cpp
Label Definition File: CWE134_Uncontrolled_Format_String.label.xml
Template File: sources-sinks-83_goodG2B.tmpl.cpp
*/
/*
* @description
* CWE: 134 Uncontrolled Format String
* BadSource: e... | mit |
cowthan/Ayo2022 | Ayo/ayo-extra/src/main/java/org/ayo/notify/sweet/ProgressHelper.java | 4456 | package org.ayo.notify.sweet;
import android.content.Context;
import org.ayo.notify.R;
public class ProgressHelper {
private ProgressWheel mProgressWheel;
private boolean mToSpin;
private float mSpinSpeed;
private int mBarWidth;
private int mBarColor;
private int mRimWidth;
private int mR... | mit |
arantebillywilson/python-snippets | py2/htp/ch06/fig06_10.py | 1267 | #!/usr/bin/python
#
# fig06_10.py
# Demonstrates use of cgi.FieldStorage with XHTML form.
#
# Author: Billy Wison Arante
# Created: 2016/09/01 EST (America/New York)
#
# Attribution: Python How to Program, 1st Ed. by Deitel & Deitel
#
import cgi
def print_header(title):
"""Prints a simple header"""
print ""... | mit |
codeclimate/codeclimate-eslint | lib/batch_sanitizer.js | 942 | var fs = require("fs");
var MINIFIED_AVG_LINE_LENGTH_CUTOFF = 100;
function BatchSanitizer(files, stderr) {
this.files = files;
this.stderr = stderr || process.stderr;
}
BatchSanitizer.prototype.sanitizedFiles = function() {
var sanitizedFiles = [];
for(var i = 0; i < this.files.length; i++) {
if (this.... | mit |
lrakhman/DontParkThereChicago | db/schema.rb | 2519 | # encoding: UTF-8
# This file is auto-generated from the current state of the database. Instead
# of editing this file, please use the migrations feature of Active Record to
# incrementally modify your database, and then regenerate this schema definition.
#
# Note that this schema.rb definition is the authoritative sou... | mit |
theplant/qor_test | lib/qor_test/gemfile.rb | 1841 | module Qor
module Test
class Gemfile
attr_accessor :options
def initialize options={}
self.options = options
end
def ruby_versions
versions = Qor::Test::Configuration.ruby_versions(options)
versions.empty? ? [RUBY_VERSION] : versions
end
def group_nam... | mit |
chiepomme/TwitterMVGenerator | Assets/UTJ/FrameCapturer/Editor/GBufferRecorderEditor.cs | 2501 | using System;
using UnityEditor;
using UnityEngine;
namespace UTJ.FrameCapturer
{
[CustomEditor(typeof(GBufferRecorder))]
public class ImageSequenceRecorderEditor : RecorderBaseEditor
{
public override void OnInspectorGUI()
{
//DrawDefaultInspector();
var recorder =... | mit |
jeraldfeller/jbenterprises | google-adwords/vendor/googleads/googleads-php-lib/src/Google/AdsApi/AdWords/v201705/cm/RateExceededErrorReason.php | 191 | <?php
namespace Google\AdsApi\AdWords\v201705\cm;
/**
* This file was generated from WSDL. DO NOT EDIT.
*/
class RateExceededErrorReason
{
const RATE_EXCEEDED = 'RATE_EXCEEDED';
}
| mit |
non/scalaz-contrib | spire/main/scala/conversions.scala | 2469 | package scalaz.contrib
package spire
import scalaz.@@
import scalaz.Tags.Multiplication
import _root_.spire.algebra
private[scalaz] trait ToSpireConversions0 {
implicit def scalazSemigroup2Spire[F](implicit m: scalaz.Semigroup[F]): algebra.Semigroup[F] = m.asSpire
implicit def scalazAddSemigroup2Spire[F](implici... | mit |
darshanhs90/Java-InterviewPrep | src/LeetcodeTemplate/_0476NumberComplement.java | 244 | package LeetcodeTemplate;
public class _0476NumberComplement {
public static void main(String[] args) {
System.out.println(findComplement(5));
System.out.println(findComplement(1));
}
public static int findComplement(int num) {
}
}
| mit |
Narentharaa/evnts | app/src/main/java/com/code/hacks/codered/evnts/evnts/adapters/EventListAdapter.java | 8847 | package com.code.hacks.codered.evnts.evnts.adapters;
import android.content.Context;
import android.content.Intent;
import android.content.SharedPreferences;
import android.media.Image;
import android.support.v7.widget.RecyclerView;
import android.view.LayoutInflater;
import android.view.View;
import android.view.View... | mit |
nicoddemus/repo-test | _pytest/unittest.py | 6386 | """ discovery and running of std-library "unittest" style tests. """
from __future__ import absolute_import
import traceback
import sys
import pytest
import py
# for transfering markers
from _pytest.python import transfer_markers
def pytest_pycollect_makeitem(collector, name, obj):
# has unittest been imported... | mit |
StratifyLabs/StratifyAPI | src/ux/Progress.cpp | 665 | /*! \file */ // Copyright 2011-2020 Tyler Gilbert and Stratify Labs, Inc; see LICENSE.md for rights.
#include "ux/Progress.hpp"
using namespace ux;
Progress::Progress(const var::String& name) : ComponentAccess<Progress>(name){
m_value = 0;
m_maximum = 100;
}
void Progress::handle_event(const ux::Event & event){
... | mit |
anhstudios/swganh | data/scripts/templates/object/tangible/deed/city_deed/shared_garden_tatooine_lrg_03_deed.py | 477 | #### NOTICE: THIS FILE IS AUTOGENERATED
#### MODIFICATIONS MAY BE LOST IF DONE IMPROPERLY
#### PLEASE SEE THE ONLINE DOCUMENTATION FOR EXAMPLES
from swgpy.object import *
def create(kernel):
result = Tangible()
result.template = "object/tangible/deed/city_deed/shared_garden_tatooine_lrg_03_deed.iff"
result.attri... | mit |
ValtoFrameworks/Angular-2 | packages/platform-browser-dynamic/test/testing_public_browser_spec.ts | 5206 | /**
* @license
* Copyright Google Inc. All Rights Reserved.
*
* Use of this source code is governed by an MIT-style license that can be
* found in the LICENSE file at https://angular.io/license
*/
import {ResourceLoader} from '@angular/compiler';
import {Compiler, Component, NgModule} from '@angular/core';
impor... | mit |
tapomayukh/projects_in_c_cpp | Phantom Control Program/Cpp_pos_enc/GetState/src/GetStateValues.cpp | 3367 | #include <stdio.h>
#include <stdlib.h>
#include <cassert>
#if defined(WIN32)
# include <conio.h>
#else
# include "conio.h"
#endif
#include <HD/hd.h>
#include <HDU/hdu.h>
#include <HDU/hduError.h>
#include <HDU/hduVector.h>
#include "GetStateValues.h"
#include "C:\Program Files\SensAble\3DTouch\examples\HD\console\Ari... | mit |
hmehr/OSS | MemoryLifter/Development/Current/MLifter.DAL/CSV/Exceptions/MalformedCsvException.cs | 7644 | // MLifter.DAL.CSV.MalformedCsvException
// Copyright (c) 2005 Sébastien Lorion
//
// MIT license (http://en.wikipedia.org/wiki/MIT_License)
//
// 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 Softw... | mit |
maccman/wysiwyg | lib/wysiwyg.js | 4881 | // Generated by CoffeeScript 1.6.2
(function() {
var $, Wysiwyg;
$ = this.jQuery || require('jquery');
Wysiwyg = (function() {
Wysiwyg.prototype.className = 'wysiwyg';
Wysiwyg.prototype.events = {
'click [data-type=bold]': 'bold',
'click [data-type=italic]': 'italic',
'click [data-typ... | mit |
davisk/gateway | gateway/static/js/test/core_movement_test.js | 896 | describe("core game logic movement", function() {
var object = {};
beforeEach(function() {
object.x = 0;
object.y = 0;
});
// Testing regular movement
it("will move object left when left key is pressed", function() {
move(object, 37, '');
expect(object.x).toBe(-5);
... | mit |
panzer13/v2ray-core | main/confloader/errors.generated.go | 208 | package confloader
import "v2ray.com/core/common/errors"
type errPathObjHolder struct{}
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).WithPathObj(errPathObjHolder{})
}
| mit |
nakov/OpenJudgeSystem | Open Judge System/Web/OJS.Web/Areas/Users/ViewModels/UserParticipationViewModel.cs | 496 | namespace OJS.Web.Areas.Users.ViewModels
{
using System;
public class UserParticipationViewModel
{
public int ContestId { get; set; }
public string ContestName { get; set; }
public int? CompeteResult { get; set; }
public int? PracticeResult { get; set; }
public ... | mit |
amervitz/xRM-Portals-Community-Edition | Framework/Adxstudio.Xrm/Web/Mvc/Liquid/CategoryFunctions.cs | 2755 | /*
Copyright (c) Microsoft Corporation. All rights reserved.
Licensed under the MIT License. See License.txt in the project root for license information.
*/
namespace Adxstudio.Xrm.Web.Mvc.Liquid
{
using System;
using System.Collections.Generic;
/// <summary>
/// Category Functions
/// </summa... | mit |