text stringlengths 184 4.48M |
|---|
import * as Tabs from '@radix-ui/react-tabs';
import SearchApp from './SearchApp';
import { useState } from 'react';
import SelectBar from './selectBar';
import '@radix-ui/themes/styles.css';
import { TextField } from '@radix-ui/themes'
import { MagnifyingGlassIcon } from '@radix-ui/react-icons'
interface SideBarProps... |
# Preserving and Resetting State
## 들어가면서
state는 컴포넌트 간에 격리된다. React는 UI 트리에서 어떤 컴포넌트가 어떤 state에 속하는지를 추적. state를 언제 보존(preserve)하고 언제 초기화(reset)할지를 제어할 수 있음.
## state는 트리의 한 위치에 묶입니다(state는 렌더 트리에서의 컴포넌트의 위치에 따라 유지되며 삭제된다.)
React는 UI의 컴포넌트 구조에 대한 렌더 트리를 빌드함.
컴포넌트에 state를 부여할 때, state가 컴포넌트 내부에 “존재”한다고 생각할 수 있음. *... |
package masterspringsecurity.domain.dto.product.request;
import jakarta.validation.constraints.DecimalMin;
import jakarta.validation.constraints.Min;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import lombok.*;
import java.io.Serializable;
import java.math.BigDecimal... |
import React, { useRef } from "react";
import logo from "../../asst/default-person.png";
import { AiFillCloseCircle } from "react-icons/ai";
import { useDispatch, useSelector } from "react-redux";
import Skeleton, { SkeletonTheme } from "react-loading-skeleton";
import "react-loading-skeleton/dist/skeleton.css";
impor... |
<?php
namespace App\Notifications;
use Illuminate\Bus\Queueable;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Notifications\Messages\BroadcastMessage;
use Illuminate\Notifications\Messages\MailMessage;
use Illuminate\Notifications\Notification;
use Illuminate\Contracts\Broadcasting\ShouldBroadcast;
cla... |
# Name: Lucas Robertson
# Class: CSC 466-01 (Fall 2018)
# Filename: C45Util.py
# Description: Provides utilities for parsing schema xml and csv data files
import numpy as np
import xml.etree.ElementTree as et
from C45Node import C45Node
SPLIT_ITERATIONS = 10 # For 10 fold cross evaluation
SPLIT_RATIO = 10
# Parses ... |
import { FunctionComponent } from "react";
import { Button } from "@mui/material";
import Card from "@mui/material/Card";
import CardContent from "@mui/material/CardContent";
import Typography from "@mui/material/Typography";
import CardActions from "@mui/material/CardActions";
import DeleteIcon from "@mui/icons-materi... |
import { Button, Col, Container, Form, FormControl, Nav, Navbar, NavDropdown, Row } from "react-bootstrap"
import { ReactSVG } from "react-svg"
import { NavLink } from "react-router-dom";
import { useDispatch, useSelector } from "react-redux";
import { getUserData, logout } from "../../storeAsyncActions/account";
impor... |
import React, { useState } from 'react'
import { auth } from '../Firebase'
import { useHistory } from 'react-router-dom'
export default function Login() {
const [email, setEmail] = useState('');
const [password, setPassword] = useState('');
const history = useHistory();
const handleSubmit = async(e) =>... |
# Folksonomy API
A light REST API designed for the Open Food Facts Folksonomy Engine.
* Design documents: https://wiki.openfoodfacts.org/Folksonomy_Engine
* API endpoint: https://api.folksonomy.openfoodfacts.org/
* API Documentation with interactive "try-out": https://api.folksonomy.openfoodfacts.org/docs
* Browser ex... |
import org.palladiosimulator.pcm.repository.CompositeDataType
import tools.vitruv.applications.pcmumlclass.DefaultLiterals
import tools.vitruv.applications.pcmumlclass.TagLiterals
import "http://www.eclipse.org/uml2/5.0.0/UML" as uml
import "http://palladiosimulator.org/PalladioComponentModel/5.2" as pcm
reactions: u... |
//
// ProgreesView.swift
// MonnifyiOSSDK
//
// Created by Nnaemeka Abah on 18/04/2022.
// Copyright © 2022 Monnify. All rights reserved.
//
import Foundation
import UIKit
@IBDesignable
class CardProgressView: UIView {
override init(frame: CGRect) {
super.init(frame: frame)
s... |
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <pthread.h>
#define PHILOSOPHERS 5
pthread_mutex_t mutex;
pthread_cond_t cond[PHILOSOPHERS]; /* one per philosopher */
pthread_mutex_t print_lock; /* protects against output interleaving */
void space(int s) {
pthread_mutex_lock(&print_lock)... |
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags"%>
<%@ taglib prefix="tiles" uri="http://tiles.apache.org/tags-tiles... |
import { DataStoreLevel, EventLogLevel, MessageStoreLevel } from '../src/index-stores.js';
/**
* Class that manages store implementations for testing.
* This is intended to be extended as the single point of configuration
* that allows different store implementations to be swapped in
* to test compatibility with de... |
import { z } from '@botpress/sdk'
import { User } from '@linear/sdk'
import { assert, Equals } from 'tsafe/assert'
export const targets = z.object({
issue: z.record(z.string()).optional(),
})
type TransformDatesToStrings<T> = {
[K in keyof T]: T[K] extends Date | undefined ? string : T[K]
}
type LinearUserProfil... |
from django.contrib import admin
from .models import Group, Post
class GroupAdmin(admin.ModelAdmin):
list_display = (
'pk',
'title',
'slug',
'description',
)
list_editable = ('description',)
search_fields = ('title',)
list_filter = ('slug',)
empty_value_display... |
/*
* File: CheckerboardKarel.java
* ----------------------------
* When you finish writing it, the CheckerboardKarel class should draw
* a checkerboard using beepers, as described in Assignment 1. You
* should make sure that your program works for all of the sample
* worlds supplied in the starter folder.
*/
i... |
using System.ComponentModel.DataAnnotations;
namespace bookStore_project.DTO_s
{
public class BookDTO
{
//DTO are typically used to communicate with the client
public string Title { get; set; }
//The DataType attribute on ReleaseDate specifies the type of the data (Date).
... |
<template>
<a-card title="基础用法" :bordered="false">
<div style="max-width: 260px">
<ele-table-select
:allow-clear="true"
placeholder="请选择"
value-key="userId"
label-key="nickname"
v-model:value="selectedValue"
:table-config="tableConfig"
:overlay-style="... |
package org.nocountry.walam.main.model.dto;
import jakarta.validation.Valid;
import jakarta.validation.constraints.*;
import lombok.Builder;
import lombok.Data;
import org.nocountry.walam.main.model.entity.User;
import java.io.Serializable;
import java.util.List;
@Data
@Builder
public class AccountDTO implements Ser... |
{% extends "base.html" %}
{% block content %}
{% load markdown_to_html %}
<h1>Каталог карточек Anki для интервального повторения</h1>
<p>Здесь вы можете выбрать карточки для изучения</p>
<p>Найдено карточек: {{ page_obj.paginator.count }}</p>
{% comment %} Пагинация начало {% endcomment %}
<div class=... |
import type { LinkProps as NextLinkProps } from 'next/link'
import NextLink from 'next/link'
import { useRouter } from 'next/router'
import type { AnchorHTMLAttributes, PropsWithChildren } from 'react'
import { useCallback } from 'react'
export type LinkProps = PropsWithChildren<
NextLinkProps & Omit<AnchorHTMLAttri... |
In this chapter we present a one-way automaton model that has the same expressive power as two-way transducers.
We begin by defining {register transducers}, which are automata that use registers to store parts of their output. We have already seen register transducers in Chapter~\ref{sec:hilbert} -- in a more genera... |
import { expect } from 'chai';
import Region from '../../database/objects/region.db';
import dbSingleton from '../../database/dbSingleton';
import regionTableResource from '../resources/region.db.resource';
describe('Region table', function () {
let table: Region;
let createdRegion: Model.Region;
before(() => {
... |
from django.contrib.auth.base_user import BaseUserManager
class CustomUserManager(BaseUserManager):
"""
Custom user model manager where email is the unique identifiers
for authentication instead of usernames.
"""
def create_user(self, password, **extra_fields):
"""
Create and save... |
<?php
namespace App\Http\Controllers\Admin;
use App\Http\Requests\EquipmentModRequest;
use Backpack\CRUD\app\Http\Controllers\CrudController;
/**
* Class EquipmentModCrudController.
*
* @property-read \Backpack\CRUD\app\Library\CrudPanel\CrudPanel $crud
*/
class EquipmentModCrudController extends CrudController
... |
# 1 - 网络层数问题
- 网络层数:输入层 + 隐藏层 + 输出层
- 全连接层数:仅计算全连接层
- ReLU层数:全连接层数 - 1(最后一个个全连接层不带ReLU)
- 例如:1层输入层 + 2层隐藏层 + 1层输出层。网络层数=4,全连接层数=3,ReLU层数=2
# 2 - 创建网络层
创建全连接层:
```
import torch.nn as nn
fc = nn.Linear(左边节点数, 右边节点数)
```
进行运算:
```
y = fc(x)
```
进行带有ReLU的全连接计算:
```
relu = nn.ReLU() # Create ReLU Instance, remember... |
# Create GKE cluster using Terraform - Nginx Ingress & TLS - OIDC Workload Identity
## Create GKE cluster using Terraform
```bash
# Authenticate with your GCP account
gcloud auth login
# List available GCP projects
gcloud projects list
# Set your desired GCP project
gcloud config set project <project_id>
# Initial... |
package org.team4.view.manager.manage.book;
import java.awt.BorderLayout;
import javax.swing.JPanel;
import javax.swing.JTable;
import javax.swing.table.TableColumn;
import org.team4.maintaindb.MaintainDatabase;
import org.team4.model.items.Item;
import javax.swing.DefaultCellEditor;
import javax.swing.JComboBox;
im... |
#ifndef CARDWIDGET_H
#define CARDWIDGET_H
#include <QLabel>
#include <QPixmap>
#include "clienttypes.h"
#include "OverlayWidget.h"
#include "Logging.h"
QT_BEGIN_NAMESPACE
class QResizeEvent;
QT_END_NAMESPACE
class ImageLoaderFactory;
class ImageLoader;
class CardWidget_Overlay;
class CardWidget : public QLabel
{
... |
import { NgModule } from "@angular/core";
import { BrowserModule } from "@angular/platform-browser";
import { RouterModule, Routes } from "@angular/router";
import { HttpClientModule, HTTP_INTERCEPTORS } from "@angular/common/http";
import { AppComponent } from "./app.component";
import { LoginComponent } from "./logi... |
(* evidence.ml: Evidence calculations by various methods.
Copyright (C) 2011 Will M. Farr <w-farr@northwestern.edu>
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 Free Software Foundation, either version 3 o... |
%(BEGIN_QUESTION)
% Copyright 2010, Tony R. Kuphaldt, released under the Creative Commons Attribution License (v 1.0)
% This means you may do almost anything with this work of mine, so long as you give me proper credit
Read and outline the ``Use of Line Reactors'' section of the ``Variable-Speed Motor Controls'' chapt... |
import {
Box,
Button,
Container,
Image,
HStack,
Icon,
Heading,
} from "@chakra-ui/react";
import { useEffect, useState } from "react";
import { Link } from "react-scroll";
import pizza from "../../assets/images/favicon.png";
import { FiShoppingCart } from "react-icons/fi";
export default function Header(... |
import React, { useEffect, useState } from "react";
import BlogDetails from "../components/BlogDetails";
import BlogForms from "../components/BlogForms";
import { useThoughtsContext } from "../hooks/useBlogsContext";
const Home = () => {
const { blogs, dispatch } = useThoughtsContext();
const [loading, setLoading] ... |
import 'package:flutter/material.dart';
class ChartBar extends StatelessWidget {
final String label;
final double spentAmount;
final double spentPercentage;
ChartBar(this.label, this.spentAmount, this.spentPercentage);
@override
Widget build(BuildContext context) {
return LayoutBuilder(builder: (cont... |
package vn.funix.fx22541.asm02.models;
import java.util.ArrayList;
import java.util.List;
public class Customer extends User {
protected final List<Account> accounts;
public Customer(String name, String customerId) {
super(name, customerId);
this.accounts = new ArrayList<>();
}
p... |
use anyhow::{bail, Context, Result};
use reqwest::header::{HeaderMap, ACCEPT, AUTHORIZATION};
use serde::{Deserialize, Serialize};
#[derive(Serialize, Deserialize, Debug)]
#[serde(untagged)]
enum DomainRecordResponse {
Ok { domain_record: DomainRecord },
Error { id: String, message: String },
}
#[derive(Seria... |
/** Copyright 2004, 2005 The Apache Software Foundation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by appli... |
/// This module defines the fee computation protocol for Soroban.
///
/// This is technically not part of the Soroban host and is provided here for
/// the sake of sharing between the systems that run Soroban host (such as
/// Hcnet core or Soroban RPC service).
/// Rough estimate of the base size of any transaction r... |
import { AppBar, makeStyles, Toolbar } from '@material-ui/core';
import { push } from 'connected-react-router';
import { useCallback, useState, VFC } from 'react';
import { useDispatch, useSelector } from 'react-redux';
import logo from '../../assets/img/header_logo.png';
import { RootState } from '../../reducks/store... |
import React, { Fragment, useState } from "react";
import KeyboardArrowDownIcon from "@mui/icons-material/KeyboardArrowDown";
import { useDispatch } from "react-redux";
import { changeTheme } from "../../../theme/themeSlice";
import { useTranslation } from "react-i18next";
import { ECMenuItem } from "../../../component... |
# 11.1 Integrating Network Changes into CI/CD Pipelines
**Automated Testing for Network Configurations:**
1. **Test Automation Tools:**
- Choose appropriate tools for automating tests on network configurations.
- Examples include NAPALM, Ansible, or custom scripts.
2. **Unit Testing:**
- Create unit ... |
<script setup>
import {ref,reactive} from "vue"
const form = ref("form")
let prevData = []
if(localStorage.getItem("data")) {
prevData = JSON.parse(localStorage.getItem("data"))
}else{
prevData = []
}
const data = reactive([
...prevData,
])
console.log( prevData)
const emit = defineEmits(['response'])
const ha... |
"""Lab 07.05 - Binary Search Tree (Cases 1, 2, 3)"""
class BSTNode:
"""BSTNode"""
def __init__(self, data) -> None:
"""Initiation"""
self.data = int(data)
self.left = None
self.right = None
def set_data(self, data):
"""Setting Data"""
self.data = int(data)
... |
{% extends 'base.html' %}
{% load crispy_forms_tags %}
{% block content %}
<!-- Begin Page Content -->
<div class="container-fluid">
<!-- Page Heading
<nav class="navbar navbar-main navbar-expand-lg px-0 mx-4 shadow-none border-radius-xl " id="navbarBlur"
data-scroll="false">
<div class="container-f... |
package com.github.benoitf.devfile.extractor.entity;
import static java.util.stream.Collectors.toCollection;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.ut... |
import 'package:flutter/material.dart';
import 'package:google_fonts/google_fonts.dart';
class AddPage extends StatefulWidget {
const AddPage({Key? key}) : super(key: key);
@override
State<AddPage> createState() => _AddPageState();
}
enum options { PANORAMA,CAMERA, GBS }
class _AddPageState extends State<AddPa... |
<template>
<div class="vue-page">
<div class="ctrl">
<el-button type="primary" @click="onClickTest01()">测试JS:无声明文件</el-button>
<el-button type="primary" @click="onClickTest02()">测试JS:有声明文件</el-button>
<el-button type="primary" @click="onClickTest03()">测试JS:IIFE无声明文件</el-b... |
/**
* Represents a function to find the object with the maximum value of a given key in a list of objects.
*/
import { AbstractContextData } from '../../context';
import { TypeGuard } from '../../utils';
import ICommand, { isCommand } from '../ICommand';
import IFunction from './IFunction';
export default class MaxO... |
import React, { useState } from "react";
import {
Carousel,
CarouselItem,
CarouselControl,
CarouselIndicators,
} from "reactstrap";
import "../../css/app.css";
const items = [
{
src: require("../../images/Deals.png").default,
altText: "Deals",
caption: "Great deals in April!... |
import { makeMap } from './makeMap'
export { makeMap }
export * from './patchFlags'
export { isGloballyWhitelisted } from './globalsWhitelist'
// 导出一个空对象
export const EMPTY_OBJ: { readonly [key: string]: any } = __DEV__
? Object.freeze({})
: {}
// 导出一个空数组
export const EMPTY_ARR: [] = []
// 导出一个空函数
export const ... |
/**
* @mxmlc -target-player=10.0.0 -debug
*/
/**
* Katakana / Hiragana learning tool
* Jukka Paasonen
*/
package sandbox
{
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.media.Sound;
import flash.text.*;
import org.paazio.utils.Numbers;
import org.paazio.lang.Japanese;
... |
#include <ESP8266WiFi.h>
#include <ESP8266WiFiMulti.h>
#include <ESP8266mDNS.h>
#include <WiFiUdp.h>
#include <NTPClient.h>
#include <ArduinoOTA.h>
#include <FS.h>
ESP8266WiFiMulti wifiMulti;
const char* dns_name = "heizungssteuerung";
// time client
WiFiUDP ntpUDP;
NTPClient timeClient(ntpUDP, "pool.ntp.org");
//W... |
package com.epam.kubernetes_intensive.service;
import com.epam.kubernetes_intensive.dao.PostRepository;
import com.epam.kubernetes_intensive.model.Post;
import lombok.extern.log4j.Log4j;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.fa... |
from django.db import transaction
from django.shortcuts import get_object_or_404
from djoser.serializers import UserSerializer
from drf_extra_fields.fields import Base64ImageField
from rest_framework import serializers
from rest_framework.validators import UniqueTogetherValidator
from recipes.models import (Favorite, ... |
<?xml version="1.0" encoding="utf-8"?>
<html xmlns:MadCap="http://www.madcapsoftware.com/Schemas/MadCap.xsd" MadCap:lastBlockDepth="6" MadCap:lastHeight="12224" MadCap:lastWidth="1220">
<head>
<link href="../Resources/Stylesheets/help_ie.css" rel="stylesheet" type="text/css" />
</head>
<body>
... |
---
title: Aspose.Cells を使用して Word Art の透かしをワークシートに追加する
type: docs
weight: 10
url: /ja/java/add-word-art-watermark-to-worksheet-using-aspose-cells/
---
## **Aspose.Cells - Word アートの透かしをワークシートに追加**
ワードアートを使用して、スプレッドシートに特殊なテキスト効果を追加します。たとえば、タイトルをファイルの上部に広げたり、テキストを装飾したり、テキストをプリセットの形状に合わせたり、テキストを背景の透かしとして Excel シートに適用したりで... |
"use client";
import React, { useEffect, useState } from "react";
import { createNitterLink } from "../lib";
import ListItem from "./ListItem";
import SubsForm from "./SubsForm";
import { useRouter } from "next/navigation";
import { removeFeedSubscription, deleteFeed } from "@/lib/api";
import { UserFeedsResponse } fro... |
import { createApp } from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'
import "bootstrap/dist/css/bootstrap.min.css"
import "bootstrap"
import { DropDown } from 'vue3-dropper';
import 'vue3-dropper/dist/base.css';
import Vue3ConfirmDialog from 'vue3-confirm-dialog';
import... |
package at.srfg.kmt.ehealth.phrs.i18n;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.net.URL;
import java.net.URLConnection;
import java.util.Enumeration;
import java.util.Locale;
import java.util.PropertyResourceBundle;
import java.util.ResourceBundle;
import j... |
<?php
declare(strict_types=1);
namespace app\common\service;
use think\facade\Cache;
class WeChat
{
private $appId;
private $appSecret;
public function __construct($appId, $appSecret)
{
$this->appId = $appId;
$this->appSecret = $appSecret;
}
public function getSignPackage()... |
import { Injectable } from '@angular/core';
import { Observable, of } from 'rxjs';
import { GeneratePassword } from './generate-password';
@Injectable({
providedIn: 'root'
})
export class GeneratePasswordService {
options = [
{
"id": "letters",
"library": "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOP... |
package br.com.fiapsoat.presenters.dto;
import br.com.fiapsoat.entities.enums.StatusDoPagamento;
import br.com.fiapsoat.entities.pagamento.ConfirmacaoPagamento;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
@Data
public class ConfirmacaoPagamentoDTO {
@Schema(description = "Número retorn... |
import React, { useState , useRef} from 'react'
import { useDispatch, useSelector } from "react-redux";
import axios from "axios"
import { useNavigate } from 'react-router-dom'
import { useForm } from 'react-hook-form';
import { yupResolver } from '@hookform/resolvers/yup';
import {userLogin} from "../../features/auth... |
import streamlit as st
from ucimlrepo import fetch_ucirepo
import joblib
import numpy as np
clf = joblib.load("clf.joblib")
aids_clinical_trials_group_study_175 = fetch_ucirepo(id=890)
X = aids_clinical_trials_group_study_175.data.features
aids_variables = aids_clinical_trials_group_study_175.variables
n_variables... |
/***********************************************************************
* File : Board.cpp
* Author : 鐘詩靈 B11115010
* 陳仕興 B11115011
* 魏美芳 B11115014
* Create Date : 2023-05-08
* Editor : 鐘詩靈 B11115010
* 陳仕興 B11115011
* 魏美芳 B11115014
* Update Date : 2023-05-17
* Description : This C++ progr... |
<?php
namespace App\Controller;
use App\Entity\Recipe;
// use App\Entity\User;
use App\Form\RecipeType;
use DateTimeImmutable;
use App\Repository\RecipeRepository;
use Doctrine\ORM\EntityManagerInterface;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\JsonRespon... |
<!DOCTYPE html>
<html>
<head>
<title>Routing</title>
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/angularjs/1.3.3/angular.min.js"></script>
</head>
<body ng-app="MyApp">
<nav>
<a href="#/page1">About Us</a>
<a href="#/page2">Our Services</a>
<a href="#/page3">Contact Us</a>
<n... |
/* The PyMem_ family: low-level memory allocation interfaces.
See objimpl.h for the PyObject_ memory family.
*/
#ifndef Py_PYMEM_H
#define Py_PYMEM_H
#include "pyport.h"
#ifdef __cplusplus
extern "C" {
#endif
/* BEWARE:
Each interface exports both functions and macros. Extension modules should
use the f... |
"""Models for Cupcake app."""
from flask_sqlalchemy import SQLAlchemy
db = SQLAlchemy()
DEFAULT_IMAGE = "https://thestayathomechef.com/wp-content/uploads/2017/12/Most-Amazing-Chocolate-Cupcakes-1-small.jpg"
class Cupcake(db.Model):
"""Available Cupcakes Model"""
__tablename__ = "cupcakes"
id = db.Colum... |
<template>
<div>
<div v-if="myCounter === 11 && !submitted">
<b-jumbotron class="myjumbo">
You Scored {{ numCorrect }} / {{ numTotal }}
<div>
<b-button @click="reload" variant="primary">Retry</b-button>
<a href="/">
<b-button>Home</b-button>
</a>
... |
import { PDFDocument, rgb } from "pdf-lib";
import { ExpenseInfo } from "./App";
// ghetto debug mode
const DEBUG = false;
export const OFFSETS = {
NAME: [310, 720],
COMMITTEE_AND_EVENT: [310, 635],
PURPOSE: [310, 574],
AMOUNT: [310, 513],
DATE_RECEIPT: [440, 450],
DATE_TODAY: [440, 385],
SIGNATURE_RECI... |
# Ansible Role: Qemu
[](https://github.com/skaary/ansible-role-qemu/actions?query=workflow%3Ci)
An Ansible Role that installs [Qemu](https://www.qemu.org) on Linux.
## Installation
Download the role directly f... |
import { Board, Engine, Result, VerticalHandler, HorizontalHandler } from './sudoku';
const easy: Board = new Board([
9, 0, 6, 3, 4, 0, 8, 1, 0,
0, 5, 1, 7, 0, 0, 3, 0, 0,
4, 7, 0, 0, 9, 1, 0, 0, 5,
0, 0, 0, 9, 0, 3, 0, 0, 2,
0, 0, 2, 0, 8, 7, 0, 0, 0,
1, 0, 7, 2, 0, 0, 6, 0, 0,
0, 8, 5, ... |
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" c... |
import { HttpException, Inject, OnModuleInit } from '@nestjs/common'
import { ClientGrpc, MessagePattern } from '@nestjs/microservices'
import { CreateUserServiceResponse, UserRPCService } from '@telman/protobuf/user'
import { RPCServicesEnum } from '@telman/rpc-connector'
import { firstValueFrom } from 'rxjs'
import ... |
import { StyleSheet, View, FlatList, ActivityIndicator } from "react-native";
import React from "react";
import { Stack, useLocalSearchParams } from "expo-router";
import Colors from "@/src/constants/Colors";
import { Text } from "@/src/components/Themed";
import { useColorScheme } from "@/src/components/useColorScheme... |
def does_clinic_have_free_space():
return Vet.space > 0
class Vet:
animals = list()
space = 5
def __init__(self, name):
self.name = name
self.animals = list()
def does_animal_exist(self, animal_name):
return animal_name in self.animals
def register_animal(self, anima... |
package com.example.blogwithsecurity.Config;
import com.example.blogwithsecurity.Services.UsersDetailsService;
import lombok.RequiredArgsConstructor;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.security.authentication.dao.D... |
<?php
/**
* Copyright (c) Enalean, 2022 - Present. All Rights Reserved.
*
* This file is a part of Tuleap.
*
* Tuleap is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
... |
package com.practice.simpleWeb.Security;
import com.practice.simpleWeb.Repository.RefreshTokenRepository;
import lombok.RequiredArgsConstructor;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.security.config.annotation.web.bui... |
using Elsa.Mediator.Contexts;
using Elsa.Mediator.Contracts;
using Elsa.Mediator.Middleware.Command.Contracts;
namespace Elsa.Mediator.Middleware.Command.Components;
/// <summary>
/// A command middleware that invokes the command.
/// </summary>
public class CommandHandlerInvokerMiddleware : ICommandMiddleware
{
... |
import cucumber.api.java.en.Given;
import cucumber.api.java.en.Then;
import cucumber.api.java.en.When;
import org.apache.log4j.Logger;
import org.junit.Assert;
public class Steps {
private static Logger logger = Logger.getLogger(Steps.class);
String providedValue;
String resultValue;
@Given("^I have... |
import { Component, Input, OnDestroy, OnInit } from '@angular/core';
import { FormBuilder, FormGroup } from '@angular/forms';
import { MoviesService } from '../../services/movies.service';
import { Router } from '@angular/router';
import { Observable, Subject, takeUntil, tap } from 'rxjs';
import { Movie } from '../../... |
import React from "react";
import { useEffect, useState } from "react";
import Logo from "../Logo";
import TodayBox from "../../components/MainPage/TodayBox";
import axios from "axios";
import { useNavigate } from "react-router-dom";
interface Props {
toggleMainVisibility: () => void;
}
interface spot {
spotName:... |
'use strict';
// // Data needed for a later exercise
// const flights =
// '_Delayed_Departure;fao93766109;txl2133758440;11:25+_Arrival;bru0943384722;fao93766109;11:45+_Delayed_Arrival;hel7439299980;fao93766109;12:05+_Departure;fao93766109;lis2323639855;12:30';
// Data needed for first part of the section
// const... |
import hmac
import hashlib
import json
from functools import wraps
from werkzeug.exceptions import Unauthorized
class Signature:
"""
参考腾讯云接口鉴权 https://cloud.tencent.com/document/product/214/1526
t = time.time()
secret_id, action = 'wechat_personal', 'send_user_feedback'
signature =... |
#PEARSON'S CORRELATION TEST ON STANDARDIZED DATA
# SETUP ----
# Libraries
library(GGally) #for nice correlation plots
library(cowplot)
# Local directories
plot.dir <- "plots"
models_path <- "data/results/full"
# Load data produced in covariate ordination plot
fit.df <- fst::read_fst(paste0(models_path, "/freeflow_da... |
package com.example.aichatbot;
import androidx.annotation.NonNull;
import androidx.appcompat.app.AppCompatActivity;
import androidx.recyclerview.widget.LinearLayoutManager;
import androidx.recyclerview.widget.RecyclerView;
import android.os.Bundle;
import android.view.View;
import android.widget.EditText;
import andr... |
package br.edu.iff.jogoforca.dominio.rodada;
import java.util.ArrayList;
import java.util.List;
import br.edu.iff.bancodepalavras.dominio.letra.Letra;
import br.edu.iff.bancodepalavras.dominio.palavra.Palavra;
import br.edu.iff.dominio.ObjetoDominioImpl;
public class Item extends ObjetoDominioImpl
{
//ATRIBUTOS
... |
Docker
- Create a docker file
- Build the docker file to create an image
- Veify image
- Inspect image
- Push image to repository
- Run image
- Pull image
- Check status with [docker ps]
Docker Components
Docker components include
Docker daemon
Docker client
Docker Objects
Images
Containers / Services
Network
... |
import { PromisePool } from "@supercharge/promise-pool";
import {
STATUT_CREATION_ORGANISME,
STATUT_FIABILISATION_COUPLES_UAI_SIRET,
STATUT_FIABILISATION_ORGANISME,
} from "shared";
import { createOrganisme, findOrganismeById } from "@/common/actions/organismes/organismes.actions";
import { STATUT_PRESENCE_REFER... |
import { IsEnum, IsInt, IsOptional, IsString } from 'class-validator';
import { JanusRequestEvent } from '../constants/janus-request-event';
import { CreateGameRoomDto } from '../dto';
export class CreateJanusRoomDto {
@IsEnum(JanusRequestEvent)
request: JanusRequestEvent;
@IsInt()
publishers: number;
@IsO... |
import { createContext, useReducer } from "react";
export const themeContext = createContext();
const initialState = { darkMode: false };
const themeReducer = (state, action) => {
switch (action.type) {
case "toggle":
return { darkMode: !state.darkMode };
default:
return state;
}
};
ex... |
ANALYZING TOP WEBSITE PAGES & ENTRY PAGES
Basic SELECT *:
SELECT * FROM website_pageviews
WHERE website_pageview_id < 1000
Identifying all the pageview URL visits for a single user:
SELECT * FROM website_pageviews
WHERE website_session_id = 6
Selecting the volume of visits for each webpage:
SE... |
{{!--
The UiTable is designed as a layer-cake of controls whose output is fed to the
input of the next tier down.
--}}
<div
class="ui-table"
role="region"
aria-describedby="{{concat this.tableGuid '-description'}}"
>
<UiSorter @records={{this.records}} as |Sorter|>
<UiFilter
@records={{Sorter.sortedRe... |
/// Unconditionally stops execution.
///
/// # Parameters:
/// - message: A description of the error to write to the standard error of a hosted environment
/// before terminating the program. The default is an empty string.
/// - file: The file name to print with `message`. The default is the file where this fu... |
package com.example.scipubwatch.logic;
import org.openqa.selenium.By;
import org.openqa.selenium.JavascriptExecutor;
import org.openqa.selenium.WebElement;
import org.openqa.selenium.firefox.*;
import org.openqa.selenium.support.ui.WebDriverWait;
import java.util.ArrayList;
import java.util.List;
import static org.o... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.