identifier stringlengths 42 383 | collection stringclasses 1
value | open_type stringclasses 1
value | license stringlengths 0 1.81k | date float64 1.99k 2.02k ⌀ | title stringlengths 0 100 | creator stringlengths 1 39 | language stringclasses 157
values | language_type stringclasses 2
values | word_count int64 1 20k | token_count int64 4 1.32M | text stringlengths 5 1.53M | __index_level_0__ int64 0 57.5k |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
https://github.com/agusmakmun/ebayscrapper/blob/master/app_product/views.py | Github Open Source | Open Source | MIT | 2,021 | ebayscrapper | agusmakmun | Python | Code | 78 | 380 | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.shortcuts import (get_object_or_404, redirect)
from django.views.generic import (TemplateView, DetailView)
from app_scraper.utils.scraper import scrape_product_info
from app_product.models import Product
class ProductScrape(TemplateView):
... | 10,452 |
https://github.com/read0nly/hms-flutter-plugin/blob/master/flutter-hms-ml/android/src/main/java/com/huawei/hms/flutter/ml/permissions/PermissionHandler.java | Github Open Source | Open Source | Apache-2.0, MIT, BSD-3-Clause | 2,021 | hms-flutter-plugin | read0nly | Java | Code | 486 | 2,087 | /*
Copyright 2020. Huawei Technologies Co., Ltd. All rights reserved.
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
https://www.apache.org/licenses/LICENSE-2.0
Unless ... | 7,625 |
https://github.com/zendesk/curlybars/blob/master/spec/dummy/app/presenters/shared/avatar_presenter.rb | Github Open Source | Open Source | Apache-2.0 | 2,023 | curlybars | zendesk | Ruby | Code | 19 | 74 | class Shared::AvatarPresenter
extend Curlybars::MethodWhitelist
attr_reader :avatar
allow_methods :url
def initialize(avatar)
@avatar = avatar
end
def url
@avatar.url
end
end
| 49,051 |
https://github.com/ryanoflaherty/arduino-rgb/blob/master/src/libraries/RgbDriver.h | Github Open Source | Open Source | MIT | null | arduino-rgb | ryanoflaherty | C | Code | 30 | 94 | #ifndef RGBDRIVER_H
#define RGBDRIVER_H
class RgbDriver
{
protected:
Led red;
Led green;
Led blue;
bool ledOn;
public:
RgbDriver(int redPin, int greenPin, int bluePin);
void setColor(Rgb color);
void turnRgbOff();
};
#endif | 21,238 |
https://github.com/jupierce/ci-tainting-webhook/blob/master/build.sh | Github Open Source | Open Source | Apache-2.0 | null | ci-tainting-webhook | jupierce | Shell | Code | 11 | 59 | #!/bin/sh
sudo docker build -t quay.io/jupierce/ci-tainting-webhook:latest .
sudo docker push quay.io/jupierce/ci-tainting-webhook:latest | 35,564 |
https://github.com/praveenpv1/ecaps-Fe/blob/master/src/app/core/components/dashboard/dashboard.component.ts | Github Open Source | Open Source | MIT | 2,020 | ecaps-Fe | praveenpv1 | TypeScript | Code | 760 | 2,721 | import { Component, OnInit, OnDestroy } from "@angular/core";
import { DataStore } from "@app/core/store/app.store";
import { CompanyReducers } from "@app/core/store/reducers/company.reducer";
import {
GET_COMPANY_WALLET,
GET_COMPANY_MAIN_TXNS,
GET_COMPANY_TXNS,
GET_CLAIMS_TXNS
} from "@app/core/store/actions";... | 2,650 |
https://github.com/kickstarter/android-oss/blob/master/app/src/main/java/com/kickstarter/ui/views/LoginPopupMenu.kt | Github Open Source | Open Source | Apache-2.0, ICU, MIT, LicenseRef-scancode-facebook-software-license, EPL-1.0 | 2,023 | android-oss | kickstarter | Kotlin | Code | 95 | 416 | package com.kickstarter.ui.views
import android.content.Context
import android.content.Intent
import android.net.Uri
import android.view.MenuItem
import android.view.View
import android.widget.PopupMenu
import androidx.appcompat.app.AppCompatActivity
import com.kickstarter.R
import com.kickstarter.libs.utils.Secrets
i... | 18,921 |
https://github.com/ZebraRoy/ThreeKingdom/blob/master/public/src/views/naming-scene.js | Github Open Source | Open Source | MIT | null | ThreeKingdom | ZebraRoy | JavaScript | Code | 107 | 355 | import {
connect
} from 'inferno-redux';
import createElement from 'inferno-create-element';
import {
Actions
} from '../actions';
export function NamingScene ({ name, onSubmit }) {
return createElement(
'div',
{
className: 'inferno-form'
},
createElement(
'form',
{
name... | 46,587 |
https://github.com/WildGoat07/LogicTable/blob/master/LogicTable/Language.cs | Github Open Source | Open Source | MIT | null | LogicTable | WildGoat07 | C# | Code | 23 | 56 | namespace LogicTable
{
public partial class MainWindow
{
#region Public Enums
public enum Language
{
FR,
EN
}
#endregion Public Enums
}
} | 44,513 |
https://github.com/burkeac/MPS_Tool_Kit/blob/master/docs/search/all_c.js | Github Open Source | Open Source | MIT | null | MPS_Tool_Kit | burkeac | JavaScript | Code | 10 | 452 | var searchData=
[
['scopetimer_65',['ScopeTimer',['../class_m_p_s_1_1_scope_timer.html',1,'MPS::ScopeTimer'],['../class_m_p_s_1_1_scope_timer.html#a3e464bc2d89e98d7b38e91e8e50ef4d9',1,'MPS::ScopeTimer::ScopeTimer()']]],
['selectprimary_66',['selectPrimary',['../class_m_p_s_1_1color_primaries.html#ae97ba301ab9140d08... | 472 |
https://github.com/HorvatMatej/IdentityUI/blob/master/src/IdentityUI.Admin/Areas/IdentityAdmin/Controllers/Group/GroupInviteController.cs | Github Open Source | Open Source | MIT | 2,020 | IdentityUI | HorvatMatej | C# | Code | 173 | 948 | using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;
using SSRD.IdentityUI.Admin.Areas.IdentityAdmin.Interfaces.Group;
using SSRD.IdentityUI.Admin.Areas.IdentityAdmin.Models.DataTable;
using SSRD.IdentityUI.Admin.Areas.IdentityAdmin.Models.Group;
using SSRD.Identit... | 38,945 |
https://github.com/isomorfeus/arangodb-driver/blob/master/lib/arango/requests/replication/get_tail.rb | Github Open Source | Open Source | MIT | 2,020 | arangodb-driver | isomorfeus | Ruby | Code | 70 | 188 | module Arango
module Requests
module Replication
class GetTail < Arango::Request
request_method :get
uri_template '{/dbcontext}/_api/wal/tail'
param :barrier_id
param :chunk_size
param :client_info
param :from
param :global
param :last_scanne... | 8,272 |
https://github.com/gotd/td/blob/master/_tools/go.mod | Github Open Source | Open Source | MIT, LicenseRef-scancode-proprietary-license | 2,023 | td | gotd | Go Module | Code | 19 | 129 | module github.com/gotd/td/_tools
go 1.16
require (
github.com/dvyukov/go-fuzz v0.0.0-20210103155950-6a8e9d1f2415
github.com/elazarl/go-bindata-assetfs v1.0.1 // indirect
github.com/stephens2424/writerset v1.0.2 // indirect
golang.org/x/tools v0.12.0
)
| 13,228 |
https://github.com/mikeleber/j2html/blob/master/library/src/main/java/j2html/tags/specialized/MapTag.java | Github Open Source | Open Source | Apache-2.0 | 2,022 | j2html | mikeleber | Java | Code | 21 | 79 | package j2html.tags.specialized;
import j2html.tags.ContainerTag;
import j2html.tags.attributes.IName;
public final class MapTag extends ContainerTag<MapTag>
implements IName<MapTag> {
public MapTag() {
super("map");
}
}
| 23,257 |
https://github.com/curtys/webprotege-attestation/blob/master/webprotege-shared/src/main/java/edu/stanford/bmir/protege/web/shared/issues/mention/EntityMention.java | Github Open Source | Open Source | BSD-2-Clause | 2,023 | webprotege-attestation | curtys | Java | Code | 72 | 291 | package edu.stanford.bmir.protege.web.shared.issues.mention;
import edu.stanford.bmir.protege.web.shared.annotations.GwtSerializationConstructor;
import edu.stanford.bmir.protege.web.shared.issues.Mention;
import org.semanticweb.owlapi.model.OWLEntity;
import javax.annotation.Nonnull;
import static com.google.common... | 28,055 |
https://github.com/BasiqueEvangelist/allium/blob/master/src/main/java/me/hugeblank/allium/lua/api/JavaLib.java | Github Open Source | Open Source | MIT | 2,022 | allium | BasiqueEvangelist | Java | Code | 693 | 2,378 | package me.hugeblank.allium.lua.api;
import me.basiqueevangelist.enhancedreflection.api.EClass;
import me.basiqueevangelist.enhancedreflection.api.EMethod;
import me.basiqueevangelist.enhancedreflection.api.typeuse.EClassUse;
import me.hugeblank.allium.Allium;
import me.hugeblank.allium.lua.type.*;
import me.hugeblank... | 39,517 |
https://github.com/MaximTiberiu/OOProject/blob/master/.gitignore | Github Open Source | Open Source | MIT | 2,021 | OOProject | MaximTiberiu | Ignore List | Code | 12 | 75 | CMakeCache.txt
CMakeFiles
CMakeScripts
Testing
Makefile
cmake_install.cmake
install_manifest.txt
compile_commands.json
CTestTestfile.cmake
_deps
/**/cmake-build-debug/
/**/cmake-build-release
| 1,475 |
https://github.com/blackcoffeexbt/lnbits-legend/blob/master/lnbits/core/__init__.py | Github Open Source | Open Source | MIT | 2,022 | lnbits-legend | blackcoffeexbt | Python | Code | 33 | 83 | from fastapi.routing import APIRouter
from lnbits.db import Database
db = Database("database")
core_app: APIRouter = APIRouter()
from .views.api import * # noqa
from .views.generic import * # noqa
from .views.public_api import * # noqa
| 21,968 |
https://github.com/Songllgons/uni-app/blob/master/src/platforms/app-plus/view/elements/index.js | Github Open Source | Open Source | Apache-2.0 | null | uni-app | Songllgons | JavaScript | Code | 9 | 18 | import View from './view'
export default {
View
}
| 46,777 |
https://github.com/markodjunev/E-Diary/blob/master/EDiary/Data/EDiary.Data.Models/Mark.cs | Github Open Source | Open Source | MIT | null | E-Diary | markodjunev | C# | Code | 57 | 137 | namespace EDiary.Data.Models
{
using EDiary.Data.Common.Models;
public class Mark : BaseDeletableModel<int>
{
public double Score { get; set; }
public string NameOfExam { get; set; }
public string StudentId { get; set; }
public virtual ApplicationUser Student { get; set;... | 22,208 |
https://github.com/Simulalex/have-you-considered/blob/master/db/database.go | Github Open Source | Open Source | MIT | null | have-you-considered | Simulalex | Go | Code | 140 | 430 | package db
import (
"fmt"
"database/sql"
_ "github.com/go-sql-driver/mysql"
"github.com/Simulalex/haveyouconsidered/models"
)
const dbConnectionString = "%v:%v@%v"
type Database interface {
GetSummary(name string) (*models.Technology, error)
}
type database struct{
mysql *sql.DB
}
type Config struct {
Use... | 44,281 |
https://github.com/sjdlloyd/tsai/blob/master/tsai/metrics.py | Github Open Source | Open Source | Apache-2.0 | null | tsai | sjdlloyd | Python | Code | 92 | 339 | # AUTOGENERATED! DO NOT EDIT! File to edit: nbs/007_metrics.ipynb (unless otherwise specified).
__all__ = ['MatthewsCorrCoefBinary', 'get_task_metrics']
# Cell
from .imports import *
from fastai.metrics import *
# Cell
mk_class('ActivationType', **{o:o.lower() for o in ['No', 'Sigmoid', 'Softmax', 'BinarySoftmax']},... | 18,356 |
https://github.com/alifffahmi/checks-api-plugin/blob/master/src/test/java/io/jenkins/plugins/checks/status/BuildStatusChecksPublisherITest.java | Github Open Source | Open Source | MIT | null | checks-api-plugin | alifffahmi | Java | Code | 361 | 1,178 | package io.jenkins.plugins.checks.status;
import hudson.model.Job;
import hudson.model.Run;
import io.jenkins.plugins.checks.util.LoggingChecksPublisher;
import io.jenkins.plugins.util.IntegrationTestWithJenkinsPerTest;
import org.junit.Test;
import org.jvnet.hudson.test.JenkinsRule;
import org.jvnet.hudson.test.TestE... | 19,268 |
https://github.com/justinribeiro/lighthouse-action/blob/master/node_modules/axe-core/lib/checks/aria/aria-hidden-body-evaluate.js | Github Open Source | Open Source | MPL-2.0, Apache-2.0 | 2,022 | lighthouse-action | justinribeiro | JavaScript | Code | 43 | 99 | /**
* Check that the element does not have the `aria-hidden` attribute.
*
* @memberof checks
* @return {Boolean} True if the `aria-hidden` attribute is not present. False otherwise.
*/
function ariaHiddenBodyEvaluate(node, options, virtualNode) {
return virtualNode.attr('aria-hidden') !== 'true';
}
export defau... | 19,233 |
https://github.com/AlexRogalskiy/DevArtifacts/blob/master/master/javascript-tutorial-ru/javascript-tutorial-ru/1-js/6-objects-more/8-decorators/3-caching-decorator/_js.view/solution.js | Github Open Source | Open Source | MIT | 2,019 | DevArtifacts | AlexRogalskiy | JavaScript | Code | 24 | 65 | function makeCaching(f) {
var cache = {};
return function(x) {
if (!(x in cache)) {
cache[x] = f.call(this, x);
}
return cache[x];
};
} | 6,788 |
https://github.com/daydream05/another-dev-swag/blob/master/web/src/components/convert-kit-signup.js | Github Open Source | Open Source | 0BSD | 2,021 | another-dev-swag | daydream05 | JavaScript | Code | 103 | 332 | import React from "react"
/** @jsx jsx */
import { jsx, Container } from "theme-ui"
import ConvertKitForm from 'convertkit-react'
import { SectionHeading } from "./section-heading"
import { mediaQueries } from "../gatsby-plugin-theme-ui/media-queries"
import { breakpoints } from "../gatsby-plugin-theme-ui/breakpoint... | 19,380 |
https://github.com/djh-A/java/blob/master/design/src/local/design/singleton/Singletondemo3.java | Github Open Source | Open Source | Apache-2.0 | null | java | djh-A | Java | Code | 45 | 221 | package local.design.singleton;
public class Singletondemo3 {
/*
定义私有无参构造
*/
private Singletondemo3() {
}
/*
私有静态属性
*/
private static Singletondemo3 instance;
public static Singletondemo3 getInstance() {
if (instance == null) {
/**
* todo:多线... | 32,027 |
https://github.com/marlonnardi/alcinoe/blob/master/references/UIB/misc/ShellExtention/Shutdown.dfm | Github Open Source | Open Source | LicenseRef-scancode-unknown-license-reference, LicenseRef-scancode-proprietary-license, MPL-1.0, LicenseRef-scancode-unknown, MPL-1.1, Apache-2.0, LicenseRef-scancode-free-unknown | 2,020 | alcinoe | marlonnardi | Pascal | Code | 235 | 552 | object ShutDownForm: TShutDownForm
Left = 379
Top = 327
Width = 325
Height = 244
Caption = 'Shutdown database'
Color = clBtnFace
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
Font.Height = -11
Font.Name = 'MS Sans Serif'
Font.Style = []
OldCreateOrder = False
Position = poDefaultPos... | 38,802 |
https://github.com/juszhc/CodeArts/blob/master/src/CodeArts.Db.Lts/DatabaseFactory.cs | Github Open Source | Open Source | MIT | 2,022 | CodeArts | juszhc | C# | Code | 2,067 | 6,680 | using CodeArts.Db.Exceptions;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Linq.Expressions;
using System.Threading;
using System.Threading.Tasks;
namespace CodeArts.Db.Lts
{
/// <summary>
/// 数据库工厂。
/// </summary>
public class DatabaseFa... | 6,929 |
https://github.com/LLNL/Tool-Gear/blob/master/src/boost/mpl/set/aux_/begin_end_impl.hpp | Github Open Source | Open Source | BSD-3-Clause, LicenseRef-scancode-unknown-license-reference, BSL-1.0 | 2,018 | Tool-Gear | LLNL | C++ | Code | 156 | 408 |
#ifndef BOOST_MPL_SET_AUX_BEGIN_END_IMPL_HPP_INCLUDED
#define BOOST_MPL_SET_AUX_BEGIN_END_IMPL_HPP_INCLUDED
// + file: boost/mpl/aux_/begin_end_impl.hpp
// + last modified: 03/may/03
// Copyright (c) 2002-03
// David Abrahams, Aleksey Gurtovoy
//
// Permission to use, copy, modify, distribute and sell this software
... | 12,361 |
https://github.com/toniferr/PeeperPattern/blob/master/src/main/java/com/toni/peeper/pattern/structural/flyweight/Private.java | Github Open Source | Open Source | MIT | null | PeeperPattern | toniferr | Java | Code | 52 | 143 | package com.toni.peeper.pattern.structural.flyweight;
public class Private implements Enemy {
private String weapon;
private final String LIFE;
public Private() {
LIFE = "200";
}
public void setWeapon(String weapon) {
this.weapon = weapon;
System.out.println("El arma del soldado es: "+ weapon);
}
... | 46,660 |
https://github.com/ShayBox/ChanceCubeTimer/blob/master/src/main/java/com/shaybox/straymod/CustomTask.java | Github Open Source | Open Source | MIT | 2,019 | ChanceCubeTimer | ShayBox | Java | Code | 76 | 334 | package com.shaybox.straymod;
import com.shaybox.straymod.proxy.ClientProxy;
import net.minecraft.client.Minecraft;
import net.minecraft.entity.player.EntityPlayerMP;
import net.minecraft.util.text.TextComponentString;
import java.util.TimerTask;
public class CustomTask extends TimerTask {
@Override
public void ru... | 48,668 |
https://github.com/KnowledgeCaptureAndDiscovery/organicdatascience/blob/master/js/core/util/WTUtil.js | Github Open Source | Open Source | Apache-2.0 | 2,019 | organicdatascience | KnowledgeCaptureAndDiscovery | JavaScript | Code | 332 | 1,243 | var WTUtil = function(title, api) {
this.title = title;
this.api = api;
// Initialize some event handlers
this.initEventHandlers();
};
WTUtil.prototype.initEventHandlers = function() {
var me = this;
$(document).ready(function() {
});
};
// TODO for now, assumes HTTP or HTTPS
WTUtil.prototype.getdomain = func... | 9,003 |
https://github.com/tanzu-mkondo/storefront/blob/master/src/app/home/home.component.scss | Github Open Source | Open Source | Apache-2.0 | 2,020 | storefront | tanzu-mkondo | SCSS | Code | 38 | 134 | :host { width: 100%;}
.card {
.card-body:hover {
background-color: rgb(248, 249, 250);
}
svg, .article-image {
height: 160px;
}
.card-text {
min-height: 50px;
}
.article-image {
background-size: cover;
}
.add-to-cart {
img {
height: 1.8em;
}
}
}
| 8,586 |
https://github.com/Remi05/uial/blob/master/Uial.UnitTests/Scenarios/Scenario.cs | Github Open Source | Open Source | MIT | 2,021 | uial | Remi05 | C# | Code | 113 | 399 | using System.Collections.Generic;
using System.Linq;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using Uial.Interactions;
using Uial.Scenarios;
using Uial.UnitTests.Interactions;
namespace Uial.UnitTests.Scenarios
{
[TestClass]
public class ScenarioTests
{
[TestMethod]
public void ... | 17,588 |
https://github.com/SimeonRaykov/Programming-Basics-2018-March/blob/master/JAVA Basics/exercises/zadachi2/fo.java | Github Open Source | Open Source | MIT | null | Programming-Basics-2018-March | SimeonRaykov | Java | Code | 76 | 217 | package zadachi2;
import java.util.Scanner;
public class fo {
public static void main(String[] args) {
Scanner Scanner = new Scanner(System.in);
int n = Integer.parseInt(Scanner.nextLine());
int sum=0;
for (int i = 1; i <=9 ; i++) {
for (int j = 1; j <= 9; j++) {
... | 35,845 |
https://github.com/QQtufu/news/blob/master/网易新闻/ChannelLabel.h | Github Open Source | Open Source | MIT | 2,016 | news | QQtufu | Objective-C | Code | 28 | 81 | //
// ChannelLabel.h
// 网易新闻
//
// Created by iMac on 16/7/22.
// Copyright © 2016年 iMac. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface ChannelLabel : UILabel
@end
| 7,235 |
https://github.com/DHS009/HackerRankSolutions/blob/master/Practice/AllDomains/CoreCS/DataStructures/Arrays/2DArray-DS.js | Github Open Source | Open Source | MIT | 2,022 | HackerRankSolutions | DHS009 | JavaScript | Code | 161 | 455 | /* author:@shivkrthakur */
process.stdin.resume();
process.stdin.setEncoding('ascii');
var input_stdin = "";
var input_stdin_array = "";
var input_currentline = 0;
process.stdin.on('data', function (data) {
input_stdin += data;
});
process.stdin.on('end', function () {
input_stdin_array = input_stdin.split(... | 47,080 |
https://github.com/agalbrai/PIMS/blob/master/frontend/src/actions/genericActions.spec.ts | Github Open Source | Open Source | Apache-2.0 | 2,022 | PIMS | agalbrai | TypeScript | Code | 204 | 671 | import configureMockStore from 'redux-mock-store';
import thunk from 'redux-thunk';
import { request, success, error } from 'actions/genericActions';
import * as ActionTypes from 'constants/actionTypes';
const createMockStore = configureMockStore([thunk]);
const store = createMockStore({
rootReducer: {
parcels: ... | 44,840 |
https://github.com/petrofcikmatus/simple-todo/blob/master/_app/views/pages/login.php | Github Open Source | Open Source | MIT | 2,016 | simple-todo | petrofcikmatus | PHP | Code | 90 | 386 | <?php
if (is_logged_in()){
redirect();
}
if (is_post()) {
if (do_login()) {
redirect();
}
}
if (isset($_COOKIE["email"])) {
$_POST["email"] = $_COOKIE["email"];
}
include_header(array("title" => "login"));
?>
<div class="row">
<div class="col-md-4 col-md-offset-4">
<form id="log... | 22,678 |
https://github.com/nikkelma/harvester/blob/master/pkg/controller/master/backup/util.go | Github Open Source | Open Source | Apache-2.0, LicenseRef-scancode-warranty-disclaimer | 2,021 | harvester | nikkelma | Go | Code | 285 | 1,130 | package backup
import (
"fmt"
"time"
snapshotv1 "github.com/kubernetes-csi/external-snapshotter/v2/pkg/apis/volumesnapshot/v1beta1"
corev1 "k8s.io/api/core/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
harvesterv1 "github.com/harvester/harvester/pkg/apis/harvesterhci.io/v1beta1"
)
func vmBackupReady(vmBac... | 45,779 |
https://github.com/pvgennip/sensor-data-portal/blob/master/portal/app/Http/Controllers/UserController.php | Github Open Source | Open Source | MIT | 2,019 | sensor-data-portal | pvgennip | PHP | Code | 694 | 2,478 | <?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use App\Http\Controllers\Controller;
use App\User;
use App\Role;
use App\Sensor;
use DB;
use Hash;
use Image;
use Auth;
class UserController extends Controller
{
// Helpers
private function checkRoleAuthorization($request=null, $permission=n... | 33,393 |
https://github.com/jasonody/Cloud-Native-Development-Patterns-and-Best-Practices/blob/master/Chapter07/order-service/test/unit/connectors/database.test.ts | Github Open Source | Open Source | MIT | 2,020 | Cloud-Native-Development-Patterns-and-Best-Practices | jasonody | TypeScript | Code | 107 | 446 | import 'mocha';
import { expect } from 'chai';
const AWS = require('aws-sdk-mock');
import { Connector } from '../../../src/connectors/database';
describe('database.ts', () => {
it('save', () => {
AWS.mock('DynamoDB.DocumentClient', 'put', (params, callback) => {
expect(params).to.deep.equal({
Tabl... | 7,337 |
https://github.com/lukas-vlcek/elasticsearch-knapsack/blob/master/src/main/java/org/xbib/io/compress/lzf/LZFCompressingInputStream.java | Github Open Source | Open Source | Apache-2.0 | 2,013 | elasticsearch-knapsack | lukas-vlcek | Java | Code | 954 | 2,188 | package org.xbib.io.compress.lzf;
import java.io.IOException;
import java.io.InputStream;
import org.xbib.io.compress.BufferRecycler;
/**
* Decorator {@link InputStream} implementation used for reading
* <b>uncompressed</b> data and <b>compressing</b> it on the fly, such that
* reads return compressed data. It is ... | 21,542 |
https://github.com/lonkamikaze/hsk-dev-stub/blob/master/src/main.c | Github Open Source | Open Source | 0BSD | null | hsk-dev-stub | lonkamikaze | C | Code | 73 | 196 | /** \file
* Device main.c Stub
*
* @author kami
*/
#include <Infineon/XC878.h>
#include <hsk_boot/hsk_boot.h>
#include "config.h"
void main(void);
void init(void);
void run(void);
/**
* Call init functions and invoke the run routine.
*/
void main(void) {
init();
run();
}
/**
* Initialize ports, timers a... | 35,477 |
https://github.com/rokon12/mNet/blob/master/src/main/java/org/jugbd/mnet/security/DatabaseAuthenticationProvider.java | Github Open Source | Open Source | MIT | 2,021 | mNet | rokon12 | Java | Code | 158 | 632 | package org.jugbd.mnet.security;
import org.jugbd.mnet.domain.User;
import org.jugbd.mnet.domain.enums.Role;
import org.jugbd.mnet.service.UserService;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.authenticat... | 20,900 |
https://github.com/gitter-badger/zimg-1/blob/master/.gitmodules | Github Open Source | Open Source | WTFPL | 2,015 | zimg-1 | gitter-badger | Git Config | Code | 8 | 47 | [submodule "UnitTest/Extra/googletest"]
path = UnitTest/Extra/googletest
url = https://github.com/google/googletest.git
| 5,615 |
https://github.com/YangHao666666/hawq/blob/master/src/pl/pljava/src/java/pljava/org/postgresql/pljava/ObjectPool.java | Github Open Source | Open Source | Artistic-1.0-Perl, ISC, bzip2-1.0.5, TCL, Apache-2.0, BSD-3-Clause-No-Nuclear-License-2014, MIT, PostgreSQL, BSD-3-Clause | 2,018 | hawq | YangHao666666 | Java | Code | 136 | 292 | /*
* Copyright (c) 2004, 2005, 2006 TADA AB - Taby Sweden
* Distributed under the terms shown in the file COPYRIGHT
* found in the root directory of this distribution or at
* http://eng.tada.se/osprojects/COPYRIGHT.html
*/
package org.postgresql.pljava;
import java.sql.SQLException;
public interface ObjectPool
{... | 35,874 |
https://github.com/NUStreaming/LoL/blob/master/dash.js/src/streaming/net/HTTPLoader.js | Github Open Source | Open Source | LicenseRef-scancode-proprietary-license, BSD-3-Clause, BSD-2-Clause, Apache-2.0 | 2,021 | LoL | NUStreaming | JavaScript | Code | 1,078 | 3,092 | /**
* The copyright in this software is being made available under the BSD License,
* included below. This software may be subject to other third party and contributor
* rights, including patent rights, and no such rights are granted under this license.
*
* Copyright (c) 2013, Dash Industry Forum.
* All rights re... | 30,973 |
https://github.com/jexenberger/codestreamparent/blob/master/codestream-di/src/test/kotlin/io/codestream/di/runtime/ComponentDefinitionTest.kt | Github Open Source | Open Source | Apache-2.0 | 2,018 | codestreamparent | jexenberger | Kotlin | Code | 156 | 428 | /*
* Copyright 2018 Julian Exenberger
*
* 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`](http://www.apache.org/licenses/LICENS... | 36,805 |
https://github.com/thinkdolabs/tailwindui-crawler/blob/master/output-vue/components/application-ui/elements/avatars/circular_avatars_with_placeholder_initials.vue | Github Open Source | Open Source | MIT | 2,021 | tailwindui-crawler | thinkdolabs | Vue | Code | 82 | 326 | <template>
<span class="inline-flex items-center justify-center h-6 w-6 rounded-full bg-gray-500">
<span class="text-xs font-medium leading-none text-white">TW</span>
</span>
<span class="inline-flex items-center justify-center h-8 w-8 rounded-full bg-gray-500">
<span class="text-sm font-medium leading... | 48,500 |
https://github.com/nikitabu/drudeLorentz/blob/master/node_modules/mathjs/lib/function/construction/string.js | Github Open Source | Open Source | Apache-2.0 | 2,015 | drudeLorentz | nikitabu | JavaScript | Code | 182 | 471 | 'use strict';
module.exports = function (math) {
var util = require('../../util/index'),
collection = require('../../type/collection'),
number = util.number,
isNumber = util.number.isNumber,
isCollection = collection.isCollection;
/**
* Create a string or convert any object into a str... | 32,425 |
https://github.com/SaeedAhmadSD7/muscleUp/blob/master/resources/views/muscle-up-app/trainee/workoutProgram/workoutProgram.blade.php | Github Open Source | Open Source | MIT | null | muscleUp | SaeedAhmadSD7 | PHP | Code | 157 | 862 | @extends('layouts.backend-main')
@section('title','Progress')
@section('style-sheet')
@stop
@section('page-heading')
<h2>Workout Program</h2>
<p>View Workout Program</p>
@stop
@section('content')
<div class="panel">
<div class="panel-body">
<div class="example-box-wrapper">
... | 46,714 |
https://github.com/GEOS-ESM/MAPL/blob/master/generic/StringCompositeMap.F90 | Github Open Source | Open Source | Apache-2.0, LicenseRef-scancode-warranty-disclaimer, LicenseRef-scancode-unknown-license-reference | 2,023 | MAPL | GEOS-ESM | Fortran Free Form | Code | 28 | 115 | module mapl_StringCompositeMap
use mapl_AbstractComposite
#include "types/key_deferredLengthString.inc"
#define _value class(AbstractComposite)
#define _value_allocatable class(AbstractComposite)
#define _map StringCompositeMap
#define _iterator StringCompositeMapIterator
#define _pair StringCompositePair
#define _a... | 25,694 |
https://github.com/didi/daedalus/blob/master/daedalus-server/src/main/java/com/didichuxing/daedalus/dal/InstanceDal.java | Github Open Source | Open Source | Apache-2.0 | 2,021 | daedalus | didi | Java | Code | 289 | 1,389 | package com.didichuxing.daedalus.dal;
import com.didichuxing.daedalus.common.enums.InstanceTypeEnum;
import com.didichuxing.daedalus.common.enums.StatusEnum;
import com.didichuxing.daedalus.entity.instance.InstanceEntity;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.... | 49,023 |
https://github.com/christocs/ICT397/blob/master/shader/default.vert | Github Open Source | Open Source | ISC | null | ICT397 | christocs | GLSL | Code | 60 | 158 | #version 410 core
layout (location = 0) in vec3 in_pos;
layout (location = 1) in vec3 in_normal;
layout (location = 2) in vec2 in_uvs;
uniform struct Matrices {
mat4 model;
mat4 view;
mat4 projection;
} u_matrices;
out VertexData {
vec2 uvs;
} o;
void main() {
o.uvs = in_uvs;
gl_Position = u_... | 12,468 |
https://github.com/adityavs/ant/blob/master/src/tests/junit/org/apache/tools/ant/types/PathTest.java | Github Open Source | Open Source | Apache-2.0 | 2,018 | ant | adityavs | Java | Code | 1,871 | 6,329 | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you... | 33,387 |
https://github.com/millerf1234/OpenGL_Windows_Projects/blob/master/OpenGL_GLFW_Project/FSMRenderEngine.cpp | Github Open Source | Open Source | MIT | null | OpenGL_Windows_Projects | millerf1234 | C++ | Code | 9 | 51 | #include "FSMRenderEngine.h"
//FSMRenderEngine::FSMRenderEngine() {
//
//}
FSMRenderEngine::~FSMRenderEngine() {
}
| 36,160 |
https://github.com/ArtiomKolesnikov/WomanInterest/blob/master/app/Http/Controllers/CosmeticsController.php | Github Open Source | Open Source | MIT | null | WomanInterest | ArtiomKolesnikov | PHP | Code | 106 | 493 | <?php
namespace App\Http\Controllers;
use App\Post;
use Falur\Breadcrumbs\BreadcrumbsItem;
use Falur\Breadcrumbs\Contracts\Breadcrumbs;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Input;
use Symfony\Component\HttpFoundation\Session\Session;
class CosmeticsController extends Controller
{
public fu... | 43,872 |
https://github.com/delaco/Argo/blob/master/src/Argo/Commands/CommandInvokerCache.cs | Github Open Source | Open Source | MIT | null | Argo | delaco | C# | Code | 98 | 302 | using System.Collections.Concurrent;
namespace Argo.Commands
{
public class CommandInvokerCache
{
private readonly ICommandDescriptorCollectionProvider _collectionProvider;
private volatile InnerCache _currentCache;
public CommandInvokerCache(ICommandDescriptorCollectionProvider colle... | 26,357 |
https://github.com/callpraths/explore-georust/blob/master/harness/src/bin/area_numerical_stability.rs | Github Open Source | Open Source | Apache-2.0 | null | explore-georust | callpraths | Rust | Code | 450 | 1,648 | use geo::{
algorithm::area::Area, map_coords::MapCoords, CoordFloat, CoordNum, Coordinate, LineString,
Polygon,
};
use geos::{Geom, Geometry};
use serde::Serialize;
use std::f64::consts::PI;
fn main() {
let polygon = {
const NUM_VERTICES: usize = 10;
const ANGLE_INC: f64 = 2. * PI / NUM_VER... | 29,532 |
https://github.com/kubilaycaglayan/Personal-Projects/blob/master/5-javascript/PubSub/user_a.js | Github Open Source | Open Source | MIT | 2,020 | Personal-Projects | kubilaycaglayan | JavaScript | Code | 38 | 141 | const PubSub = require('PubSub');
const pubsub = new PubSub();
const onUserAdd = pubsub.subscribe('user_add', (data, topic) => {
console.log('User added');
console.log('user data:', data);
console.log(topic);
});
const published = pubsub.publish('user_add', {
firstName: 'John',
lastName: 'Doe',
email: 'j... | 24,242 |
https://github.com/ask-community/ask-community-decorators/blob/master/dist/lib/index.js | Github Open Source | Open Source | MIT | 2,021 | ask-community-decorators | ask-community | JavaScript | Code | 36 | 218 | "use strict";
Object.defineProperty(exports, "__esModule", { value: true });
var CanHandleIntentRequest_1 = require("./decorators/CanHandleIntentRequest");
exports.CanHandleIntentRequest = CanHandleIntentRequest_1.CanHandleIntentRequest;
var CanHandleLaunchRequest_1 = require("./decorators/CanHandleLaunchRequest");
exp... | 28,041 |
https://github.com/PARAGJYOTI/instabuy/blob/master/node_modules/oauth20-provider/test/authorizationCode_checkRefreshTokenGrant.js | Github Open Source | Open Source | MIT | 2,016 | instabuy | PARAGJYOTI | JavaScript | Code | 284 | 1,052 | var
query = require('querystring'),
request = require('supertest'),
data = require('./server/model/data.js'),
app = require('./server/app.js');
describe('Authorization Code Grant Type ',function() {
before(function() {
app.get('oauth2').model.client.checkGrantType = function(client, grant)... | 33,049 |
https://github.com/jpaw/jpaw/blob/master/jpaw-xml/src/main/java/de/jpaw/xml/jaxb/AbstractScaledDecimalAdapter.java | Github Open Source | Open Source | Apache-2.0 | null | jpaw | jpaw | Java | Code | 90 | 298 | package de.jpaw.xml.jaxb;
import java.math.BigDecimal;
import java.math.RoundingMode;
import jakarta.xml.bind.annotation.adapters.XmlAdapter;
public abstract class AbstractScaledDecimalAdapter extends XmlAdapter<String, BigDecimal> {
private final boolean allowRounding;
private final int scale;
protect... | 27,869 |
https://github.com/Mifrill/data/blob/master/packages/-ember-data/tests/integration/record-data/record-data-state-test.ts | Github Open Source | Open Source | MIT | 2,021 | data | Mifrill | TypeScript | Code | 694 | 2,256 | import EmberObject from '@ember/object';
import Ember from 'ember';
import { module, test } from 'qunit';
import { Promise } from 'rsvp';
import Model from 'ember-data/model';
import Store from 'ember-data/store';
import { setupTest } from 'ember-qunit';
import { RECORD_DATA_STATE } from '@ember-data/canary-features... | 43,606 |
https://github.com/whitemike889/libmonetra/blob/master/examples/run_sale/run_sale.c | Github Open Source | Open Source | MIT | 2,022 | libmonetra | whitemike889 | C | Code | 322 | 1,323 | /* Usage example for libmonetra.
*
* Runs a sale through the public TranSafe test server (test.transafe.com).
*
* To build, see instructions at top of CMakeLists.txt.
*/
#include <monetra_api.h>
static void trans_callback(LM_conn_t *conn, M_event_t *event, LM_event_type_t type, LM_trans_t *trans)
{
switch (type... | 12,898 |
https://github.com/aschampion/raveler-utils/blob/master/libstack/libstack.cpp | Github Open Source | Open Source | BSD-3-Clause | 2,015 | raveler-utils | aschampion | C++ | Code | 4,034 | 11,286 | #include <stdio.h>
#include "HdfStack.h"
#include "util.h"
#include "timers.h"
#include "util.h"
#include "BodyColorTable.h"
//
// libstack.cpp
//
// This is the C interface to HdfStack.
//
// HdfStack is a C++ class. C++ code can use HdfStack directly
// and not use the below. But Python code can use ctypes to cal... | 10,405 |
https://github.com/OpusSoluttio/iExpo-backend/blob/master/iExpo/Dominios/Interfaces/ISensores.cs | Github Open Source | Open Source | MIT | 2,020 | iExpo-backend | OpusSoluttio | C# | Code | 155 | 380 | using Dominios.Classes;
using System;
using System.Collections.Generic;
using System.Text;
namespace Dominios.Interfaces
{
public interface ISensores
{
/// <summary>
/// Lista todos sensores vindos do Banco de Dados
/// </summary>
/// <returns>Retorna uma lista com todos os sen... | 20,091 |
https://github.com/sahabi/OpenAMASE/blob/master/OpenAMASE/src/Core/avtas/map/image/DDSDecoder.java | Github Open Source | Open Source | LicenseRef-scancode-unknown-license-reference, LicenseRef-scancode-us-govt-public-domain, LicenseRef-scancode-warranty-disclaimer | 2,017 | OpenAMASE | sahabi | Java | Code | 1,099 | 2,838 | // ===============================================================================
// Authors: AFRL/RQQD
// Organization: Air Force Research Laboratory, Aerospace Systems Directorate, Power and Control Division
//
// Copyright (c) 2017 Government of the United State of America, as represented by
// the Secretary of th... | 42,785 |
https://github.com/gb-nick/PagerSlidingTabStrip/blob/master/app/src/main/java/com/example/tabstrip/MainActivity.java | Github Open Source | Open Source | MIT | 2,020 | PagerSlidingTabStrip | gb-nick | Java | Code | 94 | 392 | package com.example.tabstrip;
import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.view.View;
import android.view.Window;
import android.view.WindowManager;
import android.widget.Button;
import org.w3c.dom.Text;
public c... | 12,908 |
https://github.com/roth-andreas/NeurIPS2021-traffic4cast/blob/master/baselines/naive_weighted_average_from_stats.py | Github Open Source | Open Source | Apache-2.0 | 2,022 | NeurIPS2021-traffic4cast | roth-andreas | Python | Code | 946 | 3,151 | # Copyright 2021 Institute of Advanced Research in Artificial Intelligence (IARAI) GmbH.
# IARAI licenses this file to You 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/li... | 27,397 |
https://github.com/HaoweiCh/bin-html-template/blob/master/go.mod | Github Open Source | Open Source | Apache-2.0 | 2,020 | bin-html-template | HaoweiCh | Go Module | Code | 7 | 42 | module github.com/HaoweiCh/bin-html-template
go 1.15
require github.com/arschles/assert v1.0.0
| 37,796 |
https://github.com/ch1seL/EverCraft/blob/master/shared/src/main/kotlin/com/mazekine/libs/Cryptography.kt | Github Open Source | Open Source | Apache-2.0 | 2,022 | EverCraft | ch1seL | Kotlin | Code | 440 | 1,384 | package com.mazekine.libs
import org.slf4j.LoggerFactory
import java.nio.ByteBuffer
import java.security.NoSuchAlgorithmException
import java.security.SecureRandom
import java.security.spec.InvalidKeySpecException
import java.security.spec.KeySpec
import java.util.*
import javax.crypto.Cipher
import javax.crypto.Secre... | 44,798 |
https://github.com/Shiguang-Guo/fairseq/blob/master/fairseq/benchmark/dummy_masked_lm.py | Github Open Source | Open Source | MIT | 2,022 | fairseq | Shiguang-Guo | Python | Code | 275 | 955 | # Copyright (c) Facebook, Inc. and its affiliates.
#
# This source code is licensed under the MIT license found in the
# LICENSE file in the root directory of this source tree.
import logging
from dataclasses import dataclass, field
from typing import Optional
import torch
from omegaconf import II
from .dummy_datase... | 46,432 |
https://github.com/opendatafit/sasview/blob/master/src/sas/sascalc/simulation/geoshapespy/libgeoshapespy/ellipsoid.cc | Github Open Source | Open Source | BSD-3-Clause | null | sasview | opendatafit | C++ | Code | 389 | 1,437 | /** \file Ellipsoid.cc */
#include <cmath>
#include <cassert>
#include <algorithm>
//MS library does not define min max in algorithm
//#include "minmax.h"
#include "ellipsoid.h"
#include "myutil.h"
using namespace std;
Ellipsoid::Ellipsoid()
{
rx_ = 0;
ry_ = 0;
rz_ = 0;
}
Ellipsoid::Ellipsoid(double rx, double... | 12,018 |
https://github.com/vyuldashev/minter-console-web/blob/master/components/CoinCreateForm.vue | Github Open Source | Open Source | MIT | 2,021 | minter-console-web | vyuldashev | Vue | Code | 1,423 | 6,545 | <script>
import {validationMixin} from 'vuelidate';
import required from 'vuelidate/lib/validators/required.js';
import minValue from 'vuelidate/lib/validators/minValue.js';
import maxValue from 'vuelidate/lib/validators/maxValue.js';
import minLength from 'vuelidate/lib/validators/minLength.js';
import maxLength from ... | 47,153 |
https://github.com/anugraha07/HoNoSoFt.BadgeIt.SonarQube/blob/master/HoNoSoFt.BadgeIt.SonarQube.Web/Logics/SonarQubeColorsSteps/FinalBestValueColorStep.cs | Github Open Source | Open Source | MIT | 2,019 | HoNoSoFt.BadgeIt.SonarQube | anugraha07 | C# | Code | 105 | 407 | using HoNoSoFt.BadgeIt.SonarQube.Web.Models;
using System;
namespace HoNoSoFt.BadgeIt.SonarQube.Web.Logics.SonarQubeColorsSteps
{
internal class FinalBestValueColorStep : IColorStep
{
private IColorStep _successorTrue;
private IColorStep _successorFalse;
public FinalBestValueColorStep... | 6,923 |
https://github.com/relinkt/shipping-company-tier3/blob/master/resources/js/views/sample-pages/two-step-verification.vue | Github Open Source | Open Source | MIT | null | shipping-company-tier3 | relinkt | Vue | Code | 172 | 697 | <script>
import CodeInput from "vue-verification-code-input";
export default {
data() {
return {};
},
components: { CodeInput },
methods: {},
};
</script>
<template>
<div class="account-pages my-5 pt-sm-5">
<div class="container">
<div class="row">
<div class="col-lg-12">
<di... | 11,588 |
https://github.com/Ichcodealsobinich/Test/blob/master/Seminar/src/Quest856/Movie.java | Github Open Source | Open Source | MIT | null | Test | Ichcodealsobinich | Java | Code | 116 | 312 | package Quest856;
import java.util.Arrays;
public class Movie {
private String title = "";
private String[] actors = {"", "", ""};
public void setTitle(String name) {
this.title=name;
}
public boolean setActors(String[] someActors) {
if (someActors.length==actors.length) {
actors = someActors;
return ... | 18,728 |
https://github.com/c0ding/survey/blob/master/SPV/Home/controller/DRReportVC/DRReportViewController.m | Github Open Source | Open Source | Apache-2.0 | 2,019 | survey | c0ding | Objective-C | Code | 311 | 1,496 | //
// DRReportViewController.m
// SPV
//
// Created by 黄梦炜 on 2019/2/21.
// Copyright © 2019 训机. All rights reserved.
//
#import "DRReportViewController.h"
#import "DRReportLeftTableViewCell.h"
#import "DRReportRightTableViewCell.h"
#import "DRReportModel.h"
@interface DRReportViewController ()<UITableViewDelegate... | 48,047 |
https://github.com/Ellie-Yen/demo_project/blob/master/Other/bst_builder/bst_builder_serialize_deserializer.cs | Github Open Source | Open Source | BSD-2-Clause | null | demo_project | Ellie-Yen | C# | Code | 1,626 | 4,252 | /*------
C#
Elie yen
bst builder
@value of node: int (range between (+/-)2^31 - 1), duplicate is not allowed
@the format of string input/ output is a level-order representation eg:
[5 | 3, 8 | 2, 4, 7, 9 | 1, null, null, null, 6, null, null, null]
which '|' is a separator of different level and show null
------*/
// ... | 26,831 |
https://github.com/My-Novel-Management/storybuilderunite/blob/master/builder/core/formatter.py | Github Open Source | Open Source | MIT | 2,020 | storybuilderunite | My-Novel-Management | Python | Code | 252 | 832 | # -*- coding: utf-8 -*-
'''
Formatter Object
================
'''
from __future__ import annotations
__all__ = ('Reducer',)
from enum import Enum, auto
from builder.core.executer import Executer
from builder.datatypes.builderexception import BuilderError
from builder.datatypes.formatmode import FormatMode
from buil... | 48,866 |
https://github.com/xDanielus/SmallPets/blob/master/smallpets-1.15/src/main/java/it/smallcode/smallpets/v1_15/listener/experience/EntityDeathListener.java | Github Open Source | Open Source | MIT | 2,021 | SmallPets | xDanielus | Java | Code | 126 | 688 | package it.smallcode.smallpets.v1_15.listener.experience;
/*
Class created by SmallCode
25.08.2020 22:10
*/
import it.smallcode.smallpets.core.SmallPetsCommons;
import it.smallcode.smallpets.core.manager.ExperienceManager;
import it.smallcode.smallpets.core.manager.UserManager;
import it.smallcode.smallpets.core.man... | 49,902 |
https://github.com/riccardone/MySelfLog.Ui/blob/master/src/Diary/Diary.js | Github Open Source | Open Source | Apache-2.0 | 2,018 | MySelfLog.Ui | riccardone | JavaScript | Code | 257 | 826 | import React, { Component } from 'react';
import NavBarTop from '../navbar.top';
import Footer from '../footer';
import Bus from '../bus';
import DiaryLog from './DiaryLog';
import DiaryLink from './DiaryLink';
import DiaryReport from './DiaryReport';
import CreateDiary from './CreateDiary';
import { ToastContainer, to... | 25,758 |
https://github.com/fdietz/whistler_news_reader/blob/master/client/js/components/ClickOutside.js | Github Open Source | Open Source | MIT | 2,017 | whistler_news_reader | fdietz | JavaScript | Code | 77 | 250 | import React, { Component, PropTypes } from 'react';
export default class ClickOutside extends Component {
static propTypes = {
children: PropTypes.node,
onClickOutside: PropTypes.func.isRequired,
};
constructor(props) {
super(props);
this.handleClick = this.handleClick.bind(this);
}
comp... | 3,970 |
https://github.com/Jimmy2027/MMVAE_mnist_svhn_text/blob/master/tests/test_functions.py | Github Open Source | Open Source | MIT | null | MMVAE_mnist_svhn_text | Jimmy2027 | Python | Code | 520 | 1,838 | import tempfile
import pytest
from mmvae_hub.networks.FlowVaes import PlanarMixtureMMVae
from mmvae_hub.networks.MixtureVaes import MOEMMVae
from mmvae_hub.networks.utils.mixture_component_selection import mixture_component_selection
from mmvae_hub.utils.Dataclasses.Dataclasses import *
from tests.utils import set_me... | 967 |
https://github.com/ylhoony/fs-final-react/blob/master/src/containers/navs/Product.js | Github Open Source | Open Source | MIT | null | fs-final-react | ylhoony | JavaScript | Code | 88 | 306 | import React, { Component } from "react";
import { connect } from "react-redux";
import { Link, withRouter } from "react-router-dom";
import { Card, Segment } from "semantic-ui-react";
import BreadcrumbDisplay from "../../components/BreadcrumbDisplay";
class Product extends Component {
render() {
return (
... | 30,183 |
https://github.com/Maxopoly/cards-database/blob/master/data/Diamond & Pearl/Stormfront/100.ts | Github Open Source | Open Source | MIT | 2,022 | cards-database | Maxopoly | TypeScript | Code | 298 | 697 | import { Card } from '../../../interfaces'
import Set from '../Stormfront'
const card: Card = {
name: {
en: "Regigigas",
fr: "Regigigas LV.X",
},
illustrator: "Shizurow",
rarity: "Rare",
category: "Pokemon",
set: Set,
dexId: [
486,
],
hp: 150,
types: [
"Colorless",
],
evolveFrom: {
fr: "Regigiga... | 28,359 |
https://github.com/ProjectBlackFalcon/DatBot/blob/master/DatBot.ProtocolBuilder/Utils/messages/game/context/roleplay/job/JobDescriptionMessage.java | Github Open Source | Open Source | MIT | 2,019 | DatBot | ProjectBlackFalcon | Java | Code | 135 | 569 | package protocol.network.messages.game.context.roleplay.job;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
import protocol.utils.ProtocolTypeManager;
import protocol.network.util.types.BooleanByteWrapper;
import protocol.network.NetworkMessage;
import protocol.network.util.DofusDataRe... | 50,058 |
https://github.com/aravindhsampath/Grad_school_course_Projects/blob/master/Custom_Disk_Scheduler_822_Operating_Systems/822statspy.py | Github Open Source | Open Source | MIT | 2,015 | Grad_school_course_Projects | aravindhsampath | Python | Code | 286 | 803 | import matplotlib.pyplot as plt
# Read the stats as string from all three input files
f = open("stats_serv_time_optimal.csv","r") # optimal scheduler
f1 = open("stats2.csv","r") # deadline scheduler
f2 = open("stats_serv_time_cfq.csv","r") #CFQ scheduler
s = f.read()
s1 = f1.read()
s2 = f2.read()
# ... | 44,666 |
https://github.com/Gillani0/hazelcastcustomised/blob/master/hazelcast-jet-core/src/main/java/com/hazelcast/jet/application/Application.java | Github Open Source | Open Source | Apache-2.0 | null | hazelcastcustomised | Gillani0 | Java | Code | 417 | 906 | /*
* Copyright (c) 2008-2016, Hazelcast, Inc. All Rights Reserved.
*
* 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 ... | 42,170 |
https://github.com/collinsigeh-briigo/Paysupplier/blob/master/application/views/pages/success.php | Github Open Source | Open Source | LicenseRef-scancode-unknown-license-reference, MIT | 2,019 | Paysupplier | collinsigeh-briigo | PHP | Code | 57 | 265 | <div class="container">
<div class="card page-content">
<div class="row">
<div class="col-md-12">
<div class="row">
<div class="col-9">
<h2>Success</h2>
</div>
<div class="col-3 text-right">
<a class="btn btn-sm btn-secondary" href="<?php... | 25,422 |
https://github.com/globalnaturesoft-erp/erp-stock-transfers/blob/master/README.rdoc | Github Open Source | Open Source | MIT | null | erp-stock-transfers | globalnaturesoft-erp | RDoc | Code | 8 | 19 | = Erp::StockTransfers
This project rocks and uses MIT-LICENSE. | 20,858 |
https://github.com/Marcus-Rise/labwork/blob/master/src/services/AppService.ts | Github Open Source | Open Source | 0BSD | null | labwork | Marcus-Rise | TypeScript | Code | 31 | 77 | export class AppService {
private readonly _env: string;
get isDevMode(): boolean {
return this._env === "development";
}
constructor() {
this._env = process.env.NODE_ENV;
}
}
export const app: AppService = new AppService();
| 26,602 |
https://github.com/outtaspace/jip_debug/blob/master/lib/JIP/Debug.pm | Github Open Source | Open Source | Artistic-2.0 | null | jip_debug | outtaspace | Perl | Code | 1,356 | 3,862 | package JIP::Debug;
use base qw(Exporter);
use 5.006;
use strict;
use warnings;
use Term::ANSIColor 3.00 ();
use Devel::StackTrace;
use Carp qw(croak);
use Data::Dumper qw(Dumper);
use Fcntl qw(LOCK_EX LOCK_UN);
use English qw(-no_match_vars);
our $VERSION = '0.03';
our @EXPORT_OK = qw(
to_debug
to_debug_ra... | 5,977 |
https://github.com/rbb-data/airbnb-ratings/blob/master/src/components/_shared/BalanceGauge/BalanceGauge.module.sass | Github Open Source | Open Source | MIT | 2,019 | airbnb-ratings | rbb-data | Sass | Code | 116 | 336 | $red: #e31818
$grey: #D8D8D8
.balanceGauge
display: inline-block
position: relative
margin: .3em 0
.bar
width: 80px
margin-right: 10px
height: 3px
top: 50%
transform: translateY(-50%)
display: inline-block
.leftBarPart,
.rightBarPart
display: inline-block
height: 1... | 29,669 |
https://github.com/atveit/vespa/blob/master/document/src/main/java/com/yahoo/document/json/readers/StructReader.java | Github Open Source | Open Source | Apache-2.0 | 2,018 | vespa | atveit | Java | Code | 142 | 412 | // Copyright 2017 Yahoo Holdings. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
package com.yahoo.document.json.readers;
import com.yahoo.document.Field;
import com.yahoo.document.datatypes.FieldValue;
import com.yahoo.document.datatypes.StructuredFieldValue;
import com.yahoo.doc... | 47,960 |
https://github.com/ddwivedi08/ats/blob/master/src/constitutive_relations/ewc/permafrost_model.cc | Github Open Source | Open Source | BSD-3-Clause | 2,017 | ats | ddwivedi08 | C++ | Code | 871 | 4,037 | /* -*- mode: c++; c-default-style: "google"; indent-tabs-mode: nil -*- */
/*
Ugly hackjob to enable direct evaluation of the full model, on a single
WRM/region. This is bypassing much of the "niceness" of the framework, but
seems necessary for solving a cell-wise correction equation.
Uses intensive, not ext... | 46,220 |
https://github.com/Marvenlee/cheviot/blob/master/kernel/fs/write.c | Github Open Source | Open Source | Apache-1.1 | 2,021 | cheviot | Marvenlee | C | Code | 110 | 409 |
//#define KDEBUG
#include <kernel/dbg.h>
#include <kernel/filesystem.h>
#include <kernel/globals.h>
#include <kernel/proc.h>
#include <kernel/types.h>
#include <kernel/vm.h>
#include <sys/fsreq.h>
#include <sys/mount.h>
/*
*
*/
ssize_t Write(int fd, void *src, size_t sz) {
struct Filp *filp;
struct VNode *v... | 38,691 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.