prompt large_stringlengths 70 991k | completion large_stringlengths 0 1.02k |
|---|---|
<|file_name|>ko.js<|end_file_name|><|fim▁begin|>/*
Copyright (c) 2003-2019, CKSource - Frederico Knabben. All rights reserved.
For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
*/
CKEDITOR.plugins.setLang( 'iframe', 'ko', {
border: '프레임 테두리 표시',
<|fim▁hole|> scrolling: '스크롤바 사용',
... | noUrl: '아이프레임 주소(URL)를 입력해주세요.',
|
<|file_name|>index.js<|end_file_name|><|fim▁begin|>'use strict';
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.Portal = undefined;
var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enu... | |
<|file_name|>CategoryWebServiceRepository.java<|end_file_name|><|fim▁begin|>/*
* Copyright 2016 Netbrasoft
*
* 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/licens... | */
|
<|file_name|>home.component.ts<|end_file_name|><|fim▁begin|>import { Component } from '@angular/core';
@Component({
selector: 'formly-demo-home',
template: `
<div class="container markdown github">
<div [innerHtml]="contnent"></div>
</div>
`,
})
export class HomeComponent {
contnent = require('!!... | } |
<|file_name|>TestClass.java<|end_file_name|><|fim▁begin|>package ru.otus.l51.tests;
/**
* Created by tully.
*/
@SuppressWarnings("unused")
public class TestClass {
private int a = 0;
private String s = "";
public TestClass() {
}
public TestClass(Integer a) {
this.a = a;
}
publi... | } |
<|file_name|>pce_extrae_detalle_contrato.py<|end_file_name|><|fim▁begin|># coding=utf-8
# -*- coding: utf-8 -*-
from selenium import webdriver
from selenium.common.exceptions import NoSuchElementException, TimeoutException
from bs4 import BeautifulSoup
from datetime import datetime
from decimal import *
import sys
... | OrgContratacion |
<|file_name|>class.rs<|end_file_name|><|fim▁begin|>#![allow(
dead_code,
non_snake_case,
non_camel_case_types,
non_upper_case_globals
)]
#[repr(C)]
#[derive(Default)]
pub struct __IncompleteArrayField<T>(::std::marker::PhantomData<T>, [T; 0]);
impl<T> __IncompleteArrayField<T> {
#[inline]
pub co... | |
<|file_name|>BaseWidget.py<|end_file_name|><|fim▁begin|>class BaseWidget(object):
def __init__(self, path):
self._path = path
def expand(self):<|fim▁hole|> raise Exception("Not implemented in Base class.")<|fim▁end|> | "Implement this in sub classes" |
<|file_name|>__init__.py<|end_file_name|><|fim▁begin|>import dbus
from gwibber.microblog import util
class GwibberPublic:
"""
GwibberPublic is the public python class which provides convience methods
for using Gwibber.
"""
def __init__(self):
self.bus = dbus.SessionBus()
self.acco... | example:
import json, gwibber.lib
gw = gwibber.lib.GwibberPublic()
accounts = json.loads(gw.GetAccounts()) |
<|file_name|>__init__.py<|end_file_name|><|fim▁begin|>#!/usr/bin/env python
'''
ooiui.core.app.science
Defines the application for the Science UI
'''
import os
from flask import Flask
from flask.ext.cache import Cache
from flask_environments import Environments
app = Flask(__name__, static_url_path='', template_folde... | |
<|file_name|>main.py<|end_file_name|><|fim▁begin|>#! /usr/bin/python
import re
import os
import sys
import time
import pydas.communicator as apiMidas
import pydas.exceptions as pydasException
import uuid
import json
import shutil
from zipfile import ZipFile, ZIP_DEFLATED
from subprocess import Popen, PIPE, STDOUT
from ... | parameters['email'] = cfginternal['email']+'@example.org'
parameters['securitykey'] = cfg['securityKey']
parameters['apikey'] = cfginternal['apikey'] |
<|file_name|>utils.py<|end_file_name|><|fim▁begin|>import pygame, sys, random, math
from pygame.locals import *
import organisms
import globalVars
class Graphics:
def __init__(self):
self.screen = pygame.display.set_mode((1080, 820))
pygame.display.set_caption('Ecosystem Simulator')
class GUI:
... | def act(self):
self.sliderDrag() |
<|file_name|>mouse.rs<|end_file_name|><|fim▁begin|>use libc::{c_int, c_uint, c_void, uint8_t, uint32_t};
use surface::SDL_Surface;
use video::SDL_Window;
use sdl::SDL_bool;
use event::SDL_State;<|fim▁hole|>pub const SDL_SYSTEM_CURSOR_ARROW: SDL_SystemCursor = 0;
pub const SDL_SYSTEM_CURSOR_IBEAM: SDL_SystemCursor = 1;
... |
pub type SDL_Cursor = c_void;
pub type SDL_SystemCursor = c_uint; |
<|file_name|>go_button_gtk.cc<|end_file_name|><|fim▁begin|>// Copyright (c) 2009 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 "chrome/browser/gtk/go_button_gtk.h"
#include "app/l10n_util.h"
#include "base/lo... | |
<|file_name|>BaseCommand.java<|end_file_name|><|fim▁begin|>/*
* Copyright 1999-2017 YaoTrue.
*
* 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/licen... | private static final long serialVersionUID = 6878114738264710696L;
} |
<|file_name|>commands.py<|end_file_name|><|fim▁begin|>#
# commands.py - the GraalVM specific commands
#
# ----------------------------------------------------------------------------------------------------
#
# Copyright (c) 2007, 2012, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIG... | """ The VMs that can be built and run along with an optional description. Only VMs with a
description are listed in the dialogue for setting the default VM (see _get_vm()). """
_vmChoices = {
'graal' : 'All compilation is performed with Graal. This includes bootstrapping Graal itself unless -XX:-BootstrapGraal ... |
<|file_name|>index.js<|end_file_name|><|fim▁begin|>/**
* React Starter Kit (https://www.reactstarterkit.com/)
*
* Copyright © 2014-2016 Kriasoft, LLC. All rights reserved.
*
* This source code is licensed under the MIT license found in the
* LICENSE.txt file in the root directory of this source tree.
*/
/* esli... | }, |
<|file_name|>__init__.py<|end_file_name|><|fim▁begin|># coding: utf-8
# Copyright 2014 Globo.com Player authors. All rights reserved.
# Use of this source code is governed by a MIT License
# license that can be found in the LICENSE file.
import sys
PYTHON_MAJOR_VERSION = sys.version_info
import os
import posixpath
t... | |
<|file_name|>scheduler.go<|end_file_name|><|fim▁begin|>/*
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-... | |
<|file_name|>location.rs<|end_file_name|><|fim▁begin|>/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
use dom::bindings::codegen::Bindings::LocationBinding;
use d... | fn get_url(&self) -> Url {
self.window.get_url()
} |
<|file_name|>index.d.ts<|end_file_name|><|fim▁begin|>// Type definitions for secure-json-parse 1.0
// Project: https://github.com/fastify/secure-json-parse#readme
// Definitions by: Sjoerd Diepen <https://github.com/OSjoerdWie>
// Mike MacCana <https://github.com/mikemaccana>
// Definitions: https://git... | |
<|file_name|>artifact.spec.ts<|end_file_name|><|fim▁begin|>import { getName } from '../../../test/util';
import updateArtifacts from './artifacts';
describe(getName(), () => {
describe('updateArtifacts()', () => {
it('returns empty content', () => {
expect(
updateArtifacts({
packageFileNa... | }); |
<|file_name|>inputBits.js<|end_file_name|><|fim▁begin|>import { onChange, getBits } from '../state'
import { inputWidth, centerInputs } from './inputs'
const $bits = document.getElementById('bits')<|fim▁hole|>}
const setBitsValue = value => {
setBitsWidth(value.length)
$bits.value = value
}
$bits.addEventListene... |
const setBitsWidth = width => {
$bits.style.width = inputWidth(width)
centerInputs() |
<|file_name|>retry_test.go<|end_file_name|><|fim▁begin|>/*
Copyright 2019 The Kubernetes 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/licen... | errorCount := 0
return func() (err error) {
if errorCount < n {
errorCount++ |
<|file_name|>PartialFunction$class.js<|end_file_name|><|fim▁begin|>ScalaJS.impls.scala_PartialFunction$class__orElse__Lscala_PartialFunction__Lscala_PartialFunction__Lscala_PartialFunction = (function($$this, that) {
return new ScalaJS.c.scala_PartialFunction$OrElse().init___Lscala_PartialFunction__Lscala_PartialFunc... | if ((!ScalaJS.modules.scala_PartialFunction().scala$PartialFunction$$fallbackOccurred__O__Z(z))) {
action$1.apply__O__O(z);
var jsx$1 = true |
<|file_name|>branches-test.js<|end_file_name|><|fim▁begin|>'use strict';
var chai = require('chai');
var supertest = require('supertest');
var api = supertest('https://apis-bank-dev.apigee.net'); // supertest init;
chai.should();
describe('/branches', function() {
describe('get', function() {
it('should respond... | |
<|file_name|>client.go<|end_file_name|><|fim▁begin|>package plugins
import (
"bytes"
"encoding/json"
"io"
"io/ioutil"
"net/http"
"net/url"
"time"
"github.com/Sirupsen/logrus"
"github.com/docker/docker/pkg/plugins/transport"
"github.com/docker/go-connections/sockets"
"github.com/docker/go-connections/tlscon... | |
<|file_name|>components.tsx<|end_file_name|><|fim▁begin|>/*
Copyright 2019 Google 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 require... | const { users, moderatorIds, superModeratorIds } = props;
|
<|file_name|>workflow.py<|end_file_name|><|fim▁begin|># This file is part of the GOsa framework.
#
# http://gosa-project.org
#
# Copyright:
# (C) 2016 GONICUS GmbH, Germany, http://www.gonicus.de
#
# See the LICENSE file in the project's top-level directory for details.
import logging
import os<|fim▁hole|>from zipfil... | |
<|file_name|>fn-simple.rs<|end_file_name|><|fim▁begin|>// rustfmt-normalize_comments: true
fn simple(/*pre-comment on a function!?*/ i: i32/*yes, it's possible! */
,response: NoWay /* hose */) {
fn op(x: Typ, key : &[u8], upd : Box<Fn(Option<&memcache::Item>) -> (memcache::S... | |
<|file_name|>TextBlockGeneric.java<|end_file_name|><|fim▁begin|>/* ========================================================================
* PlantUML : a free UML diagram generator
* ========================================================================
*
* (C) Copyright 2009-2014, Arnaud Roques<|fim▁hole|> * Pr... | * |
<|file_name|>cards.rs<|end_file_name|><|fim▁begin|>//! This module represents a basic, rule-agnostic 32-cards system.
use rand::{thread_rng, IsaacRng, Rng, SeedableRng};
use std::num::Wrapping;
use std::str::FromStr;
use std::string::ToString;
/// One of the four Suits: Heart, Spade, Diamond, Club.
#[derive(PartialEq... | ///
/// If `id >= 32`
pub fn from_id(id: u32) -> Self { |
<|file_name|>utils.py<|end_file_name|><|fim▁begin|># -*- coding: utf-8 -*-
"""Utility functions.
"""
from collections import OrderedDict
from .bsd_checksum import bsd_checksum # make name available from this module
def n_(s, replacement='_'):
"""Make binary fields more readable.
"""
if isinstance(s, (st... | def pad(data, size, padchar=' '):
"""Pad the `data` to exactly length = `size`.
""" |
<|file_name|>lib.rs<|end_file_name|><|fim▁begin|>// Copyright 2020 Pants project contributors (see CONTRIBUTORS.md).
// Licensed under the Apache License, Version 2.0 (see LICENSE).
#![deny(warnings)]
// Enable all clippy lints except for many of the pedantic ones. It's a shame this needs to be copied and pasted acros... | // To trigger the latch, we drop the Sender. |
<|file_name|>ModelViewHolder.java<|end_file_name|><|fim▁begin|>package com.turlir.abakgists.allgists.view.listing;
<|fim▁hole|>
abstract class ModelViewHolder<T> extends RecyclerView.ViewHolder {
ModelViewHolder(View itemView) {
super(itemView);
}
abstract void bind(T model);
}<|fim▁end|> |
import androidx.recyclerview.widget.RecyclerView;
import android.view.View; |
<|file_name|>__init__.py<|end_file_name|><|fim▁begin|><|fim▁hole|>"""
"""
import argparse
parser = argparse.ArgumentParser(
prog="portainer",
fromfile_prefix_chars="@"
)
subparsers = parser.add_subparsers()
def subcommand(name, callback=None):
"""A decorator for main functions to add themselves as subc... | |
<|file_name|>config.py<|end_file_name|><|fim▁begin|>import errno
import os
import types
import typing as t
from werkzeug.utils import import_string
class ConfigAttribute:
"""Makes an attribute forward to the config"""
def __init__(self, name: str, get_converter: t.Optional[t.Callable] = None) -> None:
... |
.. code-block:: python
import toml |
<|file_name|>core.module.ts<|end_file_name|><|fim▁begin|>/* tslint:disable:member-ordering no-unused-variable */
import {
ModuleWithProviders, NgModule,
Optional, SkipSelf
} from '@angular/core';
import { CommonModule } from '@angular/common';
import { TitleComponent } from './title.component';
import { UserServi... | constructor( @Optional() @SkipSelf() parentModule: CoreModule) {
if (parentModule) { |
<|file_name|>input.js<|end_file_name|><|fim▁begin|>const dec = () => {};
class Foo {
@dec #x() {}<|fim▁hole|> bar() {
([...this.#x] = this.baz);
}
}<|fim▁end|> | |
<|file_name|>NamePointcutExample.java<|end_file_name|><|fim▁begin|>package ru.ifmo.springaop.namepc;
import org.springframework.aop.Advisor;
import org.springframework.aop.framework.ProxyFactory;
import org.springframework.aop.support.DefaultPointcutAdvisor;
import org.springframework.aop.support.NameMatchMethodP... | public static void main(String[] args) {
NameBean target = new NameBean();
// create advisor
|
<|file_name|>node_test.go<|end_file_name|><|fim▁begin|>package router2
import (
"net/http"
"testing"
)
type routeTest struct {
route string
get string
vars map[string]string
}
type handler struct {
Name string
}
func (h handler) ServeHTTP(w http.ResponseWriter, r *http.Request) {
}
func TestRoutes(t *tes... | leaf, wc := n.Match(rt.get)
if leaf == nil {
t.Errorf("got no leaf for %#v", rt.route)
} |
<|file_name|>mod.rs<|end_file_name|><|fim▁begin|>// Copyright 2018 TiKV Project Authors. Licensed under Apache-2.0.
use concurrency_manager::ConcurrencyManager;
use criterion::{black_box, BatchSize, Bencher, Criterion};
use kvproto::kvrpcpb::Context;
use test_util::KvGenerator;
use tikv::storage::kv::{Engine, WriteDat... | black_box(engine.write(&ctx, write_data)).unwrap();
} |
<|file_name|>test_phase2.py<|end_file_name|><|fim▁begin|>from util import app
import hashlib
import os
phase2_url = '/phase2-%s/' % os.environ.get('PHASE2_TOKEN')
admin_password = u'adminpass'
admin_hash = hashlib.sha1(admin_password.encode('utf-8')).hexdigest()
session_key = 'sessionkey'
admin_session_key = 'adminses... |
rv = app.post(url, data={'username': 'test', 'password': 'abcdef'})
assert 'dashboard' not in rv.headers.get('Location') |
<|file_name|>packetServerPluginMessage17.go<|end_file_name|><|fim▁begin|>package minecraft
import (
"io"
"github.com/LilyPad/GoLilyPad/packet"
)
type packetServerPluginMessageCodec17 struct {
}
func (this *packetServerPluginMessageCodec17) Decode(reader io.Reader) (decode packet.Packet, err error) {
packetServer... | }
decode = packetServerPluginMessage
return |
<|file_name|>invalid-crate-type.rs<|end_file_name|><|fim▁begin|>// Copyright 2014 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.... | //~| SUGGESTION dylib
#![crate_type="dlib"]
//~^ ERROR invalid `crate_type` value |
<|file_name|>bookmark_tags.py<|end_file_name|><|fim▁begin|>from django import template
from bookmarks.models import BookmarkInstance
from tagging.models import Tag
register = template.Library()
<|fim▁hole|> return {'bookmark_tags': Tag.objects.usage_for_queryset(queryset=BookmarkInstance.on_site.all(), counts=True,... | @register.inclusion_tag('bookmarks/tags.html')
def show_bookmarks_tags():
""" Show a box with tags for all articles that belong to current site.
""" |
<|file_name|>minters.py<|end_file_name|><|fim▁begin|># -*- coding: utf-8 -*-
#
# This file is part of Invenio.
# Copyright (C) 2016 CERN.
#
# Invenio 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 vers... |
def recid_minter(record_uuid, data):
"""Mint record identifiers.""" |
<|file_name|>expected.js<|end_file_name|><|fim▁begin|>var sheet = cssx();
(function () {
var _1 = {},
_2 = {},
_3 = {};
_2['color'] = '#000';
_3['color'] = '#F00';
_1['body'] = _2;
_1['body.error'] = _3;
return _1;
}.apply(this))
;
sheet.add((function () {
var _5 = {},
_6 = {},
_... | _5['p'] = _6; |
<|file_name|>Test_WebDirParser.py<|end_file_name|><|fim▁begin|>from webfs import WebDirParser
testDoc = """
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<html>
<head>
<title>Index of /ubuntu</title>
</head>
<body><|fim▁hole|><img src="/icons/compressed.gif" alt="[ ]"> <a href="ls-lR.gz">ls-lR.gz</a> ... | <h1>Index of /ubuntu</h1>
<pre><img src="/icons/blank.gif" alt="Icon "> <a href="?C=N;O=D">Name</a> <a href="?C=M;O=A">Last modified</a> <a href="?C=S;O=A">Size</a> <a href="?C=D;O=A">Description</a><hr><img src="/icons/back.gif" alt="[DIR]"> <a href="/">Parent Directory</a> ... |
<|file_name|>work.component.ts<|end_file_name|><|fim▁begin|>import { Component, OnInit } from '@angular/core';
import { FormDataService } from '../data/formData.service';
@Component ({
selector: 'mt-wizard-work'
,templateUrl: 'app/work/work.component.html'
})
export class WorkComponent implements O... | if (!form.valid)
return;
|
<|file_name|>CypherPlug.py<|end_file_name|><|fim▁begin|># Copyright (C) 2016 Deloitte Argentina.<|fim▁hole|>
class CypherPlug(PlugIn):
def __init__(self, sample=None):
PlugIn.__init__(self, sample)
def getPath(self):
return "particular_header.cypher"
def getName(self):
return "cy... | # This file is part of CodexGigas - https://github.com/codexgigassys/
# See the file 'LICENSE' for copying permission.
from PlugIns.PlugIn import PlugIn |
<|file_name|>dust_grid.py<|end_file_name|><|fim▁begin|>#!/usr/bin/env python
# encoding: utf-8
"""
Make a grid of synths for a set of attenuations.
2015-04-30 - Created by Jonathan Sick
"""
import argparse
import numpy as np
from starfisher.pipeline import PipelineBase
from androcmd.planes import BasicPhatPlanes
fr... | av_grid = np.arange(0., args.max_av, args.delta_av)
if args.av is not None: |
<|file_name|>drop-trait-generic.rs<|end_file_name|><|fim▁begin|>// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.... | // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed |
<|file_name|>doctor_disability_half.py<|end_file_name|><|fim▁begin|># -*- coding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
#
# This program is free software: you ... | |
<|file_name|>check_json.py<|end_file_name|><|fim▁begin|># Copyright 2017 NeuStar, 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/license... | def __init__(self, key, obj, ip_info=False):
self.key_error = 'Field is not applicable to this license.'
if ip_info is True: |
<|file_name|>LSTM_ISTapps.py<|end_file_name|><|fim▁begin|>#! /usr/bin/env python
""" time to run LSTM on this bad boy! """
from __future__ import absolute_import
from __future__ import print_function
import numpy as np
import cPickle as pkl
from keras.optimizers import SGD, RMSprop, Adagrad
from keras.utils import np... | |
<|file_name|>const_eval.rs<|end_file_name|><|fim▁begin|>// Copyright 2012-2014 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org... | ast::ExprTup(ref exprs) =>
ast::PatTup(exprs.iter().map(|expr| const_expr_to_pat(tcx, &**expr, span)).collect()),
|
<|file_name|>InteractiveCanvas.ts<|end_file_name|><|fim▁begin|>import { Cursor } from '../diagram/Cursor';
import { DiagramElement } from '../diagram/DiagramElement';
import { Handle } from '../diagram/Handle';
import { AbstractCanvas } from './AbstractCanvas';
const zoomLevels = [1 / 8, 1 / 7, 1 / 6, 1 / 5, 1 / 4, 1 ... | |
<|file_name|>Photo.java<|end_file_name|><|fim▁begin|>package com.ouser.module;
import java.util.HashMap;
import java.util.Map;
import com.ouser.util.StringUtil;
import android.os.Bundle;
/**
* 照片
* @author hanlixin
*
*/
public class Photo {
public enum Size {
Small(80, 0), /** 小列表,菜单 */
... | } |
<|file_name|>flux.go<|end_file_name|><|fim▁begin|>package flux
import (
"fmt"
"sync"
)
//Eachfunc defines the type of the Mappable.Each rule
type Eachfunc func(interface{}, interface{}, func())
//StringEachfunc defines the type of the Mappable.Each rule
type StringEachfunc func(interface{}, string, func())
// Map... | |
<|file_name|>mcapi.py<|end_file_name|><|fim▁begin|>print('Importing command definitions...')
from jycraft.plugin.interpreter import PyContext
from org.bukkit import Bukkit
from org.bukkit import Location
from org.bukkit import Material
from org.bukkit import Effect
from org.bukkit.command import Command
from org.bukk... | # >>> def functiontest(caller, params):
# ... yell(params[0]) |
<|file_name|>tests.rs<|end_file_name|><|fim▁begin|>// #![deny(warnings)]
#![deny(bad_style)]
#[macro_use]
extern crate rustless;
extern crate hyper;
extern crate rustc_serialize as serialize;
extern crate url;
extern crate valico;
extern crate jsonway;
#[macro_export]
macro_rules! sr {
($method:ident, $url:expr) ... | mod callbacks;
mod serializers; |
<|file_name|>login.js<|end_file_name|><|fim▁begin|>'use strict';
angular.module('athenaApp')
.config(function ($stateProvider) {
$stateProvider
.state('login', {
parent: 'account',
url: '/login',
data: {
roles: [],
... | resolve: {
}
}); |
<|file_name|>bitcoin_nl.ts<|end_file_name|><|fim▁begin|><?xml version="1.0" ?><!DOCTYPE TS><TS language="nl" version="2.1">
<context>
<name>AboutDialog</name>
<message>
<location filename="../forms/aboutdialog.ui" line="+14"/>
<source>About IadixCoin</source>
<translation>Over IadixCoin<... | <source>Copy the current signature to the system clipboard</source>
<translation>Kopieer de huidige handtekening naar het systeemklembord</translation>
</message>
<message> |
<|file_name|>data_converter.py<|end_file_name|><|fim▁begin|>######## Script to convert IRS spectra into pseudophotometric
######## datapoints for modeling the TDs
import asciitable
import numpy as np
import matplotlib.pyplot as plt
import pyfits
from scipy import interpolate
def remove_duplicates_func(seq):
""" T... | coeffs=mcclure_interpol1(irs_lmb)
almbs=coeffs*ak |
<|file_name|>autopaginator.py<|end_file_name|><|fim▁begin|>try:
set
except NameError:
from sets import Set as set
from django.core.paginator import Paginator, Page, InvalidPage
from django.db.models import F
from django.http import Http404
from coffin import template
from jinja2 import nodes
from jinja2.ext i... | if len(first.intersection(current)) == 0:
first_list = list(first)
first_list.sort()
second_list = list(current) |
<|file_name|>generate.go<|end_file_name|><|fim▁begin|>/*
Copyright IBM Corp. 2016 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
... | |
<|file_name|>isb_auth.py<|end_file_name|><|fim▁begin|>#
# Copyright 2015-2019, Institute for Systems Biology
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.<|fim▁hole|>#
# Unless required by applicable law or agreed to in writing, so... | # You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0 |
<|file_name|>Departamento.java<|end_file_name|><|fim▁begin|>package net.eldiosantos.model;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import java.io.Serializable;
@Entity
public class Departamento implements Serializa... | |
<|file_name|>register.js<|end_file_name|><|fim▁begin|>/**
* Created by panos on 4/5/16.
*/
import angular from 'angular/index'
let _app = new WeakMap()
export default class Register {
constructor (appName, deps) {
deps = deps || []
let module
try {
module = angular.module(appName)
} catch (er... | provider (name, constructorFn) {
_app.get(this).provider(name, constructorFn)
return this |
<|file_name|>index.js<|end_file_name|><|fim▁begin|>Template.index.onCreated( () => {
let template = Template.instance();
template.autorun(()=> {
template.subscribe('wishList');
});
});
Template.index.helpers({
contentReady() {<|fim▁hole|> wishItems() {
return Wish.find().fetch();
}
});<|fim▁end|> | return Template.instance().subscriptionsReady();
}, |
<|file_name|>errors.py<|end_file_name|><|fim▁begin|># uncompyle6 version 2.9.10
# Python bytecode 2.7 (62211)
# Decompiled from: Python 3.6.0b2 (default, Oct 11 2016, 05:27:10)
# [GCC 6.2.0 20161005]
# Embedded file name: errors.py
import mcl.status
ERR_SUCCESS = mcl.status.MCL_SUCCESS
ERR_INVALID_PARAM = mcl.status.f... | |
<|file_name|>radgrad-login-buttons.js<|end_file_name|><|fim▁begin|>import { Template } from 'meteor/templating';
import { Meteor } from 'meteor/meteor';
import { Roles } from 'meteor/alanning:roles';
import { FlowRouter } from 'meteor/kadira:flow-router';
import { $ } from 'meteor/jquery';
import { getStudentProfileMet... | |
<|file_name|>gray.cpp<|end_file_name|><|fim▁begin|>#include <iostream>
#include <iomanip>
#include <cstdint>
#include <typeinfo>
#include "color/color.hpp"
int main( int argc, char *argv[] )
{
using namespace color;
using namespace std;
cout << "gray<std::uint8_t > is: " << typeid( trait::componen... | } |
<|file_name|>fold_test.cpp<|end_file_name|><|fim▁begin|>// Copyright (c) 2016 Google 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... |
// Make sure the instruction folded as expected. |
<|file_name|>test_fields.py<|end_file_name|><|fim▁begin|># -*- coding: utf-8 -*-
from unittest import TestCase
import logging
log = logging.getLogger(__name__)
from formencode import validators, Invalid
from nose.tools import *
import formencode
from coregae.widget.field import *
class TestBasefield(TestCase):
... | |
<|file_name|>Carousel.js<|end_file_name|><|fim▁begin|>/**
* @author
*/
imports("Controls.Composite.Carousel");
using("System.Fx.Marquee");
<|fim▁hole|>
onChange: function (e) {
var ul = this.find('.x-carousel-header'), t;
if (t = ul.first(e.from))
t.removeClass('x-carousel-header-selected');
... |
var Carousel = Control.extend({
|
<|file_name|>editProfileController.js<|end_file_name|><|fim▁begin|>'use strict';
myApp.controller('editProfileController', ['$scope', '$state', 'loadingMaskService', 'CONSTANTS', '$uibModal', '$log', '$rootScope', '$http', function ($scope, $state, loadingMaskService, CONSTANTS, $uibModal, $log, $rootScope, $http) {
... | });
|
<|file_name|>urls.py<|end_file_name|><|fim▁begin|># -*- coding: utf-8 -*-
# Copyright (C) 2014 Universidade de Aveiro, DETI/IEETA, Bioinformatics Group - http://bioinformatics.ua.pt/
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as publis... | |
<|file_name|>0009_auto__add_journey__add_scheduledstop.py<|end_file_name|><|fim▁begin|># encoding: utf-8
import datetime
from south.db import db
from south.v2 import SchemaMigration
from django.db import models
class Migration(SchemaMigration):
def forwards(self, orm):
# Adding model 'Journey'
... | 'language_code': ('django.db.models.fields.CharField', [], {'max_length': '10'}),
'verbose_name': ('django.db.models.fields.TextField', [], {}),
'verbose_name_plural': ('django.db.models.fields.TextField', [], {}),
'verbose_name_singular': ('django.db.models.fields.TextFi... |
<|file_name|>context.js<|end_file_name|><|fim▁begin|>/*
* Copyright (C) 2010 Chandra Sekar S
*
* 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/LICE... | cb = useLayout;
useLayout = undefined; |
<|file_name|>basePickle.py<|end_file_name|><|fim▁begin|>__author__ = "shikun"
import pickle<|fim▁hole|>import os
from common import operateFile
from common.variable import Constants
def write_pickle(dict_data, path="data.pickle"):
read = read_pickle(path)
result = []
if len(read) > 0:
read.append(... | |
<|file_name|>lib.rs<|end_file_name|><|fim▁begin|>// Copyright 2016 Nathan Sizemore <nathanrsizemore@gmail.com>
//
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this file,
// You can obtain one at http://mozilla.org/MPL/2.0/.
//!... | #[inline]
pub fn remove(&mut self, offset: usize) -> T {
assert!(offset < self.len, "Offset out of bounds");
|
<|file_name|>IBookQuery.java<|end_file_name|><|fim▁begin|>// Copyright 2004 The Apache Software Foundation
//
// 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... |
public int borrowerQuery(Integer borrowerPK, SortOrdering sortOrdering) throws RemoteException;
} |
<|file_name|>node_io_unittest.py<|end_file_name|><|fim▁begin|>#!/usr/bin/env python3
# Copyright (c) 2012 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.
'''Unit tests for node_io.FileNode'''
from __future__ import print_... | </release>
</grit>'''
grd = grd_reader.Parse(StringIO(xml),
util.PathFromRoot('grit/testdata')) |
<|file_name|>gulpfile.js<|end_file_name|><|fim▁begin|>const elixir = require('laravel-elixir');
elixir((mix) => {
// Mix all Sass files into one
mix.sass('app.scss');
// Mix all vendor scripts together
mix.scripts(
[
'jquery/dist/jquery.min.js',
'bootstrap-sass/assets/j... |
/* |
<|file_name|>add_note.py<|end_file_name|><|fim▁begin|>#!/usr/bin/python2.7
# Copyright 2015 Google 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... | person.latest_status not in ['believed_alive', 'is_note_author']):
UserActionLog.put_new('mark_alive', note, person.primary_full_name) |
<|file_name|>bt_nl.ts<|end_file_name|><|fim▁begin|><?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE TS>
<TS version="2.1" language="nl">
<context>
<name>AboutDialog</name>
<message>
<source>About Brewtarget</source>
<translation>Over Brewtarget</translation>
</message>
</context>
<context>
... | <source>Required Fields</source>
<translation>Vereiste Velden</translation> |
<|file_name|>_version.py<|end_file_name|><|fim▁begin|><|fim▁hole|><|fim▁end|> | version_info = (1, 9, 'dev0')
__version__ = '.'.join(map(str, version_info)) |
<|file_name|>__init__.py<|end_file_name|><|fim▁begin|># -*-coding:Utf-8 -*
# Copyright (c) 2010-2017 LE GOFF Vincent
# 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 sourc... | distance = self.ajouter_choix("distance", "t", Flag, sort, |
<|file_name|>demo.py<|end_file_name|><|fim▁begin|>"""
Demo platform that has two fake alarm control panels.
For more details about this platform, please refer to the documentation
https://home-assistant.io/components/demo/
"""
import homeassistant.components.alarm_control_panel.manual as manual
<|fim▁hole|>def setup_p... | |
<|file_name|>thread.rs<|end_file_name|><|fim▁begin|>use std::thread;
use std::sync::mpsc;
pub struct CancelSender(mpsc::Sender<()>);
impl CancelSender {
pub fn cancel_thread(self) {
let CancelSender(sender) = self;
let _ = sender.send(());
}
}
pub struct CancelReceiver(mpsc::Receiver<()>);
imp... | let (sender, receiver) = mpsc::channel(); |
<|file_name|>GenericTest4.java<|end_file_name|><|fim▁begin|>import tests.util.*;
import java.util.Map;
// Test case for Issue 134:
// http://code.google.com/p/checker-framework/issues/detail?id=134
// Handling of generics from different enclosing classes.
// TODO: revisit with nested types in 1.3.
// @skip-test
clas... | void test() {
Foo foo = getOuter();
}
|
<|file_name|>Check.py<|end_file_name|><|fim▁begin|>#!/usr/bin/env python
#!-*- coding:utf-8 -*-
def read(filename):
dic=[]
with open(filename,'r') as fp:
while True:
lines = fp.readlines(10000)<|fim▁hole|> dic.append(line)
return dic
def Write(file,dic):
with open(fi... | if not lines :
break
for line in lines:
#line = line.strip('\n') |
<|file_name|>untar.cpp<|end_file_name|><|fim▁begin|>// Based on original code by Tim Kientzle, March 2009.
#include <util.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <boost/filesystem.hpp>
/* Parse an octal number, ignoring leading and trailing nonsense. */
static int
parseoct(const char ... | if (p[n] != '\0')
return (0);
return (1);
} |
<|file_name|>96_unique_binary_search_trees.py<|end_file_name|><|fim▁begin|># 96. Unique Binary Search Trees My Submissions QuestionEditorial Solution
# Total Accepted: 84526 Total Submissions: 224165 Difficulty: Medium
# Given n, how many structurally unique BST's (binary search trees) that store values 1...n?
#
# For... | """
if n == 0: return 0
|
<|file_name|>token.rs<|end_file_name|><|fim▁begin|>// Copyright 2012-2013 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/lice... | "unary", // 3 |
<|file_name|>CountBits.java<|end_file_name|><|fim▁begin|>package in.shabhushan.cp_trials.bits;
/**
* Leetcode solution for
* https://leetcode.com/problems/counting-bits/submissions/
*/
class CountBits {
public static int[] countBits(int num) {
int[] n = new int[num + 1];
<|fim▁hole|> for (int i = 1; i < nu... | |
<|file_name|>SaveOutlined.js<|end_file_name|><|fim▁begin|>"use strict";
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = void 0;
var _createSvgIcon = _interopRequireDefault(require("./utils/createS... | var _default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)("path", {
d: "M17 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V7l-4-4zm2 16H5V5h11.17L19 7.83V19zm-7-7c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3zM6 6h9v4H6z" |
<|file_name|>0001_initial.py<|end_file_name|><|fim▁begin|># -*- coding: utf-8 -*-
# Generated by Django 1.10.5 on 2017-02-16 14:10
from __future__ import unicode_literals
from django.db import migrations, models
import django.db.models.deletion<|fim▁hole|>
class Migration(migrations.Migration):
initial = True
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.