max_stars_count int64 301 224k | text stringlengths 6 1.05M | token_count int64 3 727k |
|---|---|---|
1,209 | /*
u8g_arm.c
u8g utility procedures for LPC122x
Universal 8bit Graphics Library
Copyright (c) 2013, <EMAIL>
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 ... | 8,283 |
541 | <filename>dspace-server-webapp/src/main/java/org/dspace/app/rest/model/VocabularyEntryRest.java
/**
* The contents of this file are subject to the license and copyright
* detailed in the LICENSE and NOTICE files at the root of the source
* tree and available online at
*
* http://www.dspace.org/license/
*/
package... | 725 |
12,366 | # 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 in writing, ... | 3,990 |
5,422 | <reponame>egelwan/Karabiner-Elements
// -*- mode: objective-c -*-
@import Cocoa;
@interface FnFunctionKeysTableViewController : NSObject
- (void)setup;
- (void)valueChanged:(id)sender;
- (void)updateConnectedDevicesMenu;
- (NSInteger)selectedConnectedDeviceIndex;
@end
| 99 |
1,155 | <gh_stars>1000+
/*
* Copyright 2009, <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, ... | 2,115 |
1,755 | <reponame>arobert01/ITK<filename>Modules/ThirdParty/MetaIO/src/MetaIO/src/metaCommand.h
/*============================================================================
MetaIO
Copyright 2000-2010 Insight Software Consortium
Distributed under the OSI-approved BSD License (the "License");
see accompanying file Cop... | 3,575 |
473 | #ifndef _EXTERNAL_API_H
#define _EXTERNAL_API_H
#include "libcgc.h"
#include "cgc_cgc_types.h"
#include "cgc_printf.h"
#define assert(x) \
do { if (!(x)) { cgc_printf("fail: " #x " at %s (%u)\n", __FILE__, __LINE__); } } while(0)
char *cgc_strchr(const char *s, int c);
char *cgc_strdup(const char *src);
char *cg... | 515 |
543 | <reponame>anastasiard/riiablo
package com.riiablo.map2;
import org.apache.commons.lang3.ArrayUtils;
import com.badlogic.gdx.math.Rectangle;
import com.badlogic.gdx.math.Vector2;
import com.badlogic.gdx.utils.IntArray;
import com.badlogic.gdx.utils.IntMap;
import com.riiablo.Riiablo;
import com.riiablo.io.ByteInput;
... | 7,925 |
310 | <filename>lib/core/include/chi/CCompiler.hpp
/// \file CCompiler.hpp
#ifndef CHI_C_COMPILER_HPP
#define CHI_C_COMPILER_HPP
#include <filesystem>
#include <string_view>
#include <vector>
#include "chi/Fwd.hpp"
#include "chi/Owned.hpp"
namespace chi {
/// Use clang to compile C source code to a llvm module
/// It al... | 391 |
1,405 | package android.support.v7.content.res;
import java.lang.reflect.Array;
final class GrowingArrayUtils {
static final /* synthetic */ boolean $assertionsDisabled = (!GrowingArrayUtils.class.desiredAssertionStatus());
/* JADX WARN: Multi-variable type inference failed */
/* JADX WARN: Type inference failed... | 2,402 |
3,269 | # Time: O(n^2 * 2^n)
# Space: O(2^n)
import itertools
from fractions import gcd
class Solution(object):
def maxScore(self, nums):
"""
:type nums: List[int]
:rtype: int
"""
def popcount(n):
count = 0
while n:
n &= n-1
... | 593 |
1,134 | <reponame>Adam-sHub/cfn-lint<filename>src/cfnlint/data/ExtendedSpecs/all/03_value_types/aws_kinesisanalyticsv2.json<gh_stars>1000+
[
{
"op": "add",
"path": "/ValueTypes/AWS::KinesisAnalyticsV2::Application.RuntimeEnvironment",
"value": {
"botocore": "kinesisanalyticsv2/2018-05-23/RuntimeEnvironment"... | 148 |
2,542 | <filename>src/prod/src/Reliability/Failover/ra/Test.Unit.Infrastructure.LookupTable.cpp
// ------------------------------------------------------------
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License (MIT). See License.txt in the repo root for license information.
// ----... | 2,116 |
1,056 | <filename>groovy/groovy.editor/src/org/netbeans/modules/groovy/editor/hints/RemoveUnusedImportHint.java
/*
* 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 ownersh... | 2,689 |
391 | <reponame>RequestPrivacy/sparrow<filename>src/main/java/com/sparrowwallet/sparrow/event/WalletEntryLabelsChangedEvent.java
package com.sparrowwallet.sparrow.event;
import com.sparrowwallet.drongo.wallet.Wallet;
import com.sparrowwallet.sparrow.wallet.Entry;
import java.util.List;
/**
* This event is fired when a wa... | 296 |
7,629 | # Copyright 2019 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 in writing, ... | 2,121 |
526 | <filename>open-metadata-implementation/frameworks/open-discovery-framework/src/main/java/org/odpi/openmetadata/frameworks/discovery/properties/DataField.java
/* SPDX-License-Identifier: Apache 2.0 */
/* Copyright Contributors to the ODPi Egeria project. */
package org.odpi.openmetadata.frameworks.discovery.properties;
... | 3,536 |
1,676 | /*
* sha2.h
* Author: <NAME>
*/
#ifndef CORE_SHA2_H_
#define CORE_SHA2_H_
#include <stdint.h>
#include <cstdlib>
namespace SHA2
{
//All outputs are "big-endian" in the sense that if you sequentially
//walked through the hash and wrote it in hex, you would get the standard
//digest. (within each individual h... | 1,040 |
5,169 | <reponame>ftapp/cocoapods
{
"name": "MiniDateView",
"version": "0.2.0",
"summary": "A mini date view that presents day-of-month, weekday, and month-of-year.",
"homepage": "https://github.com/Lessica/MiniDateView",
"license": "MIT",
"authors": {
"i_82": "<EMAIL>"
},
"source": {
"git": "https://gi... | 224 |
2,151 | <reponame>zipated/src
// 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.
#include "components/password_manager/core/browser/password_syncable_service.h"
#include <algorithm>
#include <iterator>
#include <... | 7,258 |
1,875 | /*
* 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 agreed ... | 694 |
523 | <filename>app/src/debug/java/io/github/droidkaigi/confsched2017/util/FpsMeasureUtil.java
package io.github.droidkaigi.confsched2017.util;
import android.app.Application;
import jp.wasabeef.takt.Seat;
import jp.wasabeef.takt.Takt;
import timber.log.Timber;
public class FpsMeasureUtil {
private FpsMeasureUtil() {... | 312 |
1,444 | <reponame>J-VOL/mage
package mage.cards.r;
import mage.MageInt;
import mage.abilities.common.AttacksTriggeredAbility;
import mage.abilities.costs.common.TapTargetCost;
import mage.abilities.effects.common.DoIfCostPaid;
import mage.abilities.effects.common.continuous.BoostSourceEffect;
import mage.abilities.effects.com... | 824 |
3,508 | <filename>src/main/java/com/fishercoder/solutions/_1104.java
package com.fishercoder.solutions;
import com.fishercoder.common.classes.TreeNode;
import com.fishercoder.common.utils.CommonUtils;
import com.fishercoder.common.utils.TreeUtils;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collecti... | 2,521 |
713 | package org.infinispan.server.test.core;
/**
* @author <NAME> <<EMAIL>>
* @since 11.0
**/
public interface InfinispanServerListener {
default void before(InfinispanServerDriver driver) {
}
default void after(InfinispanServerDriver driver) {
}
}
| 95 |
327 | package com.honvay.cola.cloud.upm.entity;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.enums.IdType;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombo... | 390 |
17,702 | <reponame>shyamalschandra/CNTK
#pragma once
#ifndef CPUONLY
#include <cuda_runtime_api.h>
#include <cuda.h>
#endif // !CPUONLY
#include "Basics.h"
#ifdef _WIN32
#ifndef MATH_API
#ifdef MATH_EXPORTS
#define MATH_API __declspec(dllexport)
#else
#define MATH_API __declspec(dllimport)
#endif
#endif /* MATH_API */
#else ... | 1,462 |
4,013 | import logging
from typing import Dict, List, Union, Any
from checkov.common.util.type_forcers import convert_str_to_bool
from checkov.terraform.parser_utils import eval_string, split_merge_args, string_to_native, to_string
#
# Functions defined in this file implement terraform functions.
#
# Inputs:
# - First arg ... | 2,406 |
2,607 | package p.runtime.values;
/**
* Interface that must be implemented by all P values.
* @param <T> T is the type of P Value
*/
public abstract class PValue<T extends PValue<T>> {
/**
* Function to create a deep clone of the PValue
* @return deep clone of the PValue
*/
public abstract T clone();... | 562 |
1,561 | // Copyright 1996-2021 Cyberbotics Ltd.
//
// 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 agr... | 1,109 |
2,453 | //
// Generated by class-dump 3.5 (64 bit) (Debug version compiled Sep 30 2020 21:18:12).
//
// Copyright (C) 1997-2019 <NAME>.
//
#import <IDEFoundation/IDESchemeActionTestFailureStep.h>
#import <IDEKit/IDETestReport_Base-Protocol.h>
@class DVTTextDocumentLocation, NSString;
@protocol IDEResultBundleURLRedirec... | 322 |
1,393 | # Copyright (c) 2017-2018 Uber Technologies, 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 ... | 1,128 |
6,717 | //******************************************************************************
//
// Copyright (c) 2016 Microsoft Corporation. All rights reserved.
//
// This code is licensed under the MIT License (MIT).
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LI... | 442 |
621 | /*++
Copyright (c) 2019-2020 changeofpace. All rights reserved.
Use of this source code is governed by the MIT license. See the 'LICENSE' file
for more information.
--*/
#pragma once
#include <Windows.h>
#include <string.h>
#include <string>
#include <vector>
#include "../common/config.h"
//===================... | 2,211 |
1,250 | from .internals import Internals
| 8 |
348 | {"nom":"Bossus-lès-Rumigny","circ":"1ère circonscription","dpt":"Ardennes","inscrits":80,"abs":34,"votants":46,"blancs":2,"nuls":0,"exp":44,"res":[{"nuance":"LR","nom":"<NAME>","voix":38},{"nuance":"REM","nom":"<NAME>","voix":6}]} | 95 |
713 | <gh_stars>100-1000
package org.infinispan.client.hotrod.event.impl;
import static org.infinispan.client.hotrod.logging.Log.HOTROD;
import java.lang.annotation.Annotation;
import java.lang.reflect.Method;
import java.net.SocketAddress;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.HashMap;
impo... | 2,790 |
606 | <reponame>vmarkushin/Arend
package org.arend.repl;
import org.jetbrains.annotations.NotNull;
import java.util.Arrays;
import java.util.List;
import java.util.function.Supplier;
/**
* The default action. No action command.
* Added to {@link Repl} by default.
*/
public final class CodeParsingHandler implements Repl... | 448 |
13,648 | <filename>tests/basics/assign_expr.py
(x := 4)
print(x)
if x := 2:
print(True)
print(x)
print(4, x := 5)
print(x)
x = 1
print(x, x := 5, x)
print(x)
def foo():
print("any", any((hit := i) % 5 == 3 and (hit % 2) == 0 for i in range(10)))
return hit
hit = 123
print(foo())
print(hit) # shouldn't be cha... | 220 |
12,278 | <filename>boost/libs/graph/example/property-map-traits-eg.cpp
//=======================================================================
// Copyright 2001 <NAME>, <NAME>, <NAME>,
//
// Distributed under the Boost Software License, Version 1.0. (See
// accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org... | 308 |
2,517 | // This file is part of CAF, the C++ Actor Framework. See the file LICENSE in
// the main distribution directory for license terms and copyright or visit
// https://github.com/actor-framework/actor-framework/blob/master/LICENSE.
#pragma once
#include "caf/detail/core_export.hpp"
namespace caf::detail {
/// Sets the... | 147 |
13,648 | <reponame>sebastien-riou/micropython
# test construction of bytes from bytearray
print(bytes(bytearray(4)))
| 41 |
928 | #!/usr/bin/env python3
#
# RSA String Encriptation Decriptation Sample by Parra Studios
# Python RSA encriptation decriptation sample.
#
# Copyright (C) 2016 - 2021 <NAME> <<EMAIL>>
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# ... | 427 |
325 | <reponame>maallen/mojito<filename>webapp/src/test/java/com/box/l10n/mojito/service/assetintegritychecker/integritychecker/PrintfLikeIgnorePercentageAfterBracketsIntegrityCheckerTest.java
package com.box.l10n.mojito.service.assetintegritychecker.integritychecker;
import static org.junit.Assert.assertEquals;
import stat... | 5,531 |
1,501 | <gh_stars>1000+
// This file is Copyright (c) 2020 <NAME> <<EMAIL>>
// SPDX-License-Identifier: BSD-Source-Code
#ifndef __COMMAND_H__
#define __COMMAND_H__
#define MAX_PARAM 8
#define HIST_DEPTH 10 /* Used in string list, complete.c */
#define SYSTEM_CMDS 0
#define BOOT_CMDS 1
#define MEM_CMDS 2
#define SPIFLAS... | 547 |
1,338 | /*
* Copyright 2008, <NAME>, <EMAIL>.
* Distributed under the terms of the MIT License.
*/
// included by vfs.cpp
//#include "io_requests.h"
// #pragma mark - public API
extern "C" fssh_status_t
fssh_do_fd_io(int fd, fssh_io_request* request)
{
fssh_panic("fssh_do_fd_io() not yet implemented");
return FSSH_B... | 251 |
4,036 | class SynchSetUnsynchGet {
private static int var;
public synchronized void setA(int a) {
this.var = a;
}
public synchronized int getA() {
return var; // ok get is synchronized
}
public synchronized void setB(int a) {
this.var = a;
}
public int getB() {
return var; // bad
}
public synchroni... | 377 |
711 | #!/usr/bin/env python
# Copyright 2016 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 requi... | 3,403 |
335 | <reponame>Safal08/Hacktoberfest-1
{
"word": "Blind",
"definitions": [
"A screen for a window, especially one on a roller or made of slats.",
"An awning over a shop window.",
"Something designed to conceal one's real intentions.",
"A camouflaged shelter used for observing or hunti... | 156 |
739 | <filename>app/src/main/java/io/github/droidkaigi/confsched/widget/OnItemClickListener.java<gh_stars>100-1000
package io.github.droidkaigi.confsched.widget;
import android.support.annotation.NonNull;
import android.view.View;
public interface OnItemClickListener<T> {
void onItemClick(@NonNull View view, T item);
... | 112 |
453 | #pragma once
#include <deque>
#include <pthread.h>
#include <functional> // for std::function, std::bind
// 使用C++03/C++0x 语言规范实现的线程池: 基于对象做法,每一个job都是一个function对象
namespace zl
{
class ThreadPool
{
public:
typedef std::function<void()> Task;
public:
ThreadPool(int ... | 600 |
3,269 | # Time: O(max(r, c) * w)
# Space: O(w)
import collections
class Solution(object):
def hasPath(self, maze, start, destination):
"""
:type maze: List[List[int]]
:type start: List[int]
:type destination: List[int]
:rtype: bool
"""
def neighbors(maze, node):
... | 583 |
2,691 | // AUTOGENERATED FILE - DO NOT MODIFY!
// This file generated by Djinni from client_interface.djinni
package com.dropbox.djinni.test;
import javax.annotation.CheckForNull;
import javax.annotation.Nonnull;
/** Client interface */
public interface ClientInterface {
/** Returns record of given string */
@Nonnul... | 226 |
1,330 | <gh_stars>1000+
/*
* 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
* ... | 371 |
32,544 | <gh_stars>1000+
package com.stackify.slf4j.guide.xlogger;
import org.slf4j.ext.XLogger;
import org.slf4j.ext.XLoggerFactory;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
@RestContr... | 347 |
1,813 | #!/usr/bin/env python3
# encoding: utf-8
""" Configuration parser for reading, writing and manipulating
.ini files. This implementation features some customisations
such as sorting of keys, and convenience functions that
wrap load() and save() operations.
"""
from configparser import SafeConfigParser... | 2,401 |
611 | //
// SecondViewController.h
// SampleApp
//
// Created by <NAME> on 1/22/20.
// Copyright © 2020 The Iconfactory. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface SecondViewController : UIViewController
@end
| 78 |
357 | <filename>vmidentity/openidconnect/protocol/src/main/java/com/vmware/identity/openidconnect/protocol/HttpRequest.java
/*
* Copyright (c) 2012-2015 VMware, 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 Licen... | 2,692 |
775 | package me.qixingchen.mdbilibili.network;
import android.text.TextUtils;
import java.io.BufferedInputStream;
import java.io.BufferedOutputStream;
import java.io.File;
import java.io.FileOutputStream;
import java.io.IOException;
import java.net.URL;
import java.net.URLConnection;
import me.qixingchen.mdbilibili.app.B... | 1,786 |
1,144 | def monkey_patch_gevent_websocket():
# HACK: remove once socketio starts gevent websocket properly
"""
THIS IS A HACK
Right now flask-socketio uses gevent websocket handler with
gevent.pywsgi server. Therefore Querybook cannot configure
logging for websocket handler. This monke... | 416 |
918 | <reponame>LaugustusJ/FFmpegInterop
//*****************************************************************************
//
// Copyright 2015 Microsoft 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 cop... | 489 |
506 | // https://cses.fi/problemset/task/1671
#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using ii = tuple<ll, ll>;
using vii = vector<ii>;
using qii = priority_queue<ii, vii, greater<ii>>;
int main() {
ios::sync_with_stdio(0);
cin.tie(0);
ll n, m, u, v, w, y;
cin >> n >> m;
vector<vii> g... | 448 |
686 | <reponame>stotko/stdgpu
/*
* Copyright 2020 <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 applic... | 1,101 |
1,338 | <reponame>Kirishikesan/haiku
/*
* Copyright 2020, Haiku, Inc. All Rights Reserved.
* Distributed under the terms of the MIT License.
*/
#ifndef _GAME_SOUND_DEFS_H
#define _GAME_SOUND_DEFS_H
#include <SupportDefs.h>
typedef int32 gs_id;
#define B_GS_CUR_API_VERSION B_BEOS_VERSION
#define B_GS_MIN_API_VERSION 0... | 583 |
439 | <reponame>JananiPalanisamy/java<filename>exercises/practice/yacht/src/main/java/YachtCategory.java
enum YachtCategory {
YACHT,
ONES,
TWOS,
THREES,
FOURS,
FIVES,
SIXES,
FULL_HOUSE,
FOUR_OF_A_KIND,
LITTLE_STRAIGHT,
BIG_STRAIGHT,
CHOICE
}
| 150 |
464 | #Chapter 1 - Basics of Relational Databases
#*******************************************************************************************#
#Engines and Connection Strings
# Import create_engine
from sqlalchemy import create_engine
# Create an engine that connects to the census.sqlite file: engine
engine = create_engi... | 623 |
506 | <filename>examples/core2_for_aws/FactoryTest/TimerAppImage.c
const unsigned char TimerAppImage[59165]={
0xff,0xd8,0xff,0xe1,0x17,0x23,0x45,0x78,0x69,0x66,0x00,0x00,0x4d,0x4d,0x00,0x2a,
0x00,0x00,0x00,0x08,0x00,0x07,0x01,0x12,0x00,0x03,0x00,0x00,0x00,0x01,0x00,0x01,
0x00,0x00,0x01,0x1a,0x00,0x05,0x00,0x00,0x00,0x01,0... | 254,015 |
1,056 | <reponame>timfel/netbeans<filename>platform/api.visual/src/org/netbeans/modules/visual/action/SwitchCardProvider.java
/*
* 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 cop... | 705 |
1,125 | <filename>src/Controller.py
from src.Gaits import GaitController
from src.StanceController import StanceController
from src.SwingLegController import SwingController
from src.Utilities import clipped_first_order_filter
from src.State import BehaviorState, State
import numpy as np
from transforms3d.euler import euler2m... | 3,153 |
306 | //
// Copyright(C) 1993-1996 Id Software, Inc.
// Copyright(C) 2005-2014 <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 2
// of the License, or (at your option) any ... | 420 |
1,144 | <gh_stars>1000+
package de.metas.i18n;
import java.util.Map;
import java.util.Set;
import javax.annotation.Nullable;
import com.google.common.collect.ImmutableMap;
import lombok.EqualsAndHashCode;
import lombok.Singular;
/*
* #%L
* de.metas.adempiere.adempiere.base
* %%
* Copyright (C) 2016 metas GmbH
* %%
*... | 617 |
815 | <filename>Utilities/Maintenance/unique_colormaps.py
#!/usr/bin/python3
# This script takes as input a json file assumed to have a list as its
# root element and parses it, removing duplicate elements in the list.
# The new list of unique elements is written out to a given output file.
# Used to prune duplicates from ... | 497 |
427 | <gh_stars>100-1000
//===-- SBFileSpecList.h --------------------------------------------*- C++
//-*-===//
//
// The LLVM Compiler Infrastructure
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===------------------------------... | 458 |
344 | <reponame>jsaynysa/Ksiazka
//===============================================================================
// @ Player.cpp
// ------------------------------------------------------------------------------
// Player
//
// Copyright (C) 2008-2015 by <NAME> and <NAME>.
// All rights reserved.
//
// Use of this source co... | 975 |
335 | <filename>F/Fluorocarbon_noun.json
{
"word": "Fluorocarbon",
"definitions": [
"A compound formed by replacing one or more of the hydrogen atoms in a hydrocarbon with fluorine atoms."
],
"parts-of-speech": "Noun"
} | 92 |
1,627 | <reponame>Floboy/PyWebIO<filename>test/output_diff.py
import os
import sys
def diff_file(file_a, file_b):
if open(file_a).read() != open(file_b).read():
cmd = 'diff %s %s' % (file_a, file_b)
print('#' * 4, cmd, '#' * 4)
os.system(cmd)
return True
return False
def diff_dir(dir... | 323 |
765 | <gh_stars>100-1000
/*****************************************************************************
Licensed to Accellera Systems Initiative Inc. (Accellera) under one or
more contributor license agreements. See the NOTICE file distributed
with this work for additional information regarding copyright ownership.
... | 689 |
23,901 | # coding=utf-8
# Copyright 2021 The Google Research 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 applicab... | 1,757 |
680 | <filename>ff4j-web/src/main/java/org/ff4j/web/controller/StaticResourceController.java
package org.ff4j.web.controller;
/*
* #%L
* ff4j-sample-web
* %%
* Copyright (C) 2013 - 2016 FF4J
* %%
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with th... | 2,225 |
777 | // 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 "ash/common/wm/overview/scoped_overview_animation_settings_factory.h"
#include "base/logging.h"
namespace ash {
// static
ScopedOverviewAnimat... | 240 |
305 | <filename>src/integration/java/org/mamute/integration/pages/SignupPage.java
package org.mamute.integration.pages;
import org.openqa.selenium.By;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.WebElement;
public class SignupPage extends PageObject{
private final WebDriver driver;
public SignupPag... | 290 |
879 | <gh_stars>100-1000
package org.zstack.ldap;
import org.zstack.header.configuration.PythonClassInventory;
import org.zstack.header.search.Inventory;
import java.sql.Timestamp;
import java.util.ArrayList;
import java.util.Collection;
import java.util.List;
@Inventory(mappingVOClass = LdapAccountRefVO.class)
@PythonCla... | 976 |
2,753 | /*
* This software is distributed under BSD 3-clause license (see LICENSE file).
*
* Authors: <NAME>, <NAME>, <NAME>, <NAME>
*/
#ifndef _EXPONENTIALKERNEL_H___
#define _EXPONENTIALKERNEL_H___
#include <shogun/lib/config.h>
#include <shogun/lib/common.h>
#include <shogun/kernel/DotKernel.h>
#include <shogun/featu... | 1,035 |
782 | /******************************************************************************\
Copyright (c) 2005-2019, Intel Corporation
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 c... | 13,762 |
303 | #include <stdio.h>
int print_hash_value = 1;
static void platform_main_begin(void)
{
}
static unsigned crc32_tab[256];
static unsigned crc32_context = 0xFFFFFFFFUL;
static void
crc32_gentab (void)
{
unsigned crc;
unsigned poly = 0xEDB88320UL;
int i, j;
for (i = 0; i < 256; i++) {
crc = i;
for (j = 8; j > 0; j--... | 9,454 |
718 | //
// TXSakuraTrash.h
// SakuraKit
//
// Created by tingxins on 28/06/2017.
// Copyright © 2017 tingxins. All rights reserved.
// 针对不支持的 Sakura 类型进行响应,如:UIAppearance 等类。
#import "TXSakura.h"
typedef void(^TXSakuraTrashBlock)(id);
@interface TXSakuraTrash : TXSakura
- (TXSakuraTrashBlock)barTintColor;
- (TXSakur... | 188 |
14,425 | /*
* 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,055 |
2,116 | # Copyright 2019 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 in writing,... | 5,312 |
839 | /**
* 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 m... | 1,292 |
314 | <gh_stars>100-1000
//
// Generated by class-dump 3.5 (64 bit).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2013 by <NAME>.
//
#import "CDStructures.h"
@interface IDESourceControlInfoConflictDetector : NSObject
{
}
+ (id)detectConflictForTreeItem:(id)arg1 localRevisionIdentifier:(id)arg2 remo... | 712 |
444 | <reponame>p-g-krish/duckhunt
######################################################
# DuckHunter #
# <NAME> #
# Tool to prevent getting attacked by a rubberducky! #
######################################################
from ctypes import *
i... | 4,115 |
505 | package de.rieckpil.blog;
import javax.ejb.MessageDriven;
import javax.jms.JMSException;
import javax.jms.Message;
import javax.jms.MessageListener;
import javax.jms.TextMessage;
import javax.json.Json;
import javax.json.bind.Jsonb;
import javax.json.bind.JsonbBuilder;
import javax.persistence.EntityManager;
import ja... | 410 |
4,054 | <filename>modules/lwjgl/opengl/src/generated/c/org_lwjgl_opengl_AMDDebugOutput.c<gh_stars>1000+
/*
* Copyright LWJGL. All rights reserved.
* License terms: https://www.lwjgl.org/license
* MACHINE GENERATED FILE, DO NOT EDIT
*/
#include "common_tools.h"
#include "opengl.h"
typedef void (APIENTRY *glDebugMessageEnab... | 1,065 |
937 | package com.oath.cyclops.types.factory;
/**
* A Data type that supports instantiation of instances of the same type
*
* @author johnmcclean
*
* @param <T> Data type of element(s) stored inside this Pure instance
*/
@FunctionalInterface
public interface Unit<T> {
public <T> Unit<T> unit(T unit);
}
| 99 |
310 | <filename>gear/software/h/huji-cam-ios.json
{
"name": "HUJI Cam (iOS)",
"description": "A retro-style camera app.",
"url": "https://itunes.apple.com/us/app/huji-cam/id781383622"
}
| 79 |
984 | <filename>generation/WinSDK/inc/intrinfix.h
/*
An update to VS 2019 broke intrin0.h for us:
#ifdef __clang__
// This looks like a circular include but it is not because clang overrides <intrin.h> with their specific version.
// See further discussion in LLVM-47099.
#include <intrin.h>
But our ... | 423 |
1,062 | //
// Generated by class-dump 3.5b1 (64 bit) (Debug version compiled Dec 3 2019 19:59:57).
//
// Copyright (C) 1997-2019 <NAME>.
//
#import <MailFW/NSObject-Protocol.h>
@class NSString;
@protocol MFActivityProgressUpdater <NSObject>
- (void)resetProgressItemsWithTotal:(unsigned long long)arg1 andStatusMessage:... | 150 |
435 | <filename>warehouse/ingest-core/src/main/java/datawave/ingest/mapreduce/job/ConstraintChecker.java
package datawave.ingest.mapreduce.job;
import com.google.common.collect.HashMultimap;
import com.google.common.collect.Multimap;
import org.apache.hadoop.conf.Configuration;
import org.apache.hadoop.io.Text;
import org.a... | 1,520 |
348 | {"nom":"Nieul-lès-Saintes","dpt":"Charente-Maritime","inscrits":972,"abs":190,"votants":782,"blancs":70,"nuls":25,"exp":687,"res":[{"panneau":"1","voix":377},{"panneau":"2","voix":310}]} | 79 |
2,103 | import pytest
from h import models
from h.presenters.document_searchindex import DocumentSearchIndexPresenter
class TestDocumentSearchIndexPresenter:
@pytest.mark.parametrize(
"document,expected",
[
(models.Document(title="Foo"), {"title": ["Foo"]}),
(models.Document(title... | 577 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.