code stringlengths 3 1.05M | repo_name stringlengths 4 116 | path stringlengths 4 991 | language stringclasses 9
values | license stringclasses 15
values | size int32 3 1.05M |
|---|---|---|---|---|---|
import { Routes, RouterModule } from '@angular/router';
import { Grupos } from './grupos.component';
import { Ckeditor } from './components/ckeditor/ckeditor.component';
// noinspection TypeScriptValidateTypes
const routes: Routes = [
{
path: '',
component: Grupos,
children: [
{ path: 'ckeditor',... | Kmilo9433/arka-cliente-generador | src/app/pages/grupos/grupos.routing.ts | TypeScript | mit | 411 |
import 'pixi'
import 'p2'
import Phaser from 'phaser'
import BootState from './states/Boot'
import SplashState from './states/Splash'
import GameState from './states/Game'
import config from './config'
class Game extends Phaser.Game {
constructor () {
const docElement = document.documentElement
... | juergensen/a-little-game-2 | src/main.js | JavaScript | mit | 690 |
#include "Chapter7.h"
#include "Killable.h"
bool IKillable::IsDead()
{
return false;
}
void IKillable::Die()
{
GEngine->AddOnScreenDebugMessage(-1,1, FColor::Red,"Arrrgh");
AActor* Me = Cast<AActor>(this);
if (Me)
{
Me->Destroy();
}
} | sunithshetty/Unreal-Engine-4-Scripting-with-CPlusPlus-Cookbook | Chapter07/Source/Chapter7/Killable.cpp | C++ | mit | 245 |
import lazy from "lazy.js";
import { EventEmitter } from "events";
import _ from "lodash";
import AppDispatcher from "../AppDispatcher";
import GameStatus from "../constants/GameStatus";
import CompsEvents from "../events/CompsEvents";
import GamesEvents from "../events/GamesEvents";
class GameStore {
constructor()... | ruippeixotog/botwars | client/js/stores/GamesStore.js | JavaScript | mit | 3,892 |
<?php
namespace Cygnite\Base\EventHandler;
use Cygnite\Helpers\Inflector;
/**
* Class EventRegistrarTrait
*
* @package Cygnite\Base\EventHandler
*/
trait EventRegistrarTrait
{
/**
* @return $this
*/
public function boot()
{
$this->registerEvents($this->listen);
return $this;... | sanjoydesk/cygniteframework | vendor/cygnite/framework/src/Cygnite/Base/EventHandler/EventRegistrarTrait.php | PHP | mit | 1,849 |
/*
* @(#)ChoiceResource.java 1.3 97/06/27
*
* (C) Copyright Taligent, Inc. 1996 - All Rights Reserved
* (C) Copyright IBM Corp. 1996 - All Rights Reserved
*
* Portions copyright (c) 1996 Sun Microsystems, Inc. All Rights Reserved.
*
* The original version of this source code and documentation is copyrighted
... | pitpitman/GraduateWork | Java_tutorial/intl/datamgmt/demos-1dot1/ChoiceResource.java | Java | mit | 1,916 |
Template.sort.helpers({
activeRouteClass: function(/* route names */) { // Man kann natürlich benannte Argumente an die Funktion übergeben, aber man kann auch eine beliebige Anzahl von anonymen Parametern mitgeben und abrufen indem man innerhalb der Funktion das Objekt arguments aufruft.
var args = Array.prototyp... | shiftux/discover_meteor | client/templates/includes/sort.js | JavaScript | mit | 859 |
//ECS 60 Homework #2
//Christopher Bird
//ID: 997337048
//Professor: Hao Chen
//Kruskal's Implementation along with Sorting Algorithm
//Main.cpp
#include <string>
#include <iostream>
#include "spantree.h"
using namespace std;
int main()
{
spantree Spantree;
Spantree.readInput();
//Spantree.testInput();
//Reads ... | CKBird/Kruskals | Source/main.cpp | C++ | mit | 643 |
<?xml version="1.0" ?><!DOCTYPE TS><TS language="pt_PT" version="2.0">
<defaultcodec>UTF-8</defaultcodec>
<context>
<name>AboutDialog</name>
<message>
<location filename="../forms/aboutdialog.ui" line="+14"/>
<source>About PioneerCoin</source>
<translation>Sobre PioneerCoin</translation>... | pioneercrypto/PioneerCoin | src/qt/locale/bitcoin_pt_PT.ts | TypeScript | mit | 119,141 |
<?
class Welcome_model extends CI_Model{
function __construct(){
//Llamado al contructor del modelo
parent::__construct();
}
public function insertar_alumno($persona){
if ($this->db->insert('usu_al', $persona))
return true;
else
return false;
}
public function insertar_docente($persona){
if (... | GrinGraz/CIMVC | application/models/welcome_model.php | PHP | mit | 2,333 |
package br.com.splessons.configuration;
import java.util.Properties;
import javax.sql.DataSource;
import org.hibernate.SessionFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan;
import... | marcellorego/SpringLabs | lesson4/src/main/java/br/com/splessons/configuration/HibernateConfiguration.java | Java | mit | 3,156 |
declare const foo: string;
export default foo;
| typings/core | src/lib/__test__/fixtures/compile-export-default/index.d.ts | TypeScript | mit | 48 |
#coding: utf-8
require 'test_helper'
class CoreExtTest < ActiveSupport::TestCase
test "str.encode_emoji" do
assert_equal "test string", "test string".encode_emoji
assert_equal "{{260e}}️", "☎️".encode_emoji
assert_equal "{{1f4f1}}", "📱".encode_emoji
end
test "str.decode_emoji" do
assert_equal "... | phonezawphyo/monkey_emoji | test/core_ext_test.rb | Ruby | mit | 633 |
using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.ServiceModel;
using System.Text;
namespace BetterWords
{
[ServiceContract]
public interface IWordService
{
[OperationContract]
string LoadData();
[OperationContract]... | amughni/SpellChecker | BetterWords/BetterWords/IWordService.cs | C# | mit | 369 |
# Requires
require "Core/CDImage"
# An implementation for CDImage For RHEL
module PackerFiles
module RHEL
class CD < Core::CDImageImpl
# Override method for getting the ISO name
def get_iso_name_pattern
'rhel-server-@release@-@arch@-dvd.iso'
end
# Override method for getting chec... | anandvenkatanarayanan/PackerFiles | lib/PackerFiles/OS/RHEL/CD.rb | Ruby | mit | 670 |
# encoding: utf-8
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
module Azure::Compute::Mgmt::V2016_04_30_preview
module Models
#
# The List Usages operation response.
#
class ListUsagesResult
inc... | Azure/azure-sdk-for-ruby | management/azure_mgmt_compute/lib/2016-04-30-preview/generated/azure_mgmt_compute/models/list_usages_result.rb | Ruby | mit | 2,848 |
# encoding: utf-8
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
module Azure::Network::Mgmt::V2016_09_01
module Models
#
# Information gained from troubleshooting of specified resource.
#
class Troubles... | Azure/azure-sdk-for-ruby | management/azure_mgmt_network/lib/2016-09-01/generated/azure_mgmt_network/models/troubleshooting_details.rb | Ruby | mit | 2,956 |
# encoding: utf-8
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
module Azure::Network::Mgmt::V2019_02_01
module Models
#
# Application gateway backendhealth http settings.
#
class ApplicationGatewayBack... | Azure/azure-sdk-for-ruby | management/azure_mgmt_network/lib/2019-02-01/generated/azure_mgmt_network/models/application_gateway_backend_health_server.rb | Ruby | mit | 2,482 |
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html;charset=UTF-8" />
<meta charset="utf-8" />
<title>Pages - Petugas Dashboard UI Kit</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />
<link rel="apple... | Vancrew/IMK | application/views/template/header_umum.php | PHP | mit | 9,330 |
define(function(require) {
var _ = require('underscore'),
d3 = require('d3');
function isTime(type) {
return _.contains(['time', 'timestamp', 'date'], type);
}
function isNum(type) {
return _.contains(['num', 'int4', 'int', 'int8', 'float8', 'float', 'bigint'], type);
}
function isStr(type) {
... | sirrice/dbwipes | dbwipes/static/js/summary/util.js | JavaScript | mit | 6,474 |
Package.describe({
name: 'angular-compilers',
version: '0.4.0',
summary: 'Rollup, AOT, SCSS, HTML and TypeScript compilers for Angular Meteor',
git: 'https://github.com/Urigo/angular-meteor/tree/master/atmosphere-packages/angular-compilers',
documentation: 'README.md'
});
Package.registerBuildPlugin(... | Urigo/angular-meteor | atmosphere-packages/angular-compilers/package.js | JavaScript | mit | 780 |
using CharacterGen.CharacterClasses;
using CharacterGen.Domain.Tables;
using CharacterGen.Races;
using NUnit.Framework;
namespace CharacterGen.Tests.Integration.Tables.Races.BaseRaces.Ages.Rolls
{
[TestFixture]
public class IntuitiveAgeRollsTests : CollectionTests
{
protected override string table... | DnDGen/CharacterGen | CharacterGen.Tests.Integration.Tables/Races/BaseRaces/Ages/Rolls/IntuitiveAgeRollsTests.cs | C# | mit | 5,191 |
namespace WithFormat.DateTime
{
public interface IYearFormatter
{
DateTimeFormatBuilder WithOneDigit();
DateTimeFormatBuilder WithTwoDigits();
DateTimeFormatBuilder WithAtLeastThreeDigits();
DateTimeFormatBuilder WithFourDigits();
DateTimeFormatBuilder WithFiveDi... | TheCrow1213/WithFormat | WithFormat/DateTime/IYearFormatter.cs | C# | mit | 394 |
<?php
namespace Backend\Modules\Kwaliteitslabels\Ajax;
use Backend\Core\Engine\Base\AjaxAction;
use Backend\Modules\Kwaliteitslabels\Engine\Model as BackendKwaliteitslabelsModel;
/**
* Alters the sequence of Kwaliteitslabels articles
*
* @author Stijn Schets <stijn@schetss.be>
*/
class SequenceCategories extends... | Schetss/CarCor | src/Backend/Modules/Kwaliteitslabels/Ajax/SequenceCategories.php | PHP | mit | 1,047 |
using Tweetinvi.Core.Controllers;
using Tweetinvi.Core.Iterators;
using Tweetinvi.Core.Web;
using Tweetinvi.Models;
using Tweetinvi.Models.DTO;
using Tweetinvi.Parameters;
namespace Tweetinvi.Controllers.Timeline
{
public class TimelineController : ITimelineController
{
private readonly ITimelineQuery... | linvi/tweetinvi | src/Tweetinvi.Controllers/Timeline/TimelineController.cs | C# | mit | 3,067 |
class DashboardController < ApplicationController
respond_to :html
def index
@groups = Group.where(id: current_user.projects.pluck(:group_id))
@projects = current_user.projects_with_events
@projects = @projects.page(params[:page]).per(20)
@events = Event.in_projects(current_user.project_ids).limit... | robbkidd/gitlabhq | app/controllers/dashboard_controller.rb | Ruby | mit | 1,079 |
#include <iostream>
#include <vector>
#include <string>
#include <sstream>
#include <set>
#include <algorithm>
//std::vector<std::string> parseCommand(std::string input);
//std::vector<int> parseArray(std::string input);
//void exchange(int index, std::vector<int> & numbers);
//void printNumbersInArrayFormat(std::vec... | M-Yankov/CPlusPlus | 10.ExamPreparation/ArrayManipulator11October2015/Source.cpp | C++ | mit | 6,155 |
using NUnit.Framework;
namespace UsStateMapper.Tests.EndToEndTests {
[TestFixture]
public class UscgCodeInputTest {
private StateMapper subject;
[SetUp]
public void SetUp() {
subject = new StateMapper();
}
[TestCase("HA", "Hawaii")]
[TestCase("KA", "Kansas")]
[TestCase("MC", "M... | asciamanna/UsStateMapper | UsStateMapper.Tests/EndToEndTests/UscgCodeInputTest.cs | C# | mit | 745 |
var $ = require('jquery');
var layout = module.exports = {
init: function() {
$('#toggle-sidebar').click(function(e) {
e.preventDefault();
layout.sidebar();
});
$('#toggle-overlay').click(function(e) {
e.preventDefault();
layout.overlay();
});
},
restore: function() {... | joje6/three-cats | www/js/layout.js | JavaScript | mit | 1,624 |
// ***********************************************************************
// Copyright (c) 2017 Charlie Poole, Rob Prouse
//
// 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 restri... | jadarnel27/nunit | src/NUnitFramework/framework/Internal/InvalidPlatformException.cs | C# | mit | 2,741 |
package com.nodlee.theogony.ui.adapter;
import android.view.View;
public interface ItemClickedListener {
/**
* 在单元格被点击的时候调用
*
* @param position
*/
void onItemClicked(View view, int position);
} | VernonLee/Theogony | app/src/main/java/com/nodlee/theogony/ui/adapter/ItemClickedListener.java | Java | mit | 247 |
<?php
/**
* TOP API: taobao.media.file.delete request
*
* @author auto create
* @since 1.0, 2014-09-13 16:51:05
*/
class MediaFileDeleteRequest
{
/**
* 接入多媒体平台的业务code 每个应用有一个特有的业务code
**/
private $bizCode;
/**
* 文件ID字符串,可以一个也可以一组,用英文逗号间隔,如450,120,155
**/
private $fileIds;
private $apiParas = ar... | zhangbobell/mallshop | plugins/onekey/taobao/top/request/MediaFileDeleteRequest.php | PHP | mit | 1,256 |
<div class="content">
<h2><?php echo $title;?></h2>
<div class="panel panel-default">
<div class="panel-heading">
<b>The following is the list of various seed certification charges of Punjab State Certification Authorityu as applicable from Rabi-2004-05</b>
</div>
<div class="panel-body text-left">
<tabl... | puneetarora2000/BiS-conformance- | application/views/front/fees.php | PHP | mit | 3,364 |
package com.wt.studio.plugin.pagedesigner.gef.figure;
import org.eclipse.draw2d.ColorConstants;
import org.eclipse.draw2d.FrameBorder;
import org.eclipse.draw2d.Graphics;
import org.eclipse.draw2d.IFigure;
import org.eclipse.draw2d.PositionConstants;
import org.eclipse.draw2d.SchemeBorder;
import org.eclipse.draw2d.Ti... | winture/wt-studio | com.wt.studio.plugin.modeldesigner/src/com/wt/studio/plugin/pagedesigner/gef/figure/FormFrameBorder.java | Java | mit | 1,556 |
namespace Deldysoft.Foundation.CommandHandling
{
public interface ICommandExecuter
{
void Execute<T>(T command);
}
} | geekhubdk/geekhub | Deldysoft.Foundation/CommandHandling/ICommandExecuter.cs | C# | mit | 139 |
require 'spec_helper'
require 'rddd/authorization/rule'
describe Rddd::Authorization::Rule do
let(:action) { :foo }
let(:block) { lambda { |user, params| true } }
let(:authorize) do
Rddd::Authorization::Rule.new(
action, &block
)
end
describe 'should raise if rule block is invalid' do
l... | petrjanda/rddd | spec/lib/authorization/rule_spec.rb | Ruby | mit | 1,195 |
import os,sys
#import ez_setup
#ez_setup.use_setuptools()
from setuptools import setup, find_packages
import numpy
from Cython.Build import cythonize
# not compatible with distribute
#from distutils.extension import Extension
#from Cython.Distutils import build_ext
version = '0.7.0'
README = os.path.join(os.path.di... | mizuy/seqtool | setup.py | Python | mit | 2,123 |
using System;
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Globalization;
using System.Linq;
using System.Linq.Expressions;
using System.Reflection;
namespace Abc.Zebus.Routing
{
public class BindingKeyPredicateBuilder : IBindingKeyPredicateBuilder
{
private stat... | biarne-a/Zebus | src/Abc.Zebus/Routing/BindingKeyPredicateBuilder.cs | C# | mit | 4,768 |
var a = createElement("a");
attr(a, 'href', "");
function anchor(label, href) {
var element = createElement(a);
attr(element, "href", label);
if (isString(label)) {
text(element, label);
} else {
appendChild(element, label);
}
onclick(element, function (event) {
if (/^\w+... | yunxu1019/efront | coms/zimoli/anchor.js | JavaScript | mit | 423 |
'use strict';
/**
* Module Dependencies
*/
var config = require('../config/config');
var _ = require('lodash');
var Twit = require('twit');
var async = require('async');
var debug = require('debug')('skeleton'); // https://github.com/visionmedia/debug
var graph ... | justyn-clark/mylockedemo | controllers/api.js | JavaScript | mit | 15,388 |
range.collapse(true); // collapse to the starting point
console.log(range.collapsed); // outputs "true"
| msfrisbie/pjwd-src | Chapter16DOMLevels2And3/Ranges/CollapsingADOMRange/CollapsingADOMRangeExample01.js | JavaScript | mit | 108 |
<?php
/**
* TL_ROOT/system/modules/videobox_vimeo/languages/lv/tl_videobox_settings.php
*
* Contao extension: videobox_vimeo 1.0.1 stable
* Latvian translation file
*
* Copyright : David Enke 2010
* License : GNU/GPL
* Author : David Enke (david.enke), www.davidenke.de
* Translator: Maris Celmins ... | TechnoGate/contao_template | contao/videobox_vimeo/system/modules/videobox_vimeo/languages/lv/tl_videobox_settings.php | PHP | mit | 2,269 |
Rails.application.configure do
# Settings specified here will take precedence over those in config/application.rb.
# Code is not reloaded between requests.
config.cache_classes = true
# Eager load code on boot. This eager loads most of Rails and
# your application in memory, allowing both threaded web serve... | mbostler/blog5 | config/environments/production.rb | Ruby | mit | 4,041 |
<?php
class Brandedcrate_Payjunction_Model_Result extends Varien_Object
{
}
| brandedcrate/payjunction-magento | app/code/community/Brandedcrate/Payjunction/Model/Result.php | PHP | mit | 82 |
// Generated by typings
// Source: https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/80060c94ef549c077a011977c2b5461bd0fd8947/strftime/index.d.ts
declare module "strftime" {
type strftimeFunction = (format: string, date?: Date) => string;
namespace strftime {
/**
* Sets locale.... | liqu0/KentChat | src/server/typings/globals/strftime/index.d.ts | TypeScript | mit | 2,057 |
var Sequelize = require('sequelize');
var sequelize = require('./db.js').Sequelize;
var UserRooms = sequelize.define('UserRooms', {
}, {
updatedAt: false,
createdAt: false
});
module.exports = UserRooms;
| nokia-wroclaw/innovativeproject-meetinghelper | server/NodeTest/models/userRoom.js | JavaScript | mit | 236 |
(function(S, $) {
var dom = S.Dom;
var sharedUserAdmin = new Spontaneous.MetaView.UserAdmin();
var RootMenuView = new JS.Class(S.PopoverView, {
initialize: function(afterCloseCallback) {
this.afterCloseCallback = afterCloseCallback;
this.callSuper();
},
width: function() {
return 250;
},
title: fu... | magnetised/spontaneous | application/js/panel/root_menu.js | JavaScript | mit | 1,921 |
using System;
using System.Collections.Generic;
using System.Data.Entity;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using UiuCanteen.Domain.Entities;
namespace UiuCanteen.Domain.Concrete
{
public class EFDbContext : DbContext
{
public DbSet<Product> Products { get; set; }
... | rasel01/Project-1-Online-Cafeteria- | source/UiuCanteen/UiuCanteen.Domain/Concrete/EFDbContext.cs | C# | mit | 377 |
const renderToString = require('rogain-render-string');
const html = require('html').prettyPrint;
const config = require('./render.config.js');
const data = require('./fixtures/data.json');
var output = renderToString(config.components.get('Template'), data, config);
console.log(html(output, { unformatted: [] })); | krambuhl/rogain | test/render.test.js | JavaScript | mit | 318 |
module.exports = function(planetsData) {
planetsData.createPlanet("Earth")
.then((planet) => {
console.log("Created new Planet");
console.log(planet);
})
.catch(() => {
console.log("Error");
console.dir(err, { colors: true });
});
} | shopOFF/TelerikAcademyCourses | Web-Applications-with-Node.js/NodeJs-Homeworks & Exams/nodeJSWorkshop/controllers/planets-controller.js | JavaScript | mit | 316 |
// Copyright (c) 2014 Greenheart Games Pty. Ltd. All rights reserved.
// Use of this source code is governed by the MIT license that can be
// found in the LICENSE file.
#include "greenworks_workshop_workers.h"
#include <algorithm>
#include "nan.h"
#include "steam/steam_api.h"
#include "v8.h"
#include "greenworks_u... | greenheartgames/greenworks | src/greenworks_workshop_workers.cc | C++ | mit | 20,261 |
class Camera {
static init() {
this.position = vec3.fromValues(-Terrain.tiles.length/2, -Terrain.tiles[0].length/2, -1 * slider_zoom.value);
this.rotation = vec3.fromValues(0, 0, 0);
}
static getViewMatrix() {
var q = quat.create();
quat.rotateX(q, q, this.rotation[0]);
qu... | Pilex1/Pilex1.github.io | Projects/Wireworld/camera.js | JavaScript | mit | 562 |
/**
* Keyboard event keyCodes have proven to be really unreliable.
* This util function will cover most of the edge cases where
* String.fromCharCode() doesn't work.
*/
const _toAscii = {
188: '44',
109: '45',
190: '46',
191: '47',
192: '96',
220: '92',
222: '39',
221: '93',
219: '91',
173: '45... | derrickpelletier/hyper | lib/utils/key-code.js | JavaScript | mit | 1,367 |
/**
* result Module
*
* Description
*/
angular
.module('result')
.directive('navBar', navBar);
navBar.$inject = ['loginService', '$log', '$location'];
function navBar(loginService, $log, $location) {
return {
restrict: 'A',
link: function(scope, element, attrs, controller) {
loginService.user()
.success(... | techhahn/Result-Analyzer | public/packages/app/directives/app.navigationbarDirective.js | JavaScript | mit | 969 |
<?php defined('BX_DOL') or die('hack attempt');
/**
* Copyright (c) UNA, Inc - https://una.io
* MIT License - https://opensource.org/licenses/MIT
*
* @defgroup UnaCore UNA Core
* @{
*/
/**
* Message constants passed to _t_ext() function by checkAction()
*
* NOTE: checkAction() returns language dependent me... | unaio/una | inc/classes/BxDolAcl.php | PHP | mit | 35,178 |
import React, { PureComponent } from 'react';
import PropTypes from 'prop-types';
import { ViewPropTypes, Text, View } from 'react-native';
import Icon from 'react-native-vector-icons/MaterialCommunityIcons';
import getStyles from './styles';
export default class DefaultMarker extends PureComponent {
static propTyp... | joshjconlin/react-native-multi-slider-1 | DefaultMarker/index.js | JavaScript | mit | 1,946 |
///////////////////////////////////////////////////////////////////////////////
// Name: generic/vlbox.cpp
// Purpose: implementation of wxVListBox
// Author: Vadim Zeitlin
// Modified by:
// Created: 31.05.03
// RCS-ID: $Id: vlbox.cpp,v 1.22.2.1 2006/01/18 09:50:37 JS Exp $
// Copyright: (c)... | SickheadGames/Torsion | code/wxWidgets/src/generic/vlbox.cpp | C++ | mit | 18,240 |
// // Load the AWS SDK for Node.js
// var i = console.log(Math.round(new Date().getTime()/1000.0).toFixed(1));
// var AWS = require('aws-sdk');
// var path = require('path');
// var fs = require('fs');
//
// // Load credentials and set region from JSON file
// AWS.config.loadFromPath("/Users/jorge/Documents/javas... | PulseraMartin/docking_station | uploader/dynamoDBManager.js | JavaScript | mit | 1,405 |
<?php
namespace c2g\Base;
/**
* FoundationPile base class
*
* @author Thurairajah Thujeevan <thujee@gmail.com>
*/
class FoundationPile extends Pile {
const LIMIT = 13;
const NAME = 'Foundation';
/**
* data member of this class, which holds the base card
* when this pile is circular
... | thujeevan/c2g | src/Base/FoundationPile.php | PHP | mit | 3,047 |
using System;
class SayHello
{
static void Main()
{
string name = Console.ReadLine();
printName(name);
}
static void printName(string name)
{
Console.WriteLine("Hello, {0}!", name);
}
} | ndvalkov/TelerikAcademy2016 | Homework/CSharp-Part-2/03. Methods/SayHello.cs | C# | mit | 235 |
// Copyright (c) 2011-2013 The BeCoin Core developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "addresstablemodel.h"
#include "guiutil.h"
#include "walletmodel.h"
#include "base58.h"
#include "wallet/wallet.h"
... | MasterX1582/bitcoin-becoin | src/qt/addresstablemodel.cpp | C++ | mit | 14,351 |
import _plotly_utils.basevalidators
class BgcolorValidator(_plotly_utils.basevalidators.ColorValidator):
def __init__(self, plotly_name="bgcolor", parent_name="pie.hoverlabel", **kwargs):
super(BgcolorValidator, self).__init__(
plotly_name=plotly_name,
parent_name=parent_name,
... | plotly/python-api | packages/python/plotly/plotly/validators/pie/hoverlabel/_bgcolor.py | Python | mit | 499 |
package be.echostyle.moola;
import be.echostyle.moola.filters.TransactionFilter;
import java.time.LocalDateTime;
import java.util.Comparator;
import java.util.List;
import java.util.Set;
import java.util.stream.Collectors;
public interface GroupedAccount extends Account {
default AccountType getType... | Kjoep/moola | moola-domain/src/main/java/be/echostyle/moola/GroupedAccount.java | Java | mit | 3,248 |
# Options
require 'bobkit'
include Bobkit::Tasks
# Set options (these are only partial, and the defaults)
templates_folder 'templates'
layouts_folder "#{templates_folder}/layouts"
styles_folder 'styles'
output_folder 'output'
css_output_folder "#{output_folder}/css"
js_output_fol... | DannyBen/bobkit | examples/03_options/example.rb | Ruby | mit | 558 |
package seedu.jobs.storage;
import java.io.File;
import java.io.FileNotFoundException;
import java.io.IOException;
import java.util.Optional;
import java.util.logging.Logger;
import seedu.jobs.commons.core.LogsCenter;
import seedu.jobs.commons.exceptions.DataConversionException;
import seedu.jobs.commons.util.FileUti... | CS2103JAN2017-F11-B1/main | src/main/java/seedu/jobs/storage/XmlTaskBookStorage.java | Java | mit | 2,457 |
/**
Starting with version 2.0, this file "boots" Jasmine, performing all of the necessary initialization before executing the loaded environment and all of a project's specs. This file should be loaded after `jasmine.js` and `jasmine_html.js`, but before any project source files or spec files are loaded. Thus this fil... | mukulikadey/SOEN341-Group1 | chutzpah/Chutzpah/TestFiles/Jasmine/v2/boot.js | JavaScript | mit | 5,936 |
package net.lightbody.bmp;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableMap;
import com.google.common.collect.MapMaker;
import net.lightbody.bmp.client.ClientUtil;
import net.lightbody.bmp.core.har.Har;
import net.lightbody.bmp.core.har.HarLog;
import net.lightbody.bmp.cor... | misakuo/Dream-Catcher | app/src/main/java/net/lightbody/bmp/BrowserMobProxyServer.java | Java | mit | 42,816 |
require "spec_helper"
describe RefreshTraktTokenJob do
subject{described_class.new}
Given(:credential){create :credential}
Given!(:stub) do
stub_request(:post, "https://api-v2launch.trakt.tv/oauth/token")
.with(body: {refresh_token: credential.data["refresh_token"], grant_type: "refresh_token"}.to_js... | mskog/broad | spec/jobs/refresh_trakt_token_job_spec.rb | Ruby | mit | 654 |
/*!
* Angular Material Design
* https://github.com/angular/material
* @license MIT
* v0.11.4-master-5034a04
*/
goog.provide('ng.material.components.swipe');
goog.require('ng.material.core');
/**
* @ngdoc module
* @name material.components.swipe
* @description Swipe module!
*/
/**
* @ngdoc directive
* @module... | t0930198/shoait | app/bower_components/angular-material/modules/closure/swipe/swipe.js | JavaScript | mit | 1,739 |
# encoding: utf-8
module BitBucket
class Repos::Following < API
# List repo followers
#
# = Examples
# bitbucket = BitBucket.new :user => 'user-name', :repo => 'repo-name'
# bitbucket.repos.following.followers
# bitbucket.repos.following.followers { |watcher| ... }
#
def followers... | fairfaxmedia/bitbucket | lib/bitbucket_rest_api/repos/following.rb | Ruby | mit | 1,155 |
'use strict';
const crypto = require('crypto');
/* lib/handshake.js
* WebSocket handshake.
* * */
module.exports = exports = function(data){
let headers = exports._headers(data);
let sha1 = crypto.createHash('sha1');
sha1.update(headers['sec-websocket-key'] + '258EAFA5-E914-47DA-95CA-C5AB0DC85B11');
let r... | jamen/rela | lib/handshake.js | JavaScript | mit | 1,440 |
require 'spec_helper'
describe 'osx::time_machine::ask_to_use_new_disks_for_backup' do
let(:facts) { {:boxen_user => 'ilikebees' } }
describe('enabled') do
let(:params) { {:ensure => 'present'} }
it 'should set the value to true' do
should contain_boxen__osx_defaults('Toggle Whether Time Machine Asks... | joebadmo/puppet-osx | spec/classes/time_machine/ask_to_use_new_disks_for_backup_spec.rb | Ruby | mit | 950 |
<?php namespace Helpvel\Helpvel;
use Illuminate\Support\ServiceProvider;
class HelpvelServiceProvider extends ServiceProvider {
/**
* Indicates if loading of the provider is deferred.
*
* @var bool
*/
protected $defer = false;
/**
* Bootstrap the application events.
*
* @return void
*/
public fu... | Helpvel/helpvel | src/Helpvel/Helpvel/HelpvelServiceProvider.php | PHP | mit | 617 |
###############
### imports ###
###############
from fabric.api import cd, env, lcd, put, prompt, local, sudo
from fabric.contrib.files import exists
##############
### config ###
##############
local_app_dir = './flask_project'
local_config_dir = './config'
remote_app_dir = '/home/www'
remote_git_dir = '/home/git... | kaiocesar/automation-fab | fabfile.py | Python | mit | 4,325 |
# encoding: UTF-8
# Author:: Akira FUNAI
# Copyright:: Copyright (c) 2009 Akira FUNAI
require "#{::File.dirname __FILE__}/t"
class TC_Text < Test::Unit::TestCase
def setup
meta = nil
Bike::Parser.gsub_scalar('$(foo text 3 1..5)') {|id, m|
meta = m
''
}
@f = Bike::Field.instance meta... | afunai/bike | t/test_text.rb | Ruby | mit | 2,573 |
import React from 'react';
import ReactDOM from 'react-dom';
import Deferred from 'deferred-js';
import ElementsModel from './visualizution/elementsModel';
import ElementsList from './visualizution/elementsList';
import ControlsView from './controls/controlsView';
import Immutable from 'immutable';
import styles from '... | vogelino/periodic-table-data-visualization | src/js/index.js | JavaScript | mit | 1,705 |
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace SocketDog.Common
{
public struct ConnectionProtocol
{
public ConnectionProtocol(Type value)
: this()
{
Value = value;
}
public ... | deniskucherov/SocketDog | SocketDog.Common/ConnectionProtocol.cs | C# | mit | 809 |
package com.myconnector.domain;
import com.myconnector.domain.base.BaseDictionary;
public class Dictionary extends BaseDictionary {
private static final long serialVersionUID = 1L;
/*[CONSTRUCTOR MARKER BEGIN]*/
public Dictionary () {
super();
}
/**
* Constructor for primary key
*/
public Dictionary (j... | nileshk/myconnector | src/main/java/com/myconnector/domain/Dictionary.java | Java | mit | 395 |
/*
* The MIT License
*
* Copyright 2017 Arvind Sasikumar.
*
* 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 u... | arvindsasikumar/mysql-db-sync | sync/db/mysql/DBSyncAgent.java | Java | mit | 17,612 |
<?php
namespace Forecast\WeatherBundle\DependencyInjection;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\Config\FileLocator;
use Symfony\Component\HttpKernel\DependencyInjection\Extension;
use Symfony\Component\DependencyInjection\Loader;
/**
* This is the class that loads and m... | alexastro/forecast | src/Forecast/WeatherBundle/DependencyInjection/ForecastWeatherExtension.php | PHP | mit | 962 |
from django.contrib import admin
from api_boilerplate.models import ApiKey
admin.site.register(ApiKey)
| kippt/django-api-boilerplate | api_boilerplate/admin.py | Python | mit | 105 |
package com.sparcs.casino;
import com.sparcs.casino.game.Bet;
public interface Account {
/**
* @return The {@link Customer} who owns this Account.
*/
Customer getCustomer();
/**
* @return The number of chips the Customer currently holds
*/
int getChipCount();
/**
* A {@link Bet} has been won! - add... | sparcs360/Casino | game-srvkit/src/main/java/com/sparcs/casino/Account.java | Java | mit | 538 |
/* Generated By:JJTree: Do not edit this line. ASTInclusiveORExpression.java Version 4.3 */
/* JavaCCOptions:MULTI=true,NODE_USES_PARSER=false,VISITOR=true,TRACK_TOKENS=true,NODE_PREFIX=AST,NODE_EXTENDS=,NODE_FACTORY=,SUPPORT_CLASS_VISIBILITY_PUBLIC=true */
package org.iguanatool.testobject.cparser;
public class ASTIn... | iguanatool/iguana | src/main/java/org/iguanatool/testobject/cparser/ASTInclusiveORExpression.java | Java | mit | 742 |
package fi.csc.chipster.rest.websocket;
import java.io.IOException;
import java.util.concurrent.CountDownLatch;
import java.util.concurrent.TimeUnit;
import java.util.concurrent.TimeoutException;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import jakarta.websocket.CloseReason;... | chipster/chipster-web-server | src/main/java/fi/csc/chipster/rest/websocket/WebSocketClientEndpoint.java | Java | mit | 5,780 |
package com.infullmobile.jenkins.plugin.restrictedregister.settings;
import hudson.model.AbstractDescribableImpl;
import hudson.model.Descriptor;
/**
* Created by Adam Kobus on 27.05.2016.
* Copyright (c) 2016 inFullMobile
* License: MIT, file: /LICENSE
*/
public abstract class RegistrationRuleConfig extends Abst... | inFullMobile/restricted-register-plugin | src/main/java/com/infullmobile/jenkins/plugin/restrictedregister/settings/RegistrationRuleConfig.java | Java | mit | 469 |
require 'open3'
When(/^I execute it via the execute function of the PuppetShow module$/) do
@results = PuppetShow.execute(@file)
end
When(/^I execute the PuppetShow binary with the option:$/) do |opt|
cmd = "./bin/puppetshow #{opt}"
@stdout_str, @status = Open3.capture2(cmd)
end
When(/^I execute it via the Pu... | ludokng/puppetshow | features/step_definitions/execute_steps.rb | Ruby | mit | 428 |
/* @author rich
* Created on 07-Jul-2003
*
* This code is covered by a Creative Commons
* Attribution, Non Commercial, Share Alike license
* <a href="http://creativecommons.org/licenses/by-nc-sa/1.0">License</a>
*/
package org.lsmp.djep.vectorJep.values;
import org.lsmp.djep.vectorJep.*;
//import JSci.... | Kailashrb/Jep | src/org/lsmp/djep/vectorJep/values/Matrix.java | Java | mit | 4,371 |
var demand = require('must'),
DateArrayType = require('../DateArrayType');
exports.initList = function(List) {
List.add({
datearr: { type: DateArrayType },
nested: {
datearr: { type: DateArrayType }
}
});
};
exports.testFieldType = function(List) {
var testItem = new List.model();
it('should default t... | riyadhalnur/keystone | fields/types/datearray/test/server.js | JavaScript | mit | 3,459 |
# -*- coding: utf-8 -*-
# Generated by Django 1.11 on 2017-04-24 22:03
from __future__ import unicode_literals
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('samples', '0004_sample'),
]
operations = [
m... | gcrsaldanha/fiocruz | samples/migrations/0005_auto_20170424_1903.py | Python | mit | 1,172 |
# -*- coding:utf-8 -*-
import os
def split_screen():
val = os.system("xrandr --output HDMI1 --right-of VGA1 --auto")
def run_sensorcmd_web():
path = "/home/suyf/swork/git/sensorcmd-web/web/"
os.chdir(path)
val = os.system("./apprun.py")
def run_cas():
path = "/home/suyf/swork/git/cas/web/"
os.chdir(path)
val = ... | myyyy/wiki | shell/work_start.py | Python | mit | 791 |
module.exports = {
root: 'src',
rulesDir: 'rules',
rules: {
'stricter/unused-files': [
{
level: 'error',
config: {
entry: [/.*[\\\/]src[\\\/]index\.ts/, /.*__snapshots__.*/, /.*__fixtures__.*/],
relatedEntry: [/.*tes... | stricter/stricter | stricter.config.js | JavaScript | mit | 682 |
package net.trolldad.dashclock.redditheadlines.testactivity;
import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import net.trolldad.dashclock.redditheadlines.activity.PreviewActivity_;
/**
* Created by jacob-tabak on 1/28/14.
*/
public class LaunchNonImgurActivity extends Activit... | Trolldad/Reddit-Headlines | Reddit Headlines for DashClock/src/main/java/net/trolldad/dashclock/redditheadlines/testactivity/LaunchNonImgurActivity.java | Java | mit | 815 |
<?php
namespace HeroBundle\Form\Paragraph;
use HeroBundle\Entity\Item;
use HeroBundle\Repository\ItemRepository;
use Symfony\Bridge\Doctrine\Form\Type\EntityType;
use Symfony\Component\Form\CallbackTransformer;
use Symfony\Component\Form\Extension\Core\Type\IntegerType;
use Symfony\Component\Form\AbstractType;
use Sy... | Cryborg/you_are_the_hero | src/HeroBundle/Form/Paragraph/AccessConditionsType.php | PHP | mit | 1,613 |
'use strict';
// CUSTOM ERROR //
/**
* FUNCTION: createClass()
* Creates a CustomError class constructor. Note that we use function generation so that tests may be run in browsers not supporting ES2015 classes. This function may be loaded in non-ES2015 environments, but should only be invoked when ES2015 classes are ... | kgryte/utils-copy-error | test/fixtures/customerror.subclass.js | JavaScript | mit | 741 |
let AutomaticComponent = require('./AutomaticComponent');
class PurifyCss extends AutomaticComponent {
/**
* Required dependencies for the component.
*/
dependencies() {
if (Config.purifyCss) {
throw new Error(
'PurifyCSS support is no longer available. We recommen... | JeffreyWay/laravel-mix | src/components/PurifyCss.js | JavaScript | mit | 419 |
import "ember";
var Router, App, AppView, templates, router, container;
var get = Ember.get,
set = Ember.set,
compile = Ember.Handlebars.compile,
forEach = Ember.EnumerableUtils.forEach;
function bootApplication() {
router = container.lookup('router:main');
Ember.run(App, 'advanceReadiness');
}
funct... | g13013/ember.js | packages_es6/ember/tests/routing/basic_test.js | JavaScript | mit | 84,137 |
"""
from https://codelab.interviewbit.com/problems/symmetry/
"""
# Definition for a binary tree node
# class TreeNode:
# def __init__(self, x):
# self.val = x
# self.left = None
# self.right = None
class Solution:
# @param A : root node of tree
# @return an integer
def isSymm... | JuanCTorres/interview-prep-solutions | codelab/symmetric_trees.py | Python | mit | 694 |
/**
* Simple themeing with color overrides
*/
export namespace Colors {
export let flatButtonPrimary = 'rgb(0, 188, 212)';
}
| basarat/uic | src/base/styles.tsx | TypeScript | mit | 129 |
/* Gruntfile.js
* Grunt workflow for building kick-ass AngularJS applications.
* @author Calvin Lai <calvin@wunwun.com>
*/
module.exports = function(grunt) {
var _APP_NAME_ = "CHANGE ME IN Gruntfile.js";
// initial grunt configuration
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
ap... | dharmapurikar/ng-phonegap | Gruntfile.js | JavaScript | mit | 13,023 |
package CellContent;
import java.util.*;
import Cell.Cell;
import Models.Ant;
import javafx.scene.paint.Color;
public class ForagingAntsContent extends CellContent{
List<Ant>antsHere;
double homePheromone, foodPheromone, maxPheromone;
boolean isFoodSource, isHome;
public ForagingAntsContent (int ... | NaijiaoZhang/cellsociety | src/CellContent/ForagingAntsContent.java | Java | mit | 2,214 |