text stringlengths 201 300k | source_other stringlengths 180 1.21k |
|---|---|
// -------------------------------------------------------------------------------------------------
// Simple Version Control - © Copyright 2020 - Jam-Es.<EMAIL>
// Licensed under the MIT License (MIT). See LICENSE in the repo root for license information.
// ----------------------------------------------------------... | {'dir': 'c-sharp', 'id': '1503686', 'max_stars_count': '5', 'max_stars_repo_name': 'James231/Simple-Version-Control', 'max_stars_repo_path': 'src/SimpleVersionControl/Extensions/ChangeExtensions.cs', 'n_tokens_mistral': 426, 'n_tokens_neox': 413, 'n_words': 132} |
<reponame>Incapture/OG-Platform<gh_stars>0
/**
* Copyright (C) 2012 - present by OpenGamma Inc. and the OpenGamma group of companies
*
* Please see distribution for license.
*/
package com.opengamma.financial.analytics.model.future;
import java.util.Collections;
import java.util.HashSet;
import java.util.Set;
im... | {'dir': 'java', 'id': '95961', 'max_stars_count': '0', 'max_stars_repo_name': 'Incapture/OG-Platform', 'max_stars_repo_path': 'projects/OG-Financial/src/main/java/com/opengamma/financial/analytics/model/future/InterestRateFutureCurveSpecificFunctionDeprecated.java', 'n_tokens_mistral': 3508, 'n_tokens_neox': 3536, 'n_w... |
<reponame>dubesar/VueJS-Modal<filename>src.js<gh_stars>0
var app = new Vue({
el: '#app',
mounted() {
this.openModal();
},
methods : {
openModal: function() {
document.getElementById('myModal').showModal()
}
}
}) | {'dir': 'javascript', 'id': '1385914', 'max_stars_count': '0', 'max_stars_repo_name': 'dubesar/VueJS-Modal', 'max_stars_repo_path': 'src.js', 'n_tokens_mistral': 91, 'n_tokens_neox': 89, 'n_words': 13} |
import os, subprocess
cmd = "heif-convert"
QUALITY = "-q"
QUALITY_ARG = "99"
origs = os.listdir('.')
heics = os.listdir('.')
i = 0
while i < len(heics):
heics[i] = heics[i].lower()
if not heics[i].endswith(".heic"):
heics.pop(i)
origs.pop(i)
i -= 1
i += 1
for file in origs:
... | {'dir': 'python', 'id': '9442593', 'max_stars_count': '1', 'max_stars_repo_name': 'kevinp15/heic-converter', 'max_stars_repo_path': 'heic-conv.py', 'n_tokens_mistral': 311, 'n_tokens_neox': 303, 'n_words': 65} |
package com.bornium.infrastructurebootstrapping.crypto.services.openssl;
public enum OpenSSLExtension {
CA("v3_ca"),
CA_INTERMEDIATE("v3_intermediate_ca"),
SERVER("server_cert"),
CLIENT("usr_cert");
private String name;
OpenSSLExtension(String name) {
this.name = name;
}
pub... | {'dir': 'java', 'id': '876925', 'max_stars_count': '1', 'max_stars_repo_name': 'xorpherion/bootstrapping-as-code', 'max_stars_repo_path': 'backend/src/main/java/com/bornium/infrastructurebootstrapping/crypto/services/openssl/OpenSSLExtension.java', 'n_tokens_mistral': 126, 'n_tokens_neox': 119, 'n_words': 21} |
<reponame>trumanwong/leetcode<filename>algorithms/0139.WordBreak/wordBreak/wordBreak.go
package wordBreak
import "strings"
func WordBreak(s string, wordDict []string) bool {
dp := make([]int, len(s))
for i := len(s) - 1; i >= 0; i-- {
for j := 0; j < len(wordDict); j++ {
if strings.Index(s[i:], wordDict[j]) =... | {'dir': 'go', 'id': '4034273', 'max_stars_count': '1', 'max_stars_repo_name': 'trumanwong/leetcode', 'max_stars_repo_path': 'algorithms/0139.WordBreak/wordBreak/wordBreak.go', 'n_tokens_mistral': 225, 'n_tokens_neox': 191, 'n_words': 45} |
import { Navigation } from '../../../src/Navigation';
jest.unmock('@railsmob/events');
describe('Navigation', () => {
describe('.unlock', () => {
it('should set decrement locked counter', () => {
const navigation = new Navigation();
navigation.lockCounter = 3;
navigation.unlock();
expect... | {'dir': 'javascript', 'id': '19451890', 'max_stars_count': '1', 'max_stars_repo_name': 'navigationjs/core', 'max_stars_repo_path': '__tests__/Navigation/unlock/index.js', 'n_tokens_mistral': 336, 'n_tokens_neox': 320, 'n_words': 70} |
<filename>PytorchCudaOpExtension/perspective_aware_conv2d/setup.py
from setuptools import setup
from torch.utils.cpp_extension import CppExtension, BuildExtension, CUDAExtension
setup(name='pad_conv2d',
ext_modules=[CUDAExtension('pad_conv2d_gpu', ['pad_conv2d.cpp', 'pad_conv2d_cuda.cu']),],
cmdclass={'buil... | {'dir': 'python', 'id': '9998671', 'max_stars_count': '4', 'max_stars_repo_name': 'Zhaoyi-Yan/PFDNet', 'max_stars_repo_path': 'PytorchCudaOpExtension/perspective_aware_conv2d/setup.py', 'n_tokens_mistral': 118, 'n_tokens_neox': 117, 'n_words': 17} |
<filename>MemoScope/Modules/ClrRoots/ClrRootInformation.cs<gh_stars>0
using BrightIdeasSoftware;
using MemoScope.Core;
using MemoScope.Core.Data;
using Microsoft.Diagnostics.Runtime;
using WinFwk.UITools;
namespace MemoScope.Modules.ClrRoots
{
public class ClrRootsInformation : IAddressData, ITypeNameData
{
... | {'dir': 'c-sharp', 'id': '4645917', 'max_stars_count': '0', 'max_stars_repo_name': 'John-Leitch/MemoScope.Net', 'max_stars_repo_path': 'MemoScope/Modules/ClrRoots/ClrRootInformation.cs', 'n_tokens_mistral': 418, 'n_tokens_neox': 398, 'n_words': 85} |
#include <cstdio>
#include <iostream>
#include <map>
const int MAX_N = 100050;
int a[MAX_N], b[MAX_N];
std::map<int, int> m;
int cnt;
int id(int x);
template <typename T>
T read();
int main() {
std::ios::sync_with_stdio(false);
int n = read<int>(), k = read<int>();
for (int i = 1; i <= n; i++) {
... | {'dir': 'cpp', 'id': '5401125', 'max_stars_count': '1', 'max_stars_repo_name': 'krishukr/cpp-code', 'max_stars_repo_path': 'src/LG/lg-P3069.cpp', 'n_tokens_mistral': 473, 'n_tokens_neox': 448, 'n_words': 122} |
<reponame>peterthomet/BioPuur<gh_stars>0
@model VendorInfoModel
@{
Layout = "_ColumnsTwo";
//title
Html.AddTitleParts(T("PageTitle.VendorInfo").Text);
//page class
Html.AppendPageCssClassParts("html-account-page");
Html.AppendPageCssClassParts("html-vendorinfo-page");
}
@section left
{
@aw... | {'dir': 'c-sharp', 'id': '2324803', 'max_stars_count': '0', 'max_stars_repo_name': 'peterthomet/BioPuur', 'max_stars_repo_path': 'nopCommerce 4.4/src/Presentation/Nop.Web/Views/Vendor/Info.cshtml', 'n_tokens_mistral': 797, 'n_tokens_neox': 751, 'n_words': 119} |
<reponame>myyangbin/CodeToolSolution<gh_stars>1-10
using MetaWorkLib.Utils;
using SqlRepoEx.Abstractions;
using SqlRepoEx.SqlServer;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using TableTranslatorEx.Model;
namespace MetaWorkLib.Domain
{
pub... | {'dir': 'c-sharp', 'id': '7458042', 'max_stars_count': '3', 'max_stars_repo_name': 'myyangbin/CodeToolSolution', 'max_stars_repo_path': 'MetaWorkLib/Domain/AzMetaCustomCloumListEntity.cs', 'n_tokens_mistral': 228, 'n_tokens_neox': 227, 'n_words': 34} |
<reponame>FEETB24/bepuphysics2<gh_stars>0
namespace BepuPhysics.Constraints.Contact
{
/// <summary>
/// Callbacks for direct references to the solver's contact constraint data.
/// </summary>
public interface ISolverContactDataExtractor
{
/// <summary>
/// Provides a reference to a ... | {'dir': 'c-sharp', 'id': '10391985', 'max_stars_count': '0', 'max_stars_repo_name': 'FEETB24/bepuphysics2', 'max_stars_repo_path': 'BepuPhysics/Constraints/Contact/ISolverContactDataExtractor.cs', 'n_tokens_mistral': 2306, 'n_tokens_neox': 2109, 'n_words': 695} |
<gh_stars>1-10
/* global exports */
exports.addWidgets = function (eleventyConfig) {
eleventyConfig.addNunjucksShortcode('timer', function ({
time = 5,
useURLTime = false,
s = true,
h = false,
pid = undefined,
timerid = undefined,
controls = 'true',
} = {}) {
// prettier-ignore
r... | {'dir': 'javascript', 'id': '8721452', 'max_stars_count': '3', 'max_stars_repo_name': 'music-practice-tools/music-practice-tools', 'max_stars_repo_path': 'src/_11ty/widgets/timer.js', 'n_tokens_mistral': 476, 'n_tokens_neox': 463, 'n_words': 79} |
<filename>master/airsnort-0.2.7e/airsnort-0.2.7e/src/winmonitor.c
/*
winmonitor.c (distributed as part of AirSnort)
winmonitor is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of ... | {'dir': 'c', 'id': '6427288', 'max_stars_count': '4', 'max_stars_repo_name': 'AlexRogalskiy/DevArtifacts', 'max_stars_repo_path': 'master/airsnort-0.2.7e/airsnort-0.2.7e/src/winmonitor.c', 'n_tokens_mistral': 4487, 'n_tokens_neox': 4237, 'n_words': 1175} |
<gh_stars>1-10
<?php
/**
* @copyright Copyright (c) 2012-2016 RNP
* @license http://github.com/ufrgs-hyman/meican#license
*/
use yii\helpers\Html;
use yii\helpers\Url;
use meican\aaa\RbacController;
$this->params['header'] = ['Dashboard'];
?>
<div class="row" style="text-align: center">
<div class="c... | {'dir': 'php', 'id': '11711099', 'max_stars_count': '10', 'max_stars_repo_name': 'ufrgs-hyman/meican', 'max_stars_repo_path': 'modules/home/views/board/dashboard.php', 'n_tokens_mistral': 765, 'n_tokens_neox': 723, 'n_words': 121} |
'use strict';
const net = require('net');
const Readable = require('stream').Readable;
const iconv = require('iconv-lite');
// telnet protocol character
const IAC = 0xff;
const DONT = 0xfe;
const DO = 0xfd;
const WONT = 0xfc;
const WILL = 0xfb;
const SE = 0xf0;
const NOP = 0xf1;
const DM = 0xf2;
cons... | {'dir': 'javascript', 'id': '12327352', 'max_stars_count': '0', 'max_stars_repo_name': 'rilakkris/twbbs', 'max_stars_repo_path': 'lib/telnet.js', 'n_tokens_mistral': 1138, 'n_tokens_neox': 1056, 'n_words': 257} |
<reponame>AlbertusNdaru/sisfo_pringgo
<?php
defined('BASEPATH') or exit('No direct script access allowed');
?>
<!-- .d-flex -->
</div>
<script src="<?php echo base_url('bootadmin/js/bootstrap.bundle.min.js') ?>"></script>
<script src="<?php echo base_url('bootadmin/js/datatables.min.js') ?>"></script>
<script src="<?... | {'dir': 'php', 'id': '1427887', 'max_stars_count': '0', 'max_stars_repo_name': 'AlbertusNdaru/sisfo_pringgo', 'max_stars_repo_path': 'application/views/footer.php', 'n_tokens_mistral': 468, 'n_tokens_neox': 468, 'n_words': 77} |
@model IEnumerable<WebEAD.Areas.EAD.Models.NoticeMetadado>
@{
ViewBag.Title = "Avisos";
Layout = "~/Areas/EAD/Views/Shared/_LayoutDisciplinas.cshtml";
}
<div class="ui grid ">
<div class="sixteen wide blue text column centered">
<h1 class="">Avisos</h1>
</div>
</div>
<div class="ui grid ">
... | {'dir': 'c-sharp', 'id': '9679218', 'max_stars_count': '0', 'max_stars_repo_name': 'dfariaz/webead', 'max_stars_repo_path': 'WebEAD/obj/Release/Package/PackageTmp/Areas/EAD/Views/Courses/Index.cshtml', 'n_tokens_mistral': 608, 'n_tokens_neox': 594, 'n_words': 124} |
<?php declare(strict_types=1);
namespace api\models;
use yii\db\ActiveQuery;
use yii\db\ActiveRecord;
class Company extends \common\models\Company
{
public function fields(): array
{
return ['id','title','clients'];
}
}
| {'dir': 'php', 'id': '10705788', 'max_stars_count': '0', 'max_stars_repo_name': 'akulyk/bonum_test_task', 'max_stars_repo_path': 'api/models/Company.php', 'n_tokens_mistral': 78, 'n_tokens_neox': 77, 'n_words': 18} |
<reponame>BobLynn/timda-mobile<gh_stars>0
#!/usr/bin/env python
import rospy
import serial
from button.srv import TimdaMode
#COM_PORT = '/dev/ttyUSB0'
BAUD_RATES = 115200
list_ser = []
TIMDA_SERVER = "Timda_mobile"
def recieve_data():
while not rospy.is_shutdown():
while ser.in_waiting:
lis... | {'dir': 'python', 'id': '12166222', 'max_stars_count': '0', 'max_stars_repo_name': 'BobLynn/timda-mobile', 'max_stars_repo_path': 'button/src/recieve_esp.py', 'n_tokens_mistral': 518, 'n_tokens_neox': 485, 'n_words': 94} |
<gh_stars>0
console.log("Welcome to Tic-Tac-Toe Game developed by <NAME>");
let bgMusic = new Audio("bg.mp3");
let turnMusic = new Audio("turn.mp3");
let gameoverMusic = new Audio("gameover.mp3");
let turn = "X";
let gameover = false;
//Function to change the turn
const changeTurn = ()=>{
return turn === "X"?"O":... | {'dir': 'javascript', 'id': '19192131', 'max_stars_count': '0', 'max_stars_repo_name': 'jatinkumar027/Tic-Tac-Toe', 'max_stars_repo_path': 'public/script.js', 'n_tokens_mistral': 1097, 'n_tokens_neox': 964, 'n_words': 223} |
const bcrypt = require('bcryptjs');
const jwt = require('jsonwebtoken');
const { validationResult } = require('express-validator');
const controller = {};
// Import models:
const User = require('../models/User');
controller.getUser = (req, res, next) => {
res.status(200).json({
message: 'User Get'
})
... | {'dir': 'javascript', 'id': '3036458', 'max_stars_count': '0', 'max_stars_repo_name': 'Jucester/NimbleTasks', 'max_stars_repo_path': 'server/src/controller/user.controller.js', 'n_tokens_mistral': 502, 'n_tokens_neox': 475, 'n_words': 135} |
/**
* Copyright 2020 Google LLC
*
* 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... | {'dir': 'javascript', 'id': '2620719', 'max_stars_count': '1059', 'max_stars_repo_name': 'SneezingCactus/santa-tracker-web', 'max_stars_repo_path': 'static/scenes/poseboogie/js/elf.js', 'n_tokens_mistral': 8701, 'n_tokens_neox': 8455, 'n_words': 1631} |
<gh_stars>10-100
import * as React from 'react'
export type Step = {
id: string
validationLabel: string
label?: string
info?: {
url: string
label: string
}
}
export type Context = {
currentStep: number
setCurrentStep: (stepIndex: number) => void
steps: Step[]
registerSteps: (steps: Step[]) =... | {'dir': 'typescript', 'id': '9299949', 'max_stars_count': '11', 'max_stars_repo_name': 'cap-collectif/ui', 'max_stars_repo_path': 'src/components/multiStepModal/MultiStepModal.context.tsx', 'n_tokens_mistral': 239, 'n_tokens_neox': 232, 'n_words': 67} |
<reponame>lwerner-lshigh/golang-advanced-topics-computer-sci
package main
import (
"fmt"
"net/url"
)
func main() {
m := url.Values{"lang": {"en"}}
m.Add("item", "1")
m.Add("item", "2")
fmt.Printf("lang: %s\n", m.Get("lang"))
fmt.Printf("q: %s\n", m.Get("q"))
fmt.Printf("item: %s\n", m.Get("item"))
fmt.Print... | {'dir': 'go', 'id': '2924438', 'max_stars_count': '0', 'max_stars_repo_name': 'lwerner-lshigh/golang-advanced-topics-computer-sci', 'max_stars_repo_path': 'ch6/urlvalues/urlvalues.go', 'n_tokens_mistral': 196, 'n_tokens_neox': 193, 'n_words': 32} |
<filename>lib/errors/create-server-error.js
export default function createServerError(Target, statusCode) {
const ServerError = class extends Target {
statusCode;
constructor(...args) {
super(...args);
this.statusCode = statusCode;
}
};
Reflect.defineProperty(ServerError, 'name', {
v... | {'dir': 'javascript', 'id': '1139287', 'max_stars_count': '17', 'max_stars_repo_name': 'willviles/lux-passport', 'max_stars_repo_path': 'lib/errors/create-server-error.js', 'n_tokens_mistral': 112, 'n_tokens_neox': 108, 'n_words': 22} |
<gh_stars>1-10
// Copyright 2019-2020, Collabora, Ltd.
// SPDX-License-Identifier: BSL-1.0
/*!
* @file
* @brief Target Vulkan swapchain code.
* @author <NAME> <<EMAIL>>
* @author <NAME> <<EMAIL>>
* @ingroup comp_main
*/
#include "xrt/xrt_config_os.h"
#include "util/u_misc.h"
#include "util/u_timing.h"
#includ... | {'dir': 'c', 'id': '789167', 'max_stars_count': '1', 'max_stars_repo_name': 'mateosss/monado', 'max_stars_repo_path': 'src/xrt/compositor/main/comp_target_swapchain.c', 'n_tokens_mistral': 7609, 'n_tokens_neox': 7001, 'n_words': 1310} |
import { Box, Button, Grid } from "@material-ui/core";
import ShoppingCartIcon from "@material-ui/icons/ShoppingCart";
import "./Cart.css";
import CheckoutBox from "./CheckoutBox";
const Cart = ({ cart, incrementCount, decrementCount, clearCart }) => {
return (
<>
<Grid container direction="col... | {'dir': 'javascript', 'id': '13774694', 'max_stars_count': '0', 'max_stars_repo_name': 'ChaonengQuan/react-material-ui-app', 'max_stars_repo_path': 'src/components/Cart.js', 'n_tokens_mistral': 696, 'n_tokens_neox': 645, 'n_words': 127} |
<filename>src/ui/components/wallet/WalletConnectedButton.tsx
import { IWallet } from '@core/wallet';
import { Button } from '@ui/atoms';
import { ChevronIcon } from '@ui/icons';
import React, { useCallback } from 'react';
import { useBreakpoints } from 'react-match-breakpoints';
import { css } from 'styled-components';... | {'dir': 'typescript', 'id': '9200495', 'max_stars_count': '0', 'max_stars_repo_name': 'rasreee/nextjs-solana-wallet-adapter-starter', 'max_stars_repo_path': 'src/ui/components/wallet/WalletConnectedButton.tsx', 'n_tokens_mistral': 365, 'n_tokens_neox': 360, 'n_words': 77} |
package com.eric.leetcode
class MaximumWidthRamp {
fun maxWidthRamp(A: IntArray): Int {
val indices = A.indices.sortedBy { A[it] }
var width = 0
var minIndex = A.lastIndex
for (index in indices) {
width = maxOf(width, index - minIndex)
minIndex = minOf(index,... | {'dir': 'kotlin', 'id': '1820909', 'max_stars_count': '9', 'max_stars_repo_name': 'wanglikun7342/Leetcode-Kotlin', 'max_stars_repo_path': 'src/main/kotlin/com/eric/leetcode/MaximumWidthRamp.kt', 'n_tokens_mistral': 188, 'n_tokens_neox': 177, 'n_words': 46} |
<reponame>danielzy95/h2developer
import { Component, OnInit } from '@angular/core';
import { Connection } from './domain/connection';
import { DBTreeRoot, SchemaTreeNode, UserTreeNode, DBObject, nonarrs } from './domain/db-tree';
import { ConnectionService } from './connection.service';
import { Result } from './domai... | {'dir': 'typescript', 'id': '9068040', 'max_stars_count': '0', 'max_stars_repo_name': 'danielzy95/h2developer', 'max_stars_repo_path': 'src/app/app.component.ts', 'n_tokens_mistral': 3707, 'n_tokens_neox': 3655, 'n_words': 805} |
import React from 'react';
import RefreshIndicator from 'material-ui/RefreshIndicator';
import { ACCENT_BLUE } from '../style/constants';
const styles = {
spinnerContainerStyle: {
position: 'relative',
display: 'inline-block',
},
};
const Spinner = () => (
<div className="spinner" style={styles.spinnerC... | {'dir': 'javascript', 'id': '4726023', 'max_stars_count': '0', 'max_stars_repo_name': 'stevendinhdev/shopify-app', 'max_stars_repo_path': 'server/client/src/components/Spinner.js', 'n_tokens_mistral': 160, 'n_tokens_neox': 159, 'n_words': 34} |
# frozen_string_literal: true
RSpec.describe AhlScraper::TeamDataFetcher do
describe "#call" do
it "returns team data for specific season from request", :vcr do
team_data = described_class.new(65).call
expect(team_data).to all(be_a(Object))
end
end
end
| {'dir': 'ruby', 'id': '560066', 'max_stars_count': '0', 'max_stars_repo_name': 'notnotjeff/ahl_scraper', 'max_stars_repo_path': 'spec/ahl_scraper/fetchers/team_data_fetcher_spec.rb', 'n_tokens_mistral': 94, 'n_tokens_neox': 91, 'n_words': 26} |
<reponame>manuazryah/almukhalatperfume<filename>common/mail/new_registration.php
<?php
use yii\helpers\Html;
use common\models\User;
use common\models\CountryCode;
?>
<tr>
<td valign="top" class="x_902363135m_-4486764198706722540top-content" style="font-family: Arial, Helvetica, sans-serif; font-weight: normal; bo... | {'dir': 'php', 'id': '2821943', 'max_stars_count': '0', 'max_stars_repo_name': 'manuazryah/almukhalatperfume', 'max_stars_repo_path': 'common/mail/new_registration.php', 'n_tokens_mistral': 1075, 'n_tokens_neox': 966, 'n_words': 191} |
############################################################
# Ingestion tests start
############################################################
desc "Run Concurrent Tenant Ingestion Test"
task :ingestionConcurrentTenantTest do
runTests("test/features/ingestion/features/ingestion_concurrentTenant.feature")
end
desc... | {'dir': 'ruby', 'id': '1314615', 'max_stars_count': '0', 'max_stars_repo_name': 'jstokes/secure-data-service', 'max_stars_repo_path': 'sli/acceptance-tests/suites/ingestion.rake', 'n_tokens_mistral': 7437, 'n_tokens_neox': 6795, 'n_words': 984} |
package me.gosimple.nbvcxz.scoring;
import me.gosimple.nbvcxz.matching.match.BruteForceMatch;
import me.gosimple.nbvcxz.matching.match.Match;
import me.gosimple.nbvcxz.resources.Configuration;
import me.gosimple.nbvcxz.resources.Feedback;
import me.gosimple.nbvcxz.resources.FeedbackUtil;
import java.math.BigDecimal;
... | {'dir': 'java', 'id': '15965629', 'max_stars_count': '241', 'max_stars_repo_name': 'garcia-jj/nbvcxz', 'max_stars_repo_path': 'src/main/java/me/gosimple/nbvcxz/scoring/Result.java', 'n_tokens_mistral': 1481, 'n_tokens_neox': 1422, 'n_words': 489} |
<gh_stars>1-10
package dev.jozefowicz.springsecurity.methodsecurity.configuration;
import org.springframework.security.config.annotation.method.configuration.EnableGlobalMethodSecurity;
import org.springframework.security.config.annotation.web.builders.HttpSecurity;
import org.springframework.security.config.annotatio... | {'dir': 'java', 'id': '806310', 'max_stars_count': '8', 'max_stars_repo_name': 'karol-preiskorn/spring-security', 'max_stars_repo_path': 'day2/method-security/src/main/java/dev/jozefowicz/springsecurity/methodsecurity/configuration/SecurityConfiguration.java', 'n_tokens_mistral': 245, 'n_tokens_neox': 237, 'n_words': 3... |
'''
Created on 2015/11/9
:author: hubo
'''
from vlcp.config import defaultconfig
from vlcp.server.module import Module, api, proxy
from vlcp.event.core import TimerEvent
from vlcp.event.runnable import RoutineContainer
from time import time
import functools
@defaultconfig
class Knowledge(Module):
'''
Simple K... | {'dir': 'python', 'id': '3877537', 'max_stars_count': '1', 'max_stars_repo_name': 'geek-plus/vlcp', 'max_stars_repo_path': 'vlcp/service/utils/knowledge.py', 'n_tokens_mistral': 1961, 'n_tokens_neox': 1922, 'n_words': 681} |
// Copyright (c) 2021, <NAME>
// 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 condition... | {'dir': 'cpp', 'id': '5956788', 'max_stars_count': '1', 'max_stars_repo_name': 'MikhailTerekhov/PoseLib', 'max_stars_repo_path': 'PoseLib/solvers/homography_4pt.cc', 'n_tokens_mistral': 1190, 'n_tokens_neox': 1080, 'n_words': 374} |
<filename>Cars/app/src/main/java/com/udemy/carros/entities/Car.java
package com.udemy.carros.entities;
import android.graphics.drawable.Drawable;
public class Car {
public int id;
public String model;
public int horsePower;
public double price;
public String manufacturer;
public Drawable pic... | {'dir': 'java', 'id': '1668357', 'max_stars_count': '0', 'max_stars_repo_name': 'FernandoPucci/AndroidUdemy', 'max_stars_repo_path': 'Cars/app/src/main/java/com/udemy/carros/entities/Car.java', 'n_tokens_mistral': 186, 'n_tokens_neox': 181, 'n_words': 51} |
package com.zygon.rl.common.model;
import com.zygon.rl.core.model.Entity;
import java.awt.Color;
import java.util.HashMap;
import java.util.Map;
import java.util.function.Function;
/**
*
* @author zygon
*/
public enum Tile {
FLOOR(Entities.FLOOR, (e) -> '.', Color.YELLOW),
DIRT(Entities.DIRT, (e) -> '.',... | {'dir': 'java', 'id': '13119645', 'max_stars_count': '3', 'max_stars_repo_name': 'zygon4/BloodRL', 'max_stars_repo_path': 'src/main/java/com/zygon/rl/common/model/Tile.java', 'n_tokens_mistral': 701, 'n_tokens_neox': 691, 'n_words': 141} |
<filename>src/com/computablefacts/morta/snorkel/GoldLabel.java
package com.computablefacts.morta.snorkel;
import java.util.Map;
import java.util.Objects;
import com.computablefacts.nona.Generated;
import com.google.common.base.MoreObjects;
import com.google.common.base.Preconditions;
import com.google.errorprone.anno... | {'dir': 'java', 'id': '4715733', 'max_stars_count': '0', 'max_stars_repo_name': 'computablefacts/morta', 'max_stars_repo_path': 'src/com/computablefacts/morta/snorkel/GoldLabel.java', 'n_tokens_mistral': 1575, 'n_tokens_neox': 1452, 'n_words': 357} |
<filename>ctci/01_02/solution.go
package solution
import (
"bufio"
"fmt"
)
var Reverse = ReverseA
var Reverses = []func(string) string{ReverseA, ReverseB}
func ReverseA(str string) string {
s := []rune(str)
for i, j := 0, len(s)-1; i < j; i, j = i+1, j-1 {
s[i], s[j] = s[j], s[i]
}
return string(s)
}
func R... | {'dir': 'go', 'id': '1992024', 'max_stars_count': '0', 'max_stars_repo_name': 'tiagofalcao/GoNotebook', 'max_stars_repo_path': 'ctci/01_02/solution.go', 'n_tokens_mistral': 293, 'n_tokens_neox': 275, 'n_words': 75} |
<reponame>Fei-Lu/GroupPlantGenetics
package daxing.common.grt;
import daxing.common.utiles.DateTime;
import daxing.common.utiles.StringTool;
import gnu.trove.list.array.TIntArrayList;
import pgl.app.grt.LibraryInfo;
import pgl.infra.utils.Benchmark;
import pgl.infra.utils.IOUtils;
import java.io.BufferedReader;
import... | {'dir': 'java', 'id': '6085422', 'max_stars_count': '2', 'max_stars_repo_name': 'Fei-Lu/GroupPlantGenetics', 'max_stars_repo_path': 'src/daxing/common/grt/LibraryOfGRT.java', 'n_tokens_mistral': 2141, 'n_tokens_neox': 2048, 'n_words': 331} |
const mongoose = require('mongoose');
const { MongoMemoryServer } = require('mongodb-memory-server');
const mongod = new MongoMemoryServer();
/**
* Connect to the in-memory database.
*/
connect = async () => {
const uri = await mongod.getConnectionString();
const mongooseOpts = {
useNewUrlParser: true,
... | {'dir': 'javascript', 'id': '14566340', 'max_stars_count': '4', 'max_stars_repo_name': 'Shahzayb/pistagram', 'max_stars_repo_path': 'server/tests/util/db.js', 'n_tokens_mistral': 393, 'n_tokens_neox': 402, 'n_words': 107} |
<reponame>RReverser/libwebp2<filename>src/dsp/quant_c.cc
// Copyright 2020 Google LLC
//
// 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... | {'dir': 'cpp', 'id': '2493985', 'max_stars_count': '4', 'max_stars_repo_name': 'RReverser/libwebp2', 'max_stars_repo_path': 'src/dsp/quant_c.cc', 'n_tokens_mistral': 859, 'n_tokens_neox': 828, 'n_words': 227} |
<?php declare(strict_types=1);
/**
* LightningPHP
* Copyright 2021 - 2022 <NAME>.
*
* Licensed under The MIT License
* The above copyright notice and this permission notice shall be included in all copies or substantial
* portions of the Software.
*
* @copyright Copyright (c) <NAME>
* @license https://op... | {'dir': 'php', 'id': '2154944', 'max_stars_count': '3', 'max_stars_repo_name': 'jamielsharief/lightning', 'max_stars_repo_path': 'src/Translator/Translator.php', 'n_tokens_mistral': 1196, 'n_tokens_neox': 1149, 'n_words': 317} |
<gh_stars>0
# frozen_string_literal: true
require 'rspec'
require_relative '../core_maior_menor.rb'
describe '#' do
it 'choice maximum number by difficulty' do
expect(choice_maximun(1)).to eq(30)
end
end
| {'dir': 'ruby', 'id': '2946170', 'max_stars_count': '0', 'max_stars_repo_name': 'doguskysilva/ruby-games', 'max_stars_repo_path': 'tests/maior_menor_spec.rb', 'n_tokens_mistral': 81, 'n_tokens_neox': 77, 'n_words': 20} |
<filename>lib/autocomplete-provider.js
const USER_CACHE_REFRESH_INERVAL = 10 * 60 * 1000; // 10 min.
export default class AutocompleteProvider {
scopeSelector = ".text.plain.null-grammar";
enableCustomTextEditorSelector = true;
constructor() {
this.users = [];
}
init = usersRef => {
this.usersRef =... | {'dir': 'javascript', 'id': '11787690', 'max_stars_count': '1', 'max_stars_repo_name': 'hacker-box/codesidestory-atom', 'max_stars_repo_path': 'lib/autocomplete-provider.js', 'n_tokens_mistral': 695, 'n_tokens_neox': 670, 'n_words': 118} |
<gh_stars>0
<HTML>
<HEAD>
<meta charset="UTF-8">
<title>AddCardWidget.isValid - </title>
<link rel="stylesheet" href="../../style.css">
</HEAD>
<BODY>
<a href="../index.html">io.paymenthighway.sdk.ui</a> / <a href="index.html">AddCardWidget</a> / <a href="./is-valid.html">isValid</a><br/>
<br/>
<h1>... | {'dir': 'html', 'id': '631186', 'max_stars_count': '0', 'max_stars_repo_name': 'PaymentHighway/paymenthighway-android-sdk', 'max_stars_repo_path': 'docs/io.paymenthighway.sdk.ui/-add-card-widget/is-valid.html', 'n_tokens_mistral': 265, 'n_tokens_neox': 259, 'n_words': 39} |
# frozen_string_literal: true
module Spec
module Sudo
def self.present?
@which_sudo ||= Bundler.which("sudo")
end
def sudo(*cmd)
raise "sudo not present" unless Sudo.present?
sys_exec("sudo", *cmd)
end
def chown_system_gems_to_root
sudo "chown", "-R", "root", system_gem_... | {'dir': 'ruby', 'id': '2889293', 'max_stars_count': '0', 'max_stars_repo_name': 'queilawithaQ/rubygems', 'max_stars_repo_path': 'bundler/spec/support/sudo.rb', 'n_tokens_mistral': 131, 'n_tokens_neox': 121, 'n_words': 32} |
<gh_stars>0
@extends('mail.template')
@section('title', 'Squads - Password Reset Request')
@section('content')
<p>Your password reset request was successfully processed. Please use the below pin number to finish reseting your password.</p>
<p>{{$data['pin']}}<br /><small>This pin will expire in two hours.</... | {'dir': 'php', 'id': '12559785', 'max_stars_count': '0', 'max_stars_repo_name': 'Iinguistics/squads', 'max_stars_repo_path': 'resources/views/mail/password-reset-request.blade.php', 'n_tokens_mistral': 155, 'n_tokens_neox': 143, 'n_words': 52} |
<reponame>Montycarlo/ERC.Xdbg
using System;
using System.IO;
using System.Runtime.InteropServices;
namespace Managed.x64dbg.SDK
{
public class Bridge
{
public const int GUI_MAX_LINE_SIZE = 65536;
public const int MAX_LABEL_SIZE = 256;
public const int MAX_COMMENT_SIZE = 512;
pu... | {'dir': 'c-sharp', 'id': '5748650', 'max_stars_count': '74', 'max_stars_repo_name': 'Montycarlo/ERC.Xdbg', 'max_stars_repo_path': 'Managed.x64dbg/SDK/Bridge.cs', 'n_tokens_mistral': 1052, 'n_tokens_neox': 946, 'n_words': 287} |
import re, logging, bottle
from WLANderlust import config
from WLANderlust.captiveportals import CaptivePortalSolverImpl
from WLANderlust import CredentialsStore
logger = logging.getLogger(__name__)
class Fon(CaptivePortalSolverImpl):
name = "Fon"
# List of SSIDs associated with the Fon network
# Probably not... | {'dir': 'python', 'id': '11828507', 'max_stars_count': '1', 'max_stars_repo_name': 'rrooggiieerr/WLANderlust.py', 'max_stars_repo_path': 'WLANderlust/captiveportals/impl/Fon.py', 'n_tokens_mistral': 1566, 'n_tokens_neox': 1527, 'n_words': 347} |
<filename>src/components/general/TabBar.js
import React, {Component} from 'react';
import PropTypes from 'prop-types';
import Icon from 'react-native-vector-icons/Ionicons';
import {colors, metrics} from '../../styles';
import {connect} from 'react-redux';
import {bindActionCreators} from 'redux';
import * as navigatio... | {'dir': 'javascript', 'id': '15906296', 'max_stars_count': '17', 'max_stars_repo_name': 'thiagobrez/react-native-template-pro', 'max_stars_repo_path': 'src/components/general/TabBar.js', 'n_tokens_mistral': 1185, 'n_tokens_neox': 1186, 'n_words': 230} |
/*
Copyright 2019 The Knative Authors
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, soft... | {'dir': 'go', 'id': '4208177', 'max_stars_count': '0', 'max_stars_repo_name': 'richard2006/eventing', 'max_stars_repo_path': 'pkg/apis/eventing/v1alpha1/eventtype_lifecycle.go', 'n_tokens_mistral': 637, 'n_tokens_neox': 625, 'n_words': 180} |
<filename>src/sync/providers/filesystem.rs
//! Uses a filesystem folder as a repository.
//! An empty file called VPassFile is used to mark this as a vpass repository.
use super::super::{Error, SyncProvider, SyncResult, UpdateKey};
use crate::VResult;
use base64;
use serde::{Deserialize, Serialize};
use serde_json::{... | {'dir': 'rust', 'id': '1161953', 'max_stars_count': '2', 'max_stars_repo_name': 'Dentosal/vpass', 'max_stars_repo_path': 'src/sync/providers/filesystem.rs', 'n_tokens_mistral': 923, 'n_tokens_neox': 929, 'n_words': 198} |
<filename>app/Http/Controllers/WargaController.php
<?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
class WargaController extends Controller
{
public function index(Request $request){
if($request->has('cari')){
$data_warga = \App\Models\Warga::where('Nama','LIKE','%'.$reques... | {'dir': 'php', 'id': '12147398', 'max_stars_count': '0', 'max_stars_repo_name': 'ridhayusra/UAS', 'max_stars_repo_path': 'app/Http/Controllers/WargaController.php', 'n_tokens_mistral': 394, 'n_tokens_neox': 422, 'n_words': 61} |
<reponame>fossabot/Waleed.me
import "babel-polyfill";
import angular from "angular";
import uiRouter from "@uirouter/angularjs";
let router = require("./router");
import "../scss/styles.scss";
angular.module("app", [uiRouter]).config(router);
| {'dir': 'javascript', 'id': '6681755', 'max_stars_count': '0', 'max_stars_repo_name': 'fossabot/Waleed.me', 'max_stars_repo_path': 'src/scripts/app.js', 'n_tokens_mistral': 82, 'n_tokens_neox': 80, 'n_words': 18} |
package objects
import (
"encoding/json"
"github.com/pkg/errors"
)
func (p *UserProfile) Encode() (string, error) {
buf, err := json.Marshal(p)
if err != nil {
return "", errors.Wrap(err, `failed to encode user profile`)
}
return string(buf), nil
}
| {'dir': 'go', 'id': '1543505', 'max_stars_count': '1', 'max_stars_repo_name': 'zchee/slackctl', 'max_stars_repo_path': 'vendor/github.com/lestrrat/go-slack/objects/user_profile.go', 'n_tokens_mistral': 97, 'n_tokens_neox': 94, 'n_words': 27} |
<filename>intro-to-react/counter/src/Counter.js
import React from 'react';
import './Counter.css';
import renderer from './index.js'
let counter = 0;
const incrementCounter = () => {
++counter;
renderer(Counter(), document.getElementById('root'));
};
const Counter = () => (
<div>
<h1>Header 1</h1>
<h2... | {'dir': 'javascript', 'id': '9828729', 'max_stars_count': '0', 'max_stars_repo_name': 'BiserVStoev/ReactJS', 'max_stars_repo_path': 'intro-to-react/counter/src/Counter.js', 'n_tokens_mistral': 200, 'n_tokens_neox': 191, 'n_words': 40} |
<filename>webclient/webclient-processor/src/test/resources/templates/success/expected/GeneratedComplexReturnInterface.java
import io.github.raphasil.generator.client.rest.api.provider.ClientProvider;
import java.lang.Object;
import java.lang.Override;
import java.lang.Void;
import java.util.List;
import java.util.Map;
... | {'dir': 'java', 'id': '8729117', 'max_stars_count': '2', 'max_stars_repo_name': 'raphasil/rest-client-generator', 'max_stars_repo_path': 'webclient/webclient-processor/src/test/resources/templates/success/expected/GeneratedComplexReturnInterface.java', 'n_tokens_mistral': 854, 'n_tokens_neox': 828, 'n_words': 126} |
<gh_stars>0
import * as path from "path";
import * as os from "os";
import pLimit from "p-limit";
import { validate } from "schema-utils";
import serialize from "serialize-javascript";
import minifyFn from "./minify";
import schema from "./plugin-options.json";
import imageminMinify, {
normalizeImageminConfig,
} f... | {'dir': 'javascript', 'id': '14740860', 'max_stars_count': '0', 'max_stars_repo_name': 'francescolaffi/image-minimizer-webpack-plugin', 'max_stars_repo_path': 'src/index.js', 'n_tokens_mistral': 3311, 'n_tokens_neox': 3196, 'n_words': 727} |
define([],
function() {
'use strict';
var _initMultiAxis = function(multiAxis) {
var itemData = { };
_(multiAxis).each(function(axis) {
itemData[axis] = 0;
});
return itemData;
}
var _addMultiAxis = function(multiAxis, gameData, currentItem) {
_(mul... | {'dir': 'javascript', 'id': '6530076', 'max_stars_count': '0', 'max_stars_repo_name': 'richhildebrand/Jason-Kipnis', 'max_stars_repo_path': 'src/DataFormatters/BarChartFormatter.js', 'n_tokens_mistral': 489, 'n_tokens_neox': 468, 'n_words': 77} |
<reponame>unosviluppatore/conversion-service
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Http;
using Antlr4.Runtime.Tree;
using System.IO;
using ParsingServices.Models;
namespace ParsingServices.Libs
{
public interface IConverter<T>
... | {'dir': 'c-sharp', 'id': '336289', 'max_stars_count': '1', 'max_stars_repo_name': 'unosviluppatore/conversion-service', 'max_stars_repo_path': 'Libs/IConverter.cs', 'n_tokens_mistral': 133, 'n_tokens_neox': 135, 'n_words': 31} |
package com.ismaeldivita.changetracker
import java.io.Serializable
open class ChangeTrackerExtension : Serializable {
var tasks = emptySet<String>()
var whitelist = emptySet<String>()
var blacklist = emptySet<String>()
var reevaluate = emptySet<String>()
var branch = "master"
}
| {'dir': 'kotlin', 'id': '179840', 'max_stars_count': '0', 'max_stars_repo_name': 'vtuan10/change-tracker-plugin', 'max_stars_repo_path': 'change_tracker/src/main/kotlin/com/ismaeldivita/changetracker/ChangeTrackerExtension.kt', 'n_tokens_mistral': 92, 'n_tokens_neox': 87, 'n_words': 23} |
/*
* Copyright 2012-present, Polis Technology Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights for non-commercial use can be found in the PATENTS file
* in the sam... | {'dir': 'javascript', 'id': '16133505', 'max_stars_count': '0', 'max_stars_repo_name': 'ricardopoppi/old-polisClientParticipation', 'max_stars_repo_path': 'js/views/groupSelectionView.js', 'n_tokens_mistral': 755, 'n_tokens_neox': 734, 'n_words': 157} |
package service
import (
"context"
"go-common/app/interface/main/web/model"
accmdl "go-common/app/service/main/account/api"
coupon "go-common/app/service/main/coupon/model"
"go-common/library/log"
"go-common/library/sync/errgroup"
)
// Nav api service
func (s *Service) Nav(c context.Context, mid int64, cookie ... | {'dir': 'go', 'id': '3585526', 'max_stars_count': '22', 'max_stars_repo_name': '78182648/blibli-go', 'max_stars_repo_path': 'app/interface/main/web/service/nav.go', 'n_tokens_mistral': 1176, 'n_tokens_neox': 1102, 'n_words': 216} |
// Copyright (c) Microsoft Open Technologies, Inc. All Rights Reserved. Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
namespace Microsoft.CodeAnalysis.Symbols
{
internal enum CommonSynthesizedLocalKind : short
{
/// <summary>
//... | {'dir': 'c-sharp', 'id': '10079154', 'max_stars_count': '0', 'max_stars_repo_name': 'sperling/cskarp', 'max_stars_repo_path': 'Src/Compilers/Core/Portable/Symbols/CommonSynthesizedLocalKind.cs', 'n_tokens_mistral': 208, 'n_tokens_neox': 197, 'n_words': 69} |
<filename>autoscale/src/main/java/com/sequenceiq/periscope/service/RejectedThreadService.java
package com.sequenceiq.periscope.service;
import static com.sequenceiq.cloudbreak.util.JsonUtil.writeValueAsStringSilent;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import java.util.Map;... | {'dir': 'java', 'id': '8758691', 'max_stars_count': '0', 'max_stars_repo_name': 'chusopr/cloudbreak', 'max_stars_repo_path': 'autoscale/src/main/java/com/sequenceiq/periscope/service/RejectedThreadService.java', 'n_tokens_mistral': 896, 'n_tokens_neox': 883, 'n_words': 188} |
<?php
namespace App;
use Illuminate\Database\Eloquent\Model;
class Inquiry extends Model
{
public function __construct()
{
parent::__construct();
$this->primaryKey='id';
$this->table='inquiry';
$this->fillable=[
'token',
'customer_id',
'project_name',
'poi',
... | {'dir': 'php', 'id': '6045759', 'max_stars_count': '0', 'max_stars_repo_name': 'yakoult/isupport', 'max_stars_repo_path': 'app/Inquiry.php', 'n_tokens_mistral': 322, 'n_tokens_neox': 318, 'n_words': 54} |
<reponame>hase1128/dragonfly
"""
A collection of utilities needed for the APIs.
-- <EMAIL>
"""
# pylint: disable=invalid-name
# pylint: disable=maybe-no-member
# pylint: disable=no-member
# pylint: disable=bad-indentation
# pylint: disable=bad-continuation
from argparse import Namespace
import numpy as np
# Loca... | {'dir': 'python', 'id': '9951731', 'max_stars_count': '0', 'max_stars_repo_name': 'hase1128/dragonfly', 'max_stars_repo_path': 'dragonfly/apis/api_utils.py', 'n_tokens_mistral': 5852, 'n_tokens_neox': 5544, 'n_words': 1222} |
<filename>sources/engine/Xenko.Shaders.Parser/ShaderLinker.cs
// Copyright (c) Xenko contributors (https://xenko.com) and Silicon Studio Corp. (https://www.siliconstudio.co.jp)
// Distributed under the MIT license. See the LICENSE.md file in the project root for more information.
using System;
using System.Collections... | {'dir': 'c-sharp', 'id': '8334206', 'max_stars_count': '4', 'max_stars_repo_name': 'nesrak1/xenko', 'max_stars_repo_path': 'sources/engine/Xenko.Shaders.Parser/ShaderLinker.cs', 'n_tokens_mistral': 7114, 'n_tokens_neox': 6650, 'n_words': 1365} |
<?= $this->extend('layout/main')?>
<?= $this->section('content')?>
<h2><center><?= $title ?><center></h2>
<hr>
<form class="mt-5 mb-5" action="" method="post" enctype="multipart/form-data">
<div class="mb-3">
<label for="formFile" class="form-label">Upload a image:</label>
<... | {'dir': 'php', 'id': '12549107', 'max_stars_count': '0', 'max_stars_repo_name': 'srsrinath/codeigniter-sample-site', 'max_stars_repo_path': 'app/Views/gallery/upload.php', 'n_tokens_mistral': 249, 'n_tokens_neox': 241, 'n_words': 43} |
<gh_stars>1-10
#!/bin/sh
################################################################################
## ##
## This program is free software; you can redistribute it and#or modify ##
## it under the terms of the GNU General Public Lice... | {'dir': 'shell', 'id': '1011917', 'max_stars_count': '1', 'max_stars_repo_name': 'clkbit123/TheOpenHarmony', 'max_stars_repo_path': 'Openharmony v1.0/third_party/ltp/testcases/kernel/sched/hyperthreading/ht_affinity/smt_smp_affinity.sh', 'n_tokens_mistral': 900, 'n_tokens_neox': 817, 'n_words': 275} |
<gh_stars>0
#include "FixedSequenceSlot.h"
#include "PeriodicTaskIF.h"
#include <cstddef>
FixedSequenceSlot::FixedSequenceSlot(object_id_t handlerId, uint32_t setTime,
int8_t setSequenceId, ExecutableObjectIF* executableObject,
PeriodicTaskIF* executingTask) : handlerId(handlerId),
pollingTimeMs(setTime), opcode... | {'dir': 'cpp', 'id': '2479500', 'max_stars_count': '0', 'max_stars_repo_name': 'bl4ckic3/fsfw', 'max_stars_repo_path': 'tasks/FixedSequenceSlot.cpp', 'n_tokens_mistral': 182, 'n_tokens_neox': 173, 'n_words': 27} |
<gh_stars>10-100
# uncompyle6 version 2.13.2
# Python bytecode 3.5 (3351)
# Decompiled from: Python 3.5.3 (default, Jan 19 2017, 14:11:04)
# [GCC 6.3.0 20170118]
# Embedded file name: settings_provider\__init__.py
__author__ = 'sanyi'
class Settings:
no_value = object()
def __init__(self):
self._docu... | {'dir': 'python', 'id': '9454230', 'max_stars_count': '20', 'max_stars_repo_name': 'BenDerPan/DScaner', 'max_stars_repo_path': 'acunetix/v11/db/tables/settings_provider.py', 'n_tokens_mistral': 452, 'n_tokens_neox': 411, 'n_words': 120} |
package main;
import java.awt.Color;
import java.awt.GridBagConstraints;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.awt.image.BufferedImage;
import java.io.IOException;
import javax.imageio.ImageIO;
import javax.swing.BoxLayout;
import javax.swing.JButton;
import javax.swing.J... | {'dir': 'java', 'id': '18983277', 'max_stars_count': '0', 'max_stars_repo_name': 'peremoya2000/ImageEditor', 'max_stars_repo_path': 'ImageEditor/src/main/ControlPanel.java', 'n_tokens_mistral': 2683, 'n_tokens_neox': 2133, 'n_words': 375} |
<reponame>jasminetroll/LgTvControl<gh_stars>0
#!/usr/bin/env python3
'''Sample command-line client for LgTvControl REST API.'''
import os,sys,requests
def url(*parts):
return requests.urllib3.util.Url(
scheme='http',
host='localhost',
port=3840,
path=os.path.join(*(['LgTv'] + list(... | {'dir': 'python', 'id': '8098513', 'max_stars_count': '0', 'max_stars_repo_name': 'jasminetroll/LgTvControl', 'max_stars_repo_path': 'Scripts/lgtvctl.py', 'n_tokens_mistral': 631, 'n_tokens_neox': 621, 'n_words': 136} |
<reponame>rjmrohit94/WSN-PrecisionAgriculture-Simulator
/******************************************************************************************
* File Name:
* Author(s):
* Desciption:
* Created Date:
* License:
*
*********************************************************************************************/
#ifnde... | {'dir': 'c', 'id': '3487361', 'max_stars_count': '0', 'max_stars_repo_name': 'rjmrohit94/WSN-PrecisionAgriculture-Simulator', 'max_stars_repo_path': 'inc/BaseStation.h', 'n_tokens_mistral': 495, 'n_tokens_neox': 468, 'n_words': 98} |
<filename>mmap_windows.go
// +build windows
package fsm
import (
"os"
"reflect"
"syscall"
"unsafe"
)
var allocationGranularity = func() int {
kernel32 := syscall.NewLazyDLL("kernel32.dll")
getSystemInfo := kernel32.NewProc("GetSystemInfo")
systemInfo := struct {
wProcessorArchitecture uint16
wReserv... | {'dir': 'go', 'id': '4157265', 'max_stars_count': '7', 'max_stars_repo_name': 'roy2220/fsm', 'max_stars_repo_path': 'mmap_windows.go', 'n_tokens_mistral': 695, 'n_tokens_neox': 596, 'n_words': 127} |
<gh_stars>0
#include "SunflowerManger.h"
#include "Rain.h"
SunflowerManger* SunflowerManger::mySunflowerManager = nullptr;
bool SunflowerManger::init(){
myNumberOfClickedSunshine = 0;
initial();
this->schedule(schedule_selector(SunflowerManger::mutUpdate), INTERVAL_TIME);
return true;
}
void Sunflowe... | {'dir': 'cpp', 'id': '1489583', 'max_stars_count': '0', 'max_stars_repo_name': 'RabbitLee/PlantsVsRabbits', 'max_stars_repo_path': 'Classes/SunflowerManger.cpp', 'n_tokens_mistral': 1003, 'n_tokens_neox': 825, 'n_words': 140} |
package mail
import (
"encoding/json"
"fmt"
"github.com/jordan-wright/email"
"gocms/app/models/base"
"gocms/pkg/config"
"gocms/pkg/help"
"net/textproto"
"sync"
"time"
)
const (
TASK_WAIT = 1
TASK_RUNING = 2
TASK_COMPLETED = 3
TASK_FAILED = 4
TASK_DELETE = 5
)
type TaskWarp interface {
Up... | {'dir': 'go', 'id': '1246866', 'max_stars_count': '15', 'max_stars_repo_name': 'Lets-Go-together/go-funny-cms', 'max_stars_repo_path': 'pkg/mail/task.go', 'n_tokens_mistral': 1136, 'n_tokens_neox': 1067, 'n_words': 215} |
package io.roger.crypto.server;
import java.io.*;
import java.net.*;
import java.security.*;
import javax.crypto.NoSuchPaddingException;
import javax.net.ServerSocketFactory;
import javax.net.ssl.SSLServerSocketFactory;
import io.roger.crypto.config.ServerConfig;
import io.roger.crypto.cryptography.Certificates;
imp... | {'dir': 'java', 'id': '11126759', 'max_stars_count': '0', 'max_stars_repo_name': 'roger-29/dat159-crypto', 'max_stars_repo_path': 'src/main/java/io/roger/crypto/server/TCPServerSSLRSA.java', 'n_tokens_mistral': 1018, 'n_tokens_neox': 904, 'n_words': 201} |
// tslint:disable
/**
* Copyright 2020 Splunk, 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 applicable l... | {'dir': 'typescript', 'id': '9018900', 'max_stars_count': '0', 'max_stars_repo_name': 'saviotsui/splunk-cloud-sdk-js', 'max_stars_repo_path': 'src/services/search/v2beta1/apis/GeneratedApis.ts', 'n_tokens_mistral': 3116, 'n_tokens_neox': 2999, 'n_words': 1148} |
<reponame>1stjavawizard/school-management-system-full-package<gh_stars>0
<?php
session_start();
if(!isset($_SESSION['users'])){
session_destroy();
header("Location: https://www.thiscodeschool.com/confab/");
}
else{
$user = "The user of ".$_SESSION['users'];
}
include_once('Note.php');
$assignteachertoclass... | {'dir': 'php', 'id': '2124972', 'max_stars_count': '0', 'max_stars_repo_name': '1stjavawizard/school-management-system-full-package', 'max_stars_repo_path': 'teacher/note/index.php', 'n_tokens_mistral': 15163, 'n_tokens_neox': 10636, 'n_words': 1753} |
<reponame>Abang256/WebFundamentals
<!DOCTYPE html>
<html devsite>
<head>
<meta name="project_path" value="/web/tools/workbox/_project.yaml" />
<meta name="book_path" value="/web/tools/workbox/_book.yaml" />
<meta name="gtm_var" data-key="docType" data-value="reference">
<title>Class: Router</title>
<link hre... | {'dir': 'html', 'id': '2905559', 'max_stars_count': '4', 'max_stars_repo_name': 'Abang256/WebFundamentals', 'max_stars_repo_path': 'src/content/en/tools/workbox/reference-docs/prerelease/workbox.routing.Router.html', 'n_tokens_mistral': 3720, 'n_tokens_neox': 3547, 'n_words': 879} |
#include "defs.h"
#include "pcm.h"
#include "rc.h"
struct pcm pcm;
static byte buf[4096];
rcvar_t pcm_exports[] =
{
RCV_END
};
void pcm_init()
{
pcm.hz = 11025;
pcm.buf = buf;
pcm.len = sizeof buf;
pcm.pos = 0;
}
void pcm_close()
{
memset(&pcm, 0, sizeof pcm);
}
int pcm_submit()
{
pcm.pos = 0;
retu... | {'dir': 'c', 'id': '177925', 'max_stars_count': '0', 'max_stars_repo_name': 'pdpdds/SDLGameProgramming', 'max_stars_repo_path': 'sdl2/GNUBoy/sys/dummy/nosound.c', 'n_tokens_mistral': 184, 'n_tokens_neox': 164, 'n_words': 38} |
<reponame>eSquire-qq/BrainOut
package com.desertkun.brainout.content.components;
import com.badlogic.gdx.utils.Json;
import com.badlogic.gdx.utils.JsonValue;
import com.desertkun.brainout.content.components.base.ContentComponent;
import com.desertkun.brainout.data.active.ActiveData;
import com.desertkun.brainout.data.... | {'dir': 'java', 'id': '18751420', 'max_stars_count': '31', 'max_stars_repo_name': 'eSquire-qq/BrainOut', 'max_stars_repo_path': 'core/src/com/desertkun/brainout/content/components/PhysicsCollisionDetectorComponent.java', 'n_tokens_mistral': 395, 'n_tokens_neox': 374, 'n_words': 61} |
<filename>protected/modules/yeeki/modules/wiki/migrations/m120213_183419_init.php
<?php
/**
* Initial application schema
*/
class m120213_183419_init extends yupe\components\DbMigration
{
public function up()
{
$db = Yii::app()->db;
$options = Yii::app()->db->schema instanceof CMysqlSchema ? '... | {'dir': 'php', 'id': '14726098', 'max_stars_count': '3', 'max_stars_repo_name': 'StWings/yupe', 'max_stars_repo_path': 'protected/modules/yeeki/modules/wiki/migrations/m120213_183419_init.php', 'n_tokens_mistral': 853, 'n_tokens_neox': 811, 'n_words': 124} |
package org.infinispan.counter.api;
/**
* A synchronous {@link StrongCounter}.
*
* @author <NAME>
* @since 9.2
*/
public interface SyncStrongCounter {
/**
* @see StrongCounter#incrementAndGet()
*/
default long incrementAndGet() {
return addAndGet(1);
}
/**
* @see StrongCounter#decr... | {'dir': 'java', 'id': '12907705', 'max_stars_count': '713', 'max_stars_repo_name': 'franz1981/infinispan', 'max_stars_repo_path': 'commons/all/src/main/java/org/infinispan/counter/api/SyncStrongCounter.java', 'n_tokens_mistral': 384, 'n_tokens_neox': 368, 'n_words': 73} |
import styled from "styled-components";
import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";
export const StyledFontAwesomeIcon = styled(FontAwesomeIcon)`
color: rgb(85, 85, 85);
`;
StyledFontAwesomeIcon.displayName = "StyledFontAwesomeIcon";
export const StyledFooter = styled.footer`
width: 100%;
... | {'dir': 'javascript', 'id': '1652296', 'max_stars_count': '0', 'max_stars_repo_name': 'mlobunko/portfolio', 'max_stars_repo_path': 'src/app/footer/components/styles.js', 'n_tokens_mistral': 272, 'n_tokens_neox': 238, 'n_words': 57} |
import React from "react"
import styled from "styled-components"
import cziLogo from "../images/czi-logo.png"
import clcLogo from "../images/clc-logo.png"
import tdLogo from "../images/td-logo.png"
import loyaltyLogo from "../images/loyalty-logo.png"
import AngleRight from "../images/angle-right-solid.js"
const FlexC... | {'dir': 'javascript', 'id': '17012513', 'max_stars_count': '0', 'max_stars_repo_name': 'ellenprobst/portfolio-2020', 'max_stars_repo_path': 'src/components/work.js', 'n_tokens_mistral': 741, 'n_tokens_neox': 703, 'n_words': 192} |
/**
* A wrapper for data/observable subscriptions, allowing simple subscribing and unsubscribing to data/observable changes
* without direct references to the market, the original observables, or the callback to be (un)registered.
*
* @template T
* @template K
*/
export interface ISubscription {
/**
* Subscr... | {'dir': 'typescript', 'id': '47931', 'max_stars_count': '26', 'max_stars_repo_name': 'dorofino/matterport-model-three-animator', 'max_stars_repo_path': 'src/sdk-components/core/src/subscription/ISubscription.ts', 'n_tokens_mistral': 237, 'n_tokens_neox': 228, 'n_words': 103} |
<filename>tests/rackspace/requests/storage/large_object_tests.rb<gh_stars>0
Shindo.tests('Fog::Storage[:rackspace] | large object requests', ["rackspace"]) do
unless Fog.mocking?
@directory = Fog::Storage[:rackspace].directories.create(:key => 'foglargeobjecttests')
@directory2 = Fog::Storage[:rackspace].dir... | {'dir': 'ruby', 'id': '3236409', 'max_stars_count': '0', 'max_stars_repo_name': 'strzibny/fog', 'max_stars_repo_path': 'tests/rackspace/requests/storage/large_object_tests.rb', 'n_tokens_mistral': 2186, 'n_tokens_neox': 1864, 'n_words': 309} |
/*
Copyright (c) 2005 WARP ItSelf & <NAME>
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the fol... | {'dir': 'cpp', 'id': '2197022', 'max_stars_count': '1', 'max_stars_repo_name': 'TheChatty/FarManager', 'max_stars_repo_path': 'misc/lng/lng.convertor.cpp', 'n_tokens_mistral': 4844, 'n_tokens_neox': 4084, 'n_words': 1043} |
<gh_stars>1-10
package command
import (
"path/filepath"
"github.com/alibaba/kt-connect/pkg/kt/options"
"github.com/urfave/cli"
)
// AppFlags return app flags
func AppFlags(options *options.DaemonOptions) []cli.Flag {
return []cli.Flag{
cli.StringFlag{
Name: "namespace,n",
Value: "default",
... | {'dir': 'go', 'id': '318688', 'max_stars_count': '1', 'max_stars_repo_name': 'kubernetes-projects/kt-connect', 'max_stars_repo_path': 'pkg/kt/command/global.go', 'n_tokens_mistral': 410, 'n_tokens_neox': 368, 'n_words': 65} |
//
// DoraemonTimeProfilerCore.h
// DoraemonKit-DoraemonKit
//
// Created by yixiang on 2019/7/9.
//
#ifndef DoraemonTimeProfilerCore_h
#define DoraemonTimeProfilerCore_h
#include <stdio.h>
#include <objc/objc.h>
typedef struct {
__unsafe_unretained Class cls;
SEL sel;
uint64_t time; // us (1/1000 ms)... | {'dir': 'c', 'id': '5973653', 'max_stars_count': '1', 'max_stars_repo_name': 'chaoskyme/DoraemonKit', 'max_stars_repo_path': 'iOS/DoraemonKit/Src/Core/Plugin/TimeProfiler/Function/DoraemonTimeProfilerCore.h', 'n_tokens_mistral': 292, 'n_tokens_neox': 269, 'n_words': 57} |
package net.coding.mart.json;
/**
* Created by chenchao on 16/5/30.
*/
public interface BasicJobInfo {
String getName();
int getId();
String getRoles();
String getFormatPrice();
String getRewardTypeName();
int getDuration();
String getDurationString();
}
| {'dir': 'java', 'id': '11309078', 'max_stars_count': '1', 'max_stars_repo_name': 'JingMeng/Mart-Android', 'max_stars_repo_path': 'app/src/main/java/net/coding/mart/json/BasicJobInfo.java', 'n_tokens_mistral': 92, 'n_tokens_neox': 87, 'n_words': 24} |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.