repo_name stringlengths 4 116 | path stringlengths 4 379 | size stringlengths 1 7 | content stringlengths 3 1.05M | license stringclasses 15
values |
|---|---|---|---|---|
zr40/steamdisksaver | SteamDiskSaver/CategoryControl.Designer.cs | 3664 | namespace SteamDiskSaver
{
internal partial class CategoryControl
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if manag... | mit |
joemcbride/es-microservice | src/ES.Api/Startup.cs | 2399 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.InteropServices;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Authentication.JwtBearer;
using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Hosting;
using Microsoft.Extensions.Configuration;
using Microsoft.E... | mit |
idekerlab/cxio_python | cxio/element_maker.py | 12723 | from cxio.element import Element
from cxio.aspect_element import AspectElement
from cxio.cx_constants import CxConstants
class ElementMaker(object):
""" Static methods for creating (aspect) element instances.
"""
@staticmethod
def create_nodes_aspect_element(node_id, node_name=None, node_represents=N... | mit |
anonl/tcommon | core/src/main/java/nl/weeaboo/io/RandomAccessInputStream.java | 1876 | package nl.weeaboo.io;
import java.io.IOException;
import java.io.InputStream;
final class RandomAccessInputStream extends InputStream {
private final IRandomAccessFile file;
private final long offset;
private final long length;
private long read;
private long mark;
public RandomAccessInput... | mit |
GetTerminus/terminus-ui | projects/library/input/src/input.module.ts | 1377 | import { CommonModule } from '@angular/common';
import { NgModule } from '@angular/core';
import { FlexLayoutModule } from '@angular/flex-layout';
import {
FormsModule,
ReactiveFormsModule,
} from '@angular/forms';
import {
MAT_DATE_FORMATS,
NativeDateModule,
} from '@angular/material/core';
import { MatDatepic... | mit |
danprince/roguelike | tests/test.js | 453 | var should = require('should');
describe('Geometry', function() {
require('./container.spec.js');
// require('./rectangle.spec.js');
});
describe('Other', function() {
require('./bsp.spec.js');
require('./space.spec.js');
require('./util.spec.js');
// require('./walkable.spec.js');
});
describe('Dungeon'... | mit |
cryptofun/honey | src/wallet.cpp | 83007 | // Copyright (c) 2009-2010 Satoshi Nakamoto
// Copyright (c) 2009-2012 The Bitcoin developers
// Distributed under the MIT/X11 software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "wallet.h"
#include "arith_uint256.h"
#include "base58.h"
#include "coin... | mit |
uq-eresearch/dataspace | data-registry-webapp/src/main/java/net/metadata/dataspace/data/model/record/Collection.java | 1656 | package net.metadata.dataspace.data.model.record;
import java.util.HashSet;
import java.util.Set;
import javax.persistence.CascadeType;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.JoinTable;
import javax.persistence.OneToMany;
import net.metadata.dataspace.data.model.... | mit |
github/codeql | python/ql/test/library-tests/PointsTo/imports/package/x.py | 19 |
from sys import *
| mit |
BryanDonovan/node-simple-elasticsearch | test/support/random.js | 626 | var random = {
number: function (range) {
range = range || 10000;
return Math.floor(Math.random() * range);
},
string: function (str_len) {
str_len = str_len || 8;
var chars = "abcdefghiklmnopqrstuvwxyz";
var random_str = '';
for (var i = 0; i < str_len; i++)... | mit |
leedm777/cls-bcrypt | index.js | 841 | // Copyright (c) 2015. David M. Lee, II
'use strict';
var shimmer = require('shimmer');
var bcrypt = require('bcrypt');
module.exports = function(ns) {
shimmer.wrap(bcrypt, 'genSalt', function(genSalt) {
return function(rounds, cb) {
// rounds is optional
if (typeof rounds === 'function') {
... | mit |
haddada/Project | app/cache/dev/twig/1a/2d/dc76af4f75e39955753562e74a50fb2b437ac5e1af6693fd542d6930a298.php | 2402 | <?php
/* base.html.twig */
class __TwigTemplate_1a2ddc76af4f75e39955753562e74a50fb2b437ac5e1af6693fd542d6930a298 extends Twig_Template
{
public function __construct(Twig_Environment $env)
{
parent::__construct($env);
$this->parent = false;
$this->blocks = array(
'title' =>... | mit |
ddpro/admin | src/DataTable/DataTable.php | 20089 | <?php
namespace DDPro\Admin\DataTable;
use Cartalyst\Sentinel\Laravel\Facades\Sentinel;
use DDPro\Admin\Config\ConfigInterface;
use DDPro\Admin\DataTable\Columns\Column;
use DDPro\Admin\DataTable\Columns\Factory as ColumnFactory;
use DDPro\Admin\Fields\Factory as FieldFactory;
use DDPro\Admin\Helpers\DateTimeHelper;
u... | mit |
mrwrob/netfweb | netfweb/content.js | 18984 | // Runs background script to aquire score from FilmWeb. Adds SPAN and fullfill it with data from storage.
/**
* Send message to background.js to report the correctness of links to rating websites.
* @param {string} idNetflix - title's netflix ID
* @param {boolean} ok - true the link correct, otherwise false
* @par... | mit |
maland/orders_tracker | lib/orders_tracker/version.rb | 45 | module OrdersTracker
VERSION = "0.0.1"
end
| mit |
ajames72/MovieDBReact | src/components/search/movies/MoviePage.test.js | 1223 | import React from 'react';
import { Provider } from 'react-redux';
import configureStore from 'redux-mock-store';
import thunk from 'redux-thunk';
import expect from 'expect';
import { mount } from 'enzyme';
import MoviePage from './MoviePage';
import * as TestData from '../../../../test/TestData';
describe('MoviePage... | mit |
Sunderous/lupine | modules/brewing/server/controllers/brewing.server.controller.js | 2480 | 'use strict';
/**
* Module dependencies
*/
var path = require('path'),
mongoose = require('mongoose'),
Sensor = mongoose.model('Sensor'),
errorHandler = require(path.resolve('./modules/core/server/controllers/errors.server.controller'));
/**
* Create a sensor
*/
exports.create = function(req, res) {
... | mit |
iefserge/eshttp | test/index.js | 174 | 'use strict';
require('../lib/backend').setBackend(require('../backend/backend-node'));
require('./headers');
require('./parser');
require('./request');
require('./server');
| mit |
jiunjiun/redesign | app/controllers/projects/editors_controller.rb | 503 | class Projects::EditorsController < Projects::AccessController
before_action :set_project
before_action :project_data
def index
end
def update
redirect_to project_path(params[:username], params[:project_name]) if @project.update(project_params)
end
private
def set_project
@project = Proje... | mit |
madvas/node-randombase64 | lib/randombase64.js | 1884 | var Canvas = require('canvas');
function getRandomArbitrary(min, max) {
return Math.floor(Math.random() * (max - min + 1) + min);
}
exports.generate = function(options, callback) {
var canvas = new Canvas()
, ctx = canvas.getContext('2d')
, x, y
, unitSize
, opacity
, width, height
, getRg... | mit |
sikuli/sikuli-slides | jruby/lib/sikuli-slides/exception.rb | 64 | module Sikuli
class TargetNotFound < StandardError
end
end | mit |
royriojas/mac-scripts | scripts/app.py | 1402 | #!/usr/bin/env python
#
# simle'n'stupid vhost "parser"
#
# Usage: ./vhosts-reader.py FILE
# FILE is a apache config file
import re
import sys
import os.path
if len(sys.argv) != 2:
sys.exit('Usage: %s FILE' % sys.argv[0])
FILE = sys.argv[1]
if not os.path.isfile(FILE):
sys.exit('Unknown file %s' % FILE)
... | mit |
CoderAllan/SqlServerSearcher | src/Model/EventArgs/BaseFormEventArgs.cs | 287 | namespace SQLServerSearcher.Model.EventArgs
{
using System;
using System.Drawing;
public class BaseFormEventArgs : EventArgs
{
public int Width { get; set; }
public int Height { get; set; }
public Point Location { get; set; }
}
}
| mit |
ModusCreateOrg/budgeting-sample-app-webpack2 | app/components/Field/index.js | 2633 | // @flow
import * as React from 'react';
import isObject from 'utils/isObject';
import consumeContextBroadcast from 'utils/consumeContextBroadcast';
import type { FormData } from 'components/Form';
type FieldProps = {
component?: React.ElementType,
name: string,
handleRef?: (ref: ?React.ElementRef<any>) => void,... | mit |
fabrikagency/auto_html | test/fixtures/schema.rb | 316 | ActiveRecord::Schema.define do
create_table "articles", :force => true do |t|
t.column "title", :string
t.column "body", :text
t.column "body_html", :text
t.column "body_htmlized", :text
t.column "created_at", :datetime
t.column "updated_at", :datetime
end
end
| mit |
jeremykenedy/laravel_frozennode_cms | app/views/admin/elements/forms/login/login-form6.blade.php | 2023 | <style type="text/css">
body{
background: url(http://mymaplist.com/img/parallax/back.png);
background-color: #444;
background: url(http://mymaplist.com/img/parallax/pinlayer2.png),url(http://mymaplist.com/img/parallax/pinlayer1.png),url(http://mymaplist.com/img/parallax/back.png);
}
.vertical-offset-100{... | mit |
musicmunky/publify-core | app/models/post_type.rb | 368 | # coding: utf-8
class PostType < ActiveRecord::Base
validates :name, uniqueness: true
validates :name, presence: true
validate :name_is_not_read
before_save :sanitize_title
def name_is_not_read
errors.add(:name, I18n.t('errors.article_type_already_exist')) if name == 'read'
end
def sanitize_title
... | mit |
okunishinishi/kurokawa | routes/validations/serverside.js | 1790 | /**
* serverside validation
* @param clientside
* @param validations
*/
var tek = require('tek'),
define = tek['meta']['define'],
JobQueue = tek['JobQueue'];
exports = module.exports = define({
init: function () {
var s = this;
s._asyncConforms = {};
},
attrAccessor: 'clientside... | mit |
KyleCe/MyTestApplication | app/src/main/java/com/ce/game/myapplication/view/ShowcasePinCode.java | 3704 | package com.ce.game.myapplication.view;
import android.content.Context;
import android.text.TextUtils;
import android.util.AttributeSet;
import android.widget.FrameLayout;
import android.widget.ImageView;
import com.ce.game.myapplication.R;
import java.util.ArrayList;
import java.util.List;
/**
* Created by KyleCe... | mit |
Aney44/test_mgg | src/Rest/UsersBundle/Exception/InvalidFormException.php | 372 | <?php
namespace Rest\UsersBundle\Exception;
class InvalidFormException extends \RuntimeException
{
protected $form;
public function __construct($message, $form = null)
{
parent::__construct($message);
$this->form = $form;
}
/**
* @return array|null
*/
public function... | mit |
valentinivanov/swisstalk | code/Platform/Unity3d/DI/Prefabs/PrefabDIFactoryBuilderExtensions.cs | 382 | using System;
using Swisstalk.DI;
namespace Swisstalk.Platform.Unity3d.DI.Prefabs
{
public static class PrefabDIFactoryBuilderExtensions
{
public static DICollectionBuilder ForComponentInPrefab<T>(this PrefabDIFactoryBuilder builder, string prefabKey)
{
return builder.ForKey(new Pr... | mit |
hajerk/jci.com | app/cache/dev/twig/52/d3/6a600aeabb8ad00d1e1b88c63584f53a88f126bdff0b8171f1037e420409.php | 6444 | <?php
/* @WebProfiler/Profiler/toolbar_js.html.twig */
class __TwigTemplate_52d36a600aeabb8ad00d1e1b88c63584f53a88f126bdff0b8171f1037e420409 extends Twig_Template
{
public function __construct(Twig_Environment $env)
{
parent::__construct($env);
$this->parent = false;
$this->blocks = a... | mit |
jollopre/mps | ui/src/components/customers/inputText.js | 1254 | import React, { Component } from 'react';
import PropTypes from 'prop-types';
import { debounce } from '../../utils/debounce';
export default class InputText extends Component {
constructor(props) {
super(props);
this.onChangeHandler = this.onChangeHandler.bind(this);
this.state = { value: this.props.val... | mit |
dapplo/Dapplo.Log | src/Dapplo.Log/ILoggerConfiguration.cs | 1336 | // Copyright (c) Dapplo and contributors. All rights reserved.
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
using System.ComponentModel;
namespace Dapplo.Log
{
/// <summary>
/// Interface for the LoggerConfiguration
/// </summary>
... | mit |
trshafer/angular | packages/compiler-cli/src/ngcc/src/host/decorated_file.ts | 588 | /**
* @license
* Copyright Google Inc. All Rights Reserved.
*
* Use of this source code is governed by an MIT-style license that can be
* found in the LICENSE file at https://angular.io/license
*/
import * as ts from 'typescript';
import {DecoratedClass} from './decorated_class';
/**
* Information about a sour... | mit |
ExilantTechnologies/ExilityCore-5.0.0 | data/com/exilant/exility/core/DataGroup.java | 2008 | /* *******************************************************************************************************
Copyright (c) 2015 EXILANT Technologies Private Limited
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
i... | mit |
Jovtcho/JavaFundamentals | JavaOOP Advanced/Exam2017-05-12-Cresla/main/java/cresla/Main.java | 912 | package cresla;
import cresla.core.ManagerImpl;
import cresla.engine.Engine;
import cresla.entities.IdentifiableImpl;
import cresla.interfaces.*;
import cresla.io.ConsoleInputReader;
import cresla.io.ConsoleOutputWriter;
import cresla.repository.ReactorRepository;
import java.io.BufferedReader;
import java.io.InputSt... | mit |
atomic-labs/mixpanel-cli | setup.py | 511 | #!/usr/bin/env python
from setuptools import setup
from pip.req import parse_requirements
install_reqs = parse_requirements("REQUIREMENTS.txt")
reqs = [str(ir.req) for ir in install_reqs]
setup(
name = "mixpanel-cli",
version = "0.1.0",
author = "Atomic Labs, LLC",
author_email = "ops@atomicmgmt.com",... | mit |
mongodb/mongoid | spec/support/models/writer.rb | 233 | # frozen_string_literal: true
class Writer
include Mongoid::Document
field :speed, type: Integer, default: 0
embedded_in :canvas
def write; end
end
require "support/models/pdf_writer"
require "support/models/html_writer"
| mit |
Airtnp/SuperNaiveCppLib | src/sn_TypeTraits/type_traits_addon.hpp | 5699 | #ifndef SN_TYPETRAITS_TYPE_TRAITS
#define SN_TYPETRAITS_TYPE_TRAITS
#include "../sn_CommonHeader.h"
namespace sn_TypeTraits {
template <bool v>
struct bool_constant_dispatch {
using type = std::true_type;
};
template <>
struct bool_constant_dispatch<false> {
using type = std::false_type;
};
template <bo... | mit |
my-zhang/courses | nwu-eecs-339-db/btree-lab/btree_ds.cc | 7019 | #include <new>
#include <iostream>
#include <assert.h>
#include <string.h>
#include "btree_ds.h"
#include "buffercache.h"
#include "btree.h"
using namespace std;
SIZE_T NodeMetadata::GetNumDataBytes() const
{
SIZE_T n=blocksize-sizeof(*this);
return n;
}
SIZE_T NodeMetadata::GetNumSlotsAsInterior() const
{
... | mit |
iguanatool/iguana | src/main/java/org/iguanatool/testobject/structure/ConnectedNode.java | 1502 | package org.iguanatool.testobject.structure;
import java.io.Serializable;
public class ConnectedNode implements Comparable<ConnectedNode>, Serializable {
private static final long serialVersionUID = -4327291223748021793L;
public CFGNode node;
public Boolean edge;
public ConnectedNode(CFGNode node) ... | mit |
BenVuti/DataStructures | DataStructures/DataStructures/Properties/AssemblyInfo.cs | 1399 | using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("Dat... | mit |
budgetinsight/budgea-clients | BudgeaAPI.php | 12835 | <?php
/*
* MIT License
*
* Copyright (c) 2014-2020 Budget Insight
*
* 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... | mit |
MatthijsKamstra/haxejava | 04lwjgl/code/lwjgl/org/lwjgl/opengles/OESVertexArrayObject.java | 4104 | /*
* Copyright LWJGL. All rights reserved.
* License terms: http://lwjgl.org/license.php
* MACHINE GENERATED FILE, DO NOT EDIT
*/
package org.lwjgl.opengles;
import java.nio.*;
import org.lwjgl.system.*;
import static org.lwjgl.system.Checks.*;
import static org.lwjgl.system.JNI.*;
import static org.lwjgl.system... | mit |
RainerAtSpirit/hapi-plugin-djStatic | lib/index.js | 281 | exports.register = function( plugin, options, next ) {
plugin.expose('path', plugin.path);
plugin.route({
method: 'GET',
path: '/{path*}',
handler: {
directory: {
path: './public' }
}
});
next();
};
| mit |
leonardo2204/Flow1.0.0-alphaExample | app/src/main/java/leonardo2204/com/br/flowtests/presenter/NavigationPresenter.java | 358 | package leonardo2204.com.br.flowtests.presenter;
import android.support.design.widget.NavigationView;
import android.view.Menu;
import mortar.ViewPresenter;
/**
* Created by Leonardo on 18/03/2016.
*/
public class NavigationPresenter extends ViewPresenter<NavigationView> {
public Menu setupMenuItem() {
... | mit |
nailsapp/common | src/Common/Traits/Model/Nestable.php | 9796 | <?php
namespace Nails\Common\Traits\Model;
use Nails\Common\Service\Database;
use Nails\Common\Resource;
use Nails\Factory;
/**
* Trait Nestable
*
* @package Nails\Common\Traits\Model
*/
trait Nestable
{
/**
* Returns the column name for specific columns of interest
*
* @param string $sCo... | mit |
apergy/imify | client/apps/message/views/Messages.js | 419 | 'use strict';
var Marionette = require('backbone.marionette');
module.exports = Marionette.CollectionView.extend({
/**
* @type {String}
*/
className: 'messages',
/**
* @type {Marionette.ItemView}
*/
childView: require('./Message'),
/**
* Scrolls the container to the latest message
*/
o... | mit |
wtgtybhertgeghgtwtg/redux-modules | flow-typed/npm/prettier_vx.x.x.js | 2138 | // flow-typed signature: 2accf0e2123c0f379379269c7bb9a463
// flow-typed version: <<STUB>>/prettier_v^1.7.3/flow_v0.55.0
/**
* This is an autogenerated libdef stub for:
*
* 'prettier'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* c... | mit |
rahavMatan/react-phonecat | src/reducers/index.js | 243 | import { combineReducers } from 'redux';
import listReducer from './list-reducer';
import phoneReducer from './phone-reducer';
const rootReducer = combineReducers({
filtered:listReducer,
phone:phoneReducer
});
export default rootReducer;
| mit |
kiswanij/jk-util | src/main/java/com/jk/util/validation/builtin/SplitStringValidator.java | 2102 | /*
* Copyright 2002-2018 Jalal Kiswani.
* E-mail: Kiswani.Jalal@Gmail.com
*
* 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 ... | mit |
christianwade/BismNormalizer | BismNormalizer/TabularCompare/UI/SynchronizedScrollRichTextBox.cs | 1267 | using System;
using System.Windows.Forms;
namespace BismNormalizer.TabularCompare.UI
{
public class SynchronizedScrollRichTextBox : RichTextBox
{
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1009:DeclareEventHandlersCorrectly")]
public event vScrollEventHandler vScro... | mit |
Javier-Solis/admin-project | app/Validation/Exceptions/SubdivisionCode/CySubdivisionCodeException.php | 812 | <?php
/*
* This file is part of App/Validation.
*
* (c) Alexandre Gomes Gaigalas <alexandre@gaigalas.net>
*
* For the full copyright and license information, please view the "LICENSE.md"
* file that was distributed with this source code.
*/
namespace App\Validation\Exceptions\SubdivisionCode;
use App\Validati... | mit |
adewynter/Tools | Algorithms/dataStructures/suffixTree.py | 1637 | # Implementation of a suffix tree
# Adrian deWynter, 2017
class suffixTree(object):
class Node(object):
def __init__(self,label):
self.label = label
self.children = {}
def __init__(self, s):
s = s + "$"
self.root = self.Node(None)
self.root.children(s[0]) =self.Node(s)
for i in xrange(1,len(s)... | mit |
creynders/keystone | test/e2e/adminUI/tests/group002Home/uxTestHomeView.js | 3468 | module.exports = {
before: function (browser) {
browser.app = browser.page.app();
browser.signinScreen = browser.page.signin();
browser.homeScreen = browser.page.home();
browser.initialFormScreen = browser.page.initialForm();
browser.listScreen = browser.page.list();
browser.deleteConfirmationScreen = brow... | mit |
char-lie/react-vouchers | app/reducers/vouchersReducer.js | 2218 | import { ACTIONS } from '../actions';
const initialState = Object.freeze({
vouchers: [],
});
const EDITABLE_KEYS = ['brand_name', 'cvv', 'notes', 'paper_voucher',
'seller', 'serial_number', 'status'];
function replaceVoucher(vouchers, voucherIndex, vaucherPatch) {
return voucherIndex === -1 || typeof voucherIn... | mit |
eklavyamirani/vscode | src/vs/workbench/parts/debug/electron-browser/repl.ts | 12844 | /*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
*---------------------------------------------------------------... | mit |
VeganCoin/VeganCoin | src/qt/sendcoinsentry.cpp | 4337 | #include "sendcoinsentry.h"
#include "ui_sendcoinsentry.h"
#include "guiutil.h"
#include "bitcoinunits.h"
#include "addressbookpage.h"
#include "walletmodel.h"
#include "optionsmodel.h"
#include "addresstablemodel.h"
#include <QApplication>
#include <QClipboard>
SendCoinsEntry::SendCoinsEntry(QWidget *parent) :
... | mit |
hail-is/hail | hail/python/hail/ir/blockmatrix_ir.py | 13458 | import hail as hl
from hail.expr.blockmatrix_type import tblockmatrix
from hail.expr.types import tarray
from .blockmatrix_reader import BlockMatrixReader
from .base_ir import BlockMatrixIR, IR
from hail.typecheck import typecheck_method, sequenceof
from hail.utils.misc import escape_id
from hail.utils.java import Env... | mit |
ecommerce-utilities/php-countries | codes/et_EE/icu-countries.php | 49 | <?php require __DIR__.'/../et/icu-countries.php'; | mit |
zettajs/zrx | zrx.js | 4373 | var Rx = require('rx');
var siren = require('siren');
var Device = require('./device');
var Zrx = module.exports = function(current) {
if (!(this instanceof Zrx)) {
return new Zrx(current);
}
this.client = siren(current);
};
Zrx.prototype.load = function(uri) {
this.client.load(uri);
return this;
};
Z... | mit |
Curiosity-Education/curiosity-v.1.0 | public/packages/assets/js/config/request/dist/request-dist.js | 2239 | 'use strict';
var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.definePrope... | mit |
mpieces/Rails-Estates-to-Date-WIP | db/migrate/20151213233725_create_favorites.rb | 363 | class CreateFavorites < ActiveRecord::Migration
def change
create_table :favorites do |t|
t.references :favorited, polymorphic: true, index: true
# t. references :estatesale, index: true
t.references :user, index: true
t.references :shopper, index: true
# t.text_area :notes
... | mit |
VoRDKW/kw_smart | application/views/users/user_view.php | 184 | <script>
jQuery(document).ready(function ($) {
$("#menu-top li").removeAttr('class');
});
</script>
<div class="container-fluid" style="min-height: 800px;">
</div> | mit |
leevilehtonen/cook-a-gram | src/main/java/com/leevilehtonen/cookagram/CookAGramApplication.java | 502 | package com.leevilehtonen.cookagram;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
/**
* Spring Boot application starter class
*
* @author lleevi
*/
@SpringBootApplication
public class CookAGramApplication {
/**
* Application main... | mit |
protofuture/dashing | app/models/item.rb | 979 | # == Schema Information
#
# Table name: items
#
# id :integer not null, primary key
# private_path :string(255)
# user_id :integer
# shared :boolean
# created_at :datetime
# updated_at :datetime
#
class Item < ActiveRecord::Base
attr_accessor :file
attr_accessible :shared, :f... | mit |
theroot79/angularJSproject | app/js/controllers/AdminUsersListController.js | 902 | 'use strict';
appAngularJS.controller('AdminUsersListController',['$scope','adminServices','filters',
function ($scope, adminServices, filters) {
$scope.currentPage = 1;
$scope.startPage = 1;
$scope.itemsPerPage = 10;
$scope.SortBy = 'UserName';
$scope.reverseSort = false;
function loadAdminUsers(params... | mit |
askehansen/redactor_s3 | spec/dummy/config/routes.rb | 83 | Rails.application.routes.draw do
mount RedactorS3::Engine => "/redactor_s3"
end
| mit |
Domiii/smart-video-2013 | MyPlayer/src/main.cpp | 694 | #include <cstdio>
#include <iostream>
#include <opencv2/highgui/highgui.hpp>
#include "MyPlayer.h"
using namespace std;
using namespace cv;
using namespace mp;
PlayerConfig Config;
std::unique_ptr<Player> p;
int main(int argc, char* argv[])
{
Config.CfgFolder = "..";
Config.CfgFile = "config.json";
if (!Confi... | mit |
jribeiro/storybook | app/react-native/src/server/config/babel.js | 1404 | /**
* Copyright (c) 2015-present, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*/
module.exp... | mit |
tilleryj/rio | public/javascripts/components/base.js | 1022 | rio.components.Base = rio.Component.create("Base", {
attrReaders: [
["className", ""],
["seleniumId", ""]
],
styles: ["position", "top", "right", "bottom", "left", "display"],
methods: {
html: function() {
if (!this._html) {
this._html = this.buildHtml();
this._html.addClassName(this.getClassName(... | mit |
khenidak/Router | src/RouterLib/MatchingFrx/Context/ContextContainsKeyMatcher.cs | 1729 | using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace RouterLib
{
public class ContextContainsKeyMatcher : MatcherBase
{
public string KeyName { get; set; }
public StringMatchType MatchType { get; set; } ... | mit |
pballart/Memorize4me | app/src/main/java/com/best/memorize4me/util/DateUtils.java | 590 | package com.best.memorize4me.util;
import java.text.SimpleDateFormat;
import java.util.Date;
/**
* Created by konstantin.bogdanov on 08.07.2015.
*/
public class DateUtils {
public static String dateToString(Date date) {
SimpleDateFormat simpleDateFormat = new SimpleDateFormat("dd/MM/yyyy");
retu... | mit |
lucionei/chamadotecnico | chamadosTecnicosFinal-app/node_modules/date-fns/fp/isSameSecondWithOptions/index.js | 627 | 'use strict';
Object.defineProperty(exports, "__esModule", {
value: true
});
var _index = require('../../isSameSecond/index.js');
var _index2 = _interopRequireDefault(_index);
var _index3 = require('../_lib/convertToFP/index.js');
var _index4 = _interopRequireDefault(_index3);
function _interopRequireDefault(ob... | mit |
ruvents/ruvents-form-wizard-bundle | DependencyInjection/RuventsFormWizardExtension.php | 992 | <?php
declare(strict_types=1);
namespace Ruvents\FormWizardBundle\DependencyInjection;
use Ruvents\FormWizardBundle\Type\StepTypeInterface;
use Ruvents\FormWizardBundle\Type\WizardTypeInterface;
use Symfony\Component\Config\FileLocator;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component... | mit |
niromon/votvot | gutils/src/main/java/com/deguet/gutils/permutation/PrimeBase.java | 6152 | package com.deguet.gutils.permutation;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.List;
/**
* Helps represent a set of positive Integer with one using the uniqueness of prime decomposition.
* 4 ::: [0, 2] as 1^0 * 2^2
* 3 ::: [0, 0, 1] as 1^0 * 2^0 * 3... | mit |
xsoameix/utfconv | utfconv.go | 822 | package utfconv
import (
"unicode/utf16"
"unicode/utf8"
"encoding/binary"
)
const (
replacementChar = '\uFFFD'
)
func Read(charset string, data []byte) string {
switch charset {
case "utf8":
var runes []rune
for i := 0; i < len(data); {
r,size := utf8.DecodeRune(data[i:])
if r != utf8.RuneError {
... | mit |
robbytobby/kavau | spec/policies/string_setting_policy_spec.rb | 599 | require 'rails_helper'
RSpec.describe StringSettingPolicy do
subject { StringSettingPolicy.new(user, setting) }
let(:setting) { create(:string_setting) }
context "for an Admin" do
let(:user){ create :admin }
permits :all, except: [:show, :new, :edit, :create]
end
[:accountant, :user].each do |role|... | mit |
Tjoosten/dbutil-package | src/Controllers/DbUtilFunctions.php | 2290 | <?php
namespace Hopp\DbUtil\Controllers;
class DbUtilFunctions
{
/**
* Drop a table.
*
* @param string $table
* @return void
*/
public static function drop($table, $connection = null)
{
\DB::connection($connection)->getPdo()->query('drop table '.$table);
}
/**... | mit |
jwoertink/jko_api | lib/jko_api/responder.rb | 1618 | module JkoApi
class Responder < ActionController::Responder
protected
def display(model, *args)
options[:user] ||= controller.current_user
options[:wrap] ||= controller.wrap
options[:representer] ||= controller.representer
if first_model = Array.wrap(model).first
... | mit |
swimlane/ngx-ui | src/app/forms/toggle-page/toggle-page.component.ts | 378 | import { ChangeDetectionStrategy, Component } from '@angular/core';
@Component({
selector: 'app-toggle-page',
templateUrl: './toggle-page.component.html',
changeDetection: ChangeDetectionStrategy.OnPush
})
export class TogglePageComponent {
toggleChk = true;
onToggleChange(event) {
// eslint-disable-nex... | mit |
Deathangel908/djangochat | frontend/src/ts/classes/DefaultStore.ts | 29832 | import Vue from 'vue';
import Vuex from 'vuex';
import loggerFactory from '@/ts/instances/loggerFactory';
import {
ChannelModel,
ChannelsDictModel,
ChannelsDictUIModel,
ChannelUIModel,
CurrentUserInfoModel,
CurrentUserInfoWoImage,
CurrentUserSettingsModel,
EditingMessage,
GrowlModel,
GrowlType,
I... | mit |
gilramir/argparse | v2/examples/example1/main.go | 1363 | // Copyright (c) 2021 by Gilbert Ramirez <gram@alumni.rice.edu>
package main
import (
"fmt"
"time"
"github.com/gilramir/argparse/v2"
)
type MyOptions struct {
Count int
Expiration time.Duration
Verbose bool
Names []string
}
func main() {
opts := &MyOptions{}
ap := argparse.New(&argparse.Comma... | mit |
majestrate/nyaa | utils/validator/torrent/helpers.go | 1064 | package torrentValidator
import (
"net/url"
"strings"
)
// CheckTrackers : Check if there is good trackers in torrent
func CheckTrackers(trackers []string) []string {
// TODO: move to runtime configuration
var deadTrackers = []string{ // substring matches!
"://open.nyaatorrents.info:6544",
"://tracker.openbit... | mit |
hhatfield/php-contact-api | vendor/zfcampus/zf-apigility-admin/asset/src/zf-apigility-admin/js/controllers/content-negotiation.js | 3588 | (function() {
'use strict';
angular.module('ag-admin').controller(
'ContentNegotiationController',
function ($scope, $state, $stateParams, $modal, flash, selectors, ContentNegotiationResource, agFormHandler) {
var newSelector = {
content_name: '',
viewModel: '',
selectors: {}
};
$s... | mit |
wolfdale/Spaghetti-code | Golang/2020Go/avg.go | 390 | package main
import "fmt"
func main() {
var size int
fmt.Println("Enter the size of array: ")
fmt.Scan(&size)
fmt.Println("Enter the array elements: ")
// Create the array using make
array := make([]int, size)
sum := 0
for i := 0; i < size; i++ {
fmt.Scan(&array[i])
sum = sum + array[i]
}
avg := flo... | mit |
codem4ster/molecule | app/controllers/molecule_controller.rb | 670 | # This is the main Controller for molecule it handles SPA requests
class MoleculeController < ApplicationController
BOTS = %w[Applebot baiduspider Bingbot Googlebot ia_archiver msnbot
Naverbot seznambot Slurp teoma Twitterbot Yandex Yeti].freeze
def spa
return render 'molecule/non-bots' unless bot?... | mit |
Ahmed--Mohsen/leetcode | Median_of_Two_Sorted_Arrays.py | 1198 | """
There are two sorted arrays nums1 and nums2 of size m and n respectively.
Find the median of the two sorted arrays. The overall run time complexity should be O(log (m+n)).
"""
class Solution:
# @return a float
def findMedianSortedArrays(self, A, B):
m = len(A); n = len(B)
# even merged ... take ave... | mit |
srpanwar/graph | omukcontrols/Properties/AssemblyInfo.cs | 1400 | using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("om... | mit |
simosabba/alaska | src/foundation/Alaska.Foundation.Core/Caching/Interfaces/ICacheItemInfo.cs | 330 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Alaska.Foundation.Core.Caching.Interfaces
{
public interface ICacheItemInfo
{
string Key { get; }
TimeSpan Expiration { get; }
DateTime ExpirationTime { get; }
... | mit |
doctrine/mongodb-odm | tests/Doctrine/ODM/MongoDB/Tests/Functional/FilterTest.php | 9746 | <?php
declare(strict_types=1);
namespace Doctrine\ODM\MongoDB\Tests\Functional;
use Doctrine\ODM\MongoDB\DocumentNotFoundException;
use Doctrine\ODM\MongoDB\Query\FilterCollection;
use Doctrine\ODM\MongoDB\Tests\BaseTest;
use Documents\Group;
use Documents\Profile;
use Documents\User;
use function sort;
class Filt... | mit |
almeida-fogo/laravel-modules | src/Modulos/Usuarios/Simples/Views/login.blade.php | 1450 | @extends("Roots_Templates.master")
@section("titulo")
LOGIN
@endsection
@section("css")
@endsection
@section("conteudo")
<form id="loginform" class="form-horizontal form" role="form" action="{{action("UsuarioController@postLogin")}}" method="POST">
{!!csrf_field()!!}
@if ($errors->has("email"))
<div class="... | mit |
mmeents/DataMattei | C0DEC0RE/Backup/IReflectionMemberInfo.cs | 1564 | //===============================================================================
// Microsoft patterns & practices
// Object Builder Application Block
//===============================================================================
// Copyright © Microsoft Corporation. All rights reserved.
// THIS CODE AND INFORMATI... | mit |
curvedmark/tree-transformer | test/test.js | 3546 | var assert = require('assert');
var Transformer = require('..');
describe('Transformer', function () {
describe('transform a single node', function () {
it('should return returned value', function () {
var node = { type: 'number', value: 1 };
function MyTransformer() {}
MyTransformer.prototype = new Trans... | mit |
brewdente/AutoWebPerf | MasterDevs.ChromeDevTools/Protocol/CSS/GetMatchedStylesForNodeCommand.cs | 749 | using MasterDevs.ChromeDevTools;
using Newtonsoft.Json;
using System.Collections.Generic;
namespace MasterDevs.ChromeDevTools.Protocol.CSS
{
/// <summary>
/// Returns requested styles for a DOM node identified by <code>nodeId</code>.
/// </summary>
[Command(ProtocolName.CSS.GetMatchedStylesForNode)]
public class ... | mit |
binidini/mstock | members/payments_paypalpro.php | 8914 | <?
$site="paypalpro";
include("../admin/function/db.php");
include("payments_settings.php");
if(!isset($_POST["product_id"]) or !isset($_POST["product_name"]) or !isset($_POST["product_total"]) or !isset($_POST["product_type"]))
{
exit();
}
?>
<?include("../inc/header.php");?>
<h1><?=word_lang("payment")?> - Paypal... | mit |
emmellsoft/RPi.SenseHat | RPi.SenseHat/RTIMULibCS/Devices/LSM9DS1/AccelSampleRate.cs | 1469 | ////////////////////////////////////////////////////////////////////////////
//
// This file is part of RTIMULibCS
//
// Copyright (c) 2015, richards-tech, LLC
//
// Permission is hereby granted, free of charge, to any person obtaining a copy of
// this software and associated documentation files (the "Software"), ... | mit |
yimlu/testSuite | testSuite.js | 2616 | var https = require('https');
var querystring = require('querystring');
var fs = require('fs');
var colors = require('colors/safe');
var caseBuilder = (function(){
var CaseBuilder = {
"build":function(globConfig,options){
return {
"name":options.name,
"host":globConfig.host,
"port":globConfig.p... | mit |
bugsnag/bugsnag-js | examples/ts/angular/src/app/app.component.ts | 1425 | import { Component } from '@angular/core';
import Bugsnag from '@bugsnag/js';
@Component({
selector: 'app-root',
templateUrl: './app.component.html',
styleUrls: ['./app.component.css']
})
export class AppComponent {
title = 'app';
doARenderError = false;
doAHandledError = false;
// this function is trig... | mit |