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
namespace AmsterdamPHP\JobBundle\Form;
use AmsterdamPHP\JobBundle\Form\ChoiceList\ContractType;
use Symfony\Component\Form\AbstractType;
use Symfony\Component\Form\FormBuilderInterface;
use Symfony\Component\OptionsResolver\OptionsResolverInterface;
class JobType extends AbstractType
{
public function buil... | AmsterdamPHP/job-board | src/AmsterdamPHP/JobBundle/Form/JobType.php | PHP | mit | 2,149 |
namespace OmniXaml.Typing
{
using System;
using System.Collections.Generic;
using System.Reflection;
using Glass.Core;
public class MetadataProvider
{
private readonly IDictionary<string, AutoKeyDictionary<Type, object>> lookupDictionaries = new Dictionary<string, AutoKeyDictionary<Typ... | Perspex/OmniXAML | Source/OmniXaml/Typing/MetadataProvider.cs | C# | mit | 2,302 |
/****************************************************************************
** Copyright (c) quickfixengine.org All rights reserved.
**
** This file is part of the QuickFIX FIX Engine
**
** This file may be distributed under the terms of the quickfixengine.org
** license as defined by quickfixengine.org and appearin... | SoftFx/FDK | FDK/QuickFix/Log.cpp | C++ | mit | 2,071 |
// --------------------------------------------
// Copyright KAPSARC. Open source MIT License.
// --------------------------------------------
// The MIT License (MIT)
//
// Copyright (c) 2015 King Abdullah Petroleum Studies and Research Center
//
// Permission is hereby granted, free of charge, to any person obtaining... | ambah/KTAB | examples/comsel/src/democomsel.cpp | C++ | mit | 13,110 |
/*
* This file is part of Flow Engine, licensed under the MIT License (MIT).
*
* Copyright (c) 2013 Spout LLC <http://www.spout.org/>
*
* 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 ... | flow/engine | src/main/java/com/flowpowered/engine/network/handler/FlowMessageHandler.java | Java | mit | 2,915 |
package com.joao.pedro.nardari.locationstrategysampleproject;
import android.app.AlarmManager;
import android.app.PendingIntent;
import android.content.Context;
import android.content.Intent;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.view.View;
import android.widget.Toas... | joaopedronardari/LocationStrategySampleProject | app/src/main/java/com/joao/pedro/nardari/locationstrategysampleproject/MainActivity.java | Java | mit | 1,526 |
namespace InControl
{
using System;
using System.IO;
using UnityEngine;
public class MouseBindingSource : BindingSource
{
public Mouse Control { get; protected set; }
public static float ScaleX = 0.05f;
public static float ScaleY = 0.05f;
public static float ScaleZ = 0.05f;
internal MouseBindingSour... | Hekaton/SolarWind | Assets/InControl/Source/Binding/MouseBindingSource.cs | C# | mit | 3,202 |
package com.github.kennedyoliveira.asteriskjava.khomp.manager.event;
import org.asteriskjava.manager.event.ManagerEvent;
/**
* Reports the detection of a {@code Collect Call}.
*
* @author kennedy
*/
public class CollectCallEvent extends ManagerEvent {
private String channel;
public CollectCallEvent(Object s... | kennedyoliveira/asterisk-java-khomp | src/main/java/com/github/kennedyoliveira/asteriskjava/khomp/manager/event/CollectCallEvent.java | Java | mit | 807 |
using AppCampus.Domain.Interfaces.Repositories;
using System;
using System.ComponentModel.DataAnnotations;
namespace AppCampus.PortalApi.Validation.ValidationAttributes
{
public sealed class UniqueCompanyIdAttribute : ValidationAttribute
{
public ICompanyRepository CompanyRepository { get; set; }
... | hendrikdelarey/appcampus | AppCampus.PortalApi/Validation/ValidationAttributes/UniqueCompanyIdAttribute.cs | C# | mit | 727 |
'use strict';
(function(module) {
const repos = {};
repos.all = [];
repos.requestRepos = function(callback) {
$.get('/github/user/repos')
.then(data => repos.all = data, err => console.error(err))
.then(callback(repos));
};
repos.with = attr => repos.all.filter(repo => repo[attr]);
module.... | Jamesbillard12/jamesPortfolio | public/js/repo.js | JavaScript | mit | 347 |
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class GameScene : MonoBehaviour {
void Start () {
GameController gameController = GameController.Instance;
ItemSpawnManager itemSpawnManager = ItemSpawnManager.Instance;
RespawnManager respawnManager = Resp... | sasvdw/LD37 | Unity/LD37/Assets/Scripts/Scenes/GameScene.cs | C# | mit | 411 |
import { Injectable } from '@angular/core';
import { Http, Headers, Response, RequestOptions } from '@angular/http';
import { Observable } from 'rxjs/Observable';
import { AuthenticationService, AlertService } from '../services';
import { DttType } from '../models';
import 'rxjs/add/operator/map'
@Injectable()
export ... | manuelnelson/patient-pal | src/client/services/dtt-type.service.ts | TypeScript | mit | 3,176 |
<?php
namespace Tangent\Bundle\BookTrackerBundle\Controller;
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
class DefaultController extends Controller
{
public function indexAction($name)
{
return $this->render('TangentBookTrackerBundle:Default:index.html.twig', array('name' => $name... | gump/book-tracker | src/Tangent/Bundle/BookTrackerBundle/Controller/DefaultController.php | PHP | mit | 332 |
package com.grapapp.grapapp.adapter;
import android.content.Context;
import android.content.Intent;
import android.os.Bundle;
import android.support.v7.widget.RecyclerView;
import android.util.Log;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.TextVi... | Hz-Ryze/GrapApp | app/src/main/java/com/grapapp/grapapp/adapter/TupianTitleAdapter.java | Java | mit | 2,351 |
require_relative 'gluey/base/version'
require_relative 'gluey/base/exceptions'
# environments
require_relative 'gluey/base/environment'
require_relative 'gluey/workshop/workshop'
require_relative 'gluey/warehouse/warehouse'
# addons
require_relative 'gluey/base/rack_mountable'
| doooby/gluey | lib/gluey.rb | Ruby | mit | 281 |
<?php
namespace Somnambulist\Tenancy\Tests\Stubs\Providers;
use Illuminate\Support\ServiceProvider;
class AppServiceProvider extends ServiceProvider
{
/**
* Register any application services.
*
* @return void
*/
public function register()
{
$this->app->singleton('em', function... | dave-redfern/laravel-doctrine-tenancy | tests/Stubs/Providers/AppServiceProvider.php | PHP | mit | 644 |
<?php
namespace SiteBundle\Repository;
/**
* TagRepository
*
* This class was generated by the Doctrine ORM. Add your own custom
* repository methods below.
*/
class UserGroupRepository extends \Doctrine\ORM\EntityRepository
{
}
| firestorm23/gyrolab-ste | src/SiteBundle/Repository/UserGroupRepository.php | PHP | mit | 236 |
<table >
<?php
$rq = "SELECT acquisto,utente,colloquio FROM acquisti_aperti join utenti using(utente)";
$trs = $db -> query($rq) -> fetchAll(PDO::FETCH_ASSOC);
?>
<?php
foreach ($trs as $k => $q) {
echo "<td style=\"width:1em\" >
<form name=input action=\"cassa.php\" method=POST>
<input type = hidden... | paolino/emporio | selezioneacquisto.php | PHP | mit | 702 |
package com.swallow.core.dom;
import org.w3c.dom.Element;
/**
* Swallow 2017-03-10 15:33
*/
public interface ElementUtil {
static String getAttributeValue(Element element, String name, String defaultValue) {
String value = element.getAttribute(name);
if (!(value == null || "".equals(value))) {
... | zhuzaixiaoshulin/swallow | src/main/java/com/swallow/core/dom/ElementUtil.java | Java | mit | 676 |
using System.Collections.Generic;
namespace Magnesium.OpenGL.Internals
{
public class GLNextPipelineLayout : IGLPipelineLayout
{
public GLUniformBinding[] Bindings { get; private set; }
public int NoOfBindingPoints { get; private set; }
public IDictionary<int, GLBindingPointOffsetInfo> Ranges { get; private s... | tgsstdio/Mg | Magnesium.OpenGL/DescriptorSets/GLNextPipelineLayout.cs | C# | mit | 4,510 |
/**
*
*/
package net.caiban.auth.dashboard.dao.bs.impl;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import javax.annotation.Resource;
import net.caiban.auth.dashboard.dao.BaseDao;
import net.caiban.auth.dashboard.dao.bs.BsDao;
import net.caiban.auth.dashboard.domain.bs.Bs;
import net.ca... | yysoft/yy-auth | auth-dashboard/src/main/java/net/caiban/auth/dashboard/dao/bs/impl/BsDaoImpl.java | Java | mit | 8,217 |
package demo.rest;
import demo.domain.RunningInfo;
import demo.service.RunningInfoService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.PageRequest;
import org.springframework.http.HttpStatus;
import org.springframewo... | zjxjasper/running-info-service | src/main/java/demo/rest/RunningInfoRestController.java | Java | mit | 1,573 |
import {Injectable, EventEmitter, Inject, ElementRef, Renderer, Renderer2} from '@angular/core';
import { DOCUMENT } from '@angular/platform-browser';
import { Router } from '@angular/router';
import { MetaModel } from './meta.model';
export class MetaService {
public url: EventEmitter<string> = new EventEmitter<s... | schmist/dimensions-builder | src/app/meta/meta.service.ts | TypeScript | mit | 3,420 |
const create = require('./create')
const geom2 = require('../geometry/geom2')
const fromPoints = points => {
const geometry = geom2.fromPoints(points)
const newShape = create()
newShape.geometry = geometry
return newShape
}
module.exports = fromPoints
| jscad/csg.js | src/core/shape2/fromPoints.js | JavaScript | mit | 262 |
package com.plexobject.rx.util;
import java.util.Spliterator;
import java.util.function.Consumer;
public class ArraySpliterator<T> implements Spliterator<T> {
private final Object[] array;
private int origin; // current index, advanced on split or traversal
private final int fence; // one past the greates... | bhatti/RxJava8 | src/test/java/com/plexobject/rx/util/ArraySpliterator.java | Java | mit | 1,567 |
/****************************************************************************
Copyright (c) 2010-2011 cocos2d-x.org
Copyright (c) 2008-2010 Ricardo Quesada
http://www.cocos2d-x.org
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "So... | DmitriyKirakosyan/testNinjaX | libs/cocos2dx/layers_scenes_transitions_nodes/CCScene.cpp | C++ | mit | 2,012 |
<?php
namespace Fallen\FallenBundle\Form;
use Symfony\Component\Form\AbstractType;
use Symfony\Component\Form\FormBuilderInterface;
class ContactType extends AbstractType
{
public function buildForm(FormBuilderInterface $builder, array $options)
{
$builder->add('email', 'email', array('attr'=>array('... | laureenw/Projet-Symfony2 | src/Fallen/FallenBundle/Form/ContactType.php | PHP | mit | 681 |
using UnityEngine;
using System.Collections;
using System.Collections.Generic;
// source: https://forum.unity3d.com/threads/a-free-simple-smooth-mouselook.73117/#post-3101292
// added: lockCursor
namespace UnityLibrary
{
public class SmoothMouseLookAveraged : MonoBehaviour
{
[Header("Info")]
p... | UnityCommunity/UnityLibrary | Assets/Scripts/Camera/SmoothMouseLookAveraged.cs | C# | mit | 3,365 |
<?php declare(strict_types=1);
namespace WyriHaximus\Travis\Resource\Sync;
use ApiClients\Foundation\Hydrator\CommandBus\Command\BuildAsyncFromSyncCommand;
use Rx\React\Promise;
use WyriHaximus\Travis\Resource\Repository as BaseRepository;
use WyriHaximus\Travis\Resource\RepositoryInterface;
use WyriHaximus\Travis\Re... | WyriHaximus/php-travis-client | src/Resource/Sync/Repository.php | PHP | mit | 5,196 |
////////////////////////////////////////////////////////////////////////////////
//
// keytreeutil.h
//
// Copyright (c) 2013-2014 Tim Lee
//
// 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 Softwar... | stequald/KeyTree-qt | keytree-qt/keytreeutil.cpp | C++ | mit | 5,198 |
'use strict';
var users = require('../../app/controllers/users.server.controller'),
streams = require('../../app/controllers/streams.server.controller');
module.exports = function(app){
app.route('/api/streams')
.get(streams.list)
.post(users.requiresLogin, streams.create);
app.... | plonsker/onetwo | app/routes/streams.server.routes.js | JavaScript | mit | 599 |
import Reflux from 'reflux';
//TODO: recheck the flow of these actions 'cause it doesn't seem to be OK
export default Reflux.createActions([
'eventPartsReady',
'eventPartsUpdate'
]);
| fk1blow/repeak | src/client/actions/event-part-actions.js | JavaScript | mit | 188 |
<?php
namespace ProductBundle\Form;
use Symfony\Component\Form\AbstractType;
use Symfony\Component\Form\FormBuilderInterface;
use Symfony\Component\OptionsResolver\OptionsResolverInterface;
class SausHotType extends AbstractType
{
/**
* @param FormBuilderInterface $builder
* @param array $options
... | Kelevari/webshop-opdracht | src/ProductBundle/Form/SausHotType.php | PHP | mit | 884 |
// ReSharper disable All
using System;
using System.Configuration;
using System.Diagnostics;
using System.Net.Http;
using System.Runtime.Caching;
using System.Web.Http;
using System.Web.Http.Controllers;
using System.Web.Http.Dispatcher;
using System.Web.Http.Hosting;
using System.Web.Http.Routing;
using Xunit;
namesp... | nubiancc/frapid | src/Frapid.Web/Areas/Frapid.Config/WebApi/Tests/AppRouteTests.cs | C# | mit | 11,134 |
/**
* @license Angular v5.2.2
* (c) 2010-2018 Google, Inc. https://angular.io/
* License: MIT
*/
import { EventEmitter, Injectable } from '@angular/core';
import { __extends } from 'tslib';
import { LocationStrategy } from '@angular/common';
/**
* @fileoverview added by tsickle
* @suppress {checkTypes} checked b... | RJ15/FixIt | badminton/node_modules/@angular/common/esm5/testing.js | JavaScript | mit | 11,979 |
package de.helwich.junit;
import static java.lang.annotation.ElementType.TYPE;
import static java.lang.annotation.RetentionPolicy.RUNTIME;
import java.lang.annotation.Retention;
import java.lang.annotation.Target;
/**
* Annotation used to configure jasmine test runner.
*
* @author Hendrik Helwich
*/
@Target(TYP... | dddpaul/junit-jasmine-runner | src/main/java/de/helwich/junit/JasmineTest.java | Java | mit | 651 |
import javafx.application.Application;
// Scene
import javafx.fxml.FXMLLoader;
import javafx.scene.Parent;
import javafx.scene.Scene;
// Stage
import javafx.stage.Stage;
public class ChessApp extends Application {
public static void main(String[] args) {
launch(args);
}
@Override
public voi... | tlee753/chess-visualizer | src/ChessApp.java | Java | mit | 574 |
function router(handle, pathname, res, postdata) {
console.log('into the router request for->'+pathname);
// var newpathname = pathname;
// var newpostdata = postdata;
// console.log(pathname.lastIndexOf('.'));
var extendNM = pathname.substr(pathname.lastIndexOf('.')+1);
// console.log(extendNM);
// var cssFileR... | noprettyboy/my_portal_page | serverjs/router.js | JavaScript | mit | 744 |
require 'fog/core/model'
module Fog
module Brightbox
class Compute
class LoadBalancer < Fog::Model
identity :id
attribute :url
attribute :name
attribute :status
attribute :resource_type
attribute :nodes
attribute :policy
attribute :healthc... | jbenjore/JPs-love-project | annotate-models/ruby/1.9.1/gems/fog-0.8.1/lib/fog/compute/models/brightbox/load_balancer.rb | Ruby | mit | 1,025 |
package com.eway.payment.sdk.android.entities;
import com.eway.payment.sdk.android.beans.CodeDetail;
import java.util.ArrayList;
public class CodeLookupResponse {
private String Language;
private ArrayList<CodeDetail> CodeDetails;
private String Errors;
public CodeLookupResponse(String errors, Strin... | eWAYPayment/eway-rapid-android | sdk/src/main/java/com/eway/payment/sdk/android/entities/CodeLookupResponse.java | Java | mit | 991 |
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("_1... | dobri19/OldRepos | Telerik/01-Programming-with-C#/01-C#-Fundamentals-2016-October/01-Intro-Programming/16.LongSequence/Properties/AssemblyInfo.cs | C# | mit | 1,426 |
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("Wo... | sharpninja/WorldBankBBS | WorldBankBBS.WCF.Data/Properties/AssemblyInfo.cs | C# | mit | 1,418 |
"use strict"
class Compress extends R.Compressor{
/**
*
*
*/
run(R,compressor){
this.compressBackbone(true);
}
}
module.exports=Compress; | williamamed/Raptor.js | @raptorjs-development/raptor-panel/Compressor/Compress.js | JavaScript | mit | 154 |
# requires all of the integrators at the end of the file
class Metriculator
@@integrations = {}
@parsed, @db_stored, @finished = false, false, false
# integration points are:
@@names = [:on_db_store, :on_finish, :on_metric_parse]
@@names.each {|name| @@integrations[name] = [] }
class << self
## Takes ... | princelab/metriculator | lib/integrators.rb | Ruby | mit | 1,530 |
var parserx = require('parse-regexp')
var EventEmitter = require('events').EventEmitter
var MuxDemux = require('mux-demux')
var remember = require('remember')
var idle = require('idle')
var timestamp = require('monotonic-timestamp')
var from = require('from')
var sync = require(... | dominictarr/rumours_ | index.js | JavaScript | mit | 6,007 |
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace BlackHole.Entity
{
public class UserInfo
{
}
public class BasicUserInfo
{
/// <summary>唯一识别码
///
/// </summary>
public string UserGUID { ... | 1024home/BlackHole | BlackHole/BlackHole.Entity/UserInfo.cs | C# | mit | 711 |
'use strict';
var xpath = require('xpath');
var dom = require('xmldom').DOMParser;
module.exports = function (grunt) {
var xml = grunt.file.read(__dirname + '/../pom.xml');
var doc = new dom().parseFromString(xml);
var select = xpath.useNamespaces({"xmlns": "http://maven.apache.org/POM/4.0.0"});
var... | bheiskell/HungerRain | changelog/Gruntfile.js | JavaScript | mit | 800 |
/*
The MIT License (MIT)
Copyright (c) 2013-2015 winlin
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, p... | Akagi201/srs-librtmp | src/protocol/srs_rtmp_io.hpp | C++ | mit | 5,514 |
using Newtonsoft.Json;
using System.Collections.Generic;
namespace WizBot.Common.Pokemon
{
public class SearchPokemon
{
public class GenderRatioClass
{
public float M { get; set; }
public float F { get; set; }
}
public class BaseStatsClass
{
... | Wizkiller96/WizBot | src/WizBot/Common/Pokemon/SearchPokemon.cs | C# | mit | 1,319 |
package com.tomogle.iemclient.requests;
/**
* Represents a type of request in the IEM API.
* According to the IEM API docs, it represents the 'name of the API file in question'.
*
* We ignore the Java uppercase enum naming convention for ease of use.
*/
public enum RequestType {
subscribers,
authentication,
... | tom-ogle/InterspireEmailMarketerClient | src/main/java/com/tomogle/iemclient/requests/RequestType.java | Java | mit | 338 |
import Class from '../mixin/class';
import Media from '../mixin/media';
import {$, addClass, after, Animation, assign, attr, css, fastdom, hasClass, isNumeric, isString, isVisible, noop, offset, offsetPosition, query, remove, removeClass, replaceClass, scrollTop, toFloat, toggleClass, toPx, trigger, within} from 'uikit... | RadialDevGroup/rails-uikit-sass | vendor/assets/js/core/sticky.js | JavaScript | mit | 8,774 |
// app/models/article.js
var Mongoose = require('mongoose');
// define article schema
var articleSchema = Mongoose.Schema({
url: {
type: String,
required: true
},
tags: [String],
userId: {
type: String,
required: true
},
meta: {
title: String,
author: String,
readTime: String,
summary: String,
... | isaacev/Ink | app/models/article.js | JavaScript | mit | 615 |
#include "ReadAlignChunk.h"
#include "Parameters.h"
#include "OutSJ.h"
#include <limits.h>
#include "ErrorWarning.h"
int compareUint(const void* i1, const void* i2) {//compare uint arrays
uint s1=*( (uint*)i1 );
uint s2=*( (uint*)i2 );
if (s1>s2) {
return 1;
} else if (s1<s2) {
return ... | alexdobin/STAR | source/outputSJ.cpp | C++ | mit | 7,239 |
package sc_zap
import (
"crypto/sha256"
"encoding/base32"
"errors"
"github.com/watermint/toolbox/essentials/log/esl"
"github.com/watermint/toolbox/infra/app"
"github.com/watermint/toolbox/infra/control/app_control"
"github.com/watermint/toolbox/infra/control/app_resource"
"github.com/watermint/toolbox/infra/se... | watermint/toolbox | infra/security/sc_zap/zap.go | GO | mit | 1,823 |
using System;
using Xamarin.Forms;
namespace people
{
public partial class NewItemPage : ContentPage
{
public Item Item { get; set; }
public NewItemPage()
{
InitializeComponent();
Item = new Item
{
Text = "Item name",
... | pjsamuel3/xPlatformDotNet | mac_app/people/Views/NewItemPage.xaml.cs | C# | mit | 624 |
using Abstraction;
using System;
namespace CohesionAndCoupling
{
public static class PointUtils
{
public static double CalcDistance2D(Point3D first, Point3D second)
{
double distanceX = (second.X - first.X) * (second.X - first.X);
double distanceY = (second.Y - first.Y)... | dobri19/OldRepos | Telerik/01-Programming-with-C#/03-HighQualityCode01-2016-August/08-HighClasses/Cohesion-and-Coupling/PointUtils.cs | C# | mit | 642 |
<?php
/*
|--------------------------------------------------------------------------
| Application Routes
|--------------------------------------------------------------------------
|
| Here is where you can register all of the routes for an application.
| It's a breeze. Simply tell Laravel the URIs it should respond ... | bionikspoon/playing-with-laravel-5---getting-up-to-speed | app/Http/routes.php | PHP | mit | 768 |
module Fontello
module Rails
class Engine < ::Rails::Engine
end
end
end
| blackxored/fontello-rails | lib/fontello-rails/engine.rb | Ruby | mit | 84 |
const webModel = require('../webModel');
const webModelFunctions = require('../webModelFunctions');
const robotModel = require('../robotModel');
const getCmdVelIdleTime = require('../getCmdVelIdleTime');
const WayPoints = require('../WayPoints.js');
const wayPointEditor = new WayPoints();
function pickRandomWaypoint()... | chrisl8/ArloBot | node/behaviors/pickRandomWaypoint.js | JavaScript | mit | 2,341 |
/**
* Created by zhibo on 15-8-20.
*/
/*
* 上传图片插件改写
* @author:
* @data: 2013年2月17日
* @version: 1.0
* @rely: jQuery
*/
$(function(){
/*
* 参数说明
* baseUrl: 【字符串】表情路径的基地址
*/
var lee_pic = {
uploadTotal : 0,
uploadLimit : 8, //最多传多少张
uploadify:fu... | zl0314/ruida | static/js/lee_pic.js | JavaScript | mit | 6,916 |
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
class Cart extends CI_Controller {
private $data;
public function __construct()
{
parent::__construct();
$this->load->library('cart');
$this->load->model("cart_model");
$this->load->model("product_model");
}
public function in... | sygcom/diesel_2016 | application/controllers/Cart_2016_09_28.php | PHP | mit | 17,322 |
module Fintech
class Stat
attr_accessor :date, :previous, :rate, :installment, :payments, :fees_assessed
def initialize(attrs = {})
attrs.each { |k, v| send("#{k}=", v) if respond_to?("#{k}=") }
end
def scheduled_payment_cents
@scheduled_payment_cents ||= if payments.any?
[paymen... | dvanderbeek/fintech | lib/fintech/stat.rb | Ruby | mit | 3,844 |
<?php
namespace Numa\DOAApiBundle\Controller;
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
class DefaultController extends Controller
{
public function indexAction($name)
{
return $this->render('NumaDOAApiBundle:Default:index.html.twig', array('name' => $name));
}
}
| genjerator13/doa | src/Numa/DOAApiBundle/Controller/DefaultController.php | PHP | mit | 303 |
import pytest
from aiohttp_json_api.common import JSONAPI_CONTENT_TYPE
class TestDocumentStructure:
"""Document Structure"""
@pytest.mark.parametrize(
'resource_type',
('authors', 'books', 'chapters', 'photos', 'stores')
)
async def test_response_by_json_schema(self, fantasy_client,
... | vovanbo/aiohttp_json_api | tests/integration/test_document_structure.py | Python | mit | 587 |
from collections import defaultdict
from collections import namedtuple
from itertools import izip
from enum import Enum
from tilequeue.process import Source
def namedtuple_with_defaults(name, props, defaults):
t = namedtuple(name, props)
t.__new__.__defaults__ = defaults
return t
class LayerInfo(named... | tilezen/tilequeue | tilequeue/query/common.py | Python | mit | 15,803 |
require File.expand_path(File.join(File.dirname(__FILE__), '..', 'spec_helper'))
module AliasMethodChainSpec # namespacing
describe "alias method chain" do
module ModifiedAliasMethodChain
# From Tammo Freese's patch:
# https://rails.lighthouseapp.com/projects/8994/tickets/285-alias_method_chain-limits-exte... | jpartlow/graph_mediator | spec/investigation/alias_method_chain_spec.rb | Ruby | mit | 4,078 |
'use strict';
$(function() {
$('a.page-scroll').bind('click', function(event) {
var $anchor = $(this);
$('html, body').stop().animate({
scrollTop: $($anchor.attr('href')).offset().top
}, 1750, 'easeInOutSine');
event.preventDefault();
});
});
| mskalandunas/parcel | app/js/lib/smooth_scroll.js | JavaScript | mit | 270 |
// @flow
import React, { Component } from 'react'
import Carousel, { Modal, ModalGateway } from '../../../../src/components'
import { videos } from './data'
import { Poster, Posters } from './Poster'
import View from './View'
import { Code, Heading } from '../../components'
type Props = {}
type State = { currentModa... | jossmac/react-images | docs/pages/CustomComponents/AlternativeMedia/index.js | JavaScript | mit | 1,796 |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package net.maizegenetics.util;
import net.maizegenetics.dna.snp.GenotypeTable;
/**
*
* @author qs24
*/
public class VCFUtil {
// variables for calculating OS and PL for VCF, might not be in the cor... | yzhnasa/TASSEL-iRods | src/net/maizegenetics/util/VCFUtil.java | Java | mit | 4,777 |
define(['react', 'lodash', './searchView.rt'], function
(React, _, template) {
'use strict';
var exactMatchFieldNames = ['type', 'topic'];
var partialMatchFieldNames = ['title'];
return React.createClass({
displayName: 'searchView',
propTypes: {
configData: React.PropTy... | rommguy/merkaz-hadraha | src/main/webapp/client/views/searchView.js | JavaScript | mit | 2,152 |
package redis
import (
"encoding/json"
"net"
"github.com/boz/ephemerald/lifecycle"
"github.com/boz/ephemerald/params"
rredis "github.com/garyburd/redigo/redis"
)
func init() {
lifecycle.MakeActionPlugin("redis.exec", actionRedisExecParse)
lifecycle.MakeActionPlugin("redis.ping", actionRedisExecParse)
}
type ... | boz/ephemerald | builtin/redis/exec.go | GO | mit | 1,370 |
import requests
from pprint import pprint
r = requests.get("http://pokeapi.co/api/v2/pokedex/1")
#pprint(r.json()["pokemon_entries"])
regpath = "regular/"
shinypath = "shiny/"
import os
for pkmn in r.json()["pokemon_entries"]:
id = str(pkmn["entry_number"])
name = pkmn["pokemon_species"]["name"]
for file in os.lis... | MarkSpencerTan/pokemaster_bot | img/pokemon/image_rename.py | Python | mit | 559 |
export * from './InvalidValueInput'
| sanity-io/sanity | packages/@sanity/form-builder/src/inputs/InvalidValueInput/index.ts | TypeScript | mit | 36 |
package net.kahowell.xsd.fuzzer.generator;
import java.lang.annotation.Annotation;
import java.text.MessageFormat;
import javax.xml.namespace.QName;
import net.kahowell.xsd.fuzzer.XsdTypeValueGenerator;
import net.kahowell.xsd.fuzzer.config.DefaultGeneratorsModule;
/**
* Provides functions for selecting an {@link ... | kahowell/java-xmlfuzzer | src/main/java/net/kahowell/xsd/fuzzer/generator/XsdType.java | Java | mit | 2,469 |
import Ember from 'ember';
export default Ember.Route.extend({
model(params) {
let zipcode = params.zipcode || '97212';
let zipcode2 = params.zipcode2 || '98074';
return Ember.RSVP.hash({
first_location: $.getJSON(`https://api.wunderground.com/api/13fcb02d16148708/conditions/forecast/q/${zipcode}.j... | gpxl/simple-weather-ember | app/routes/index.js | JavaScript | mit | 1,151 |
import { RpcRequest } from '../RpcRequest'
import { RpcResponse } from '../RpcResponse'
/**
* JSON-RPC request for the `help` command.
*/
export interface HelpRequest extends RpcRequest {
readonly method: 'help'
readonly params?: [string]
}
/**
* JSON-RPC response for the `help` command.
*/
export interface H... | Tilkal/multichain-api | src/Commands/Help.ts | TypeScript | mit | 616 |
namespace DvachBrowser3.TextRender
{
/// <summary>
/// Элемент программы с атрибутом.
/// </summary>
public interface IAttributeRenderProgramElement : IRenderProgramElement
{
/// <summary>
/// Атрибут.
/// </summary>
ITextRenderAttribute Attribute { get; }
}
} | Opiumtm/DvachBrowser3 | DvachBrowser3.TextRender/RenderProgram/IAttributeRenderProgramElement.cs | C# | mit | 353 |
#include <string>
#include <iostream>
#include "Flight.h"
#include "Plane.h"
using namespace std;
int main()
{
Flight test(3233, 43, "JFK", "FLF", "Boeing 747", 614, "NA");
cout << test.getFlightInfo() << endl;
} | johnnynybble/CIS17A-SI-CODE | Session-11-6-17/main.cpp | C++ | mit | 218 |
/**
* Copyright 2000-2010 Geometria Contributors
* http://geocentral.net/geometria
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License
* http://www.gnu.org/licenses
*/
package net.geocentral.geometria.model.answer.condition;
import jav... | stelian56/geometria | archive/3.0/src/net/geocentral/geometria/model/answer/condition/GCondition.java | Java | mit | 855 |
(function () {
'use strict';
angular
.module('starter-app')
.run(['$window', function ($window) {
$window.proj4 = require('proj4');
}]);
})(); | OrdnanceSurvey/web-elements-starter | src/app/app.constants.js | JavaScript | mit | 187 |
<?php
$lang['dashboardHeading'] = 'Dashboard';
$lang['bestSafetyHeading'] = 'Best Safety';
$lang['auditsHeading'] = 'Audits';
$lang['auditsfail'] = 'Failed';
$lang['auditspassed'] = 'Passed';
$lang['auditsissues'] = 'Issues';
$lang['auditsasset'] = 'Asset';
$lang['auditsdriver'] = 'DRIVER';
$lang['auditsshipper'] = 'S... | sureshClerisy/trackingnew | application/language/english/dashboard_lang.php | PHP | mit | 3,725 |
"use strict";
define([
'lodash',
'jquery',
'jquery-ui/ui/autocomplete',
'deckslots/cardstore'
], function(_, $, autocomplete, CardStore) {
var CardSelector = function (conf) {
this.domNode = conf.domNode;
this.onSelectCallback = conf.onSelect;
this.cardSource = [];
... | hodavidhara/deckslots | static/js/deckslots/cardselector.js | JavaScript | mit | 1,188 |
for(_="taz'+qadd@=a.Z0,Wre!SCALE6void(~trans%[1]+'$=\"qc`.map(_',^0 K!turnJ){JIentRdelzQ/)&&(QPelmSvgO),100W5K75,^'fill: # 1075function+)/g,(,K5W0zngramZpagepolygon[0]ate(a){mousevar 25 25,25Zzrget touchpointsc!SVG( W 5W5000c.match(/'],['.!place(/szrtetAttribute('active%l aI'<svg ... | ripter/js1k | 2017/dragdrop/914_code_babili_rp.js | JavaScript | mit | 986 |
#!/usr/bin/env ruby
require 'optparse'
require 'bio-logger'
require 'systemu'
SCRIPT_NAME = File.basename(__FILE__); LOG_NAME = SCRIPT_NAME.gsub('.rb','')
# Parse command line options into the options hash
options = {
:logger => 'stderr',
:log_level => 'info',
}
o = OptionParser.new do |opts|
opts.banner = "
... | timbalam/finishm | bin/contigs_against_assembly.rb | Ruby | mit | 5,675 |
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using UnityEngine;
public class HighScores
{
private static HighScores _instance;
public static HighScores Instance
{
get
{
if (_instance==null)
{
_instance = new Hi... | richardkopelow/Wedges | Assets/HighScores.cs | C# | mit | 1,896 |
"""
Script that trains Sklearn singletask models on GDB7 dataset.
"""
from __future__ import print_function
from __future__ import division
from __future__ import unicode_literals
import numpy as np
np.random.seed(123)
import tensorflow as tf
tf.set_random_seed(123)
import deepchem as dc
from sklearn.kernel_ridge impo... | ktaneishi/deepchem | examples/qm7/qm7_sklearn.py | Python | mit | 1,271 |
package com.bitdecay.game.ui.pointBurst;
import com.badlogic.gdx.Gdx;
import com.badlogic.gdx.graphics.Color;
import com.badlogic.gdx.scenes.scene2d.Group;
import com.badlogic.gdx.scenes.scene2d.actions.Actions;
import com.badlogic.gdx.scenes.scene2d.actions.AlphaAction;
import com.badlogic.gdx.scenes.scene2d.actions.... | bitDecayGames/LudumDare38 | src/main/java/com/bitdecay/game/ui/pointBurst/PointBurstEffect.java | Java | mit | 1,697 |
import { GluegunCommand } from 'gluegun'
import { SolidarityOutputMode, SolidarityRequirementChunk, SolidarityRunContext } from '../types'
import Listr from 'listr'
module.exports = {
alias: 'f',
description: 'Applies all specified fixes for rules',
run: async (context: SolidarityRunContext) => {
// Node Mod... | infinitered/solidarity | src/commands/fix.ts | TypeScript | mit | 2,567 |
// Parser.cc for FbTk
// Copyright (c) 2004 - 2006 Fluxbox Team (fluxgen at fluxbox dot org)
//
// 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 limit... | ystk/debian-fluxbox | src/FbTk/Parser.cc | C++ | mit | 1,265 |
import * as vscode from 'vscode';
import Server from './Server';
import Logger from '../utils/Logger';
const L = Logger.getLogger('StatusBarItem');
class StatusBarItem {
server: Server = null;
item: vscode.StatusBarItem;
constructor() {
L.trace('constructor');
this.item = vscode.window.createStatusBar... | rafaelmaiolla/remote-vscode | src/lib/StatusBarItem.ts | TypeScript | mit | 2,197 |
package main
import (
"bytes"
"encoding/base64"
"encoding/hex"
"encoding/json"
"flag"
"fmt"
"io"
"io/ioutil"
"log"
"math/rand"
"net"
"net/http"
"net/rpc"
"net/url"
"os"
"os/exec"
"os/signal"
"reflect"
"regexp"
"strconv"
"syscall"
"time"
"github.com/aws/aws-lambda-go/lambda/messages"
)
var apiB... | lambci/docker-lambda | go1.x/run/aws-lambda-mock.go | GO | mit | 13,597 |
/*
* The Plaid API
*
* The Plaid REST API. Please see https://plaid.com/docs/api for more details.
*
* API version: 2020-09-14_1.78.0
*/
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
package plaid
import (
"encoding/json"
)
// Deductions An object with the deduction in... | plaid/plaid-go | plaid/model_deductions.go | GO | mit | 5,789 |
/**
* Code derived from Leaflet.heat by Vladimir Agafonkin (2-clause BSD License)
* https://github.com/Leaflet/Leaflet.heat/blob/gh-pages/src/HeatLayer.js
*/
L.CanvasLayer = (L.Layer ? L.Layer : L.Class).extend({
redraw: function () {
if (this._heat && !this._frame && !this._map._animating) {
... | nrenner/leaflet-raw-dem | js/CanvasLayer.js | JavaScript | mit | 2,656 |
import Ember from 'ember';
export default Ember.Route.extend({
model() {
const eventRecord = this.store.createRecord('event');
const openingTier = this.store.createRecord('opening-tier');
eventRecord.set('openingTier', openingTier);
return eventRecord;
},
actions: {
didTransition() {
... | NullVoxPopuli/aeonvera-ui | app/pods/events/new/route.js | JavaScript | mit | 392 |
# Copyright (c) 2010-2014 Bo Lin
# Copyright (c) 2010-2014 Yanhong Annie Liu
# Copyright (c) 2010-2014 Stony Brook University
# Copyright (c) 2010-2014 The Research Foundation of SUNY
#
# Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation files
#... | mayli/DistAlgo | da/endpoint.py | Python | mit | 14,912 |
# encoding: utf-8
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
module Azure::Network::Mgmt::V2020_03_01
module Models
#
# Bgp Communities sent over ExpressRoute with each route corresponding to a
# prefix ... | Azure/azure-sdk-for-ruby | management/azure_mgmt_network/lib/2020-03-01/generated/azure_mgmt_network/models/virtual_network_bgp_communities.rb | Ruby | mit | 1,751 |
$(document).ready( function () {
var Counter = Backbone.Model.extend({
defaults : {"value" : 0},
inc : function () {
var val = this.get("value");
this.set("value", val+1);
}
});
var CounterView = Backbone.View.extend({
render: function () {
... | clarissalittler/backbone-tutorials | counterMulti.js | JavaScript | mit | 1,026 |
public class UnsatNullPointerException02 {
public int x;
public static void main(String args[]) {
UnsatNullPointerException02 a = null;
a.x = 42;
}
}
| jayhorn/jayhorn | jayhorn/src/test/resources/horn-encoding/null/UnsatNullPointerException02.java | Java | mit | 178 |
<?php
require_once('../../Classes/ClassParent.php');
class Users extends ClassParent{
var $empid = NULL;
var $password = NULL;
var $lastname = NULL;
var $firstname = NULL;
var $visibility = false;
var $archived = false;
var $use... | rpascual0812/calltracker | Classes/Users.php | PHP | mit | 3,176 |
# encoding: utf-8
module NiceBootstrap3Form::Wrappers
def _offset_wrapper(&block)
if horizontal
content_tag(:div, class: _input_offset_classes, &block)
else
block.call
end
end
def _input_group_wrapper(attribute, &block)
if @inside_group
block.call
else
content_tag(:div... | jh125486/nice_bootstrap3_form | lib/nice_bootstrap3_form/wrappers.rb | Ruby | mit | 650 |