text stringlengths 27 775k |
|---|
/*!
* Copyright (c) Microsoft. All rights reserved.
* Licensed under the MIT license. See LICENSE file in the project.
*/
import React, { memo } from 'react'
import { VerticalTextAlignment } from '@chart-parts/interfaces'
import {
Chart,
Group,
Circle,
Line,
LinearScale,
BandScale,
Dimension,
Text,
} from '@... |
<?php
// namespace App\Http\Controllers\Users;
use JWTAuth;
use Illuminate\Http\Request;
use App\Models\Role;
use App\Models\Administrator;
use App\Models\User;
use App\Http\Controllers\Controller;
class UsersController extends Controller
{
// Gets all the admin
public function index()
{
$users =... |
# -*- coding: utf-8 -*-
module Bio
module FastQC
class Converter
def initialize(fastqc_object, id: nil, runid: nil)
@id = id
@runid = runid
@fastqc_object = fastqc_object
end
def convert_to(format)
case format
when "json"
to_json
when "... |
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.SceneManagement;
public class MainMenu : MonoBehaviour
{
public void Play()
{
SceneManager.LoadScene("Forest");
}
public void Quit()
{
Application.Quit();
}
public void CheckS... |
#ifndef DATABASE_H
#define DATABASE_H
#include <QObject>
#include <QStandardItemModel>
#include <QSqlDatabase>
/**************************************
*作者: jianghj@up-tech.com
*日期: 2016-09-20
*描述: 数据库创建并打开
***************************************/
class Database : public QObject
{
Q_OBJECT
public:
... |
using Dfe.Spi.Registry.Domain;
namespace Dfe.Spi.Registry.Application.Matching
{
public class MatchResultItem
{
public RegisteredEntity RegisteredEntity { get; set; }
public string MatchReason { get; set; }
}
} |
#!/bin/bash
cd trunk
cmake -D CMAKE_INSTALL_PREFIX=$PREFIX \
-D CMAKE_SKIP_RPATH=ON \
-D HDF5_INCLUDE_DIR=$PREFIX/include \
-D HDF5_LIB_PATH=$PREFIX/lib \
.
make
make install
|
import request from 'utils/request';
export const getFlights = async params => {
let url = 'http://localhost:3001/flights';
const queryParams = [
`sourceCity=${params.sourceCity}`,
`destinationCity=${params.destinationCity}`,
`travelDate=${params.travelDate}`,
];
if (params.returnDate) queryParam... |
-- Translations from figure 7.25 & 7.26
--
-- Binary many-to-many relationship: E1 (x,N) - R - (x,N) E2
--
CREATE TABLE E1 (
-- primary key field(s)
AE11 VARCHAR(30),
-- mandatory fields
AE12 DECIMAL(10, 2) NOT NULL,
-- CONSTRAINTS:
PRIMARY KEY (AE11)
) COMMENT "Table for entity E1"... |
$(function () {
initData();
})
function initData() {
document.getElementById("loginName").innerText = userInfo.LoginName;
if (userInfo.UserInformation) {
document.getElementById("name").innerText = userInfo.UserInformation.Name;
document.getElementById("gender").innerText = userInfo.UserInf... |
package chezmoi
import (
"fmt"
"path"
"path/filepath"
"sort"
"github.com/bmatcuk/doublestar/v4"
vfs "github.com/twpayne/go-vfs/v4"
)
// A StringSet is a set of strings.
type StringSet map[string]struct{}
// An patternSet is a set of patterns.
type patternSet struct {
includePatterns StringSet
excludePattern... |
library inflection.verbs_ending_with_ed;
/// A collection of verbs ending with -ed.
final List<String> verbsEndingWithEd = const [
"bed",
"bleed",
"breed",
"embed",
"exceed",
"feed",
"heed",
"need",
"proceed",
"seed",
"shred"
"speed",
"succeed",
"ted",
"wed",
"weed"
];
|
# frozen_string_literal: true
begin
require 'puppet_x/lsp/security_policy'
rescue LoadError => _detail
require 'pathname' # JJM WORK_AROUND #14073
mod = Puppet::Module.find('local_security_policy', Puppet[:environment].to_s)
if mod
require File.join(mod.path, 'lib/puppet_x/lsp/security_policy')
else # re... |
import * as Stats from 'stats.js';
/**
* Phaser game implementation which adds performance stats to the game.
*/
export default class PhaserStatsGame extends Phaser.Game {
private stats: Stats;
constructor(config?: Phaser.Types.Core.GameConfig) {
super(config);
this.stats = new Stats();
this.stats... |
// License: MIT
// see LICENSE file in this folder, if this file is not preset refer to
// https://github.com/sprintworx-gmbh/examples/blob/master/LICENSE
// https://opensource.org/licenses/MIT
// https://mit-license.org/
//
// The following copyright applies
//
// Copyright © 2019 SprintWORX GmbH, authors: Matthias Fr... |
use student;
show tables;
select * from employee;
alter table employee drop column languages;
alter table employee drop column grade;
insert into employee values('Veda', 08, 'CSE');
insert into employee values('Shivi', 08, 'CSE');
insert into employee values('Sharan', 08, 'CSE');
insert into employee values('kamal', 08... |
package net.ccbluex.liquidbounce.features.module.modules.movement.speeds.spectre;
import net.minecraft.client.entity.EntityPlayerSP;
import net.minecraft.util.MathHelper;
import net.ccbluex.liquidbounce.utils.MovementUtils;
import net.ccbluex.liquidbounce.event.events.MoveEvent;
import net.ccbluex.liquidbounce.featur... |
"""
Merge CivicPlus and Legistar site metadata CSVs into
a single, standardized file that contains a single row
for every "meeting body" associated with a site.
Output file enables automated and/or manual oaddition of metadata
(e.g. state, county, agency type fields).
Requires:
* git
* SSH pubkey uploaded to ... |
package me.ibrahimsn.library
import android.content.SharedPreferences
import io.reactivex.Observable
import android.content.SharedPreferences.OnSharedPreferenceChangeListener
import io.reactivex.ObservableOnSubscribe
class LiveSharedPreferences constructor(private val preferences: SharedPreferences) {
private la... |
using System;
using System.Collections.Generic;
namespace Ilustarador
{
//Clase abstracta de "Figura"
abstract class Figura
{
//Variavles en protected de "Figura"
protected int px,py;
protected string color;
//Constructor de "Figura
public Figura(int x,int y, string c)... |
# -*- coding:utf-8 -*-
from __future__ import unicode_literals
import logging
import hashlib
#from django.contrib.auth.models import User
from django.conf import settings as django_settings
from django.template.defaultfilters import slugify
from django.db.models.signals import pre_save
from django.dispatch import rece... |
{-
(c) The GRASP/AQUA Project, Glasgow University, 1992-1998
\section[RnSource]{Main pass of renamer}
-}
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE CPP #-}
module RnTypes (
-- Type related stuff
rnHsType, rnLHsType, rnLHsTypes, rnContext,
rnHsKind, rnLHsKind,
rnHsSigType, rnHsW... |
---
title: The Financial Cost of Computer Hacking
author: PipisCrew
date: 2017-09-20
categories: [news]
toc: true
---
http://www.tgdaily.com/technology/the-financial-cost-of-computer-hacking
origin - http://www.pipiscrew.com/?p=10026 the-financial-cost-of-computer-hacking |
---
name: jameshupp
full_name: James Hupp
first_name: James
last_name: Hupp
role:
team:
city: New York
state: NY
redirect_from: "/team/jameshupp/"
published: false
---
|
import torch.nn as nn
import torch
embed_size = 300
hidden_size = 100
hidden_layers = 3
bidirectional = True
class TextLSTM(nn.Module):
def __init__(self, vocab_size, sequence_len, num_class, word_embeddings=None, fine_tune=True, dropout=0.5):
super(TextLSTM, self).__init__()
# Embedding Layer
... |
# ETL
## Description
Source data is publised as a datacube using Microsoft Analysis Services.
In order to extract data for visualizations the following process was made:
* Create a Tableau workbook on a windows machine
* Connect the datasource to the datacube on Microsoft analysis services.
* Create a Worksheet... |
/**
* Copyright 2016 SPeCS.
*
* 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 writi... |
#!/bin/bash
_ () { [[ "${!1}" = "" ]] && export $1="$2"; }
# ______________________________________________________________________________
#
# Compile raylib project
#
# - Linux ./build.sh
# - Windows (w64devkit) ./build.sh
# - Windows (cross compile) TARGET=Windows_NT ./build.sh
# - Web ... |
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE FlexibleContexts #-}
import Data.Text
import Control.Concurrent
import Control.Monad.IO.Class
import Control.Monad.Trans.Control
import Control.Monad.Logger (runLoggingT, runStdoutLoggingT)
import Network.... |
@switch($idQuyenRiengTu)
@case('CONGKHAI')
<i class="fas fa-globe-europe"></i> Công khai
@break;
@case('CHIBANBE')
<i class="fas fa-user-friends"></i> Bạn bè
@break;
@case('RIENGTU')
<i class="fas fa-lock"></i> Chỉ mình tôi
@break;
@endswitch |
package com.dburyak.exercise.game.bowling.service.format;
import com.dburyak.exercise.game.bowling.config.Config;
import com.dburyak.exercise.game.bowling.domain.Game;
import com.dburyak.exercise.game.bowling.service.io.GameHistoryInput;
/**
* Parser of game input.
* We may have multiple implementations to support ... |
package primer04StudentMinimalnoEnkapsulacija;
/**
* Dodatak:
* - enkapsulacija: polja su private
*/
public class Student {
private String ime; // ime studenta
private String prezime; // prezime studenta
private String indeks; // indeks studenta
// implicitno se inicijalizuju na null
... |
// * **************************************************************************
// * Copyright (c) McCreary, Veselka, Bragg & Allen, P.C.
// * This source code is subject to terms and conditions of the MIT License.
// * A copy of the license can be found in the License.txt file
// * at the root of this distributi... |
# node-influxdb-udp
[![NPM version][npm-image]][npm-url]
[![Build status][travis-image]][travis-url]
[![Test coverage][coveralls-image]][coveralls-url]
[![Dependency Status][david-image]][david-url]
[![License][license-image]][license-url]
[![Downloads][downloads-image]][downloads-url]
[![Gittip][gittip-image]][gitti... |
module Support
module MarkdownHelper
def markdown_to_html(markdown_string)
Markdown.new(markdown_string).to_html.html_safe
end
end
end
|
@using Daniel15.Shared.Configuration
@model Daniel15.Web.ViewModels.Blog.TagListingViewModel
@inject ISiteConfiguration Config
@{
Model.PageUrlGenerator = page => Url.BlogTag(Model.Tag, page);
Model.Heading = Config.BlogName;
Model.Title = $"Latest posts in {Model.Tag.Title} — {Config.BlogName}";
// Only show ... |
import FirebaseSerializer from 'emberfire/serializers/firebase';
export default FirebaseSerializer.extend({
attrs: {
children: { embedded: 'always' },
config: { embedded: 'always' }
}
});
|
# Advent of Code 2020
My [Advent of Code 2020](https://adventofcode.com/2020) solutions in Zig.
## Build and run
`zig build dayXX [target and mode options] -- [program args]`
## Build
`zig build install_dayXX [target and mode options]`
|
alter table users add firstname varchar(255) null,
add lastname varchar(255) null,
add login varchar(255) null;
update users set firstname='', lastname='', login='';
alter table users alter column firstname set not null,
alter column lastname set not null,
... |
/*
* IBM/3270 Driver -- Copyright (C) 2000 UTS Global LLC
*
* tubttybld.c -- Linemode tty driver screen-building functions
*
*
*
*
*
* Author: Richard Hitt
*/
#include "tubio.h"
extern int tty3270_io(tub_t *);
static void tty3270_set_status_area(tub_t *, char **);
static int tty3270_next_char(tub_t *);
... |
/**
* @fileoverview 多边形
* @author dxq613@gmail.com
*/
import ShapeBase from './base';
import inPolyline from '../util/in-stroke/polyline';
import isInPolygon from '../util/in-path/polygon';
class Polygon extends ShapeBase {
isInStrokeOrPath(x, y, isStroke, isFill, lineWidth) {
const { points } = this.attr();... |
<div class="separator"></div>
<a id="variables" href="#variables" class="field">`variables`</a> <span class="type">Map</span>
Copilot は Service 名などを常に環境変数としてタスクに対して渡します。本フィールドではそれら以外に追加で渡したい環境変数をキーバーリューのペアで指定します。
<div class="separator"></div>
<a id="env_file" href="#env_file" class="field">`env_file`</a> <span cla... |
import { createGlobalStyle } from "styled-components";
export const main = {
title: "main",
primary: "#e02041",
second: "#41414d",
paragraph: "#737380",
foreground: "#262626",
background: "#f0f0f5",
support: "#dcdce6",
accent: "#fff"
};
export const dark = {
title: "dark",
primary: "#e02041",
se... |
/*! @file nanodm/Helpers.h
* @brief nanodm Helper functions
*
* @author Douglas Davis, <ddavis@cern.ch>
* @author Carl Suster, <carl.suster@cern.ch>
*/
#ifndef nanodm_Helpers_h
#define nanodm_Helpers_h
// Local
#include "IPhysicsObject.h"
// ROOT
#include <Math/GenVector/VectorUtil.h>
// C++
#include <cmath... |
# step 1
stack_hub_url=https://github.com/kabanero-io/kabanero-stack-hub/releases/latest/download/kabanero-stack-hub-index.yaml
appsody list kabanero 2> /dev/null || appsody repo add kabanero ${stack_hub_url}
docker network create opentrace_network
docker run --name jaeger-collector \
--detach \
--rm \
-e COL... |
# keep-wifi-up
Application that workarounds issues that prevent NetworkManager from reconnecting to a
WiFi network
## How it works
At start the application checks which WiFi network is currently activated. If no network
is yet activated it awaits for one to be activated.
Then it enters a loop that checks each minut... |
import express from 'express';
import BeerDAO, { Beer } from '../models/BeerDAO.js';
import Container from '../schemas/Container.js';
export default class Beers {
constructor() {
this.router = express.Router();
this.DAO = new BeerDAO();
this.router.get('/', async (req, res) => {
try {
const result = aw... |
package SaleCD.action;
import SaleCD.model.ManageBasicModel;
import SaleCD.model.ManageGeneralModel;
import java.util.List;
public class ManageBasicAction extends IndexAction {
private List manageGeneralList;
private List manageBasicList;
private ManageBasicModel manageBasicModel;
private ManageGener... |
{% include [object-storage-duplicati](../../_includes/tutorials/archive/object-storage-duplicati.md) %}
|
# Oh-My-Posh default settings
$global:ThemeSettings = New-Object -TypeName PSObject -Property @{
CurrentThemeLocation = "$PSScriptRoot\Themes\Agnoster.psm1"
MyThemesLocation = '~\Documents\WindowsPowerShell\PoshThemes'
ErrorCount = 0
GitSymbols ... |
import { sortBy } from 'lodash';
import { Action, ActionReducer } from '@ngrx/store';
const initialState: any = {
activeDomain: null,
development: false,
bookingType: null,
userType: null,
domains: [],
settings: {},
contentDashboard: [],
systemDashboard: [],
blocked: false
};
export const app: Actio... |
import R from '@2snail/libs/R';
import test from '../../tests/R';
test(R); |
<?php
namespace RegistroEventos\CoreBundle\Repository;
use Doctrine\ORM\EntityRepository;
/**
* TipoEventoRepository
*
* This class was generated by the Doctrine ORM. Add your own custom
* repository methods below.
*/
class TipoEventoRepository extends EntityRepository
{
public function listarTiposEventosActiv... |
require 'rails_helper'
describe TaxonName, type: :model, group: [:nomenclature] do
let!(:root) { FactoryBot.create(:root_taxon_name) }
let!(:family) { Protonym.create!(name: 'Treeidae', parent: root, rank_class: Ranks.lookup(:iczn, :family)) }
let!(:genus) { Protonym.create!(name: 'Treeini', parent: root, rank_... |
(in-package :utility)
(defun string-prefix-p (prefix string)
(when (>= (length string) (length prefix))
(string= string prefix :start1 0 :end1 (length prefix))))
(defun string-suffix-p (suffix string)
(when (>= (length string) (length suffix))
(string= string suffix :start1 (- (length string) (length suff... |
package tinyscalautils.util
import tinyscalautils.assertions.require
/** The largest integer `m` such that `2^m <= n`. */
@throws[IllegalArgumentException]("if n is not positive")
def log2(n: Int): Int =
require(n > 0, "n must be positive")
var log = 0
var m = n
while m > 1 do
log += 1
m = ... |
$:.unshift "spec/"
require 'xiki/core/search'
require 'xiki/core/core_ext'
describe Search, "#case_options" do
it "should initialize" do
options = Search.case_options
options.class.should == Array
options[0][0].should == 'upper'
end
it "should convert case correctly" do
options = Search.case_opt... |
//! Scaling types for reducing errors between conversions between point (pt) and millimeter (mm)
macro_rules! impl_partialeq {
($t:ty) => (
impl PartialEq for $t {
// custom compare function because of floating point inaccuracy
fn eq(&self, other: &$t) -> bool {
if ... |
---
layout: page
title: About
---
<br>
Hi there !!!
Thanks for visiting !
|
<?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use Prettus\Validator\Contracts\ValidatorInterface;
use App\Services\DashboardService;
use Auth;
use Exception;
class DashboardController extends Controller
{
private $service;
public function __construct(DashboardService $service)
{
... |
#!/bin/bash
echo "sqlserver: localhost,MEU IP" >> /etc/hosts.allow
echo "mssql: localhost,MEU IP" >> /etc/hosts.allow
echo "mysql: localhost,MEU IP" >> /etc/hosts.allow
echo "mysqld: localhost,MEU IP" >> /etc/hosts.allow
|
#!/bin/bash
# Start pulseaudio
pulseaudio --log-level=1 --log-target=stderr --disallow-exit=true --exit-idle-time=180 --realtime & > /dev/null 2>&1
# Test ble
btmgmt find -l
# Test bluetooth
hciconfig hci0 up
hciconfig
hcitool dev
# Test GPIO input buttons
evtest /dev/input/event1
while :
do
echo "Just chilling.... |
# -*- encoding : utf-8 -*-
module GitStats
module GitData
class Activity
def initialize(commits)
add_commits(commits)
end
def by_date
@by_date ||= default_hash
end
def by_hour
@by_hour ||= default_hash
end
def by_hour_array
by_hour.to_k... |
compact workflow:
1) place RCM zip files in pwd
2) python3 rcm_group_by_beam.py
3) python3 unzip_all.py
4) python3 snap_TC_box.py
5) python3 rcm_rearrange.py
6) rcm_merge
|
package za.co.entelect.services.security;
import za.co.entelect.domain.entities.user.AppUser;
/**
* This service is intended to be used from Spring EL expression in pages or security annotations, to check if the user
* has sufficient access to edit profile pages or make api calls.
*
* For example:
* <p t... |
using Avalonia.Diagnostics.ViewModels;
using AvalonStudio.Extensibility.Templating;
using System.Collections.Generic;
using System.Linq;
namespace AvalonStudio.Controls.Standard.SolutionExplorer
{
class TemplateViewModel : ViewModelBase
{
private ITemplate _inner;
public TemplateViewModel(ITe... |
import { HttpStatus } from "./http-status";
import { AnyObject } from "../data";
/**
* HttpRequestHandler class - handles requests and provides standard error handling
*/
export class HttpRequestHandler {
constructor(protected request, protected response) {}
get params(): AnyObject {
return this.request.par... |
# encoding: UTF-8
class User
include Mongoid::Document
include Mongoid::Timestamps
include Chartable
include Workable
CURRENCIES = {
'USD' => '$',
'EUR' => '€',
'JPY' => '¥',
'GBP' => '£',
'CHF' => 'Fr.'
}.freeze
DEFAULT_COLOR = '#000000'.freeze
DEFAULT_CURRENCY = 'USD'.fre... |
require 'test/unit'
require 'feed_tools'
class GenerationTest < Test::Unit::TestCase
def setup
FeedTools.reset_configurations
FeedTools.configurations[:tidy_enabled] = false
FeedTools.configurations[:feed_cache] = "FeedTools::DatabaseFeedCache"
end
def test_generate_rss_20_from_scratch
# Create ... |
# sensors
Currently contains code for blob statistics.
# How to use
Create a folder called `build` then inside of sensors/build run `cmake ..` then `make`.
Then you can run either executable which is in the same folder
__NOTE:_ bar_code_reader is tested only on those 2 images in sensors/build
# Resources used
## blob... |
module Epiklesis.Module where
-- loading of a lua module of multiple
-- types, different modules require
-- different required fields or functions
-- some module types load in extra functions
import Prelude()
import UPrelude
import qualified Foreign.Lua as Lua
import Anamnesis.Data
import Artos.Var
import Artos.Queue
i... |
use std::slice::{Chunks, ChunksMut};
use std::ops::{Deref, DerefMut, Index, IndexMut};
use std::marker::PhantomData;
use num_traits::Zero;
use color_model::{Rgb, Rgba, Gray, GrayA};
use traits::{Color as Pixel, ImageView};
/// Iterator over references to pixels.
pub struct Pixels<'a, P: Pixel + 'a>
where P::Subpi... |
# Changelog
## 0.3.0 (2021-05-07)
### Features
- Support and CI tests for Python 3.9
### Bug fixes
- Update notifications-python-client; this indirectly fixes a backwards incompatible change in PyJWT
- Fix the Factory Boy dependency specification
## 0.2.0 (2021-04-29)
### Features
- Support and CI tests for Dja... |
open class c1 {
object c1_c1 {
fun c1_c1_sf1() {}
}
}
|
struct CrayonWrapper
c::Crayon
v::Vector{Union{CrayonWrapper,String}}
end
function (c::Crayon)(args::Union{CrayonWrapper,AbstractString}...)
typefix(cw::CrayonWrapper) = cw
typefix(str) = String(str)
CrayonWrapper(c, typefix.(collect(args)))
end
Base.show(io::IO, cw::CrayonWrapper) = _show(io, cw... |
using LiteGui.Graphics;
namespace LiteGui.Control
{
internal static class LGuiToolTips
{
internal static bool Begin(LGuiVec2 Size)
{
if (!LGuiMisc.PreviousControlIsHovered())
{
return false;
}
var Pos = LGuiContext.IO... |
import Vue from "vue";
import Vuetify from "vuetify";
import "vuetify/dist/vuetify.min.css";
Vue.use(Vuetify);
export default new Vuetify({
theme: {
dark:
typeof localStorage.getItem("prefs") === "string"
? JSON.parse(localStorage.getItem("prefs")).dark
: false,
themes: {
light: ... |
echo '打包sp.jicu.vip'
BRANCH_NAME=master
echo '[start] git clone...'
read -p "请输入分支名称(回车代表master):" branch
if [ "$branch" != "" ]
then
BRANCH_NAME=$branch
fi
echo "即将clone的分支名称为:$BRANCH_NAME"
git clone -b $BRANCH_NAME git@gitlab.com:superxzl/way-admin-shop.git
echo '[end] git clone...'
echo '[start] cd way-admin-sh... |
module MetricFu
class RCovLine
attr_accessor :content, :was_run
def initialize(content, was_run)
@content = content
@was_run = was_run
end
def to_h
{ content: @content, was_run: @was_run }
end
def covered?
@was_run == 1
end
def missed?
@was_run == 0
... |
<?php
namespace RIPS\ConnectorBundle\Entities\Application\Scan\Issue;
class ContextEntity
{
/**
* @var int
*/
protected $id;
/**
* @var Context\PartEntity[]
*/
protected $parts;
/**
* Set id
*
* @param int $id
* @return $this
*/
public function s... |
using System;
using ApplicationCore.Data.Entities;
using ApplicationCore.Data.Interfaces;
namespace ApplicationCore.Services.LogServices
{
public class LogErrorDatabaseService : ILogErrorService
{
private readonly ILogErrorRepository _logErrorRepository;
public LogErrorDatabaseService(ILogErr... |
using System;
using System.Collections.Generic;
using System.Reflection;
namespace Atata
{
public class ObjectMapper : IObjectMapper
{
private readonly IObjectConverter _objectConverter;
public ObjectMapper(IObjectConverter objectConverter)
{
_objectConverter = objectConve... |
import { Easing } from "react-native";
import { TransitionConfig } from "./types";
export function blurFadeIn(duration: number = 300): TransitionConfig {
return {
transitionSpec: {
animation: "timing",
config: {
duration,
easing: Easing.out(Easing.poly(4)),
useNativeDriver: t... |
#!/bin/bash
#
if [ "$1" = "" ]; then
exit 1
fi
name=$1
program="./$name"
pid=`ps -aef | grep "$program$" | grep -v grep | awk '{print $2}'`
echo "pid = $pid"
if [ "$pid" = "" ]; then
echo no such program
exit 1
else
echo OK
exit 0
fi
|
/**
******************************************************************************
* @file utilities_conf.h
* @author MCD Application Team
* @brief Configuration file to utilities
******************************************************************************
* @attention
*
* <h2><center>© ... |
module Judgeable
extend ActiveSupport::Concern
include Competeable
included do
belongs_to :judge, touch: true
validates :judge, presence: true
validates :judge_id, uniqueness: { scope: [:competitor_id] }, on: :create
delegate :user, to: :judge
end
end
|
/**
*
*/
package com.shtick.utils.data.json;
import com.shtick.util.tokenizers.json.NumberToken;
/**
* @author sean.cox
*
*/
public interface JSONNumberDecoder {
/**
*
* @param token
* @return An object representing the decoded number.
*/
public Object decodeNumber(NumberToken token);
}
|
import {getData} from '../app/api'
describe('#getUser() using Promises', () => {
it('should load user data', () => {
return getData()
.then(({data}) => {
expect(data).toBeDefined()
expect(data.base).toBe('USD')
})
})
}) |
using Content.Localization.Tests;
using System;
using System.Collections.Generic;
using System.IO;
using System.Threading.Tasks;
using Xunit;
namespace Content.Localization.AspNetFramework.Tests
{
public sealed class LocalizerConfigurationTests : IDisposable
{
private readonly string _location;
... |
-- ----------------------------------------------------------------------
-- Discuz!ML (Multilingual) (C) 2008-2014 Codersclub.org
--
-- All the Countries SUBDIVISIONS
-- (Regions, States, Provinces, etc.)
--
-- by Valery Votintsev, http://codersclub.org/discuzx/?1
-- ---------------------------------------------------... |
-- +migrate Up
create table customer_types
(
id int
constraint customer_types_pk
primary key,
name text
);
alter table customer_types alter column name set not null;
alter table customer_types
add created_at timestamptz not null;
alter table customer_types
add updated_at timestamptz not null;
create unique ind... |
export const getModule = async (src) => {
const module = { exports: {} };
eval(src);
return module.exports;
};
|
---
'@backstage/catalog-model': patch
---
Ignore relations when comparing entities. This stops the refresh loop from rewriting entities over and over.
|
function insert(num) {
document.form.display.value = document.form.display.value + num
}
function backspace() {
var display = document.form.display.value;
document.form.display.value = display.substring(0, display.length - 1);
}
function clean() {
document.form.display.value = "";
}
function equal() {
... |
---
category: 容器
columns: single
title: ScrollBar
subtitle: 滚动框
---
## 基本用法
超出范围时显示滚动条
```js
import React from 'react'
import Paragraphs from '../../commons/Paragraphs'
import {ScrollBar} from 'fantasy-ui'
export default class ScrollBarNormal extends React.Component {
render () {
return (
<div style={{h... |
using System.Threading.Tasks;
namespace ServiceGovernance.Repository.Agent
{
/// <summary>
/// Interface to abstract service repository client functions
/// </summary>
public interface IServiceRepositoryClient
{
/// <summary>
/// Publishes the API to the service repository
... |
### 请求地址
/commodity/recommendList
### 请求参数
* cid 商品id
### 返回结果
```json
{
"list": [{
"commNo": "商品编号",
"brandName": "品牌1",
"recommendCid": 2, #商品id
"price": 900.22,
"resourcePath": "https://oss-admin.oss-cn-beijing.aliyuncs.com/img/94a4d496b90c430496c571d36774b2fa.... |
/**
*
* Copyright (c) 2006-2018, Speedment, 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 requ... |
#!/bin/bash
ssh -t root@192.168.1.123 date --set $(date "+%Y-%m-%dT%H:%M:%S")
|
#!/bin/bash
# $1 is the binary to run, all other parameteres after are optional and passed to the binary
KCOV=${KCOV_BINARY:?}
if ! ${KCOV:?} --version &> /dev/null ; then echo "${KCOV} executable not found" ; exit 1 ; fi
if ! [ -d ${KCOV_TARGET_DIRECTORY:?} ] ; then echo "target dir does not exist: ${KCOV_TARGET_DI... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.