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
006274a527c5e79423856ac9ea4c50437049986ae07e7ab89e9279b4d5386ff6
#pragma once #include "bitmap.h" #include "rom_file.h" #define MAKEQUAD(r, g, b) (((BYTE)(b) | ((WORD)((BYTE)(g))<<8)) | (((DWORD)(BYTE)(r)) << 16)) class TilePalette { public: TilePalette(); bool LoadSpriteSubPal(CartFile& cart, UINT id); bool LoadPalette(CartFile& cart, UINT addr); bool Lo...
C
src/tile.h
francislr/dkc2-maps
mit
1,139
45
codeparrot/github-code
09c1345dce3304ad5201a89b843304857c42f07367aab9ec1733fc870f9e6f32
// TODO: replace IOUtils // Graciously borrowed from: // https://github.com/lwjglgamedev/lwjglbook/blob/master/chapter20/c20-p2/src/main/java/org/lwjglb/engine/Utils.java package engine.util.io; import java.io.BufferedReader; import java.io.InputStream; import java.io.InputStreamReader; import java.util.ArrayList; im...
Java
src/engine/util/io/IOUtils.java
dwbrite/polvo
mit
1,861
58
codeparrot/github-code
a4be344e2ad8dcf589061a2b89b81d2a5fc1f9663177f021b29159cd3dcd9b99
var p = require('path'); var fs = require('fs'); var chalk = require('chalk'); var cst = require('../Constants'); var Titan = require('./Titan'); // rewrite console var rConsole = require('./console'); var nConsole = rConsole.nativeConsole; rConsole.rewriteCLI(); var CLI = module.exports = {}; /** * CLI init. * ...
JavaScript
lib/CLI.js
longzero1888/Titan
mit
9,033
394
codeparrot/github-code
cd8953574ea0109961573270c4175a116aedba30f927e6dc430e1a6e223797fe
package coffeescript_editor.editors; import org.eclipse.jface.text.TextAttribute; import org.eclipse.jface.text.rules.IRule; import org.eclipse.jface.text.rules.IToken; import org.eclipse.jface.text.rules.IWordDetector; import org.eclipse.jface.text.rules.MultiLineRule; import org.eclipse.jface.text.rules.PatternRule;...
Java
src/coffeescript_editor/editors/CoffeescriptScanner.java
567000/simple_eclipse_coffeescript_editor
mit
3,060
117
codeparrot/github-code
0295987fd060f3ba54e0d216a1e7527bb7f40d3c298700dc8d4ba452f53d49c8
using System; using NetRuntimeSystem = System; using System.ComponentModel; using NetOffice.Attributes; namespace NetOffice.PublisherApi { /// <summary> /// DispatchInterface Shape /// SupportByVersion Publisher, 14,15,16 /// </summary> [SupportByVersion("Publisher", 14,15,16)] [EntityType(EntityType.IsDispatc...
C#
Source/Publisher/DispatchInterfaces/Shape.cs
NetOfficeFw/NetOffice
mit
36,943
1,327
codeparrot/github-code
da88b4473f3311e5c8a5932ca274584dc0aeb3f203fa293f6083d0ab97f4cff3
require 'rubygems' require 'net/ldap' require 'time' require "ucb_ldap/version" require 'ucb_ldap/schema' require 'ucb_ldap/schema_attribute' require 'ucb_ldap/entry' require 'ucb_ldap/person' require 'ucb_ldap/expired_person' require 'ucb_ldap/job_appointment' require 'ucb_ldap/org' require 'ucb_ldap/namespace' requi...
Ruby
lib/ucb_ldap.rb
ucb-ist-eas/ucb-ldap
mit
6,128
224
codeparrot/github-code
08deaf1b354f14287a5fcc7035ffc5740e31da5d1961da8cae46651e62b459cf
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html lang='en' xml:lang='en' xmlns='http://www.w3.org/1999/xhtml'><head><title>/Library/Ruby/Gems/1.8/gems/activesupport-2.2.2/lib/active_support/core_ext/date/calculations.rb - C0 code coverage in...
HTML
coverage/-Library-Ruby-Gems-1_8-gems-activesupport-2_2_2-lib-active_support-core_ext-date-calculations_rb.html
starapor/slippers
mit
35,485
841
codeparrot/github-code
1772cdc8c29988944e7cdd367e8c7902f3d9dcb4bef4c9d0f0f5ceb25dedbffc
pub use self::{animal::*, food::*, world::*}; mod animal; mod food; mod world; use lib_simulation as sim; use rand::prelude::*; use serde::Serialize; use wasm_bindgen::prelude::*; #[wasm_bindgen] pub struct Simulation { rng: ThreadRng, sim: sim::Simulation, } #[wasm_bindgen] impl Simulation { #[wasm_bin...
Rust
libs/simulation-wasm/src/lib.rs
Patryk27/Shorelark
mit
1,148
51
codeparrot/github-code
983be0d1be8251569203a6849b3e1d59c7b89ba124b9dfedf7bc3c0729851c0b
package com.adobe.plugins; import org.apache.cordova.CallbackContext; import org.apache.cordova.CordovaPlugin; import org.json.JSONArray; import org.json.JSONException; import com.google.analytics.tracking.android.GAServiceManager; import com.google.analytics.tracking.android.GoogleAnalytics; import com.google.analy...
Java
src/android/GAPlugin.java
codigoabierto/GAPlugin
mit
2,930
90
codeparrot/github-code
df3671a8e24e2adcb72dd70446eb363a505b783a8bf6d0850e89b07f6f0b38f1
using ESRI.ArcGIS.esriSystem; using ESRI.ArcGIS.Framework; namespace ClearCache { /// <summary> /// Command to invoke the REST admin clear /// </summary> public class ClearCommand : ESRI.ArcGIS.Desktop.AddIns.Button { private IDockableWindow _dockWindow; protected override void On...
C#
ClearCache/ClearCommand.cs
davetimmins/AutoClearREST
mit
933
31
codeparrot/github-code
c6c7a6976733c4beab9c49138d254c4f080ed91d8f0f26fba2586634524b4891
#include "umlReflectionExec/DataStoreNodeObject.hpp" //General Includes #include "abstractDataTypes/SubsetUnion.hpp" #include "uml/DataStoreNode.hpp" #include "umlReflection/UMLPackage.hpp" #include "fUML/Semantics/Loci/Locus.hpp" #include "uml/Class.hpp" //Includes From Composite Structures /*Not done for metamodel o...
C++
src/common/umlReflection/src_gen/umlReflectionExec/DataStoreNodeObject.cpp
MDE4CPP/MDE4CPP
mit
53,189
1,169
codeparrot/github-code
b751e57914193e3fd80e061689819b0cf488abaaade2aebd78b2a4a2099bef59
define(function(require , exports , module){ var $ = require("jquery"); var Backbone = require("backbone"); var datatype = require("datatype"); var AppModel = datatype.DataItem.extend({ getDefault: function () { return { preference: {} , fileTree: null , openFiles: new FileList() , ...
JavaScript
js/modules/core/model.js
appleskiller/BackboneExample
mit
2,638
103
codeparrot/github-code
f36c57ed9b804cf0e88c89ba45bf22d1c01e434faf271f09a57f7ed4d640ce70
function metaphone(a) { function h(a) { b += a } function i(b) { return a.charAt(c + b).toUpperCase() } function j(a) { return function() { return i(a) } } var d, e, f, g, b = "", c = 0; if (!(a = String(a || ""))) return ""; for ...
JavaScript
language-lib/metaphone.js
LaunchMii/dash.index
mit
3,819
136
codeparrot/github-code
0156c2d1c1a85e94ac5486134cd4e764839f50e17f8217e435eb9b9f74ab0fb2
class StaticPagesController < ApplicationController def home if logged_in? @micropost = current_user.microposts.build @feed_items = current_user.feed.paginate(page: params[:page]) end end def help end def about end def contact end def contact_message @contact_messages = Co...
Ruby
app/controllers/static_pages_controller.rb
StayFitTowson/StayFit
mit
790
33
codeparrot/github-code
67e7f89c47a619126371aff4a563074bfd02df06b67e8decc25d837c1dced37b
<?php namespace Kanboard\Auth; use Kanboard\Core\Base; use Kanboard\Core\Security\OAuthAuthenticationProviderInterface; use Kanboard\User\GoogleUserProvider; /** * Google Authentication Provider * * @package auth * @author Frederic Guillot */ class GoogleAuth extends Base implements OAuthAuthenticationProvid...
PHP
app/Auth/GoogleAuth.php
davefoster/kanbanBoard
mit
2,968
144
codeparrot/github-code
5a2ca432e822985b7d022573cff90a178b08d0e2aa22be835bac1cf728b4ff09
using System; class TheBiggestOfFiveNumbers { static void Main() { Console.WriteLine("Plese enter five numbers!"); Console.Write("Plese enter the first number: "); double firstNum = double.Parse(Console.ReadLine()); Console.Write("Plese enter the second number: "); doub...
C#
C#-Part1/05. ConditionalStatements/06-TheBiggestOfFiveNumbers/TheBiggestOfFiveNumbers.cs
glifada/TelerikAcademy
mit
1,175
38
codeparrot/github-code
20927ec912495279c59e0ec2e09b261556b93150ac7f92a3faa962dc4f76a6b7
<?php namespace App\Entity; use Doctrine\ORM\Mapping as ORM; use Doctrine\Common\Collections\Collection; use Doctrine\Common\Collections\ArrayCollection; use Symfony\Component\Serializer\Annotation\Groups; use App\Entity\Person; /** * App\Entity\Address * * @ORM\Entity(repositoryClass="App\Repository\AddressRepos...
PHP
src/Entity/Address.php
naitsirch/ecgpb-memberlist
mit
5,663
297
codeparrot/github-code
86e0f2cf30abde08cdb573e98f651efa90b2059814256287e3445c24fe5e39b0
// // Copyright (c) 2013 Mikko Mononen memon@inside.org // // This software is provided 'as-is', without any express or implied // warranty. In no event will the authors be held liable for any damages // arising from the use of this software. // Permission is granted to anyone to use this software for any purpose, // ...
C
CCPathRendering/nanovg/nanovg.h
bmanGH/CCPathRendering
mit
18,767
467
codeparrot/github-code
451c3d9ecb4832066f2300c7cb5abb443300e9e0d77d2afdf67612439be135da
/** * @package Graph * @file tools/Load.js * @author Nagy Zoltán (NAZRAAI.ELTE) <abesto0@gmail.com> * @license Apache License, Version 2.0 * * GraphUI tool for re-creating a graph from serialized JSON * * Copyright 2011 Nagy Zoltán * Licensed under the Apache License, Version 2.0 (the "License"); * you may no...
JavaScript
js/net/abesto/graph/tools/Load.js
abesto/algo-old
mit
3,541
81
codeparrot/github-code
ca4c2dfbfe909eb997c62f09f7ecc3f00b55b7adcb99e787d5c238b4488b6793
/** * Created by Leslie on 2016/11/30. */ var db = require('../models/model'); var Response = require('../common/Response'); var utils = require('../common/Utils'); var q = require('q'); exports.create = function (answer) { if (answer.content == '') return Response.msg(200, false, '回答不能为空', {}); db....
JavaScript
dal/answer.js
fiamma21/segmentfault
mit
1,061
33
codeparrot/github-code
1ffa4694c54f2473c2c99bfa8490fc94df67c11ca1e4b8a41bdf39f37f3f024e
using System; using Newtonsoft.Json; using SeekU.Domain; using SeekU.Eventing; namespace SeekU.Sql.Eventing { /// <summary> /// SQL snapshot storage provider /// </summary> public class SqlSnapshotStore : ISnapshotStore { private static readonly JsonSerializerSettings SerializerSettings = ...
C#
Providers/SeekU.Sql/Eventing/SqlSnapshotStore.cs
TylerBrinks/SeekU
mit
2,416
71
codeparrot/github-code
7dbe5bf8c4f43859de85eafb6c5c7720e218c052a309ef880a09c451b208ae24
class ObjectPicker { // -------------------------------------------------------------------------- constructor() { this.log('Constructing'); /** * Contains reference to the active picker - i.e., the one which the CDN manager is attached to * @type {Object} */ ...
JavaScript
assets/js/components/ObjectPicker.js
nailsapp/module-cdn
mit
13,294
406
codeparrot/github-code
5796a3bd9088e47abdac8bded90144e3be359d6170f9b23091f8eb08638ea4cd
#include <cassert> #include <cimple/Time.h> #include <Pegasus/Common/Config.h> #include <Pegasus/Client/CIMClient.h> #include <Pegasus/Listener/CIMListener.h> #include <Pegasus/Consumer/CIMIndicationConsumer.h> PEGASUS_USING_PEGASUS; PEGASUS_USING_STD; const String FILTER_CLASS = "CIM_IndicationFilter"; const String ...
C++
src/pegasus/clients/MyIndicationClientListener/MyIndicationClientListener.cpp
LegalizeAdulthood/cimple
mit
6,875
264
codeparrot/github-code
fae63b631bf0e28ccea8c9ad26c89054e7f04d8dc6f5c64132f8e6d40f5781d9
/***************************************************************************************** * * * OpenSpace * * ...
C++
modules/gaia/rendering/octreeculler.cpp
OpenSpace/OpenSpace
mit
4,028
83
codeparrot/github-code
5c84eb58b7b0a7c33d6daaec5882d749f0fe4ac74d48300760955b1114c998c3
#include "resource_change_watcher.h" #include "solar/containers/container_helpers.h" #include "solar/io/directory_change_watcher.h" #include "solar/utility/assert.h" #include "solar/utility/trace.h" #include "solar/time/real_time.h" namespace solar { resource_change_watcher::watching_resource_info::watching_resource...
C++
src/solar/resources/resource_change_watcher.cpp
jseward/solar
mit
3,104
92
codeparrot/github-code
12c932f766a5033aab28a793c7dc29b06458d4ebdd61066ed9518e434db18084
import numpy as np class Node(object): """ Base class for nodes in the network. Arguments: `inbound_nodes`: A list of nodes with edges into this node. """ def __init__(self, inbound_nodes=[]): """ Node's constructor (runs when the object is instantiated). Sets pro...
Python
MiniFlow/5 - Cost/miniflow.py
nehal96/Deep-Learning-ND-Exercises
mit
4,928
180
codeparrot/github-code
6db2326b38ce1ff163187c99261d7f78166c97772aa8ec60d5c4cc4d11fa82ce
"""Module which contains all spells that check something in a cgf file.""" # -------------------------------------------------------------------------- # ***** BEGIN LICENSE BLOCK ***** # # Copyright (c) 2007-2012, NIF File Format Library and Tools. # All rights reserved. # # Redistribution and use in source and binar...
Python
pyffi-develop/pyffi/spells/cgf/check.py
griest024/PokyrimTools
mit
9,081
203
codeparrot/github-code
9a8b4e41447d0d00335840de6663133d79ff2f8910d8fadb0494f54cd46f3a24
package com.dgimenes.jhog.test.view; import java.awt.GridLayout; import java.awt.Image; import javax.swing.BoxLayout; import javax.swing.ImageIcon; import javax.swing.JFrame; import javax.swing.JLabel; import javax.swing.JPanel; import com.dgimenes.jhog.HOGProcessor; import com.dgimenes.jhog.test.HOGVisualizer; pub...
Java
src/com/dgimenes/jhog/test/view/HOGVisualizerView.java
danielgimenes/jHOG
mit
2,268
65
codeparrot/github-code
95324702232d2a733fbc8a168e3bf95e7b30791c6e7a330808e50f285cd6bafb
using UnityEngine; using System.Collections; using System.Linq; public class Room : MonoBehaviour { private GameObject doorE, doorW, doorN, doorS; private GameObject spawnE, spawnW, spawnN, spawnS; public GameObject NewFloor; private Vector3 size; public bool isBoosRoom = false; public GameObj...
C#
Assets/scripts/Room.cs
mfgpker/Procedural-Death-Labyrinth
mit
8,746
287
codeparrot/github-code
acb8b204590c439565eba280c3f8f14319df12478cfe1e90a11885217b99664b
/*++ Copyright (c) 2011 Microsoft Corporation Module Name: occf_tactic.cpp Abstract: Put clauses in the assertion set in OOC (one constraint per clause) form. Constraints occuring in formulas that are not clauses are ignored. The formula can be put into CNF by using mk_sat_preprocessor s...
C++
byterun/z3str2/z3/lib/occf_tactic.cpp
sukwon0709/byterun
mit
7,623
253
codeparrot/github-code
ec15b16269821539f8a668630432f5caf6a780d7dc17b125ea399355b8cac336
package redbutton; import java.awt.BorderLayout; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.awt.event.WindowAdapter; import java.awt.event.WindowEvent; import java.io.FileInputStream; import java.io.IOException; import java.io.InputStream; import java.net.ServerSocket; import ...
Java
Server [Button]/redbutton/MainRedButtonServer.java
afsheenrane/BigRedButton
mit
8,574
310
codeparrot/github-code
414738ff4d7c22d16e6fd0f63a8834b5222ae940d46aa031be188e3f89cb4f1f
'use strict' let gen = require('./gen.js') let proto = { basename:'accum', gen() { let code, inputs = gen.getInputs( this ), genName = 'gen.' + this.name, functionBody gen.requestMemory( this.memory ) gen.memory.heap[ this.memory.value.idx ] = this.initialValue functio...
JavaScript
js/accum.js
charlieroberts/genish.js
mit
3,623
118
codeparrot/github-code
a4c6727cf5c4ac516d811b2529ef75defa659b320402efce9042d62fc9dbd323
// Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. package com.azure.resourcemanager.sql.implementation; import com.azure.core.http.rest.PagedFlux; import com.azure.core.http.rest.PagedIterable; import com.azure.resourcemanager.resources.fluentcore.model.implementation.Ref...
Java
sdk/resourcemanager/azure-resourcemanager-sql/src/main/java/com/azure/resourcemanager/sql/implementation/RecommendedElasticPoolImpl.java
Azure/azure-sdk-for-java
mit
6,486
192
codeparrot/github-code
a40caa4e935839e6bf4e16390bf3e902e024ade6549cc1ca54811c452b7dea6c
#ifndef SIGNALFD_CTX_H_ #define SIGNALFD_CTX_H_ #include <signal.h> #include <stdint.h> #include <stdlib.h> #include <pthread.h> #include "kqueue_event.h" typedef struct { int kq; // non owning sigset_t sigs; KQueueEvent kqueue_event; } SignalFDCtx; typedef struct { uint32_t ssi_signo; int32_t ssi_errno; in...
C
src/signalfd_ctx.h
jiixyj/epoll-shim
mit
949
47
codeparrot/github-code
4354671807d6fa6c70e311b0580cdd02feea169d9a3209ebda535ac7052d1bcb
package com.mozidev.newskeeper.presentation.injection; import android.content.Context; import com.mozidev.newskeeper.data.ArticlesDataProviderImpl; import com.mozidev.newskeeper.data.CategoriesDataProviderImpl; import com.mozidev.newskeeper.data.PublishersDataProviderImpl; import com.mozidev.newskeeper.domain.article...
Java
app/src/main/java/com/mozidev/newskeeper/presentation/injection/DataModule.java
zanctor/NewsKeeper
mit
1,726
69
codeparrot/github-code
c271721deee3cea4de86b8cc51657271f07fdcd0815acf65b94f87a771a2d3fa
<?php namespace At\Theme; use At\Theme\Resolver\ResolverInterface; use Zend\Expressive\Template\TemplateRendererInterface; use Zend\Stdlib\PriorityQueue; class Manager { /** * @var null|string */ protected $currentTheme; /** * @var null|\Zend\Stdlib\PriorityQueue */ protected $re...
PHP
src/Manager.php
atukai/theme-middleware
mit
4,837
192
codeparrot/github-code
752b0d15e46524ce604be8f3dc59dea7e708af23b3b371e1d457f2307213a8bf
# -*- coding:utf-8 -*- # This code is automatically transpiled by Saklient Translator import six from ..client import Client from .model import Model from ..resources.resource import Resource from ..resources.routerplan import RouterPlan from ...util import Util import saklient str = six.text_type # module saklient....
Python
saklient/cloud/models/model_routerplan.py
sakura-internet/saklient.python
mit
2,906
100
codeparrot/github-code
ee255153543c9c962b4cd5e6014332cf1175df4a50483adfa9ec9ec09f62cb40
/* ****************************************************************************** * @attention * * <h2><center>&copy; COPYRIGHT 2016 STMicroelectronics</center></h2> * * Licensed under MCD-ST Liberty SW License Agreement V2, (the "License"); * You may not use this file except in compliance with t...
C
firmware/stm32f4x7_eth.c
tvelliott/dsp_ice
mit
98,514
2,524
codeparrot/github-code
a836e72ad0d5f45374d91aa7e223d9222e4ae27494d7d98d295c35f82faae8ac
<?php /* DeleteOpportunities.php Marketo REST API Sample Code Copyright (C) 2016 Marketo, Inc. This software may be modified and distributed under the terms of the MIT license. See the LICENSE file for details. */ $delete = new DeleteOpportunities(); $delete->dedupeBy = "dedupeFields"; $delete->input ...
PHP
php/LeadDatabase/Opportunities/DeleteOpportunities.php
Marketo/REST-Sample-Code
mit
2,367
74
codeparrot/github-code
8b8030de9c5217ba494f7150735237b0822ba21fea25868b986d457812823e71
#include <stdlib.h> #include <stdio.h> #include <stdint.h> #include <string.h> #include <inttypes.h> typedef enum { NIL, SYMBOL, NUMBER, ERROR, LIST, LAMBDA, MACRO, FUNC, ENV } type; #define nil (value_t) { NIL, 0 } #define check_error(A) if (A.type == ERROR) return A; typedef int64_t chunk_t; typedef struct { ...
C
c/libdabble.c
josephburnett/callow
mit
22,349
949
codeparrot/github-code
f8b09e947524a964db58987f63419f03fc4fe13b2caf685622335a7e4094e5e5
<!DOCTYPE html> <!--[if IE 8]> <html class="no-js lt-ie9" lang="zh-tw" > <![endif]--> <!--[if gt IE 8]><!--> <html class="no-js" lang="zh-tw" > <!--<![endif]--> <head> <meta charset="utf-8" /> <meta name="viewport" content="width=device-width" /> <title>{% if page.title %}{{ page.title }} - {% endif %}{{ s...
HTML
_layouts/master.html
rschiang/yojigen
mit
2,864
89
codeparrot/github-code
6bca78c7fe980bc30198606e4b8c89def4b0f0ed1f108fbe099ce4c6beac6225
""" This file is part of the tractor library. See LICENSE.txt for licensing, CONTRIBUTORS.txt for contributor information. Created on Jan 06, 2012. """ __docformat__ = 'reStructuredText en' __all__ = ['create_wrapper_for_ticket_creation', 'create_wrapper_for_ticket_update', 'TicketWrapper' ...
Python
tractor/ticket.py
helixyte/tractor
mit
15,619
524
codeparrot/github-code
9562964db982a82652b787e41d7e5fa5d0ca47f06555e91a8fd5ebcc3ee03fbd
var gulp = require('gulp'); var header = require('gulp-header'); var rename = require('gulp-rename'); var rimraf = require('gulp-rimraf'); var uglify = require('gulp-uglify'); var util = require('gulp-util'); var pkg = require('./package.json'); var currentYear = util.date(new Date(), 'yyyy'); var banner = '/*! <%= p...
JavaScript
Gulpfile.js
lare-team/lare.js
mit
999
32
codeparrot/github-code
babeb8d85226f528b41a381a9400965ddb6a856aba9ecccb6977e873b2a4a2a0
/** * Created by Mehdi on 2015-11-17. */ 'use strict'; var constants = require('../lib/constants'); var utils = {}; utils.isRequestValid = (body) => { try { return body != null && body != "" && body != {} && body[constants.req_param] != undefined && constants.movie_url_pattern....
JavaScript
lib/utils.js
code-guru/viaplay-trailer
mit
1,328
46
codeparrot/github-code
1e77cbf00d2e70cee26c5a60487a75d51f022099e5346d7ef98cce0da35dc25b
<?php namespace Tecnotek\RetoAprenderBundle\Form; use Symfony\Component\Form\AbstractType; use Symfony\Component\Form\FormBuilder; use Symfony\Component\Form\FormBuilderInterface; use Symfony\Component\Validator\Constraints\Email; use Symfony\Component\Validator\Constraints\MinLength; use Symfony\Component\Validator\...
PHP
src/Tecnotek/RetoAprenderBundle/Form/ContactType.php
selimcr/Tecnotek_RetoAprender
mit
1,346
45
codeparrot/github-code
9bec67994315a4ace4dc3a3ceb7a73e296f8ed1301564063f73f2b27133873a6
$(function(){ function getDataSync(){ let req = new XMLHttpRequest(); req.open('GET', 'https://api.codementor.io/api/v2/mentors/fixjs/reviews?cm_auth=5eed1556-91b0-4da8-b75c-36db1672f4e2', true); // since the third parameter is true when you call req.send // it pauses everything :BLOCKING req....
JavaScript
0-1-xhr-sample.js
fixjs/jsremoteconf-2016
mit
2,724
120
codeparrot/github-code
55459dfa6c59931c24bc54d93936da272062525cee457e7add2fd872edc834f0
class Registrar::DomainsController < Registrar::DeppController # EPP controller before_action :init_domain, except: :new before_action :init_contacts_autocomplete_map, only: [:new, :edit, :create, :update] # rubocop: disable Metrics/PerceivedComplexity # rubocop: disable Metrics/CyclomaticComplexity # ruboco...
Ruby
app/controllers/registrar/domains_controller.rb
domify/registry
mit
4,936
168
codeparrot/github-code
0babae306604e04ea94ba8ee1422417d8b81fe7cff2a9899002129eb73973143
/****************************************************************************** * Copyright AllSeen Alliance. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and th...
C++
alljoyn/alljoyn_core/unit_test/DescriptionTest.cc
Vovkasquid/compassApp
mit
22,482
562
codeparrot/github-code
7d5019d5dc8206bf23b9a3e0a6823269c3225e5a02b5a1f94250e0db586d5faf
# frozen_string_literal: true # rubocop:disable Rails/Output class EnvironmentSetup # Increment this version if you change the setup such that everyone should re-run this VERSION = 2 ENV_FILE = File.expand_path("../../.ruby-env", __FILE__).freeze RED = "\e[31m".freeze GREEN = "\e[32m".freeze BOLD = "\e[1m"....
Ruby
lib/environment_setup.rb
samerbuna/Grantzilla
mit
2,853
123
codeparrot/github-code
60baea646e87fda47d62fdf004bc6f987af1ef517839b051fe401abfdd86cba6
using System; using System.Collections.Generic; using System.Linq; using System.Numerics; using System.Text; using System.Threading.Tasks; namespace _011EnigmaSecondTry { class EnigmaSecondTry { static string allLetters = "abcdefghijklmnopqrstuvwxyz"; static void Main(string[] args) {...
C#
C#TwoFinalExam/CSharpTwoFinalExam/011EnigmaSecondTry/EnigmaSecondTry.cs
TsvetanMilanov/TelerikAcademyFinalExams
mit
1,584
66
codeparrot/github-code
075f7464bba4e46a08d3fa54d98ee6023724cfc8a5ee324ba8b97faba939e0fa
namespace DylanSharp.Core.Expressions { using System; using System.Collections.Generic; using System.Linq; using System.Text; public class DefineExpression : IExpression { private string name; private string typename; private IExpression expression; ...
C#
Src/DylanSharp.Core/Expressions/DefineExpression.cs
ajlopez/DylanSharp
mit
960
35
codeparrot/github-code
21399c1e3701dcb7bf8e1d8f49fdfcfa690ad7061ac54540f869b9e458a88079
#ifndef FORECASTER_H_INCLUDED #define FORECASTER_H_INCLUDED #include "ChinaL1DiscreteFeature.h" #include "RollScheme.h" #include <map> #include <vector> #include <string> #include <time.h> typedef std::vector<ChinaL1DiscreteFeature *> FeatureVector; typedef std::map<std::string, FeatureVector> FeatureMap; class For...
C
lib/libforecaster/forecaster.h
LMiceOrg/FemasTrader
mit
3,680
233
codeparrot/github-code
ca47b37913fd1180a750be7999fe7111ca5f0eb8da8fd544fd37e0ce82da6301
// import required dependencies import React from 'react'; import GoogleLogin from 'react-google-login'; /** * Create a react component * @class Body */ export default class Body extends React.Component { /** * Set user's state to either logged in or not logged in * @constructor */ constructor() { ...
JavaScript
src/app/components/Body.js
Boluwatifes/andela24
mit
2,559
86
codeparrot/github-code
c52a759d5eef40a74cd5b3fd3b72f1f51a7d395a1ecf991be6be70d40d1c8b00
package fileserver; import java.io.File; import java.text.DecimalFormat; import java.util.Date; public class test { String text=""; File[] rootFiles; public String Dummytext(String fileName){ if(!fileName.equals("getDrives") && !fileName.equals("checkDrives")) { File paramFile= new Fi...
Java
src/fileserver/test.java
t-k-c/FileServer
mit
11,175
230
codeparrot/github-code
0fdf43c94610ded7194db376b6ed9c840f9b51ac913e7c09c88e72d14346e070
package tagclients import ( "encoding/json" "github.com/gotokatsuya/growthpush/dispatcher" "github.com/gotokatsuya/growthpush/util" ) const endpoint = "tag_clients" type CreateNewTagClientRequest struct { ClientID string `json:"clientId"` TagID string `json:"tagId"` Value string `json:"value"` } type C...
GO
service/tagclients/tag_clients.go
gotokatsuya/growthpush
mit
875
38
codeparrot/github-code
a6f33d3e2df707b723723030577ae1d1337089a237b345340c6a53f19bc816e7
//******************************************************************* // CHORD MAPPER //******************************************************************* function chordMpr (data) { var mpr = {}, mmap = {}, n = 0, matrix = [], filter, accessor; mpr.setFilter = function (fun) { filter = fun; return...
JavaScript
chord_diagram_result/js/mapper.js
pestefo/viz-youtube
mit
2,320
82
codeparrot/github-code
5f095b3f898b22db1aa2d822b442af07838c0a064715556798299a20fdc197fc
/* The MIT License (MIT) Copyright (c) 2015 Martin Reinhardt 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...
Java
src/android/de/martinreinhardt/cordova/plugins/CertificatesCordovaWebViewClient.java
hypery2k/cordova-certificate-plugin
mit
2,891
97
codeparrot/github-code
14ee24c5592d0c8268aa35f5fea41db75ab778c9bd89cf429d43e03e1c2900b8
class HostsController < ApplicationController before_action :set_host, only: [:show, :edit, :update, :destroy] # GET /hosts # GET /hosts.json def index @hosts = Host.all end # GET /hosts/1 # GET /hosts/1.json def show end # GET /hosts/new def new @host = Host.new end # GET /hosts/1...
Ruby
app/controllers/hosts_controller.rb
murphybytes/serverscan
mit
1,772
75
codeparrot/github-code
2f8431c5389c08412dd91e632cd45d307987a5c52f85fe1ff7a206c548eaec0d
--https://moddota.com/forums/discussion/1205/making-any-ability-use-charges modifier_charges = class({}) if IsServer() then function modifier_charges:Update() if self:GetDuration() == -1 then self:SetDuration(self.kv.replenish_time, true) self:StartIntervalThink(self.kv.replenish_time) end if self:GetSta...
Lua
game/scripts/vscripts/modifiers/modifier_charges.lua
ark120202/aabs
mit
1,900
84
codeparrot/github-code
2a49007addbce7afc995594b9451e0b49f37d550a1ab5d5d8866c4482d2cea28
#ifndef DG_LEGACY_BFS_H_ #define DG_LEGACY_BFS_H_ #include "dg/ADT/Queue.h" #include "dg/legacy/NodesWalk.h" namespace dg { namespace legacy { enum BFSFlags { BFS_INTERPROCEDURAL = 1 << 0, BFS_PARAMS = 1 << 1, BFS_CFG = 1 << 2, BFS_REV_CFG = 1 << 3, BFS_CD = 1 << 4, BFS_DD = 1 << 5, BFS_R...
C
include/dg/legacy/BFS.h
mchalupa/dg
mit
2,172
92
codeparrot/github-code
730dedcab23a4cdf96177d3bee30907664e63bfdedc9f3833ee11b76c15fc297
<?php /* Unsafe sample input : get the field userData from the variable $_GET via an object, which store it in a array sanitize : none construction : interpretation with simple quote */ /*Copyright 2015 Bertrand STIVALET Permission is hereby granted, without written agreement or royalty fee, to use, copy, modify...
PHP
URF/CWE_601/unsafe/CWE_601__object-indexArray__no_sanitizing__header_file_name-interpretation_simple_quote.php
stivalet/PHP-Vulnerability-test-suite
mit
1,514
70
codeparrot/github-code
f376b2eb2128134019632eecd8ef2a0ae374db92f0ab04669172d96870fa7e8b
package com.vdurmont.vdmail.dto; import org.joda.time.DateTime; public class SessionDTO extends EntityDTO { private String token; private DateTime expirationDate; private UserDTO user; public String getToken() { return token; } public void setToken(String token) { this.token ...
Java
src/main/java/com/vdurmont/vdmail/dto/SessionDTO.java
vdurmont/vdmail
mit
663
34
codeparrot/github-code
bae35c031b54f7f11090f68eb0255f1deda5b929b0bf764b2352d99021fc6319
// Derived from public-domain/MIT-licensed code at // https://github.com/open-source-parsers/jsoncpp. Thanks, Baptiste Lepilleur! #pragma once #include "value.h" #include <vector> #include <string> #include <ostream> // Disable warning C4251: <data member>: <type> needs to have dll-interface to // be used by... #if ...
C
old/src/core/data/json/writer.h
dhh1128/intent
mit
10,419
321
codeparrot/github-code
da06c8e0788acbb7e148b9ab32b7a39b39ee1a38ab3374fa677375a842ac6381
import React from 'react' import { Menu, Icon, Popover } from 'antd' import BadgeBox from './BadgeBox' import styles from './Header.less' import Menus from './Menu' const SubMenu = Menu.SubMenu function Header ({user, logout, switchSider, siderFold, isNavbar, menuPopoverVisible, location, switchMenuPopover, navOpenKe...
JavaScript
src/routes/App/layout/Header.js
liufulin90/react-admin
mit
1,547
47
codeparrot/github-code
9eb78ff878f34e08da66520ce635ddc04e593a62be9f16241145cfc3939277f9
/* * Author: Minho Kim (ISKU) * Date: 2017.04.07 * E-mail: minho1a@hanmail.net * * https://github.com/ISKU/Algorithm * https://code.google.com/codejam/contest/32016/dashboard#s=p0 */ import java.util.Scanner; import java.util.ArrayList; import java.util.Collections; public class A_Large { public static void...
Java
CodeJam/2008/1A/A_Large.java
ISKU/Algorithm
mit
933
39
codeparrot/github-code
986972c3515952a09e29116293cef61dce2cf02b23bfe4e01df93846edce7796
<?php /** * This file is part of the m1\vars library * * (c) m1 <hello@milescroxford.com> * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. * * @package m1/vars * @version 1.1.0 * @author Miles Croxford <hello@milescrox...
PHP
src/Vars.php
m1/Vars
mit
9,785
371
codeparrot/github-code
12139267e2f000c8d7d2e397eccaa4a67e6166debbade2e4914c6ea3c6e24380
#include "tickit.h" struct TickitEventHook; typedef int TickitEventFn(void *owner, TickitEventType ev, void *info, void *data); void tickit_hooklist_run_event(struct TickitEventHook *hooks, void *owner, TickitEventType ev, void *info); int tickit_hooklist_run_event_whilefalse(struct TickitEventHook *hooks, void *ow...
C
terminal/libtickit/hooklists.h
dylan-foundry/deuce-terminal
mit
2,562
39
codeparrot/github-code
9c5f018c344247e6e6f0518849e5fe27c089cbeb211dd0bfce725fe961d4c43c
/****************************************************************************** * NSynth - A Managed Multimedia API - http://nsynth.gearedstudios.com/ * * Copyright © 2009-2013 William 'cathode' Shelley. All Rights Reserved. * * This software is released under the terms and conditions of the MIT/X11 *...
C#
source/NSynth/FilterProcessingContext.cs
cathode/nsynth
mit
4,675
138
codeparrot/github-code
88582da3bc8f8e9aae4707e5c18e1c81b45efdbd009b5dfc4810ff8d2ca89979
# -*- coding: utf-8 -*- # # This file is part of Invenio. # Copyright (C) 2015-2018 CERN. # # Invenio is free software; you can redistribute it and/or modify it # under the terms of the MIT License; see LICENSE file for more details. """Invenio error handlers.""" from __future__ import absolute_import, print_function...
Python
invenio_theme/views.py
inveniosoftware/invenio-theme
mit
1,481
52
codeparrot/github-code
9324344a30e8e31009d7b4ba8f6deb6ff355bab6ec1365f83cbf292f151a04a6
$(document).ready(function() { var iCnt = 0; // CREATE A "DIV" ELEMENT AND DESIGN IT USING JQUERY ".css()" CLASS. var container = $(document.createElement('div')).css({ padding: '5px', margin: '20px', width: '170px', border: '1px dashed' }); $('#btAdd').c...
JavaScript
js/multiplesElementos.js
chisquillo/App
mit
2,843
66
codeparrot/github-code
88e5cab44c5ba2e32663407082d268de4123d304ce929dfc3fab29b68fece03b
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); if ( ! function_exists('format_puid')) { // Formats a PUID with one leading zero // Returns '-1' if input string is blank or not a number function format_puid($dirty = NULL) { $clean = '-1'; // Exit if blank or NaN i...
PHP
application/helpers/puid_helper.php
heztet/phoenixclub
mit
1,122
47
codeparrot/github-code
f1741e2e58194e29ecbd515cb4d3d2fe222662a118fb570a88beb7d0cfcfc338
<?php defined('BASEPATH') OR exit('No direct script access allowed'); /* | ------------------------------------------------------------------------- | URI ROUTING | ------------------------------------------------------------------------- | This file lets you re-map URI requests to specific controller functions. | | T...
PHP
application/config/routes.php
zuhairtaha/pr1
mit
3,266
81
codeparrot/github-code
0e6b4acb59df3d682c0f8031d536c20ecefdf722cb04af5e0143f36735f0a43c
import json from django.contrib.auth.decorators import login_required from django.core.paginator import EmptyPage, PageNotAnInteger, Paginator from django.http import (HttpResponse, HttpResponseBadRequest, HttpResponseForbidden) from django.shortcuts import get_object_or_404, render from djang...
Python
spark/feeds/views.py
rg3915/spark
mit
6,435
211
codeparrot/github-code
79971e925c8cb374030548bf6d08bdcc78a18d0603e3a8ae312704efe77c9989
var assert = require('assert'), pass = require('../public/js/pass.js'), Api = require('../public/js/api.js')(pass.username, pass.password); describe('Api', function () { var sub = 'https://lobste.rs'; describe('userInfo()', function () { it('Should return correct username.', function (done) { Api.us...
JavaScript
test/api-test.js
tefu/inordinate
mit
3,149
115
codeparrot/github-code
7f0ba783f048b2c5825e9cc5217cd7bd7577681058edc9b2751965e7ce508401
using UnityEngine; using System.Collections; public class DecalBehaviour : MonoBehaviour { public SpriteRenderer SpriteRenderer; public Sprite BulletScorch; public Sprite ExplosionScorch; public Sprite BloodSplatter; public DecalState State; private float _livetime = 3.5f; private Spri...
C#
Unity/Assets/Scripts/RTS/Behaviours/DecalBehaviour.cs
aaron9000/simple-rts
mit
1,106
45
codeparrot/github-code
0210e64f9a8a8bafd48531478f78397cdd437170bc67063a943e9455a2402f8c
import pygame from pygame.locals import * class Food(pygame.sprite.Sprite): def __init__(self, tile, x, y): super(Food, self).__init__() self.tile = tile self.energy = 1000 w = self.w = 9 h = self.h = 5 self.image = pygame.Surface((w, h), SRCALPHA).convert_alpha()...
Python
evolutron/food.py
flexo/evolutron
mit
1,376
43
codeparrot/github-code
40a79bc4d0d0734951bba2a22722833c65588ccf1aeb2f536e94d7e5e9e3ff65
import org.eclipse.jetty.server.Connector; import org.eclipse.jetty.server.Handler; import org.eclipse.jetty.server.Server; import org.eclipse.jetty.server.handler.ContextHandlerCollection; import org.eclipse.jetty.server.nio.SelectChannelConnector; import org.eclipse.jetty.servlet.ServletContextHandler; import o...
Java
src/main/java/RunMe.java
dunse/try-it-out
mit
2,876
77
codeparrot/github-code
4ac67f496fab76d1a3ca77328cbad72101d637a520a9457820f30af1943e571e
<?php $this->view('header.html');?> <?php if (APP_VER < '2.2.2'): ?> <?php $cp_theme_folder = $this->EE->config->item('theme_folder_url') . 'cp_themes/' . $this->EE->config->item('cp_theme') . '/';?> <!-- ee 2.1.x doesn't have these styles and we still support it.. :/ --> <style type="text/css"> #mainContent h3...
HTML
nyusocial/expressionengine/third_party/user/views/preferences_form.html
ProJobless/nyus
mit
8,618
278
codeparrot/github-code
1e25f0eadea7d41eda14996dc45196907ad9f708814896cf8a7b9d0dfa887cf7
/** * @license * Visual Blocks Editor * * Copyright 2011 Google Inc. * https://developers.google.com/blockly/ * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apach...
JavaScript
BlockySource/blockly/core/blockly.js
simoesusp/RobosNaEscola
mit
17,720
608
codeparrot/github-code
aec2bd3b2b246dbe062de3cd9ae1ca4f4cebb07eac656ccdb87452d0480af943
package rorm type rorm struct { redisQuerier *RedisQuerier } func NewROrm() ROrmer { return new(rorm).Using("default") } func (r *rorm) QueryHash(key string) HashQuerySeter { return &hashQuerySet{ querySet: &querySet{ rorm: r, key: key, }, } } func (r *rorm) QueryKeys(key string) KeysQuerySeter { re...
GO
rorm.go
szyhf/go-DIRedisOrm
mit
1,084
70
codeparrot/github-code
9e8d2d293789d941ce54e7c57de8c85efa93b309f2bfd519a5e55322cbe313f4
var _ = require('lodash'); var when = require('when'); var Provider = require('../provider'); module.exports = [ Provider.extend({ name: 'ifixit', type: 'rich', uri: "//www\\.ifixit\\.com/[^#?/]+/[^#?/]+/.+$", version: 0, fetch: function(uri) { return this.fetchEmbed(uri, { api: 'h...
JavaScript
providers/domains_ij.js
numinos1/embedable
mit
1,791
80
codeparrot/github-code
cfcb0b5c5b1448172f17241534bb78550e1151780e69f6e931e6b939f30cac8a
require "log4r" require "vagrant/util/subprocess" require "vagrant/util/scoped_hash_override" require "vagrant/util/which" module VagrantPlugins module ManagedServers module Action # This middleware uses `rsync` to sync the folders over to the # AWS instance. class SyncFolders includ...
Ruby
lib/vagrant-managed-servers/action/sync_folders.rb
chrisbaldauf/vagrant-managed-servers
mit
4,021
105
codeparrot/github-code
dd657428637dcf0498f40ff4e54158c43b4e4c5b804e47842ba78180bc60bceb
#include <iostream> #include <vector> using namespace std; const long long MOD = 1000000007; vector<int> e[100000]; long long dp[100000][2]; int color[100000]; void dfs(int u) { dp[u][1] = 0; dp[u][0] = 1; for (int v : e[u]) { dfs(v); dp[u][1] *= dp[v][0]; dp[u][1] %= MOD; ...
C++
Codeforces/462D_Appleman and Tree/462D.cc
hangim/ACM
mit
830
50
codeparrot/github-code
9f7c3d100745f733b92187bd36b4aec94b6d9cba751a2887a8cfa0eb05bf9ce6
import {Component} from '@angular/core'; import {CHART_DIRECTIVES} from 'angular2-highcharts'; @Component({ selector:'chart-component-16', styles: [` chart { display: block; } `], template: ` <chart [options]="options" (load)="saveChart($event.context)"> <series (hide)="...
TypeScript
app/dashboard/land-use/chart-component-16.component.ts
nrbrigmon/launch2035
mit
3,171
99
codeparrot/github-code
84e86e3dd0b854ba0567367d95775d2e572eac07ce720bc95e080da034214245
/** * Created by Kristof on 5/11/2015. */ define('IDBKeyRange', [ 'util' ], function(util){ var IDBKeyRange = function(lower, upper, lowerOpen, upperOpen){ if(arguments.length === 0) return; // clone this.lower = lower; this.upper = upper; this.lowerOpen = lowerOpen ? lowerOpe...
JavaScript
src/IDBKeyRange.js
kristofdegrave/indexedDBmock
mit
2,560
85
codeparrot/github-code
2bc6dbb660359ed73af47d21c0a97121e2d2b73909bfd1062ff55499e4bff6e9
<?php namespace WS\Tools\ORM\Db\Gateway; /** * File definition * * @author my.sokolovsky@gmail.com */ class File extends Common { protected function setupFilterClass() { return \WS\Tools\ORM\Db\Filter\File::className(); } /** * @param $path * @return \WS\Tools\ORM\BitrixEntity\File...
PHP
lib/orm/db/gateway/file.php
worksolutions/bitrix-module-tools
mit
696
31
codeparrot/github-code
6f547299fa5705c675bc5523631f09049fbad24ad61e39bceb22caac9815633b
package com.edms.core.common.bean; import com.edms.core.common.constant.IPlatformConstant; import java.util.HashMap; import java.util.Map; public class ResponseBean { private String code; private String message; private Map<String, Object> data = new HashMap<String, Object>(); public ResponseBean() {} pub...
Java
edms-core/src/main/java/com/edms/core/common/bean/ResponseBean.java
junwang1216/btgk-edms
mit
1,335
59
codeparrot/github-code
a5c460781f7f1539a69a865908bd34742153bcab52f4567b30483e996dcb9295
package org.craft.world.populators; import java.util.*; import org.craft.blocks.*; import org.craft.maths.*; import org.craft.world.*; public class MountainsPopulator implements IWorldPopulator { private int startChunkY; private int maxHeight; private Block surfaceBlock; private Block interiorBl...
Java
src/main/java/org/craft/world/populators/MountainsPopulator.java
OurCraft/OurCraft
mit
1,874
59
codeparrot/github-code
57602c42f867d33aa792911812af30f4526b62e375fa1904b13c7f5b90a70ace
<div class="modal-header"> <h3>Log in</h3> <p>Please log in using your credentials</p> <div class="modal-body"> <?php // echo "<pre>"; // echo print_r($this->session->userdata, TRUE); // print_r($this->session); // echo "</pre>"; // echo "</pre>"; // echo "S...
PHP
application/views/admin/user/login.php
arslankhurshid/mywork
mit
2,247
73
codeparrot/github-code
e23408ffb5d2a947c742967d94ff6edc53d86af2a5e4ee90259702899aeb7864
import { Component, OnInit, OnDestroy } from '@angular/core'; import { SharedVariableService } from "../../../_service/sharedvariable-service"; import { ActionBtnProp } from '../../../_model/action_buttons'; import { Subscription } from 'rxjs/Subscription'; import { DRService } from '../../../_service/docrepo/dr-servic...
TypeScript
src/app/modules/docrepo/view/viewdr.comp.ts
masagatech/erpv1
mit
3,566
122
codeparrot/github-code
e4c25206ac2c843132f9d033ee9dd25db2dd065ce4fae9d81b556aacf1fcdaeb
namespace DazPaz.Cyclone { public class SpringForceGenerator : IParticleForceGenerator { #region Properties private IParticle OtherParticle { get; set; } private double SpringConstant { get; set; } private double RestLength { get; set; } private bool IsBungeeSpring { get; set; } #endregion #region C...
C#
src/DazPaz.Cyclone/SpringForceGenerator.cs
dazpaz/Cyclone
mit
1,065
43
codeparrot/github-code
663076c895942acec7e97241f21fc1fd94454be358387f0211f02b5f28d1b838
// Constructor Function // -------------------- function AsyncSpec(spec){ this.spec = spec; } (function(){ // Public API // ---------- AsyncSpec.prototype.beforeEach = function(block){ this.spec.beforeEach(runAsync(block)); }; AsyncSpec.prototype.afterEach = function(block){ this.spec.afterEach(runAsync(block...
JavaScript
src/jasmine.async.js
alextseng/karma-jasmine-async
mit
826
46
codeparrot/github-code
ab6d074df42cb23b254ce6ab7a02340e6c7ce0de9936b593812495bedb02e5ae
<?php use Symfony\Component\HttpKernel\Kernel; use Symfony\Component\Config\Loader\LoaderInterface; class AppKernel extends Kernel { public function registerBundles() { $bundles = [ new Symfony\Bundle\FrameworkBundle\FrameworkBundle(), new Symfony\Bundle\SecurityBundle\Security...
PHP
app/AppKernel.php
Nieobliczalny/paw-server
mit
1,769
54
codeparrot/github-code
0f44e517d684e075d882d7166935c7f3815cf2c9a557e4fb146d29fc754d8159
var Data = function(data) { this.data = data || null; this.features = new Array(); this.getData = function(){ return this.data; }; this.setData = function(data){ this.data = data; }; this.getFeatures = function(){ return this.features; }; this.setFeatures = function(features){ this.features = fe...
JavaScript
assets/js/model/data.js
renanpupin/geovis
mit
5,966
188
codeparrot/github-code
bca93549b108567965f3dfcbb8fda9730d9cff3255c67450d70189b2abd2d03a
using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Windows.Forms; using System.IO; using System.Xml; using System.ServiceModel.Syndication; using System.Diagnostics; using GenericForms; namespace Word...
C#
Wordy/formOptions.cs
Winterstark/Wordy
mit
16,176
480
codeparrot/github-code
ece60571219865c4ceefd8ceeceee488957d12de88b9fcd7ad3e674340f1c926
#!/usr/bin/env python # -*- coding:utf-8 -*- """ .. note:: This module is not designed to be used by user. """ import contextlib import distutils.spawn import fcntl import os import pty import select import subprocess class Process(object): """ A class representing a background *Vim* process. """ de...
Python
headlessvim/process.py
manicmaniac/headlessvim
mit
3,571
133
codeparrot/github-code
bbd51253cd52817591cbe04fb62747ac9d6af242a7ee75ea30b7aeff0ef05234
'use strict'; exports.__esModule = true; var _stringify = require('babel-runtime/core-js/json/stringify'); var _stringify2 = _interopRequireDefault(_stringify); var _promise = require('babel-runtime/core-js/promise'); var _promise2 = _interopRequireDefault(_promise); var _regenerator = require('babel-runtime/rege...
JavaScript
lib/index.js
d925529/dubbo-hessian
mit
48,664
867
codeparrot/github-code
30c6cfacc7437b8cec51c921db67d48167d838298e309be97c7087bc69064d9d
#!/usr/bin/env python description = ">> make final magnitude" usage = "%prog image [options] " import os import string import re import sys from optparse import OptionParser import time import math import agnkey import numpy as np if __name__ == "__main__": start_time = time.time() parser = OptionParser(usag...
Python
trunk/bin/agnmag.py
svalenti/agnkey
mit
19,750
320
codeparrot/github-code
860c4686dd4c40f53bc6f06aa600f80ceb9fdabe125f0ddf4ed534851408704e
using System.ComponentModel.DataAnnotations; using System.Threading.Tasks; using CmsEngine.Application.Services; using CmsEngine.Data.Entities; using Microsoft.AspNetCore.Identity; using Microsoft.AspNetCore.Mvc; using Microsoft.AspNetCore.Mvc.RazorPages; using Microsoft.Extensions.Logging; namespace CmsEngine.Ui.Areas...
C#
CmsEngine.Ui/Areas/Identity/Pages/Account/Manage/ChangePassword.cshtml.cs
davidsonsousa/CMSEngine
mit
3,649
107
codeparrot/github-code
c46de60586aacb8b7152d1ac2a1efcf4a1131877bc7a41108d07e43e3b1ba4e3
// Copyright (c) 2011-2013 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 <QApplication> #include "bitcoingui.h" #include "clientmodel.h" #include "walletmodel.h" #include "optionsmodel.h" #...
C++
src/qt/bitcoin.cpp
neutrinofoundation/neutrino-digital-currency
mit
10,792
311
codeparrot/github-code