text stringlengths 27 775k |
|---|
require 'pry'
require 'open-uri'
require 'nokogiri'
require_relative "./gurps_cli/version.rb"
require_relative "./gurps_cli.rb"
require_relative "./scraper.rb"
require_relative "./books.rb"
require_relative "./topics_or_series.rb"
|
<?
$MESS["GD_SONET_USER_DESC_CONTACT_TITLE"] = "Контактная информация";
$MESS["GD_SONET_USER_DESC_CONTACT_UNSET"] = "Контактная информация не указана.";
$MESS["GD_SONET_USER_DESC_CONTACT_UNAVAIL"] = "Контактная информация недоступна.";
$MESS["GD_SONET_USER_DESC_PERSONAL_TITLE"] = "Личная информация";
$MESS["GD_SONET_US... |
package codec
// This file is for kafka code bytes type. Format method as alpha order.
func putRecord(bytes []byte, idx int, dstBytes []byte) int {
return putVCompactBytes(bytes, idx, dstBytes)
}
func putRecordBatch(bytes []byte, idx int, dstBytes []byte) int {
return putBytes(bytes, idx, dstBytes)
}
|
import React, { useState } from 'react';
import { useSelector, useDispatch } from 'react-redux';
import { AppState } from '@store';
import { selectMagicRecoveryCode } from '@store/onboarding/selectors';
import { SIGN_IN_CORRECT } from '@common/track';
import { doStoreSeed } from '@store/wallet/actions';
import { DEFAUL... |
import { Request, Response } from "express";
import { STATUS_CODES } from "../config/statusCodes";
import { receiveFile } from "../utils/receiveFile";
export const adminUpload = async (req: Request, res: Response) => {
const { token } = req.params;
if (!token || typeof token !== "string") {
return res.status(... |
import os
import requests
import telegram
from json import JSONDecodeError
from flask_sqlalchemy import SQLAlchemy
from telegram.error import Unauthorized
from app import create_app
from models import Track
TOKEN = os.environ.get('TELEGRAM_TOKEN')
PRICE_TRIGGER = 0.9 # 90% of the initial price
G2A_URL = 'https:/... |
package com.gitlab.kordlib.kordx.commands.kord.model.processor
import com.gitlab.kordlib.kordx.commands.model.command.Command
import info.debatty.java.stringsimilarity.Levenshtein
/**
* A suggester that suggests commands with a similar name from a map.
*/
interface CommandSuggester {
/**
* Suggests a comm... |
<?php
namespace Oro\Bundle\TestFrameworkBundle\DependencyInjection;
use Symfony\Component\Config\FileLocator;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\DependencyInjection\Extension\PrependExtensionInterface;
use Symfony\Component\DependencyInjection\Loader;
use Symfony\Compone... |
use core::fmt;
extern crate alloc;
use alloc::borrow::Cow;
use alloc::rc::Rc;
use anyhow::Result;
use http_auth_basic::Credentials;
use crate::{
http::server::middleware::Middleware, http::server::registry::*, http::server::*, http::*, io,
};
use super::role::*;
pub trait Authenticator {
fn authenticate(&... |
<!-- 搜索栏 -->
<div class="top-search">
<div class="inner">
<a class="logo" href="index.html"><img src="/static/images/icons/logo.jpg" alt="U袋网" class="cover"></a>
<div class="search-box">
<form class="input-group" action="/goods/search" method="post">
<input type="text" name="goods_name" placehol... |
package cn.quickits.rainbow.theme
import androidx.annotation.ArrayRes
import cn.quickits.rainbow.R
object ThemeValueResourceProvider {
@ArrayRes
var primaryColors: Int = R.array.mtrl_primary_palettes
@ArrayRes
var secondaryColors: Int = R.array.mtrl_secondary_palettes
@ArrayRes
val colorDes... |
// ignore_for_file: avoid_returning_null
// ignore_for_file: camel_case_types
// ignore_for_file: cascade_invocations
// ignore_for_file: comment_references
// ignore_for_file: file_names
// ignore_for_file: library_names
// ignore_for_file: lines_longer_than_80_chars
// ignore_for_file: non_constant_identifier_names
/... |
import { Injectable } from '@nestjs/common';
import { JwtService } from '@nestjs/jwt';
import { UserService } from './user.service';
import { IJwtPayload } from '../../infrastructure/dto';
@Injectable()
export class AuthService {
constructor(
private readonly usersService: UserService,
private rea... |
import List from '../';
import Contacts from '../../components/Contacts';
describe('List', () => {
let wrapper;
beforeEach(() => {
wrapper = shallow(<List contacts={[]} total={0} />);
});
it('should have contacts', () => {
expect(wrapper.find(Contacts).length).toBe(1);
});
});
|
package io.github.myolwin00.sunshine.app.utils
import io.github.myolwin00.sunshine.R
import io.github.myolwin00.sunshine.data.Weather
import java.text.SimpleDateFormat
/**
* Created by myolwin00 on 11/13/17.
*/
fun getWeatherDescStr(weathers: List<Weather>?) = weathers?.joinToString(" ") {
it.description
} ?: "... |
CREATE TABLE ateneo_db.failed_jobs (
`id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
`connection` text COLLATE utf8mb4_unicode_ci NOT NULL,
`queue` text COLLATE utf8mb4_unicode_ci NOT NULL,
`payload` longtext COLLATE utf8mb4_unicode_ci NOT NULL,
`exception` longtext COLLATE utf8mb4_unicode_ci NOT NULL,
`f... |
/*!
\file math_math.cpp
\brief Math example
\author Ivan Shynkarenka
\date 01.09.2016
\copyright MIT License
*/
#include "math/math.h"
#include <iostream>
int main(int argc, char** argv)
{
uint64_t a = 4984198405165151231;
uint64_t b = 6132198419878046132;
uint64_t c = 915649814513510... |
#!/usr/bin/env perl
# vim:ts=4:sw=4:expandtab
# x11vis - an X11 protocol visualizer
# © 2011 Michael Stapelberg and contributors (see ../LICENSE)
#
use strict;
use warnings;
use Data::Dumper;
use JSON::XS;
use v5.10;
# This hash was generated with:
# perl -n -e '/define XA_([^ ]*).*?([0-9]+)/ and print "$2 => \"$1\",... |
/*
* Copyright 2010-2018 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license
* that can be found in the LICENSE file.
*/
package org.jetbrains.kotlin.backend.konan.objcexport
import org.jetbrains.kotlin.backend.konan.Context
import org.jetbrains.kotlin.backend.konan.KonanConfigKeys
impor... |
function createElement(tag: any, className: string = '') {
const element = document.createElement(tag)
element.className = className
return element
}
function setAttributes($el: HTMLElement, attrs: any) {
for (let key in attrs) {
$el.setAttribute(key, attrs[key])
}
}
export { createElement, setAttribute... |
<?php
class HttpServerException extends Exception {
}
class HttpServerException404 extends Exception {
function __construct($message = 'Not Found') {
parent::__construct($message, 404);
}
}
class RestClientException extends Exception {
}
class RestClient {
const COOKIE_JAR = '/tmp/rest-client-cookie';
... |
---
title: 포함 파일
description: 포함 파일
services: vpn-gateway
author: cherylmc
ms.service: vpn-gateway
ms.topic: include
ms.date: 02/14/2020
ms.author: cherylmc
ms.custom: include file
ms.openlocfilehash: a04ac0e7c634a0d1d1909e691fabfcec3c52ebc5
ms.sourcegitcommit: 2ec4b3d0bad7dc0071400c2a2264399e4fe34897
ms.translationtyp... |
-- Schema : dwtest_monir@bidb
-- Creating Dimension table -- Dim_Cross_Provider
CREATE
TABLE DIM_CROSS_PROVIDER
(
CHILD_PROV_ID NUMBER ( 10, 0 ) NOT NULL ENABLE,
PARENT_PROV_ID NUMBER ( 10, 0 ) NOT NULL ENABLE
)
NOLOGGING;
-- PROCEDURE FOR INSERTING DATA INTO DIMENSION T... |
sudo pip3 install -r requirements.txt
sudo cp home_status.service /lib/systemd/system/
sudo chmod 644 /lib/systemd/system/home_status.service
sudo chmod +x home.py
sudo systemctl daemon-reload
sudo systemctl enable home_status.service
sudo systemctl start home_status.service
|
require 'rails_helper'
RSpec.describe Organization, type: :model do
it { should validate_presence_of :name }
it { should validate_presence_of :address }
it { should validate_uniqueness_of :name }
it { should have_many :users }
it { should have_many :questions }
it "should count encounters" do
organiza... |
# frozen_string_literal: true
module Admin::Resources
class ImportController < Admin::ApplicationController
def create
@entity = @project.entities.find_by!(model_klass_name: params[:resource_id])
Simpleadmin::Resources::ImportService.new(@project_connector, params[:resource_id], params[:file]).impor... |
package cofoga
import org.specs.runner.JUnit4
import org.specs.Specification
import Cofoga._
import Player._
import scala.math._
object ThreatGroupsSpec extends Specification with ThreatGroups with Logged {
val rows = ROWS
val cols = COLS
val connections = CXNS
protected val matrix = Array.ofDim[Player](rows,... |
package org.gp.ml
import com.typesafe.scalalogging.LazyLogging
import org.gp.ml.dataset.Batch
import org.gp.ml.layers.{CachingLayer, Layer}
import org.gp.ml.logging.TrackingCallback
import org.gp.ml.loss.LossFunction
import org.nd4j.linalg.api.ndarray.INDArray
import org.nd4j.linalg.factory.Nd4j
import scala.collecti... |
package jsonmodels
import "time"
// InfoResponse holds the response of the GET request.
type InfoResponse struct {
// version of GoShimmer
Version string `json:"version,omitempty"`
// Network Version of the autopeering
NetworkVersion uint32 `json:"networkVersion,omitempty"`
// whether the node is synchronized
S... |
#include <cstdio>
#include <sstream>
#include <vector>
#ifndef BaseInclusion_H
#define BaseInclusion_H
#endif //BaseInclusion_H |
control '5.8' do
title "Ensure 'repl_slave_priv' Is Not Set to 'Y' for Non-Slave Users (Scored)"
desc "The REPLICATION SLAVE privilege governs whether a given user
(in the context of the master server) can request updates that have been made on the master server."
impact 0.5
tag "severity": 'medium'
tag "c... |
import { Component } from '@angular/core';
import { UserServices } from '../../services/userservices/userservices';
import { map } from 'rxjs/operators';
import { of } from 'rxjs';
import { Geolocation } from '@ionic-native/geolocation/ngx';
import { LoadingController } from '@ionic/angular';
@Component({
selector:... |
import os
import csv
import errno
import json
import click
import requests
import time
import shutil
import threading
from functools import wraps
import git
from .constants import VALID_HC_TYPES
def rate_limited(max_per_second: int):
"""
Rate-limits the decorated function locally, for one process.
:param ... |
Create a new playground first:
$ cd $TESTDIR/..
$ pip install virtualenv >/dev/null 2>&1
$ virtualenv --python="$(which python)" FOO >/dev/null 2>&1
$ PATH=FOO/bin:$PATH
$ pip install --upgrade --force-reinstall 'pip' > /dev/null 2>&1
$ pip install argparse >/dev/null 2>&1
$ pip install packaging >/dev/n... |
(function ()
{
var Sprite = Laya.Sprite;
var Stage = Laya.Stage;
var Event = Laya.Event;
var Keyboard = Laya.Keyboard;
var TimeLine = Laya.TimeLine;
var WebGL = Laya.WebGL;
var target;
var timeLine = new TimeLine();
(function ()
{
// 不支持WebGL时自动切换至Canvas
Laya.init(550, 400, WebGL);
... |
1
2 52
3
4
5 52 148
6 60 110 174
7 111 120
8 41 95 121
9 175 177
10 117 172
11 83
12 172
13 43 90
14
15 43 44 103
16 38 80
17 66 116
18
19 134
20 112 134 147
21 48
22
23 59
24 159
25 126
26 117 153
27 4
28
29 28 165
30
31 7 26 124 168
32 55
33 19
34 114
35 25
36 56
37 162
38 17 150 161
39
40 85 141
41 95
42 34 43
43 7 ... |
trash ./build/*
flatc --js -o ./build/scripts ../../../schemas/common.fbs
flatc --js -o ./build/scripts ../../../schemas/bridge.fbs
flatc --js -o ./build/scripts ../../../schemas/wire.fbs
flatc --js -o ./build/scripts ../../../schemas/radarArc.fbs
flatc --js -o ./build/scripts ../../../schemas/hackEV.fbs
|
-- Copyright (c) YugaByte, Inc.
create table certificate_info (
uuid uuid not null,
customer_uuid uuid not null,
label varchar(255),
start_date timestamp not null,
expiry_date timestamp not null,
private_ke... |
import { Component, OnInit } from '@angular/core';
import { Store } from '@ngrx/store';
import { Cliente } from '../shared/cliente';
import { Observable } from 'rxjs';
import { ClienteState } from '../store/clientes.reducers';
import { selectObterClientes } from '../store/clientes.selector';
@Component({
selector: '... |
-- Thinking Functionall with Haskell
-- Chapter 05 Homework
-- Implement a new version of nub, which does not care about Order
-- the complexity of normal nub is O(n^2)
import Data.List
myNub :: (Ord a) => [a] -> [a]
myNub xs = nubOrder ys
where ys = sort xs
nubOrder [] = []
nubOrder [x] = [x]... |
import 'package:slikker_kit/slikker_kit.dart';
class SlikkerIcons {
SlikkerIcons._();
static const String _fontFamily = 'SlikkerIcons';
static const String _fontPackage = 'slikker_kit';
static const IconData plus =
IconData(0xe900, fontFamily: _fontFamily, fontPackage: _fontPackage);
static const Ico... |
import React from "react";
import ResponseItem from "../../components/2_molecules/ResponseItem";
export const ResponseList = props => {
const { responses, options, m, mode } = props;
return (
<>
<h3>Responses</h3>
{Object.keys(responses).map((e, i) => (
<ResponseItem
response={op... |
# Trigger Custom Resources
Argo Events supports Argo workflows, standard K8s objects, Sensor and Gateway as
K8s triggers. In order to add your custom resource as trigger to Argo Events, you will
need to register the scheme of resource in Argo Events.
If you feel Argo Events should support your custom resource out of b... |
package com.shengc.lucene.core
import _root_.org.apache.lucene.document.Field
object annotations {
final case class singletoken() extends scala.annotation.StaticAnnotation
final case class store(value: Field.Store = Field.Store.NO) extends scala.annotation.StaticAnnotation
final case class fieldname(value: Stri... |
import * as React from 'react'
import '@testing-library/jest-dom'
import { fireEvent } from '@testing-library/react'
import { renderWithProviders } from '@opentrons/components'
import { mockDeckCalData } from '../../../../../redux/calibration/__fixtures__'
import * as calibrationSelectors from '../../../../../redux/cal... |
// !DIAGNOSTICS: -UNUSED_PARAMETER,-UNUSED_VARIABLE,-PROVIDED_RUNTIME_TOO_LOW
// WITH_RUNTIME
// SKIP_TXT
import kotlinx.serialization.Serializable
import kotlinx.serialization.Transient
import java.io.Serializable as JavaSerializable
import kotlin.jvm.Transient as JavaTransient
@Serializable
class Data(val x: Int, @... |
# occupant-query project overview
## Motivation
The primary motivation for this project it two-fold.
Firstly, developing a simple open-source method of
delivering surveys and questionnaires to building
occupants offers researchers much more control than is
available via proprietary survey software/services. Secondly,... |
package andrew.studio.com.ultrabuddymvvm.ui.map
import andrew.studio.com.ultrabuddymvvm.R
import andrew.studio.com.ultrabuddymvvm.data.entity.Polygon
import andrew.studio.com.ultrabuddymvvm.databinding.UltraMapFragmentBinding
import andrew.studio.com.ultrabuddymvvm.internal.ScopedFragment
import andrew.studio.com.ultr... |
import { AppRouter } from './AppRouter'
import { IType } from './decorators'
import { Injector } from './Injector'
import asyncMiddleware from './AsyncMiddleware'
import { server } from './Server'
interface IStoreItem {
path: string
propertyName: string
method: string
}
class RouteStore {
route: {[key: string... |
package kr.ac.shms.main.commuity.vo;
import lombok.Data;
import lombok.Getter;
/**
* @author 최희수
* @since 2021. 5. 27.
* @version 1.0
* @see javax.servlet.http.HttpServlet
* <pre>
* [[개정이력(Modification Information)]]
* 수정일 수정자 수정내용
* -------- -------- ------------... |
package eu.bcvsolutions.idm.core.model.entity;
import java.util.UUID;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Index;
import javax.persistence.Table;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import javax.validation.con... |
--TEST--
testing fsockopen() with udp sockets
--FILE--
<?php
$hostname = 'udp://127.0.0.1';
$port = '31337';
echo "Open a server socket\n";
$server = stream_socket_server($hostname . ':' . $port, $errno, $errstr, STREAM_SERVER_BIND);
echo "\nCalling fsockopen():\n";
$client = fsockopen($hostname, $port);
var_dump($c... |
package sheet
import (
"github.com/watermint/toolbox/domain/google/api/goog_auth"
"github.com/watermint/toolbox/domain/google/api/goog_conn"
"github.com/watermint/toolbox/domain/google/sheets/model/bo_sheet"
"github.com/watermint/toolbox/domain/google/sheets/service/sv_sheet"
"github.com/watermint/toolbox/infra/c... |
USE Tax2
GO
DROP TABLE IF EXISTS Organization;
CREATE TABLE Organization
(
CustomerID INT PRIMARY KEY,
BusinessSegment VARCHAR(50) NOT NULL,
CONSTRAINT FK_Organization FOREIGN KEY (CustomerID)
REFERENCES Customer(CustomerID)
);
DROP PROCEDURE IF EXISTS organizationcreation;
GO
CREATE PROCEDURE o... |
# OpenFst - Release 1.3.6
## Python Wrapper
TODO:
## Windows installation
Use vcpkg to install dependencies under windows. In order to setup vcpkg for system
wide usage, execute the following command in the root directory of vcpkg (requires
admin on first use):
.\vcpkg integrate install
Use
"-DCMAKE_TOOLCHAI... |
result="$4"
case "$1" in
*c*) ./compile $2.c >/dev/null 2>&1 || result="$3" ;;
esac
case "$1" in
*l*) ./load $2 >/dev/null 2>&1 || result="$3" ;;
esac
case "$1" in
*r*) ./$2 >/dev/null 2>&1 || result="$3" ;;
esac
rm -f $2.o $2
exec cat "$result"
|
/*
Package toggl provides an API for interacting with the Toggl time tracking service.
See https://github.com/toggl/toggl_api_docs for more information on Toggl's REST API.
*/
package toggl
import (
"bytes"
"encoding/json"
"fmt"
"io"
"io/ioutil"
"log"
"net/http"
"net/url"
"os"
"time"
)
// Toggl service c... |
# 3MarcoConverter
### なにこれ
VRChatの某界隈で使用されている謎の単位を変換します。
### 使用方法
直観でわかると思う。
### ライセンス
MIT
なので、商用利用したいとか、こういう機能が欲しいとかは勝手にforkしてやればいいと思うよ。
### 更新履歴
2021.08.28 複数のDJ単位に対応
2020.08.01 初版
|
var fs = require('fs'),
fsp = require('fs-promise'),
marked = require('marked'),
path = require('path');
var isDoc = /\/*-{3}([\s\S]*?)-{3,}/;
var isMeta = /([A-z][\w-]*)[ \t]*:[ \t]*([\w\-\.\/][^\n]*)/g;
module.exports = require('postcss').plugin('mdcss', function (opts) {
// set options object
opts = ... |
<?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use App\Slide
class SlideController extends Controller
{
//
function __contruct(){
$slide = Slide::all();
view()->share('slide',$slide);
}
}
|
package adventofcode
import java.io.File
class PuzzleDay01 {
fun countDepthIncrease(input: File): Int = input.useLines { seq ->
seq.map { it.toInt() }
.windowed(2)
.map { it[1] - it[0] }
.count { it > 0 }
}
fun countDepthIncreaseGrouped(input: File): Int = inp... |
package views
import models.Game
object BoardRenderer {
private object Cell {
val Cool = 'C'
val Fresh = 'F'
val Ghost = 'G'
val OMG = 'O'
val Party = 'P'
val Skull = 'S'
}
private val LineSeparator = '\n'
def apply(game: Game)(prev: game.Board, next: game.Board): String = {
impo... |
create table panel (
user_id int key,
email varchar(50),
name varchar(50)
);
create table panelists (
user_id int,
email_active int
);
insert into panel values
(5, "hello@dummy.com", "john"),
(6, "man@city.com", "Ronn"),
(1, "fun@dummy.com", "... |
<?php
use Bnomei\SecurityHeaders;
@include_once __DIR__ . '/vendor/autoload.php';
Kirby::plugin('bnomei/securityheaders', [
'options' => [
'enabled' => null, // null => disable in panel and api
'seed' => function () {
return Url::stripPath(site()->url());
},
'headers' ... |
#pragma once
#include <boost/asio/io_service.hpp>
/**
* A simple structure containing a boolean that indicates
* when the socket has disconnected. This is used to prevent
* the OnDisconnect callback from being called multiple times
* when there are multiple async callbacks that fail on the socket.
*/
str... |
/*
* hifmc100_spi_issi.c
*
* The Flash Memory Controller v100 Device Driver for hisilicon
*
* Copyright (c) 2020 HiSilicon (Shanghai) Technologies CO., LIMITED.
*
* 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... |
<?php
namespace common\components\metricas;
use common\models\Vaga;
use Yii;
use common\models\MetricaPorVaga;
class MetricaVaga extends MetricaPorVaga
{
public static function insertMetrica($id)
{
$userAgent = Yii::$app->userAgent;
$vaga = Vaga::findOne($id);
$model = new MetricaPor... |
from bs4 import BeautifulSoup
import requests
import json
import pytz
from datetime import datetime
def getWind(id, ref):
link = "https://www.yr.no/en/forecast/daily-table/" + id + "/" + ref
web = requests.get(link)
soup = BeautifulSoup(web.content, 'html.parser')
act = soup.find_all('div',{"class":"n... |
/* Copyright 2017 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... |
package test.java.mockito3.first_try._4_mockito_javadoc;
public class Car {
public Object shiftGear() {
return null;
}
}
|
Ar-PHP
======
Fork of Ar-PHP (http://www.ar-php.org/project-php-arabic.html)
Other project than can be interesting
* https://github.com/tawfekov/ar-php
|
<?php
namespace app\modules\admin\controllers;
use app\models\Subscription;
use app\models\UserSubscription;
use DateTime;
use Yii;
use yii\base\Exception;
use yii\helpers\ArrayHelper;
use yii\helpers\VarDumper;
use yii\web\Controller;
use yii\web\Response;
use common\models\User;
use app\models\SignupForm;
use app\m... |
Status:
Tags:
Links: [[Anime MOC]]
___
# Anime Plan to Watch
## Romance
- I Wanna Eat Your Pancreas
- Plastic Memories
## Shounen
- Demon Slayer
- [[Fullmetal Alchemist Brotherhood]]
## Superpower
- Fire Force
## Mystery
- Erased
- Death Note
- Made in Abyss
- Monster
## Isekai
- Konosuba
___
References: |
/*
* Diff Match and Patch
*
* Copyright 2011 Google Inc.
* http://code.google.com/p/google-diff-match-patch/
*
* 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.... |
'use strict';
exports.config = chromeConfig();
function chromeConfig() {
return {
browserName: 'chrome',
chromeOptions: {
args: ['disable-infobars'],
prefs: {
'credentials_enable_service': false,
'profile': {
'password_manager_enabled': false
}
}
},
... |
<?php
/**
* Response
*
* @see \Illuminate\Contracts\Routing\ResponseFactory
*/
class Response extends Illuminate\Support\Facades\Response {}
|
namespace M5x.DEC.Jobs.Commands
{
public sealed record Tick<TJob, TIdentity> : SchedulerMessage<TJob, TIdentity>
where TJob : IJob
where TIdentity : IJobId
{
private Tick()
{
}
public static Tick<TJob, TIdentity> Instance { get; } = new();
}
} |
#[path="../src/lib.rs"]
mod png;
use png::*;
#[test]
fn open_image() {
let image = Image::open("tests/sample.png");
match image {
Ok(_) => {},
Err(e) => { panic!("Opening image failed: {:?}", e); }
}
}
#[test]
fn read_sig() -> Result<(), std::io::Error> {
let mut image = Image::open("tests/sample.png")?;
... |
DROP DATABASE IF EXISTS products_db;
CREATE DATABASE products_db;
-- CREATE TABLE images (
-- id int(10) UNSIGNED PRIMARY KEY NOT NULL AUTO_INCREMENT,
-- image_name varchar(255) DEFAULT NULL
-- ) |
#include <FontSize.h>
#include <Remath.h>
#include <ft2build.h>
#include FT_SIZES_H
namespace Relib {
//////////////////////////////////////////////////////////////////////////
CFontSizeOwner::CFontSizeOwner( CFontSizeOwner&& other ) :
sizeHandle( other.sizeHandle )
{
other.sizeHandle = nullptr;
}... |
using System.Threading.Tasks;
using Grpc.Core;
using Microsoft.Extensions.Logging;
using Volo.Abp.Threading;
namespace AElf.CrossChain.Grpc
{
public class CrossChainGrpcServer : ICrossChainServer
{
private Server _server;
private readonly CrossChainGrpcServerBase _serverBase;
public ILo... |
import socket
SOCK_READ_MAX = 1024
def socket_connect(host, addr):
sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
sock.connect((host, addr))
sock.setblocking(False)
return sock
def socket_read(sock: socket.socket, len_=SOCK_READ_MAX):
return sock.recv(len_).decode('utf-8')
def sock... |
/*
* Copyright (c) 2012 GCT Semiconductor, Inc. All rights reserved.
*
* This software is licensed under the terms of the GNU General Public
* License version 2, as published by the Free Software Foundation, and
* may be copied, distributed, and modified under those terms.
*
* This program is distributed in the ... |
Repository containing some python projects made using Pytorch.
```
Python 3.6
Pytorch 1.1.0
```
|
package com.infinum.sentinel.ui
import android.os.Bundle
import androidx.annotation.RestrictTo
import com.infinum.sentinel.ui.shared.BaseActivity
@RestrictTo(RestrictTo.Scope.LIBRARY)
internal class SentinelActivity : BaseActivity() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(sa... |
using System;
using SharpSweeper.Enum;
using SharpSweeper.Interfaces;
using SharpSweeper.Struct;
namespace SharpSweeper
{
public class Game : ISharpSweeperGame
{
private Bomb m_Bomb;
private Flag m_Flag;
private GameState _state;
private GameState m_State
{
... |
function render(cur_size, cur_data, cur_layout, cur_config)
if is_repl
render_unicode(cur_size, cur_data, cur_layout, cur_config)
else
render_html(cur_size, cur_data, cur_layout, cur_config)
end
end
# render_unicode in repl.jl
function render_html(cur_size, cur_data, cur_layout, cur_config)
cur_plot_d... |
<?php
use yii\helpers\Html;
use yii\helpers\Url;
use yii\grid\GridView;
use yiidhtmlx\Grid;
use yii\widgets\Block;
use kartik\widgets\SideNav;
/**
* @var yii\web\View $this
* @var yii\data\ActiveDataProvider $dataProvider
* @var app\modules\parties\models\PartySearch $searchModel
*/
$this->title = 'Purchase Or... |
import React from "react"
import { Link as GatsbyLink } from "gatsby"
import * as PropTypes from "prop-types"
import classNames from "classnames"
import "./link.css"
const isExternalURL = url => /^https?:\/\/|^\/\//i.test(url)
const Link = ({ children, className, title, url }) => {
if (isExternalURL(url)) {
re... |
public showresh
prcs segment
assume cs:prcs
showresh proc far
mov ah,09h
int 21h
ret
showresh endp
prcs ends
end
|
import { Encoding } from '../common';
/**
* Load dynamic container.
* NOTE: The "remoteEntry.js" script must be loaded before calling this method.
*
* Webpack Docs:
* https://webpack.js.org/concepts/module-federation/#dynamic-remote-containers
*
*/
export async function loadRemoteModule(args: { namespace:... |
using System;
using System.Windows;
using System.Windows.Controls;
namespace BetterExplorer {
/// <summary>
/// Interaction logic for StringSearchCriteriaDialog.xaml
/// </summary>
public partial class SizeSearchCriteriaDialog : Window {
public bool Confirm = false;
public SizeSearchCriteriaDial... |
from starlette.routing import Route
from star_resty.method import Method
from .request import resolve_parameters, resolve_request_body, resolve_request_body_params
from .response import resolve_responses
__all__ = ('setup_route_operations',)
def setup_route_operations(route: Route, endpoint: Method, version: int = ... |
/*************************************************************
* Project: NetCoreCMS *
* Web: http://dotnetcorecms.org *
* Author: OnnoRokom Software Ltd. *
* Website: www.onnorokomsoftware.com *
* ... |
import { CheckboxValueType } from 'antd/lib/checkbox/Group';
interface GetInsightsProperties {
url?: string;
categories?: CheckboxValueType[];
apiKey?: string;
strategy?: string;
}
const getInsights = ({
url,
categories = [],
apiKey,
strategy = 'mobile',
}: GetInsightsProperties): string => {
const ... |
import * as functions from 'firebase-functions';
import * as admin from 'firebase-admin';
import { PubSub } from '@google-cloud/pubsub';
import { GeoFirestore } from 'geofirestore';
import { to } from 'utils/async';
import {
REQUESTS_COLLECTION,
MAIL_COLLECTION,
USERS_PUBLIC_COLLECTION,
USERS_COLLECTION,
} from... |
// SYNTAX TEST "Packages/Rust Enhanced/RustEnhanced.sublime-syntax"
// dyn trait
fn f(x: dyn T, y: Box<dyn T + 'static>, z: &dyn T,
// ^^^ meta.function.parameters storage.type.trait
// ^^^ meta.function.parameters meta.generic storage.type.trait
// ^^^ ... |
// Copyright Epic Games, Inc. All Rights Reserved.
// This file is automatically generated. Changes to this file may be overwritten.
namespace Epic.OnlineServices.Auth
{
/// <summary>
/// All possible types of login methods, availability depends on permissions granted to the client.
/// <seealso cref="AuthInterface... |
class RemoveCustomerIdFromDeliverables < ActiveRecord::Migration
def change
remove_column :deliverables, :customer_id
end
end
|
# vim:set ts=2 sw=2 sts=2 autoindent:
require 'spec_helper'
describe Travis::Build::Script::Julia, :sexp do
let(:data) { payload_for(:push, :julia) }
let(:script) { described_class.new(data) }
subject { script.sexp }
it { store_example }
it_behaves_like 'a bash script'
it_behaves_like 'a... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.