text stringlengths 27 775k |
|---|
package com.smartgwt.mobile.showcase.client.widgets.layouts;
import com.smartgwt.mobile.client.types.Alignment;
import com.smartgwt.mobile.client.types.VerticalAlignment;
import com.smartgwt.mobile.client.widgets.Header1;
import com.smartgwt.mobile.client.widgets.Header2;
import com.smartgwt.mobile.client.widgets.Pane... |
import { Component, OnInit, QueryList, ViewChildren } from '@angular/core';
import { AbstractControl, FormBuilder, FormGroup, Validators } from '@angular/forms';
import { MatSelectionList, MatSelectionListChange } from '@angular/material/list';
import { IForm } from '@core/models/form';
import { Equipment } from '@modu... |
import 'package:flutter/material.dart';
void main() {
runApp(
MaterialApp(
title: "GDG POS Demo",
home: GDGPosDemo(),
),
);
}
class GDGPosDemo extends StatefulWidget {
@override
_GDGPosDemoState createState() => _GDGPosDemoState();
}
class _GDGPosDemoState extends State<GDGPosDemo> {
in... |
INSERT INTO table_test VALUES ('a2');
INSERT INTO table_test VALUES ('a4');
COMMIT; |
import timeit
import os
# time 1
# start pub/sub server and operator
startvis = timeit.default_timer()
print("draw the graph")
print (startvis) |
// A custom struct:
struct Droppable {
name: &'static str,
}
// A custom implementation of the Drop trait for the struct:
impl Drop for Droppable {
// Rust calls automatically `drop()` for each field of a struct. A custom
// implementation of the Drop trait needs only to dealocacte resources
// introdu... |
package gcloud.scala.pubsub
import java.util.concurrent.TimeUnit
import com.google.api.gax.core.CredentialsProvider
import com.google.cloud.pubsub.v1.{
AckReplyConsumer,
MessageReceiver,
Subscriber => GCloudSubscriber
}
import com.google.pubsub.v1
object Subscriber {
private[pubsub] final val MaxInboundMessa... |
#!/bin/bash
flake8 cloudeyeclient | tee flake8.log
exit ${PIPESTATUS[0]}
|
import 'dart:math';
import 'package:data/injection.dart';
import 'package:domain/entity/item.dart';
import 'package:domain/entity/story_type.dart';
import 'package:domain/logger.dart';
import 'package:domain/usecase/get_item_use_case.dart';
import 'package:domain/usecase/get_stories_use_case.dart';
import 'package:flu... |
using AdventOfCode.Core;
using NUnit.Framework;
namespace AdventOfCode2017
{
public class Day17Tests : TestBase
{
const int DAY = 17;
[Test]
public void TestPartOne()
{
Assert.That(Day17.PartOne(343), Is.EqualTo(1914));
}
[Test]
public void... |
using Levels.domain.repositories;
using Purchases.domain.repositories;
using Purchases.presentation.ui;
using Zenject;
namespace Purchases.adapters
{
public class LevelNumberProviderAdapter : PassLevelRewardPurchaseItem.ILevelNumberProvider
{
[Inject] private IPassLevelRewardPurchasesRepository passLe... |
/*
* Copyright (c) 2012-2018 Daniele Bartolini and individual contributors.
* License: https://github.com/dbartolini/crown/blob/master/LICENSE
*/
#include "config.h"
#if CROWN_BUILD_UNIT_TESTS
#include "core/command_line.h"
#include "core/containers/array.h"
#include "core/containers/hash_map.h"
#include "core/co... |
require 'brew_sparkling/logger'
require 'brew_sparkling/gateway/xcode'
require 'digest/sha1'
module BrewSparkling
class User
class <<self
def default
@user ||= new
end
end
def account
@account ||= find_or_first(accounts) { |account|
account.username == env(:username)
... |
---
title: S002《I tell you》Windows系统各版本纯净镜像
---
## 直达链接: [https://msdn.itellyou.cn/](https://msdn.itellyou.cn/)

I tell you 提供从Windows98 之后时间段的所有镜像,如果你需要重装系统,或者安装虚拟机,可以从这里下载到纯净的ISO Windows镜像, 镜像提供了p2p下载链接,下... |
class Regex {
// https://stackoverflow.com/a/32686261/9449426
Regex._();
static RegExp regExp = RegExp(r'^[^\s@]+@[^\s@]+\.[^\s@]+$');
static set regexp(RegExp value) {
regExp = value;
}
static RegExp get regexp => regExp;
}
|
package cz.prague.cvut.fit.steuejan.amtelapp.fragments.abstracts
import androidx.fragment.app.activityViewModels
import cz.prague.cvut.fit.steuejan.amtelapp.view_models.activities.MatchViewPagerActivityVM
abstract class AbstractMatchActivityFragment : AbstractBaseFragment()
{
protected val matchViewModel by activ... |
# vkphpbot
Бот для ВКонтакте написанный на PHP, использует Callback API. Пример: https://vk.com/iusephpbtw
#### ОСТОРОЖНО! ГОВНОКОД !!!!
# Настройка
Создайте файл config.php и впишите туда:
``` php
<?php
$confirmation_token = "токен для подтверждения сервера";
$token="токен группы";
$dbhost="localhost или что нибудь е... |
# gg18-etude
# GG18
R. Gennaro and S. Goldfeder. Fast Multiparty Threshold ECDSA with Fast Trustless Setup. In ACM CCS 2018.
4.1 Key generation protocol
Phase 1. Each Player Pi selects ui. Pi send g^ui to Pj(i!=j) by using commitment schema.
Phase 2. All Players perform Join-Feldman VSS together.
Phase 3. ZK-prove.
... |
// -----------------------------------------------------------------------
// <copyright file="Extensions.cs" company="Asynkron AB">
// Copyright (C) 2015-2021 Asynkron AB All rights reserved
// </copyright>
// -----------------------------------------------------------------------
using System;
using Google.Proto... |
const ST = ScientificTypes
ST.scitype(::PersistenceDiagram, ::ST.DefaultConvention; kwargs...) = PersistenceDiagram
|
# LINQ - Ordering Operators
The `orderby` clause of a LINQ query sorts the output sequence. You can control the properties used for sorting, and specify ascending or descending order.
## orderby sorts elements
This sample uses `orderby` to sort a list of words alphabetically.
``` cs --region orderby-syntax --source... |
<?php
namespace App\Http\Controllers;
use App\Workshop;
use Illuminate\Support\Facades\File;
use Illuminate\Support\Facades\Storage;
class PanelWorkshopsController extends Controller
{
public function index()
{
return view('panel.talleres.index', [
'talleres' => workshop::paginate()
... |
import Base from './base';
import Content from './content';
import Wrapper from './wrapper';
export {
Base,
Content,
Wrapper,
} |
package de.javaclub.playground.hexagonal.domain
data class DeletionStatistic(
val successful: List<DeletionProof>,
val failure: List<DeletionProof>,
val repaired: List<DeletionProof>) |
# frozen_string_literal: true
##
# This module is the overall representation of our InspecDelta implementation
module InspecDelta
##
# This is the version constant for the inspec_delta gem
VERSION = '0.1.1'
end
|
@{
Layout = "~/Views/Shared/_ContentPage.cshtml";
Response.StatusCode = 404;
}
@section leftnav{
<li class="active"><a href="javascript:void(0)">Not found Error</a></li>
}
<h1>
Page not found (404)
</h1>
<p>
The page may have been moved or is no longer available.
</p>
<p>
<a href="/">WorldWide Telescope Home p... |
"""
---
Structure for OFDM
# --- Syntax
- nFFT : FFT size [Int]
- nCP : Cyclic prefix size [Int]
- allocatedSubcarriers : Vector of allocated subbcarriers [Array{Int}]
# ---
# v 1.0 - Robin Gerzaguet.
"""
struct StrucOFDM <: Waveform
nFFT::Int;
nCP::Int;
allocatedSubcarriers::Array{Int};
end
"""
---
Crea... |
@page
@model Senparc.Areas.Admin.Pages.IndexModel
@{
ViewData["Title"] = "管理员后台首页";
Layout = "_Layout_Vue";
}
@section style{
<style>
.xncf-stat-item {
position: relative;
display: block;
margin-bottom: 12px;
border: 1px solid #E4E4E4;
ov... |
using System;
using System.Linq;
using Microsoft.Azure.Cosmos;
using CosmosToolbox.Core.Attributes;
using CosmosToolbox.Core.Data;
using CosmosToolbox.Core.Extensions;
namespace CosmosToolbox.App.Extensions
{
public static class EntityExtensions
{
public static ContainerProperties GetContainerPropertie... |
import 'package:flutter/material.dart';
void main() {
runApp(MyApp());
}
class MyApp extends StatelessWidget {
// This widget is the root of your application.
@override
Widget build(BuildContext context) {
return MaterialApp(
theme: ThemeData(
// This is the theme of your application.
... |
using Content.Client.GameObjects.Components.Research;
using Content.Shared.Research;
using Robust.Client.Graphics;
using Robust.Client.Graphics.Drawing;
using Robust.Client.Interfaces.Graphics;
using Robust.Client.UserInterface.Controls;
using Robust.Client.UserInterface.CustomControls;
using Robust.Client.Utility;
usi... |
require 'test_helper'
class AssignmentTest < ActiveSupport::TestCase
setup do
@user = Factory(:user, :username => 'bob', :password => 'secret')
@course = Factory(:course)
@repository = Factory(:repository, :user => @user)
end
teardown :clean_local_fs!
test "should create assignment with attached c... |
use regex::Regex;
use std::str::FromStr;
#[derive(Debug)]
pub enum DirectoryItemType {
Link,
File,
Directory,
}
#[derive(Debug)]
pub struct DirectoryItem {
name: String,
item_type: DirectoryItemType,
}
impl FromStr for DirectoryItem {
type Err = String;
fn from_str(s: &str) -> Result<Self, Self::Err> {
//... |
import {
IsAny,
IsAnyOrUnknown,
IsUnknown,
Iteration,
KeyValuate
} from "@re-/utils"
import { ParseConfig, ShallowCycleError } from "./internal.js"
import { Root } from "../root.js"
import { References } from "../../references.js"
type CheckReferencesForShallowCycle<
References extends string[]... |
---
layout: post
title: "/usr/libexec/mysqld: Incorrect information in file"
date: 2014-09-20 15:09:08 +0900
comments: true
categories: MySQL
published: true
---
[ERROR] /usr/libexec/mysqld: Incorrect information in fileと言うエラー文。
どうもテーブル参照ができないらしい。
mysqlcheckを実行してみる。
```
$ mysqlcheck -u root -p -... |
// Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved.
// Code generated. DO NOT EDIT.
// Core Services API
//
// APIs for Networking Service, Compute Service, and Block Volume Service.
//
package core
import (
"github.com/oracle/oci-go-sdk/common"
)
// TunnelStatus Specific connection det... |
#!/usr/bin/env bash
state_file="sync/state"
# If state file exists remove it
[[ -f $state_file ]] && rm $state_file
# If State file does not exist create it
[[ ! -f $state_file ]] && touch $state_file
vagrant up
# Create docker context
docker context create remote --default-stack-orchestrator=swarm --docker host=t... |
#!/bin/sh
. ./include.sh
TEMP1=temp1.grib_index.py.txt
TEMP2=temp2.grib_index.py.txt
IDX_FILE=my.idx
rm -f $IDX_FILE
# First time it will create the index file
$PYTHON $examples_src/grib_index.py > $TEMP1
[ -f "$IDX_FILE" ]
# Second time it will use the file created before
$PYTHON $examples_src/grib_index.py > $T... |
<?php
return [
'our_outlets' => 'Data Instansi PPU',
];
|
<?php
/**
* @var \Bavix\GlowApi\Api $client
*/
$client = require __DIR__ . '/_client.php';
// create
$client->showOrCreateBucket('api');
// show
$client->showOrCreateBucket('api');
// get all
foreach ($client->allBuckets() as $bucket) {
var_dump($bucket);
var_dump($client->dropBucket($bucket['name']));
}
|
import {
createStyles,
Theme,
withStyles,
Typography,
Container
} from "@material-ui/core";
import * as React from "react";
import "typeface-roboto";
const CareersJpg = "/assets/jpg/careers.jpg";
const CooperationJpg = "/assets/jpg/cooperation.jpg";
const styles = (theme: Theme) =>
createStyles({
root:... |
<?php
namespace App\Http\Controllers;
use App\Commands\CreateAsset;
use App\Commands\DeleteAsset;
use App\Commands\GetAsset;
use App\Entities\Asset;
use App\Http\Responses\AjaxResponse;
use Illuminate\Validation\ValidationException;
use Symfony\Component\HttpKernel\Exception\MethodNotAllowedHttpException;
/**
* @Mi... |
using PetStore.Data.Models;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Metadata.Builders;
namespace PetStore.Data.Configuration
{
using static DataValidations;
public class BreedConfiguration : IEntityTypeConfiguration<Breed>
{
public void Configure(EntityTypeBuilder... |
# Analog2PWM
ATtiny85 converts analog in (0-Vcc) to PWM.
In response to a request on r/AskElectronics
Single-chip (+ bypass cap) solution.
This application uses a tiny fraction of the resources available and does the job quite well for less than USD 2.
Analog input must not exceed Vcc (5v max, although could be run ... |
module Graham.A278818 (a278818) where
import Math.NumberTheory.Powers.Squares (isSquare')
import Graham.A277278 (a277278)
import Data.List (find)
import Data.Maybe (fromJust)
-- The least t such that there exists a sequence
-- n = b_1 < b_2 < ... < b_t = A277278(n)
-- such that b_1 + b_2 +...+ b_t is a perfect square... |
#![doc(html_root_url = "https://docs.rs/dav/0.1.0-alpha.1")]
//! ## Placeholder for WEBDAV crates.
//!
//! Just a placeholder. `webdav_handler`, `webdav_server` might move here.
//!
#[cfg(test)]
mod tests {
#[test]
fn it_works() {
assert_eq!(2 + 2, 4);
}
}
|
<?php
namespace inklabs\kommerce\EntityRepository;
use inklabs\kommerce\Entity\Pagination;
use inklabs\kommerce\Entity\Product;
use inklabs\kommerce\Lib\UuidInterface;
/**
* @method Product findOneById(UuidInterface $id)
*/
interface ProductRepositoryInterface extends RepositoryInterface
{
public function findO... |
(define-native set-x)
(define-native get-system-cursor)
(define-native is-grabbed)
(define-native is-visible)
(define-native get-cursor)
(define-native set-visible)
(define-native get-relative-mode)
(define-native set-grabbed)
(define-native set-cursor)
(define-native get-position)
(define-native has-cursor)
(define-na... |
#!/usr/bin/env bash
# Rash example mysql schema
# =========================
# This is an example schema file for mysql. Customize this
# and save it as "schema.sh".
# Path to the file which contains the current migration step.
# TODO: This should be stored in the db itself.
CURRENT_MIGRATION_FILE="current_migrat... |
package com.panosdim.moneytrack.viewmodel
import androidx.lifecycle.*
import com.panosdim.moneytrack.api.CategoriesRepository
import com.panosdim.moneytrack.api.ExpensesRepository
import com.panosdim.moneytrack.api.data.Resource
import com.panosdim.moneytrack.model.Category
import com.panosdim.moneytrack.model.Expense... |
import React, { Fragment } from 'react';
import { Listbox, Transition } from '@headlessui/react';
import { TextSelectOption } from 'components/atoms';
import TextSelectProps from 'components/molecules/TextSelect/types';
import classNames from 'classnames';
export default function TextSelect({ options, state, className... |
require 'rails_helper'
RSpec.describe GradingReview::ReviewableEvaluationGroup do
subject { described_class.new(evaluation_group: evaluation_group, evaluations: evaluations) }
let(:evaluations) { [] }
let(:evaluation_group) { instance_double(EvaluationGroup) }
describe 'delegation' do
it { is_expected.to... |
require 'byebug/command'
#
# TODO: Implement thread commands as a single command with subcommands, just
# like `info`, `var`, `enable` and `disable`. This allows consistent help
# format and we can go back to showing help for a single command in the `help`
# command.
#
module Byebug
#
# Utilities to assist command... |
package com.winterparadox.themovieapp.home;
import com.winterparadox.themovieapp.common.beans.Movie;
import com.winterparadox.themovieapp.common.room.FavoriteDao;
import com.winterparadox.themovieapp.common.room.RecentlyViewedDao;
import java.util.List;
import io.reactivex.Single;
import io.reactivex.schedulers.Sche... |
using System.Windows;
namespace Xe.Tools.Components.MapEditor.Models
{
public class Frame
{
public Rect Source { get; set; }
public Point Pivot { get; set; }
}
}
|
-- import_schema_stats.sql
-- import statistics for a schema
-- comment this line to see variable subtitution
set verify off
col stattab_owner new_value stattab_owner noprint
col stat_table new_value stat_table noprint
col schema new_value schema noprint
col noinvalidate new_value noinvalidate noprint
col statid new... |
require "spec_helper"
require "support"
RSpec.describe SimpleState::Machine do
let(:dsl_definition) do
proc do
state :pending, :outsourced, :printed, :matched, :dispatched, :cancelled
transition :print, from: [:pending, :outsourced], to: :printed
transition :match, from: :printed, to: :match... |
<?php
return [
'send_password_link' => 'Stuur wagwoord terugstel skakel',
'email_reset_password' => 'E-pos wagwoord herstel',
'reset_password' => 'Herstel wagwoord',
'login' => 'Teken aan',
'login_prompt' => 'Asseblief Login',
'forgot_pas... |
import unittest
import import_ipynb
import pandas as pd
import pandas.testing as pd_testing
import numpy.testing as np_testing
from sklearn import datasets, svm, model_selection
class Test(unittest.TestCase):
def setUp(self):
import Exercise_8_2
self.exercises = Exercise_8_2
self.digits =... |
CREATE TABLE Changes
(
ChangeId INTEGER NOT NULL UNIQUE CONSTRAINT PrimaryKeyChanges PRIMARY KEY,
TableName TEXT(255) NULL,
FieldName TEXT(255) NULL,
ActionType TEXT(255) NULL,
OldValue TEXT(255) NULL,
NewValue TEXT(255) NULL,
ChangeDate DATETIME NULL,
Message TEXT(255) NULL
); |
{-|
Copyright : (c) Dave Laing, 2017-2019
License : BSD3
Maintainer : dave.laing.80@gmail.com
Stability : experimental
Portability : non-portable
-}
{-# LANGUAGE OverloadedStrings #-}
module Main (main) where
import Network.Wai (responseLBS)
import Network.HTTP.Types.Status (status200)
import Reflex.Backend.... |
<?php
declare(strict_types=1);
namespace Otis22\VetmanagerRestApi\URI;
use Otis22\VetmanagerRestApi\Model;
use PHPUnit\Framework\TestCase;
class OnlyModelTest extends TestCase
{
public function testAsString(): void
{
$this->assertTrue(
strpos(
(
new On... |
package watchjs
import "sync"
// Hub dispatches Message to multiple listeners.
type Hub struct {
mu sync.RWMutex
conns map[Listener]struct{}
}
// NewHub creates a new Hub.
func NewHub() *Hub {
return &Hub{
conns: map[Listener]struct{}{},
}
}
// Listener is a connection that cares about the changes.
type Li... |
from functools import lru_cache
from importlib import import_module
from .basic import BasicSSHConnector
from .basic import set_max_startups # noqa
@lru_cache()
def get_connector_class(mod_cls_name=None):
if not mod_cls_name:
return BasicSSHConnector
mod_name, _, cls_name = mod_cls_name.rpartition(... |
package kotlinmud.mob.skill.impl.malediction
import kotlinmud.affect.model.Affect
import kotlinmud.affect.type.AffectType
import kotlinmud.io.model.Message
import kotlinmud.mob.model.Mob
import kotlinmud.mob.skill.factory.easyForMage
import kotlinmud.mob.skill.factory.mageAt
import kotlinmud.mob.skill.type.SkillType
i... |
#Get the HyperflexExtFcStoragePolicy to delete
$HyperflexExtFcStoragePolicy = Remove-IntersightHyperflexExtFcStoragePolicy -Name HyperflexExtFcStoragePolicyName
$HyperflexExtFcStoragePolicy | Remove-IntersightHyperflexExtFcStoragePolicy
#Remove the server profile by Moid.
Remove-IntersightHyperflexExtFcStoragePolicy ... |
package com.corvisaAPI.notification;
import javax.servlet.ServletException;
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
@WebServlet("/launch")
public ... |
package main
import (
"flag"
)
var (
cmdHelp = flag.Bool("h", false, "帮助")
)
func init() {
flag.Parse()
}
func main() {
if *cmdHelp {
flag.PrintDefaults()
return
}
}
|
---
layout: page
title: Page Not Found - 404
showTitle: false
---
{% assign path="boilerplate/404/" | append: site.jaytch.page_404 | append: ".md" %}
{% include {{ path }} %} |
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
namespace Visualisation {
public static partial class Vis {
}
} |
# Create Docker image with Itamae
## install itamae
1. Create a new `Gemfile`
```bash
$ bundle init
$ vim Gemfile
```
2. Now open `Gemfile` and put `itamae` as dependency
```
gem "itamae"
```
3. Save, close file and install deps
```bash
$ bundle install --path vendor
```
## itamae init
1. Create a new `itamae... |
package system
import (
"github.com/creasty/apperrors"
)
// ErrorCode represents error identifier specified for this application
type ErrorCode int
// Enum values for ErrorCode
const (
ErrorUnknown ErrorCode = iota
ErrorInvalidArgument
ErrorUnauthorized
ErrorForbbiden
ErrorNotFound
ErrorFailedToReadDB
ErrorF... |
<?php
namespace FKS\Channels;
class NodeJS
{
private $host='localhost';
private $port='1771';
private $socket;
private function connect()
{
if (($this->socket = socket_create(AF_INET, SOCK_STREAM, SOL_TCP))){
return socket_connect($this->socket,$this->host,$this->port);
... |
<?php
class Brivium_ExtraTrophiesAwarded_DataWriter_User extends XFCP_Brivium_ExtraTrophiesAwarded_DataWriter_User
{
protected function _getFields()
{
$fields = parent::_getFields();
$fields ['kmk_user']['breta_event_date'] = array('type' => self::TYPE_UINT, 'default' => 0);
$fields ['kmk_user']['breta_user... |
package top.techqi.chaotic.util
import android.annotation.SuppressLint
import android.app.Application
import top.techqi.chaotic.R
/**
* 在任意模块中都能获取到常规信息的辅助类
*/
@SuppressLint("PrivateApi")
@Suppress("unused", "MemberVisibilityCanBePrivate", "HasPlatformType")
object PluginApp {
val INSTANCE: Application by lazy {... |
# Leetcode Notes
[click here to return](https://annaleee.github.io/books.html)
1. <a href="DP/DP.md">动态规划</a>
2. <a href="Backtracking/Backtracking.md">回溯算法</a>
|
package de.mtorials.dialbot.listeners
import de.mtorials.dialbot.Config
import de.mtorials.dialphone.dialevents.MessageReceivedEvent
import de.mtorials.dialphone.listener.ListenerAdapter
import kotlinx.coroutines.GlobalScope
import kotlinx.coroutines.launch
class WordListener(
private val moderationConfig : Confi... |
/*
* StatCraft Plugin
*
* Copyright (c) 2016 Kyle Wood (DemonWav)
* https://www.demonwav.com
*
* MIT License
*/
package com.demonwav.statcraft.sql
class SpongeDatabaseManager : AbstractDatabaseManager() {
// We don't have access to commons lang < 3, so we don't have escapeSql, so just don't worry about it
... |
CREATE PROCEDURE [dbo].[spSRAGetEmployeeByToken]
@token_id nvarchar(50)
AS
SELECT
[TBL_SRA_EMPLOYEE].id,
[TBL_SRA_EMPLOYEE].area,
[TBL_SRA_EMPLOYEE].[role],
[TBL_SRA_PERSON].id as "person_id",
[TBL_SRA_PERSON].identification,
[TBL_SRA_PERSON].name,
[TBL_SRA_PERSON].middle_name,
[TBL_SRA_PERSON... |
/*
Copyright 1996-2008 Ariba, Inc.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed... |
import math
# inputs:
# thetadeg -> polar coordinate angle in degrees
# distancemm -> polar coordinate radius in mm
# xtxm/ytxm -> translations in the x & y dimensions
# outputs:
# x -> cartesian coordinate in x dimension in m
# y -> cartesian coordinate in y dimension in m
angleRad = (thetadeg + angulartx... |
# Use duecredit (duecredit.org) to provide a citation to relevant work to
# be cited. This does nothing, unless the user has duecredit installed,
# And calls this with duecredit (as in `python -m duecredit script.py`):
from .external.due import due, Doi, BibTeX
due.cite(Doi("10.3389/fninf.2011.00013"),
descr... |
require 'test_helper'
class PortfolioTest < ActiveSupport::TestCase
# test "the truth" do
# assert true
# end
def setup
@user = User.new(name: "Example User2", email: "example2@example.com",
password: "foobar", password_confirmation: "foobar")
@user.save
@portfoli... |
import { getFullPathLabel, getTreeValue } from './helper';
import { TreeNode, TreeNodeValue, CascaderContextType } from '../interface';
/**
* input和treeStore变化的副作用
* @param inputVal
* @param treeStore
* @param setTreeNodes
* @returns
*/
export const treeNodesEffect = (
inputVal: CascaderContextType['inputVal']... |
package com.cheise_proj.remote_source.mapper.user
import com.cheise_proj.data.model.user.UserData
import com.cheise_proj.remote_source.mapper.RemoteMapper
import com.cheise_proj.remote_source.model.dto.user.UserDto
internal class UserDtoDataMapper :
RemoteMapper<UserDto, UserData> {
override fun dtoToData(t: ... |
;;;-*- Mode: Lisp; Package: :cl-user -*-
;;;
;;; apex/system/asa/rat.lisp
;;;
;;; Copyright: See apex/LICENSE
;;; Version: $Id: rat.lisp,v 1.1 2006/03/13 19:22:37 will Exp $
(in-package :common-lisp-user)
;;; ------ Resource Allocation Tables
;;; The resource-allocation-table agent slot contains a struct... |
package org.dhis2.utils.filters.workingLists
import org.hisp.dhis.android.core.trackedentity.TrackedEntityInstanceFilter
class TeiFilterToWorkingListItemMapper(
private val defaultWorkingListLabel: String
) {
fun map(teiFilter: TrackedEntityInstanceFilter): WorkingListItem {
return WorkingListItem(
... |
<#
.Synopsis
Enable litigation hold for a user or for all users.
.Description
Enable litigation hold for a user or for all users.
.Parameter all
If litigation hold should be enabled for all users
.Parameter user
If all is $False, a user must be specified. Use their email address.
.Parameter use... |
CREATE DATABASE T_AutoPecas;
USE T_AutoPecas;
CREATE TABLE Pecas(
PecaId INT PRIMARY KEY IDENTITY NOT NULL,
PecaCodigo INT UNIQUE NOT NULL,
Descricao VARCHAR(255) NOT NULL,
Peso FLOAT NOT NULL,
PrecoCusto MONEY NOT NULL,
PrecoVenda MONEY NOT NULL,
FornecedorId INT FOREIGN KEY REFERENCES Fornecedores(Fornecedor... |
import { getRandomNumber, getRandomColor } from './utils';
const registerTicket = function () {
const newTicket = {
number: getRandomNumber(),
color: getRandomColor()
};
this.setState((prevState) => {
prevState.tickets.push(newTicket);
return {
tickets: prevStat... |
package io.github.durun.lateko.model.inline
import io.github.durun.lateko.model.Element
import io.github.durun.lateko.model.Format
interface InlineElement : Element {
fun <R> accept(visitor: InlineVisitor<R>): R
fun renderedAs(format: Format): String
} |
import classes from "../Styles/Header.module.css"
import { NavLink } from "react-router-dom";
import logo from "../../src/img/Titile_logo.png"
import styles from "../Styles/Header.module.css"
import React from "react";
type Props_type = {
logout? : ()=>void,
auth? : boolean
}
const path = logo;
const Header_... |
#!/bin/bash
cat >~/.config/user-dirs.dirs <<EOF
XDG_DESKTOP_DIR="$HOME/Desktop"
XDG_DOWNLOAD_DIR="$HOME/Downloads"
XDG_TEMPLATES_DIR="$HOME/Templates"
XDG_PUBLICSHARE_DIR="$HOME/Public"
XDG_DOCUMENTS_DIR="$HOME/Documents"
XDG_MUSIC_DIR="$HOME/Music"
XDG_PICTURES_DIR="$HOME/Pictures"
XDG_VIDEOS_DIR="$HOME/Video"
EOF
|
<?php
namespace Modules\Announcement\Http\Controllers;
use Illuminate\Http\Request;
use Illuminate\Http\Response;
use Illuminate\Routing\Controller;
use Modules\Announcement\Repositories\AnnouncementRepository;
use Modules\Announcement\Http\Requests\CreateAnnouncementRequest;
use Modules\Announcement\Http\Requests\U... |
/*
* Copyright © 2016-2018 European Support Limited
*
* 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 applica... |
package es.nimio.nimiogcs.jpa.entidades.artefactos.directivas;
import java.util.Map;
import javax.persistence.Access;
import javax.persistence.AccessType;
import javax.persistence.Column;
import javax.persistence.DiscriminatorValue;
import javax.persistence.Entity;
import javax.persistence.Table;
import e... |
@extends('layouts.app')
@section('title')
<title>Quản trị danh mục phim </title>
@endsection
@section('content')
<div class="container">
<h2 style="text-align: center">Chào mừng bạn đến với trang quản lí danh mục</h2>
<table class="table table-striped table-dark" style="background-color: white; color: black">... |
/* %%%%%%%%%%%%%%%%%%%% (c) William Landi 1991 %%%%%%%%%%%%%%%%%%%%%%%%%%%% */
/* Permission to use this code is granted as long as the copyright */
/* notice remains in place. */
/* =========================== sim_debug.c ================================= */
/* Main (driving) routine of the Simulator/Debugger. ... |
systemctl --user enable onedrive
systemctl --user start onedrive
sudo apt install dphys-swapfile
sudo dphys-swapfile swapoff && \
sudo dphys-swapfile uninstall && \
sudo systemctl disable dphys-swapfile |
package com.fitbit.goldengate.bt.gatt.server.services.gattlink
import android.bluetooth.BluetoothGattService
import java.util.UUID
/**
* Represents the Gattlink Service hosted on mobile that allows reliable streaming of
* arbitrary data over a BLE connection using the GATT protocol, with support for BLE/GATT stacks... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.