repo_name stringlengths 4 116 | path stringlengths 4 379 | size stringlengths 1 7 | content stringlengths 3 1.05M | license stringclasses 15
values |
|---|---|---|---|---|
DrClick/ARCRacing | training/train.py | 5282 | #!/usr/bin/python
import csv
import numpy as np
from scipy.misc import imread
import cv2
from keras.models import Sequential
from keras.layers.core import Dense, Activation, Flatten, Dropout, Lambda
from keras.layers import concatenate, Input
from keras.models import Model
from keras.layers.convolutional import Convol... | mit |
dawidf/allegroapi | src/Imper86/AllegroApi/Soap/Wsdl/doGetMyWonItemsResponse.php | 1339 | <?php
namespace Imper86\AllegroApi\Soap\Wsdl;
class doGetMyWonItemsResponse
{
/**
* @var int $wonItemsCounter
*/
protected $wonItemsCounter = null;
/**
* @var ArrayOfWonitemstruct $wonItemsList
*/
protected $wonItemsList = null;
/**
* @param int $wonItemsCounter
* ... | mit |
sethtrain/marvin | functions/roll/handler.js | 1652 | 'use strict';
/* Patterns accepted:
* - 4d20 Rolls a d20 four times
* - d12+3 Rolls a d12 once and adds 3
* - d128 Rolls a d128 (arbitrary dice shape) once
* - 3d6-2 Rolls a d6 three times and subtracts 2
* - 1d10*10 Rolls a d10 once and multiplies by 10
* - 4d6+2-4*5 Rolls a d6 fo... | mit |
mgfreshour/gamebot | chess/FEN.go | 3381 | package chess
import (
"bytes"
"strconv"
"strings"
"unicode"
)
func LoadFENGame(s string) *Game {
game := &Game{make([]*Piece, 0), White, 0, 0, castlingStatus{}, "", ""}
n := loadBoardPositions(s, game)
n = loadSide(s, n, game)
n = loadCastling(s, n, game)
n = loadEnPassant(s, n, game)
n = loadHalfMove(s, ... | mit |
Nnamso/tbox | application/config/config.php | 13549 | <?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
function autoload($classname)
{
if (strpos($classname, 'CI_') !== 0)
{
$file = APPPATH . 'libraries/' . $classname . '.php';
if (file_exists($file) && is_file($file))
{
//include_once($file);
require_once $file;
}
}
}
spl_a... | mit |
4FunApp/4Fun | client/FourFun/app/src/main/java/com/joker/fourfun/Constants.java | 1489 | package com.joker.fourfun;
/**
* Created by joker on 2016/12/20.
*/
public class Constants {
public static final String MAIN_ACTIVITY_BUNDLE = "main_bundle";
public static final String MEDIA_BUNDLE = "media_bundle";
public static final String MOVIE_BUNDLE = "movie_bundle";
public static final String... | mit |
iceicy/NEMS | js/application/views/registration/register/form.php | 8114 | <section>
<!-- Page content-->
<div class="content-wrapper">
<h3>Sing Up
<small></small>
</h3>
<!-- START row-->
<div class="row">
<div class="col-lg-12">
<!-- START panel-->
<div class="panel panel-default">
<div class="pa... | mit |
debjeet-sarkar/aedes | test/qos1.js | 16924 | 'use strict'
var test = require('tape').test
var helper = require('./helper')
var aedes = require('../')
var setup = helper.setup
var connect = helper.connect
var subscribe = helper.subscribe
test('publish QoS 1', function (t) {
var s = connect(setup())
var expected = {
cmd: 'puback',
messageId: 42,
q... | mit |
wildbit/beanstalk-code-snippet-bot | src/bot.js | 2429 | const getFileContents = require('./utils').getFileContents
const Botkit = require('botkit')
const BeepBoop = require('beepboop-botkit')
const storage = require('node-persist')
const {
HELP_MESSAGE,
ERROR_MESSAGE,
MISSING_AUTH,
BS_URL_MATCH,
UNRECOGNIZED_REQUEST
} = require('./constants')
const cont... | mit |
ChrisHuston/Wiki | app/scripts/directives/sectionlink.js | 726 | 'use strict';
angular.module('wikiApp')
.directive('sectionLink', function () {
return {
template: '<a href="javascipt:void(0)" ng-click="fxn(section)">{{txt}}</a>',
restrict: 'A',
transclude:true,
scope: {
fxn:'=',
section:'@',
... | mit |
DDReaper/XNAGameStudio | Samples/PushRecipe_WP7_SL/Source/WindowsPhone.Recipes.Push.Messasges/HttpWebResponseExtensions.cs | 2384 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Net;
namespace WindowsPhone.Recipes.Push.Messasges
{
/// <summary>
/// Extends the <see cref="HttpWebResponse"/> type with methods for translating push notification specific status codes strings to strong typed ... | mit |
gil0mendes/continuum | engine/src/main/java/org/continuum/datastructures/BlockmaniaArray.java | 1603 | /*
* Copyright 2014-2017 Gil Mendes
*
* 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.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agree... | mit |
noahlvb/dotfiles | .atom/packages/teletype/lib/host-portal-binding.js | 5602 | const path = require('path')
const {CompositeDisposable, Emitter} = require('atom')
const {FollowState} = require('@atom/teletype-client')
const BufferBinding = require('./buffer-binding')
const EditorBinding = require('./editor-binding')
const SitePositionsController = require('./site-positions-controller')
module.ex... | mit |
LibertyReserve/LibertyReserve | src/qt/locale/bitcoin_sah.ts | 107594 | <?xml version="1.0" ?><!DOCTYPE TS><TS language="sah" version="2.1">
<context>
<name>AboutDialog</name>
<message>
<location filename="../forms/aboutdialog.ui" line="+14"/>
<source>About LibertyReserve</source>
<translation type="unfinished"/>
</message>
<message>
<locatio... | mit |
yogeshsaroya/new-cdnjs | ajax/libs/fastclick/0.6.4/fastclick.min.js | 129 | version https://git-lfs.github.com/spec/v1
oid sha256:b6c31e4046d25cfc21cf2116d42acab6bd5ef6647b0613c22b63f90a852eca7c
size 7177
| mit |
tabfugnic/newsie | lib/generators/newsie/newsie_generator.rb | 591 | # Requires
require 'rails/generators'
require 'rails/generators/migration'
class NewsieGenerator < Rails::Generators::Base
include Rails::Generators::Migration
def self.source_root
@source_root ||= File.join(File.dirname(__FILE__), 'templates')
end
def self.next_migration_number(dirname)
if ActiveRec... | mit |
guiseek/find-my-money | public/app/controllers.js | 10251 | 'use strict';
/* Controllers */
angular.module('myApp.controllers', []).
controller('AppCtrl', function ($rootScope, $scope, $http, $location) {
$scope.active = function(route) {
return route === $location.path();
}
$rootScope.$on('handleEmitCenter', function(event, coords) {
$rootScope.$b... | mit |
comodojo/foundation | src/Comodojo/Foundation/Events/EventsTrait.php | 1491 | <?php
namespace Comodojo\Foundation\Events;
use \Comodojo\Foundation\Events\Manager as EventsManager;
/**
* @package Comodojo Dispatcher
* @author Marco Giovinazzi <marco.giovinazzi@comodojo.org>
* @author Marco Castiello <marco.castiello@gmail.com>
* @license GPL-3.0+
*
* LICENSE:
*
* This... | mit |
toby3d/hitGox | chat/StickyMessage.go | 641 | package chat
import (
"encoding/json"
"strings"
"time"
)
func (ws *Connection) StickyMessage(channel, name, nameColor, text string, startTime *time.Time) error {
var motdMsg Message
motdMsg.Name = message
motdMsg.Args = append(motdMsg.Args, Args{
Method: "motdMsg",
Params: map[string]interface{}{
"channe... | mit |
rgalindo33/pont_del_petroli | spec/spec_helper.rb | 142 | $LOAD_PATH.unshift("#{File.dirname(__FILE__)}/../lib")
require 'pry'
require 'pont_del_petroli'
require 'swell/parser'
require 'meteo/parser' | mit |
Azure/azure-sdk-for-ruby | management/azure_mgmt_network/lib/2015-05-01-preview/generated/azure_mgmt_network/models/connection_shared_key.rb | 1174 | # 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::V2015_05_01_preview
module Models
#
# Response for GetConnectionSharedKey Api service call
#
class Connection... | mit |
json-api-dotnet/JsonApiDotNetCore | test/JsonApiDotNetCoreTests/IntegrationTests/NamingConventions/JsonKebabCaseNamingPolicy.cs | 2748 | using System.Text;
using System.Text.Json;
namespace JsonApiDotNetCoreTests.IntegrationTests.NamingConventions;
// Based on https://github.com/J0rgeSerran0/JsonNamingPolicy
internal sealed class JsonKebabCaseNamingPolicy : JsonNamingPolicy
{
private const char Separator = '-';
public static readonly JsonKeba... | mit |
pprkut/lunr | src/Lunr/Gravity/Database/MySQL/Tests/MySQLConnectionMasterSlaveTest.php | 2638 | <?php
/**
* This file contains the MySQLConnectionMasterSlaveTest class.
*
* PHP Version 5.3
*
* @package Lunr\Gravity\Database\MySQL
* @author Heinz Wiesinger <heinz@m2mobi.com>
* @copyright 2013-2018, M2Mobi BV, Amsterdam, The Netherlands
* @license http://lunr.nl/LICENSE MIT License
*/
namespac... | mit |
dlouwers/reactive-consul | client/src/it/scala/stormlantern/consul/client/util/ConsulRegistratorDockerContainer.scala | 1173 | package stormlantern.consul.client.util
import com.spotify.docker.client.messages.ContainerConfig
import org.scalatest.Suite
import stormlantern.dockertestkit.{ DockerClientProvider, DockerContainers }
import scala.collection.JavaConversions._
trait ConsulRegistratorDockerContainer extends DockerContainers { this: S... | mit |
FreeTymeKiyan/LeetCode-Sol-Res | src/main/java/com/freetymekiyan/algorithms/level/medium/EncodeAndDecodeTinyURL.java | 2102 | package com.freetymekiyan.algorithms.level.medium;
import java.util.HashMap;
import java.util.Map;
import java.util.Random;
/**
* 535. Encode and Decode TinyURL
* <p>
* Note: This is a companion problem to the System Design problem: Design TinyURL.
* TinyURL is a URL shortening service where you enter a URL such ... | mit |
hunzaGit/Algoritmo-A-estrella | src/Negocio/heuristica/CalcularDistanciaLineaRecta.java | 611 | package Negocio.heuristica;
/**
* A heuristic that uses the tile that is closest to the target
* as the next best tile.
*/
public class CalcularDistanciaLineaRecta implements InterfazHeuristica {
public float calcularDistanciaAMeta(int startX, int startY, int goalX, int goalY) {
... | mit |
SabreOSS/conf4j | conf4j-javassist/src/test/java/com/sabre/oss/conf4j/factory/javassist/JavassistDynamicIgnorePrefixTest.java | 1536 | /*
* MIT License
*
* Copyright 2017-2018 Sabre GLBL Inc.
*
* 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,... | mit |
seentaoInternetOrganization/reactDemo | app/components/Mro.js | 3206 | import React from 'react';
import MroActions from '../actions/MroActions'
import MroStore from '../stores/MroStore'
import MroDialog from './MroDialog';
class Mro extends React.Component {
constructor(props) {
super(props);
this.state = MroStore.getState();
this.onChange = this.onChange.bin... | mit |
ImmaculatePine/hermitage | lib/hermitage/rails_render_core.rb | 2053 | # frozen_string_literal: true
module Hermitage
# This class performs all the rendering logic for Rails apps
class RailsRenderCore
def initialize(objects, options = {})
@objects = objects
@options = Configurator.options_for(objects, options)
@template = ActionView::Base.new
end
# Rend... | mit |
PaluMacil/misc | wxPy/app.py | 97 | import wx
app = wx.App()
frame = wx.Frame(None, -1, "Hello World")
frame.Show()
app.MainLoop() | mit |
okhosting/OKHOSTING.ORM | test/OKHOSTING.Tienda/OKHOSTING.Tienda.ORM.UI.Test.Net4.WPF/MainWindow.xaml.cs | 623 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;... | mit |
scotton22/test-sym-base | src/Cotton/hello/crudBundle/DependencyInjection/Configuration.php | 880 | <?php
namespace Cotton\hello\crudBundle\DependencyInjection;
use Symfony\Component\Config\Definition\Builder\TreeBuilder;
use Symfony\Component\Config\Definition\ConfigurationInterface;
/**
* This is the class that validates and merges configuration from your app/config files
*
* To learn more see {@link http://s... | mit |
karim/adila | database/src/main/java/adila/db/hs2d10dtb4_hs2d10dtb4.java | 227 | // This file is automatically generated.
package adila.db;
/*
* Haier HS-10DTB4
*
* DEVICE: HS-10DTB4
* MODEL: HS-10DTB4
*/
final class hs2d10dtb4_hs2d10dtb4 {
public static final String DATA = "Haier|HS-10DTB4|";
}
| mit |
0xaio/create-react-app | packages/react-scripts/bin/react-scripts.js | 1813 | #!/usr/bin/env node
/**
* Copyright (c) 2015-present, Facebook, Inc.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
'use strict';
const spawn = require('@0xaio/react-dev-utils/crossSpawn');
const args = process.argv.slice(2);
cons... | mit |
SebastienDaniel/fieldValidator | Gruntfile.js | 2307 | module.exports = function(grunt) {
// instructions for grunt
grunt.initConfig({
pkg: grunt.file.readJSON("package.json"),
removelogging: {
build: {
src: "fieldValidator.js"
}
},
clean: ["build/**"],
uglify: {
build:... | mit |
cschwarz/AppShell | samples/NativeMaps/AppShell.Samples.NativeMaps/ViewModels/NativeMapsMasterViewModel.cs | 2645 | using AppShell.NativeMaps;
using System.Collections.Generic;
using System.Collections.ObjectModel;
namespace AppShell.Samples.NativeMaps
{
public class NativeMapsMasterViewModel : MasterViewModel
{
public NativeMapsMasterViewModel(IServiceDispatcher serviceDispatcher)
: base(serviceDispatc... | mit |
Yuliang-Zou/Automatic_Group_Photography_Enhancement | lib/networks/caffenet.py | 1795 | import tensorflow as tf
from networks.network import Network
class caffenet(Network):
def __init__(self, trainable=True):
self.inputs = []
self.data = tf.placeholder(tf.float32, shape=[None, None, None, 3])
self.rois = tf.placeholder(tf.float32, shape=[None, 5])
self.keep_prob = tf.... | mit |
chirpd/chirpd-platform | symphony/lib/toolkit/cryptography/class.sha1.php | 1274 | <?php
/**
* @package, cryptography
*/
/**
* SHA1 is a cryptography class for hashing and comparing messages
* using the SHA1-Algorithm
*
* @since Symphony 2.3.1
* @see toolkit.Cryptography
* @deprecated This code is regarded as insecure and exists only for backwards-compatibility-purposes.
* It shou... | mit |
terrafx/terrafx | sources/Graphics/Core/Graphics/GraphicsPipelineInputElementKind.cs | 810 | // Copyright © Tanner Gooding and Contributors. Licensed under the MIT License (MIT). See License.md in the repository root for more information.
namespace TerraFX.Graphics;
/// <summary>Defines the kind of a graphics pipeline input element.</summary>
public enum GraphicsPipelineInputElementKind
{
/// <summary>De... | mit |
OssecTN/TuniHack2015 | Netlinkers/TunihackOfficialProject-master/src/Data/DataTools.java | 2046 | package Data;
import java.io.ByteArrayOutputStream;
import java.io.IOException;
import java.security.MessageDigest;
import java.security.NoSuchAlgorithmException;
import java.util.ArrayList;
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file,... | mit |
thekoders/kticketing | booking_without_visa.php | 1645 | <?php
require_once 'conf/smarty-conf.php';
include 'functions/user_functions.php';
include 'functions/chat_functions.php';
include 'functions/outstanding_functions.php';
$module_no = 58;
if ($_SESSION ['login'] == 1) {
if (check_access ( $module_no, $_SESSION ['user_id'] ) == 1) {
if ($_REQUEST ['job'] == "booking_... | mit |
postgrestsharp/postgrestsharp | src/PostgRESTSharp/IMetaModelConvention.cs | 213 | namespace PostgRESTSharp
{
public interface IMetaModelConvention
{
}
public interface IMetaModelFieldNamingConvention : IMetaModelConvention
{
string Process(string fieldName);
}
} | mit |
robwebdev/ember-cli-staticboot | lib/commands/staticboot.js | 2127 | /* jshint node: true */
'use strict';
const RSVP = require('rsvp');
const getPort = RSVP.denodeify(require('portfinder').getPort);
const ServerTask = require('../tasks/staticboot-server');
const SilentError = require('silent-error');
const blockForever = () => (new RSVP.Promise(() => {}));
const noop = function() { ... | mit |
Tonius/NEI-Integration | src/main/java/tonius/neiintegration/mods/forestry36/RecipeHandlerMoistener.java | 4966 | package tonius.neiintegration.mods.forestry36;
import java.awt.Point;
import java.awt.Rectangle;
import java.util.ArrayList;
import java.util.List;
import net.minecraft.client.gui.inventory.GuiContainer;
import net.minecraft.item.ItemStack;
import net.minecraftforge.fluids.FluidRegistry;
import net.minecraftforge.flu... | mit |
nfMalde/Ren.CMS.NET | Ren.CMS.Net/Source/Ren.CMS.Net-Modules/Ren.CMS.Net.BlogModule/BlogModule/Blog/Controllers/BlogController.cs | 18497 | namespace Ren.CMS.Blog
{
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Data.SqlClient;
using System.Globalization;
using System.Linq;
using System.Text.RegularExpressions;
using System.Web;
using System.Web.Mvc;
using ... | mit |
previousdeveloper/Retrofit.OAuth-2 | app/src/main/java/oauth2/constant/OauthConstant.java | 1385 | package oauth2.constant;
/**
* Created by gokhan on 4/8/15.
*/
public class OauthConstant {
public static final String ACCESS_TOKEN = "access_token";
public static final String CLIENT_ID = "client_id";
public static final String CLIENT_SECRET = "client_secret";
public static final String REFRESH_TOK... | mit |
GluuFederation/oxTrust | server/src/main/java/org/gluu/oxtrust/action/radius/SearchRadiusClientAction.java | 3638 | package org.gluu.oxtrust.action.radius;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.Comparator;
import java.util.List;
import javax.enterprise.context.ConversationScoped;
import javax.faces.application.FacesMessage;
import javax.inject.Inject;
import javax.inject.Named;
import javax.vali... | mit |
gmich/Gem | Gem.Engine/Database/BTree/TreeStringSerialzier.cs | 518 | using System;
namespace Gem.Engine.Database
{
public class TreeStringSerialzier : ISerializer<string>
{
public byte[] Serialize (string value)
{
return System.Text.Encoding.UTF8.GetBytes (value);
}
public string Deserialize (byte[] buffer, int offset, int length)
{
return System.Text.Encoding.UTF8.... | mit |
goominc/goommerce-react | mobile-site/containers/ResetPassword.js | 2431 | // Copyright (C) 2016 Goom Inc. All rights reserved.
import React, { PropTypes } from 'react';
import { Link } from 'react-router';
import { connect } from 'react-redux';
import _ from 'lodash';
import i18n from 'commons/utils/i18n';
import { ApiAction } from 'redux/actions';
const { resetPassword } = ApiAction;
imp... | mit |
dx14/Cell-Society | src/Buttons.java | 7889 |
import java.util.ResourceBundle;
import javafx.animation.KeyFrame;
import javafx.animation.Timeline;
import javafx.geometry.Pos;
import javafx.scene.control.Alert;
import javafx.scene.control.Button;
import javafx.scene.control.CheckBox;
import javafx.scene.control.ComboBox;
import javafx.scene.layout.BorderPane;
imp... | mit |
edwin1127/EdwinCAwesomeNauts | js/entities/entities.js | 6614 | game.PlayerEntity = me.Entity.extend({
init: function(x, y, settings) {
this.setSuper();
this.setPlayerTimers();
this.setAttributes();
this.type = "PlayerEntity";
this.setFlags();
me.game.viewport.follow(this.pos, me.game.viewport.AXIS.BOTH);
this.addAnimation();
this.renderable.setCurrentAn... | mit |
vsite-hr/mentor | src/main/java/hr/vsite/mentor/servlet/rest/resources/UnitResource.java | 6908 | package hr.vsite.mentor.servlet.rest.resources;
import java.io.IOException;
import java.nio.file.Files;
import java.util.Date;
import java.util.List;
import javax.inject.Inject;
import javax.inject.Provider;
import javax.transaction.Transactional;
import javax.ws.rs.GET;
import javax.ws.rs.HEAD;
import javax.ws.rs.He... | mit |
ladislavlisy/payrollee_cz | lib/payrollee_cz/pay_tags/income_netto_tag.rb | 206 | # Specification: Net Income
module PayrolleeCz
class IncomeNettoTag < PayrollTag
def initialize
super(PayTagGateway::REF_INCOME_NETTO, PayConceptGateway::REFCON_INCOME_NETTO)
end
end
end
| mit |
pchrysa/Memento-Calendar | android_mobile/src/main/java/com/alexstyl/specialdates/events/peopleevents/PeopleEventsViewRefresher.java | 1639 | package com.alexstyl.specialdates.events.peopleevents;
import android.appwidget.AppWidgetManager;
import android.content.ContentResolver;
import android.content.Context;
import com.alexstyl.specialdates.PeopleEventsView;
import com.alexstyl.specialdates.upcoming.widget.list.UpcomingEventsScrollingWidgetView;
import c... | mit |
Chicloon/conf | server/routes/login.ts | 1831 | import { Router, Request, Response, NextFunction } from "express";
import { randomBytes, pbkdf2 } from "crypto";
import { sign } from "jsonwebtoken";
import { secret, length } from "../config";
const loginRouter: Router = Router();
const user = {
hashedPassword: "97fe86e10b558f6b0de6b20a4f22fae853bcce137234519993... | mit |
lgbr/warehouse | test/unit/directory_file_test.rb | 160 | require 'test_helper'
class DirectoryFileTest < ActiveSupport::TestCase
# Replace this with your real tests.
test "the truth" do
assert true
end
end
| mit |
wait4pumpkin/pityboy | lib/haml/filters/mathjax.rb | 833 | require 'redcarpet'
class HTMLwithMathJax < Redcarpet::Render::HTML
def initialize(options={})
@@counter = 0
@@limit = options[:truncate]
logger.warn 'ABC'
logger.info options.inspect
super
end
def block_code(code, language)
if language == 'mathjax'
"<script type=\"math/tex; mode=d... | mit |
RoryBecker/CR_FavoriteViews | CR_FavoriteViews/PlugIn1.Designer.cs | 2684 | namespace CR_FavoriteViews
{
partial class PlugIn1
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
public PlugIn1()
{
/// <summary>
/// Required for Windows.Forms Class Composition Designer support
/// </summary>
Initi... | mit |
yanzay/shoppu | lib/shoppu/interactors/add_item_to_order.rb | 162 | module Shoppu
class AddItemToOrder
def initialize(params)
@params = params
end
def execute
ItemsRepo.create(@params)
end
end
end
| mit |
tacki/Symfony | src/Ruins/StoreBundle/RuinsStoreBundle.php | 128 | <?php
namespace Ruins\StoreBundle;
use Symfony\Component\HttpKernel\Bundle\Bundle;
class RuinsStoreBundle extends Bundle
{
}
| mit |
zdvresearch/fast15-paper-extras | tape_mounts/robot_mount_logs/src/StateMachine.py | 2487 | __author__ = 'maesker'
import sys
class FiniteStateMachine:
def __init__(self):
self.transitions={}
self.state = None
self.defaultErrorState = 0
self.last_event_ts = 0
self.subsequent_events = []
def add_transition(self, event, src, dest, callback, rules={}):
if... | mit |
phiphou/was | src/app/shared/pipes/dateConvert.pipe.ts | 989 | import {Pipe, PipeTransform} from '@angular/core';
@Pipe({
name: 'dateConvert'
})
export class DateConvertPipe implements PipeTransform {
transform(value: any, lang: string = 'en') {
let daysEn: string[] = ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'];
let monthsEn: string[... | mit |
pimier15/PyGUI | Kivy/Kivy/Bk_Interractive/My/C2/Rotation/rotation.py | 290 | import kivy
kivy.require('1.9.1')
from kivy.app import App
from kivy.uix.relativelayout import RelativeLayout
class RotationCanvas(RelativeLayout):
pass
class RotationApp(App):
def build(self):
return RotationCanvas()
if __name__ == '__main__':
RotationApp().run()
| mit |
guyonroche/exceljs | lib/utils/browser-buffer-decode.js | 386 | // eslint-disable-next-line node/no-unsupported-features/node-builtins
const textDecoder = typeof TextDecoder === 'undefined' ? null : new TextDecoder('utf-8');
function bufferToString(chunk) {
if (typeof chunk === 'string') {
return chunk;
}
if (textDecoder) {
return textDecoder.decode(chunk);
}
ret... | mit |
moberwasserlechner/vaadin-medium-editor | demo/src/main/java/com/byteowls/vaadin/mediumeditor/demo/ui/views/theme/BootstrapThemeView.java | 1236 | package com.byteowls.vaadin.mediumeditor.demo.ui.views.theme;
import com.byteowls.vaadin.mediumeditor.MediumEditor;
import com.byteowls.vaadin.mediumeditor.demo.ui.views.AbstractAddonView;
import com.byteowls.vaadin.mediumeditor.options.MediumEditorTheme;
import com.thedeanda.lorem.Lorem;
import com.vaadin.spring.anno... | mit |
CMDann/hololens-starter | Assets/HoloToolkit/Utilities/Scripts/SingleInstance.cs | 1558 | // Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See LICENSE in the project root for license information.
using UnityEngine;
namespace HoloToolkit.Unity
{
/// <summary>
/// A simplified version of the Singleton class which doesn't depend on the Instance ... | mit |
xamarin/monotouch-samples | NavigationBar/NavigationBar/CitiesDataSource.cs | 1351 | using System;
using System.Collections.Generic;
using System.Linq;
using Foundation;
using UIKit;
namespace NavigationBar
{
public class CitiesDataSource : UITableViewDataSource
{
private readonly List<string> cities = new List<string>();
public CitiesDataSource()
{
var ci... | mit |
Ada323/brainstorm | client/app/reducers/currentNode.js | 254 | function currentNode(state={}, action) {
switch (action.type) {
case 'SET_NODE':
// console.log('updating state, setting current node')
return action.node
default:
return state
}
return state
}
export default currentNode
| mit |
tonymayflower/smartask | tests/SMARTASKCommentBundle/Controller/DefaultControllerTest.php | 385 | <?php
namespace SMARTASKCommentBundle\Tests\Controller;
use Symfony\Bundle\FrameworkBundle\Test\WebTestCase;
class DefaultControllerTest extends WebTestCase
{
public function testIndex()
{
$client = static::createClient();
$crawler = $client->request('GET', '/');
$this->assertContai... | mit |
ulocbr/uloc-vue-theme | src/components/icon/IconLibrary.js | 819 | const IconLibrary = {
library: {},
removeItem (name) {
if (typeof this.library[name] !== 'undefined') {
delete this.library[name]
}
},
add (Library) {
// TODO: Validar objeto e lançar exceção caso não passe
/**
* Library Interface:
* name: 'default' // Name of library
* Comp... | mit |
ziedAb/PVMourakiboun | tools/render.js | 2067 | /**
* React Starter Kit (https://www.reactstarterkit.com/)
*
* Copyright © 2014-present Kriasoft, LLC. All rights reserved.
*
* This source code is licensed under the MIT license found in the
* LICENSE.txt file in the root directory of this source tree.
*/
import path from 'path';
import fetch from 'node-fetch'... | mit |
quandhz/resaga | lib/internal/helpers/__tests__/selectOwnStore.test.js | 1079 | import { fromJS } from 'immutable';
import { VARIABLES } from '../../constants';
/* eslint-disable redux-saga/yield-effects */
import selectOwnStore, { selectValues, shallowlyConvert } from '../selectOwnStore';
const state = fromJS({ TemplateStore: { [VARIABLES]: { id: 1 } } });
describe('selectOwnStore()', () => {
... | mit |
EddyVerbruggen/nativescript-bluetooth | demo/nativescript.config.ts | 286 | import { NativeScriptConfig } from '@nativescript/core';
export default {
id: 'org.nativescript.bluetoothdemo',
appResourcesPath: 'app/App_Resources',
android: {
v8Flags: '--expose_gc',
markingMode: 'none'
},
appPath: 'app'
} as NativeScriptConfig;
| mit |
zxldev/soblog | app/plugins/NotFoundPlugin.php | 1288 | <?php
use Phalcon\Events\Event;
use Phalcon\Mvc\User\Plugin;
use Phalcon\Dispatcher;
use Phalcon\Mvc\Dispatcher\Exception as DispatcherException;
use Phalcon\Mvc\Dispatcher as MvcDispatcher;
/**
* NotFoundPlugin
*
* Handles not-found controller/actions
*/
class NotFoundPlugin extends Plugin
{
/**
* This actio... | mit |
yanhaijing/console.js | src/index.js | 1566 | const apply = Function.prototype.apply;
export function polyfill() {
const g = typeof window !== 'undefined' ? window : {};
const _console = g.console || {};
const methods = ['assert', 'clear', 'count', 'debug', 'dir', 'dirxml', 'exception', 'error', 'group', 'groupCollapsed', 'groupEnd', 'info', 'log', '... | mit |
milejko/mmi | src/Mmi/Mvc/RouterConfigRoute.php | 875 | <?php
/**
* Mmi Framework (https://github.com/milejko/mmi.git)
*
* @link https://github.com/milejko/mmi.git
* @copyright Copyright (c) 2010-2017 Mariusz Miłejko (mariusz@milejko.pl)
* @license https://en.wikipedia.org/wiki/BSD_licenses New BSD License
*/
namespace Mmi\Mvc;
class RouterConfigRoute
{
... | mit |
PiotrDabkowski/Js2Py | tests/test_cases/built-ins/Object/getOwnPropertyDescriptor/15.2.3.3-4-113.js | 805 | // Copyright (c) 2012 Ecma International. All rights reserved.
// Ecma International makes this code available under the terms and conditions set
// forth on http://hg.ecmascript.org/tests/test262/raw-file/tip/LICENSE (the
// "Use Terms"). Any redistribution of this code must retain the above
// copyright and this n... | mit |
mortenthorpe/gladturdev | src/Gladtur/MobileBundle/DependencyInjection/Configuration.php | 883 | <?php
namespace Gladtur\MobileBundle\DependencyInjection;
use Symfony\Component\Config\Definition\Builder\TreeBuilder;
use Symfony\Component\Config\Definition\ConfigurationInterface;
/**
* This is the class that validates and merges configuration from your app/config files
*
* To learn more see {@link http://symf... | mit |
hendrang/andriaskitchen | src/app/shared/modal-simple/modal-simple.component.ts | 876 | import { Component, OnInit, ViewChild, Output, EventEmitter } from '@angular/core';
import { NgbModal } from '@ng-bootstrap/ng-bootstrap';
@Component({
selector: 'app-modal-simple',
templateUrl: './modal-simple.component.html',
styleUrls: ['./modal-simple.component.scss']
})
export class ModalSimpleCompo... | mit |
jackchi/util | python/substring.py | 1790 | #!/usr/bin/python
# https://github.com/jackchi/util
# Copyright 2014 Jack Chi
# Python String manipulation practice
# A Substring is a segment of the original word broken down to len(word)...len(1)
import sys
def toUniqueOrderList(seq):
"""Given a sequence of strings return the unique sequence whilst preserving ord... | mit |
hhaip/langtaosha | lts-hessian/src/main/java/com/caucho/burlap/client/BurlapProxy.java | 6793 | /*
* The Apache Software License, Version 1.1
*
* Copyright (c) 2001-2004 Caucho Technology, Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
*
* 1. Redistributions of source code mu... | mit |
dahall/vanara | PInvoke/Gdi32/WinGdi.Pen.cs | 30688 | using System;
using System.Runtime.InteropServices;
namespace Vanara.PInvoke
{
public static partial class Gdi32
{
/// <summary>End caps used by Pen functions and structures.</summary>
[PInvokeData("wingdi.h", MSDNShortId = "34ffa71d-e94d-425e-9f9d-21e3df4990b7")]
public enum PenEndCap : uint
{
/// <summa... | mit |
lovewxz/mobile-admin | src/routes.js | 1780 | import Login from './views/Login.vue'
import NotFound from './views/404.vue'
import Home from './views/Home.vue'
import Main from './views/Main.vue'
import Table from './views/nav1/Table.vue'
import Form from './views/nav1/Form.vue'
import user from './views/nav1/user.vue'
import echarts from './views/charts/ech... | mit |
RamonCanabarro/web2 | PI/html/produtos/index.php | 1493 | <?php
include_once 'list.php';
$oCadastro = new Produtos();
$cadastrar = $oCadastro->recuperarTodos();
include_once '../cabecalho.php'; ?>
<table class="table table-bordered table-striped table-hover" style="background-color:beige ">
<h1 style="color:silver" align="center">Listagem</h1>
<tr>
<td>Açõe... | mit |
tuanphpvn/core | tests/Fixtures/TestBundle/Entity/Dummy.php | 5230 | <?php
/*
* This file is part of the API Platform project.
*
* (c) Kévin Dunglas <dunglas@gmail.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
declare(strict_types=1);
namespace ApiPlatform\Core\Tests\Fixtures\TestBundle\En... | mit |
Marhz/ppem2l | controllers/validerFormations.php | 296 | <?php
use Core\Error;
use Models\User;
if(!auth('user')->isChef())
Error::set(403);
$employes = User::where('chef_id', auth('user')->id)->with(['formations' => function($query){
$query->with('adresse')->where('valide', 0);
}])->get();
$page="gestion";
include('views/validerFormations.php'); | mit |
hgabor/boardgame | BoardGameRules/Expressions/AddExpr.cs | 1172 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace Level14.BoardGameRules.Expressions
{
class AddExpr: Expression
{
Expression lhs, rhs;
public AddExpr(Expression lhs, Expression rhs)
{
this.lhs = lhs;
... | mit |
CoandaCMS/coanda-web-forms | src/views/attributes/fieldtypes/checkboxes.blade.php | 706 | <div class="form-group @if (isset($invalid_fields['field_' . $field->id])) has-error @endif">
<label class="control-label">{{ $field->label }} @if ($field->required) * @endif</label>
@foreach ((isset($field->typeData()['options']) ? $field->typeData()['options'] : []) as $option_index => $option)
<div class="check... | mit |
appdev-academy/appdev.academy-react | src/js/components/Tags/TableBody.js | 547 | import PropTypes from 'prop-types'
import React from 'react'
import { Link } from 'react-router'
import TableRow from './TableRow'
export default class TableBody extends React.Component {
render() {
let tags = this.props.tags
return (
<tbody>
{ tags.map((tag, index) => {
return ... | mit |
kabisa/kudo-o-matic | spec/graphql/queries/viewer/team_invites_by_viewer_query_spec.rb | 1257 | # frozen_string_literal: true
RSpec.describe Queries::ViewerQuery do
set_graphql_type
let(:user) { create(:user) }
let(:teams) { create_list(:team, 2) }
let!(:team_invite) { create(:team_invite, email: user.email, team: teams.first) }
let!(:team_invite_2) { create(:team_invite, email: user.email, team: team... | mit |
ktanakaj/ws-chat-sample | chat-web/public/app/app.module.ts | 2856 | /**
* @file WebSocketサンプルChatアプリルートモジュール。
*/
import { NgModule, ErrorHandler, Injectable, LOCALE_ID } from '@angular/core';
import { HttpClient, HttpClientModule } from "@angular/common/http";
import { FormsModule } from '@angular/forms';
import { BrowserModule } from '@angular/platform-browser';
import { RouterModu... | mit |
VegasCoin/vegascoin | src/qt/locale/vegascoin_ru.ts | 137974 | <?xml version="1.0" ?><!DOCTYPE TS><TS language="ru" version="2.0">
<defaultcodec>UTF-8</defaultcodec>
<context>
<name>AboutDialog</name>
<message>
<location filename="../forms/aboutdialog.ui" line="+14"/>
<source>About VegasCoin</source>
<translation>&О VegasCoin</translation... | mit |
asolagmbh/plotly.js | src/lib/geo_location_utils.js | 1565 | /**
* Copyright 2012-2019, Plotly, Inc.
* All rights reserved.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
'use strict';
var countryRegex = require('country-regex');
var Lib = require('../lib');
// make list of all country iso3 id... | mit |
gilneidp/FinalProject | ALL_FILES/Python/pullstats.py | 25 | import pox
import oslib
| mit |
andy-c-jones/FilmWebsiteTestingDemo | src/FunctionalTests/HomePage/AddFilmOnHomepageTests.cs | 1432 | using NUnit.Framework;
using TestHelpers;
namespace FunctionalTests
{
[TestFixture]
public class AddFilmOnHomepageTests
{
[Test]
public void GivenTheHomepageWhenFilmAddedViaAddControlThenTheFilmShouldBeRenderedInTheList()
{
SqlHelper.TruncateFilmsTable();
v... | mit |
kocsismate/php-di-container-benchmarks | src/Fixture/B/FixtureB582.php | 99 | <?php
declare(strict_types=1);
namespace DiContainerBenchmarks\Fixture\B;
class FixtureB582
{
}
| mit |
magnusamundsen/mychessratings | app/scripts/app.js | 170 | /** @jsx React.DOM */
var React = require('react');
var App = require('./components/App');
React.renderComponent(
<App />,
document.getElementById('container')
);
| mit |
ptphp/ptphp | tests/Frontend/icon.js | 1680 | /**
* Created by jf on 15/12/9.
*/
"use strict";
import React from 'react';
import { shallow } from 'enzyme';
import assert from 'assert';
import WeUI from '../src/index';
const {Icon} = WeUI;
describe('<Icon>', ()=> {
[
'success',
'success_circle',
'success_no_circle',
'safe_s... | mit |
Michayal/michayal.github.io | node_modules/mathjs/lib/entry/dependenciesAny/dependenciesBignumber.generated.js | 667 | "use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.bignumberDependencies = void 0;
var _dependenciesBigNumberClass = require("./dependenciesBigNumberClass.generated");
var _dependenciesTyped = require("./dependenciesTyped.generated");
var _factoriesAny = require("../../factoriesA... | mit |
tacchinotacchi/osu | osu.Game/Screens/Select/BeatmapInfoWedge.cs | 12952 | // Copyright (c) 2007-2017 ppy Pty Ltd <contact@ppy.sh>.
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
using System;
using System.Collections.Generic;
using System.Linq;
using OpenTK;
using OpenTK.Graphics;
using osu.Framework.Allocation;
using osu.Framework.Ext... | mit |