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 |
|---|---|---|---|---|---|---|---|---|
ba83bcb65aadbdc2ccb7991b567d8cace1b6b434c028cdad6694a92446806d6c | package es.infointernet.bean;
import java.security.Principal;
import java.util.List;
public class User implements Principal {
private String username;
private List<String> roles;
public String getUsername() {
return username;
}
public void setUsername(String username) {
this.username = use... | Java | src/main/java/es/infointernet/bean/User.java | mpecero/jaxrs-jwt-example | mit | 538 | 34 | codeparrot/github-code |
c0e0714779e00bdfca0c1975d09fcb7d9e9303fff258808a9933ad2cb40d72b7 | package org.sharedmq.primitives;
import java.nio.ByteBuffer;
/**
* An adapter for the {@link MappedByteArrayStorageKey}.
*/
public class MappedByteArrayStorageKeyStorageAdapter implements StorageAdapter<MappedByteArrayStorageKey> {
private static final MappedByteArrayStorageKeyStorageAdapter instance
... | Java | src/main/java/org/sharedmq/primitives/MappedByteArrayStorageKeyStorageAdapter.java | yu-kopylov/shared-mq | mit | 1,277 | 43 | codeparrot/github-code |
636dca3c1a6ac3f269e629246e9524eb4d3e594449195291573846e288b3704f | package algorithms.imageProcessing.features;
import algorithms.util.PairInt;
import algorithms.util.PixelHelper;
import gnu.trove.iterator.TIntIterator;
import gnu.trove.set.TIntSet;
import gnu.trove.set.hash.TIntHashSet;
import java.util.HashSet;
import java.util.Set;
import algorithms.packing.Intersection2DPacking;
... | Java | src/algorithms/imageProcessing/features/PatchUtil.java | nking/curvature-scale-space-corners-and-transformations | mit | 12,845 | 453 | codeparrot/github-code |
7136d93e780bd6d66eeb61f759ad3bc2ff03178a0ad79656eeb8c36d4d32ba1d | // Package services provides Github Integration.
package services
import (
"encoding/json"
)
// Git structs
type User struct {
Name string
Email string
Username string
Display_name string
}
type GitRepository struct {
Id int
Name string
Full_name ... | GO | services/git.go | PredictionGuru/webhook | mit | 2,755 | 111 | codeparrot/github-code |
468d36178ca58ddfc504a838af4541070e95c92e4d33c846a14f27d0cf2c621e | <?php
namespace Nht\Http\Requests;
use Nht\Http\Requests\Request;
class AdminCategoryRequest extends Request
{
/**
* Determine if the user is authorized to make this request.
*
* @return bool
*/
public function authorize()
{
return true;
}
/**
* Get the validation rules that apply to the request.
... | PHP | app/Http/Requests/AdminCategoryRequest.php | alvintran/rapian-document | mit | 667 | 41 | codeparrot/github-code |
1652898f47e6738d8355d95ce0a76c9d2703b518f30efc457f505cbc4732b371 | <!DOCTYPE html>
<html lang="en">
<head>
<!-- The jQuery library is a prerequisite for all jqSuite products -->
<script type="text/ecmascript" src="../../../js/jquery.min.js"></script>
<!-- This is the Javascript file of jqGrid -->
<script type="text/ecmascript" src="../../../js/trirand/jquery.jqGri... | HTML | assets/lib/gurido/bootstrap/paging/client_paging/index.html | lapakku2016/ciproject | mit | 2,917 | 74 | codeparrot/github-code |
408bbc1bd1390ecb3987d6d7d0d8bb71217abb83265af4dec5e7ee6e5008bf1f | 'use strict';
var assert = require('assert'),
mongoose = require('mongoose'),
mobgoose = require('../')(mongoose);
var Foo = mongoose.model('Foo', new mongoose.Schema({}), 'foo_collection_name');
it('accepts configuration without url', function() {
return mobgoose({ host: 'localhost', database: 'test123' }... | JavaScript | test/spec.js | dougmoscrop/mobgoose | mit | 2,576 | 94 | codeparrot/github-code |
0ea6a08c5e537ce3cc3fdf6cf354b582893fd921990f3da993a7505b5a780a77 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Security;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Mvc;
using Microsoft.Extensions.Logging;
using NBitcoin;
using Newtonsoft.Json;
using Stratis.Bitcoin.Consensus;
using Stratis.Bitcoin.Controllers;
using Stratis.Bitcoin.Fe... | C# | src/Stratis.Bitcoin.Features.Wallet/WalletRPCController.cs | quantumagi/StratisBitcoinFullNode | mit | 34,890 | 716 | codeparrot/github-code |
98d2ed66d52ee2cd0474761f1f6b4a4d41eeaa9e95eb3251a8e79c4048f08354 | using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Net;
public class Point
{
public double X { get; set; }
public double Y { get; set; }
}
class Program
{
static void Main()
{
var pointOne = ReadPointCoordinates();
var pointTwo = ... | C# | Programming Fundamentals/13.ObjectsAndClassesLab/04.V2.DistanceBetweenTwoPoints/V2DistanceBetweenTwoPoints.cs | kalinmarkov/SoftUni | mit | 923 | 39 | codeparrot/github-code |
4b9688953f807e2d5fef5cf9f6b90983cd9e8f637d91cb072d99d68a495b3034 | /*
* Copyright (c) 2019 Handywedge Co.,Ltd.
*
* This software is released under the MIT License.
*
* http://opensource.org/licenses/mit-license.php
*/
package com.handywedge.context;
import java.util.Date;
import javax.enterprise.context.RequestScoped;
import com.handywedge.context.FWRequestContext;
import lo... | Java | handywedge-master/handywedge-core/src/main/java/com/handywedge/context/FWRequestContextImpl.java | cstudioteam/csFrame | mit | 616 | 31 | codeparrot/github-code |
d24e77cf4a281798bc61d94a1604b94e2b6f693912cbe8d40f356403b228258f | using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.Text;
namespace AspxCommerce.ServiceItem
{
[Serializable]
[DataContract]
public class ServiceItemsDetailsInfo
{
[DataMember]
private int _itemID;
[DataMember]
... | C# | AspxCommerce.ServiceItem/Entity/ServiceItemsDetailsInfo.cs | AspxCommerce/AspxCommerce2.7 | mit | 2,883 | 129 | codeparrot/github-code |
a94ddd8ab54406c3e089df9db0bef4cb5e1cc95b567d40de6f01253f4633d9fe | <?php
/* @Framework/Form/search_widget.html.php */
class __TwigTemplate_1e27897cdf53745818839e0426e315ba62e8c6dc797e62f5556e82b242f48ae4 extends Twig_Template
{
public function __construct(Twig_Environment $env)
{
parent::__construct($env);
$this->parent = false;
$this->blocks = array... | PHP | app/cache/prod/twig/ce/ce45fd5017f3759799c3c6de030876e2d9ecdf7fec1bb9e4dbdf5a086758c464.php | youcefboukersi/serveurdevoeux | mit | 1,407 | 46 | codeparrot/github-code |
d7dae0c180acdf9b0c8e0956c43469d6919572721d388aa8cd17a642daef557a | package lcf.clock.prefs;
import java.util.List;
import lcf.clock.R;
import lcf.weather.CitiesCallback;
import lcf.weather.City;
import lcf.weather.WeatherMain;
import android.content.Context;
import android.content.SharedPreferences;
import android.os.Bundle;
import android.preference.PreferenceManager;
import androi... | Java | app/src/main/java/lcf/clock/prefs/CityDialog.java | Nikolay-Kha/TabletClock | mit | 4,834 | 174 | codeparrot/github-code |
3330d343a239b17dd86a0dd911f9215ba925ae1c44e6f77ec4d2370a7dc0f9a3 | /**
* Using Rails-like standard naming convention for endpoints.
* GET /api/bridges -> index
* POST /api/bridges -> create
* GET /api/bridges/:id -> show
* PUT /api/bridges/:id -> upsert
* PATCH /api/bridges/:id -> patch
* DELETE /api/br... | JavaScript | server/api/bridge/bridge.controller.js | sunshouxing/bshm | mit | 2,898 | 119 | codeparrot/github-code |
45a2c47d2f32f097954d8dd93166967f538c284fb73e8114c11417dd3c19c67a | <?php
class Jobs extends CI_Controller {
public function __construct()
{
parent::__construct();
$this->load->model('job_get');
$this->load->helper('url_helper');
$this->load->library('session');
}
public functio... | PHP | Jobs.php | Skchoudhary/Challenge | mit | 1,017 | 32 | codeparrot/github-code |
bc293c05a9dc3d62ea928790ab37a9aab049a1c4b4530cacace252d3698135a0 | /*
jQuery UI Sortable plugin wrapper
@param [ui-sortable] {object} Options to pass to $.fn.sortable() merged onto ui.config
*/
angular.module('ui.sortable', [])
.value('uiSortableConfig',{})
.directive('uiSortable', [ 'uiSortableConfig',
function(uiSortableConfig) {
return {
... | JavaScript | javascripts/angular-sortable.js | kdisneur/wish_list | mit | 4,272 | 123 | codeparrot/github-code |
a0978c86b37dcee2e869f2a2a3390885f267b5f9b4519c641d008e77cda7a6b7 | <?xml version="1.0" ?><!DOCTYPE TS><TS language="et" version="2.0">
<defaultcodec>UTF-8</defaultcodec>
<context>
<name>AboutDialog</name>
<message>
<location filename="../forms/aboutdialog.ui" line="14"/>
<source>About Bitcoin</source>
<translation type="unfinished"/>
</message>
... | TypeScript | src/qt/locale/bitcoin_et.ts | jlcurby/NobleCoin | mit | 98,083 | 2,499 | codeparrot/github-code |
19ac4c526889a3fe0fbe8ff76a9f13fee2cc22981128b81c8d17f14f08febd9c | // -----------------------------------------------------------------------
// <copyright file="SubscriptionDailyUsageRecordCollectionOperations.java" company="Microsoft">
// Copyright (c) Microsoft Corporation. All rights reserved.
// </copyright>
// ---------------------------------------------------------------... | Java | PartnerSdk/src/main/java/com/microsoft/store/partnercenter/usage/SubscriptionDailyUsageRecordCollectionOperations.java | iogav/Partner-Center-Java-SDK | mit | 3,167 | 70 | codeparrot/github-code |
30ccde94ef98af3f490d17ebb239d64ae1e2eb63166ae719d840d0837ba371c4 | local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
local NPCT = E:NewModule('NameplateTweaks', 'AceEvent-3.0')
local NP = E:GetModule('NamePlates')
if E.private.npct == nil then E.private.npct = {} end
if P.npct == nil then P.npct = {} end
-- Locked Settings, These settings... | Lua | config.lua | Lleafll/ElvUI_NPTweaks | mit | 2,598 | 93 | codeparrot/github-code |
9363d59e7d9b888c1c1752a0ab2fa96346f689a0d2c55aa74eb734e62c5920a7 | // The MIT License (MIT)
//
// Copyright (c) 2015-2016 Rasmus Mikkelsen
// Copyright (c) 2015-2016 eBay Software Foundation
// https://github.com/rasmus/EventFlow
//
// Permission is hereby granted, free of charge, to any person obtaining a copy of
// this software and associated documentation files (the "Software")... | C# | Source/EventFlow.Examples.Shipping/Application/BookingApplicationService.cs | AntoineGa/EventFlow | mit | 2,843 | 66 | codeparrot/github-code |
70a0ffa3adaf95109bc1ecc0711d4642578e36dd543ba1b3d6128655d58cb02f | // ***********************************************************************
// Filename : StopWatch.h
// Author : LIZHENG
// Created : 2014-04-28
// Description : 高精度计时器
//
// Copyright (c) lizhenghn@gmail.com. All rights reserved.
// ******************************************************... | C | zlreactor/base/StopWatch.h | lizhenghn123/zl_reactor | mit | 2,562 | 105 | codeparrot/github-code |
5a4920fa049dd37b3367a8488e07e24cc4d58fc62147b000f6368d1849143793 | import { jMask } from '@mask-j/jMask';
import { parser_parse, mask_stringify } from '@core/parser/exports';
import { listeners_on, listeners_off } from '@core/util/listeners';
UTest({
'should parse name' () {
var ast = jMask(`
define Foo {
h4 > 'Hello'
}
`);
var def = ast.filter('define').get(0);
eq... | TypeScript | test/node/parser/define.spec.ts | atmajs/MaskJS | mit | 2,850 | 110 | codeparrot/github-code |
e8a193245c9f7dc192ee7620ed71fa69f119d673599d18fd8d7158471caa3a9f | var fs = require('fs');
var os=require('os');
var express = require('express'),
// wine = require('./routes/wines');
user = require('./services/user');
contact = require('./services/contact');
inbox = require('./services/inbox');
outbox = require('./services/outbox');
device = require('./services/devic... | JavaScript | server.js | tonycaovn/vivuserver | mit | 6,443 | 207 | codeparrot/github-code |
31f1f6ac7d05dae9c10c40f0914a03c1d66ed55e0545de02bfa032d997c264cd | package cc.hughes.droidchatty;
public class SearchResult
{
private int _postId;
private String _author;
private String _content;
private String _posted;
public SearchResult(int postId, String author, String content, String posted)
{
_postId = postId;
_author = author;
... | Java | src/cc/hughes/droidchatty/SearchResult.java | arhughes/droidchatty | mit | 661 | 39 | codeparrot/github-code |
4ca3be3d7694fcb2f2cc103fbf4af27d733ecb03dc2b2e82a55dc8764f1c0bcc | /**
*
* Description: Simple Chat Server.
* Author: Deric Fagnan
*
*
*
*/
#include <stdio.h>
#include <stdlib.h>
#include <string.h> //strlen
#include <unistd.h> //write
#include <sys/socket.h>
#include <sys/types.h>
#include <netinet/in.h>
#include <arpa/inet.h> //inet_addr
#include <pthread.h> //for threading , l... | C | src/server.c | deric92/chatroom | mit | 4,223 | 180 | codeparrot/github-code |
61dddff5042201862aa31649aa08844fc58b422972ffe62bac1d02c055d47479 | # -*- coding: utf-8 -*-
import sqlite3
VERBOSE = 0
CTABLE_DOMAIN = '''
CREATE TABLE IF NOT EXISTS Domains(
did INTEGER PRIMARY KEY AUTOINCREMENT,
domain VARCHAR(64) UNIQUE,
indegree INTEGER,
outdegree INTEGER
)'''
CTABLE_WEBSITE = '''
CREATE TABLE IF NOT EXISTS Websites(
wid INTEGER PRIMARY KEY AUTOINCREMENT,
... | Python | WebModel/database/databasehelper.py | JaySon-Huang/WebModel | mit | 4,250 | 164 | codeparrot/github-code |
4635b1fd0ab8051a723cc1c57ad79e7c455da8e5ffc9b73203f6ee271184d81a | #include <stdio.h>
#include <stdlib.h>
#include <stdint.h>
#define PACKET_SIZE 256
#define THRESHOLD_VAL 10
// Performs thresholding with <THRESHOLD_VAL> and performs zero-length encoding
// @data: pointer to the dataset to encode; encodes <PACKET_SIZE> bytes at a time
// @output: pointer to the output buffer; ... | C | src/encode.c | arnettus/marco | mit | 1,022 | 43 | codeparrot/github-code |
e8bf225be0bbd113dd6691065066492e7d14b8f5cee0617c165c256682391f21 | package com.muller.wikimagesearch.volley;
import com.android.volley.AuthFailureError;
import com.android.volley.NetworkResponse;
import com.android.volley.ParseError;
import com.android.volley.Request;
import com.android.volley.Response;
import com.android.volley.toolbox.HttpHeaderParser;
import com.google.gso... | Java | app/src/main/java/com/muller/wikimagesearch/volley/GsonRequest.java | lauw/mustached-octo-happiness | mit | 1,897 | 56 | codeparrot/github-code |
421d7e3d4b21f5daefd3818eff0e68032aef16a04e5b1a66841b15d04418a61d | # coding: utf-8
import re
from crossword import *
class Crossword2(Crossword):
def __init__(self):
self.grid = OpenGrid()
self.connected = {}
self.used_words = []
def copy(self):
copied = Crossword2()
copied.grid = self.grid.copy()
copied.connected = self.co... | Python | crossword2.py | yattom/crossword | mit | 7,931 | 268 | codeparrot/github-code |
64795a52aa70caa13a45cc0b97b220cf2ab516cf124df2b625c3166637f40489 | // Javascript helper functions for parsing and displaying UUIDs in the MongoDB shell.
// This is a temporary solution until SERVER-3153 is implemented.
// To create BinData values corresponding to the various driver encodings use:
// var s = "{00112233-4455-6677-8899-aabbccddeeff}";
// var uuid = UUID(s); // ... | JavaScript | lib/uuidhelpers.js | sragu/mongo-uuid | mit | 6,977 | 154 | codeparrot/github-code |
ab0500c3faf1c900920962803b4adacdaa2dba44a511cbb675e8d464a99b3af3 | using System.Xml;
namespace Anycmd.Xacml.Policy.TargetItems
{
/// <summary>
/// Represents a read-only Action element in the Policy document. This class is a specialization of TargetItem class
/// which contains the information needed for all the items that can be part of the target.
/// </summary>
public class A... | C# | src/Anycmd.Xacml/Policy/TargetItems/ActionElement.cs | anycmd/anycmd | mit | 2,034 | 61 | codeparrot/github-code |
e83dc91b002859c633f5dfb1aa2427b6e3bb94eb4019beb5512e5f915793dddb | <?php
class Input {
public static $is_parsed = false;
public static $params = [];
/**
* Парсит и сохраняет все параметры в переменной self::$params
*
* @access protected
* @return $this
*/
protected static function parse() {
if (filter_input(INPUT_SERVER, 'argc')) {
$argv = filter_inpu... | PHP | core/Input.php | dmitrykuzmenkov/kisscore | mit | 2,431 | 87 | codeparrot/github-code |
74eea8b141fc2ca2b7c1b4ddc16184df277c649c329ed57336f89fd596d0ff88 | //
// VariableValueReference.cs
//
// Author:
// Lluis Sanchez Gual <lluis@novell.com>
//
// Copyright (c) 2009 Novell, Inc (http://www.novell.com)
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to de... | C# | Mono.Debugging.Soft/VariableValueReference.cs | joj/debugger-libs | mit | 3,237 | 113 | codeparrot/github-code |
b4b49e4ee53617644d883339ce1fff91761576d61b603c5c51ac6185d5e49379 | // Langevin.h -- The Velocity Verlet molecular dynamics algorithm.
// -*- c++ -*-
//
// Copyright (C) 2001-2011 Jakob Schiotz and Center for Individual
// Nanoparticle Functionality, Department of Physics, Technical
// University of Denmark. Email: schiotz@fysik.dtu.dk
//
// This file is part of Asap version 3.
//
/... | C | Asap-3.8.4/Basics/Langevin.h | auag92/n2dm | mit | 3,141 | 96 | codeparrot/github-code |
c390d786220f02f5d73b35844f761f2f3536bf6866ecff121ab57bdd48335d8f | <!DOCTYPE html>
<!--[if IE 6]> <html id="ie ie67 ie6" dir="ltr" lang="en-US"> <![endif]-->
<!--[if IE 7]> <html id="ie ie67 ie7" dir="ltr" lang="en-US"> <![endif]-->
<!--[if IE 8]> <html id="ie ie678 ie8" dir="ltr" lang="en-US"> <![endif]-->
<!--[if !(IE 6) | !(IE 7) | !(IE 8) ]><!--> <html dir="ltr" lang="en-US"> <... | PHP | index2.php | Southbay-CityChurch/crossings-community | mit | 2,438 | 61 | codeparrot/github-code |
4e3d544672acc6f0b2661803cc3beb9d76a29f3072970815003f3fbcae5c310b | #!/usr/bin/php -q
<?php
/*
The MIT License (MIT)
Copyright (c) 2015 Gary Smart www.smart-itc.com.au
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 limitati... | PHP | automator/createTicketPeriod.php | garyns/osTicket-extensions | mit | 5,765 | 196 | codeparrot/github-code |
204b993da99e971e2eff29302b456c85243b4d4fda9d547d7b8cec16110e4449 | <?php
namespace Recurrence\Validator;
use Recurrence\Model\Frequency;
use Recurrence\Model\Recurrence;
use Recurrence\Constraint\ProviderConstraint\EndOfMonthConstraint;
use Recurrence\Model\Exception\InvalidRecurrenceException;
/**
* Class RecurrenceValidator
* @package Recurrence\Validator
*/
class RecurrenceVa... | PHP | src/Recurrence/Validator/RecurrenceValidator.php | Samffy/recurrence | mit | 1,331 | 42 | codeparrot/github-code |
f8fd936a491797fe624a2b40bfb0b1601dfa654eed7458738b173283f94bb644 | #ifndef QMLTAB_H
#define QMLTAB_H
#include <QWidget>
#include <QLayout>
#include <QQuickView>
#include <QQmlEngine>
#include <QQuickItem>
#include <QQmlComponent>
#include <QVariantList>
#include <QApplication>
#include <memory>
#include "dbi/dbi.h"
class QmlTab : public QWidget
{
Q_OBJECT
public:
explicit Qm... | C | src/qmltab/qmltab.h | Sushisource/wubwub | mit | 607 | 35 | codeparrot/github-code |
e5bd71a9e8e33069df6d5364453f15e6f69f8a3464b54e3f35538fbc6a59fd45 | package org.openforis.collect.web.manager;
import java.util.HashMap;
import java.util.Map;
import org.openforis.collect.manager.CachedRecordProvider;
import org.openforis.collect.model.CollectRecord;
import org.openforis.collect.model.CollectRecord.Step;
import org.openforis.collect.model.CollectSurvey;
public class... | Java | collect-server/src/main/java/org/openforis/collect/web/manager/SessionRecordProvider.java | openforis/collect | mit | 1,273 | 46 | codeparrot/github-code |
2b23b10575cba3c5676116e9fe65c3db6b6c34998df1eb2f497b2acda924a252 | <?php
class Controller
{
private $project;
private $request;
private $response;
private $user;
private $template_engine;
public function __construct(BaseProject $project, Request $request=null)
{
$this->project = $project;
$this->request = $request;
}
public function getActionName($action)
{
return... | PHP | Muesli/Lib/Muesli/Controller/Controller.php | iamkoby/muesli | mit | 3,549 | 144 | codeparrot/github-code |
932abb9738692620e252478b62aee0fdd3e5698338ecdc19fdffc17ce4ed9a9d | /**
* @author Phuluong
* Feb 13, 2016
*/
/** Exports **/
module.exports = new Config();
/** Imports **/
var fs = require("fs");
var util = require(__dir + '/core/app/util');
/** Modules **/
function Config() {
var configContainer = {};
/**
* Get config value by key
* @param {String} key
* @par... | JavaScript | framework/core/app/config.js | phult/adu | mit | 1,664 | 57 | codeparrot/github-code |
e6c7e76c822939fa603dd8358785165632a99d1b859f35634b9ec7fa3ff238ef | /* jshint node: true */
module.exports = function(environment) {
var ENV = {
modulePrefix: 'addressbook-app',
environment: environment,
baseURL: '/',
locationType: 'auto',
emberPouch: {
localDb: 'dentone-addressbook',
remoteDb: 'https://wasilleptichandfurningio:6c01f93f266bb3cf6dfd579... | JavaScript | config/environment.js | adentone/addressbook-app | mit | 1,639 | 62 | codeparrot/github-code |
5f298aeadd045a354d023a5da3d211bcdb83d692fd7ae91dd310dc917661437b | import math
class Point:
def __init__(self, x, y):
self.x = x
self.y = y
def rssToEstimatedDistance(rss):
freq = 2462 # freq of WiFi channel 6
origDBm = -20 # estimate this value
loss = abs(origDBm - rss)
dist = 10 ** ( ( loss + 27.55 - 20 * math.log10(freq) )... | Python | app/Trilateration_Colin.py | DepthDeluxe/dot11sniffer | mit | 1,799 | 69 | codeparrot/github-code |
3dca5e4be47af6dada9edd7f1785d78786c456f0db0ca8bd3cc3237ca7f09777 | <!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Web 2.0</title>
<meta name="author" content="raesene">
<!-- Enable responsive viewport -->
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<!-- Le HTML5 shim, for IE6-8 support of HTML elements -->
<!--[if lt IE 9]>
<script s... | HTML | blog/2006/01/20/web_20/index.html | raesene/raesene.github.io | mit | 7,983 | 256 | codeparrot/github-code |
f771c46d16cbc9c96c210da1eed14332dfd9d1e12ed0920ba61ab98aba2c8514 | package _04MordorsCrueltyPlan;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
public class Wizard {
private static final Map<String, Integer> FOODS = new HashMap<String, Integer>() {{
put("cram", 2);
put("lembas", 3);
put("apple", 1);
put("melon", 1);
... | Java | JavaFundamentals/JavaOOPBasic/03.InheritanceExercise/src/_04MordorsCrueltyPlan/Wizard.java | yangra/SoftUni | mit | 1,184 | 48 | codeparrot/github-code |
c0ebcd852ba2312f563382354542f1dec439796423bd3523b4ba26ee45772298 | /* global describe, before, it */
require('mocha')
require('should')
var async = require('async')
var testUtils = require('./testUtils')
var errorMessage = require('../errorMessages/errorMessages')
var mongo_dcms_core = require('../index')
describe('should get file Content by file id', function () {
var filepath = '... | JavaScript | test/content.js | RaykorTech/mongo-dcms-core | mit | 1,897 | 67 | codeparrot/github-code |
a3d8c68d15ab665883252167bbfa4ea5020d8003dac6cb74eeb52fab5cdfd6d1 |
import { Behavior } from '@aelea/core'
import { $text, component, style } from '@aelea/dom'
import { $card, $column, $row, $seperator, $TextField, $VirtualScroll, layoutSheet, ScrollRequest, ScrollResponse } from '@aelea/ui-components'
import { pallete } from '@aelea/ui-components-theme'
import { at, debounce, empty, ... | TypeScript | website/src/pages/examples/virtual-scroll/$VirtualScrollExample.ts | nissoh/fufu | mit | 3,616 | 112 | codeparrot/github-code |
b7918379bf7d88a7825c3699d834b0420c4265c280bd2a2463378e019dd9440f | /* Definitions of target machine for GNU compiler. MIPS version.
Copyright (C) 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998
1999, 2000, 2001, 2002, 2003, 2004, 2005, 2007, 2008, 2009
Free Software Foundation, Inc.
Contributed by J. Grosbach, james.grosbach@microchip.com
Changes by J. Kajit... | C | MacOS core/chipkit-core/pic32/compiler/pic32-tools/lib/gcc/pic32mx/4.5.2/plugin/include/config/pic32/mchp.h | biomurph/chipKIT-core-prebuilt | mit | 47,712 | 1,152 | codeparrot/github-code |
78210748905e0bd4ad3e80236b6bf554a20984680d303ebdce4f0d99ff9fbd8d | /**
* Lawnchair!
* ---
* clientside json store
*
*/
var Lawnchair = function () {
// lawnchair requires json
if (!JSON) throw 'JSON unavailable! Include http://www.json.org/json2.js to fix.'
// options are optional; callback is not
if (arguments.length <= 2 && arguments.length > 0) {
var... | JavaScript | test/lib/lawnchair.js | d2s/lawnchair | mit | 10,887 | 323 | codeparrot/github-code |
985f6ec047e241beabbebab10274ea22b22d4cd087e8d77fb72a54bda6ca3366 | module Hanami
module Utils
# HTML escape utilities
#
# Based on OWASP research and OWASP ESAPI code
#
# @since 0.4.0
#
# @see https://www.owasp.org
# @see https://www.owasp.org/index.php/Cross-site_Scripting_%28XSS%29
# @see https://www.owasp.org/index.php/XSS_(Cross_Site_Scripting... | Ruby | lib/hanami/utils/escape.rb | vyper/utils | mit | 23,390 | 578 | codeparrot/github-code |
43b14a9939ab01e22389abb48b8147395f2b8cca5d0898dc4e5823fb83261e25 | /**
* drcProcess
* Created by dcorns on 1/2/15.
*/
'use strict';
var RunApp = require('./runApp');
var Server = require('./server');
var parseInput = require('./parseInput');
var CommandList = require('./commandList');
var runApp = new RunApp();
var cmds = new CommandList();
cmds.add(['ls', 'pwd', 'service', 'ps']);... | JavaScript | drcProcess.js | dcorns/processThis | mit | 1,200 | 39 | codeparrot/github-code |
4a9a1e92380d891e3a841305c9559aa7280660c0307e9eba80c2bf1acb7ad603 | /*****************************************************************************
The following code is derived, directly or indirectly, from the SystemC
source code Copyright (c) 1996-2006 by all Contributors.
All Rights reserved.
The contents of this file are subject to the restrictions and limitations
... | C | metamorphosys/tonka/models/SystemC/systemc-2.3.0/examples/sysc/simple_bus/simple_bus_request.h | pombredanne/metamorphosys-desktop | mit | 2,323 | 75 | codeparrot/github-code |
68a0d2884dc12343500bf66d0198a4aeb75e0613df54f48e865a5a462fddf83c | using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using gView.Framework.Data;
using gView.Framework.Offline;
namespace gView.Framework.Offline.UI
{
public partial class FormAddReplicationID : Form,IFe... | C# | gView.Offline.UI/Framework/Offline/UI/FormAddReplicationID.cs | jugstalt/gViewGisOS | mit | 3,179 | 103 | codeparrot/github-code |
8d471972005e10f9a9047e70aacb335203b7038f3dde5b93e2aab81b16ffb2d2 | 'use strict';
module.exports = Source;
const inherits = require('util').inherits;
const Stream = require('../stream');
const Chunk = require('../chunk');
const Compose = require('../through/compose');
const Break = require('../through/break');
const Filter = require('../through/filter');
const Map = require('../throu... | JavaScript | src/source/source.js | shishidosoichiro/lazy | mit | 1,283 | 48 | codeparrot/github-code |
328a38ba1d242cc5049904a868fee97e27bcc2da4c30a30b5d816880815760d6 | using System;
using System.Linq;
using System.Net.Http;
using System.Net.Http.Json;
using System.Threading.Tasks;
using Microsoft.Extensions.Logging;
using Models;
namespace Services
{
public interface IArticlesService
{
Task<Section[]> GetSections();
Task<Section> GetSection(string sectionRe... | C# | web/Services/ArticlesService.cs | Rammesses/5coy-archive | mit | 4,134 | 129 | codeparrot/github-code |
90e1314c3bf24a82876a46967b7573f9fd7933e209196c3ffc06f458b79fccb9 | <?php
class itemModel extends CI_Model
{
public function insertItem()
{
$itemName = $this->input->post('itemName');
$this->db->where('item_name',$itemName);
$result=$this->db->get('shop_item');
if($result->num_rows()>0) {
$this->session->set_flashdata('Error','Ite... | PHP | Ishop 10.12.2017/Ishop/application/models/itemModel.php | WeerakoonOS/iShop | mit | 3,245 | 108 | codeparrot/github-code |
df11f66a228a463c98d7159eb8d3522a8539d85f450c8e47893b4d3f3bbd6a8d | // Idea and initial code from https://github.com/aomra015/ember-cli-chart
import Ember from 'ember';
export default Ember.Component.extend({
tagName: 'canvas',
attributeBindings: ['width', 'height'],
onlyValues: false,
chartData: {},
didInsertElement: function(){
var context = this.get('element').getCo... | JavaScript | ui/app/components/ember-chart.js | snowman-io/snowman-io | mit | 3,145 | 112 | codeparrot/github-code |
62953b81f2fd10c0c358fff5ccdead158cc1f9f64d9c3d07c6dbd8a20d387c08 | /**
* This module defines the `tslint-json` project task.
*
* @module project-tasks/tslint-json
* @internal
*/
/** (Placeholder comment, see TypeStrong/typedoc#603) */
import { Furi, join as furiJoin } from "furi";
import Undertaker from "undertaker";
import { DEFAULT_UNTYPED_TSLINT_CONFIG } from "../options/tsl... | TypeScript | src/lib/project-tasks/tslint-json.ts | demurgos/web-build-tools | mit | 1,210 | 40 | codeparrot/github-code |
8b374579439824f6853ccb5da8e9c96edac25132cc32214192b3185bc45483d1 | #include "ParticleData.h"
#include <algorithm>
#include <cassert>
namespace {
template<typename T>
void ResizeVector(T& obj, size_t size) {
obj.clear();
obj.resize(size);
obj.shrink_to_fit();
}
template<typename T>
size_t STLMemory(T& obj) {
using Type = typename T::value_type;
return obj.capacity() * sizeof(T... | C++ | src/ParticleData.cpp | jedarnaude/particles | mit | 1,572 | 78 | codeparrot/github-code |
9ab11987492cd0cc6d606de1fa67ec37abbf2e016762522755f72ffccf43b968 | import { autoBindMethodsForReact } from 'class-autobind-decorator';
import { HotKeyRegistry } from 'insomnia-common';
import React, { PureComponent } from 'react';
import { AUTOBIND_CFG, DEBOUNCE_MILLIS, SortOrder } from '../../../common/constants';
import { hotKeyRefs } from '../../../common/hotkeys';
import { execut... | TypeScript | packages/insomnia-app/app/ui/components/sidebar/sidebar-filter.tsx | getinsomnia/insomnia | mit | 2,804 | 94 | codeparrot/github-code |
4da5e4b2f7429e81f5416b163d772526b6d04412853151c0d0c150f4b530f034 | // Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See LICENSE in the project root for license information.
using Microsoft.MixedReality.Toolkit.Utilities.Editor;
using System.Collections.Generic;
using System.Linq;
using UnityEditor;
using UnityEngine;
namespace Microsof... | C# | Assets/MRTK/SDK/Inspectors/Input/Handlers/SpeechInputHandlerInspector.cs | SystemFriend/HoloLensUnityChan | mit | 10,109 | 223 | codeparrot/github-code |
d26af5c78361ef2e1f8f1493a46d168a145b4ae30b900957b42ed5a438c6445f | /*!
@file stddebug_windows_ntddk.c
@abstract Common debugging utilities
@copyright (c) 1997-2017 by Matt Slot <mattslot@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 wi... | C | stddebug_windows_ntddk.c | mattslot/stddebug | mit | 6,294 | 262 | codeparrot/github-code |
477ef8f52b002b564071a5a892df3f26e4cbaf7659c2b1d3338ba044ee2085a4 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
#if NETFX_CORE
using Windows.UI.Xaml.Data;
using Windows.UI.Xaml;
using Windows.UI.Xaml.Controls;
using Windows.UI;
using Windows.UI.Xaml.Media;
#else
using System.Windows;
using System.Windows.Data;
... | C# | TestApplication.Shared/Controls/StringToBrushConverter.cs | xinjiguaike/pomodoro-keeper | mit | 2,565 | 94 | codeparrot/github-code |
18d09627476aae1fda8de0b8e4e4511a54cbefee5ebff65ccff8e0595e968fd0 | {% extends "base.html" %}
{% set active_page = "admin" %}
{% block title %}Edit Schedules - BearStatus{{title}} {% endblock %}
{% block head %}
{{ super() }}
{% endblock %}
{% block content %}
<div id="content">
<div class="container">
{% if is_special == True %}
<div class="alert alert-danger" role="alert"... | HTML | view/templating/edit.html | shickey/BearStatus | mit | 1,883 | 52 | codeparrot/github-code |
9f1da4550d8d7b6cd48f379e8537318a80ea3db2757d545c6dbb6bc4bf57bd9b |
<!doctype html>
<!--#if expr="$HTTP_COOKIE=/fonts\-loaded\=true/" -->
<html lang="en-GB" class="fonts-loaded">
<!--#else -->
<html lang="en-GB">
<!--#endif -->
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0... | HTML | docs/docs/core/base.html | Jaywing/atomic | mit | 20,327 | 770 | codeparrot/github-code |
774a3f150a0d76e72b2f008d410bd4bc63d5118e93e51d61abe61fb8fb7f3d8f | 'use strict';
/**
* Email.js service
*
* @description: A set of functions similar to controller's actions to avoid code duplication.
*/
const _ = require('lodash');
const sendmail = require('sendmail')({
silent: true
});
module.exports = {
send: (options, cb) => {
return new Promise((resolve, reject) => ... | JavaScript | jekyll-strapi-tutorial/api/plugins/email/services/Email.js | strapi/strapi-examples | mit | 1,088 | 42 | codeparrot/github-code |
5997d6670a5de2368bbca5077ad299a1bc4e7d4cd3ad70b10bf53bb41256053c | package se.sciion.quake2d.level;
import java.io.File;
import com.badlogic.gdx.files.FileHandle;
import com.badlogic.gdx.utils.ObjectMap;
import se.sciion.quake2d.ai.behaviour.BehaviourTree;
import se.sciion.quake2d.level.items.Weapon;
public class Statistics {
private ObjectMap<BehaviourTree,Float> totalDamageG... | Java | core/src/se/sciion/quake2d/level/Statistics.java | sci10n/Quake2D | mit | 4,664 | 154 | codeparrot/github-code |
46ff2bdd7bd994ac1301809574c8bfa790b77b5fb06d1e25d4465954cc9711cc | {template '_header'}
{template 'diypage/_common'}
<div class="page-heading">
<span class='pull-right' style="padding: 15px 10px;">
<strong>左侧跟随</strong>
<input class="js-switch small" id="phoneposition" type="checkbox" value="1" checked />
</span>
<h2>{if !empty($menu)}编辑{else}新建{/if}自定义菜单 {if... | HTML | addons/ewei_shopv2/plugin/diypage/template/web/menu/post.html | Broomspun/shanque | mit | 2,383 | 68 | codeparrot/github-code |
c7478c260b1a8d3f5c82d1541d1e0067113fabc0a2e3afedb553109255802655 | from functools import reduce
# constants used in the multGF2 function
mask1 = mask2 = polyred = None
def setGF2(degree, irPoly):
"""Define parameters of binary finite field GF(2^m)/g(x)
- degree: extension degree of binary field
- irPoly: coefficients of irreducible polynomial g(x)
"""
def i... | Python | calc.py | srijs/hwsl2-core | mit | 1,141 | 39 | codeparrot/github-code |
4b5822ab847a1a1c5155b38682b0cf26839df0fa1aa5754c5863302eb30344d8 | 'use strict';
import React from 'react';
import {BootstrapTable, TableHeaderColumn} from 'react-bootstrap-table';
var products = [];
function addProducts(quantity) {
var startId = products.length;
for (var i = 0; i < quantity; i++) {
var id = startId + i;
products.push({
id: id,
name: "Item n... | JavaScript | examples/js/sort/sort-table.js | opensourcegeek/react-bootstrap-table | mit | 1,308 | 48 | codeparrot/github-code |
deb57c7d61f42ca1912e52099bc84bd94d39e50054abba7aa6bafc7ce2081e3e | ////////////////////////////////////////////////////////////////////////////////////
////// Events
////////////////////////////////////////////////////////////////////////////////////
'use strict';
// DI
var db,
responseHandler;
/**
*
* @param req the HTTP requests, contains header and body parameters
* @param re... | JavaScript | controllers/events.js | Gitification/gitification-server | mit | 2,351 | 81 | codeparrot/github-code |
86b1bf773a5ee81356860f4155c804c9b91eff71cfb0548164fcd11c98d88d51 | 'use strict';
const path = require('path');
const request = require('supertest');
const pedding = require('pedding');
const assert = require('assert');
const sleep = require('ko-sleep');
const mm = require('..');
const fixtures = path.join(__dirname, 'fixtures');
const baseDir = path.join(fixtures, 'app-event');
desc... | JavaScript | test/app_event.test.js | eggjs/egg-mock | mit | 2,448 | 106 | codeparrot/github-code |
ca56f11105736a7403fd83700ac519af8bbe39071a549a593244d3d0b4e607bd | var gulp = require('gulp');
var connect = require('gulp-connect');
var uglify = require('gulp-uglify');
var concat = require('gulp-concat');
var opn = require('opn');
var config = {
rootDir: '.',
servingPort: 8080,
servingDir: './dist',
paths: {
src: {
scripts: './src/**/*.js',
styles: './src/*... | JavaScript | gulpfile.js | codehangar/agenda-codehangar | mit | 1,188 | 56 | codeparrot/github-code |
09eac196ec7a764115861e7d6865e99dcb2252cced2e110c74b333adaae2e82d | <!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>hardware: Not compatible 👼</title>
<link rel="shortcut icon" type="image/png" href="../../../../../favicon.png" />
<link href="../../../../../bootstrap.min.cs... | HTML | clean/Linux-x86_64-4.11.2-2.0.7/released/8.12.0/hardware/8.7.0.html | coq-bench/coq-bench.github.io | mit | 7,080 | 168 | codeparrot/github-code |
55309759c2c86aeaf44ccc148db2ed14931dd971bca9f4a7a22d31ac187879d4 | <!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>ceramist: 2 h 5 m 🏆</title>
<link rel="shortcut icon" type="image/png" href="../../../../../favicon.png" />
<link href="../../../../../bootstrap.min.css" rel=... | HTML | clean/Linux-x86_64-4.06.1-2.0.5/extra-dev/8.10.dev/ceramist/1.0.0.html | coq-bench/coq-bench.github.io | mit | 15,509 | 240 | codeparrot/github-code |
8ec6aaa3a08699b96d0d81b965a10124961b3d9d39deec4899313ac59e2ae8d5 | <!DOCTYPE html>
<html lang="ko">
<head>
<meta charset="utf-8">
<title>io.js 주간 뉴스 2015년 3월 27일 | Node.js 한국 커뮤니티</title>
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
<meta name="description" content="io.js 1.6.2 릴리스 이번 주에는 v1.6.2 릴리스가 있었습니다. GitHub에서 전체 변경사항을 볼 수 있습니... | HTML | weekly/2015/03/27/weekly/index.html | nodejs/iojs-ko | mit | 13,300 | 278 | codeparrot/github-code |
90d7c2a0028ef344946edd221b0fd1c0cfabaaa50db251ea9692651ea963d0cc | import React from 'react'
import {Observable} from 'rx'
import {TextField} from 'material-ui'
import ThemeManager from 'material-ui/lib/styles/theme-manager';
import MyRawTheme from '../components/Theme.js';
import ThemeDecorator from 'material-ui/lib/styles/theme-decorator';
import {compose} from 'recompose'
import... | JavaScript | client/components/Search.js | dralletje/Tonlist | mit | 2,791 | 95 | codeparrot/github-code |
50ea4ac618fb827f399c932bcd277d8bdfc92c914d1a5960613c4efa21ea552b | (function(ns) {
/**
* JSON CORS utility
* Wraps up all the cors stuff into a simple post or get. Falls back to jsonp
*/
var JSONCORS = function() {
var self = this;
var supportsCORS = ('withCredentials' in new XMLHttpRequest()) || (typeof XDomainRequest != 'undefined');
/**********************************... | JavaScript | stacktodo/api/core/jsoncors.js | stacktodo/stacktodo_js_api | mit | 6,394 | 189 | codeparrot/github-code |
1eac09b3359e63cf49f855d103b5b490c55a067af6caf618bd0c3865274cc048 | package fr.inria.jessy.transaction.termination.vote;
import java.io.Externalizable;
import java.io.IOException;
import java.io.ObjectInput;
import java.io.ObjectOutput;
import fr.inria.jessy.ConstantPool;
/**
*
* @author Masoud Saeida Ardekani
*
*/
public class VotePiggyback implements Externalizable {
privat... | Java | src/fr/inria/jessy/transaction/termination/vote/VotePiggyback.java | EvilMcJerkface/jessy | mit | 817 | 44 | codeparrot/github-code |
6483c4a8c75a4eedda76cc9edb696f15e975258ec549cf6b6ef70a424bfed046 | require "active_support/core_ext/date/calculations"
require "active_support/core_ext/numeric/time"
require "active_support/core_ext/object/try"
require "google/api_client"
require "google/api_client/client_secrets"
require "ruboty"
require "time"
module Ruboty
module Handlers
class GoogleCalendar < Base
DE... | Ruby | lib/ruboty/handlers/google_calendar.rb | r7kamura/ruboty-google_calendar | mit | 4,793 | 172 | codeparrot/github-code |
dac870dfe5c0c59f367b59cad20c623dd4535cf13af5f865c73c4356908e98c3 | team1 = {"name" : "Iron Patriot",
"key": "MURICA",
"puzzles" :
[{"idPz": 0}, // Breakfast
{"idPz": 1}, // Blueprints, all
{"idPz": 2}, // Morning Rotation # 1
// {"idPz": 14}, // Morning Rotation # 1 Item! (to alieviate routing issues slightly)
{"idPz": 3}, // M... | JavaScript | backend/puzzles.js | sean9keenan/WordWeb | mit | 48,757 | 1,282 | codeparrot/github-code |
d05e4aea3cbce865af45eb3e8b18a9bf03112d44de216fb8a7c2c50493b551b3 | // Copyright (c) 2010 Satoshi Nakamoto
// Copyright (c) 2009-2012 The Bitcoin developers
// Distributed under the MIT/X11 software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "main.h"
#include "db.h"
#include "init.h"
#include "bitcoinrpc.h"
using name... | C++ | src/rpcmining.cpp | gfneto/colossus | mit | 18,531 | 498 | codeparrot/github-code |
306ad376f609023a86ef3dfe4f15a52bfafaca520f44625ffd89afa561c4113e | package com.asksunny.rpc.admin;
import java.util.concurrent.ExecutorService;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import com.asksunny.protocol.rpc.RPCAdminCommand;
import com.asksunny.protocol.rpc.RPCAdminEnvelope;
import com.asksunny.protocol.rpc.RPCEnvelope;
import com.asksunny.rpc.mtserver.RPC... | Java | src/main/java/com/asksunny/rpc/admin/AdminRPCRuntime.java | devsunny/mt-rpc-server | mit | 1,997 | 63 | codeparrot/github-code |
16f5cdb1063d1bfac2d6d5d3869efd75c4cce5e4cf9ea78843add390b30a4f5b | import DBService, { BuilderSingle } from '../DBService'
import Approval from '../../../models/extprod/Approval'
import { Map } from '../../../utils/map'
import { UndefinedError } from '../../../models/Error'
interface FindAllOptions {
userId?: string
}
export default class ApprovalService extends DBService<Approval... | TypeScript | src/services/db/extprod/ApprovalService.ts | Portgass/api-server | mit | 750 | 33 | codeparrot/github-code |
c15dee91da4f487aa5f51267c185fad256e21e380f63a3266947bbb934807325 | <?php
/*
|--------------------------------------------------------------------------
| Oculus XMS
|--------------------------------------------------------------------------
|
| This file is part of the Oculus XMS Framework package.
|
| (c) Vince Kronlein <vince@ocx.io>
|
| For the full copyright and license inf... | PHP | app/admin/model/sale/order.php | oculusxms/ocx | mit | 54,683 | 1,351 | codeparrot/github-code |
2137adaa8dea2e323aa4ae99ce5f74e9ede0245d4548b0be7053d09aa3933dc9 | import Off from './Off';
import On from './On';
// ==============================
// CONCRETE CONTEXT
// ==============================
export default class Computer {
constructor() {
this._currentState = null;
this._states = {
off: new Off(),
on: new On()
};
}
... | JavaScript | GoF/classic/Behavioral/State/ECMAScript/ES6/API/Computer.js | Badacadabra/PatternifyJS | mit | 579 | 33 | codeparrot/github-code |
c276cbdf99b776967a14417ddc03b23ce1c52ab53a6fa993924cab09f60e26ad | /*
* Functions used to build the ast
*/
#pragma once
#include "structures.h" /* TreeNode, NodeList and such*/
#include <stdio.h> /*printfs*/
#include <stdlib.h> /*mallocs et all*/
#include <string.h> /*strcmp*/
TreeNode* InitTreeNode(enum NodeType type);
NodeList* InitNodeList(TreeNode* node);
TreeNode* InsertTermin... | C | ast.h | Crushy/Compiladores2014 | mit | 1,565 | 35 | codeparrot/github-code |
2d9e1b9916fefb947f5399f7af314850b51066a7e127155678163f325fe1b0cf | <!DOCTYPE html>
<!--[if lt IE 7 ]><html class="ie ie6" lang="en"> <![endif]-->
<!--[if IE 7 ]><html class="ie ie7" lang="en"> <![endif]-->
<!--[if IE 8 ]><html class="ie ie8" lang="en"> <![endif]-->
<!--[if (gte IE 9)|!(IE)]><!-->
<html lang="en" xmlns="http://www.w3.org/1999/html"> <!--<![endif]-->
<head>
<!-- Basic... | HTML | bower_components/font-awesome/src/3.2.1/license/index.html | vmetayer/co-brand | mit | 11,722 | 262 | codeparrot/github-code |
2b096cafd4f63455eeb9473933836ab3885a1ac1cfd5e906ab1bbca5396cb915 | using System;
using System.Text.RegularExpressions;
using System.CodeDom.Compiler;
using System.IO;
using System.Reflection;
namespace Backend
{
/// <summary>
/// Operation compiler.
/// </summary>
public static class OperationCompiler
{
/// <summary>
/// Compiles a mathematical operation given by a string a... | C# | Code/Backend/OperationCompiler.cs | Onkeliroh/DSA | mit | 2,514 | 89 | codeparrot/github-code |
f79c1a63b04f54ea20e382b25aa862d8e280789d5d42b0d70c90aca44bafd9e0 | import UtilMath = require('./UtilMath');
import Timer = require('./Timer');
import Browser = require('./Browser');
import BaserElement = require('./BaserElement');
import AlignedBoxes = require('./AlignedBoxes');
import BackgroundContainer = require('./BackgroundContainer');
import Checkbox = require('./Checkbox');
imp... | TypeScript | src/Class/JQueryAdapter.ts | baserproject/baserjs | mit | 17,160 | 737 | codeparrot/github-code |
a0b423029e73665b95fa6d5e90f13b3636340df35bf50b66e3282f4a1699d20c | /*
* This file is part of Sponge, licensed under the MIT License (MIT).
*
* Copyright (c) SpongePowered <https://www.spongepowered.org>
* Copyright (c) contributors
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Softwar... | Java | src/main/java/org/spongepowered/common/registry/type/world/gen/BiomeTreeTypeRegistryModule.java | SpongePowered/SpongeCommon | mit | 5,058 | 103 | codeparrot/github-code |
6e89433e860a89232dae2181cb0f82680ee2ba56699e4b7f5c2198a3df82e3ce | var Nightmare = require('nightmare')
var NTU = require('./NightmareTestUtils')
const NounPhraseTest = (nightmare, delay) => {
return nightmare
// Can I open the addedit form and make it go away by clicking cancel?
.click('#add-np').wait(delay)
.click('#np-addedit-form #cancel').wait... | JavaScript | src/nightmare/NounPhraseTest.js | bostontrader/senmaker | mit | 2,952 | 74 | codeparrot/github-code |
d5ec3613985995059712822df4a4321390c8e43bfe73ec1afe4fae8be9e6e74f | <?php
namespace Soga\NominaBundle\Entity;
use Doctrine\ORM\Mapping as ORM;
/**
* @ORM\Table(name="trasladoeps")
* @ORM\Entity(repositoryClass="Soga\NominaBundle\Repository\TrasladoEpsRepository")
*/
class TrasladoEps
{
/**
* @ORM\Id
* @ORM\Column(name="id", type="integer")
*/
private $id; ... | PHP | src/Soga/NominaBundle/Entity/TrasladoEps.php | wariox3/soga | mit | 3,539 | 182 | codeparrot/github-code |
0fe7496fc0a21ae7a9f6dd4414c82bc73587a7be387d37bfc7a51c262cba78e9 | import { UIPanel, UIRow, UIHorizontalRule } from './libs/ui.js';
import { AddObjectCommand } from './commands/AddObjectCommand.js';
import { RemoveObjectCommand } from './commands/RemoveObjectCommand.js';
import { MultiCmdsCommand } from './commands/MultiCmdsCommand.js';
import { SetMaterialValueCommand } from './comm... | JavaScript | editor/js/Menubar.Edit.js | fraguada/three.js | mit | 5,225 | 274 | codeparrot/github-code |
778132bbae52c8539d7bc1f0b78ff7d572e5e0af87141bdda46e62652f6108fc | import './init'
import React from 'react'
import ReactDom from 'react-dom'
import Root from './root'
import {APP_THEMES_LIGHT, APP_THEMES_DARK} from 'reducers/settings/constants'
import LocalStorage from 'lib/localStorage'
import {initializeStore} from './redux/store'
import {initServiceWorker} from './swWindow'
// ren... | JavaScript | assets/app.js | le0pard/pgtune | mit | 1,045 | 40 | codeparrot/github-code |
f1bba2aac1242249e8f566e8763d06e0de28b8643a96a527c16964f93ef6b4c9 | /**
* @author Kai Salmen / www.kaisalmen.de
*/
'use strict';
if ( KSX.test.projectionspace === undefined ) KSX.test.projectionspace = {};
KSX.test.projectionspace.VerifyPP = (function () {
PPCheck.prototype = Object.create(KSX.core.ThreeJsApp.prototype, {
constructor: {
configurable: true,... | JavaScript | test/projectionspace/VerifyPP.js | kaisalmen/kaisalmen.de | mit | 2,021 | 73 | codeparrot/github-code |
37cc675f176548b103c39817381df3dc5b56f88ddcfa059b6d5ae2b9a1f78e1e | package com.avocarrot.adapters.sample.admob;
import android.content.Context;
import android.content.Intent;
import android.os.Bundle;
import android.support.annotation.NonNull;
import android.support.v7.app.ActionBar;
import android.support.v7.app.AppCompatActivity;
import android.text.TextUtils;
import android.view.V... | Java | avocarrot-app-sample/src/main/java/com/avocarrot/adapters/sample/admob/AdmobNativeActivity.java | Avocarrot/android-adapters | mit | 8,086 | 170 | codeparrot/github-code |
6db3b7ecc47abdc23acdb839dda83d913d8eb440520df5d5fa7e8a801b0daf1b |
//
// This source file is part of appleseed.
// Visit https://appleseedhq.net/ for additional information and resources.
//
// This software is released under the MIT license.
//
// Copyright (c) 2012-2013 Esteban Tovagliari, Jupiter Jazz Limited
// Copyright (c) 2014-2018 Esteban Tovagliari, The appleseedhq Organizat... | C++ | src/appleseed.python/bindscene.cpp | Biart95/appleseed | mit | 2,822 | 69 | codeparrot/github-code |
0dadeb01b73fd0118333b52e1e73f0c24a707e3f22a3a332f1c62424ad5cf90e | // Copyright (c) 2009-2010 Satoshi Nakamoto
// Copyright (c) 2009-2019 The Bitcoin Core developers
// Copyright (c) 2014-2019 The DigiByte Core developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include <wallet/db.h>
#... | C++ | src/wallet/db.cpp | digibyte/digibyte | mit | 29,494 | 803 | codeparrot/github-code |
e55c590b3b7a80fb4e8dd0ac96d0b2d9bf1c6bb7c8038a9f38813fa6c0eb069f | <?php
/**
* @link http://zoopcommerce.github.io/shard
* @package Zoop
* @license MIT
*/
namespace Zoop\Shard\Serializer\Reference;
use Zend\ServiceManager\ServiceLocatorAwareInterface;
use Zend\ServiceManager\ServiceLocatorAwareTrait;
/**
*
* @since 1.0
* @author Tim Roediger <superdweebie@gmail... | PHP | lib/Zoop/Shard/Serializer/Reference/Eager.php | zoopcommerce/shard | mit | 884 | 41 | codeparrot/github-code |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.