text
stringlengths
27
775k
<?php namespace AlexBrin\Scoreboard; use pocketmine\plugin\PluginBase; /** * Class Scoreboard * @package AlexBrin\Scoreboard * * @author Alexander Gorenkov <g.a.androidjc2@ya.ru> */ class Main extends PluginBase { /** * {@inheritDoc} */ public function onEnable() { $this->getLogge...
using System; using System.IO; using System.Drawing; using System.Drawing.Drawing2D; using System.Drawing.Imaging; using System.Linq; using System.Windows.Forms; namespace BatchResize.Util { public class ImageProcessor { public string OriginalDirectory; public string[] OriginalFiles; p...
require 'simple-random' module TrailGuide module Algorithms class Bandit < Algorithm def choose!(**opts) variants.find { |var| var == best_guess } end private def guesses @guesses ||= variants.map do |variant| [variant.name, arm_guess(variant.participants, vari...
--- title: Values Aggregation short_title: Values --- A _multi-bucket_ value source based aggregation where buckets are dynamically built - one per unique **value**. ## Structuring The following snippet captures the structure of range aggregations: ```json "<aggregation_name>": { "_values": { "_field": "<fie...
let timeLineFrame = '<a class="timeline__frame" href="#"></a>'; export default timeLineFrame;
import { BASE_URL, endpoints } from '../../config' import { setSession, discardSession, startRefreshInterval, stopRefreshInterval } from './session' // constants export const LOGIN_REQUEST = 'LOGIN_REQUEST' export const LOGIN_SUCCESS = 'LOGIN_SUCCESS' export const LOGIN_FAILURE = 'LOGIN_FAILURE' export const ...
DROP DATABASE IF EXISTS security_database; CREATE DATABASE security_database; USE security_database; CREATE TABLE users ( username VARCHAR(50) NOT NULL, passwd VARCHAR(50) NOT NULL, role ENUM('user','admin') ); INSERT INTO users VALUES("testuser", "test", "user"); INSERT INTO users VALUES("testadmin", "test", "...
# frozen_string_literal: true require 'spec_helper' describe Ptimelog::Day do include_context 'mocked timelog' let(:date) { mocked_timelog_date } subject { described_class.new(date) } it 'has entries' do is_expected.to respond_to :entries end it 'returns entries as Hash of Arrays, grouped by date' d...
package tlschannel.helpers import java.nio.ByteBuffer import java.nio.channels.ByteChannel class ChunkingByteChannel(val wrapped: ByteChannel, chunkSize: Int) extends ByteChannel { def close() = wrapped.close() def isOpen() = wrapped.isOpen() def read(in: ByteBuffer): Int = { if (!in.hasRemaining) ...
/* * Copyright (C) 2020 HERE Europe B.V. * * 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...
<?php namespace ORFS\Bundle\StoreBundle\Entity; use Doctrine\ORM\Mapping as ORM; /** * Schedules * * @ORM\Table() * @ORM\Entity(repositoryClass="ORFS\Bundle\StoreBundle\Entity\SchedulesRepository") */ class Schedules { /** * @var integer * * @ORM\Column(name="id", type="integer") * @ORM\...
object i0 { def i1(i2: String, i3: Boolean = None): Int = i4 val i4 = new i2(1) val i5 = i3(1, ) i1() i4() val i6: i2 = i6() yield i7(i3, ) => () def i8[i2](i3: i2 => String): i1 = (i5.i5) => i1 + i3 == i3) }
<?php namespace Overtrue\LaravelLang; use Illuminate\Translation\FileLoader as LaravelTranslationFileLoader; use Illuminate\Filesystem\Filesystem; class FileLoader extends LaravelTranslationFileLoader { /** * 37 languages dir. * * @var string */ protected $multiLangPath; /** * ...
package com.sethchhim.kuboo_client.ui.reader.pdf import android.annotation.SuppressLint import com.sethchhim.kuboo_client.data.model.GlidePdf @SuppressLint("Registered") open class ReaderPdfActivityImpl2_Overlay : ReaderPdfActivityImpl1_Search() { override fun setOverlayImage() { when (isDownload()) { ...
import 'dart:math'; import 'package:mobx/mobx.dart'; part 'dice_game_model.g.dart'; class DiceGameViewModel = _DiceGameViewModelBase with _$DiceGameViewModel; abstract class _DiceGameViewModelBase with Store { @observable int left = Random().nextInt(6) + 1; @observable int right = Random().nextInt(6) + 1; ...
DROP TABLE IF EXISTS locations; CREATE TABLE locations ( location_id INT NOT NULL AUTO_INCREMENT, code VARCHAR(256) NOT NULL, description VARCHAR(2048), order_val INT, CONSTRAINT locations_pk PRIMARY KEY (location_id) );
start() -> bnot (bnot (((1 bor 2) band 2) bxor 1)).
# Copyright (C) 2021 Ilya Baran. This program is distributed under the terms of the MIT license. using ModelBlocks using Test using OrdinaryDiffEq using Plots println("Bindings Test starting"); variables = Variables([ Variable("X", 1, (0, 100), "", ""), Variable("Y", 1, (0, 100), "", ""), ]); parameters = ...
package com.zj.weather.room.entity import androidx.room.ColumnInfo import androidx.room.Entity import androidx.room.PrimaryKey /** * 版权:Zhujiang 个人版权 * * @author zhujiang * 创建日期:2021/10/31 * 描述:PlayAndroid * */ @Entity(tableName = "city_info") data class CityInfo( @PrimaryKey(autoGenerate = true) var uid: ...
using Better_Kids.Model; using System; using System.Collections.Generic; using System.IO; using System.Linq; using System.Runtime.InteropServices.WindowsRuntime; using System.Threading.Tasks; using Windows.Foundation; using Windows.Foundation.Collections; using Windows.Media.SpeechSynthesis; using Windows.UI.Popups; u...
import torch import torch.nn as nn import torch.nn.functional as F from torchviz import make_dot # define the network class class MyNetwork(nn.Module): def __init__(self): # call constructor from superclass super().__init__() # define network layers self.fc1 = nn.Li...
<Note> ####### Sandy documentatie ontbreekt De documentatie voor dit patroon moet nog geschreven worden. </Note>
# Credit to https://github.com/rails/rails/issues/28292#issuecomment-324061067 module JsonAttrParser extend ActiveSupport::Concern included do columns.select { |column| column.type == :json }.map(&:name).each do |attr| define_method("#{attr}=") do |value| self[attr] = value.is_a?(String) ? JSON.p...
CREATE EXTENSION IF NOT EXISTS "uuid-ossp"; CREATE TABLE users ( id uuid DEFAULT uuid_generate_v4() PRIMARY KEY, display_name TEXT NOT NULL, google_id TEXT NULL UNIQUE, twitter_screen_name TEXT NULL UNIQUE );
import router from './router' import store from './store' import NProgress from 'nprogress' // progress bar import '@/components/NProgress/nprogress.less' // progress bar custom style NProgress.configure({ showSpinner: false }) // NProgress Configuration router.beforeEach((to, from, next) => { NProgress.start() ...
package log_test import ( "testing" "github.com/stretchr/testify/assert" "github.com/sutd-statnlp/service-ladrawex/log" ) func TestOpenFile(test *testing.T) { assert.True(test, log.OpenFile()) } func TestCloseFile(test *testing.T) { log.OpenFile() assert.True(test, log.CloseFile()) }
package com.tony.tmall.service; import com.baomidou.mybatisplus.extension.service.IService; import com.tony.tmall.entity.OmsOrderReturnApplyEntity; import com.tony.tmall.model.dto.OmsUpdateStatusParam; import com.tony.tmall.model.vo.OmsOrderReturnApplyResult; import com.tony.tmall.util.PageUtils; import java.util.Lis...
#!/usr/bin/env ruby require_relative '../lib/pdfium' require 'pathname' path = Pathname.new(__FILE__).dirname.join('pdfs','example_images.pdf') # guide = PDFium::Document.new( path ) # `rm /tmp/images/*` # page = guide.page_at(0) # path.write page.as_image(height: 120).data('jpg') data = path.read puts data.leng...
class ChangeScholarshipApplication < ActiveRecord::Migration[5.0] def change rename_column :scholarship_applications, :terms_accpeted, :terms_accepted end end
import { computed, inject, provide, Ref, ref, UnwrapRef, watch } from "vue-demi" import { AsyncCacheProvider, ResponsePromiseCallback } from "./types" import { useAsync } from "./useAsync" const defaultKey = "asyncCache" export function useAsyncCacheProvider<T>(key?: string) { const asyncValue = useAsync<T,Error>(u...
package servers import ( "github.com/gorilla/websocket" log "github.com/sirupsen/logrus" "go-websocket/api" "go-websocket/define/retcode" "go-websocket/tools/util" "net/http" ) const ( // 最大的消息大小 maxMessageSize = 8192 ) type Controller struct { } type renderData struct { ClientId string `json:"clientId"` }...
require_relative 'spec_helper' RSpec.describe "PreQueryParenthesisParser" do before do @parser = MLibrarySearchParser::PreQueryParenthesisParser.new end it "validates balanced parentheses" do expect { @parser.parse("(test)") }.not_to raise_error end it "validates sequential balanced parentheses" do...
package bg.bugstracker.service; import java.util.List; import javax.ejb.Local; import bg.bugstracker.entity.CommentModel; import bg.bugstracker.entity.IssueModel; @Local public interface IssueServiceLocal { List<IssueModel> ListAllIssues(); IssueModel save(IssueModel entity); IssueModel upd...
/* * Program POMEGRANATE for cell lineage tree simulation and sampling * by Victoria Popic (viq@stanford.edu) 2014-2015 * * MIT License * * Copyright (c) 2014 Victoria Popic. * Permission is hereby granted, free of charge, to any person obtaining * a copy of this software and associated documentation fi...
exports.randomString = function (length) { var chars = '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHUJKLMNOPQRSTUVWXYZ'; var result = ''; for (var i = length; i > 0; --i) result += chars[Math.round(Math.random() * (chars.length - 1))]; return result; } exports.responses = function(res, status, obj) { var re...
class ConsoleLogger def initialize(manager) @manager = manager end def log return manager.next_logger unless should_process? end private def should_process? false end attr_reader :manager end
require 'analytics/rails/extensions/action_view/base' require 'analytics/rails/railtie' require 'analytics/rails/version' module Analytics module Rails end end
// Copyright (c) 2020, the Flutter PetClinicApp project authors. Please see // the AUTHORS file for details. All rights reserved. Use of this source code // is governed by a BSD-style license that can be found in the LICENSE file. import 'dart:developer'; import 'package:flutter/material.dart'; import 'owner_detail...
# 关于本项目 方便做笔记的一款 web 应用程序, 本地部署. ## 技术说明 - SPA(single page application) - Functional Reactive Flux - [re-frame](https://github.com/Day8/re-frame) (和 Redux 一样的设计理念, 看项目的时间线, 明显是 redux 要晚于 re-frame) - 当下的前端架构发展趋势会越来越多地受到 clojure/clojurescript 社区的影响 - 后端将会有多种平台实现: clojure, ruby, nodejs ## 那些让我获益良多的书 - Think In Java -...
## v1.2 ### v1.2.0 [![14.08.2021](https://img.shields.io/date/1628932414)](https://github.com/d8corp/watch-state/tree/v1.2.0) - updated readme - added linting ## v1.1 ### v1.1.3 [![13.08.2021](https://img.shields.io/date/1628806723)](https://github.com/d8corp/watch-state/tree/v1.1.3) - updated readme - added chang...
from django.urls import path, include from . import views urlpatterns = [ path('', views.index, name="index"), path('type_filter/<int:id>', views.filter_product), path('<int:id>', views.get_product_by_id), path('filtered/', views.advanced_filter, name="filtered") ]
// Code generated by cmd/cgo -godefs; DO NOT EDIT. // cgo -godefs defs_solaris.go // package lif -- go2cs converted at 2020 October 09 06:07:39 UTC // import "vendor/golang.org/x/net/lif" ==> using lif = go.vendor.golang.org.x.net.lif_package // Original source: C:\Go\src\vendor\golang.org\x\net\lif\zsys_solaris_amd64...
require "test_helper" class ApiNamespaceTest < ActiveSupport::TestCase setup do @subdomain = subdomains(:public) @subdomain.update(api_plugin_events_enabled: true) @subdomain_events_api = api_namespaces(:plugin_subdomain_events) @subdomain_events_api.api_resources.destroy_all @message_thread = me...
#!/usr/bin/env bash # This script provides a convenient interface to interact with the LUCE servers # This script is placed in the default shell path so it can be directly executed as a command # No arguments if [ $ == ] then printf "Please use luce with one of the following arguments: luce start -> Starts the Jup...
package test1 import akka.actor.typed._ import akka.actor.typed.scaladsl.{AbstractBehavior, ActorContext, Behaviors} class StartStopActor1(context: ActorContext[String]) extends AbstractBehavior[String](context) { println("第一个 actor 启动") context.spawn(StartStopActor2(), "second") override def onMessage(msg: Str...
require "active_support/concern" module RecordsRip module Model extend ActiveSupport::Concern class_methods do def rest_in_place(&block) model_class = self serializer = if block_given? block else lambda do |record| Ha...
import { Injectable } from '@angular/core'; import { Router } from '@angular/router'; import { StoragePersistenceService } from '../storage/storage-persistence.service'; import { OpenIdConfiguration } from './../config/openid-configuration'; const STORAGE_KEY = 'redirect'; @Injectable() export class AutoLoginService ...
// Copyright 2020 Energinet DataHub A/S // // Licensed under the Apache License, Version 2.0 (the "License2"); // 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...
// SPDX-License-Identifier: GPL-2.0-or-later /* * Copyright 2020, Heinrich Schuchardt <xypron.glpk@gmx.de> * * Driver for Amlogic hardware random number generator */ #include <common.h> #include <clk.h> #include <dm.h> #include <rng.h> #include <asm/io.h> struct meson_rng_plat { fdt_addr_t base; struct clk clk;...
# encoding: utf-8 require 'spec_helper' require 'json' module Machete module CF describe AppFile do let(:app) { double(:app, name: 'app_name') } subject(:app_file) { AppFile.new(app) } describe '#has_file?' do context 'with a standard CF deployment' do before do ...
from fastapi import APIRouter, Depends, status from sqlalchemy.ext.asyncio import AsyncSession from app.categories import views from app.categories.schemas import CreateCategory, GetCategory, GetSuperCategory, UpdateCategory from app.permission import is_superuser from app.schemas import Message from db import get_db ...
// +build dev package wtserver import ( "fmt" "net" "time" "github.com/decred/dcrd/dcrec/secp256k1" ) type MockPeer struct { remotePub *secp256k1.PublicKey remoteAddr net.Addr IncomingMsgs chan []byte OutgoingMsgs chan []byte writeDeadline <-chan time.Time readDeadline <-chan time.Time Quit chan str...
package com.syrous.ycceyearbook.ui.papers_and_resources import android.os.Bundle import android.view.LayoutInflater import android.view.View import android.view.ViewGroup import androidx.lifecycle.coroutineScope import androidx.recyclerview.widget.LinearLayoutManager import com.syrous.ycceyearbook.databinding.Fragment...
class Skroutz::Resources::ProductsCollection < Skroutz::CollectionProxy def search_by_shop_uid(shop_uid) response = client.get("#{base_path}/search", shop_uid: shop_uid) return parse(response) unless block_given? yield response end end
import WebformBuilder from './WebformBuilder'; import Webform from './Webform'; import BuilderUtils from './utils/builder'; import _ from 'lodash'; import { fastCloneDeep } from './utils/utils'; export default class WizardBuilder extends WebformBuilder { constructor() { let element, options; if (arg...
<?php defined('C5_EXECUTE') or die('Access Denied.'); use Concrete\Core\Page\Page; use Concrete\Core\File\File; $c = Page::getCurrentPage(); $pageTitle = $c->getCollectionName(); if ($overridePageName) { $pageTitle = $customPageHeaderTitle; } $backgroundImage = null; if ($fID) { $background = File::getByID($fI...
package com.wut.resources.storage.row; import com.wut.model.Data; import com.wut.model.scalar.IdData; import com.wut.model.scalar.StringData; import com.wut.pipeline.WutRequest; import com.wut.provider.row.RowProvider; import com.wut.provider.table.TableResourceProvider; import com.wut.resources.common.MissingParamete...
using System; using System.Collections.Generic; using System.Drawing; using System.IO; using System.Linq; using System.Text; using System.Threading.Tasks; namespace IconScanner { class IconScanner { static void Main(string[] args) { string inputfolder = "."; if (args.L...
<?php namespace PackageB\Mapper; class Query implements QueryInterface { use EntityManagerAwareTrait; public function getPackageById($id) { return $this->getEntityManager()->findOne($id); } public function getPackagesBy(array $criteria) { return $this->getEntityManager()->fin...
# coding: utf-8 require_relative 'benchmark_helper' require 'astrolabe/node' require 'parser/current' describe 'performance' do Benchmarking.warm_up = true Benchmarking.trial_count = 3 Benchmarking.loop_count_in_trial = 1000 def generate_source(max, current_nest_level = 1) <<-END class SomeClass#{cur...
--- id: C9030B04-0B31-4664-9D74-5A183FD248F1 title: "Mono.Android.GoogleMaps.dll" --- # Mono.Android.GoogleMaps.dll
{-@ LIQUID "--no-termination" @-} module M32 (main) where {-@ main :: Bool -> Int -> { b:Bool | b } @-} main :: Bool -> Int -> Bool main b ij = case while 100 (b, ij, ij, 0) of (b', i, j, n) -> i == j {-@ while :: Int -> (Bool, Int, Int, Int) -> (Bool, Int, Int, Int) @-} while :: Int -> (Bool, Int, I...
import { recruitement } from '../../../providers'; /** * @api {get} /recruitement? Get recruitement data. */ export default async function get(ctx, next) { const { session: { user }, params } = ctx; ctx.body = (user && user.email) ? ({ recruitement: await recruitement(params || {}), }) : ({ status: 'Un...
package no.nav.omsorgspenger.personopplysninger.pdl import kotlinx.coroutines.runBlocking import no.nav.omsorgspenger.ApplicationContext import no.nav.omsorgspenger.testutils.ApplicationContextExtension import org.junit.jupiter.api.Assertions.assertNotNull import org.junit.jupiter.api.Assertions.assertNull import org....
<?php namespace Fisdap\Api\Client\Attachments\Categories\Gateway; use Fisdap\Api\Client\Gateway\Gateway; /** * Contract for attachment categories gateways * * @package Fisdap\Api\Client\Attachments\Categories\Gateway * @author Ben Getsug <bgetsug@fisdap.net> */ interface AttachmentCategoriesGateway extends Gate...
import { BlockUIServiceInstance } from '../block-ui.module'; import { BlockUIDecoratorSettings } from '../models/block-ui-decorator-settings.model'; export let blockInstanceGuid = 1; export function BlockUI(blockName?: string, settings: BlockUIDecoratorSettings = {}) { if (!settings.scopeToInstance) { return fu...
IMAGE="ubuntu-20.04" declare -a machines=( "consul-leader-0" "nomad-leader-0" "nomad-worker-0" "nomad-worker-1" "nomad-worker-2" ) function clear_logs { for i in "${machines[@]}"; do rm -rf "out_$i.txt" & done } function rebuild { printf "%s\n\n" "Cluster is rebuilding..." ...
import 'package:flutter/material.dart'; import 'package:mqtt_app/models/room.dart'; import 'package:mqtt_app/modules/core/managers/MQTTManager.dart'; import 'package:provider/provider.dart'; import 'package:mqtt_app/helpers/database_helper.dart'; class CustomSDisplayChoice extends StatefulWidget { // final Room room...
<?php class History { private $CI; private $dataHtml; public function __construct($arr = array()) { $this->CI =& get_instance(); $this->dataHtml = $arr; $this->html = $this->builder(); } private function builder() { $data = $this->dataHtml; $html = array(); foreach ($data a...
module PdflibMini module Handle class Asset < Base def initialize(asset, p) super(asset) @p = p end end end end
namespace GrovePi.Sensors { public interface IPIRMotionSensor { bool IsPeopleDetected(); } internal class PIRMotionSensor:Sensor<IPIRMotionSensor>, IPIRMotionSensor { public PIRMotionSensor(GrovePi device, Pin pin):base(device, pin, PinMode.Input) { } publ...
import { Controller, Get } from '@nestjs/common'; import { WelcomeService } from './welcome.service'; import { Observable } from 'rxjs'; import { ApiImplicitHeader } from '@nestjs/swagger'; @Controller() export class WelcomeController { constructor(private readonly _welcomeService: WelcomeService) {} @Get() wel...
<!-- START: Scripts --> <!-- jQuery --> <script src="assets/vendor/jquery/dist/jquery.min.js"></script> <!-- Font Awesome --> <script defer src="assets/vendor/fontawesome-free/js/all.js"></script> <script defer src="assets/vendor/fontawesome-free/js/v4-shims.js"></script> <!-- Object Fit Images --> <script src="assets...
/* Operators Copyright 2010-201x held jointly by LANS/LANL, LBNL, and PNNL. Amanzi is released under the three-clause BSD License. The terms of use and "as is" disclaimer for this license are provided in the top-level COPYRIGHT file. Author: Konstantin Lipnikov (lipnikov@lanl.gov) Base class for ver...
#!/usr/bin/env bash supervisord </dev/null &>/dev/null & sleep 1 python3 -m pytest --failed-first --verbose -x --cov-report term-missing \ --cov="$PWD" python2 -m pytest --failed-first --verbose -x --cov-report term-missing \ --cov="$PWD"
# ATTiny programming shield (using an Arduino Uno) This project is a simple PCB design which can be used to program an ATTiny(25/45/85) with an Arduino Uno as an ISP. # Getting started ## Required parts The following is a list of the parts used in this project: * DIP 8-pin socket * 10uF electrolytic capacitor * Mal...
namespace LinkedDataFragments.TriplePatternFragments { using System; using System.Collections; using System.Collections.Generic; using VDS.RDF; internal class Enumerator : IEnumerator<Triple> { private IEnumerator<Triple> e; private Uri uri; internal Enumerator(Uri uri...
namespace Mix.Cms.Lib.Constants { public class MixAuthConfigurations { public const string AccessTokenExpiration = "AccessTokenExpiration"; public const string RefreshTokenExpiration = "RefreshTokenExpiration"; public const string ValidateIssuer = "ValidateIssuer"; public const ...
using System; using System.Drawing; using System.Drawing.Drawing2D; using NUnit.Framework; using System.Reflection; namespace Test.Sys.Drawing { /// <summary> /// Summary description for Pens. /// </summary> [TestFixture] public class ColorsFixture { [SetUp] public void SetUp () { ...
'use strict'; const expect = chai.expect; describe('bracket notation', () => { it('types of tasty treats', () => { const key1 = 'dry'; const key2 = _; const obj = {}; obj[key2] = _; obj[_] = 'bread' expect(obj.wet).to.equal('soup'); expect(obj[_]).to.equal(_); }); it('a menagerie', (...
using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace Maui.Presentation.Excel { public class AddinReloadButton : IToolbarButton { public AddinReloadButton( Action reloadAction ) { OnClickHandler = reloadAction; } ...
package ctpm import ( "fmt" "github.com/c3pm-labs/c3pm/config" ) type RemoveOptions struct { Dependencies []string } func Remove(pc *config.ProjectConfig, opts RemoveOptions) error { if pc.Manifest.Dependencies == nil || len(pc.Manifest.Dependencies) == 0 { return fmt.Errorf("cannot remove dependency: there is...
package com.tunjid.androidx.tablists.tables import android.view.View import android.view.ViewGroup import android.widget.FrameLayout import androidx.constraintlayout.widget.ConstraintLayout import androidx.core.view.updateLayoutParams import androidx.dynamicanimation.animation.SpringForce import androidx.dynamicanimat...
import argparse import time import pagerank DP = 0.85 EPS = 1e-6 OFILE = 'output.pagerank' def load_graph(fname): with open(fname, 'r') as f: size = int(f.readline().split()[1]) g = pagerank.Graph(size) # read all edges for l in f: tks = l.split() idx, ou...
import 'dart:convert'; import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; import 'package:http/http.dart' as http; import '../OverAll.dart'; import '../overall_home_widget.dart'; import 'dashed_line_widget.dart'; import 'news.dart'; class NewsHomePage extends StatefulWidget{ final Strin...
import React from "react"; import styles from "../../styles/jss/components/listWithIcon"; import { Icon, Typography } from "@material-ui/core"; export default function ListWithIcon(props) { const classes = styles(); const { lists, startIcon, iconColor = "action" } = props; return ( <ul className={classes.lis...
use super::application_windows::WindowData; use super::{external_windows::*, keys_windows::virtual_keycode_to_key}; use kapp_platform_common::*; use std::ptr::null_mut; use std::convert::TryInto; use std::sync::atomic::{AtomicBool, Ordering}; pub static mut DBLCLICK_L: AtomicBool = AtomicBool::new(false); pub static ...
require "spec_helper" describe PhotoSize do describe "#geometry_string" do it "mobile_sm resizes to natural x 480" do geo = PhotoSize.mobile_sm.geometry_string expect(geo).to eq("x480") end it "mobile_lg resizes to natural x 960" do geo = PhotoSize.mobile_lg.geometry_string expec...
#!/usr/bin/env bash set -ex bin/i18n-convert-transifex-hugo.sh mkdir -p src/public src/resources hugo -s src
package nhdphuong.com.manga.usecase import io.reactivex.Single import nhdphuong.com.manga.data.repository.BookRepository import javax.inject.Inject interface GetDownloadedBookPagesUseCase { fun execute(bookId: String): Single<List<String>> } class GetDownloadedBookPagesUseCaseImpl @Inject constructor( privat...
package uk.gov.companieshouse.api.accounts.model.entity; import org.springframework.data.mongodb.core.mapping.Field; public class MembersFundsEntity { @Field("profit_and_loss_account") private Long profitAndLossAccount; @Field("total_members_funds") private Long totalMembersFunds; public Long g...
/** * Created by Alexandru Ionut Budisteanu - SkyHub on 6/5/2017. * (C) BIT TECHNOLOGIES */ import Forum from '~models/Forum/Forum'; export function defaultRouterState (initial) { return{ refAuthenticationModal : initial.refAuthenticationModal||null, } }; export default function RouterStateReducer ( ...
# Licensed to Elasticsearch B.V. under one or more contributor # license agreements. See the NOTICE file distributed with # this work for additional information regarding copyright # ownership. Elasticsearch B.V. licenses this file to you under # the Apache License, Version 2.0 (the "License"); you may # not use this f...
class Mappru::DSL::Converter include Mappru::Utils::Helper def self.convert(exported, options = {}) self.new(exported, options).convert end def initialize(exported, options = {}) @exported = exported @options = options end def convert output_vpcs(@exported) end private def output_...
//! Module with the type part of a HTTP message head. use std::fmt; pub mod header; pub mod method; mod status_code; pub mod version; #[doc(no_inline)] pub use header::{Header, HeaderName, Headers}; #[doc(no_inline)] pub use method::Method; pub use status_code::StatusCode; #[doc(no_inline)] pub use version::Version;...
package cmd import ( "fmt" "log" "os" "sync" "github.com/agilebits/sm/secrets" "github.com/spf13/cobra" ) // shredCmd represents the shred command var shredCmd = &cobra.Command{ Use: "shred", Short: "Shred all files listed in the manifest", Long: `This command will remove all files in the .sm/manifest. F...
/* Package permutations https://leetcode-cn.com/problems/permutations/ 46. 全排列 给定一个 没有重复 数字的序列,返回其所有可能的全排列。 */ package permutations // --- 自己 /* 方法一: 回溯 时间复杂度: 空间复杂度: */ func permute(nums []int) [][]int { ans := make([][]int, 0) item := make([]int, 0) var backTrack func() backTrack = func() { if len(item) =...
function Get-DSGroupMember { [CmdletBinding(DefaultParameterSetName='Current')] param( # Domain controller. [Parameter(ParameterSetName = 'Remote', Mandatory = $true)] [string] $ComputerName, # Credentials to use connection. [Parameter...
/* Generated by RuntimeBrowser Image: /System/Library/Frameworks/AudioToolbox.framework/AudioToolbox */ @interface AUAudioUnitBus_XPC : AUAudioUnitBus <NSSecureCoding> { AUAudioUnit_XH * _audioUnit; unsigned int _element; AVAudioFormat * _format; <AUAudioUnitXPCProtocol> * _remoteAU; bool _re...
# encoding: utf-8 require 'x2ch' include X2CH bbs = Bbs.load bbs['趣味']['アクアリウム'].threads.first.each{|post| puts "#{post.name} <> #{post.mail} <> #{post.metadata} <> #{post.body}" }