id stringlengths 64 64 | content stringlengths 500 100k | language stringclasses 29
values | path stringlengths 4 333 | repo stringlengths 5 116 | license stringclasses 15
values | size int64 500 100k | lines int64 26 8.06k | source stringclasses 1
value |
|---|---|---|---|---|---|---|---|---|
e191c7df6e5cfc3a3c99ef04292beaf441498a722566c2d163c765da0c593758 | <?php
namespace Roots\Sage\Wrapper;
/**
* Theme wrapper
*
* @link https://roots.io/sage/docs/theme-wrapper/
* @link http://scribu.net/wordpress/theme-wrappers.html
*/
function template_path() {
return SageWrapping::$main_template;
}
function sidebar_path() {
return new SageWrapping('templates/sidebar-foote... | PHP | lib/wrapper.php | ceto/dogdayswear | mit | 1,517 | 65 | codeparrot/github-code |
ad27db58dbd8ef97fdcaa0cf9e3f4f6369f76a27973ca6dcd5bde73418686b5e | /*
* Patch.h
*
* Created on: Jun 9, 2010
* Author: Vincent
*/
#ifndef PATCH_H_
#define PATCH_H_
#include <QRect>
#include <QPolygon>
#include <QDataStream>
#include <QList>
class Patch;
typedef QList<Patch> PatchList;
// Methods to save Patches
QDataStream & operator<<(QDataStream & stream, const Patch &... | C | Patch.h | azurvii/yimp | mit | 1,092 | 52 | codeparrot/github-code |
2a43e347b62ba4d2eef21b976e0883a35b263b2ecfee5520e92314120720af30 | function Placemark(id, name, coord) {
var mCoord = coord;
var mName = name;
var mId = id;
var mIsVisible = true;
this.setVisible = function(isVisible) {
mIsVisible = isVisible;
};
this.getCoord = function() {
return mCoord;
};
this.getName = function() {
re... | JavaScript | reacc/reac2.2/src/Entities/Placemark.js | scrinoman/pmp | mit | 561 | 33 | codeparrot/github-code |
e7c8be089f5a20942edfc06d230787d3d3a012557f1d781519083ded91a6f78e | <?php
namespace DvsaCommon\FullStackLogging\Service;
use DvsaApplicationLogger\Log\Logger;
use DvsaCommon\FullStackLogging\Provider\LoggingHeaderNameProvider;
use DvsaCommon\FullStackLogging\Provider\RequestEventType;
use DvsaCommon\FullStackLogging\Provider\RequestTracingIdProvider;
use Zend\Http\Request;
use Zend\L... | PHP | mot-common-web-module/src/DvsaCommon/FullStackLogging/Service/FullStackLoggingService.php | dvsa/mot | mit | 6,404 | 225 | codeparrot/github-code |
8152669625791220fc965f35e8ac69b756d2910a16039b26005867770a06b94c | import base64
from flask import request, jsonify, session as flask_session
from flask.ext.login import login_user, LoginManager, current_user, current_app
from flexget.api import api, APIResource, app
from flexget.webserver import User
from flexget.utils.database import with_session
login_manager = LoginManager()
lo... | Python | flexget/api/authentication.py | tsnoam/Flexget | mit | 3,365 | 108 | codeparrot/github-code |
054241b4550bc943cf7b0c5e1722747625d804d58948811f183a609d6f3f15c5 | package com.oney.WebRTCModule;
import com.facebook.react.uimanager.annotations.ReactProp;
import com.facebook.react.uimanager.SimpleViewManager;
import com.facebook.react.uimanager.ThemedReactContext;
import com.facebook.react.uimanager.ViewProps;
import org.webrtc.MediaStream;
public class RTCVideoViewManager exten... | Java | android/src/main/java/com/oney/WebRTCModule/RTCVideoViewManager.java | blackneck/react-native-webrtc | mit | 3,214 | 91 | codeparrot/github-code |
a1599f7906ff32623ab00ad4017886f1f96a89ccc3f8bd42abcc0ad77646bb37 | import {DOM} from 'aurelia-pal';
let svgElements, svgPresentationElements, svgPresentationAttributes, svgAnalyzer;
if (typeof FEATURE_NO_SVG === 'undefined') {
/* eslint-disable */
svgElements = {
a: ['class','externalResourcesRequired','id','onactivate','onclick','onfocusin','onfocusout','onload','onmousedow... | JavaScript | src/svg.js | jods4/binding | mit | 22,014 | 240 | codeparrot/github-code |
abbdd0ee1c96a74aa1a84a6e9315f8b33dff842d8aaf44dcee5417ad7a21628e | package eval
import (
"bytes"
"monkey/ast"
)
type InterpolatedString struct {
Value *String
RawValue string
Expressions map[byte]ast.Expression
}
type Interpolable interface {
Interpolate(scope *Scope)
}
func (is *InterpolatedString) Inspect() string { return is.Value.Value }
func (is *InterpolatedS... | GO | eval/string.go | mayoms/monkey | mit | 8,566 | 449 | codeparrot/github-code |
99c40bffea64b6b5f1c1ef0a8d566db723120a4f02f0cfd309e82eb608803cd8 | namespace Easy.Common.XAML.Sample
{
using Easy.Common.XAML.Sample.Messages;
using Easy.MessageHub;
public sealed class MainVM : ViewModelBase
{
#region DataBinding
private string _title;
public string Title
{
get => _title;
set => SetField(ref _... | C# | Easy.Common.XAML.Sample/MainVM.cs | NimaAra/Easy.Common | mit | 869 | 40 | codeparrot/github-code |
b8910d69423c903871a20e584da82040ccad8bc57d0c21c01c0446ef3dc71edc | package cucumber.runtime.scala
import _root_.cucumber.api.DataTable
trait Transform[T] {
def apply(a: Any): T
}
object Transform {
def apply[A](f:String => A):Transform[A] = new Transform[A]{
def apply(a:Any) = a match {
case s:String => f(s)
}
}
implicit val t2table: Transform[DataTable] = n... | Scala | scala/src/main/scala/cucumber/runtime/scala/Transform.scala | nilswloka/cucumber-jvm | mit | 984 | 35 | codeparrot/github-code |
f9202e95dac527373b9fe3e5b31f93640fd107a8a08f87f05feb76e84855cb27 | import json
import random
import time
import re
try:
from StringIO import StringIO # Python 2
except ImportError:
from io import BytesIO as StringIO # Python 3
from datetime import date, datetime, timedelta
import requests
from requests.adapters import HTTPAdapter
try:
from requests.packages.urlli... | Python | mintapi/api.py | jbms/mintapi | mit | 25,488 | 689 | codeparrot/github-code |
2c3007700e4329ec481c216742b298b81e79fdac01de12b4f7d4a6ff28de021b | import urllib.request
import json
# This URL returns all stock tickers in JSON format
TICKER_URL = 'http://query.yahooapis.com/v1/public/yql?q=select%20*%20from%20yahoo.finance.industry%20where%20id%20in%20%28select%20industry.id%20from%20yahoo.finance.sectors%29&format=json&env=store%3A%2F%2Fdatatables.org%2Falltable... | Python | symbol_downloader.py | hsdistefa/MarketQuotes | mit | 1,466 | 41 | codeparrot/github-code |
d97aa580ba404212ca7f9c68dfb76fc9ffb9ca4b665a1017abf7262d0c92e711 |
#include "type/pngpack_context.h"
#include <stdlib.h>
pngpack_context_t*
pngpack_context_create(int flags, byte *template, size_t size, byte *key) {
pngpack_context_t *ctx = calloc(1, sizeof(pngpack_context_t));
if (ctx == NULL)
goto PNGPACK_CONTEXT_CREATE_CLEANUP;
ctx->encode = (flags & PNGPA... | C | src/type/pngpack_context.c | zellio/libpngpack | mit | 1,267 | 56 | codeparrot/github-code |
b09234be72ba6d947c296ed2b670aeb0f823ca8b7a40f42023e6e26f999a0017 | package com.qiniu.storage;
import com.qiniu.common.Config;
import com.qiniu.common.QiniuException;
import com.qiniu.http.Client;
import com.qiniu.http.Response;
import com.qiniu.util.StringMap;
import java.io.File;
/**
* 七牛文件上传管理器
* <p/>
* 一般默认可以使用这个类的方法来上传数据和文件。这个类自动检测文件的大小,
* 只要超过了{@link com.qiniu.common.Confi... | Java | QiNiuGenertorToken/src/com/qiniu/storage/UploadManager.java | CharsDavy/QiNiuGenertorToken | mit | 4,496 | 159 | codeparrot/github-code |
04725a6191834cbf008644049eadc3694c7e4c900b0159f66a9f4bc7cc68894a | require 'openldap/constants'
require 'openldap/bindings'
module OpenLDAP
class LDAPError < StandardError
attr_reader :result_code
def initialize(result_code)
@result_code = result_code
message = OpenLDAP::Bindings::ldap_err2string(@result_code)
super(message)
end
end
class LDAPAttr... | Ruby | lib/openldap/exceptions.rb | justfalter/openldap-ffi | mit | 1,974 | 61 | codeparrot/github-code |
3a27ec06ade7063defad981e43a345ba00965147804d97a86b104d9025c472a9 | package edu.neu.ccs.cs5004.assignment10.blackbox;
import edu.neu.ccs.cs5004.assignment10.MainDocumentProcessor;
import org.junit.Assert;
import org.junit.Rule;
import org.junit.Test;
import org.junit.rules.ExpectedException;
import java.nio.file.Files;
import java.nio.file.Paths;
/**
* Created by yanxu on 4/3/17.
... | Java | src/test/java/edu/neu/ccs/cs5004/assignment10/blackbox/MainDocumentProcessorTest.java | magic-stone/Markdown-Document-Processor | mit | 1,541 | 51 | codeparrot/github-code |
ae59626b140cd24fe0d05c75cbe98543d986c449c2ba4f347c01a27ee26cc80e | var Bacon = require('baconjs').Bacon;
var fs = require('fs');
// bacon-fromnodecallback
var read = Bacon.fromNodeCallback(fs.readFile, 'input.txt');
read.onError(function(error) {
console.log("Reading failed: " + error);
});
read.onValue(function(value) {
console.log("Read contents: " + value);
});
// bacon-repea... | JavaScript | demo/tools-demo/baconjs-demo.js | waterbolik/prestudy | mit | 2,058 | 85 | codeparrot/github-code |
e3ac55115b067c047c79a37c6c3105662e0e9cfce27fc974f6063b9db411401e | "use strict";
var core_1 = require('@angular/core');
require('./baFullCalendar.loader.ts');
var BaFullCalendar = (function () {
function BaFullCalendar() {
this.onCalendarReady = new core_1.EventEmitter();
}
BaFullCalendar.prototype.ngAfterViewInit = function () {
var calendar = jQuery(this.... | JavaScript | src/MyHeritage.App/src/app/theme/components/baFullCalendar/baFullCalendar.component.js | nimeshvaghasiya/MyHeritage | mit | 1,491 | 39 | codeparrot/github-code |
aad21ac03cfbff719aae97114265517f5b49abfc58d2ddf3f002eb3635cce189 | # Class Warfare, Validate a Credit Card Number
# I worked on this challenge [by myself, with: ].
# I spent 2 hours on this challenge.
# Pseudocode
# Input: A group of integers
# Output: true or false
# Steps:
#Check how many integers we have.
#If it's not 16, raise an ArgumentError
#If it is, assign the numbers to ... | Ruby | week-6/credit-card/my_solution.rb | jmcolella/phase-0 | mit | 5,871 | 157 | codeparrot/github-code |
d7d8b113111484b666cedd216ca107251653c6384ab6f208671c2731669576a3 | /*
* Copyright © 2015 Packt Publishing - All Rights Reserved.
* Unauthorized copying of this file, via any medium is strictly prohibited.
*/
package com.packtpub.rest.ch7.wadl;
import java.io.Serializable;
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import java... | Java | rest-chapter7-service-doctools/rest-chapter7-jaxrs2wadl/src/main/java/com/packtpub/rest/ch7/wadl/Department.java | jobinesh/restful-java-web-services-edition2 | mit | 3,624 | 120 | codeparrot/github-code |
85e8de8665707bab48d3e5c7e37b22b0dd74e13a7e4f9bffd3e551cc0c8f2ba2 | using UnityEngine;
using System.Collections;
using System;
using System.IO;
using System.Collections.Generic;
public class Loader: UWClass {
public static string BasePath = "C:\\GAMES\\UW1\\";
public string Path;//To the file relative to the root of the game folder
public bool DataLoaded;
//... | C# | UnityScripts/scripts/Loaders/Loader.cs | hankmorgan/UnderworldExporter | mit | 3,234 | 103 | codeparrot/github-code |
82890d9b04a211d9a10263fb25a6fcbefbb3170e424b0a1f5448663f4d7233a9 | <?php
/**
* @author Yury Kozyrev <ykmship@yandex-team.ru>
*/
namespace Kozz\Helper\ArrayHelper;
use RecursiveIteratorIterator;
/**
* Class ArrayPathHelper
*
* @package Kozz\Helper\ArrayHelper
*/
class ArrayPathHelper
{
/**
* @param $array
* @param array $path
* @param $value
*/
pub... | PHP | src/Helper/ArrayHelper/ArrayPathHelper.php | urakozz/php-array-updater | mit | 924 | 53 | codeparrot/github-code |
5e15e851e7ff671f8849edafb3510ac0ee02d91c94366918db17b9e77142f9be | /* Copyright (c) 2015 Damian Jakub Smoczyk (jakub.smoczyk@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... | C++ | src/engine/CScriptManager.hpp | creepydragon/revision1 | mit | 1,786 | 54 | codeparrot/github-code |
6cc890f763ee84f64fa7313686493152bff86822f441b6fd8608a97d384ced94 | import builtinControls from './controls/builtin'
import is from './utils/is'
const create = (userControls = []) => {
const controls = [...userControls, ...builtinControls]
const runtime = (input, success = () => {}, error = () => {}) => {
const iterate = gen => {
const yieldValue = isError => ret => {
... | JavaScript | src/create.js | youknowriad/rungen | mit | 913 | 39 | codeparrot/github-code |
951bf9a8accc4d894b7f69dfd397c9e79db06284152a724cc83b86ad816bf6d3 | <?php
/**
* TOP API: alibaba.aliqin.fc.iot.device.post request
*
* @author auto create
* @since 1.0, 2017.03.15
*/
class AlibabaAliqinFcIotDevicePostRequest
{
/**
* 备注
**/
private $comments;
/**
* 设备类型(将来扩展)
**/
private $deviceType;
/**
* 15位imei号
**/
private $imei;
/**... | PHP | driver/taobao/top/request/AlibabaAliqinFcIotDevicePostRequest.php | gmars/yii2-sms | mit | 1,554 | 97 | codeparrot/github-code |
8ba1626a4fe214759ecad7776b0d6b85f7393a7f65c1d4bae0c10afacbca1e92 | #ifndef SCRIPTRUNNER_H
#define SCRIPTRUNNER_H
#include "StdinReader.h"
#include "Vector3D.h"
#include "Game.h"
#ifdef MINEFLAYER_GUI_ON
#include <QScriptEngineDebugger>
#include <QMainWindow>
#endif
#include <QObject>
#include <QScriptEngine>
#include <QUrl>
#include <QTextStream>
#include <QTimer>
#include <QTime>
... | C | src/ScriptRunner.h | simcop2387/mineflayer | mit | 8,861 | 198 | codeparrot/github-code |
55850589a4c5e34ede3cd2a179c715064b2462d0043d5d75c3694b69c08e2788 | 'use strict';
angular.module("ngLocale", [], ["$provide", function($provide) {
var PLURAL_CATEGORY = {ZERO: "zero", ONE: "one", TWO: "two", FEW: "few", MANY: "many", OTHER: "other"};
function getDecimals(n) {
n = n + '';
var i = n.indexOf('.');
return (i == -1) ? 0 : n.length - i - 1;
}
function getVF(n... | JavaScript | metamorphosys/META/3rdParty/MetaGME2Doc/Documentation/js/angular-1.3.0-beta.19/i18n/angular-locale_sk-sk.js | pombredanne/metamorphosys-desktop | mit | 2,628 | 117 | codeparrot/github-code |
b71a2c093ae72cfded189f4c720afc1b9e465975a3846d47e00e49930998c3a9 | #!/usr/bin/env python
'''
https://projecteuler.net/problem=7
By listing the first six prime numbers: 2, 3, 5, 7, 11, and 13, we can see that the 6th prime is 13.
What is the 10001st prime number?
'''
import math
def prime(n):
# we start with the knowledge of at least one prime
primes = [2]
# and the next po... | Python | projecteuler/0007_10001st_prime.py | ArthurZey/toyproblems | mit | 1,337 | 47 | codeparrot/github-code |
7a78af456fdbd338123ac86b47e51c227e40bcfe058c80b3ab267d312aed0d73 | var express = require("express"),
bodyParser = require("body-parser"),
compression = require('compression'),
methodOverride = require('method-override'),
morgan = require('morgan'),
mongoose = require('mongoose'),
... | JavaScript | app.js | mikepenzin/yummy.li | mit | 3,848 | 139 | codeparrot/github-code |
ff8c68e60f324b033ceb1a1f0c43a5850d40ef2f002a8fcee221f3b1be2b8fba | require 'socket'
class DCHubConnection
attr_reader :socket
attr_accessor :logger
attr_reader :recv_timeout
def initialize(host, port, command_trigger_callback)
@host = host
@port = port
@command_trigger_callback = command_trigger_callback
@recv_timeout = 60
end
def connect
@socket = ... | Ruby | lib/rdcbot/dc_hub_connection.rb | morr/rDCbot | mit | 1,178 | 57 | codeparrot/github-code |
2efd721ee4159388b43774bcdbc52942f3cafd0c59631a8bf8bac5d536155422 | // 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.
//
// Why base-58 instead of standard base-64 encoding?
// - Don't want 0OIl char... | C | src/base58_1.h | DolphinCoin/dolphincoin | mit | 12,990 | 457 | codeparrot/github-code |
00497591cc144af036228b2930aae68037ed7df8759c47d3a6130e759fe98571 | /**
* Enemy object, extends Phaser.Sprite
*/
var ticks = 0;
var Enemy = function(game, scale, sprite) {
this._game = game;
this._state = this._game.state.getCurrentState();
//properties
this.hp = 1;
this.facing = "";
this.movespeed = 90;
this.facing = "";
startPosition = this._stat... | JavaScript | js/enemy.js | 2machten/pixel-evolution | mit | 8,166 | 282 | codeparrot/github-code |
f457b971cb6c4c4050c200ded5688ce5f250d926a79d3cf6dbcea5af8668e9e5 | <!DOCTYPE html>
<!--[if IE]><![endif]-->
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<title>Class MetadataValuesSchemaUpdateCommand
| Picturepark.SDK.V1 API </title>
<meta name="viewport" content="width=device-width">
<meta name="title... | HTML | docs/sdk/site/api/Picturepark.SDK.V1.ServiceProvider.Contract.MetadataValuesSchemaUpdateCommand.html | Picturepark/Picturepark.SDK.DotNet | mit | 13,149 | 281 | codeparrot/github-code |
07659ccbc60f6975953c3d380a8be0ff3dce2ec0ccef93038feeaa9f0ab8b018 | //! Target machine information, to generate assembly or object files.
use super::prelude::*;
use super::target::LLVMTargetDataRef;
#[repr(C)]
pub struct LLVMOpaqueTargetMachine;
pub type LLVMTargetMachineRef = *mut LLVMOpaqueTargetMachine;
#[repr(C)]
pub struct LLVMTarget;
pub type LLVMTargetRef = *mut LLVMTarget;
... | Rust | src/target_machine.rs | ProtectedMode/llvm_sys | mit | 3,927 | 101 | codeparrot/github-code |
b859f63f3ea9168c9d1a233b9741e9f9c857941cec12ba19b90db2636afe76de | // 中文编码 utf8
var _slider = document.createElement("div");
addClass(_slider, "slider-item");
var container = document.createElement("div");
var floor = Math.floor;
var ceil = Math.ceil;
var round = Math.round;
var abs = Math.abs;
/**
*
* @param {Boolean|Array|Function} autoplay
*/
function slider(autoplay, circle =... | JavaScript | coms/zimoli/slider.js | yunxu1019/efront | mit | 10,645 | 322 | codeparrot/github-code |
86b391e5db86122bb9b4c4b11c8d258cfb837c55e274fe4afbd2b8cf10655e93 |
import React, { Component } from 'react';
import PropTypes from 'prop-types';
import './style.global.css';
export default class Avatar extends Component {
static propTypes = {
src: PropTypes.string,
fallback: PropTypes.string,
};
static defaultProps = {
fallback: 'assets/images/u... | JavaScript | src/js/components/Avatar/index.js | trazyn/weweChat | mit | 873 | 39 | codeparrot/github-code |
189eb5b2ac8311f7e02c19665f83c656262bd1381a374d75a6a5708f4b8b1844 | <?php
/**
* Spiral Framework.
*
* @license MIT
* @author Alexander Novikov
* @author Anton Titov (Wolfy-J)
*/
declare(strict_types=1);
namespace Spiral\Command\Router;
use Closure;
use ReflectionException;
use ReflectionFunction;
use ReflectionObject;
use Spiral\Boot\KernelInterface;
use Spiral\Consol... | PHP | src/Framework/Command/Router/ListCommand.php | spiral/spiral | mit | 5,668 | 203 | codeparrot/github-code |
15ca1156caeb31d68c15952ff189b76562a06e7e26791e7a070e3a142de6a8d5 | 'use strict';
const common = require('../common');
const fixtures = require('../common/fixtures');
const assert = require('assert');
const child = require('child_process');
const path = require('path');
const failures = [];
const slashRE = /\//g;
const backslashRE = /\\/g;
const resolveTests = [
[ path.win32.resolv... | JavaScript | plugins/languageAPI/jsAPI/3rdParty/nodejs/10.1.0/source/test/parallel/test-path-resolve.js | MTASZTAKI/ApertusVR | mit | 2,801 | 72 | codeparrot/github-code |
bb461d079b6e3ee8ee0954aa3864235f197fc4e59b3cc58447ffefd622346851 | <?php echo $content; ?>
<script type="text/javascript">
function fn_opt_tarif(){
var a = jQuery("#customer").val() ;
var b = jQuery("#product").val() ;
var c = jQuery("#origin").val() ;
var d = jQuery("#city").val() ;
var e = jQuery("#plant").val() ;
var f = jQuery("#product_trucktype").val();
var g = jQ... | PHP | application/views/transaksi/order_planning.php | rickyalex/cts | mit | 1,401 | 54 | codeparrot/github-code |
868d6c4bcd465b0e189ce85bef068dfca9f4b80bd4f10f0c099032f31e76d7e6 | <?php
if (!defined('DIR_CORE')) {
header('Location: static_pages/');
}
class ModelExtensionCardstream extends Model {
public function getMethod($address) {
$this->load->language('cardstream/cardstream');
if ($this->config->get('cardstream_status')) {
$query = $this->db->query("SELECT *
FROM " . $... | PHP | code/extensions/cardstream/storefront/model/extension/cardstream.php | cardstream/abantecart | mit | 1,560 | 60 | codeparrot/github-code |
43ce43260e3498e87d954d0a652fe36b250893700b8308d814c8f3c21a0c35aa | import { c } from 'ttag';
import { truncate } from '../../helpers/string';
import { MAX_FILENAME_CHARS_DISPLAY, MAX_IMPORT_CONTACTS_STRING, MAX_IMPORT_FILE_SIZE_STRING } from '../constants';
export enum IMPORT_ERROR_TYPE {
NO_FILE_SELECTED,
NO_CSV_OR_VCF_FILE,
FILE_EMPTY,
FILE_TOO_BIG,
FILE_CORRU... | TypeScript | packages/shared/lib/contacts/errors/ImportFileError.ts | ProtonMail/WebClient | mit | 2,170 | 52 | codeparrot/github-code |
7b96ade2b71a8deffdbba14296c48f50e225b696c9a43789534eee7e8187e354 | using System;
using System.Globalization;
using System.Linq;
using System.Security.Claims;
using System.Threading.Tasks;
using System.Web;
using System.Web.Mvc;
using Microsoft.AspNet.Identity;
using Microsoft.AspNet.Identity.Owin;
using Microsoft.Owin.Security;
using Sabio.Web.Models;
using Sabio.Web.Services;
// **... | C# | Sabio.Web/Controllers/AccountController.cs | entrotech/deployapp | mit | 18,390 | 512 | codeparrot/github-code |
20c2128eba6e4ccf310e5d0615815006182e291c6d21a9712899610781e99f56 | package overcurrent
import (
"context"
"time"
)
type (
// NoopBreaker is a circuit breaker that never trips.
NoopBreaker struct{}
// NoopCollector is a metric collector that does nothing.
NoopCollector struct{}
)
var defaultCollector = NewNoopCollector()
// NewNoopBreaker creates a new non-tripping breaker.
... | GO | noop.go | efritz/overcurrent | mit | 1,232 | 39 | codeparrot/github-code |
14fc18bae9a3941dad1b287f4a6e08f54437e0d4fd9fe10342a6f6702f73824e | <!DOCTYPE html>
<!--[if IE 8]> <html lang="en" class="ie8 no-js"> <![endif]-->
<!--[if IE 9]> <html lang="en" class="ie9 no-js"> <![endif]-->
<!--[if !IE]><!-->
<html lang="en" dir="{{ getDir() }}">
<!--<![endif]-->
<!-- BEGIN HEAD -->
<head>
<meta charset="utf-8" />
<title>{{ trans('lang.... | PHP | src/publish/views/auth/passwords/reset.blade.php | ramiawadallah/myhelper | mit | 4,452 | 99 | codeparrot/github-code |
1afef4dbdccc19a956a6bd2d67551e5e11d6a17315aebdf0000f30f6ea57e6eb | /*
*
*/
import React from 'react';
import {Navbar,Preloader,Button} from 'react-materialize';
import {connect} from 'react-redux';
import {makeSelectCredentials,makeSelectDetails} from './selectors';
import { createStructuredSelector } from 'reselect';
import {login,logout} from "./actions";
import '../../styles/hom... | JavaScript | app/containers/HomePage/index.js | oualid-mazouz/fbchallenge | mit | 6,386 | 212 | codeparrot/github-code |
a9d5af3ba2ac775042617af6b7a8d4da625fc2bde90080897ae51e5ec05baa0c | /**
* Copyright 2012-2019, Plotly, Inc.
* All rights reserved.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
'use strict';
var glslify = require('glslify');
var vertexShaderSource = glslify('./shaders/vertex.glsl');
var contextShaderSo... | JavaScript | src/traces/parcoords/lines.js | asolagmbh/plotly.js | mit | 17,224 | 534 | codeparrot/github-code |
2b1eaf73b9655a5da8523c49962e4eab7e502f480345d52a8dfdce0ebce3dc30 | package com.op1.aiff;
import com.op1.iff.Chunk;
import com.op1.iff.types.ID;
import com.op1.util.ChannelSplitter;
import org.apache.commons.io.FileUtils;
import org.junit.Ignore;
import org.junit.Rule;
import org.junit.Test;
import org.junit.rules.TemporaryFolder;
import org.slf4j.Logger;
import org.slf4j.LoggerFactor... | Java | op1/src/test/java/com/op1/aiff/AiffReaderWriterTest.java | operator1/op1 | mit | 4,899 | 140 | codeparrot/github-code |
49a50c1dcd781f22b6cdabf73bac5285d072e398bf1d6628c94152a8c439ded0 | ///ts:ref=jquery.d.ts
/// <reference path="../../vendor/jquery.d.ts"/> ///ts:ref:generated
///ts:ref=NagiosResponse.d.ts
/// <reference path="../../jsonInterfaces/NagiosResponse.d.ts"/> ///ts:ref:generated
///ts:import=Connector
import Connector = require('../../connector/Connector'); ///ts:import:generated
///ts:impor... | TypeScript | src/main/ts/nagios/connector/NagiosConnector.ts | afranken/simon | mit | 3,072 | 72 | codeparrot/github-code |
e6d8d8cf31278cc06531b4444d3f20e8c3a00baa7e6fce0b762afccfe0cccde9 | import React from 'react';
import { formatPrice } from '../helpers';
class SoldItem extends React.Component {
constructor() {
super();
this.renderOrderItem = this.renderOrderItem.bind(this);
}
renderOrderItem(key) {
const carpet = this.props.carpets[key];
const juice = this.props.juice[key];
const numbe... | JavaScript | src/components/soldItem.js | AdinoyiSadiq/back-office-tool | mit | 1,136 | 53 | codeparrot/github-code |
cf0053ec5938cb72baff543ac8e39fa75af91a99154df440581fd5813b99405e | /*---------------------------------------------------------------*/
/* heap.c */
/*---------------------------------------------------------------*/
/* Norbert Kuck 26.4.93 */
/* Version 4.0 seq */
/*---------------------------------------------------------------*/
/* Verwaltung des Knoten-Heaps, auf... | C | seq/src/heap.c | noqu/vbb | mit | 11,109 | 460 | codeparrot/github-code |
4c36498f79ea0b1a75badebab56f021275469b7c38d251f8d4b28fd8812c78c5 | require 'rollbar'
require 'rollbar/exception_reporter'
require 'rollbar/request_data_extractor'
module Rollbar
module Middleware
class Rack
include ::Rollbar::ExceptionReporter
include RequestDataExtractor
def initialize(app)
@app = app
end
def call(env)
Rollbar.re... | Ruby | lib/rollbar/middleware/rack.rb | rollbar/rollbar-gem | mit | 1,307 | 53 | codeparrot/github-code |
062f316abad5be60fd7fc358b91fed024b922ba2dd4741408de06b097b80515d | # frozen_string_literal: true
module Gnrd
# Tries to figure out a file type
class FileInspector
class << self
def info(path)
unless path.is_a?(String)
raise(TypeError.new("File path is not string: #{path}"))
end
unless File.exist?(path)
raise(Gnrd::FileMissing... | Ruby | lib/gnrd/file_inspector.rb | GlobalNamesArchitecture/gnrd | mit | 1,178 | 45 | codeparrot/github-code |
e3bab04539791e2e92a38e9eb03ac56367736f3dae527c163ad4510e03e99c50 | #include "StdAfx.h"
#ifndef DISABLE_FEATHERSTONE
#include "StringConv.h"
#include "MultiBodyJointFeedback.h"
#include "MultiBodyLink.h"
#include "MultiBodyLinkCollider.h"
MultiBodyLink::MultiBodyLink(btMultibodyLink* native)
{
_native = native;
}
Vector3 MultiBodyLink::GetAxisBottom(int dof)
{
ret... | C++ | src/MultiBodyLink.cpp | AndresTraks/BulletSharp | mit | 7,454 | 321 | codeparrot/github-code |
93ac9aa9a46cb8dd73695466788d55f559d7c47efe771a5891b64a23055c66ce | using System;
using System.Collections.Generic;
using System.Linq;
using Windows.Web.Http;
using Windows.Web.Http.Headers;
using Windows.Web.Http.Filters;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using Windows.Foundation;
using System.Runtime.InteropServices.WindowsRuntime;
namespace Y... | C# | src/Yort.Http.ClientPipeline.Uwp/RetryFilterBase.cs | Yortw/Yort.Http.ClientPipeline | mit | 5,032 | 163 | codeparrot/github-code |
3d4517547d5689f8aa4b671040b5ef3b6cd28fc5ef930872297726de1d90eaad | using System;
using System.Collections.Generic;
using System.IO;
using System.Threading.Tasks;
namespace muyou.Lib.Downloaders
{
public abstract class AbstractDownloadExecutor
{
protected abstract void ProcessDownloadList(string downloadUrl, string localFile, Action<int, string> progress);
pu... | C# | muyou.Lib/Downloaders/AbstractDownloadExecutor.cs | contactsamie/mediaman | mit | 3,586 | 87 | codeparrot/github-code |
d9ff005a25c3d1b7eaddea18d018e58ace7927ddc5b3959aa76dd7703912b98c | var app = require('http').createServer(handler);
var io = require('socket.io')(app);
var fs = require('fs');
var SnakeServer = require('./snake/Game.js');
var serverIp = '0.0.0.0';
var serverPort = 4321;
var players = 0;
var clients = [];
var game = new SnakeServer();
game.onAdvanceTick = function(allPlayersDead) ... | JavaScript | server.js | ysdanielkim/snake-server | mit | 1,492 | 61 | codeparrot/github-code |
2e2dd060597d05bfda346367ea53bc61f4f57f320a9ade27355157db711485ee | <!DOCTYPE html>
<html lang="en"
>
<head>
<title>aadm: misc</title>
<!-- Using the latest rendering mode for IE -->
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link href="http://aadm.github.... | HTML | tag/misc4.html | aadm/aadm.github.io | mit | 19,548 | 399 | codeparrot/github-code |
aba96e9d8eeb6928cf0dd097e216f1665438ba941bacf268405ab7343e4bd279 | // Machine generated IDispatch wrapper class(es) created with Add Class from Typelib Wizard
//#import "C:\\Windows\\assembly\\GAC_MSIL\\ASCOM.DeviceInterfaces\\6.0.0.0__565de7938946fba7\\ASCOM.DeviceInterfaces.tlb" no_namespace
// CAxisRates wrapper class
#define CACHE_DISPID(name) \
static DISPID id;\
if (id == N... | C | ASCOMTele/CAxisRates.h | PKAstro/ASCOMTelescopeMFC | mit | 1,550 | 66 | codeparrot/github-code |
c20b7e0b62110e49bc98d2d0bdf89174e86c6bf72a803eda71f939649867e554 | ##!/usr/bin/python
# -*- coding: utf-8 -*-
"""
Две модели биноминального распределения (N=2 и N=40)
Запуск:
python ./binominal.py
Пример визуализации возникновения событий в соответствии с биноминальным распределением.
Биномиальное распределение представляется как сумма исходов событий, которые следуют распреде... | Python | other/binominal.py | vpv11110000/pyss | mit | 3,629 | 137 | codeparrot/github-code |
e654e1eeef4b8d45e70ff8d5fb8c04e4cb7642715260a970790838ec1b6bdb4c | var PrologPrepare = function(){
var that = this;
this.init = function(){};
/**
* Provides some preparsing support for the prolog interpreter.
*/
this.process = function(term, command){
var cmd = that.prepareCommand(command);
freeform(term, cmd);
};
/**
* Provide support for unification using '=' an... | JavaScript | js/prolog.prepare.js | kevinbluett/tryprolog.org | mit | 945 | 40 | codeparrot/github-code |
8cdb879a75ad437927b6dd13746734640125ce828ed9baa751206c798edc8593 | (function ($) {
"use strict";
// Internet explorer 6 or 7?
var ie67mode = (navigator.appName == 'Microsoft Internet Explorer' && /MSIE [67]/.test(navigator.userAgent));
var previousDocumentStack = [];
var currentDocument = document;
// Private utility functions
// Adds attributes to an HTML Element
v... | JavaScript | jquery.element.js | johan-gorter/jquery.element | mit | 4,329 | 107 | codeparrot/github-code |
a94d96d258a18d6cb091d4c5f341fd60da2b96f5fe98fbad562596e9631d5f06 | import {deleteRoom} from './roomAction';
import {deleteChoosedOrder} from './orderAction';
import {deleteDepartments} from './departmentAction';
import config from '../../config';
export function parseJSON(response) {
return response.json();
}
import {
FETCHING_DONE,
FETCHING_DATA_REQUEST,
CLOSE_MODE... | JavaScript | frontend/actions/utils.js | zhangmingkai4315/RoomBookingSystem | mit | 1,715 | 89 | codeparrot/github-code |
4173b9f672aba82e622f07c826869d62870518ed98336fa6942289fd16bf5be3 | <?php
namespace TenUp\Exodus\Migrator;
use TenUp\Exodus\Migrator\Parsers\Base_Parser;
use TenUp\Exodus\Report\Report;
use TenUp\Exodus\Database\Validator;
/**
* Class Migrator
* @package TenUp\Exodus\Migrator
*/
class Migrator extends Base_Importer {
/**
* @var Base_Parser instance of the injected parser
*/... | PHP | Migrator/Migrator.php | ivanlopez/Exodus | mit | 3,108 | 121 | codeparrot/github-code |
7e0a685273d80bcfe01f2135441eb3b5317980a36b8d003ee86b1a2c44e4157e | class NQueens
attr_accessor :head :solutions
def initialize(n = 8)
@head = Node.new([Array.new(n)] * n)
@solutions = []
end
def find_solutions
end
end
class Node
QUEEN = 1
QCONTROL = 0
attr_accessor :parent :board :children :position
def initialized(parent_board, parent = nil, positio... | Ruby | nqueens.rb | jclif/n-queens | mit | 1,105 | 65 | codeparrot/github-code |
89ebd85d0e146f24ccc61ed53bee8c4d3f7ed06bc3f601a80a115c16f2b1c419 | /*
* Exception.h
*
* Created on: 2014
* Author: jc
*/
#pragma once
#include <stdexcept>
#include <string>
namespace GreenZone
{
class Exception : public std::exception
{
public:
Exception(std::string const & message)
: m_message(message){}
virtual const char * what() const throw()
{
return ... | C++ | include/Exception.hpp | topcpporg/GreenZone | mit | 1,398 | 82 | codeparrot/github-code |
2c1963926adb57f4c73cc648b7d66e86af3da797baeb20d4927f72c65cd70805 | #include <node.h>
using namespace v8;
Handle<Value> Callback(const Arguments& args) {
HandleScope scope;
// Ensure that we got a callback. Generally, your functions should have
// optional callbacks. In this case, you can declare an empty
// Local<Function> handle and check for content before callin... | C++ | server/dev/node-cpp-modules-master/04_callback_functions/modulename.cpp | xavierjs/helicojs | mit | 2,234 | 60 | codeparrot/github-code |
b721bada841916b37a32821545ee76ffcffcf806709e82cf942f3df3e910f5b7 | 'use strict';
const Path = require('path'),
Notification = require('atom').Notification,
Constants = require('./../helpers/constants'),
DataBase = require('./../helpers/database');
class ProjectView extends HTMLElement {
// native
createdCallback () {
this.classList.add('list-item');
... | JavaScript | lib/views/project-view.js | GenerationLabs/atom-project-dashboard | mit | 7,600 | 246 | codeparrot/github-code |
30ae9e4677158c3b3ac2a472b5ed3748f470e22734babb22728fc122e10d75e1 | import React from "react"
import { mount } from "enzyme"
import FeaturedGene from "../FeaturedGene"
describe("FeaturedGene", () => {
let rendered
let featuredGene
beforeEach(() => {
featuredGene = {
title: "Gold",
href: "/gene/gold",
image: {
url: "gold.jpg",
},
}
re... | JavaScript | src/desktop/apps/categories/components/__tests__/FeaturedGene.test.js | xtina-starr/force | mit | 724 | 39 | codeparrot/github-code |
d30437f6b7ad622981dbdc91d52343d0fd7c9079179ccfffd40378dd82be213d | /**
* Created by pi on 9/17/16.
*/
$(function () {
var recipesDataTable = $('#recipesTable').DataTable();
var selected = [], lines = [];
var dialog, form,
// From http://www.whatwg.org/specs/web-apps/current-work/multipage/states-of-the-type-attribute.html#e-mail-state-%28type=email%29
em... | JavaScript | public/js/recipes.js | ffftaw/hwlt | mit | 6,190 | 189 | codeparrot/github-code |
cbc5462b466a48a89edb31dc46acf02cecbb1d7a2662b3560e5a78eff6a3afdc | module example {
'use strict';
interface IProjectsScope extends ng.IScope {
extraValues: any[];
}
/** @ngInject */
export function acmeMalarkey(malarkey: any): ng.IDirective {
return {
restrict: 'E',
scope: {
extraValues: '='
},
template: ' ',
link: linkFu... | TypeScript | src/app/components/malarkey/malarkey.directive.ts | kazamage/example | mit | 1,942 | 89 | codeparrot/github-code |
803132268333afe39741dacf5f3e74dc4593316931e0877558c8e83745e4eb6d | /* global require, describe, it */
'use strict';
// MODULES //
var // Expectation library:
chai = require( 'chai' ),
// Module to be tested:
isInt16Array = require( './../lib' );
// VARIABLES //
var expect = chai.expect,
assert = chai.assert;
// TESTS //
describe( 'validate.io-int16array', function tests()... | JavaScript | test/test.js | validate-io/int16array | mit | 1,068 | 61 | codeparrot/github-code |
5eedff382e3914fb6db72c5731d1cc4575153003af82cf696c5a94995ba60fd3 | <?php
class Cloud_folder extends Cloud_object
{
public function delete()
{
$objects = $this->get_all_objects();
foreach ($objects['folders'] as $object)
{
if(! $object->delete())
{
return FALSE;
}
}
foreach ($objects['files'] as $object)
{
if(! $object->delete())
{
return FALS... | PHP | application/yourCloud/classes/Cloud_folder.php | Exus1/yourCloud | mit | 2,425 | 160 | codeparrot/github-code |
5ae1fae42159cbc66fe107a1a207125a1a58ca7fa42bd1eca20d2e0f2561bd55 | var width, height;
var canvas;
var player
function resize(e) {
engine.resize(window.innerWidth, window.innerHeight);
}
function start() {
canvas = LAN.id_get_dom('render');
width = window.innerWidth;
height = window.innerHeight;
engine = new LAN.Engine(width, height, canvas);
scene = new LA... | JavaScript | static/js/demo.js | AngusLang/LAN.js | mit | 2,919 | 147 | codeparrot/github-code |
44f27db3e45898469947be632a6c840747d451be2969a1e3bddfdbc64dc5c330 | namespace Grupos
{
partial class Poblaciones
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <par... | C# | ProyectoFinal Base de datos Local/Investigacion/Investigacion/Poblaciones.Designer.cs | Ookamigmr/Proyecto-ballenas | mit | 6,588 | 133 | codeparrot/github-code |
f109e9f2d2345d2e0049efdc51c73284979dc007a958ac43b7b6d527ec9ffb0b | import { Laya } from "Laya";
import { URL } from "laya/net/URL";
import { Browser } from "laya/utils/Browser";
import { Main } from "./../Main";
export class Network_ProtocolBuffer {
private ProtoBuf: any = Browser.window.protobuf;
Main: typeof Main = null;
constructor(maincls: typeof Main) {
this.Main = maincls... | TypeScript | src/samples/2d/Network_ProtocolBuffer.ts | layabox/layaair | mit | 1,241 | 48 | codeparrot/github-code |
ff4bff538c13d08826868f7ab21d836fb8af81b4bd50f428e05cd729311ab68f | #include "StdAfx.h"
#include "CreateMMG.h"
#include "TaskFactory.h"
#include "../resource.h"
#include "WeatherBasedSimulationString.h"
using namespace std;
namespace WBSF
{
//*********************************************************************
const char* CCreateMMG::ATTRIBUTE_NAME[NB_ATTRIBUTES]... | C++ | wbsTools/WeatherUpdater/Tasks/CreateMMG.cpp | RNCan/WeatherBasedSimulationFramework | mit | 1,860 | 87 | codeparrot/github-code |
6f68789c6cd6013073df3524e106339254010ad20c151d486283660c34c65db9 | /*
http://www.cgsoso.com/forum-211-1.html
CG搜搜 Unity3d 每日Unity3d插件免费更新 更有VIP资源!
CGSOSO 主打游戏开发,影视设计等CG资源素材。
插件如若商用,请务必官网购买!
daily assets update for try.
U should buy the asset from home store if u use it in your project!
*/
#if !BESTHTTP_DISABLE_ALTERNATE_SSL && (!UNITY_WEBGL || UNITY_EDITOR)
using System;
names... | C# | NGUI_Test/NGUI_Sample/Assets/Best HTTP (Pro)/BestHTTP/SecureProtocol/math/ec/multiplier/WNafUtilities.cs | SeongBongJang/amuzlabBonRepo | mit | 17,329 | 543 | codeparrot/github-code |
4f361651a82811007fa10afcd89fc04c7d177bf84caf0b245c3a1e662516e960 | /*---------------------------------------------------------------------------
| $Id: NumberUtil.java,v 1.13 2013/02/24 12:50:40 quoc Exp $
| Copyright (c) 1999 Quoc T. Truong. All Rights Reserved.
|--------------------------------------------------------------------------*/
package com.qtt.tool.util;
import java.text... | Java | tool/src/util/NumberUtil.java | qtruong/profit | mit | 9,221 | 337 | codeparrot/github-code |
3d686f67b20a9d10338eb77a902976999e5361d13636acf0bc1d38266d979273 | // Console input and output.
// Input is from the keyboard or serial port.
// Output is written to the screen and serial port.
#include "types.h"
#include "defs.h"
#include "param.h"
#include "traps.h"
#include "spinlock.h"
#include "fs.h"
#include "file.h"
#include "memlayout.h"
#include "mmu.h"
#include "proc.h"
#in... | C | xv6/console.c | NatanJMai/xv6_IPC | mit | 5,335 | 299 | codeparrot/github-code |
2a9e5b621659f46c0c71f20a03dd49a843c83231759c1a6e0275257721df3011 | package com.clem.ipoca1.adapter;
import android.graphics.drawable.Drawable;
import android.view.View;
import android.widget.ImageView;
import android.widget.TextView;
import com.bumptech.glide.Glide;
import com.bumptech.glide.load.resource.drawable.GlideDrawable;
import com.bumptech.glide.request.animation.GlideAnima... | Java | app/src/main/java/com/clem/ipoca1/adapter/CoverTarget.java | narakai/DemoApp2 | mit | 2,189 | 57 | codeparrot/github-code |
c68dc36b6d6eb346407a15a38c419db168e3159a39aaf4e543b933dcf80bfe20 | var Utils = require('./utils');
var path = require('path');
var fs = require('fs');
var AsposeStorage = require('./aspose-storage');
function AsposeTasks(config) {
this.appSID = config.appSID;
this.appKey = config.appKey;
this.baseURI = config.baseURI;
}
/* Resources Methods */
AsposeTasks.prototype.getR... | JavaScript | lib/aspose-tasks.js | asposemarketplace/Aspose_for_Node.js | mit | 19,721 | 682 | codeparrot/github-code |
75217a75ae1a81cbbaf4fe88e21291b514cdbb8dc6a1cd412a0f7e51d9aef716 | import { ActionType, IAction, IPoint, ToolName, ISceneImage, ISize } from '../models';
export interface ISetActiveToolAction extends IAction {
toolName: ToolName;
}
export interface IClearSelectionAction extends IAction {
}
export interface ISelectAllPointsAction extends IAction {
pointIndices?: number[];
}
expor... | TypeScript | client/typescripts/app/actions/editor.ts | codeandcats/delaunay-animation-editor | mit | 2,546 | 68 | codeparrot/github-code |
48320e7dd4a1c46bac80be9b1aa386aff4e08615c03eefde11a734f1244ba5cc | <?php
require_once __DIR__ . '/../utils/Request.class.php';
require_once __DIR__ . '/../models/User.class.php';
/**
* The main controller class
*
* @author Jonas Metzener
* @license MIT
* @copyright Copyright (c) 2016, Jonas Metzener
*/
class Controller {
/**
* The errors of this controller
*
... | PHP | app/controllers/Controller.class.php | anehx/galery | mit | 2,832 | 131 | codeparrot/github-code |
158f4f3e0b4da8a7c0d7cb45c91c240d37b13b266792c9f43d8175b70865b515 | package org.nkjmlab.gis.datum.util;
import static org.junit.Assert.*;
import org.junit.Before;
import org.junit.Test;
import org.nkjmlab.gis.datum.DatumConverter;
public class TD2WgsTest {
@Before
public void setUp() throws Exception {}
@Test
public void testToWgs() {
double latDegTD = 35.71004;
d... | Java | src/test/java/org/nkjmlab/gis/datum/util/TD2WgsTest.java | yuu-nkjm/JJPDatum | mit | 1,237 | 42 | codeparrot/github-code |
74a2a078f6058690392af922d828b4983eb31c1f401619ae2d124cefff1b88c7 | <?php
require_once 'DiContainer/Container.php';
interface IA
{
}
interface IB
{
}
class A implements IA
{
private $b = null;
private $scalar = null;
public function __construct(IB $b, $scalar)
{
$this->b = $b;
$this->scalar = $scalar;
}
}
class B implements IB
{
private $sc... | PHP | example6.php | antimax/PHP-DependencyInjectionContainer | mit | 776 | 46 | codeparrot/github-code |
7550496b8e2cb55aa21cbe106a5aec2bd461629efc37dd6258c44a078c797664 | import EmberCollection from 'ember-collection/components/ember-collection';
import layout from './ember-virtual-collection/template';
import Ember from 'ember';
const hasTouch = ('ontouchstart' in window) || window.DocumentTouch && document instanceof window.DocumentTouch;
const { set } = Ember;
export default EmberC... | JavaScript | addon/components/ember-virtual-collection.js | yapplabs/ember-virtual-scrollkit | mit | 4,155 | 118 | codeparrot/github-code |
0ccbd42ac0579ab002d608713e716e4bd4ecbf7301c62a9a2240c1434a931a15 | #include "usr.h"
INLINE voba_value_t* voba_allocate_user_data(size_t s)
{
size_t size = (s+sizeof(voba_value_t));
if(size % 16 !=0){
// size must be 16 bytes alignment.
size = (size/16 + 1) * 16;
}
voba_value_t * p = (voba_value_t*)GC_MALLOC(size);
assert(p);
return p;
}
INLINE ... | C | imp/usr.c | wcy123/voba_value | mit | 840 | 31 | codeparrot/github-code |
6788e8e1e3578528f34ef3b103251b1431de495ba79509f4eaf518c05d5896a1 | /*
Módulo: Financeiro
Função: Consulta Recebimento x Cliente (Filtros)
Autor.: Jackson Patrick Werka
Data..: 28/01/2013
© Copyright 2012-2012 SoftGreen - All Rights Reserved
*/
//---------------------------------------------------------------------------
#include <vcl.h>
#include "uSfgGlobals.h"
#include "uSfgTools.h"
... | C++ | Financeiro/uFin3014.cpp | jpwerka/SistemaSFG | mit | 7,017 | 212 | codeparrot/github-code |
b071b46c289fc77b6af0105c1f884b2d2c754e6c9ff5ba65d8ece4de6b1e35fa | #include <bits/stdc++.h>
using namespace std;
typedef long long int ll;
typedef pair<int, int> P;
typedef pair<ll, ll> Pll;
typedef vector<int> Vi;
//typedef tuple<int, int, int> T;
#define FOR(i,s,x) for(int i=s;i<(int)(x);i++)
#define REP(i,x) FOR(i,0,x)
#define ALL(c) c.begin(), c.end()
#define DUMP( x ) cerr << #x... | C++ | atcoder/other/jag2016_sp1_c.cpp | knuu/competitive-programming | mit | 1,438 | 58 | codeparrot/github-code |
3e3ea04b4f5682a698e6bf55d8dc292cebcb4c68635fbdb2239a7defb82ac30e | <!DOCTYPE html>
<html>
<head>
<title>SF Movies | Find out where the best movies happened in San Fransisco</title>
<meta name="viewport" content="initial-scale=1.0, user-scalable=no" />
<style type="text/css">
html, body, #map-canvas {
height: 100%;
margin: 0;
padding: 0;
... | HTML | app/index.html | bbraithwaite/sf-movies-web | mit | 14,313 | 436 | codeparrot/github-code |
011873b86a978075a4f95aaf1964896b733618d35cc34d5e3ff5a6b7887525b7 | 'use strict';
var mongoose = require('mongoose'),
fs = require('fs'),
path = require('path'),
util = require('util'),
_ = require('lodash'),
errorHandler = require(path.resolve('./modules/core/server/controllers/errors.server.controller')),
Project = mongoose.model('Project'),
multiparty = require('mult... | JavaScript | modules/projects/server/controllers/media.server.controller.js | steven-st-james/mapping-slc | mit | 18,742 | 661 | codeparrot/github-code |
b34031bd4606c340d4032c76c956eed411c21c9cef2593230aa72cbfc24d5459 | import EVENTS from '../events.js';
import external from '../externalModules.js';
import toolColors from '../stateManagement/toolColors.js';
import drawHandles from '../drawing/drawHandles.js';
import { state } from '../store/index.js';
import { getToolState } from '../stateManagement/toolState.js';
import { clipToBox }... | JavaScript | src/tools/FreehandRoiSculptorTool.js | chafey/cornerstoneTools | mit | 35,121 | 1,271 | codeparrot/github-code |
02fe5d61447572238fba8d1746d028ae065974a4aaa225102627924f5ceaeed6 | /**
* @fileoverview A visual containing an arbitrary model
* @author Tony Parisi
*/
goog.provide('SB.Model');
goog.require('SB.Visual');
/**
* @constructor
* @extends {SB.Visual}
*/
SB.Model = function(param)
{
SB.Visual.call(this, param);
this.frame = 0;
this.animating = false;
this.frameRate = SB.Model... | JavaScript | engine/src/visuals/model.js | tparisi/Skybox | mit | 1,562 | 99 | codeparrot/github-code |
612bde83d5a785485123ee3070c30408e199a6f9defd4454202c97829bb5bb54 | /*
* Please leave this Copyright notice in your code if you use it
* Written by Decebal Mihailescu [http://www.codeproject.com/script/articles/list_articles.asp?userid=634640]
*/
using System;
using System.Collections.Generic;
using System.Collections;
using System.Text;
using System.Runtime.InteropServices;... | C# | ISOBurner/FileImage/FileDiscFormatData.cs | hgroover/diskpub-utils | mit | 14,566 | 479 | codeparrot/github-code |
7572a0037d3077999b9ae7b5e9844c32a6b53011227506c81ce6bd69258280f2 | // Copyright (c) 2009-2014 The Bitcoin developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "base58.h"
#include "rpcserver.h"
#include "init.h"
#include "main.h"
#include "script/script.h"
#include "script/standar... | C++ | src/rpcdump.cpp | drewtalati/talaticoin | mit | 15,112 | 400 | codeparrot/github-code |
f4d7c8f86e9e89bc44601c5419f6827f18c13d136ae62fa1eb957ba98b5fdaa0 | <!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<title>Color Thief</title>
<link rel="stylesheet" href="./screen.css">
</head>
<body>
<img src="https://color-thief-cors-test-images.s3-us-west-1.amazonaws.com/boise-spacebar-arcade.... | HTML | cypress/test-pages/cors.html | lokesh/color-thief | mit | 975 | 39 | codeparrot/github-code |
80df2e98d41a504b9c6b45cb5c423ce212b87776b37a8a276499f0e0b961ca60 | //
// JumpHelper.cpp
// Build-Age
//
// Created by Patrik Štrba on 20.1.2013.
// Copyright (c) 2013 Patrik Štrba. All rights reserved.
//
#include "Client/Player/JumpHelper.h"
#include "Client/World/World.h"
#include "Client/Control/Timer.h"
JumpHelper::JumpHelper() {
jumpTime = 0;
}
bool JumpHelper::jump(V... | C++ | Client/Player/JumpHelper.cpp | pajon/build-age | mit | 1,616 | 81 | codeparrot/github-code |
4bfad597086412080a3448e214ca958cdc8acc1fb69f2636f54fe70c22fa0058 | using EdiEngine.Common.Enums;
using EdiEngine.Common.Definitions;
using EdiEngine.Standards.X12_004010.Segments;
namespace EdiEngine.Standards.X12_004010.Maps
{
public class M_218 : MapLoop
{
public M_218() : base(null)
{
Content.AddRange(new MapBaseEntity[] {
new TF() { ReqDes = RequirementDesignator.Man... | C# | EdiStandards/X12_004010/Maps/M_218.cs | olmelabs/EdiEngine | mit | 10,980 | 299 | codeparrot/github-code |
30d08d775a5f84dd2a33a2a987c01c6ff830f5bcf134b2cc07deaee8e7607323 | <?php
/**
* Sija Framework.
*
* @package Sija
* @author Alex Chermenin <alex@chermenin.ru>
*/
namespace Sija;
use Sija\Common\Application, Sija\Common\Config, Sija\Common\Request, Sija\Common\ParametersList, Sija\Common\ResponseBuilder, ActiveRecord, Exception;
/**
* Init general autoload class.
*
* @param... | PHP | Sija/Sija.php | chermenin/sija | mit | 8,988 | 224 | codeparrot/github-code |
6d407047c24ad0f2bba10762d23f6ad1510222b8ba6839fabb18524c37b529fb | // This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Copyright (C) 2008 Gael Guennebaud <gael.guennebaud@inria.fr>
// Copyright (C) 2010,2012 Jitse Niesen <jitse@maths.leeds.ac.uk>
//
// This Source Code Form is subject to the terms of the Mozilla
// Public License v. 2.0. If a... | C | word2vec/Eigen/src/Eigenvalues/EigenSolver.h | lache/ml.net | mit | 23,132 | 641 | codeparrot/github-code |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.