text
stringlengths
184
4.48M
<?php use Illuminate\Database\Schema\Blueprint; use Illuminate\Database\Migrations\Migration; class CreateMatchTeamPivotTable extends Migration { /** * Run the migrations. * * @return void */ public function up() { Schema::create('match_team', function (Blueprint $table) { ...
import Vue from 'vue'; import {Button} from '../components/common/Button'; import {PlayerInputModel} from '../models/PlayerInputModel'; import {Party} from '../components/Party'; import {TranslateMixin} from './TranslateMixin'; import {PartyName} from '../turmoil/parties/PartyName'; export const SelectPartyToSendDeleg...
--- permalink: nas-audit/display-connections-external-fpolicy-servers-task.html sidebar: sidebar keywords: display, information, connections, external fpolicy servers summary: 您可以显示有关与集群或指定 Storage Virtual Machine ( SVM )的外部 FPolicy 服务器( FPolicy 服务器)连接的状态信息。此信息可帮助您确定连接了哪些 FPolicy 服务器。 --- = 显示有关连接到外部 FPolicy 服务器的信息...
//This class represents a box with a width, height, and depth. //The variable grade is a measure of the thickness of the cardboard //used to construct the box. public class Box2 { private int width, height, depth, grade; // class constructor public Box2(int width, int height, int depth, int grade) { ...
/* * Original Author -> Harry Yang (taketoday@foxmail.com) https://taketoday.cn * Copyright © TODAY & 2017 - 2022 All Rights Reserved. * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Publi...
--- title: LiquidCrystal_I2C layout: ardbiblio --- # LiquidCrystal_I2C Traducció de <https://github.com/mrkaleArduinoLib/LiquidCrystal_I2C> #### **Contingut** - [Introducció](#introducció) - [Crèdits](#crèdits) - [Dependencia](#dependencia) - [Interfície](#interfície) ## Introducció És la reimplementació de la bi...
`timescale 1ns/10ps module neg_tb; reg PCout, Zlowout, MDRout, R2out, R3out; // add any other signals to see in your simulation reg MARin, Zlowin, PCin, MDRin, IRin, Yin; reg IncPC, Read, NEG, R1in, R2in, R3in; reg clock, clear; reg [31:0] Mdatain; parameter Default = 4'b0000, Reg_load1a = 4'...
doctype html html(lang='en') head meta(charset='utf-8') title Office Shop meta(name='viewport', content='width=device-width, initial-scale=1.0') meta(name='description', content='') meta(name='author', content='') // Bootstrap styles link(href='assets/css/bootstrap.css', rel='stylesheet') ...
package xyz.xzaslxr.guidance; import edu.berkeley.cs.jqf.fuzz.guidance.Guidance; import edu.berkeley.cs.jqf.fuzz.guidance.GuidanceException; import edu.berkeley.cs.jqf.fuzz.guidance.Result; import edu.berkeley.cs.jqf.fuzz.guidance.TimeoutException; import edu.berkeley.cs.jqf.fuzz.util.Coverage; import edu.berkeley.cs....
import 'package:flutter/material.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart'; import 'package:test_pt_seru/presentation/components/widgets/widgets.components.dart'; class LocationField extends StatelessWidget { final Future<List<String>> Function(int, String)? items; final List<String>? sele...
/* * Lumeer: Modern Data Definition and Processing Platform * * Copyright (C) since 2017 Lumeer.io, s.r.o. and/or its affiliates. * * 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 ...
<?php /* * phpcs:disable WordPress.Security.NonceVerification.Recommended * phpcs:disable WordPress.Security.NonceVerification.Missing * phpcs:disable WordPress.Security.ValidatedSanitizedInput.InputNotSanitized: */ use RT\ThePostGrid\Helpers\Fns; $current_post_id = ''; if ( ! empty( $_GET['pid'] ) ) { $current_...
import 'dart:async'; import 'dart:convert'; import 'dart:typed_data'; import 'package:flutter/material.dart'; import 'package:flutter_bluetooth_serial/flutter_bluetooth_serial.dart'; class ChatPage2 extends StatefulWidget { final BluetoothDevice server; const ChatPage2({required this.server}); @override _Ch...
from fastapi import FastAPI, status from fastapi.middleware.cors import CORSMiddleware import uvicorn from log import logger from config import global_settings from tasks import apscheduler_tasks from user.routers.crud import router as user_crud_router from user.routers.actions import router as user_actions_router fro...
package stream.input; import java.io.BufferedOutputStream; import java.io.File; import java.io.FileNotFoundException; import java.io.FileOutputStream; import java.io.IOException; import java.io.OutputStream; import javax.crypto.Cipher; import logic.FSPasswordHash; import logic.FileElement; /** * Class specialized ...
import { Provide } from '@midwayjs/decorator'; import { makeHttpRequest } from '@midwayjs/core'; import { WeatherInfo } from '../interface'; import { WeatherEmptyDataError } from '../error/weather.error'; // 这里使用 @Provide 装饰器修饰类,便于后续 Controller 注入该类 @Provide() export class WeatherService { async getWeather(cityId: s...
# Copyright (C) 2009 Greenbone Networks GmbH # Some text descriptions might be excerpted from (a) referenced # source(s), and are Copyright (C) by the respective right holder(s). # # SPDX-License-Identifier: GPL-2.0-or-later # # This program is free software; you can redistribute it and/or # modify it under the terms o...
--- title: "Dijkstra's Algorithm" tags: - Algorithms - Graphs --- # Dijkstra's Algorithm ## 1. Problem Statement Given a graph and a source vertex in the graph, find shortest paths from source to all vertices in the given graph. - NOTE : If graph is a **DAG**, then simply do [[topo-sort|Topological Sort]] ...
package org.lt.project.service; import org.apache.commons.io.input.Tailer; import org.apache.commons.io.input.TailerListener; import org.lt.project.core.result.ErrorResult; import org.lt.project.core.result.Result; import org.lt.project.core.result.SuccessResult; import org.lt.project.entity.SuspectIPEntity; import or...
//Abstraction Typescript abstract class Character { public name: string; public damage: number; public attackSpeed: number; constructor(name: string, damage: number, speed: number) { this.name = name; this.damage = damage; this.attackSpeed = speed; } public abstract dam...
<template> <div class="content"> <div class="content-top"> <el-input class="searchClass" v-model="keyword" @input="handleSearchKey" placeholder="搜索周边" :suffix-icon="Search" /> </div> <div class="search-box"> <var-tabs elevation colo...
<!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://font...
document.addEventListener("DOMContentLoaded", function () { const dynamicForm = document.getElementById("dynamicForm"); const numFieldsSelect = document.getElementById("numFields"); const inputContainer = document.getElementById("inputContainer"); numFieldsSelect.addEventListener("change", functio...
// // RideDetailViewModel.swift // Edvora_Test // // Created by Rahul Chaturvedi on 19/03/22. // import Foundation struct Item { var title: String var value: String } class RideDetailViewModel { var ride: Ride init(ride: Ride) { self.ride = ride } func getDetailStacks() -> [It...
import 'dart:developer' as devtools show log; import 'package:firebase_core/firebase_core.dart'; import 'package:flutter/material.dart'; import 'package:hooks_riverpod/hooks_riverpod.dart'; import 'firebase_options.dart'; import 'state/auth/providers/is_logged_in_provider.dart'; import 'state/providers/is_loading_pro...
import { List, ListItem, Typography, TextField, Button, Link, } from '@material-ui/core'; import axios from 'axios'; import { useRouter } from 'next/router'; import { getError } from '../utils/error'; import React, { useContext, useEffect } from 'react'; import Layout from '../components/Layout'; import { S...
// @flow import type {AST, Environment, MutableAsset} from '@parcel/types'; import PostHTML from 'posthtml'; // A list of all attributes that may produce a dependency // Based on https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes const ATTRS = { src: [ 'script', 'img', 'audio', 'video', ...
## 뉴스 내용 요약 및 중복제거 from openai import OpenAI import snowflake.connector from snowflake.connector.pandas_tools import pd_writer from snowflake.connector.pandas_tools import write_pandas import os import pandas as pd def summary_api(): # db 접근 ## 접속 인자 snow_conn = snowflake.connector.connect( user=o...
# TABLEAU DE BORD SODECOTON - CAMEROUN V01 -2020. Auteur : Samuel Talle #--chargemement des librairies-------------------------------------------- library(shiny) library(shinydashboard) library(RMariaDB) library("DBI") library(RODBC) library(lattice) library(ggplot2) library(tidyverse) library(dplyr) require(gr...
import 'package:flutter/material.dart'; import 'package:cometchat_uikit_shared/cometchat_uikit_shared.dart'; ///[BaseStyles] is the base style class for most style classes provided by [CometChatUIKit] /// /// ```dart /// /// BaseStyles( /// width: 100.0, /// height: 50.0, /// background: Colors.blue, /// gradi...
import java.util.Random; import java.util.Scanner; // basic hero class // can be extended to specific hero type // hp = level*100 // level up mp = 1.1*mp // atk = (strength + weapon)*0.05 // dodge = agility*0.02 // exp required = level*10 public abstract class Hero extends Role { protected int experience; // curre...
--- title: "Open Government Data, opendata.swiss" date: "2023-08-23" output: html_document --- ## Dataset: Umzüge innerhalb der Stadt nach Herkunft, seit 1971 Anzahl Umzüge innerhalb der Stadt Zürich nach Herkunft und Jahr, seit 1971. [Direct link by **opendata.swiss** for dataset](https://opendata.swiss/de/datase...
import { toastHelper } from '@/helpers/toast-helper' import axios from '@/lib/axios' import { create } from 'zustand' interface State { logo: string | null getLogo: () => Promise<void> updateLogo: (file: File) => Promise<void> } const useConfigStore = create<State>()((set) => ({ logo: null, getLogo: async (...
import { MouseEventHandler, ReactNode, RefObject } from 'react'; import { IconType } from 'react-icons'; export interface DataType extends OptionBase { isDisabled?: boolean; label: string; value: string; icon?: string; chainId: string; chainRoute?: string; } export interface ChooseChainInfo { chainName:...
import { doc, onSnapshot } from "firebase/firestore"; import React, { useState } from "react"; import { useEffect } from "react"; import { db } from "../firebase"; /** * * @param {string} collectionName * @param {string} documentId * @returns {{document: Object | null, error: Error | null}} */ export const useDoc...
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> </head> <body> <my-paragraph> <span slot="text-contents">Text Contents</span> </my-paragraph> <my-paragraph></my-paragraph> <template my-paragraph> <p class="title">My Paragraph</p> <p><slot name="text-contents">Nothing...
@extends('layouts.material') @section('menuLateral') @include('inventario.menuLateral') @endsection @section('contenido') <div class="row"> <div class="col-md-12"> <div class="card"> <div class="card-header card-header-success"> <div class="row"> ...
import UIKit import CoreData class CategoryViewController: UITableViewController { var categories = [Category]() let customAlert = CustomAlert() let context = CoreDataHelper.shared.persistentContainer.viewContext override func viewDidLoad(){ super.viewDidLoad() setupUI() ...
from fastapi import Depends from sqlalchemy import Column, Date, Integer, String, ForeignKey, Sequence, Enum from sqlalchemy.orm import relationship, backref from DataBase import Base, get_db class User(Base): __tablename__ = 'users' id = Column(Integer, Sequence('user_id_seq', start=1), primary_key=True) ...
import os import pandas as pd class DataExtractor: def __init__(self, files, young_person_file='young_person.txt'): self.files = files self.valid_files = [] for file in files: if os.path.exists(file): self.valid_files.append(file) self.young_person_file ...
/* * RealmSpeak is the Java application for playing the board game Magic Realm. * Copyright (c) 2005-2015 Robin Warren * E-mail: robin@dewkid.com * * 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 Foun...
const express = require('express'); const pool = require('../config.js') const { isLoggedIn } = require('../middleware/index.js') const Joi = require('joi') router = express.Router(); const commentOwner = async (req, res, next) => { if (req.user.role === 'admin') { return next() } const [[comment]] = await ...
const express = require('express'); const bcrypt = require('bcryptjs'); const jwt = require('jsonwebtoken'); const keys = require('../config/keys'); const validateRegisterInput = require('../validation/register'); const validateLoginInput = require('../validation/login'); const User = require('../models/User'); const...
import { HardhatRuntimeEnvironment } from "hardhat/types"; import { Contracts } from "./Contracts"; type Account = ReturnType<typeof web3.eth.accounts.privateKeyToAccount>; export async function switchToProductionMode( hre: HardhatRuntimeEnvironment, contracts: Contracts, deployerPrivateKey: string, g...
import React, { FC } from "react"; import styles from "./slugpage.module.css"; import Image from "next/image"; import Menu from "../components/menu"; import CommentSection from "../components/comments"; import BlogContent from "../components/BlogContent"; import BlogItem from "../components/RelatedBlog/BlogItem"; impor...
package com.restaurant.orderservice.web; import javax.validation.Valid; import com.restaurant.orderservice.domain.Order; import com.restaurant.orderservice.domain.OrderService; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import reactor.core.publisher.Flux; import reactor.core.publisher.Mono; import org....
import * as vscode from 'vscode'; import * as fs from 'fs'; import * as path from 'path'; function readHideList(workspacePath: string): RegExp[] { const hideListPath = path.join(workspacePath, '.hideme'); try { const hideListContent = fs.readFileSync(hideListPath, 'utf8'); return hideListContent .split('\n') ...
import { CommandHandler, ICommandHandler } from '@nestjs/cqrs'; import { UserDto } from '@subscribely/contracts'; import { LoggerService } from '@subscribely/core'; import { UserNotFoundException } from '@subscribely/exceptions'; import { UserRepository } from '../../repositories'; import { DeleteUserCommand } from '...
<!DOCTYPE html> <html> <head> <title>Lession 5 Challenge</title> <meta charset="UTF-8" /> <script src="https://fb.me/react-0.14.7.js"></script> <script src="https://fb.me/react-dom-0.14.7.js"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/babel-core/5.8.2/browser.min.js"></script> <link rel="sty...
from django.shortcuts import render, redirect from django.contrib.auth.decorators import login_required from django.contrib import messages from django.shortcuts import get_object_or_404 from django.http import JsonResponse from django.views.decorators.http import require_POST from django.http import HttpResponse from ...
import { GetDiceRoll, GetRandomBetween } from "../dice.js"; import { Room } from "./room.js"; import { Level } from "./level.js"; import { Tile } from "./tile.js"; export class SimpleLevelBuilder { newLevel({ height, width, min = 3, max = 10, rooms = 40 }) { const level = new Level({ height, width }); level...
import React from 'react'; import { connect, ConnectedProps } from 'react-redux'; import { Paper, Fab, Box, Grid } from '@material-ui/core'; import { Theme, createStyles, WithStyles, withStyles } from '@material-ui/core/styles'; import { Pagination, Skeleton } from '@material-ui/lab'; import { A...
import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:my_app/pages/settings/widgets/should_delete.dart'; import 'package:my_app/services/services.dart'; import '../widgets/text_form_field.dart'; class ProfilePage extends StatelessWidget { final _formKey = GlobalKe...
# Multiple Producers and Multiple Consumers, same Topic Apache Kafka is a distributed streaming platform that allows you to publish and subscribe to streams of records, store those records in a fault-tolerant manner, and process them. In Kafka, you can have multiple producers and consumers communicating through topics...
# %% import numpy as np import pandas as pd import seaborn as sns import matplotlib.pyplot as plt from multi_variable_loess import fit, single_variable_fit # %% def función_sintética(x,funcion,varianza): if funcion == 1 : return (1/np.sqrt(2))* x + np.sqrt(5) + np.random.normal(loc = 0.0, scale = varianza...
import java.util.ArrayList; public class OddEvenList { public static void main(String[] args) { Solution solution = new Solution(); int arr[] = new int[] { 10, 20, 30, 40, 50, 60 }; Node head = new Node(arr[0]); Node cur = head; for (int i = 1; i < arr.length; i++) { ...
#' Calculation of the variance-covariance matrix for a specified survey design (experimental function) #' #' @param vcovMat a variance-covariance matrix. #' @param estfun a gradient function of the log-likelihood function. #' @param design a \code{survey.design} object. #' @description #' This function is an equivalent...
package com.ichi2.anki.tests; import android.Manifest; import android.content.SharedPreferences; import androidx.annotation.StringRes; import androidx.test.annotation.UiThreadTest; import androidx.test.rule.GrantPermissionRule; import com.ichi2.anki.AnkiDroidApp; import com.ichi2.anki.R; import org.acra.ACRA; impor...
import HomeView from '@/views/HomeView.vue' import AboutView from '@/views/AboutView.vue' import { createRouter, createWebHistory } from 'vue-router' const routes = [ { path: '/', name: 'home', component: HomeView, meta: { title: 'Home', }, }, { path: '/about', name: 'about', ...
import React, { useEffect, useState } from "react"; import { apiBaseUrl } from "../../index.js"; export default function Users() { const [users, setUsers] = useState([]); const [loading, setLoading] = useState(true); useEffect(() => { fetch(apiBaseUrl + "users", { method: "GET", }) .then((re...
import { Action } from "redux"; import { NormalizedObjects } from "../../store/normalized-objects"; import { User } from "./user-state"; export enum UserActionTypes { LOAD_USERS_INIT = "Users__LoadUsersInit", LOAD_USERS_SUCCESS = "Users__LoadUsersSuccess", GET_USER = "Users__GetUser", GET_USER_SUCCESS = "Users...
<template> <div> <navbar /> <main class="day-review-list-wrapper"> <div class="review-type">여정 일기</div> <div class="review-list-header"> <div class="review-list-header-item review-list-header-title">제목</div> <div class="review-list-header-item">작성자</div> <div class="review-...
import React from "react"; import { PersonalInfo } from "../../../models/personal-info"; import { FinancialInfo } from "../../../models/financial-info"; // @todo - Can we use the actual machine context here? type Context = { personalInfo: PersonalInfo; financialInfo: FinancialInfo }; export type TipType = | "credit...
import React, { useState, useContext } from 'react'; import { TaskContext } from './taskcontext'; // Import TaskContext const AddTask = () => { const { tasks, setTasks } = useContext(TaskContext); const [task, setTask] = useState(''); const [dueDate, setDueDate] = useState(null); // Optional for date input co...
import {expect} from 'chai'; import {describe, beforeEach, afterEach, it} from 'mocha'; import NumbersValidator from '../../app/numbers_validator.js'; describe('getEvenNumbersFromArray', () => { let validator; beforeEach(() => { validator = new NumbersValidator(); }); afterEach(() => { validator = nul...
class Compute { public String isSubset( long a1[], long a2[], long n, long m) { HashMap<Long, Integer> frequencyMap1 = new HashMap<>(); // Create a frequency map of elements in array a1 for (long num : a1) { frequencyMap1.put(num, frequencyMap1.getOrDefault(num, 0) + 1); ...
package uni.UNIA088341; import io.dcloud.uniapp.*; import io.dcloud.uniapp.extapi.*; import io.dcloud.uniapp.framework.*; import io.dcloud.uniapp.runtime.*; import io.dcloud.uniapp.vue.*; import io.dcloud.uniapp.vue.shared.*; import io.dcloud.unicloud.*; import io.dcloud.uts.*; import io.dcloud.uts.Map; import io.dclou...
s3napback: Cycling, Incremental, Compressed, Encrypted Backups on Amazon S3 Manual for version 1.0 2008-05-07 Copyright (c) 2008 David Soergel <dev@davidsoergel.com> The problem ----------- In searching for a way to back up one of my Linux boxes to Amazon S3, I was surprised to find that none of the many backup m...
<script setup> import { onMounted, ref } from 'vue' import axios from 'axios' import cartMethods from "@/utils/cart"; const cart = ref([]) const isLoaded = ref(false) const getWishList = async () => { isLoaded.value = false const response = await axios.get('http://localhost:8000/api/wishlist/', { headers: { ...
#include "twig_hardware/twig_lib.hpp" twig_hardware::TwigLib::TwigLib(int i2c_bus, int i2c_address, std::string i2c_device) : i2c_bus(i2c_bus), i2c_address(i2c_address), i2c_device(i2c_device) { } twig_hardware::TwigLib::~TwigLib() { i2c_close_connection(); } // I2c bool twig_hardware::TwigLib::i2c_open_connectio...
from flask import Flask from flask_sqlalchemy import SQLAlchemy from flask_bcrypt import Bcrypt from flask_login import LoginManager from flask_mail import Mail from flask_blog.config import DevelopmentConfig, TestingConfig from flask_migrate import Migrate from flask_pagedown import PageDown from flask_bootstrap impor...
#include <stdio.h> #include <stdlib.h> #include <string.h> int n_entered = 0; void get_input(int *n, double arr[][*n]) { if (n_entered == 0) { printf("Enter n: "); scanf("%d", n); n_entered++; } if (arr != NULL) { printf("Enter the elements of the array:\n"); ...
import {{pascalCase schemaName}}, { {{pascalCase schemaName}}Attributes } from '@modules/{{camelCase moduleName}}/infra/mongoose/schemas/{{pascalCase schemaName}}.schema' import I{{pascalTableName}}, { CreateProps, FindByIdProps, UpdateProps, DeleteProps } from '@modules/{{camelCase moduleName}}/repositories/interfaces...
use uo; include "include/dotempmods"; exported function GetLifeRegenRate (character) // 1 point per 5 seconds // ... is 12 points per minute // ... is 1200 hundredths per minute //No regen if poisoned if (character.poisoned) return 0; endif //NPCs regenerate faster if they have more HP if (!character.acct...
import React, { useState } from "react"; import { useQuery, useMutation } from "@apollo/client"; import { GET_GOALS } from "../utils/queries"; import { CREATE_GOAL } from "../utils/mutations"; import AuthService from "../utils/auth"; import '../assets/Goal.css'; function GoalManagement() { const [goalInput, setGoalI...
import { ReactNode, useEffect, useState } from 'react'; import { SortableContainer, SortableElement, SortableHandle, arrayMove, } from 'react-sortable-hoc'; import { Space } from 'antd'; import './index.less'; const DragHandle = SortableHandle(() => ( <i className="iconfont spicon-drag2 core-form-drag-list-i...
const detectEndpoint = async (force = false) => { const endpoint = sessionStorage.getItem("endpoint"); if (!endpoint || force) { const myHeaders = new Headers(); myHeaders.append("accept-language", "pt-BR,pt;q=0.9,en-US;q=0.8,en;q=0.7,ru;q=0.6"); myHeaders.append("cache-control", "no-cac...
const API_KEY = 'api_key=3646c928b1d09ad843c146504a0749e0'; const BASE_URL = 'https://api.themoviedb.org/3'; const API_URL = BASE_URL + '/discover/movie?sort_by=popularity.desc&'+API_KEY; const IMG_URL = 'https://image.tmdb.org/t/p/w500'; const SEARCH_URL = BASE_URL + '/search/movie?'+API_KEY const main = document.get...
import discord from discord.ext import commands import random # Cogs are used to make categories col = discord.Color.purple() class Actions(commands.Cog): def footer(self): return f"!help fun [command] for more information" @commands.group() async def fun(self, ctx): if ctx.invoked...
function renderLicenseBadge(license) { if (license !== "None") { return `![Github license](https://img.shields.io/badge/license-${license}-olive.svg)`; } return ""; } function generateMarkdown(data) { return `# ${data.title} ${renderLicenseBadge(data.license)} ## Description ${data.description} #...
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); const transfer_status_enum_1 = require("../enums/transfer-status.enum"); class ChunkTransferHelper { constructor(io, importStepHelper, transfersRepository) { this.io = io; this.importStepHelper = importStepHelper; t...
--- title: folders section: 5 description: Folder Structures Used by npm --- ### Description npm puts various things on your computer. That's its job. This document will tell you what it puts where. #### tl;dr * Local install (default): puts stuff in `./node_modules` of the current package root. * Global instal...
import React from "react"; import PropTypes from "prop-types"; import classNames from "classnames"; import {Title} from "../components"; class PopupBody extends React.Component { componentDidMount() { if (!this.props.scroll) { document.getElementsByTagName("body")[0].style.overflow = "hidden"; } } componen...
using System.Text; using static Entidades.Llamada; namespace Entidades { public class Centralita : IGuardar<string> { private List<Llamada> listaDeLlamadas; private string razonSocial; private string rutaDeArchivo = Environment.GetFolderPath(Environment.SpecialFolder.Desktop) + @"\cent...
<!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title></title> <style type="text/css"> .classObject{ color:red; } </style> </head> <body> <div id="app"> <my-component v-bind:show="nice" ></my-component> ...
@page "/Task/{id:int}" <h3>TaskPage</h3> @if (State != null && State.Identity.Name != "Anonymous") { @if (task == null && id != -1) { <tr>Loading Data ...</tr> } else { <label for="fname">Заголовок:</label> <input type="text" rows="100" @bind="@task.Title" @bind:event="oninput" placeholder="@task.Title" id...
<html lang="zh-tw"> <!-- Mirrored from www.1keydata.com/css-tutorial/tw/box-model.php by HTTrack Website Copier/3.x [XR&CO'2013], Thu, 22 Aug 2013 15:42:07 GMT --> <head> <title>CSS 盒子模式CSS 語法教學</title> <meta name="description" content="解釋 CSS 內的盒子模式 (Box Model)。"> <link rel="canonical" href="box-model.html" /> <meta ...
from datetime import datetime, timedelta import pytest from django.test.client import Client from django.urls import reverse from django.utils import timezone from news.models import Comment, News from news.pytest_tests.constants import ( AUTHOR_USERNAME, COMMENT_TEXT, NEWS_DELETE, NEWS_DETAIL, NEW...
using System.Runtime.ConstrainedExecution; using System.Runtime.Serialization; using System.Text; using Azure; using Azure.AI.OpenAI; namespace Claire; public class Claire { private class CommandDefinition(string name, string description, Action function) { public readonly string Name = name; ...
import React from "react"; import { useNavigate } from "react-router-dom"; import StyledPopup, { StyledButtons, StyledText, StyledButton, } from "./StyledPopup"; import { useDataLayerValue } from "../../DataLayer"; const Popup = () => { const navigate = useNavigate(); const [{ showPopup }, dispatch] = useDat...
<!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"> <title>Document</title> </head> <body> <script> // 验证二叉搜索树 // https://leetcode-cn.com/problems/v...
import json import logging import os from typing import Any, Optional import boto3 import sagemaker import sagemaker.session from botocore.exceptions import ClientError from sagemaker.huggingface import HuggingFaceModel, get_huggingface_llm_image_uri from sagemaker.workflow.parameters import ParameterString from sagem...
structure AST = struct type id = string datatype binop = Plus | Minus | Times datatype unop = Not | Neg datatype logicop = And | Or | Xor | Implies datatype relop = Equals | LessThan | GreaterThan datatype decl = ValDecl of id * exp and prg = Program of exp*prg | LastExp of exp and exp = NumExp of int ...
import { Inject } from '@nestjs/common'; import { BigNumberish } from 'ethers'; import { APP_TOOLKIT, IAppToolkit } from '~app-toolkit/app-toolkit.interface'; import { PositionTemplate } from '~app-toolkit/decorators/position-template.decorator'; import { DefaultDataProps } from '~position/display.interface'; import {...
const mongoose = require('mongoose') const passportLocalMongoose = require('passport-local-mongoose') const userSchema = new mongoose.Schema({ name: { type: String, required: true, trim: true, minlength: 3, maxlength: 60 }, avatar: { type: String, trim: true }, isDeleted: { ty...
from django.db import models from django.contrib.auth.models import User from django.db.models.signals import post_save class Meep(models.Model): user = models.ForeignKey( User, related_name="meeps", on_delete=models.DO_NOTHING ) body = models.CharField(max_length=200) created_at =...
/* Goal: Lotto Application - Refactoring Number matching and Player functions Synopsis: (1)This game will take 3 players (2) Produce Weekly random Lotto winning numbers (3) Each Player will enter thier numbers for the week. (4) Mathing numbers will bank an amount for player (5) The winner will be the one with the hirs...
import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; import { RegisterPage } from './register.page'; import { Router } from '@angular/router'; import { IonicModule } from '@ionic/angular'; import { AppRoutingModule } from 'src/app/app-routing.module'; describe('RegisterPage', () => { let ...
import { ErrorRequestHandler } from 'express'; export interface ErrorObject { type: | 'unauthorized' | 'forbidden' | 'notFound' | 'conflict' | 'unprocessableEntity'; message: string; } const serviceErrorToStatusCode = { unauthorized: 401, forbidden: 403, notFound: 404, conflict: 409, ...
from langchain.document_loaders import PyPDFLoader from langchain.chat_models.openai import ChatOpenAI from langchain.text_splitter import RecursiveCharacterTextSplitter from langchain.embeddings.openai import OpenAIEmbeddings from langchain.vectorstores.chroma import Chroma from langchain.chains.conversation.memory im...