repo_name stringlengths 4 116 | path stringlengths 4 379 | size stringlengths 1 7 | content stringlengths 3 1.05M | license stringclasses 15
values |
|---|---|---|---|---|
yogeshsaroya/new-cdnjs | ajax/libs/pace/0.4.11/pace.js | 130 | version https://git-lfs.github.com/spec/v1
oid sha256:e12074e3d6d94608d611bbe7c3b3c4fc792008c33e6ee20e5c3d5ef3ceb70661
size 20349
| mit |
uberlife/circle | lib/circle/circle.rb | 5767 | require File.join(File.dirname(__FILE__), 'models', 'friendship')
require File.join(File.dirname(__FILE__), 'models', 'blocked_user')
module Circle
def self.included(receiver)
receiver.extend ClassMethods
end
module ClassMethods
def has_circle
include Circle::InstanceMethods
has_many :frie... | mit |
maclunar/blug | test/dummy/config/routes.rb | 69 | Rails.application.routes.draw do
mount Blug::Engine => "/blug"
end
| mit |
bit-oasis/coin | src/BitOasis/Coin/Address/Validators/CosmosAddressValidator.php | 407 | <?php
namespace BitOasis\Coin\Address\Validators;
use Murich\PhpCryptocurrencyAddressValidation\Validation\ValidationInterface;
/**
* @author Robert Mkrtchyan <mkrtchyanrobert@gmail.com>
*/
class CosmosAddressValidator extends Bech32AddressWithPrefixAndTagValidator implements ValidationInterface {
protected $pre... | mit |
scottcarr/reviewbot | Annotator/ex.cs | 10591 | //------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.33440
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//--... | mit |
MaGuangChen/resume-maguangchen | server/models/message.js | 291 | const mongoose = require('mongoose');
const Schema = mongoose.Schema;
const MessageSchema = new Schema({
userAcount: { type: String },
text: { type: String },
createdTime: { type: String },
sendToUserAcount: { type: String },
});
mongoose.model('message', MessageSchema); | mit |
shahabhijeet/azure-sdk-for-net | src/SDKs/Network/Management.Network/Generated/Models/ExpressRouteCircuitSku.cs | 2632 | // <auto-generated>
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for
// license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is
// re... | mit |
laraveladminpanel/admin | publishable/database/migrations/2018_06_06_074941_alter_data_types_table_name_not_unique.php | 667 | <?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class AlterDataTypesTableNameNotUnique extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::table('da... | mit |
BlackDice/nome | test/nome.test.js | 4011 | import chai, { expect } from 'chai'
import sinon from 'sinon'
import sinonChai from 'sinon-chai'
import NoMe from '../dist/nome'
chai.use(sinonChai)
describe('NoMe', function () {
it('should be a function', function () {
expect(NoMe).to.be.an('function')
})
it('should return a function when invoked', function (... | mit |
itmayziii/itmayziiiPortfolio | database/seeds/DatabaseSeeder.php | 480 | <?php
use Illuminate\Database\Seeder;
class DatabaseSeeder extends Seeder
{
/**
* Run the database seeds.
*
* @return void
*/
public function run()
{
$this->call(UsersTableSeeder::class);
$this->call(CategoriesTableSeeder::class);
$this->call(ContactMeTableSeede... | mit |
ompu/ompu | src/game/gc.cpp | 3430 | #include "ompu/game/gc.hpp"
#include "ompu/game/game_data.hpp"
#include "ompu/midi.hpp"
#include "ompu/util.hpp"
#include <boost/scope_exit.hpp>
#include <thread>
#include <chrono>
#include <ctime>
namespace ompu { namespace game {
GC::Profile::Profile()
: last_run_at(std::chrono::system_clock::now())
{
}
G... | mit |
yjjnls/LeetCode | src/cpp/31. Next Permutation.cpp | 601 | /*
Implement next permutation, which rearranges numbers into the lexicographically next greater permutation of numbers.
If such arrangement is not possible, it must rearrange it as the lowest possible order (ie, sorted in ascending order).
The replacement must be in-place, do not allocate extra memory.
Here a... | mit |
celestial-winter/vics | web-client/app/scripts/controller/adminUserController.js | 4101 |
angular
.module('canvass')
.controller('adminUserController', function (util, $timeout, $scope, userService, $location, toastr) {
$scope.editMode = false;
$scope.validationErrors = [];
function initCreateUserModel() {
return {
username: '',
firstName: '',
lastName: '',
... | mit |
jaredlunde/cargo-orm | cargo/builder/domains.py | 2407 | """
`Cargo ORM Domain Builder`
--·--·--·--·--·--·--·--·--·--·--·--·--·--·--·--·--·--·--·--·--·--·--·--·--·--·--
2015 Jared Lunde © The MIT License (MIT)
http://github.com/jaredlunde
"""
from cargo.fields.field import Field
from cargo.expressions import *
from cargo.statements import *
from cargo.builder.utils... | mit |
DavidTanner/RaspPiSousVide-js | routes/index.js | 6886 | var express = require('express');
var router = express.Router();
var fs = require('fs');
var pid = new pidjs(2000, 44, 165, 4);
var act_temp = 0;
var set_point = 0;
var state = false;
var re = 'YES\n[^=]*=([0-9]*)';
var temp_avg = [];
var pos = 0;
var max = 10;
var cycle_time = 2000;
var relay_on = false;
var p... | mit |
robinroestenburg/marked | lib/marked_blog/engine.rb | 89 | module MarkedBlog
class Engine < Rails::Engine
engine_name "marked_blog"
end
end
| mit |
atealxt/work-workspaces | Test_Java/src/test/security/base64/IBase64URL.java | 171 | package test.security.base64;
public interface IBase64URL {
String encode4URL(String data) throws Exception;
String decode4URL(String data) throws Exception;
}
| mit |
rassvet85/vk | VkNet.UWP/Utils/VkResponseArray.cs | 2419 | using System.Linq;
namespace VkNet.Utils
{
using System.Collections.Generic;
using System.Collections;
using Newtonsoft.Json.Linq;
/// <summary>
/// Массив
/// </summary>
public sealed class VkResponseArray : IEnumerable<VkResponse>
{
/// <summary>
/// Массив
/... | mit |
wizawu/1c | @types/jdk/java.sql.PreparedStatement.d.ts | 5232 | declare namespace java {
namespace sql {
interface PreparedStatement extends java.sql.Statement {
executeQuery(): java.sql.ResultSet
executeUpdate(): number
setNull(arg0: number | java.lang.Integer, arg1: number | java.lang.Integer): void
setBoolean(arg0: number | java.lang.Integer, arg1:... | mit |
maximummeteor/publisher | package.js | 1024 | Package.describe({
name: 'maximum:publisher',
version: '0.3.0',
summary: 'Package that create automatic publications and make template subcriptions easier to use',
git: 'https://github.com/maximummeteor/meteor-publisher',
documentation: 'README.md'
});
Package.onUse(function(api) {
api.versionsFrom('1.1.0.... | mit |
3s3s/multicoins.org | server_side/app.js | 18319 | 'use strict';
const crypto = require('crypto');
const utils = require('./utils.js');
const $ = require('jquery');
const alerts = require('./alerts');
const bitcoin = require('multicoinjs-lib');
exports.EncodeWallet = function(password)
{
var jsonSavedKeyPairs = utils.getItem("KeyPairs").value || {};
if ... | mit |
eablack/code-corps-ember | app/components/navigation-menu.js | 696 | import Ember from 'ember';
const { service } = Ember.inject;
/**
`navigation-menu` composes the top navigation-menu.
## default usage
```handlebars
{{navigation-menu}}
```
@class navigation-menu
@module Component
@extends Ember.Component
*/
export default Ember.Component.extend({
classNames: ['m... | mit |
shreyaspotnis/gpe3d_mpi_nlt | python/gpe3d_mpi_nlt/__init__.py | 159 | from simulator import Simulator
from simulator import load_sim_from_file, load_sim_from_folder
from simulator import write_submission_script, get_ex_vals_dict
| mit |
turingstudio/clockpuncher | lib/clockpuncher/services/harvest/requests/task_assignment_request.rb | 310 | module Clockpuncher
module Harvest
class TaskAssignmentRequest < Request
property :project_id, :required => true
property :task_assignment_id, :required => true, :from => :id
def path
"/projects/#{project_id}/task_assignments/#{task_assignment_id}"
end
end
end
end
| mit |
Opeey/python-sudoku-buddy | cython/setup.py | 227 | from distutils.core import setup
from distutils.extension import Extension
from Cython.Distutils import build_ext
ext = Extension("sFunc", sources=["sFunc.pyx"])
setup(ext_modules=[ext],
cmdclass={'build_ext': build_ext}) | mit |
zidad/Umbraco-CMS | src/Umbraco.Core/Services/IContentTypeService.cs | 7513 | using System.Collections.Generic;
using System.Xml.Linq;
using Umbraco.Core.Models;
namespace Umbraco.Core.Services
{
/// <summary>
/// Defines the ContentTypeService, which is an easy access to operations involving <see cref="IContentType"/>
/// </summary>
public interface IContentTypeService... | mit |
anehx/anonboard-frontend | tests/unit/models/thread-test.js | 256 | import { moduleForModel, test } from 'ember-qunit'
moduleForModel('thread', 'Unit | Model | thread', {
needs: [ 'model:user', 'model:comment', 'model:topic' ]
})
test('it exists', function(assert) {
let model = this.subject()
assert.ok(!!model)
})
| mit |
chinafzy/qcloudapi | qcloudapi-base/src/main/java/org/wtb/qcloudapi/base/QcloudApiConf.java | 3446 | package org.wtb.qcloudapi.base;
import java.io.UnsupportedEncodingException;
import java.net.URLEncoder;
import java.util.Map;
import java.util.Random;
import org.wtb.qcloudapi.base.util.Args;
import org.wtb.qcloudapi.base.util.ChainMap;
import org.wtb.qcloudapi.base.util.QcloudSigners;
/**
* (ThreadSafe)QQ云平台客户端AP... | mit |
squix78/extraleague | src/main/java/ch/squix/extraleague/model/playermarket/MeetingPointPlayer.java | 465 | package ch.squix.extraleague.model.playermarket;
import java.util.Date;
import lombok.Data;
import com.googlecode.objectify.annotation.Cache;
import com.googlecode.objectify.annotation.Entity;
import com.googlecode.objectify.annotation.Id;
import com.googlecode.objectify.annotation.Index;
@Entity
@Cache
@Data
publi... | mit |
jgauna/MarionetteLte | public/js/app/views/WelcomeView.js | 480 | define(['App', 'marionette', 'models/Model', 'text!templates/welcome.html'],
function(App, Marionette, Model, template) {
//ItemView provides some default rendering logic
return Marionette.ItemView.extend({
//Template HTML string
template: _.template(template),
mo... | mit |
thomas07vt/zk_client | lib/zk_client/version.rb | 40 | module ZkClient
VERSION = "0.5.3"
end
| mit |
spryker/demoshop | src/Orm/Zed/Product/Persistence/SpyProductAbstractStoreQuery.php | 724 | <?php
/**
* This file is part of the Spryker Demoshop.
* For full license information, please view the LICENSE file that was distributed with this source code.
*/
namespace Orm\Zed\Product\Persistence;
use Spryker\Zed\Product\Persistence\Propel\AbstractSpyProductAbstractStoreQuery as BaseSpyProductAbstractStoreQu... | mit |
emadrange/symfony3wa | src/Troiswa/BackBundle/Validator/AntigrosmotsValidator.php | 1256 | <?php
/**
* Created by PhpStorm.
* User: wap75
* Date: 16/07/15
* Time: 11:01
*/
namespace Troiswa\BackBundle\Validator;
use Symfony\Component\Validator\Constraint;
use Symfony\Component\Validator\ConstraintValidator;
class AntigrosmotsValidator extends ConstraintValidator
{
public function validate($value,... | mit |
valtech/valtech-contactsync-android | app/src/main/java/com/valtech/contactsync/api/BinaryResponse.java | 177 | package com.valtech.contactsync.api;
import java.io.ByteArrayOutputStream;
public class BinaryResponse {
public ByteArrayOutputStream data;
public String lastModified;
}
| mit |
zjutjsj1004/third | boost/libs/intrusive/test/parent_from_member_test.cpp | 7836 | /////////////////////////////////////////////////////////////////////////////
//
// (C) Copyright Ion Gaztanaga 2014-2014
//
// Distributed under the Boost Software License, Version 1.0.
// (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
//
// See http://w... | mit |
NFQakademija-4grupe/basketplanner | src/BasketPlanner/TeamBundle/Controller/TeamController.php | 9295 | <?php
namespace BasketPlanner\TeamBundle\Controller;
use BasketPlanner\TeamBundle\Entity\TeamUser;
use BasketPlanner\TeamBundle\Form\TeamType;
use BasketPlanner\TeamBundle\Form\InviteType;
use BasketPlanner\TeamBundle\Entity\Team;
use BasketPlanner\TeamBundle\Entity\Invite;
use BasketPlanner\UserBundle\Entity\User;
u... | mit |
giorgiosaud/politicatheme | resources/assets/js/calendar-zonapro.js | 5279 | (function( $ ){
function obtenerTablaDeDias(m,y){
var actualDay=1,
firstDay=new Date(y,m,1).getDay(),
NumberDayOfWeek=0,
tablaDias='<table><tr>',
daysPerMonth=[31, (((y%4===0)&&(y%100!==0))||(y%400===0)) ? 29 : 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31];
while(actualDay<=daysPerMonth[m]){
var actualDay2... | mit |
jeffer16/virtualstereo | Views/dashboard/agregar.php | 13 | agregar dash
| mit |
briansw/brb | app/controllers/admin/concerns/taggings.rb | 358 | module Admin::Concerns::Taggings
extend ActiveSupport::Concern
def tags
scope = params[:scope].try(:to_sym) || :tags
@tags = resource_class
.tag_counts_on(scope)
.order(:name)
if params[:query].present?
@tags = @tags.where('name like ?', "%#{params[:query]}%")
end
... | mit |
chintan21191/vlb | application/modules/test/controllers/admin/test.php | 1711 | <?php (defined('BASEPATH')) OR exit('No direct script access allowed');
/**
* CMS Canvas
*
* @author Mark Price
* @copyright Copyright (c) 2012
* @license MIT License
* @link http://cmscanvas.com
*/
class test extends Admin_Controller
{
function __construct()
{
parent::__constr... | mit |
michaelhabeck/isdhic | tests/compare_with_isd2.py | 1359 | from isdhic.core import take_time
from isdhic.chromosome import ChromosomeSimulation
import compare_with_isd as compare
## generate posterior with isd
isd_posterior, contacts = compare.create_isd_posterior()
beadsize = isd_posterior.likelihoods['backbone'].data.values[0]
## create isdhic posterior
n_particles = l... | mit |
bartlomiejwolk/Health | DamageComponent/Editor/DamageEditor.cs | 2289 | // Copyright (c) 2015 Bartlomiej Wolk (bartlomiejwolk@gmail.com)
//
// This file is part of the Health extension for Unity. Licensed under the MIT
// license. See LICENSE file in the project root folder.
using UnityEditor;
using UnityEngine;
namespace HealthEx.DamageComponent {
[CustomEditor(typeof (Damage))]
... | mit |
zhoujiagen/giant-data-analysis | data-pipeline/infrastructure-track/src/test/java/com/spike/giantdataanalysis/track/htrace/MockingWorker.java | 1003 | package com.spike.giantdataanalysis.track.htrace;
import java.util.Date;
import java.util.Random;
import java.util.concurrent.Callable;
import org.apache.htrace.core.TraceScope;
import org.apache.htrace.core.Tracer;
class MockingWorker implements Callable<String> {
final Tracer tracer;
private final String inpu... | mit |
mikekelly/blue_bank | lib/blue_bank/customer.rb | 469 | module BlueBank
class Customer
def initialize(client:)
@client = client
end
def id
json.fetch("id")
end
def given_name
json.fetch("givenName")
end
def accounts
@accounts ||= AccountList.new(customer: self, client: client)
end
def current_account
ac... | mit |
yozi-developer/telegraph | tests/src/server/tests.js | 964 | 'use strict';
/*
global after: true, afterEach: true, before: true, beforeEach, it: true, describe: true, process: true
*/
import {WsTgClient} from '../../../lib/client';
import {WsTgServer} from '../../../lib/server';
import should from 'should';
const port = process.env.PORT || 3000;
export function runTests() {... | mit |
AlejandroMorales92/Ingressum | controller/class.obtenerRepPorFechaController.php | 984 | <?php
class obtenerRepPorFecha extends controllerExtended {
public function main(\request $request) {
try {
$this->loadTablecontrol();
$controlDAO = new controlDAOExt($this->getConfig());
$respuesta1 = $controlDAO->reportePorFecha($request->getParam('fechaInicial'), $request->getParam('fechaF... | mit |
mathiasbynens/unicode-data | 6.3.0/blocks/Emoticons-code-points.js | 868 | // All code points in the Emoticons block as per Unicode v6.3.0:
[
0x1F600,
0x1F601,
0x1F602,
0x1F603,
0x1F604,
0x1F605,
0x1F606,
0x1F607,
0x1F608,
0x1F609,
0x1F60A,
0x1F60B,
0x1F60C,
0x1F60D,
0x1F60E,
0x1F60F,
0x1F610,
0x1F611,
0x1F612,
0x1F613,
0x1F614,
0x1F615,
0x1F616,
0x1F617,
0x1F618,
0x... | mit |
jugalkishor-sujal/snowWhiteClient | src/common/plunker.js | 2111 | angular.module('snowWhite.plunker', [])
.factory('plunkGenerator', function ($document) {
return function (ngVersion, bsVersion, version, module, content) {
var form = angular.element('<form style="display: none;" method="post" action="http://plnkr.co/edit/?p=preview" target="_blank"></form>');
var... | mit |
michaelblumenthal/RP2-Downpour2.0- | WebVote/Controllers/ManageController.cs | 14061 | using System;
using System.Linq;
using System.Threading.Tasks;
using System.Web;
using System.Web.Mvc;
using Microsoft.AspNet.Identity;
using Microsoft.AspNet.Identity.Owin;
using Microsoft.Owin.Security;
using WebVote.Models;
namespace WebVote.Controllers
{
[Authorize]
public class ManageController : Control... | mit |
Cemal96/test_task_frontend | src/app/models/offer.ts | 63 | export class Offer {
constructor(public price: number) { }
}
| mit |
luciusgone/roda-contrib | lib/roda/contrib/plugins/csrf.rb | 1630 | require 'rack/csrf'
module RodaContrib
module Plugins
# The contrib_csrf plugin is a bit different from offical csrf plugin. It
# offers only one instance methods instead of five. It is just my personal
# flavor.
#
# You can use it like this:
# # in the routing tree
# csrf.field ... | mit |
pothibo/observejs | lib/observejs/railtie.rb | 290 | module ObserveJS
class Railtie < Rails::Railtie
initializer 'observejs.assets.paths', before: :add_view_paths do |app|
app.paths['vendor/assets'] << File.dirname(__FILE__) + '/app/assets/'
app.paths['app/views'] << File.dirname(__FILE__) + '/app/views/'
end
end
end
| mit |
leonardosalles/enzo | static/js/directives/inputDigits.js | 1173 | define(['directives/directives'], function (directives) {
'use strict';
directives.directive('enzoInputDigits', function () {
return {
restrict: 'A',
require: 'ngModel',
link: function (scope, element, attr, ctrl) {
element.setMask({mask: '9', type: 'repeat', autoTab: false});
ctrl.$formatters... | mit |
Codifico/phpspec-rest-view-extension | spec/Codifico/PhpSpec/RestViewExtension/Serializer/PropertyMetadataFakeSpec.php | 561 | <?php
namespace spec\Codifico\PhpSpec\RestViewExtension\Serializer;
use Codifico\PhpSpec\RestViewExtension\Serializer\PropertyMetadataFake;
use JMS\Serializer\Metadata\PropertyMetadata;
use PhpSpec\ObjectBehavior;
use Prophecy\Argument;
/**
* @mixin PropertyMetadataFake
*/
class PropertyMetadataFakeSpec extends Ob... | mit |
ABTSoftware/SciChart.WPF.Examples | v4.x/Examples/SciChart.Examples.ExternalDependencies/Common/SciChartPolarInteractionToolbar.cs | 2167 | // *************************************************************************************
// SCICHART® Copyright SciChart Ltd. 2011-2017. All rights reserved.
//
// Web: http://www.scichart.com
// Support: support@scichart.com
// Sales: sales@scichart.com
//
// SciChartPolarInteractionToolbar.cs is part of SCIC... | mit |
iansoftdev/all-blockchain | src/test/java/io/iansoft/blockchain/web/rest/errors/ExceptionTranslatorIT.java | 5528 | package io.iansoft.blockchain.web.rest.errors;
import io.iansoft.blockchain.BlockchainApp;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.h... | mit |
limpoxe/Android-Plugin-Framework | Samples/PluginTest/src/main/java/com/example/plugintest/manymethods/j/c/A5.java | 8249 | package com.example.plugintest.manymethods.j.c;
public class A5 {
public static void a0(String msg) { System.out.println("msg=" + msg + 0); }
public static void a1(String msg) { System.out.println("msg=" + msg + 1); }
public static void a2(String msg) { System.out.println("msg=" + msg + 2); }
public st... | mit |
strues/TopShelf | src/server/api/raid/index.js | 679 | import express from 'express';
var controller = require('./raid.controller');
//var auth = require('../../auth/auth.service');
var router = express.Router();
router.get('/', controller.find);
router.get('/all', controller.find);
router.post('/', controller.create);
router.put('/', controller.update);
router.patch('/... | mit |
joefearnley/wyw-api | database/migrations/2017_02_14_030908_create_users_table.php | 760 | <?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class CreateUsersTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('users', function (B... | mit |
dotmailer/dotmailer-magento-extension | code/Dotdigitalgroup/Email/Block/Wishlist.php | 1178 | <?php
class Dotdigitalgroup_Email_Block_Wishlist
extends Dotdigitalgroup_Email_Block_Edc
{
/**
* @var
*/
public $website;
/**
* @return bool|Mage_Wishlist_Model_Mysql4_Item_Collection
*/
public function getWishlistItems()
{
$wishlist = $this->_getWishlist();
... | mit |
amcintosh/PushOverflow | tests/test_stackexchange.py | 2548 | import configparser
import datetime
import unittest
from unittest.mock import patch
import httpretty
from pushoverflow import cli
class StackExchangeTests(unittest.TestCase):
@patch("pushoverflow.cli.filter_questions")
@patch("pushoverflow.cli.get_stack_exchange_questions")
def test_check_exchange(self,... | mit |
tomorrow-lauren/phase-0 | week-6/attr/release_4.rb | 1384 | # Release 3:
class Profile
# here is the change, we combined the attr_writer and attr_reader into one declaration: attr_accessor
attr_accessor :age, :name, :occupation
def initialize
@age = 27
@name = "Kim"
@occupation = "Cartographer"
end
def print_info
puts
puts "age: #{@age}"
puts
... | mit |
VaskoViktorov/SoftUni-Homework | 10. C# Web Development Basics - 19.09.2017/05. HTTP Protocol - Lab/02. Validate URL/02. Validate URL/StartUp.cs | 1539 | namespace _02._Validate_URL
{
using System;
using System.Net;
public class StartUp
{
public static void Main()
{
string url = Console.ReadLine();
string decodedUrl = WebUtility.HtmlDecode(url);
try
{
Uri uri = new Uri(decod... | mit |
geomorillo/framework | app/Config/Session.php | 871 | <?php
/**
* Session Configuration.
*
* @author Virgil-Adrian Teaca - virgil@giulianaeassociati.com
* @version 3.0
*/
use Core\Config;
Config::set('session', array(
'handler' => '\Session\FileSessionHandler', // The default Session Handler, using files for Session cache.
// Storage configuration.
'l... | mit |
gumgl/java | Paint/src/ca/qc/johnabbott/cs603/asg3/shapes/Rectangle.java | 1194 | package ca.qc.johnabbott.cs603.asg3.shapes;
import android.graphics.Canvas;
import android.graphics.Color;
import android.graphics.Paint;
import android.graphics.Paint.Style;
public class Rectangle extends Shape {
private float x1, y1, x2, y2;
public Rectangle(float x1, float y1, float x2, float y2, int strokeCo... | mit |
berkayoktem/Hackerrank | Algorithms/C#/Implementation/1-Grading Students.cs | 1829 | using System.CodeDom.Compiler;
using System.Collections.Generic;
using System.Collections;
using System.ComponentModel;
using System.Diagnostics.CodeAnalysis;
using System.Globalization;
using System.IO;
using System.Linq;
using System.Reflection;
using System.Runtime.Serialization;
using System.Text.RegularExpressions... | mit |
tonysneed/GK.AspNetCore.v1.Demos | Demos/09_EF_Core/09b_Repositories_Queries/RepositoriesQueries/Startup.cs | 1639 | using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Hosting;
using Microsoft.EntityFrameworkCore;
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Logging;
using RepositoriesQueries.Contexts;
using RepositoriesQueries.Repositories;
namespa... | mit |
conanb/syntax | samples/UnitTest/utilities.cpp | 12290 | #include "utilities.h"
#include <gl_core_4_4.h>
#include <GLFW/glfw3.h>
#include <imgui.h>
#undef APIENTRY
#define GLFW_EXPOSE_NATIVE_WIN32
#define GLFW_EXPOSE_NATIVE_WGL
#include <GLFW/glfw3native.h>
struct imguiData {
GLFWwindow* m_window = nullptr;
double m_time = 0.0f;
bool m_mousePressed[3];// = { false, ... | mit |
kaizer04/Telerik-Academy-2013-2014 | ASP.NET WebForms/LibrarySystem/LibrarySystem/Search.aspx.cs | 1141 | using LibrarySystem.Models;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.ModelBinding;
using System.Web.UI;
using System.Web.UI.WebControls;
namespace LibrarySystem
{
public partial class Search : System.Web.UI.Page
{
public LibraryDbContext dbC... | mit |
nicoribeiro/java_efactura_uy | app/dgi/soap/consultas/ConsultaRespuestaReporte.java | 1303 |
package dgi.soap.consultas;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlType;
/**
* <p>Java class for ConsultaRespuestaReporte complex type.
*
* <p>The following schema fragment... | mit |
way2muchnoise/refinedstorage | src/main/java/com/raoulvdberge/refinedstorage/apiimpl/network/NetworkNodeListener.java | 3263 | package com.raoulvdberge.refinedstorage.apiimpl.network;
import com.raoulvdberge.refinedstorage.api.network.node.INetworkNode;
import com.raoulvdberge.refinedstorage.api.network.node.INetworkNodeProxy;
import com.raoulvdberge.refinedstorage.api.network.security.Permission;
import com.raoulvdberge.refinedstorage.apiimp... | mit |
vocxod/wega | rb.php | 260714 | <?php
namespace RedBeanPHP {
/**
* RedBean Logging interface.
* Provides a uniform and convenient logging
* interface throughout RedBeanPHP.
*
* @file RedBean/Logging.php
* @desc Logging interface for RedBeanPHP ORM
* @author Gabor de Mooij and the RedBeanPHP Community
* @license BSD/GPLv2
*
* copyr... | mit |
ifedu/generator-speedseed-multi-tic-tac-toe | seed/template/framework/angular2/all/root/src/views/game/components/table/box/box.component.ts | 384 | import { Component } from '@angular/core'
@Component({
selector: 'ss-box',
styles: [require('./box.style')],
template: require('./box'),
})
export class SSBoxComponent {
static xo = ''
xo: any
push() {
if (this.xo !== undefined) return
SSBoxComponent.xo = (SSBoxComponent.xo =... | mit |
drmikecrowe/loopback-angular-admin | client/app/modules/events/controllers/events.ctrl.js | 4309 | /*jshint sub:true*/
'use strict';
angular.module('com.module.events')
.controller('EventsCtrl', function ($scope, $state, $stateParams, CoreService,
Event, gettextCatalog) {
var eventId = $stateParams.id;
var createDate = function (date, time) {
console.log(date)... | mit |
CS2103AUG2016-T09-C4/main | src/test/java/guitests/ClearCommandTest.java | 978 | package guitests;
import org.junit.Test;
import seedu.unburden.commons.exceptions.IllegalValueException;
import static org.junit.Assert.assertTrue;
public class ClearCommandTest extends ListOfTaskGuiTest {
//@Test
public void clear() throws IllegalValueException {
//verify a non-empty list can be ... | mit |
spazzarama/Direct3D-Rendering-Cookbook | Ch11_01HelloCoreWindow/Vertex.cs | 4555 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Runtime.InteropServices;
using SharpDX;
namespace Ch11_01HelloCoreWindow
{
/// <summary>
/// Vertex input structure: Position, Normal and Color
/// </summary>
[StructLayout... | mit |
nika-m/di_fminator | spec/support/devise.rb | 146 | RSpec.configure do |config|
config.include Devise::TestHelpers, :type => :controller
config.extend ControllerHelpers, :type => :controller
end | mit |
cleverage/process-bundle | Filesystem/FileStreamInterface.php | 1052 | <?php declare(strict_types=1);
/*
* This file is part of the CleverAge/ProcessBundle package.
*
* Copyright (C) 2017-2019 Clever-Age
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace CleverAge\ProcessBundle\Filesystem;
/*... | mit |
wavebeem/weather-diff | src/app/main.js | 452 | require('whatwg-fetch'); // polyfill fetch
const React = require('react');
const ReactDOM = require('react-dom');
const ReactRedux = require('react-redux');
const store = require('./store').store;
const WeatherDiff = require('./weather-diff').WeatherDiff;
const R = React.createElement;
const root = document.getElemen... | mit |
pimenta53/AgroMarket | spec/views/admin/cities/index.html.erb_spec.rb | 328 | require 'spec_helper'
describe "admin/cities/index" do
before(:each) do
assign(:admin_cities, [
stub_model(Admin::City),
stub_model(Admin::City)
])
end
it "renders a list of admin/cities" do
render
# Run the generator again with the --webrat flag if you want to use webrat matchers
... | mit |
camsys/transam_audit | spec/models/audit_result_spec.rb | 1598 | require 'rails_helper'
RSpec.describe AuditResult, :type => :model do
let(:test_subtype) { create(:asset_subtype)}
let(:test_parent_policy) { create(:parent_policy, type: test_subtype.asset_type_id, subtype: test_subtype.id) }
let(:test_policy) { create(:policy, organization: test_parent_policy.organization, pa... | mit |
ardhi95/pltrans | application/views/front_end/html/V_homeslide.php | 1640 | <div class="banner-section">
<section class="slider">
<div class="flexslider">
<ul class="slides">
<?php
$data = $this->db->query("SELECT * FROM slider")->result();
foreach ($data as $key) {
?>
<li>
<div class="slider-info">
<img src="<?=base_url()?>uploads/<?php echo... | mit |
supertreeteam/supertree-auth | app/initializers/i18n.js | 60 | export { default } from 'supertree-auth/initializers/i18n';
| mit |
mlanett/commotion | lib/commotion/version.rb | 41 | module Commotion
VERSION = "0.0.1"
end
| mit |
EspecializacaoMobileIFSP/Mensageiro | Mensageiro/app/src/main/java/br/edu/ifspsaocarlos/mensageiro/ui/MainActivity.java | 3773 | package br.edu.ifspsaocarlos.mensageiro.ui;
import android.content.Intent;
import android.os.Bundle;
import android.support.design.widget.Snackbar;
import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentManager;
import android.support.v4.app.FragmentTransaction;
import android.support.v7.app.App... | mit |
Datamats/gm-discordlib | lua/discordlib/discordlib.lua | 9262 | --[[
Discord Library for Garry's Mod Lua by Datamats
Check the README.md and LICENSE file for more infomation.
]]
discordlib = discordlib or {meta = {}}
discordlib.__index = discordlib
discordlib.currid = discordlib.currid or 1
discordlib.endpoints = {}
discordlib.endpoints.base = "https://discordapp.com/api/v6"
di... | mit |
pavermakov/phaser-synth | src/prefabs/base/Graphics.js | 330 | import Phaser from 'phaser';
export default class extends Phaser.Graphics {
constructor(game, { x, y, inputEnabled, anchor, scale }) {
super(game, x, y);
this.inputEnabled = inputEnabled || true;
if (anchor) {
this.anchor.setTo(anchor.x, anchor.y);
}
if (scale) {
this.scale.setTo(scale.x, scale.y);... | mit |
djangothon/django-generic-file | genericfile/migrations/0001_initial.py | 778 | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
class Migration(migrations.Migration):
dependencies = [
('contenttypes', '0002_remove_content_type_name'),
]
operations = [
migrations.CreateModel(
name='FileStore',
... | mit |
krainboltgreene/time-lord | test/lib/time-lord/time_test.rb | 741 | require 'helper'
class TestTimeLordTime < TestCase
def test_to_words_past_seconds
expected = "50 seconds ago"
actual = TimeLord::Time.new(@timestamp - 50).period.to_words
assert_equal(expected, actual)
end
def test_to_words_singular
expected = "1 minute ago"
actual = TimeLord::Time.new(@tim... | mit |
adamjgrant/Mozart | docs/advanced/selection/index.js | 1624 | // OPTION 1
// ========
m.lookup.acts({
blink_green(_$, args) {
// args.element isn't the component, but if you pass this
// in, Mozart will find it.
var me = _$.me(args.element);
me.classList.add("blink");
}
});
m.lookup.acts({
blink_green(_$, args) {
var me = _$.me();
me.classList.add("... | mit |
gkonst/scriba | client/components/form/detail.controller.js | 723 | 'use strict';
angular.module('scribaApp')
.controller('ModalDetailCtrl', function ($log, $modalInstance, id, ModelFactory, initial) {
var vm = this;
if (angular.isDefined(id)) {
$log.debug('Editing', id);
vm.model = ModelFactory.get({id: id});
} else {
$log.debug('Creating new');
... | mit |
yingchn/android-viewpager-indicator | app/src/main/java/me/caiying/indicator/demo/CirclePagerActivity.java | 930 | package me.caiying.indicator.demo;
import android.os.Bundle;
import android.support.v4.app.FragmentActivity;
import android.support.v4.view.ViewPager;
import me.caiying.indicator.R;
import me.caiying.library.viewpagerindicator.CirclePagerIndicator;
/**
* Created by caiying on 06/02/2016.
*/
public class CirclePage... | mit |
EwanC/pyProc | proc_scraper/proc_mounts.py | 1558 | #!/usr/bin/env python3
from .proc_base import ProcBase
class ProcMounts(ProcBase):
'''Object represents the /proc/mounts file.'''
format_str = '{0:15} | {1:25} | {2:15} | {3}'
def __init__(self, pid):
'''
Read file by calling base class constructor
then parse the contents.
... | mit |
jgeumlek/MoltenGamepad | source/core/event_translators/axis/axis2btns.cpp | 893 | #include "axis2btns.h"
#include "../event_translator_macros.h"
void axis2btns::process(struct mg_ev ev, virtual_device* out) {
struct input_event out_ev;
memset(&out_ev, 0, sizeof(out_ev));
out_ev.type = EV_KEY;
out_ev.code = neg_btn;
out_ev.value = ev.value < -.5 * ABS_RANGE;
if (out_ev.value != neg_cache... | mit |
chintan21191/vlb | api/developments/update_user_setting.php | 2038 | <?php
/* http://192.168.1.26/vlb_design/api/index
.php?tag=usersetting&user_id=205&vlb_terms_and_conditions=0&company_terms_conditions=0&company_contract=0 */
# http://192.168.1.26/vlb_design/api/index.php?tag=general_data&last_checked_gmt_timestamp=1403852034
# Request Parameter
$user_id = $_REQUEST['user_id'];
$fir... | mit |
trln/trln_argon | spec/lib/trln_argon/search_builder/default_local_search_builder_spec.rb | 1583 | describe DefaultLocalSearchBuilder do
let(:obj) { described_class.new(CatalogController.new) }
describe 'processor chain' do
it 'adds the disable_boolean_for_all_caps method to the processor_chain' do
expect(obj.processor_chain).to include(:disable_boolean_for_all_caps)
end
it 'adds the wildcard... | mit |
ProjectOdinMakerSquare/OdinProject-OmniAuth | app/controllers/forums_controller.rb | 1521 | class ForumsController < ApplicationController
def show
@is_forum = true;
@moot_hash = generate_moot_hash
# puts "\n\n\n @moot_hash is #{@moot_hash}!! \n\n\n"
end
private
def generate_moot_hash
# Based on info from https://moot.it/docs/single-sign-on.html
return {} unless user_signed_in?... | mit |
fsmawi/aivam | fuel/app/classes/model/item.php | 2600 | <?php
class Model_Item extends \Orm\Model
{
protected static $_properties = array(
'id',
'year',
'month',
'city',
'group',
'make',
'premium_segment',
'model_gnr',
'model',
'segment',
'ckd_cbu',
'pc_cv',
'engine_type',
'type',
'displacement',
'sales',
'origine',
'body_type',
'rsp',... | mit |
codematix/pickaxe | stock_data/stock_stats.rb | 237 | require_relative 'csv_reader'
reader = CsvReader.new
ARGV.each do |csv_file_name|
STDERR.puts "Processing file #{csv_file_name}"
reader.read_in_csv_data(csv_file_name)
end
puts "Total stock value = #{reader.total_value_in_stock}"
| mit |
dmitrysmorodinnikov/FoursquareAPI | FoursquareAPI/FoursquareApi.Services/Venues/SuggestCompletionVenuesService.cs | 2269 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using FoursquareApi.Models.Venues;
using HttpClient;
using HttpClient.SerializationService;
namespace FoursquareApi.Services.Venues
{
public class SuggestCompletionVenuesService
{
privat... | mit |