repo_name stringlengths 6 101 | path stringlengths 4 300 | text stringlengths 7 1.31M |
|---|---|---|
zhangyin2088/Teamcat | teamcat_service/docker_build/target/one_step_build/teamcat/doraemon/project/urlrouter/project_dashboard_urls.py | <reponame>zhangyin2088/Teamcat
#coding=utf-8
# coding=utf-8
'''
Created on 2014-1-5
@author: ETHAN
'''
from django.conf.urls import url
from doraemon.project.views.project_dashboard_view import index_list,more_activites
dashboard_router=[url(r"(\d{1,6})/dashboard/$",index_list),
url(r"(\d{1,6})/das... |
jcleng/nix-kangle-3.5.13.2 | src/src/KReplaceIPMark.h | <filename>src/src/KReplaceIPMark.h
#ifndef KREPLACEIPMARK_H
#define KREPLACEIPMARK_H
#include "KMark.h"
class KReplaceIPMark : public KMark
{
public:
KReplaceIPMark()
{
header = "X-Real-Ip";
val = NULL;
}
~KReplaceIPMark()
{
if (val) {
delete val;
}
}
bool mark(KHttpRequest *rq, KHttpObject *obj,
... |
ShenQianwithC/HistomicsTK | packages/girder_worker/examples/plugin_example/gwexample/__init__.py | from girder_worker import GirderWorkerPluginABC
class GWExamplePlugin(GirderWorkerPluginABC):
def __init__(self, app, *args, **kwargs):
self.app = app
# Here we can also change application settings. E.g.
# changing the task time limit:
#
# self.app.config.update({
# ... |
SoftReaper/Mesa-Renoir-deb | src/compiler/clc/clc.c | /*
* Copyright © Microsoft Corporation
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation
* the rights to use, copy, modify, merge, publ... |
frochet/pquic | picoquic/protoop.c | <reponame>frochet/pquic
#include "protoop.h"
protoop_id_t PROTOOP_PARAM_PARSE_FRAME = { .id = PROTOOPID_PARAM_PARSE_FRAME };
protoop_id_t PROTOOP_PARAM_PROCESS_FRAME = { .id = PROTOOPID_PARAM_PROCESS_FRAME };
protoop_id_t PROTOOP_PARAM_WRITE_FRAME = { .id = PROTOOPID_PARAM_WRITE_FRAME };
protoop_id_t PROTOOP_PARAM_NOT... |
doits/mobility | spec/database.rb | <filename>spec/database.rb
module Mobility
module Test
class Database
class << self
def connect(orm)
case orm
when 'active_record'
::ActiveRecord::Base.establish_connection config[driver]
::ActiveRecord::Migration.verbose = false if in_memory?
... |
MiccWan/dbux | samples/case-studies/async/producer_consumer/producer_consumer_cb.js | import { ConsumerBase, ProducerBase } from './producer_consumer_base';
const sleep = setTimeout;
/**
*
*/
function foreverCb(task) {
function next() {
return task(next);
}
return next();
}
// ###########################################################################
// Consumer
// #####################... |
Neusoft-Technology-Solutions/aws-sdk-cpp | aws-cpp-sdk-appflow/include/aws/appflow/model/ConnectionMode.h | <filename>aws-cpp-sdk-appflow/include/aws/appflow/model/ConnectionMode.h
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/appflow/Appflow_EXPORTS.h>
#include <aws/core/utils/memory/stl/AWSString.h>
namespace Aws
{
namespa... |
inepex/ineform | ineframe/src/main/java/com/inepex/ineFrame/server/di/guice/DefaultApplicationLangs.java | <reponame>inepex/ineform<filename>ineframe/src/main/java/com/inepex/ineFrame/server/di/guice/DefaultApplicationLangs.java<gh_stars>1-10
package com.inepex.ineFrame.server.di.guice;
import java.util.Arrays;
import java.util.Collection;
import com.google.inject.Inject;
import com.inepex.ineFrame.client.i18n.IneFrameI18... |
aulonm/okr-tracker | src/router/router-guards/user.js | <gh_stars>10-100
import { db } from '@/config/firebaseConfig';
import store from '@/store';
const { state } = store;
export default async function RouterGuardUser(to, from, next) {
const { id } = to.params;
if (!id) {
next();
} else {
try {
const { exists } = await db.collection('users').doc(id).... |
atviriduomenys/spinta | spinta/types/object/link.py | <reponame>atviriduomenys/spinta
from spinta import commands
from spinta.components import Context
from spinta.types.datatype import Object
from spinta.types.helpers import set_dtype_backend
@commands.link.register(Context, Object)
def link(context: Context, dtype: Object) -> None:
set_dtype_backend(dtype)
for... |
BKJang/YourHome | front/src/redux/modules/releaseList.js | import { createAction, handleActions } from 'redux-actions';
import { pender } from 'redux-pender';
import * as releaseAPI from '../../lib/api/releaseList';
import { Map, List } from 'immutable';
const CHANGE_CURRENTID = 'orderList/CHANGE_CURRENTID'; //Nav 위치 변경
const CHANGE_CUSTNO = 'orderList/CHANGE_CURRENTNO'; //RE... |
pavaniuriti2000/python_files | challenge.py | #challenge in making_complex_decisions
tax = 0
total = 0
country = input("Enter what country you are from :")
country = country.lower()
total = float(input("Enter total "))
if country == "canada":
province = input("Enter your province ")
province = province.lower()
if province == "alberta":
tax... |
WarpCloud/WALM | pkg/models/release/metainfo_resource_types.go | package release
import (
"github.com/tidwall/gjson"
"github.com/sirupsen/logrus"
"strconv"
"fmt"
"encoding/json"
"WarpCloud/walm/pkg/k8s/utils"
)
type MetaResourceMemoryConfig struct {
IntConfig
}
func (config *MetaResourceMemoryConfig) BuildDefaultValue(jsonStr string) {
config.DefaultValue = config.BuildMe... |
veriKami/ePF_API_doc | ePF_API_doxy-0.2.x-dev/html/classep___senator.js | <filename>ePF_API_doxy-0.2.x-dev/html/classep___senator.js
var classep___senator =
[
[ "__toString", "classep___senator.html#a7516ca30af0db3cdbf9a7739b48ce91d", null ],
[ "getDataStruct", "classep___senator.html#a79dabf680e30ee6e62508a8df24ed243", null ],
[ "komisje", "classep___senator.html#a66895e14014726... |
ehsk/CHF-TopoResolver | src/main/java/tr/util/db/BatchExecutor.java | package tr.util.db;
import java.sql.Connection;
import java.sql.PreparedStatement;
import java.sql.SQLException;
import java.util.function.Consumer;
/**
* Created with IntelliJ IDEA.
* User: user
* Date: 11/11/2016
* Time: 2:26 PM
*/
public class BatchExecutor {
private final String sql;
private final in... |
NASA-AMMOS/MGViz | scripts/essence/Tools/FileManager/FileManagerTool.js | <gh_stars>1-10
define([
'Layers_',
'jquery',
'd3',
'Formulae_',
'Map_',
'Globe_',
'Login',
'CursorInfo',
'shp',
'mark',
], function(L_, $, d3, F_, Map_, Globe_, Login, CursorInfo, shp) {
var userfiles = {}
// prettier-ignore
var markup = [
"<div id='fileManagerTo... |
dosisod/skull | test/skull/common/errors.c | #include <stdbool.h>
#include <stdlib.h>
#include <string.h>
#include "skull/common/str.h"
#include "skull/common/errors.c"
#include "skull/semantic/variable.h"
#include "test/skull/common/errors.h"
#include "test/testing.h"
static bool message_stringify_wrapper(Message *error, const char *expected) {
message_strin... |
schinmayee/nimbus | applications/physbam/physbam-lib/External_Libraries/src/fltk/src/fl_symbols.cxx | <reponame>schinmayee/nimbus<filename>applications/physbam/physbam-lib/External_Libraries/src/fltk/src/fl_symbols.cxx
//
// "$Id: fl_symbols.cxx,v 1.1 2011/12/10 04:53:51 rbsheth Exp $"
//
// Symbol drawing code for the Fast Light Tool Kit (FLTK).
//
// Copyright 1998-2010 by <NAME> and others.
//
// This library is fre... |
igiant/connect | domains.go | package connect
import "encoding/json"
// DeliveryType - Delivery Type
type DeliveryType string
const (
Online DeliveryType = "Online" // deliver online, immediatelly
OfflineScheduler DeliveryType = "OfflineScheduler" // delivery is started by scheduler
OfflineEtrn DeliveryType = "Offline... |
dji-sdk/DJI-Cloud-API-Demo | src/main/java/com/dji/sample/common/error/CommonErrorEnum.java | <gh_stars>1-10
package com.dji.sample.common.error;
/**
* @author sean.zhou
* @version 0.1
* @date 2021/11/25
*/
public enum CommonErrorEnum implements IErrorInfo {
SYSTEM_ERROR(600500, "system error"),
SECRET_INVALID(600100, "secret invalid"),
NO_TOKEN(600101, "accss_token is null"),
TOKEN_EXP... |
ggear/cloudera-framework | cloudera-framework-common/src/main/java/com/cloudera/framework/common/util/DfsUtil.java | <reponame>ggear/cloudera-framework<gh_stars>10-100
package com.cloudera.framework.common.util;
import java.io.FileNotFoundException;
import java.io.IOException;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Map;
import java.util.Set;
import org.apache.hadoop.fs.FileStatus;
import org.apache.had... |
sajiok/beanio | test/org/beanio/parser/json/segment/JsonSegmentParserTest.java | package org.beanio.parser.json.segment;
import static org.junit.Assert.*;
import java.io.*;
import java.util.*;
import org.beanio.*;
import org.beanio.beans.Person;
import org.beanio.parser.ParserTest;
import org.junit.*;
/**
* JUnit test cases for JSON segments.
*
* @author <NAME>
* @since 2.0... |
IncompleteWorlds/01_gs4cubesat | C++Server/Common/include/CxxUtilities/FitsUtility.hh | /*
* FitsFile.hh
*
* Created on: Jun 18, 2014
* Author: yuasa
*/
#ifndef CXXUTILITIES_FITSFILE_HH_
#define CXXUTILITIES_FITSFILE_HH_
#include "CxxUtilities/String.hh"
namespace CxxUtilities {
class FitsUtility {
#ifndef TBIT
public:
// DATATYPE TFORM CODE
static const int TBIT = 1; // ... |
open-hand/hzero-front | packages/hzero-front/src/components/Tips/index.js | <reponame>open-hand/hzero-front<gh_stars>10-100
import React, { Component } from 'react';
import { Bind } from 'lodash-decorators';
import { Tooltip } from 'hzero-ui';
import { queryToolTip } from '../../services/api';
import StaticTextEditor from './StaticTextEditor';
import styles from './index.less';
export defau... |
Intel-EPID-SDK/epid-sdk | epid/internal/ippmath/test/tatepairing-test.cc | /*############################################################################
# Copyright 2016-2019 Intel Corporation
#
# 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
#
# ht... |
reactjsguru/atom-settings | packages/ide-typescript/node_modules/bufrw/test/atoms.js | // Copyright (c) 2015 Uber Technologies, Inc.
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge... |
aimldl/coding | c++/en/dropbox/ConsoleApplication1/ConsoleApplication1/ConsoleApplication1.cpp | <filename>c++/en/dropbox/ConsoleApplication1/ConsoleApplication1/ConsoleApplication1.cpp<gh_stars>0
#include "pch.h" // Uncomment this in Visual Studio
#include <iostream>
#include <set>
using namespace std;
int main() {
auto x = 2;
auto y = 3.141592;
auto z = &x;
// Show the typeid of each vari... |
AsahiOS/gate | usr/src/prototypes/prototype.h | <filename>usr/src/prototypes/prototype.h
/*
* This file and its contents are supplied under the terms of the
* Common Development and Distribution License ("CDDL"), version 1.0.
* You may only use this file in accordance with the terms of version
* 1.0 of the CDDL.
*
* A full copy of the text of the CDDL should h... |
eccles/lnxproc | lnxproc/pidfd.py | <reponame>eccles/lnxproc
'''
Contains PidFd() class
Reads the /proc/<pid>/fd directory and resolves symbolic links
NB requires sudo
'''
from contextlib import suppress
from logging import getLogger
from os import listdir, readlink, path as ospath
from .readfile import ReadFile
LOGGER = getLogger(__name__)
cla... |
TigerBSD/FreeBSD-Custom-ThinkPad | FreeBSD/sys/security/mac/mac_inet6.c | <gh_stars>10-100
/*-
* Copyright (c) 2007-2009 <NAME>
* All rights reserved.
*
* This software was developed by <NAME> for the TrustedBSD Project.
*
* This software was developed at the University of Cambridge Computer
* Laboratory with support from a grant from Google, Inc.
*
* Redistribution and use in sourc... |
impedimentToProgress/UCI-BlueChip | snapgear_linux/user/microwin/src/include/windef.h | <reponame>impedimentToProgress/UCI-BlueChip
/* windef.h*/
/*
* Copyright (c) 1999 <NAME> <<EMAIL>>
*
* Win32 API base type definitions
*/
#define _WINDEF_H
#ifdef VXWORKS
/* Don't include the internal Tornado header file <ntcontext.h>, **
** as the definitions in it conflict with these definitions. */
#defin... |
HendrylNogueira/CursoPython3 | pythonMundoTres/ex074.py | <gh_stars>0
''' Crie um programa que vai gerar cinco números aleatórios e colocar em uma tupla.
Depois disso, mostre a listagem de números gerados e também indique o menor e o maior valor
que está na tupla. '''
import random
num = (random.randint(1, 10), random.randint(1, 10), random.randint(1, 10), random.randint(1, ... |
rbkmoney/woody_java | woody-thrift/src/main/java/com/rbkmoney/woody/thrift/impl/http/interceptor/ext/THSExtensionContext.java | package com.rbkmoney.woody.thrift.impl.http.interceptor.ext;
import com.rbkmoney.woody.api.interceptor.ext.ExtensionContext;
import com.rbkmoney.woody.api.trace.ContextUtils;
import com.rbkmoney.woody.api.trace.TraceData;
import com.rbkmoney.woody.thrift.impl.http.THMetadataProperties;
import javax.servlet.http.HttpS... |
praneethgb/rasa | rasa/nlu/extractors/spacy_entity_extractor.py | <gh_stars>1-10
import typing
from typing import Any, Dict, List, Text
from rasa.engine.graph import ExecutionContext, GraphComponent
from rasa.engine.storage.resource import Resource
from rasa.engine.storage.storage import ModelStorage
from rasa.shared.nlu.constants import ENTITIES, TEXT
from rasa.nlu.utils.spacy_util... |
neeldaveloper97/entraos | src/main/java/no/entra/entraos/api/repository/TemplateRepository.java | package no.entra.entraos.api.repository;
import java.util.Collections;
import java.util.List;
import java.util.Optional;
import java.util.UUID;
import java.util.stream.Collectors;
import io.helidon.common.reactive.Multi;
import io.helidon.common.reactive.Single;
import io.helidon.dbclient.DbClient;
import io.helidon.... |
cctvzd7/aliyun-openapi-java-sdk | aliyun-java-sdk-sofa/src/main/java/com/aliyuncs/sofa/transform/v20190815/DeleteLinkeantcodeAntcodeDeleteprojectkeyResponseUnmarshaller.java | /*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed u... |
ideacrew/opm_enroll | components/benefit_sponsors/config/routes.rb | BenefitSponsors::Engine.routes.draw do
namespace :profiles do
resources :registrations do
post :counties_for_zip_code, on: :collection
end
namespace :broker_agencies do
resources :broker_agency_profiles, only: [:new, :create, :show, :index, :edit, :update] do
collection do
... |
kevinflaherty1/crnk-framework | crnk-gen/crnk-gen-openapi/src/test/java/io/crnk/gen/openapi/internal/operations/RelationshipGetTest.java | package io.crnk.gen.openapi.internal.operations;
import io.crnk.gen.openapi.internal.OperationType;
import io.swagger.v3.oas.models.Operation;
import org.junit.Assert;
import org.junit.jupiter.api.Test;
class RelationshipGetTest extends NestedOperationsBaseTest {
@Test
void operationType() {
RelationshipGet R... |
cybervisiontech/cdap | cdap-data-fabric/src/main/java/co/cask/cdap/data2/dataset2/lib/table/MetadataStoreDataset.java | /*
* Copyright © 2014 <NAME>, 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 to i... |
esean/stl_voro_fill | sw/3rd_party/VTK-7.1.0/Common/DataModel/vtkImplicitBoolean.cxx | /*=========================================================================
Program: Visualization Toolkit
Module: vtkImplicitBoolean.cxx
Copyright (c) <NAME>, <NAME>, <NAME>
All rights reserved.
See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
This software is dist... |
crafterm/piccr | test/functional/commments_controller_test.rb | require File.dirname(__FILE__) + '/../test_helper'
require 'commments_controller'
# Re-raise errors caught by the controller.
class CommmentsController; def rescue_action(e) raise e end; end
class CommmentsControllerTest < Test::Unit::TestCase
fixtures :commments
def setup
@controller = CommmentsController.n... |
tschaffter/apl-core-library | aplcore/src/component/corecomponent.cpp | /**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License").
* You may not use this file except in compliance with the License.
* A copy of the License is located at
*
* http://aws.amazon.com/apache2.0/
*
* or in the "license" ... |
pxviet1997/hyreyou-frontend | src/utils/index.js | <reponame>pxviet1997/hyreyou-frontend
import getInitials from './getInitials';
import Roles from './Roles';
import * as validationSchema from './validationSchema';
export { getInitials, Roles, validationSchema };
|
mk-prg-net/PlaygroundJS | HTML5/Scripts/lodash-amd/internal/Reflect.js | define(['./root'], function(root) {
/** Built-in value references. */
var Reflect = root.Reflect;
return Reflect;
});
|
BW-AnyWhereFitness1/Backend | data/migrations/20201019113852_user.js | <reponame>BW-AnyWhereFitness1/Backend
exports.up = function(knex) {
return knex.schema.createTable('user', tbl => {
tbl.increments();
tbl.string('name').notNullable();
tbl
.string('email')
.notNullable()
.unique();
tbl
.string('username')
.notNullable()
.unique()... |
log-Z/iblog | src/main/java/com/log/blog/mapper/AdminMapper.java | package com.log.blog.mapper;
import com.log.blog.dto.AdminParam;
import com.log.blog.entity.Admin;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import java.util.List;
@Mapper
public interface AdminMapper {
Admin getAdminById(@Param("id") String id);
Admin getAdmin... |
zayloxd/OtakuBot | events/ready.js | <reponame>zayloxd/OtakuBot
const Discord = require('discord.js');
const settings = require('../settings.json');
const client = new Discord.Client();
const fs = require('fs');
module.exports = client => {
console.log(`yourbots Online and ready to serve ${client.guilds.cache.size} servers.`);
};
|
Roopesh2/C.js | src/color/color_converters.js | export function hue2RGB(p, q, t) {
if (t < 0) t += 1;
if (t > 1) t -= 1;
if (t < 1 / 6) return p + (q - p) * 6 * t;
if (t < 1 / 2) return q;
if (t < 2 / 3) return p + (q - p) * (2 / 3 - t) * 6;
return p;
}
/**
* Converts an RGB color value to HSL. Conversion formula
* adapted from http://en.wikipedia.org/wiki/... |
MAKENTNU/web | docs/migrations/0001_initial.py | <gh_stars>1-10
# Generated by Django 2.2.8 on 2019-12-14 22:00
import ckeditor_uploader.fields
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.CreateModel(
... |
cjmcv/cuda | opencl/ocl_util.h | <reponame>cjmcv/cuda
#ifndef CJMCV_OCL_UTIL_HPP_
#define CJMCV_OCL_UTIL_HPP_
#include <iostream>
#include <CL/cl.h>
namespace cjmcv_ocl_util {
////////////////
// Macro.
////////////////
#define OCL_CHECK(condition) \
do { \
cl_int error = condition; \
if (error != CL_SUCCESS) { \
fprintf(stderr, "OC... |
RajeshKumarC6/Learn-Scala-Programming | Chapter11/src/main/scala/ch11/Store.scala | <filename>Chapter11/src/main/scala/ch11/Store.scala
package ch11
import akka.actor._
import com.typesafe.config.ConfigFactory
import Manager.ShoppingList
import Mixer.Groceries
abstract class Store {
val store = ActorSystem("Store", ConfigFactory.load("grocery.conf"))
val seller: ActorRef = store.actorOf(Props(n... |
leongold/ovirt-engine | frontend/webadmin/modules/gwt-common/src/main/java/org/ovirt/engine/ui/common/widget/PatternflyIconType.java | package org.ovirt.engine.ui.common.widget;
import com.google.gwt.dom.client.Style.HasCssName;
public enum PatternflyIconType implements HasCssName {
PF_CLOSE("pficon-close"); //$NON-NLS-1$
private final String cssName;
private PatternflyIconType(String cssName) {
this.cssName = cssName;
}
... |
web-health-portal/portal-capstone | frontend/src/store/articleCategory.js | import {createSlice} from "@reduxjs/toolkit"
import {httpConfig} from "../ui/shared/utils/http-config";
const articleCategorySlice = createSlice({
name: "articleCategory",
initialState: [],
reducers: {
getAllArticleCategories: (articleCategory, action) => {
return action.payload
... |
Matthijsy/amber-api | spec/requests/v1/groups_controller/create_spec.rb | require 'rails_helper'
describe V1::GroupsController do
describe 'POST /groups', version: 1 do
it_behaves_like 'a creatable and permissible model' do
let(:record) { FactoryBot.build(:group) }
let(:record_url) { '/v1/groups' }
let(:record_permission) { 'group.create' }
let(:invalid_attribu... |
JakubVojvoda/design-patterns-java | visitor/Main.java | /*
* Java Design Patterns: Visitor
* Author: <NAME> [github.com/JakubVojvoda]
* 2016
*
* Source code is licensed under MIT License
* (for more details see LICENSE)
*
*/
package app;
public class Main {
public static void main(String[] args) {
Element elementA = new ConcreteElementA();
Elem... |
pintoXD/stm32wb55LoRaFuota | Middlewares/ST/STM32_Cryptographic/Fw_Crypto/STM32H7A3/Inc/DES/Common/des_common.h | /**
******************************************************************************
* @file des_common.h
* @author MCD Application Team
* @brief DES common functions and definitions
******************************************************************************
* @attention
*
* <h2><center>© Co... |
wiidz/goutil | structs/networkStruct/networkStruct.go | package networkStruct
type ContentType int8
const (
Query ContentType = 1
BodyJson ContentType = 2
BodyForm ContentType = 3
)
// ReadCommonStruct 读取列表公用的参数
type ReadCommonStruct struct {
PageNow int `json:"page_now" belong:"etc" default:"1"`
PageSize int `json:"page_size" belong:"etc" default:"10"`
O... |
tizzen33/core | homeassistant/components/knx/weather.py | """Support for KNX/IP weather station."""
from __future__ import annotations
from xknx import XKNX
from xknx.devices import Weather as XknxWeather
from homeassistant.components.weather import WeatherEntity
from homeassistant.const import CONF_ENTITY_CATEGORY, CONF_NAME, TEMP_CELSIUS
from homeassistant.core import Hom... |
labs14-lambda-app-store/FE | src/components/student/share/Share.js | <reponame>labs14-lambda-app-store/FE
import React, { useState } from 'react';
import {
LinkedinShareButton,
TwitterShareButton,
LinkedinIcon,
TwitterIcon,
} from 'react-share';
import Fade from 'react-reveal/Fade';
import { Link } from 'react-router-dom';
const Share = ({ studentId, name, about }) => {
const... |
AeneasPlatform/Aeneas | node/src/main/scala/com/aeneas/transaction/validation/impl/TransferTxValidator.scala | package com.aeneas.transaction.validation.impl
import cats.data.ValidatedNel
import com.aeneas.lang.ValidationError
import com.aeneas.transaction.transfer.TransferTransaction
import com.aeneas.transaction.validation.TxValidator
object TransferTxValidator extends TxValidator[TransferTransaction] {
override def valid... |
NotFound403/WePay | src/main/java/cn/felord/wepay/ali/sdk/api/domain/AlipayTradeOrderSettleModel.java | package cn.felord.wepay.ali.sdk.api.domain;
import java.util.List;
import cn.felord.wepay.ali.sdk.api.AlipayObject;
import cn.felord.wepay.ali.sdk.api.internal.mapping.ApiField;
import cn.felord.wepay.ali.sdk.api.internal.mapping.ApiListField;
/**
* 统一收单交易结算接口
*
* @author auto create
* @version $Id: $Id
*/
publ... |
utilitywarehouse/poc-pg-mirror | billmodel/mobprepa.xo.go | // Package billmodel contains the types for schema 'equinox'.
package billmodel
// GENERATED BY XO. DO NOT EDIT.
import (
"database/sql"
"github.com/lib/pq"
)
// Mobprepa represents a row from 'equinox.mobprepa'.
type Mobprepa struct {
Mppcliuniquesys sql.NullFloat64 `json:"mppcliuniquesys"` // mppcliuniquesys
... |
shahedex/tfjson | vendor/github.com/hashicorp/terraform/builtin/providers/azurerm/resource_arm_virtual_machine_extension_test.go | <reponame>shahedex/tfjson<filename>vendor/github.com/hashicorp/terraform/builtin/providers/azurerm/resource_arm_virtual_machine_extension_test.go
package azurerm
import (
"fmt"
"net/http"
"testing"
"regexp"
"github.com/hashicorp/terraform/helper/acctest"
"github.com/hashicorp/terraform/helper/resource"
"githu... |
goderbauer/ftl | strings/trim.cc | // Copyright 2016 The Fuchsia Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "lib/ftl/strings/trim.h"
namespace ftl {
ftl::StringView TrimString(ftl::StringView str, ftl::StringView chars_to_trim) {
size_t start_index =... |
TeamNuclear/external_chromium_org_third_party_webrtc | modules/audio_coding/main/acm2/acm_common_defs.h | /*
* Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
*
* Use of this source code is governed by a BSD-style license
* that can be found in the LICENSE file in the root of the source
* tree. An additional intellectual property rights grant can be found
* in the file PATENTS. All contribut... |
ceekay1991/CallTraceForWeChat | CallTraceForWeChat/CallTraceForWeChat/WeChat_Headers/ScanBookMgr.h | //
// Generated by class-dump 3.5 (64 bit) (Debug version compiled Sep 17 2017 16:24:48).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2015 by <NAME>.
//
#import "MMService.h"
#import "MMServiceProtocol-Protocol.h"
#import "PBMessageObserverDelegate-Protocol.h"
@class MMTimer, NSData, NSStrin... |
jasha64/jasha64 | Spring 2018/ACM/2018.4.14/J.cpp | <gh_stars>0
#include <iostream>
#include <string>
#include <sstream>
#include <vector>
#include <algorithm>
#include <climits>
using namespace std;
const int N = 100001;
bool f[N]; //is_prime
vector<int> a;
void Get_Prime()
{
fill(f, f+N, 1);
f[0] = f[1] = 0;
for (int i = 2; i < N; i++)
if (f[i])
fo... |
sarismet/basic-CRM-module | src/main/java/com/layermark/layermark_sarismet/exception/GlobalExceptionHandler.java | package com.layermark.layermark_sarismet.exception;
import com.layermark.layermark_sarismet.exception.bad_request.*;
import com.layermark.layermark_sarismet.exception.not_found.ResourceNotFoundException;
import org.springframework.http.HttpStatus;
import org.springframework.http.ResponseEntity;
import org.springframew... |
wangsenyuan/learn-go | src/leetcode/set0000/set800/set800/p831/solution_test.go | <reponame>wangsenyuan/learn-go
package p831
import "testing"
func TestMaskEmail(t *testing.T) {
S := "<EMAIL>"
expect := "<EMAIL>"
res := maskPII(S)
if res != expect {
t.Errorf("error got %s", res)
}
}
func TestMaskPhone(t *testing.T) {
S := "+111 111 111 1111"
expect := "+***-***-***-1111"
res := maskPII(... |
bborisov11/Java-Frameworks-Hibernate-Spring | 05. Spring data intro/src/main/java/org/bookshop/system/bookshopsystem/enums/AgeRestriction.java | <filename>05. Spring data intro/src/main/java/org/bookshop/system/bookshopsystem/enums/AgeRestriction.java
package org.bookshop.system.bookshopsystem.enums;
public enum AgeRestriction {
MINOR,TEEN,ADULT
}
|
rande/pkgmirror | mirror/npm/npm_pat_test.go | // Copyright © 2016-present <NAME> <<EMAIL>>.
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file.
package npm
import (
"testing"
"net/http"
"github.com/stretchr/testify/assert"
"goji.io/pattern"
"golang.org/x/net/context"
)
type TestVersion struct {
Url... |
WeDoSoftware/trino | core/trino-main/src/test/java/io/trino/sql/planner/iterative/rule/TestPushLimitThroughSemiJoin.java | <reponame>WeDoSoftware/trino
/*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in w... |
rsjtaylor/libadm | tests/position_interaction_range_tests.cpp | #include <catch2/catch.hpp>
#include "adm/elements/position_interaction_range.hpp"
TEST_CASE("positionRange_interaction_range") {
using namespace adm;
// Default contructor
{
PositionInteractionRange positionRange;
REQUIRE(positionRange.has<AzimuthInteractionMin>() == false);
REQUIRE(positionRange.ha... |
laides/mbed-cloud-client | factory-configurator-client/utils/utils/mbed_stats_helper.c | <reponame>laides/mbed-cloud-client
// ----------------------------------------------------------------------------
// Copyright 2016-2017 ARM Ltd.
//
// 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 L... |
iamlmn/PyDS | queues/dequeue_linkedLists.py | class Node:
def __init__(self, element, next):
self.element = element
self.next = next
class DQ:
def __init__(self):
self.front = None
self.rear = None
self.size = 0
def __len__(self):
return self.size
def isEmpty(self):
return self.size == 0
... |
gridgentoo/titus-control-plane | titus-supplementary-component/task-relocation/src/main/java/com/netflix/titus/supplementary/relocation/workflow/DefaultNodeConditionController.java | <gh_stars>100-1000
package com.netflix.titus.supplementary.relocation.workflow;
import java.time.Duration;
import java.util.Collections;
import java.util.List;
import java.util.Map;
import java.util.Set;
import java.util.concurrent.TimeUnit;
import java.util.stream.Collectors;
import com.google.common.annotations.Vis... |
qyangge/wechat | node_modules/_wechaty-puppet-padplus@0.6.3@wechaty-puppet-padplus/dist/src/pure-function-helpers/room-event-join-message-parser.js | "use strict";
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
return new (P || (P = Promise))(function (resolve, reject) {
function fulfilled(value) { t... |
velasqueziturrate/multiplataforma | node_modules/.staging/@nativescript/core-b2cc363a/ui/activity-indicator/activity-indicator-common.js | import { View, CSSType } from '../core/view';
import { booleanConverter } from '../core/view-base';
import { Property } from '../core/properties';
let ActivityIndicatorBase = class ActivityIndicatorBase extends View {
};
ActivityIndicatorBase = __decorate([
CSSType('ActivityIndicator')
], ActivityIndicatorBase);
ex... |
Drazuam/RunicArcana | src/main/java/com/latenighters/runicarcana/common/symbols/categories/SymbolCategory.java | package com.latenighters.runicarcana.common.symbols.categories;
import com.latenighters.runicarcana.common.symbols.Symbols;
import com.latenighters.runicarcana.common.symbols.backend.Symbol;
import static com.latenighters.runicarcana.RunicArcana.MODID;
public class SymbolCategory {
public static SymbolCategory ... |
enwords/enwords | spec/services/yandex/kassa/check_payment_spec.rb | require 'rails_helper'
describe Yandex::Kassa::CheckPayment do
subject { described_class.run!(options) }
let(:options) do
{
payment: payment
}
end
let(:payment) { create(:payment, status: :pending, data: [{ 'id' => 123 }]) }
let(:response_body) do
{
id: '23d93cac-000f-5000-8000-12662... |
kx-Huang/VE482 | lab/lab_6/ex3/core/plugin_utility.c | <filename>lab/lab_6/ex3/core/plugin_utility.c
#include "plugin_utility.h"
#include <dirent.h>
#include <dlfcn.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
static char *get_plugin_name(char *filename) {
char *extension = strrchr(filename, '.');
if (!extension || strcmp(extension, ".so") != 0)
... |
RdecKa/bark | docs/tutorials/config_notebook.py | import os
cwd = os.getcwd()
runfiles_dir = cwd.split("run.runfiles")[0]
bark_root = os.path.join(runfiles_dir, "run.runfiles/bark_project")
try:
os.chdir(bark_root)
print("Changing to bark root {}".format(bark_root))
except:
pass |
perfectsense/gyro-aws-provider | src/main/java/gyro/aws/dynamodb/DynamoDbTableBackupFinder.java | <filename>src/main/java/gyro/aws/dynamodb/DynamoDbTableBackupFinder.java
/*
* Copyright 2020, Perfect Sense, 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.apa... |
jsoref/atlassian-bitbucket-server-integration-plugin | src/main/java/com/atlassian/bitbucket/jenkins/internal/model/BitbucketWebhook.java | package com.atlassian.bitbucket.jenkins.internal.model;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.fasterxml.jackson.annotation.JsonProperty;
import org.apache.commons.lang3.builder.ToStringBuilder;
import java.util.Objects;
import jav... |
fabricebouye/gw2-web-api-mapping | test/api/web/gw2/mapping/v2/mounts/skins/MountsSkinsUtilsTest.java | /*
* Copyright (C) 2015-2019 <NAME>
* All rights reserved.
*
* This software may be modified and distributed under the terms
* of the BSD license. See the LICENSE file for details.
*/
package api.web.gw2.mapping.v2.mounts.skins;
import api.web.gw2.mapping.core.EnumValueFactory;
import java.util.stream.IntStrea... |
RNAcentral/rnacentral-import-pipeline | tests/rnacentral/precompute/qa/missing_rfam_match_test.py | <filename>tests/rnacentral/precompute/qa/missing_rfam_match_test.py
# -*- coding: utf-8 -*-
"""
Copyright [2009-2018] EMBL-European Bioinformatics Institute
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 Lice... |
kbingman/bkr | vendor/disabled_extensions/multi_site/vendor/plugins/haml/lib/haml/filters.rb | <reponame>kbingman/bkr<filename>vendor/disabled_extensions/multi_site/vendor/plugins/haml/lib/haml/filters.rb
# This file contains redefinitions of and wrappers around various text
# filters so they can be used as Haml filters.
# :stopdoc:
require 'erb'
require 'sass/engine'
require 'stringio'
begin
require 'rubyg... |
projekt86/goartik-cloud | model/subscription_array..go | package model
// SubscriptionArray model
type SubscriptionArray struct {
Subscriptions []Subscription `json:"subscriptions,omitempty"`
}
|
bingo1118/SST_AS | p2PCoresst0405/src/main/java/com/p2p/shake/ShakeManager.java | <reponame>bingo1118/SST_AS
package com.p2p.shake;
import java.net.InetAddress;
import android.os.Handler;
public class ShakeManager {
public static final int HANDLE_ID_SEARCH_END = 0x11;
public static final int HANDLE_ID_RECEIVE_DEVICE_INFO = 0x12;
public static final int HANDLE_ID_APDEVICE_END = 0x13;
private... |
Grosskopf/openoffice | main/toolkit/qa/complex/toolkit/awtgrid/DummyColumn.java | <reponame>Grosskopf/openoffice
/**************************************************************
*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The... |
whitemike889/afdko | c/spot/source/pathbuild.c | /* Copyright 2014 Adobe Systems Incorporated (http://www.adobe.com/). All Rights Reserved.
This software is licensed as OpenSource, under the Apache License, Version 2.0.
This license is available at: http://opensource.org/licenses/Apache-2.0. */
#include <math.h>
#include <stdio.h>
#include "global.h"
#include ... |
raindigi/Merchello | src/Merchello.Web.UI.Client/src/views/common/dialogs/edit.address.controller.js | /**
* @ngdoc controller
* @name Merchello.Common.Dialogs.EditAddressController
* @function
*
* @description
* The controller for adding a country
*/
angular.module('merchello')
.controller('Merchello.Common.Dialogs.EditAddressController',
function ($scope) {
... |
falcon11/ASFoundation | ASFoundation/Classes/Base/ViewController/ASBaseViewController.h | //
// BaseViewController.h
// ASFoundation
//
// Created by Ashoka on 2020/6/23.
//
#import <UIKit/UIKit.h>
#import <QMUIKit/QMUIKit.h>
#import "BaseViewModel.h"
NS_ASSUME_NONNULL_BEGIN
@interface ASBaseViewController : QMUICommonViewController
// MVVM 时使用
@property (strong, nonatomic) BaseViewModel *viewModel;
... |
THEONLYDarkShadow/alive_reversing | Source/AliveLibAE/ShadowZone.cpp | #include "stdafx.h"
#include "ShadowZone.hpp"
#include "Function.hpp"
#include "Game.hpp"
#include "Map.hpp"
#include "stdlib.hpp"
#include "Events.hpp"
BaseGameObject* ShadowZone::VDestructor(signed int flags)
{
return vdtor_463A70(flags);
}
void ShadowZone::VUpdate()
{
vUpdate_463C40();
}
void ShadowZone::... |
legsem/legstar-core2 | legstar-maven-plugin/src/test/java/com/legstar/maven/plugin/BaseGeneratorMojoTest.java | package com.legstar.maven.plugin;
import java.io.File;
public class BaseGeneratorMojoTest extends LegStarAbstractMojoTestCase
{
public void testMojoBasic() throws Exception {
File testPom = new File(getBasedir(),
"src/test/resources/poms/basic-test-plugin-config.xml");
BaseGener... |
coheigea/tcommon-studio-se | main/plugins/org.talend.metadata.managment.ui/src/main/java/org/talend/metadata/managment/ui/wizard/CheckLastVersionRepositoryWizard.java | <reponame>coheigea/tcommon-studio-se
// ============================================================================
//
// Copyright (C) 2006-2021 Talend Inc. - www.talend.com
//
// This source code is available under agreement available at
// %InstallDIR%\features\org.talend.rcp.branding.%PRODUCTNAME%\%PRODUCTNAME%lic... |
Connway/Shibboleth | src/Frameworks/Gleam/Gleam_Frustum.cpp | /************************************************************************************
Copyright (C) 2021 by <NAME>
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, includi... |
hpehl/domino-ui | domino-ui/src/main/java/org/dominokit/domino/ui/datatable/plugins/SortPlugin.java | <gh_stars>0
package org.dominokit.domino.ui.datatable.plugins;
import elemental2.dom.HTMLElement;
import org.dominokit.domino.ui.datatable.ColumnConfig;
import org.dominokit.domino.ui.datatable.DataTable;
import org.dominokit.domino.ui.datatable.events.SortEvent;
import org.dominokit.domino.ui.icons.Icons;
import org.... |
SLB-Pizza/radio-pizza | src/components/helpers/HeroRightArrow.js | <gh_stars>0
import React from 'react'
/**
* Renders the right arrow for the Hero.
* @category Layout Helper
* @function HeroRightArrow
* @param {Function} onClick
* @returns {jsx}
*/
export default function HeroRightArrow({ onClick }) {
return (
<svg
className="hero-arrow__right"
baseProfile="t... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.