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/kaywenith/TorchMPS/blob/master/torchmps/tests/benchmarks/test_benchmark_prob_mps.py | Github Open Source | Open Source | MIT | 2,022 | TorchMPS | kaywenith | Python | Code | 538 | 1,667 | # MIT License
#
# Copyright (c) 2021 Jacob Miller
#
# Permission is hereby granted, free of charge, to any person obtaining a copy of
# this software and associated documentation files (the "Software"), to deal in
# the Software without restriction, including without limitation the rights to
# use, copy, modify, merge,... | 14,675 |
https://github.com/diegorafaelvieira/Programacao-3/blob/master/Aula 10/Exercicios/aula10/Aula-10-Exemplos/exemplo_slide_25.php | Github Open Source | Open Source | MIT | null | Programacao-3 | diegorafaelvieira | PHP | Code | 34 | 124 | <!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Aula de PHP</title>
</head>
<body>
<?php
$nome = "Maria";
$idade = 30;
?>
<h1>Welcome, <?php echo $nome?>!</h1>
<p>
You have <?php echo $idade?> years old.
</p>
</body>
</html> | 4,635 |
https://github.com/collinsauve/csharp-driver/blob/master/src/Cassandra.IntegrationTests/MetadataTests/TokenMapTopologyChangeTests.cs | Github Open Source | Open Source | Apache-2.0, MIT | 2,019 | csharp-driver | collinsauve | C# | Code | 291 | 1,118 | //
// Copyright DataStax, Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by appli... | 9,341 |
https://github.com/Iyiola-am/webnotes/blob/master/resources/views/layouts/note.blade.php | Github Open Source | Open Source | MIT | 2,019 | webnotes | Iyiola-am | PHP | Code | 26 | 107 | <article class="card shadow-sm my-3">
<div class="card-body">
<a href="{{ route('notes.show', $note->id) }}" class="text text-primary d-3 card-title">{{ $note->title }}</p>
</div>
<div class="card-footer">
@include('layouts.action', ['note' => $note])
</div>
</article> | 20,675 |
https://github.com/dotnet/runtime/blob/master/src/libraries/Common/tests/System/Security/Cryptography/AlgorithmImplementations/EC/ECKeyPemTests.cs | Github Open Source | Open Source | MIT | 2,023 | runtime | dotnet | C# | Code | 920 | 8,258 | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
using System.Text;
using Test.Cryptography;
using Xunit;
namespace System.Security.Cryptography.Tests
{
[SkipOnPlatform(TestPlatforms.Browser, "Not supported on Browser")]
p... | 7,619 |
https://github.com/LSmyrnaios/exareme/blob/master/Exareme-Docker/src/mip-algorithms/mipframework/runner/__init__.py | Github Open Source | Open Source | MIT | 2,020 | exareme | LSmyrnaios | Python | Code | 7 | 22 | from .runner import create_runner
__all__ = ['create_runner'] | 7,309 |
https://github.com/orfeas0/kibana/blob/master/packages/kbn-optimizer/src/report_optimizer_stats.ts | Github Open Source | Open Source | Apache-2.0 | 2,020 | kibana | orfeas0 | TypeScript | Code | 249 | 519 | /*
* Licensed to Elasticsearch B.V. under one or more contributor
* license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright
* ownership. Elasticsearch B.V. licenses this file to you under
* the Apache License, Version 2.0 (the "License"); you may
* not u... | 18,461 |
https://github.com/NoelChaparro/CentroVision/blob/master/app/views/lentescontacto.blade.php | Github Open Source | Open Source | MIT | 2,015 | CentroVision | NoelChaparro | PHP | Code | 639 | 3,522 | @extends('layouts.baseother')
@section('titulo')
Operación Laser
@stop
@section('Contenido')
{{ Form::open(array('action' => 'LentesContactoController@guardarLentesContacto','class' => 'form-horizontal frmLentesContacto')) }}
<input type='hidden' name='varIdPaciente' id="varIdPaciente" value='{{$Paciente[0]->... | 9,873 |
https://github.com/HimanshuAgrahari07/Campaign_API/blob/master/src/dtos/signin.dto.ts | Github Open Source | Open Source | MIT | null | Campaign_API | HimanshuAgrahari07 | TypeScript | Code | 22 | 61 | import { IsString, IsNumber } from 'class-validator';
class SignInDto {
@IsString()
public email: string;
@IsString()
public password: string;
}
export default SignInDto;
| 12,337 |
https://github.com/binkley/basilisk/blob/master/basilisk-service/src/main/java/hm/binkley/basilisk/flora/chef/Chef.java | Github Open Source | Open Source | Unlicense | 2,019 | basilisk | binkley | Java | Code | 46 | 204 | package hm.binkley.basilisk.flora.chef;
import hm.binkley.basilisk.StandardDomain;
import hm.binkley.basilisk.flora.chef.store.ChefRecord;
import hm.binkley.basilisk.flora.chef.store.ChefRepository;
import hm.binkley.basilisk.flora.chef.store.ChefStore;
import lombok.EqualsAndHashCode;
import lombok.ToString;
@Equals... | 13,834 |
https://github.com/nujo/genieparser/blob/master/src/genie/libs/parser/ios/tests/test_show_routing.py | Github Open Source | Open Source | Apache-2.0 | 2,021 | genieparser | nujo | Python | Code | 426 | 2,089 | import unittest
from unittest.mock import Mock
# ATS
from pyats.topology import Device
from genie.metaparser.util.exceptions import SchemaEmptyParserError, \
SchemaMissingKeyError
from genie.libs.parser.ios.show_routing import (ShowIpRoute,
... | 14,773 |
https://github.com/boberfly/the-forge-glfw/blob/master/external/the-forge/Common_3/OS/FileSystem/ZipFileSystem.cpp | Github Open Source | Open Source | Apache-2.0 | 2,020 | the-forge-glfw | boberfly | C++ | Code | 399 | 963 | ///*
// * Copyright (c) 2018-2021 The Forge Interactive Inc.
// *
// * This file is part of The-Forge
// * (see https://github.com/ConfettiFX/The-Forge).
// *
// * Licensed to the Apache Software Foundation (ASF) under one
// * or more contributor license agreements. See the NOTICE file
// * distributed with this work... | 18,822 |
https://github.com/OpenLocalizationTestOrg/ECMA2YamlTestRepo2/blob/master/fulldocset/add/codesnippet/CSharp/m-system.data.oledb.oled_3_1.cs | Github Open Source | Open Source | CC-BY-4.0, MIT | 2,017 | ECMA2YamlTestRepo2 | OpenLocalizationTestOrg | C# | Code | 22 | 70 | public void CreateOleDbParameter()
{
OleDbParameter parameter = new OleDbParameter();
parameter.ParameterName = "Description";
parameter.OleDbType = OleDbType.VarChar;
parameter.Direction = ParameterDirection.Output;
parameter.Size = 88;
} | 243 |
https://github.com/yarikbratashchuk/NNfSiX/blob/master/R/p001.r | Github Open Source | Open Source | MIT | 2,022 | NNfSiX | yarikbratashchuk | R | Code | 29 | 76 | inputs <- c(1.2, 5.1, 2.1)
weights <- c(3.1, 2.1, 8.7)
bias <- 3
output <- inputs[1] * weights[1] + inputs[2] * weights[2] + inputs[3] * weights[3] + bias
output
| 51,084 |
https://github.com/jasonpmcculloch/pure_interface/blob/master/pure_interface.py | Github Open Source | Open Source | MIT | 2,017 | pure_interface | jasonpmcculloch | Python | Code | 2,266 | 6,916 | try:
from abc import abstractmethod, abstractproperty, abstractclassmethod, abstractstaticmethod
except ImportError:
from abc import abstractmethod, abstractproperty
class abstractclassmethod(classmethod):
__isabstractmethod__ = True
def __init__(self, callable):
callable.__is... | 44,234 |
https://github.com/TPNguyen/ThunderRW/blob/master/random_walk/uniform_sampling.h | Github Open Source | Open Source | MIT | 2,021 | ThunderRW | TPNguyen | C | Code | 454 | 1,588 | //
// Created by Shixuan Sun on 11/28/20.
//
#ifndef XTRAGRAPHCOMPUTING_UNIFORM_SAMPLING_H
#define XTRAGRAPHCOMPUTING_UNIFORM_SAMPLING_H
#include "types.h"
#include "amac_frame.h"
void uniform_interleaving_move(Graph *graph, BufferSlot *ring, sfmt_t *sfmt, int length) {
// Stage 1: generate random number & prefe... | 17,588 |
https://github.com/tommy351/kosko/blob/master/packages/config/src/types.ts | Github Open Source | Open Source | MIT | 2,023 | kosko | tommy351 | TypeScript | Code | 118 | 358 | import {
array,
string,
object,
assign,
optional,
record,
boolean,
integer,
min
} from "superstruct";
/**
* Environment config type.
*
* @public
*/
export interface EnvironmentConfig {
require?: string[];
components?: string[];
loaders?: string[];
}
export const environmentConfigSchema = o... | 40,340 |
https://github.com/xiayingfeng/blaze-persistence/blob/master/entity-view/impl/src/main/java/com/blazebit/persistence/view/impl/entity/InverseElementToEntityMapper.java | Github Open Source | Open Source | ECL-2.0, Apache-2.0 | null | blaze-persistence | xiayingfeng | Java | Code | 149 | 354 | /*
* Copyright 2014 - 2022 Blazebit.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agre... | 22,092 |
https://github.com/lcmr/practica1-g2/blob/master/application/views/layout/footer.php | Github Open Source | Open Source | MIT | null | practica1-g2 | lcmr | PHP | Code | 17 | 90 | <!-- Bootstrap core JavaScript -->
<script src="<?php echo base_url('library/users/vendor/jquery/jquery.min.js'); ?>"></script>
<script src="<?php echo base_url('library/users/vendor/bootstrap/js/bootstrap.bundle.min.js'); ?>"></script>
</body>
</html>
| 30,642 |
https://github.com/AndersonMGarcia/Modulo1-Introducao/blob/master/11-ExercicioPraticoVariaveis/index.php | Github Open Source | Open Source | MIT | null | Modulo1-Introducao | AndersonMGarcia | PHP | Code | 85 | 386 | <!DOCTYPE html>
<html lang="pt-br">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Exercício Prático - Variáveis</title>
</head>
<body>
<pre>
<?php
$lista = [
... | 25,521 |
https://github.com/randiayeshanikossinna/Log-Analyser/blob/master/src/main/java/com/ConstructionTeam/FileRepository/FileReaderBuffered.java | Github Open Source | Open Source | MIT | null | Log-Analyser | randiayeshanikossinna | Java | Code | 48 | 149 | package com.ConstructionTeam.FileRepository;
import java.io.BufferedReader;
import java.io.FileNotFoundException;
import java.io.FileReader;
import java.io.IOException;
public class FileReaderBuffered implements InputFileReader {
@Override
public BufferedReader readFile(String path) {
FileReader fileR... | 27,082 |
https://github.com/SagePtr/TwelveMonkeys/blob/master/sandbox/sandbox-common/src/main/java/com/twelvemonkeys/io/FileLockingTest.java | Github Open Source | Open Source | BSD-3-Clause | 2,022 | TwelveMonkeys | SagePtr | Java | Code | 361 | 739 | /*
* Copyright (c) 2009, Harald Kuhr
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* * Redistributions of source code must retain the above copyright notice,
* this list of c... | 39,862 |
https://github.com/caffeinehit/cuffs.js/blob/master/src/compiler.coffee | Github Open Source | Open Source | MIT | 2,013 | cuffs.js | caffeinehit | CoffeeScript | Code | 90 | 215 | define ['./ns'], (Cuffs) ->
STOP_DESCENT = 'stop-descent-+"*' # Random string, easier equality comparison
walk = (tree, callback)->
# Walk a DOM tree depth first and call a callback on
# each node. Escape current descent if the callback returns
# STOP_DESCENT and continue with next sibl... | 9,044 |
https://github.com/Andarin/Java_project_studies/blob/master/WkVonMuenzenHerausfinden/Main.java | Github Open Source | Open Source | Apache-2.0 | null | Java_project_studies | Andarin | Java | Code | 295 | 943 | import java.math.BigInteger;
/*
* Modell: Es gibt 5 Messreihen, die von 2 gezinkten Muenzen stammen. Man weiß nicht, welche Messreihen
* von welcher Muenze stammen, und will nun die wahrscheinlichsten Wk der Muenzen herausfinden.
*/
public class Main {
public static int iteration = 100;
public static int[][] mess... | 13,796 |
https://github.com/fused-effects/fused-effects/blob/master/src/Control/Carrier/Empty/Maybe.hs | Github Open Source | Open Source | BSD-3-Clause | 2,023 | fused-effects | fused-effects | Haskell | Code | 420 | 895 | {-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE MultiParamTypeClasses #-}
{-# LANGUAGE TypeOperators #-}
{-# LANGUAGE UndecidableInstances #-}
{- | A carrier for an 'Empty' effect, indicating failure with a 'Nothing' value. Users that need access to an error message should u... | 7,144 |
https://github.com/neoPix/Edely/blob/master/Lib/Edely/Tool/SqlConnection.class.php | Github Open Source | Open Source | Apache-2.0 | 2,014 | Edely | neoPix | PHP | Code | 285 | 1,058 | <?php
/**
* Classe SqlConnection
* @role: Gestion de la connexion a une base de donnée
* @creator: Balan David
* @updated: 01/06/2013
**/
class SqlConnection{
private static $_connections;
private $_con=null;
private $_stm=null;
public $name = '';
private function __construct($connection='defa... | 20,702 |
https://github.com/ewaters/screenshots/blob/master/test/base/all_tests.dart | Github Open Source | Open Source | BSD-2-Clause-FreeBSD | 2,022 | screenshots | ewaters | Dart | Code | 9 | 37 | import 'process_common_test.dart' as process_common_test;
void main() {
process_common_test.main();
}
| 16,828 |
https://github.com/asrani27/kosmetik/blob/master/app/Http/Controllers/KeranjangController.php | Github Open Source | Open Source | MIT | null | kosmetik | asrani27 | PHP | Code | 137 | 606 | <?php
namespace App\Http\Controllers;
use Alert;
use App\Barang;
use App\Keranjang;
use Illuminate\Http\Request;
class KeranjangController extends Controller
{
public function add(Request $req)
{
$checkStok = Barang::find($req->barang_id)->stok;
$checkKeranjang = Keranjang::where('barang_id',... | 49,017 |
https://github.com/kzvd4729/Problem-Solving/blob/master/UVa/UVA - 10871/Accepted.cpp | Github Open Source | Open Source | MIT | 2,022 | Problem-Solving | kzvd4729 | C++ | Code | 109 | 622 | /****************************************************************************************
* @author: kzvd4729 created: 2018-03-21 19:19:23
* solution_verdict: Accepted language: C++
* run... | 32,431 |
https://github.com/aitorventura/folklore-musical-exchange-backend/blob/master/src/chat/chat.controller.ts | Github Open Source | Open Source | MIT | null | folklore-musical-exchange-backend | aitorventura | TypeScript | Code | 295 | 1,003 | import {
Controller,
Get,
Post,
Body,
Delete,
Put,
Param,
UseGuards,
ForbiddenException,
} from '@nestjs/common';
import { ChatDto } from '../chat/chat.dto';
import { MessageDto } from '../chat/message.dto';
import { ChatService } from '../chat/chat.service';
import { ChatDataBaseConnection } from './... | 10,569 |
https://github.com/ankushjamdagani/semantic-chat/blob/master/client/src/store/reducers.js | Github Open Source | Open Source | MIT | null | semantic-chat | ankushjamdagani | JavaScript | Code | 28 | 107 | import { combineReducers } from "redux";
import logoutReducer from "../components/hoc/with-logout/reducers";
import authReducer from "../components/views/auth/reducers";
import homeReducer from "../components/views/home/reducers";
export default combineReducers({
logout: logoutReducer,
auth: authReducer,
home: ... | 21,263 |
https://github.com/mrcece/ColaFrameWork/blob/master/Assets/3rd/Behavior Designer/Runtime/Basic Tasks/GameObject/Find.cs | Github Open Source | Open Source | MIT | 2,022 | ColaFrameWork | mrcece | C# | Code | 61 | 190 | using UnityEngine;
namespace BehaviorDesigner.Runtime.Tasks.Basic.UnityGameObject
{
[TaskCategory("Basic/GameObject")]
[TaskDescription("Finds a GameObject by name. Returns Success.")]
public class Find : Action
{
[Tooltip("The GameObject name to find")]
public SharedString gameObjectNa... | 40,368 |
https://github.com/ckrause/loda/blob/master/programs/oeis/189/A189480.asm | Github Open Source | Open Source | Apache-2.0 | 2,021 | loda | ckrause | Assembly | Code | 30 | 289 | ; A189480: [4rn]-4[rn], where r=sqrt(5) and [ ]=floor.
; 0,1,2,3,0,1,2,3,0,1,2,3,0,1,2,3,0,0,1,2,3,0,1,2,3,0,1,2,3,0,1,2,3,0,1,1,2,3,0,1,2,3,0,1,2,3,0,1,2,3,0,1,2,2,3,0,1,2,3,0,1,2,3,0,1,2,3,0,1,2,3,3,0,1,2,3,0,1,2,3,0,1,2,3,0,1,2,3,0,0,1,2,3,0,1,2,3,0,1,2
mul $0,2
add $0,2
mul $0,4
seq $0,60143 ; a(n) = floor(n/tau),... | 34,425 |
https://github.com/illia-okonskyi/PostCore/blob/master/src/PostCore/PostCore.Core/Services/Dao/MailDao.cs | Github Open Source | Open Source | MIT | null | PostCore | illia-okonskyi | C# | Code | 1,050 | 3,510 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Microsoft.EntityFrameworkCore;
using PostCore.Core.Activities;
using PostCore.Core.Branches;
using PostCore.Core.Cars;
using PostCore.Core.DbContext;
using PostCore.Core.Mail;
using PostCore.Core.U... | 855 |
https://github.com/dayansoft01/screenshot/blob/master/lib/src/platform_specific/file_manager/file_manager.dart | Github Open Source | Open Source | MIT | 2,022 | screenshot | dayansoft01 | Dart | Code | 29 | 116 | import 'dart:typed_data';
// import 'file_manager_mobile.dart';
import 'file_manager_stub.dart'
if (dart.library.io) "file_manager_io.dart"
if (dart.library.html) "non_io.dart";
abstract class PlatformFileManager {
factory PlatformFileManager() => getFileManager();
Future<String> saveFile(Uint8List fileCo... | 18,621 |
https://github.com/MichaelLogutov/Rocks.Commands/blob/master/src/Rocks.Commands.Tests/Decorators/Async/Commands/IDecoratableAsyncCommand.cs | Github Open Source | Open Source | MIT | 2,019 | Rocks.Commands | MichaelLogutov | C# | Code | 15 | 49 | namespace Rocks.Commands.Tests.Decorators.Async.Commands
{
internal interface IDecoratableAsyncCommand
{
int Number { get; set; }
}
} | 49,667 |
https://github.com/icestudent/ontl/blob/master/ntl/format.hxx | Github Open Source | Open Source | Zlib, LicenseRef-scancode-stlport-4.5 | 2,022 | ontl | icestudent | C++ | Code | 649 | 1,951 | /**\file*********************************************************************
* \brief
*
*
****************************************************************************
*/
#ifndef NTL__FORMAT
#define NTL__FORMAT
#pragma once
#include "basedef.hxx"... | 20,259 |
https://github.com/austince/flink/blob/master/flink-formats/flink-orc/src/test/java/org/apache/flink/orc/OrcFileSystemITCase.java | Github Open Source | Open Source | MIT, Apache-2.0, MIT-0, BSD-3-Clause | 2,020 | flink | austince | Java | Code | 204 | 503 | /*
* 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 ... | 31,517 |
https://github.com/abdulsamadola/hospital-finder/blob/master/src/components/Home/Home.scss | Github Open Source | Open Source | MIT | 2,021 | hospital-finder | abdulsamadola | SCSS | Code | 116 | 396 | #components-dropdown-demo-dropdown-button .ant-dropdown-button {
margin: 0 8px 8px 0;
}
#components-dropdown-demo-dropdown-button
.ant-btn-group-rtl.ant-dropdown-button {
margin: 0 0 8px 8px;
}
.header {
position: sticky;
top: 0;
z-index: 999999999;
-webkit-box-shadow: 10px 10px 39px -4px rgba(0, 0, 0, 0... | 17,026 |
https://github.com/JackTheRipper42/Binding/blob/master/Assets/Scripts/BindingTest/ViewModel.cs | Github Open Source | Open Source | MIT | null | Binding | JackTheRipper42 | C# | Code | 295 | 964 | using Assets.Scripts.Binding;
using UnityEngine;
namespace Assets.Scripts.BindingTest
{
public class ViewModel
{
public readonly NotifyingObject<Vector3> PositionProperty;
public readonly NotifyingObject<string> UpButtonTextProperty;
public readonly NotifyingObject<string> DownButtonTe... | 33,968 |
https://github.com/AaronCGoidel/CLImate/blob/master/interactions/__init__.py | Github Open Source | Open Source | BSD-3-Clause | 2,021 | CLImate | AaronCGoidel | Python | Code | 62 | 99 | """CLImate: Interactions package
Classes which implement various interactions with the user via command line
YesNo: prompts the user with a yes or no question
Selector: prompts the user with a list of options from which they may choose a specified number
Created by: Aaron Goidel
"""
from .interaction import Interact... | 38,944 |
https://github.com/cortexapps/datadog-api-client-java/blob/master/src/main/java/com/datadog/api/v1/client/model/SyntheticsTriggerCITestsResponse.java | Github Open Source | Open Source | Apache-2.0 | 2,022 | datadog-api-client-java | cortexapps | Java | Code | 590 | 2,147 | /*
* Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License.
* This product includes software developed at Datadog (https://www.datadoghq.com/).
* Copyright 2019-Present Datadog, Inc.
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-gen... | 50,239 |
https://github.com/ArrogantWombatics/openbsd-src/blob/master/gnu/usr.bin/perl/t/uni/universal.t | Github Open Source | Open Source | BSD-3-Clause | 2,019 | openbsd-src | ArrogantWombatics | Perl | Code | 475 | 1,605 | #!./perl
#
# check UNIVERSAL
#
BEGIN {
chdir 't' if -d 't';
@INC = '../lib';
$| = 1;
require "./test.pl";
}
use utf8;
use open qw( :utf8 :std );
plan tests => 93;
$a = {};
bless $a, "Bòb";
ok $a->isa("Bòb");
package Hùmàn;
sub èàt {}
package Fèmàlè;
@ISA=qw(Hùmàn);
package Àlìcè;
@ISA=qw(Bòb Fèmà... | 50,421 |
https://github.com/jamescaoBJ/springcloud/blob/master/springboot-dao/src/main/java/com/ncme/springboot/mapper/NcmeCourseTypeMapper.java | Github Open Source | Open Source | Apache-2.0 | null | springcloud | jamescaoBJ | Java | Code | 15 | 72 | package com.ncme.springboot.mapper;
import com.ncme.springboot.model.NcmeCourseType;
public interface NcmeCourseTypeMapper {
int insert(NcmeCourseType record);
int insertSelective(NcmeCourseType record);
} | 17,161 |
https://github.com/Drebakare/lex-management-system/blob/master/resources/views/Pages/Old/Actions/create-product-drinktype.blade.php | Github Open Source | Open Source | MIT | null | lex-management-system | Drebakare | PHP | Code | 470 | 2,240 | @extends('admin_app')
@section('contents')
<div class="page-content">
<div class="container-fluid">
<!-- start page title -->
<div class="row">
<div class="col-12">
<div class="page-title-box d-flex align-items-center justify-content-between">
... | 25,558 |
https://github.com/madsendennis/scalismo/blob/master/src/main/scala/scalismo/sampling/proposals/MHMixtureProposal.scala | Github Open Source | Open Source | Apache-2.0 | 2,023 | scalismo | madsendennis | Scala | Code | 291 | 729 | /*
* Copyright 2016 University of Basel, Graphics and Vision Research Group
*
* 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
*
* Unl... | 22,930 |
https://github.com/miguelpuyol/hermes/blob/master/hermes-consumers/src/main/java/pl/allegro/tech/hermes/consumers/consumer/rate/calculator/MaximumOutputRateCalculator.java | Github Open Source | Open Source | Apache-2.0 | 2,017 | hermes | miguelpuyol | Java | Code | 35 | 186 | package pl.allegro.tech.hermes.consumers.consumer.rate.calculator;
import pl.allegro.tech.hermes.api.Subscription;
import pl.allegro.tech.hermes.consumers.consumer.ActiveConsumerCounter;
class MaximumOutputRateCalculator {
private final ActiveConsumerCounter activeConsumerCounter;
MaximumOutputRateCalculato... | 50,467 |
https://github.com/lilyclemson/delete_it/blob/master/ML/Trees.ecl | Github Open Source | Open Source | MIT | null | delete_it | lilyclemson | ECL | Code | 5,695 | 17,911 | IMPORT ML;
IMPORT * FROM $;
IMPORT $.Mat;
IMPORT * FROM ML.Types;
IMPORT * FROM ML.Sampling;
EXPORT Trees := MODULE
EXPORT t_node := INTEGER4; // Assumes a maximum of 32 levels presently
SHARED t_Index:= INTEGER4;
EXPORT t_level := INTEGER1; // Would allow up to 2^256 levels
EXPORT Node := RECORD
t_node nod... | 41,611 |
https://github.com/KiroTheBlueFox/MoBlocks/blob/master/src/main/java/kirothebluefox/moblocks/content/decoration/colorableflowerpot/ColorableFlowerPotTileRenderer.java | Github Open Source | Open Source | MIT | 2,023 | MoBlocks | KiroTheBlueFox | Java | Code | 132 | 761 | package kirothebluefox.moblocks.content.decoration.colorableflowerpot;
import com.mojang.blaze3d.vertex.PoseStack;
import kirothebluefox.moblocks.content.ModTileEntities;
import net.minecraft.client.Minecraft;
import net.minecraft.client.color.block.BlockColors;
import net.minecraft.client.renderer.ItemBlockRenderType... | 41,628 |
https://github.com/limiao2008/ActivitiSourceCode/blob/master/modules/activiti-bpmn-converter/src/main/java/org/activiti/bpmn/converter/BpmnXMLConverter.java | Github Open Source | Open Source | Apache-2.0 | 2,021 | ActivitiSourceCode | limiao2008 | Java | Code | 2,145 | 11,681 | /* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distribut... | 48,513 |
https://github.com/jpdoyle/verifast/blob/master/examples/busywaiting/clhlock/clhlock.c | Github Open Source | Open Source | MIT | 2,023 | verifast | jpdoyle | C | Code | 2,324 | 8,190 | // Tobias Reinhard and Bart Jacobs. Ghost signals: verifying termination of busy-waiting. 2020.
//@ #include "ghost_lists.gh"
#include <stdlib.h>
#include "atomics.h"
#include "clhlock.h"
//@ #include <quantifiers.gh>
struct node {
int lock;
//@ struct node *pred;
//@ real frac;
//@ void *signal;
... | 8,168 |
https://github.com/ocanbascil/validation-draft/blob/master/exercises/util.py | Github Open Source | Open Source | MIT | 2,021 | validation-draft | ocanbascil | Python | Code | 115 | 355 |
def compare(expected, actual, path=''):
"""Recursive comparator to help with debugging"""
assert type(expected) == type(actual), 'Different types, path: {}'.format(path)
if isinstance(actual, dict):
missing = set(expected.keys()).difference(actual.keys())
extra = set(actual.keys()).differ... | 34,230 |
https://github.com/samjf/silverstripe4-docker-example/blob/master/asset-admin/client/src/mocks/react-redux.js | Github Open Source | Open Source | BSD-3-Clause | 2,017 | silverstripe4-docker-example | samjf | JavaScript | Code | 9 | 18 | export function connect() {
return (Component) => Component;
}
| 16,216 |
https://github.com/excalidraw/excalidraw/blob/master/src/components/DialogActionButton.tsx | Github Open Source | Open Source | MIT, LicenseRef-scancode-free-unknown | 2,023 | excalidraw | excalidraw | TSX | Code | 111 | 340 | import clsx from "clsx";
import { ReactNode } from "react";
import "./DialogActionButton.scss";
import Spinner from "./Spinner";
interface DialogActionButtonProps {
label: string;
children?: ReactNode;
actionType?: "primary" | "danger";
isLoading?: boolean;
}
const DialogActionButton = ({
label,
onClick,
... | 33,980 |
https://github.com/christyfernandes/Paathshala/blob/master/src/app/client/src/app/modules/shared/services/util/util.service.spec.data.ts | Github Open Source | Open Source | MIT | null | Paathshala | christyfernandes | TypeScript | Code | 984 | 4,195 | export const servicemockRes = {
formData: {
'code': 'board',
'dataType': 'text',
'name': 'Board',
'label': 'Board/Syllabus',
'description': 'Education Board (Like MP Board, NCERT, etc)',
'editable': true,
'inputType': 'select',
'required': false,
'displayProperty': 'Editable',
... | 20,135 |
https://github.com/dereklamego/JavaPoo/blob/master/ManipulacaoFiles/src/manipulacaofiles/FilesOperations.java | Github Open Source | Open Source | MIT | null | JavaPoo | dereklamego | Java | Code | 154 | 570 | package manipulacaofiles;
import java.io.File;
import java.io.FileNotFoundException;
import java.io.FileWriter;
import java.io.IOException;
import java.util.InputMismatchException;
import java.util.Scanner;
public class FilesOperations {
File arquivoCriado = new File("info.txt"); //um atributo do tipo file para a... | 14,164 |
https://github.com/CrackerCat/snail/blob/master/snail/src/main/java/com/acgist/snail/net/torrent/dht/request/FindNodeRequest.java | Github Open Source | Open Source | Apache-2.0 | 2,023 | snail | CrackerCat | Java | Code | 104 | 438 | package com.acgist.snail.net.torrent.dht.request;
import com.acgist.snail.config.DhtConfig;
import com.acgist.snail.net.torrent.dht.DhtRequest;
import com.acgist.snail.net.torrent.dht.NodeContext;
import com.acgist.snail.net.torrent.dht.response.FindNodeResponse;
/**
* <p>查找Node</p>
*
* @author acgist
*/
public ... | 23,651 |
https://github.com/neoedmund/neoeedit/blob/master/scripts/Concat1.java | Github Open Source | Open Source | BSD-3-Clause | 2,023 | neoeedit | neoedmund | Java | Code | 51 | 154 |
import java.util.ArrayList;
import java.util.List;
import neoe.ne.Script;
/** Prototype of Concat lines to a single line */
public class Concat1 implements Script {
@Override
public List<CharSequence> run(List<CharSequence> lines) {
List<CharSequence> ret = new ArrayList<CharSequence>();
StringBuilder sb = ne... | 36,481 |
https://github.com/hmrc/customs-declare-exports-frontend/blob/master/test/services/SubmissionServiceSpec.scala | Github Open Source | Open Source | Apache-2.0 | 2,023 | customs-declare-exports-frontend | hmrc | Scala | Code | 564 | 2,216 | /*
* Copyright 2023 HM Revenue & Customs
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or a... | 43,388 |
https://github.com/gsilvers/maptz.vscode.extensions.customfolding/blob/master/src/engine/RegionServices.ts | Github Open Source | Open Source | MIT | 2,022 | maptz.vscode.extensions.customfolding | gsilvers | TypeScript | Code | 147 | 435 | /* #region Imports */
"use strict";
import * as vscode from "vscode";
import * as config from "./../config/Configuration";
import {RegionProvider, CustomRegion} from "./CustomRegions";
/* #endregion */
/* #region RegionService */
export class RegionService {
regionProvider: RegionProvider;
document: vscode... | 32,688 |
https://github.com/sndnv/stasis/blob/master/client-android/lib/src/main/kotlin/stasis/client_android/lib/model/server/api/requests/CreateDatasetDefinition.kt | Github Open Source | Open Source | Apache-2.0 | 2,023 | stasis | sndnv | Kotlin | Code | 41 | 200 | package stasis.client_android.lib.model.server.api.requests
import com.squareup.moshi.Json
import com.squareup.moshi.JsonClass
import stasis.client_android.lib.model.server.datasets.DatasetDefinition
import stasis.client_android.lib.model.server.devices.DeviceId
@JsonClass(generateAdapter = true)
data class CreateDat... | 4,532 |
https://github.com/FernandoGomezS/Masisa/blob/master/deletejpg.php | Github Open Source | Open Source | MIT | null | Masisa | FernandoGomezS | PHP | Code | 7 | 41 | <?php
$data = $_POST['jpg'];
unlink('/sites/masisa/images/'.$data)or print_r(error_get_last());
?> | 21,087 |
https://github.com/cthacker-udel/NCT-AndroidGUI/blob/master/app/src/main/java/com/example/nctai_trading/bittrex/WalletHealth.java | Github Open Source | Open Source | Apache-2.0 | null | NCT-AndroidGUI | cthacker-udel | Java | Code | 202 | 633 | /*
* *
* This file is part of the bittrex4j project.
*
* @author CCob
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
* /
*/
package com.example.nctai_trading.bittrex;
import com.fasterxml.jackson.annotation.JsonCreator;
impor... | 30,456 |
https://github.com/KnxAssociation/api-client/blob/master/KNX/Api/Contact.php | Github Open Source | Open Source | MIT | null | api-client | KnxAssociation | PHP | Code | 266 | 705 | <?php
/**
* KNX Api
*
* This file is a part of the KNX Api client
*
* @package KNX Api
*/
namespace KNX\Api;
class Contact {
/**
* ID
*
* @access public
* @var int $id
*/
public $id;
/**
* Details
*
* @var $details
* @access private
*/
public $details;
/**
* Contructor
*
* @acces... | 30,464 |
https://github.com/letssteam/codal-stm32-B-L475E-IOT01A/blob/master/samples/Basic/MessageBus/MessageBus_Sample.cpp | Github Open Source | Open Source | MIT | null | codal-stm32-B-L475E-IOT01A | letssteam | C++ | Code | 31 | 180 | #include "MessageBus_Sample.h"
using namespace codal;
SampleMessageBus* sample;
void MessageBusSample_main(codal::STM32DISCO_L475VG_IOT& discoL475VgIot)
{
sample = new SampleMessageBus(discoL475VgIot);
while (true) {
discoL475VgIot.io.led1.setDigitalValue(sample->state ? 1 : 0);
discoL475VgI... | 19,896 |
https://github.com/andela-jejezie/peopleProject/blob/master/node_modules/grunt-nodemon/node_modules/nodemon/lib/index.js | Github Open Source | Open Source | MIT | 2,022 | peopleProject | andela-jejezie | JavaScript | Code | 3 | 10 | module.exports = require('./nodemon'); | 18,317 |
https://github.com/puneet1999/Ryujinx/blob/master/Ryujinx.Cpu/MemoryManager.cs | Github Open Source | Open Source | MIT | 2,022 | Ryujinx | puneet1999 | C# | Code | 2,311 | 6,115 | using ARMeilleure.Memory;
using Ryujinx.Cpu.Tracking;
using Ryujinx.Memory;
using Ryujinx.Memory.Tracking;
using System;
using System.Collections.Generic;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Threading;
namespace Ryujinx.Cpu
{
/// <summary>
/// Represents a... | 27,576 |
https://github.com/catercow/react-apollo/blob/master/test/client/graphql/queries/polling.test.tsx | Github Open Source | Open Source | MIT | null | react-apollo | catercow | TypeScript | Code | 477 | 1,257 | import React from 'react';
import renderer from 'react-test-renderer';
import gql from 'graphql-tag';
import ApolloClient from 'apollo-client';
import { InMemoryCache as Cache } from 'apollo-cache-inmemory';
import { mockSingleLink } from '../../../../src/test-utils';
import { ApolloProvider, graphql, ChildProps } from... | 38,396 |
https://github.com/Lin0818/py-study-notebook/blob/master/notebook/vector_v1.py | Github Open Source | Open Source | Apache-2.0 | 2,018 | py-study-notebook | Lin0818 | Python | Code | 89 | 339 | #vector_v1.py
#multi-dimensional Vector class
from array import array
import reprlib
import math
class Vector:
typecode = 'd'
def __init__(self, components):
self.__components = array(self.typecode, components)
self._score = 3
@property
def score(self):
return self._score
... | 26,817 |
https://github.com/aevv/qcmd/blob/master/QCmd/QCmd/Commands/QCommandDefinition.cs | Github Open Source | Open Source | Apache-2.0 | 2,015 | qcmd | aevv | C# | Code | 47 | 121 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace QCmd.Commands
{
class QCommandDefinition
{
public string Command { get; set; }
public IList<string> Parameters { get; set; }
public bool HideOnFinish { get; set... | 30,662 |
https://github.com/snumrl/TillingPatch/blob/master/program/lego/tgasave.h | Github Open Source | Open Source | Apache-2.0 | 2,022 | TillingPatch | snumrl | C | Code | 155 | 337 | // +-------------------------------------------------------------------------
// | tgasave.h
// |
// | Author: Manmyung Kim
// +-------------------------------------------------------------------------
// | COPYRIGHT:
// | Copyright Manmyung Kim 2013
// | See the included COPYRIGHT.txt file for further details.
... | 22,727 |
https://github.com/mottl-jan/koin/blob/master/koin-projects/examples/multimodule-ktor/module-b/src/main/kotlin/org/koin/samples/multi_module/module_b/ModuleBService.kt | Github Open Source | Open Source | Apache-2.0 | 2,022 | koin | mottl-jan | Kotlin | Code | 18 | 65 | package org.koin.samples.multi_module.module_b
import org.koin.samples.multi_module.common.IService
class ModuleBService : IService {
override fun sayHello() = "Hello! I am ${javaClass.name}"
} | 9,796 |
https://github.com/random-entity/off-axis-projection-unity/blob/master/Assets/Scripts/Projection/ProjectionPlaneCamera.cs | Github Open Source | Open Source | MIT | 2,021 | off-axis-projection-unity | random-entity | C# | Code | 315 | 996 | //NOTE: Undefine this if you need to move the plane at runtime
//#define PRECALC_PLANE
using System.Collections;
using UnityEngine;
namespace Apt.Unity.Projection
{
[ExecuteInEditMode]
[RequireComponent(typeof(Camera))]
public class ProjectionPlaneCamera : MonoBehaviour
{
//Code based on http... | 44,620 |
https://github.com/Strumenta/antlr-kotlin/blob/master/ci.sh | Github Open Source | Open Source | Apache-2.0 | 2,023 | antlr-kotlin | Strumenta | Shell | Code | 100 | 256 | #!/bin/bash
set -eu
# JS tests will fail because no headless chrome can be found, so we skip tests
extra="-x jsIrBrowserTest -x jsLegacyBrowserTest"
if [ -n "$*" ]; then
extra="$extra $*"
fi
echo "INFO: $(date) running clean"
./gradlew clean
echo "INFO: $(date) running test"
./gradlew test $extra
echo "INFO: $(d... | 4,321 |
https://github.com/martrics/leetcode/blob/master/src/com/adam/test/Q82.java | Github Open Source | Open Source | MIT | null | leetcode | martrics | Java | Code | 170 | 477 | package com.adam.test;
/**
* @author adam
* contact: luminghi@hotmail.com
* date: 2021/3/25 11:27
* version: 1.0.0
*/
public class Q82 {
public static void main(String[] args) {
ListNode node1 = new ListNode(1);
ListNode node2 = new ListNode(2);
ListNode node3 = new ListNode(3);
... | 46,566 |
https://github.com/TBuddha/learnkeys/blob/master/learnkeys-refactoring/src/main/java/org/example/c10简化函数调用/p8以函数取代参数/Demo.java | Github Open Source | Open Source | Apache-2.0 | 2,021 | learnkeys | TBuddha | Java | Code | 396 | 1,203 | package org.example.c10简化函数调用.p8以函数取代参数;
/**
* 以下代码用于计算定单折扣价格。虽然这么低的折扣不大可能出现在现实生活中, 不过作为一个范例,我们暂不考虑这一点:
*
* @author zhout
* @date 2020/5/6 14:47
*/
class Demo {
public double getPrice() {
int basePrice = _quantity * _itemPrice;
// 折扣等级
int discountLevel;
if (_quantity > 100) discountLevel = 2;
... | 44,781 |
https://github.com/spicesouls/ducker/blob/master/ducker.py | Github Open Source | Open Source | MIT | 2,022 | ducker | spicesouls | Python | Code | 287 | 811 | #!/bin/env python3
from src.templates import *
from src.messaging import *
from colorama import init, Style, Fore, Back
init()
import argparse
import sys
banner = Fore.YELLOW + Style.BRIGHT + fr"""
____ _ _ ___ __ _ ____ ____ __
( \/ )( \ / __)( / )( __)( _ \ <(o )___
) D () \/ (( (__ ) ( ) _) ... | 28,403 |
https://github.com/daniel-kullmann/intellij-scala/blob/master/test/org/jetbrains/plugins/scala/testingSupport/scalatest/scala2_11/scalatest2_2_1/Scalatest2_11_2_2_1_DuplicateConfigTest.scala | Github Open Source | Open Source | Apache-2.0 | 2,020 | intellij-scala | daniel-kullmann | Scala | Code | 20 | 129 | package org.jetbrains.plugins.scala.testingSupport.scalatest.scala2_11.scalatest2_2_1
import org.jetbrains.plugins.scala.testingSupport.scalatest.ScalaTestDuplicateConfigTest
/**
* @author Roman.Shein
* @since 22.01.2015
*/
class Scalatest2_11_2_2_1_DuplicateConfigTest extends Scalatest2_11_2_2_1_Base with ScalaTe... | 18,364 |
https://github.com/dzena/tuwien/blob/master/bakk/OOP WS08/src/aufgabe7/HardDisk.java | Github Open Source | Open Source | Apache-2.0 | 2,013 | tuwien | dzena | Java | Code | 128 | 366 | package aufgabe7;
public class HardDisk implements StandAloneMemory{
protected float used_memory;
protected float max_memory;
//initializes a Harddisk with variable size
public HardDisk(float memory) {
max_memory=memory;
}
//returns the available memory size (in Bytes)
public float available() {
retur... | 48,142 |
https://github.com/tthoma24/sysadmin-challenge/blob/master/src/scripts/dockerbackups.cron.d | Github Open Source | Open Source | Apache-2.0 | 2,017 | sysadmin-challenge | tthoma24 | D | Code | 34 | 76 | #
# cron.d/dockerbackups -- Periodically backu Apache and MySQL Docker containers to S3
#
# Written by tthoma24 9/23/17
#
# By default, run at 19:15 everyday
15 19 * * * root /data/scripts/dockerbackups.sh | 47,066 |
https://github.com/BlitzkriegSoftware/CoreTenantHelpers/blob/master/BlitzkriegSoftware.Tenant.Demo.Web/Libs/TypeSwitch.cs | Github Open Source | Open Source | MIT | null | CoreTenantHelpers | BlitzkriegSoftware | C# | Code | 267 | 729 | using System;
using System.Diagnostics.CodeAnalysis;
namespace BlitzkriegSoftware.Tenant.Demo.Web.Libs
{
/// <summary>
/// Case Info
/// </summary>
public class CaseInfo
{
/// <summary>
/// Gets or sets a value indicating whether is Default Case
/// </summary>
publi... | 26,918 |
https://github.com/xiaoyangxxx/dream_car/blob/master/HARDWARE/OSAL/OSAL_Error.c | Github Open Source | Open Source | Apache-2.0 | null | dream_car | xiaoyangxxx | C | Code | 24 | 128 | #include <stdio.h>
#include <stdlib.h>
#include "OSAL_Error.h"
void osal_error_output(char *API,int err_para)
{
//printf("\n********************************************************\nosal API:<%s> \nosal EC :<%x>\n********************************************************\n", API, err_para);
if(err_para >= osal_erro... | 9,317 |
https://github.com/Encrylize/MyDictionary/blob/master/config.py | Github Open Source | Open Source | MIT | 2,015 | MyDictionary | Encrylize | Python | Code | 98 | 336 | import os
basedir = os.path.abspath(os.path.dirname(__file__))
class Config:
""" Base configuration with values used in all configurations. """
SERVER_NAME = 'localhost:5000'
SECRET_KEY = os.getenv('MYDICTIONARY_SECRET_KEY')
SQLALCHEMY_RECORD_QUERIES = True
SQLALCHEMY_TRACK_MODIFICATIONS = True
... | 4,870 |
https://github.com/JLimperg/lean/blob/master/src/tests/util/lru_cache.cpp | Github Open Source | Open Source | Apache-2.0 | 2,022 | lean | JLimperg | C++ | Code | 186 | 585 | /*
Copyright (c) 2014 Microsoft Corporation. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Author: Leonardo de Moura
*/
#include "util/test.h"
#include "util/lru_cache.h"
using namespace lean;
static void tst1(int C = 10000) {
lru_cache<int> m_cache(C);
for (int i = ... | 40,640 |
https://github.com/silenaker/mfei/blob/master/examples/base/src/components/MFEIView.vue | Github Open Source | Open Source | MIT | 2,021 | mfei | silenaker | Vue | Code | 149 | 565 | <template>
<div ref="container" v-loading="loading" class="mfei-container"></div>
</template>
<script>
import { ServiceLoader } from "mfei";
export default {
name: "MFEIView",
data() {
return {
loading: false,
};
},
mounted() {
if (this.$route.meta.url) {
this.load(this.$route.meta.u... | 1,585 |
https://github.com/zhbyak/ZRNormalAppFramework/blob/master/我的网易彩票/我的网易彩票/Classes/ZRMoreFeatureCell.m | Github Open Source | Open Source | Apache-2.0 | 2,017 | ZRNormalAppFramework | zhbyak | Objective-C | Code | 50 | 208 | //
// ZRMoreFeatureCell.m
// 我的网易彩票
//
// Created by 张 锐 on 15/6/24.
// Copyright (c) 2015年 张 锐. All rights reserved.
//
#import "ZRMoreFeatureCell.h"
#import "ZRTabBarController.h"
@interface ZRMoreFeatureCell ()
@property (weak, nonatomic) IBOutlet UIImageView *backImage;
@end
@implementation ZRMoreFea... | 8,254 |
https://github.com/xzmeng/gamehub/blob/master/app/main/views.py | Github Open Source | Open Source | MIT | 2,020 | gamehub | xzmeng | Python | Code | 660 | 2,918 | from datetime import date
from flask import render_template, request, abort, redirect, url_for, flash, current_app
from flask_login import current_user, login_required
from sqlalchemy import cast, Float
from ..models import Game, Genre, Comment, GameRating, Cart, Order, OrderItem, WishList
# from .cart import Cart, W... | 33,145 |
https://github.com/enhavo/enhavo/blob/master/src/Enhavo/Bundle/PageBundle/Factory/PageFactory.php | Github Open Source | Open Source | MIT | 2,023 | enhavo | enhavo | PHP | Code | 96 | 421 | <?php
namespace Enhavo\Bundle\PageBundle\Factory;
use Enhavo\Bundle\BlockBundle\Factory\NodeFactory;
use Enhavo\Bundle\ContentBundle\Entity\Content;
use Enhavo\Bundle\ContentBundle\Factory\ContentFactory;
use Enhavo\Bundle\PageBundle\Entity\Page;
use Enhavo\Bundle\RoutingBundle\Factory\RouteFactory;
class PageFactory... | 33,287 |
https://github.com/scali/agrest/blob/master/agrest-docs/agrest-docs-protocol/src/docs/asciidoc/_protocol/_protocol-extensions/sencha-adapter.adoc | Github Open Source | Open Source | Apache-2.0 | 2,021 | agrest | scali | AsciiDoc | Code | 61 | 115 | === Sencha Adapter
Provides a few extensions to the Agrest protocol to better handle certain Sencha features:
* If a to-one relationship property is included in the Collection, the
framework would also generate a companion "synthetic" FK property called
"propertyName_id"
* `"filter"` key - an alternative to `"ex... | 16,435 |
https://github.com/brlrt/Timecrypt/blob/master/Android/app/src/main/kotlin/co/timecrypt/android/helpers/OnMessageChangedListener.kt | Github Open Source | Open Source | Apache-2.0 | 2,016 | Timecrypt | brlrt | Kotlin | Code | 50 | 99 | package co.timecrypt.android.helpers
/**
* A simple listener for Timecrypt message changes.
*/
interface OnMessageChangedListener {
/**
* Notifies the listener instance that the text being typed was invalidated (either empty or not empty).
*
* @param empty Whether the new text is empty or not
... | 1,351 |
https://github.com/bcesardev/design-patterns-examples/blob/master/composite/src/Triangle.java | Github Open Source | Open Source | Apache-2.0 | null | design-patterns-examples | bcesardev | Java | Code | 15 | 39 | public class Triangle implements SceneObject {
@Override
public void draw() {
System.out.println("Drawing triangle");
}
}
| 40,988 |
https://github.com/ricardo-jrm/nebula/blob/master/src/components/legal/CookiePolicy/index.stories.tsx | Github Open Source | Open Source | MIT | null | nebula | ricardo-jrm | TypeScript | Code | 42 | 99 | import React from 'react';
import { Story, Meta } from '@storybook/react';
import { CookiePolicy } from '.';
export default {
title: 'Components/Legal/CookiePolicy',
component: CookiePolicy,
parameters: {
componentSubtitle: 'CookiePolicy component',
},
} as Meta;
export const Default: Story = () => <Cooki... | 26,653 |
https://github.com/RobertChinem/backend-coding-platform/blob/master/src/code-environments/dto/create-code-environment.dto.ts | Github Open Source | Open Source | MIT | null | backend-coding-platform | RobertChinem | TypeScript | Code | 4 | 9 | export class CreateCodeEnvironmentDto {}
| 24,191 |
https://github.com/lechium/tvOS144Headers/blob/master/System/Library/PrivateFrameworks/HomeKitDaemon.framework/HMDCameraAccessorySettingsConfiguration.h | Github Open Source | Open Source | MIT | 2,021 | tvOS144Headers | lechium | C | Code | 205 | 724 | /*
* This header is generated by classdump-dyld 1.5
* on Wednesday, April 14, 2021 at 2:30:51 PM Mountain Standard Time
* Operating System: Version 14.4 (Build 18K802)
* Image Source: /System/Library/PrivateFrameworks/HomeKitDae... | 35,769 |
https://github.com/frenziedtalon/ExchangeSharp/blob/master/src/ExchangeSharpConsole/Options/OrderDetailsOption.cs | Github Open Source | Open Source | MIT | 2,022 | ExchangeSharp | frenziedtalon | C# | Code | 76 | 226 | using System;
using System.Threading.Tasks;
using CommandLine;
using ExchangeSharpConsole.Options.Interfaces;
namespace ExchangeSharpConsole.Options
{
[Verb("order-details", HelpText = "Fetch the order details from the exchange.")]
public class OrderDetailsOption : BaseOption, IOptionPerExchange, IOptionPerOrderId, ... | 15,032 |
https://github.com/embano1/cloud-provider-vsphere/blob/master/pkg/cloudprovider/vsphere/server/client.go | Github Open Source | Open Source | Apache-2.0 | null | cloud-provider-vsphere | embano1 | Go | Code | 75 | 291 | package server
import (
"context"
"time"
"k8s.io/klog"
"google.golang.org/grpc"
pb "k8s.io/cloud-provider-vsphere/pkg/cloudprovider/vsphere/proto"
vcfg "k8s.io/cloud-provider-vsphere/pkg/common/config"
)
// NewVSphereCloudProviderClient creates CloudProviderVsphereClient
func NewVSphereCloudProviderClient(ct... | 7,231 |
https://github.com/sonoble/oom-py-amd64/blob/master/usr/local/oom/test/oomtest.py | Github Open Source | Open Source | MIT | 2,016 | oom-py-amd64 | sonoble | Python | Code | 140 | 297 | # /////////////////////////////////////////////////////////////////////
#
# oomtest.py :
# For each port,
# for read keys, functions, write keys
# Read each key, read each function, write each write key
#
# Not checking values, just making sure every key is coded in a
# way that doesn't throw an excep... | 24,465 |
https://github.com/jshpng/elastic-charts/blob/master/src/chart_types/partition_chart/state/selectors/picked_shapes.ts | Github Open Source | Open Source | MIT, ISC, Apache-2.0 | 2,021 | elastic-charts | jshpng | TypeScript | Code | 336 | 897 | /*
* Licensed to Elasticsearch B.V. under one or more contributor
* license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright
* ownership. Elasticsearch B.V. licenses this file to you under
* the Apache License, Version 2.0 (the "License"); you may
* not u... | 24,266 |
https://github.com/sudeeptoG/ios-2/blob/master/EvaKit/Core/SearchModels/EVSearchScope.m | Github Open Source | Open Source | MIT | 2,016 | ios-2 | sudeeptoG | Objective-C | Code | 42 | 129 | //
// EVSearchScope.m
// EvaKit
//
// Created by Yegor Popovych on 8/18/15.
// Copyright (c) 2015 Evature. All rights reserved.
//
#import "EVSearchScope.h"
@implementation EVSearchScope
+ (instancetype)scopeWithContextTypes:(EVSearchContextType)types {
EVSearchScope *scope = [[EVSearchScope new] autorelease... | 9,081 |
https://github.com/motacano/EasyLOB-Chinook/blob/master/Chinook.UnitTest.xUnit/UnitTests/2 - Service/Service.cs | Github Open Source | Open Source | MIT | 2,018 | EasyLOB-Chinook | motacano | C# | Code | 15 | 47 | using Microsoft.Practices.Unity;
using Xunit;
namespace Chinook.UnitTest.xUnit
{
public class ServiceTests : BaseTest
{
}
} | 4,698 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.