max_stars_count int64 301 224k | text stringlengths 6 1.05M | token_count int64 3 727k |
|---|---|---|
622 | /*
* Copyright (C) 2012-2016 Facebook, 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 law or ag... | 4,746 |
3,645 | <gh_stars>1000+
/*
* Audible AA demuxer
* Copyright (c) 2015 <NAME>
*
* Header parsing is borrowed from https://github.com/jteeuwen/audible project.
* Copyright (c) 2001-2014, <NAME>
*
* Redistribution and use in source and binary forms, with or without modification,
* are permitted provided that the following ... | 5,031 |
1,777 | //
// CustomViewCell.h
// InAppSettingsKitSampleApp
//
// Created by <NAME> on 05.11.10.
// Copyright 2010 FutureTap. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface CustomViewCell : UITableViewCell {
UITextView *textView;
}
@property (nonatomic, retain) IBOutlet UITextView *textView;
@end
| 114 |
1,374 | /*
* JSweet - http://www.jsweet.org
* Copyright (C) 2015 CINCHEO SAS <<EMAIL>>
*
* 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
*... | 340 |
5,937 | <gh_stars>1000+
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
//+-----------------------------------------------------------------------------
//
//
// $TAG EN... | 3,510 |
621 | <reponame>rtg0795/data-validation
# 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 applic... | 710 |
453 | /*#######################################################################
# RDOS operating system
# Copyright (C) 1988-2006, <NAME>
#
# This library is free software; you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as published
# by the Free Software Foundation; eithe... | 1,378 |
384 | /*
* Copyright (C) 2013 The Android Open Source Project
*
* 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 app... | 2,275 |
750 | from piccolo.conf.apps import AppConfig
from .commands.dump import dump
from .commands.load import load
APP_CONFIG = AppConfig(
app_name="fixtures",
migrations_folder_path="",
table_classes=[],
migration_dependencies=[],
commands=[dump, load],
)
| 94 |
398 | /**************************************************************************\
|
| Copyright (C) 2009 <NAME>
|
| This program 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 3 of the L... | 2,239 |
764 | {"symbol": "ADB","address": "0x2baac9330Cf9aC479D819195794d79AD0c7616e3","overview":{"en": ""},"email": "<EMAIL>","website": "https://adbank.network/","state": "NORMAL","links": {"blog": "https://medium.com/adbank-blog/","twitter": "https://twitter.com/adbanknetwork","telegram": "https://t.me/adbanknetwork","github": "... | 121 |
360 | <reponame>NishanthJKumar/iGibson
import argparse
import json
import os
import parser
import bddl
import igibson
from igibson.envs.behavior_env import BehaviorEnv
from igibson.metrics.agent import BehaviorRobotMetric, FetchRobotMetric
from igibson.metrics.disarrangement import KinematicDisarrangement, LogicalDisarrang... | 1,162 |
645 | <filename>javatests/org/chromium/distiller/webdocument/filters/LeadImageFinderTest.java
// Copyright 2015 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
package org.chromium.distiller.webdocument.filters;
import org.ch... | 1,347 |
10,525 | <reponame>ClanceyHuang/ip2region<filename>binding/nginx/ngx_ip2region_module.c
#include <ngx_config.h>
#include <ngx_core.h>
#include "ngx_ip2region.h"
static void *ngx_ip2region_create_conf(ngx_cycle_t *cycle);
static char *ngx_ip2region_init_conf(ngx_cycle_t *cycle, void *conf);
static ngx_int_t ngx_ip2region_ini... | 3,743 |
436 | <gh_stars>100-1000
package com.qiyi.tm.demo.test;
public interface ITest {
public void doTest();
}
| 42 |
1,350 | <reponame>Shashi-rk/azure-sdk-for-java
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
package com.azure.cosmos.implementation.directconnectivity;
import com.azure.cosmos.implementation.Configs;
import com.azure.cosmos.implementation.IAuthorizationTokenProvider;
import ... | 1,306 |
332 | <filename>sdk/src/main/java/com/vk/api/sdk/objects/ads/StatsCities.java<gh_stars>100-1000
// Autogenerated from vk-api-schema. Please don't edit it manually.
package com.vk.api.sdk.objects.ads;
import com.google.gson.Gson;
import com.google.gson.annotations.SerializedName;
import com.vk.api.sdk.objects.Validable;
impo... | 1,102 |
965 | <reponame>bobbrow/cpp-docs
class CTray : public CObject { };
class CStack : public CTypedPtrList< CObList, CTray* >
{
public:
// Add element to top of stack
void Push(CTray* newTray)
{
AddHead(newTray);
}
// Peek at top element of stack
CTray* Peek()
{
return IsEmpty() ? NULL : GetHea... | 173 |
348 | <filename>docs/data/leg-t2/0ZP/0ZP01018.json
{"nom":"Fatu-Hiva","circ":"1ère circonscription","dpt":"Polynésie française","inscrits":552,"abs":299,"votants":253,"blancs":5,"nuls":3,"exp":245,"res":[{"nuance":"UDI","nom":"<NAME>","voix":189},{"nuance":"DVD","nom":"<NAME>","voix":56}]} | 120 |
879 | <reponame>qianfei11/zstack<gh_stars>100-1000
package org.zstack.kvm;
import org.zstack.header.core.Completion;
import org.zstack.header.errorcode.ErrorCode;
import org.zstack.header.host.TakeSnapshotOnHypervisorMsg;
public interface KVMTakeSnapshotExtensionPoint {
void beforeTakeSnapshot(KVMHostInventory host, T... | 251 |
597 | """Validate services schema."""
from importlib import import_module
from pathlib import Path
import voluptuous as vol
from ..const import ATTR_ADDON, ATTR_CONFIG, ATTR_DISCOVERY, ATTR_SERVICE, ATTR_UUID
from ..utils.validate import schema_or
from ..validate import uuid_match
def valid_discovery_service(service):
... | 585 |
585 | # Copyright (c) 2016-present, Facebook, 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 law or agreed... | 1,811 |
6,240 | <reponame>Chen188/chalice<gh_stars>1000+
{
"schema-version": "0.2",
"changes": [
{
"category": "CLI",
"description": "Add ``--connection-timeout`` to the ``deploy`` command\n(`#344 <https://github.com/aws/chalice/issues/344>`__)",
"type": "feature"
},
{
"category": "policy",
... | 450 |
2,151 | // Copyright (c) 2013 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "net/third_party/quic/core/spdy_utils.h"
#include <memory>
#include <vector>
#include "net/third_party/quic/platform/api/quic_flag_utils.h"... | 2,952 |
12,278 | <reponame>Harshitha91/Tmdb-react-native-node
/*
Copyright 2018 <NAME>
(<EMAIL>)
Distributed under the Boost Software License, Version 1.0.
(http://www.boost.org/LICENSE_1_0.txt)
*/
#ifndef BOOST_TYPEOF_CONSTANT_HPP
#define BOOST_TYPEOF_CONSTANT_HPP
#include <boost/config.hpp>
namespace boost {
namespace type_of {
t... | 219 |
7,482 | <filename>bsp/apm32/libraries/APM32F10x_Library/APM32F10x_StdPeriphDriver/inc/apm32f10x_usart.h
/*!
* @file apm32f10x_usart.h
*
* @brief This file contains all the functions prototypes for the USART firmware library
*
* @version V1.0.1
*
* @date 2021-03-23
*
*/
#ifndef __APM32F10X_USART_H
... | 3,388 |
488 |
#include <numeric>
#include "MatrixTypeTransformer.h"
#include "rose.h"
#include "sageGeneric.h"
#include "utility/utils.h"
namespace sb = SageBuilder;
namespace ru = RoseUtils;
namespace MatlabToCpp
{
// \note see below for an alternative approach
struct MatrixTypeSetter : AstSimpleProcessing
{
typede... | 2,994 |
575 | // Copyright 2016 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "components/ntp_tiles/icon_cacher_impl.h"
#include <utility>
#include "base/bind.h"
#include "base/metrics/field_trial_params.h"
#include "base... | 4,361 |
328 | /* Copyright 2021 The TensorFlow Authors. All Rights Reserved.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or a... | 2,648 |
4,640 | /*
* 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 ... | 3,568 |
362 | import networkx
import numpy as np
def partition(embeddings):
''' Compute a partition of embeddings, where each partition is pooled together.
Args:
embeddings: N-by-D matrix, where N is the number of node embeddings, and D
is the embedding dimension.
'''
dist = np.dot(embeddings)
... | 473 |
2,293 | from dynaconf.utils import build_env_list
from dynaconf.utils import upperfy
from dynaconf.utils.parse_conf import parse_conf_data
from dynaconf.utils.parse_conf import unparse_conf_data
try:
from redis import StrictRedis
except ImportError:
StrictRedis = None
IDENTIFIER = "redis"
def load(obj, env=None, si... | 1,603 |
1,388 | <gh_stars>1000+
//
// Copyright 2016 <NAME>
//
// 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... | 1,527 |
3,682 | # local/serializers/factory.py
import importlib
def get_serializer(format):
try:
module = importlib.import_module(f"serializers.{format}")
serializer = getattr(module, f"{format.title()}Serializer")
except (ImportError, AttributeError):
raise ValueError(f"Unknown format {format!r}") f... | 178 |
777 | <gh_stars>100-1000
// Copyright 2016 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "base/strings/utf_string_conversions.h"
#include "base/test/scoped_command_line.h"
#include "base/test/scoped_feature_list.h"
... | 1,688 |
892 | <filename>advisories/unreviewed/2022/04/GHSA-cr34-rcr6-jr32/GHSA-cr34-rcr6-jr32.json
{
"schema_version": "1.2.0",
"id": "GHSA-cr34-rcr6-jr32",
"modified": "2022-04-30T18:17:24Z",
"published": "2022-04-30T18:17:24Z",
"aliases": [
"CVE-2001-1130"
],
"details": "Sdbsearch.cgi in SuSE Linux 6.0-7.2 could ... | 534 |
348 | {"nom":"Apremont","circ":"3ème circonscription","dpt":"Ardennes","inscrits":96,"abs":36,"votants":60,"blancs":4,"nuls":2,"exp":54,"res":[{"nuance":"LR","nom":"<NAME>","voix":42},{"nuance":"FN","nom":"<NAME>","voix":12}]} | 89 |
1,085 | /*
* Copyright (C) 2017-2019 Dremio Corporation
*
* 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... | 614 |
343 | // Copyright 2014 Google Inc. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable... | 643 |
1,338 | #include <Application.h>
#include <DirectWindow.h>
#include <stdio.h>
static const char *
state_to_string(direct_buffer_state state)
{
//TODO: Return more info like B_CLIPPING_MODIFIED, etc.
switch (state & B_DIRECT_MODE_MASK) {
case B_DIRECT_START:
return "B_DIRECT_START";
case B_DIRECT_STOP:
return ... | 1,018 |
2,151 | //===-- SPUTargetMachine.h - Define TargetMachine for Cell SPU ----*- C++ -*-=//
//
// The LLVM Compiler Infrastructure
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===-------------------------------------------------------... | 889 |
486 | <gh_stars>100-1000
//
// Copyright (C) 2019 Microsoft. All rights reserved.
// See LICENSE file in the project root for full license information.
//
#include "catch.hpp"
#include "msixtest_int.hpp"
#include "UnpackTestData.hpp"
#include "FileHelpers.hpp"
#include <iostream>
void RunUnpackTest(HRESULT e... | 7,472 |
574 | <filename>joints_detectors/Alphapose/online_demo.py
import torch
from torch.autograd import Variable
import torch.nn.functional as F
import torchvision.transforms as transforms
import torch.nn as nn
import torch.utils.data
import numpy as np
from opt import opt
from dataloader import WebcamLoader, DataWriter, crop_fr... | 2,776 |
645 | // Copyright 2013 Viewfinder. All rights reserved.
// Author: <NAME>
package co.viewfinder;
class DBFormat {
public static String userIdKey() {
return "u/";
}
public static String userIdKey(long userId) {
return userIdKey() + Long.toString(userId);
}
}
| 90 |
675 | #include "game_settings.h"
#include "engine/core/log/Log.h"
#include "engine/core/util/PathUtil.h"
#include "engine/core/io/IO.h"
#include "engine/core/render/base/renderer.h"
#include "engine/core/main/Engine.h"
#include "engine/core/scene/node_tree.h"
#include <ostream>
namespace Echo
{
GameSettings::GameSettings()... | 2,022 |
3,531 | <reponame>zhangtemplar/esp-adf
/**
* @file lv_demo_music_main.h
*
*/
#ifndef LV_DEMO_MUSIC_MAIN_H
#define LV_DEMO_MUSIC_MAIN_H
#ifdef __cplusplus
extern "C" {
#endif
/*********************
* INCLUDES
*********************/
#include "lv_demo_music.h"
#if LV_USE_DEMO_MUSIC
/*********************
* DEF... | 369 |
317 | <filename>Modules/Learning/Supervised/include/otbLibSVMMachineLearningModel.hxx
/*
* Copyright (C) 2005-2020 Centre National d'Etudes Spatiales (CNES)
*
* This file is part of Orfeo Toolbox
*
* https://www.orfeo-toolbox.org/
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not u... | 6,144 |
372 | <filename>clients/google-api-services-gamesConfiguration/v1configuration/1.29.2/com/google/api/services/gamesConfiguration/GamesConfiguration.java
/*
* 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 Licens... | 23,402 |
2,305 | # Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.
"""Thie file handles "slice" commonly used in mixed-operation.
The ``slice_type`` we support here, is "slice" or "list of slice".
The reason is that sometimes (e.g., in multi-head attention),
the tensor slice could be from multiple parts. This t... | 4,618 |
732 | <gh_stars>100-1000
import logging
import json
from tandem.shared.protocol.messages.base import ProtocolMarshalError
class ProtocolHandlerBase(object):
def _protocol_message_utils(self):
return None
def _protocol_message_handlers(self):
return None
def _extra_handler_arguments(self, io_da... | 763 |
5,730 | package org.ansj.domain;
import org.ansj.recognition.Recognition;
import org.nlpcn.commons.lang.util.StringUtil;
import java.util.Iterator;
import java.util.List;
/**
* 分词结果的一个封装
*
* @author Ansj
*
*/
public class Result implements Iterable<Term> {
private char[] chars ;
private List<Term> terms = null;
... | 644 |
4,036 | <filename>java/ql/test/stubs/shiro-core-1.4.0/org/apache/shiro/crypto/PaddingScheme.java
package org.apache.shiro.crypto;
public enum PaddingScheme {
NONE("NoPadding"),
ISO10126("ISO10126Padding"),
OAEP("OAEPPadding"),
OAEPWithMd5AndMgf1("OAEPWithMD5AndMGF1Padding"),
OAEPWithSha1AndMgf1("OAEPWithSH... | 368 |
433 | <reponame>dbramwell/django-select2
from django.urls import include, path
from .forms import (
AddressChainedSelect2WidgetForm,
AlbumModelSelect2WidgetForm,
HeavySelect2MultipleWidgetForm,
HeavySelect2WidgetForm,
ModelSelect2TagWidgetForm,
Select2WidgetForm,
)
from .views import TemplateFormView... | 663 |
683 | /*
* Copyright The OpenTelemetry Authors
* SPDX-License-Identifier: Apache-2.0
*/
package io.opentelemetry.javaagent.instrumentation.tomcat.v7_0;
import io.opentelemetry.instrumentation.api.instrumenter.Instrumenter;
import io.opentelemetry.javaagent.instrumentation.servlet.v3_0.Servlet3Accessor;
import io.opentel... | 476 |
1,337 | <reponame>wwjiang007/cuba
/*
* Copyright (c) 2008-2016 Haulmont.
*
* 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 require... | 21,562 |
372 | <gh_stars>100-1000
/*
* 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 ... | 786 |
507 | <reponame>mjuenema/python-terrascript
# terrascript/data/onelogin/onelogin.py
# Automatically generated by tools/makecode.py (24-Sep-2021 15:23:37 UTC)
import terrascript
class onelogin_user(terrascript.Data):
pass
class onelogin_users(terrascript.Data):
pass
__all__ = [
"onelogin_user",
"onelogin... | 135 |
421 |
// <Snippet1>
using namespace System;
using namespace System::Collections;
void PrintValues( IEnumerable^ myList, char mySeparator );
int main()
{
// Creates and initializes a new ArrayList.
ArrayList^ myAL = gcnew ArrayList;
myAL->Add( "The" );
myAL->Add( "quick" );
myAL->Add( "brown" )... | 695 |
453 | /* Support macros for making weak and strong aliases for symbols,
and for using symbol sets and linker warnings with GNU ld.
Copyright (C) 1995,1996,1997,1998,2000,2001 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
... | 4,724 |
594 | #include "qtestupdaterbackend.h"
#include "qtestupdateinstaller.h"
#include <chrono>
using namespace QtAutoUpdater;
using namespace std::chrono;
Q_LOGGING_CATEGORY(logTestPlugin, "qt.autoupdater.core.plugin.test")
QTestUpdaterBackend::QTestUpdaterBackend(QString &&key, QObject *parent) :
UpdaterBackend{std::move(key... | 1,689 |
2,151 | // Copyright 2014 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef CONTENT_BROWSER_FRAME_HOST_NAVIGATION_REQUEST_INFO_H_
#define CONTENT_BROWSER_FRAME_HOST_NAVIGATION_REQUEST_INFO_H_
#include <string>
#include "... | 835 |
386 | <reponame>oldium/FastLogin
/*
* SPDX-License-Identifier: MIT
*
* The MIT License (MIT)
*
* Copyright (c) 2015-2021 <Your name and contributors>
*
* 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 t... | 1,423 |
332 | /*
* Copyright 2013 the original author or 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 l... | 481 |
336 | "githelp.py -- helpers for doing things on git"
import fnmatch
import git
def parse_rev_to_tuple(rev_string):
if '...' in rev_string:
left, _, right = rev_string.partition('...')
return left, right
elif '..' in rev_string:
raise ValueError("we don't support two-dot strings -- use a three-dot")
else:... | 419 |
648 | <reponame>swrobel/fhir
{"resourceType":"DataElement","id":"MedicationRequest.dosageInstruction","meta":{"lastUpdated":"2017-04-19T07:44:43.294+10:00"},"url":"http://hl7.org/fhir/DataElement/MedicationRequest.dosageInstruction","status":"draft","experimental":true,"stringency":"fully-specified","element":[{"id":"Medicat... | 317 |
311 | <gh_stars>100-1000
/**
* Copyright 2019 The JoyQueue 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 b... | 654 |
614 | [
{ "home": "West Bromwich Albion", "away": "Everton", "homescore": "2", "awayscore": "3" },
{ "home": "Frosinone", "away": "Empoli", "homescore": "2", "awayscore": "0" },
{ "home": "Atalanta", "away": "Sampdoria", "homescore": "2", "awayscore": "1" },
{
"home": "TSV Eintracht Braunschweig",
"away": "Sp... | 1,718 |
4,224 | /****************************************************************************
*
* Copyright (c) 2017 PX4 Development Team. 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. Redistri... | 1,259 |
471 | /////////////////////////////////////////////////////////////////////////////
// Name: wx/msw/brush.h
// Purpose: wxBrush class
// Author: <NAME>
// Modified by:
// Created: 01/02/97
// Copyright: (c) <NAME>
// Licence: wxWindows licence
////////////////////////////////////////////////////////... | 709 |
412 | interface Interface {
boolean b();
}
class Inner implements Interface {
public boolean b() { return false; }
}
class Outer implements Interface {
private Interface inner;
public Outer(Interface inner) { this.inner = inner; }
public boolean b() { return !inner.b(); }
}
public class Virtual {
public static... | 113 |
395 | <gh_stars>100-1000
package timely.api.request.subscription;
import timely.api.annotation.WebSocket;
@WebSocket(operation = "create")
public class CreateSubscription extends SubscriptionRequest {
}
| 57 |
6,688 | <filename>QtScrcpy/util/mousetap/xmousetap.cpp
#include <QX11Info>
#include <xcb/xproto.h>
#include <stdlib.h>
#include <stdint.h>
#include "xmousetap.h"
XMouseTap::XMouseTap() {}
XMouseTap::~XMouseTap() {}
void XMouseTap::initMouseEventTap() {}
void XMouseTap::quitMouseEventTap() {}
static void find_grab_window... | 1,379 |
640 | /*************************************************************************//**
*****************************************************************************
* @file misc.c
* @brief
* @author <NAME>
* @date 2008
*****************************************************************************
********************... | 566 |
13,511 | <filename>stetho/src/main/java/com/facebook/stetho/common/Utf8Charset.java
/*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
package com.facebook.stetho.common;
import java.io.Unsu... | 267 |
1,108 | <reponame>jaffrey007/sql2o<filename>core/src/test/java/org/sql2o/performance/UnderscoreToCamelCasePerformanceTests.java<gh_stars>1000+
package org.sql2o.performance;
import com.google.common.base.CaseFormat;
import com.google.common.collect.ImmutableList;
import org.junit.Test;
import org.sql2o.tools.UnderscoreToCamel... | 850 |
3,269 | # Time: O(m + n)
# Space: O(1)
class ListNode(object):
def __init__(self, x):
self.val = x
self.next = None
class Solution(object):
# @param two ListNodes
# @return the intersected ListNode
def getIntersectionNode(self, headA, headB):
curA, curB = headA, headB
while cu... | 209 |
571 |
"""
Conversion from country ISO codes to their full name
"""
iso2full = {"AF":"Afghanistan",
"AX":"Aland Islands",
"AL":"Albania",
"DZ":"Algeria",
"AS":"American Samoa",
"AD":"Andorra",
"AO":"Angola",
"AI":"Anguilla",
"AQ":"Antarctica",
"AG":"Antigua and Barbuda",
"AR":"Argentina",
"AM":"Armenia",
"AW":"Aruba... | 2,140 |
2,260 | #ifndef GAMEPAD_H_
#define GAMEPAD_H_
#include "Vector2.h"
namespace gameplay
{
class Button;
class Container;
class Form;
class JoystickControl;
class Platform;
/**
* Defines a gamepad interface for handling input from joysticks and buttons.
*
* A gamepad can be either physical or virtual. Most platform support... | 2,083 |
1,175 | <filename>Authenticated-Encryption/AE-with-MACs/MAC-then-Encrypt/mac-then-encrypt.py<gh_stars>1000+
"""
An illustration of MAC then Encrypt technique of Authenticated Encryption with MACs
MAC algorithm: CBC-MAC
Encryption: AES in CBC mode
Note that this is only for illustrative purposes (the script is vulnerable to CBC... | 929 |
997 | <filename>crypto_sign/sphincs-haraka-192f-simple/aesni/thash_haraka_simplex4.c
#include <stdint.h>
#include <string.h>
#include "address.h"
#include "haraka.h"
#include "params.h"
#include "thashx4.h"
/**
* 4-way parallel version of thash; takes 4x as much input and output
*/
#define thashx4_variant(name, inblocks)... | 4,145 |
1,350 | // Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
package com.azure.spring.integration.eventhub.util;
import com.azure.messaging.eventhubs.EventData;
import java.util.LinkedHashMap;
import java.util.Map;
/**
* Helper class to process {@link EventData}.
*/
public class... | 254 |
411 | package com.kiminonawa.mydiary.entries.diary.picker;
import android.app.DatePickerDialog;
import android.app.Dialog;
import android.os.Bundle;
import android.support.v4.app.DialogFragment;
import com.kiminonawa.mydiary.shared.ThemeManager;
import java.util.Calendar;
/**
* Created by daxia on 2016/11/25.
*/
publi... | 575 |
631 | /*
* Copyright 2018 <NAME>. All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable ... | 584 |
381 | package com.tngtech.jgiven.exception;
/**
* Thrown when a field cannot be uniquely resolved by the name or type.
*/
public class AmbiguousResolutionException extends JGivenWrongUsageException {
private static final long serialVersionUID = 1L;
public AmbiguousResolutionException( String message ) {
s... | 101 |
485 | from sys import argv
from utils import api
from os import getenv as _
from datetime import datetime
from dotenv import load_dotenv
load_dotenv()
argv += [''] * 1
def main():
try:
page = int(argv[1])
except:
page = 1
result = api('GET', f'paginate?page={page}')
for video in result['data']:
link = f... | 218 |
900 | package com.thedazzler.droidicon.test;
import java.util.Random;
import android.graphics.Color;
public class Utils {
public static int randomColor() {
Random random = new Random();
return Color.rgb(random.nextInt(255), random.nextInt(255), random.nextInt(255));
}
} | 107 |
984 | /*
* 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 ... | 1,674 |
333 | # -*- coding: utf-8 -*-
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
from __future__ import unicode_literals
import darknet_tools
import functools
import json
import os
import settings
import subprocess
import sys
from collections import defaultdict
fro... | 2,691 |
335 | <reponame>Safal08/Hacktoberfest-1
{
"word": "Cult",
"definitions": [
"A system of religious veneration and devotion directed towards a particular figure or object.",
"A relatively small group of people having religious beliefs or practices regarded by others as strange or as imposing excessive c... | 164 |
3,193 | #pragma once
#include <sol/string_view.hpp>
#include <array>
#include <cstring>
namespace sol {
// Everything here was lifted pretty much straight out of
// ogonek, because fuck figuring it out=
namespace unicode {
enum class error_code {
ok = 0,
invalid_code_point,
invalid_code_unit,
i... | 4,666 |
6,224 | <gh_stars>1000+
/*
* Copyright (c) 2016 Intel Corporation
*
* SPDX-License-Identifier: Apache-2.0
*/
#include <zephyr.h>
#include <ztest.h>
#include <arch/cpu.h>
#include <tc_util.h>
#ifdef CONFIG_BIG_ENDIAN
#define BIT_INDEX(bit) ((3 - ((bit >> 3) & 0x3)) + 4*(bit >> 5))
#else
#define BIT_INDEX(bit) (bit >> 3... | 1,964 |
5,169 | <filename>Specs/0/f/b/DateTimePicker/2.0.1/DateTimePicker.podspec.json
{
"name": "DateTimePicker",
"version": "2.0.1",
"summary": "A nicer iOS UI component for picking date and time.",
"description": "DateTimePicker makes it easy to select date and time with an attractive looking component.",
"homepage": "htt... | 361 |
421 | # This is a proof of concept for CVE-2020-11978, a RCE vulnerability in one of the example DAGs shipped with airflow
# This combines with CVE-2020-13927 where unauthenticated requests to Airflow's Experimental API were allowded by default.
# Together, potentially allows unauthenticated RCE to Airflow
#
# Proof of con... | 1,466 |
2,151 | // Copyright 2013 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef CHROMEOS_NETWORK_NETWORK_POLICY_OBSERVER_H_
#define CHROMEOS_NETWORK_NETWORK_POLICY_OBSERVER_H_
#include <string>
namespace chromeos {
class N... | 349 |
2,542 | // ------------------------------------------------------------
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License (MIT). See License.txt in the repo root for license information.
// ------------------------------------------------------------
#pragma once
namespace Data
{... | 388 |
369 | <filename>Example/Source/Shared/Geometry/Utilities/Icosahedron.c
//
// IcoSphereGenerator.c
// Geometry-macOS
//
// Created by <NAME> on 6/4/20.
// Copyright © 2020 Hi-Rez. All rights reserved.
//
#include "Icosahedron.h"
#include <malloc/_malloc.h>
#include <simd/simd.h>
GeometryData generateIcosahedronGeometry... | 2,244 |
1,467 | <filename>source/TonyHawksUnderground.WidescreenFix/dllmain.cpp
#include "stdafx.h"
#include <random>
struct Screen
{
int32_t Width;
int32_t Height;
float fWidth;
float fHeight;
int32_t Width43;
float fAspectRatio;
float fAspectRatioDiff;
float fFieldOfView;
float fHUDScaleX;
fl... | 3,246 |
573 | // Copyright 2015, VIXL authors
// 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 conditions ... | 58,401 |
3,495 | <filename>src/test/java/com/android/volley/cronet/CronetHttpStackTest.java
/*
* Copyright (C) 2020 The Android Open Source Project
*
* 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
*
* ... | 7,921 |
319 | '''
go list comprehensions
'''
def main():
a = []int(x for x in range(3))
TestError( len(a)==3 )
TestError( a[0]==0 )
TestError( a[1]==1 )
TestError( a[2]==2 )
| 79 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.