repo_name stringlengths 6 101 | path stringlengths 4 300 | text stringlengths 7 1.31M |
|---|---|---|
totalamateurhour/oci-utils | tests/test_exec_utils-config-helper.py | <filename>tests/test_exec_utils-config-helper.py
# Copyright (c) 2018, 2021 Oracle and/or its affiliates. All rights reserved.
# Licensed under the Universal Permissive License v 1.0 as shown at
# http://oss.oracle.com/licenses/upl.
import os
import sys
import subprocess
import unittest
from tools.oci_test_case import... |
mayankmetha/Notilizer2 | app/src/main/java/com/mayank/notilizer2/models/ApplicationDao.java | package com.mayank.notilizer2.models;
import com.j256.ormlite.dao.Dao;
import java.sql.SQLException;
import java.util.List;
public interface ApplicationDao extends Dao<Application, String> {
public List<Application> getIgnoredApps() throws SQLException;
}
|
dannyhx/artisynth_core | src/artisynth/core/femmodels/FrameNodeNodeAttachmentTest.java | <reponame>dannyhx/artisynth_core<filename>src/artisynth/core/femmodels/FrameNodeNodeAttachmentTest.java
package artisynth.core.femmodels;
import java.util.*;
import maspack.matrix.*;
import maspack.spatialmotion.*;
import maspack.geometry.*;
import maspack.util.*;
import artisynth.core.mechmodels.*;
import artisynth.... |
lovemomia/MomiaAdmin | src/main/java/com/momia/action/TopicGoodsAction.java | <reponame>lovemomia/MomiaAdmin
package com.momia.action;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.HashMap;
import java.util.Map;
import javax.annotation.Resource;
import javax.servlet.http.HttpServletRequest;
import org.springframework.stereotype.Controller;
import org.springframewo... |
gaol/wildfly-transaction-client | src/main/java/org/wildfly/transaction/client/XAImporter.java | <filename>src/main/java/org/wildfly/transaction/client/XAImporter.java
/*
* JBoss, Home of Professional Open Source.
* Copyright 2016 Red Hat, Inc., and individual contributors
* as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file excep... |
alanktwong/slow-light | proxy/src/main/java/com/tacitknowledge/slowlight/proxyserver/handler/AbstractChannelHandler.java | <reponame>alanktwong/slow-light<gh_stars>1-10
package com.tacitknowledge.slowlight.proxyserver.handler;
import io.netty.buffer.Unpooled;
import io.netty.channel.Channel;
import io.netty.channel.ChannelDuplexHandler;
import io.netty.channel.ChannelFutureListener;
import io.netty.channel.ChannelHandler;
import io.netty.... |
TANGKUO/joice | joice-web/src/main/java/org/joice/mvc/dao/SysRolesPermissionsMapper.java | package org.joice.mvc.dao;
import org.apache.ibatis.annotations.Param;
import org.joice.mvc.dao.domain.SysRolesPermissions;
public interface SysRolesPermissionsMapper {
int deleteByPrimaryKey(@Param("roleId") Long roleId, @Param("permissionId") Long permissionId);
int insert(SysRolesPermissions recor... |
samuelyuan/OpenBiohazard2 | render/surface2d.go | package render
import (
"github.com/go-gl/gl/v4.1-core/gl"
"github.com/samuelyuan/openbiohazard2/geometry"
)
const (
IMAGE_SURFACE_WIDTH = 320
IMAGE_SURFACE_HEIGHT = 240
)
var (
screenImage = NewImage16Bit(0, 0, IMAGE_SURFACE_WIDTH, IMAGE_SURFACE_HEIGHT)
)
type Surface2D struct {
TextureId uint32 ... |
hpi-schul-cloud/klassi-js | page-objects/pages/coursePages/CRSSViewTopicPage.js | <filename>page-objects/pages/coursePages/CRSSViewTopicPage.js
/*[url/courses]/[courseId]/topics/[topicId]]*/ |
nyinyiz/The-Houzz | TheHouzz/app/src/main/java/com/nyinyi/nw/thehouzz/activities/ViewProductActivity.java | <gh_stars>0
package com.nyinyi.nw.thehouzz.activities;
import android.content.Context;
import android.content.Intent;
import android.os.Bundle;
import android.support.annotation.Nullable;
import android.support.v7.app.AppCompatActivity;
import android.support.v7.widget.Toolbar;
import android.view.Menu;
impor... |
lastweek/source-freebsd | src/sys/dev/veriexec/verified_exec.c | <gh_stars>0
/*
* $FreeBSD$
*
* Copyright (c) 2011-2013, 2015, 2019 Juniper Networks, Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain... |
IGalat/libnine | src/main/java/io/github/phantamanta44/libnine/block/state/VirtualState.java | package io.github.phantamanta44.libnine.block.state;
import com.google.common.collect.Lists;
import net.minecraft.block.properties.IProperty;
import net.minecraft.block.state.BlockStateContainer;
import net.minecraft.block.state.IBlockState;
import javax.annotation.Nullable;
import java.util.HashMap;
import java.util... |
phatblat/macOSPrivateFrameworks | PrivateFrameworks/HomeKitDaemon/AWDHomeKitEventTriggerEvent.h | //
// Generated by class-dump 3.5 (64 bit).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2013 by <NAME>.
//
#import "PBCodable.h"
#import "NSCopying.h"
@class AWDHomeKitCalendarEvent, AWDHomeKitCharacteristicEvent, AWDHomeKitCharacteristicThresholdEvent, AWDHomeKitDurationEvent, AWDHomeKitLoc... |
alpano-unibz/ontop | client/protege/src/main/java/it/unibz/inf/ontop/protege/gui/component/PropertyMappingPanel.java | package it.unibz.inf.ontop.protege.gui.component;
/*
* #%L
* ontop-protege
* %%
* Copyright (C) 2009 - 2013 KRDB Research Centre. Free University of Bozen Bolzano.
* %%
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may... |
kshithijiyer/isis | core/applib/src/main/java/org/apache/isis/applib/services/wrapper/WrapperFactory.java | /*
* 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 ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License")... |
htdvisser/exp | natsconfig/natsconfig_test.go | package natsconfig
import (
"fmt"
"testing"
"github.com/google/go-cmp/cmp"
"github.com/spf13/pflag"
)
func TestConfigFlags(t *testing.T) {
var config Config
flags := config.Flags("test.", nil)
var flagNamesAndValues []string
flags.VisitAll(func(f *pflag.Flag) {
flagNamesAndValues = append(flagNamesAndValu... |
rajkovukovic/tfux | utils/engines/jspm/jspm.js | <filename>utils/engines/jspm/jspm.js
'use strict';
const fs = require('fs');
const path = require('path');
const { AbstractEngine } = require('../abstract-engine/abstract-engine.js');
const { transformAndCopyModules } = require('./transform/transform-and-copy-modules.js');
const { transformJsFile } = require('./transf... |
he5050/hframe | src/middleware/base_component.js | <filename>src/middleware/base_component.js<gh_stars>0
import { Component } from "react";
import { fromJS, is } from "immutable";
function trackLog(componentName) {
return function (target, name, descriptor) {
const fn = descriptor.value;
descriptor.value = function () {
let result = fn.apply(this, argu... |
trombik/rotas | lib/rotas/project.rb | <filename>lib/rotas/project.rb
# frozen_string_literal: true
require "sem_version"
require "rotas/project/arch"
module Rotas
# Rotas::Project represents a project
class Project
attr_reader :name, :stable_version, :arch
def initialize(arg)
@name = arg[:name]
@path = arg[:path].is_a?(Pathname) ... |
helmasur/bitwig-extensions | src/main/java/com/bitwig/extensions/framework/InternalLightStateBinding.java | <filename>src/main/java/com/bitwig/extensions/framework/InternalLightStateBinding.java
package com.bitwig.extensions.framework;
import java.util.function.Supplier;
import com.bitwig.extension.controller.api.InternalHardwareLightState;
import com.bitwig.extension.controller.api.MultiStateHardwareLight;
public class I... |
DXYyang/SDP | sourcedata/poi-REL_3_0/src/scratchpad/src/org/apache/poi/hwpf/model/types/TCAbstractType.java | <reponame>DXYyang/SDP<gh_stars>1-10
/* ====================================================================
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 ownershi... |
kenjili/morelove | morelove-api/common/src/main/java/wujiuye/morelove/common/utils/showapi/ShowApiRequest.java | package wujiuye.morelove.common.utils.showapi;
import java.io.IOException;
import java.io.UnsupportedEncodingException;
/**
* 基于REST的客户端。
*/
public class ShowApiRequest extends NormalRequest {
private String appSecret;
public ShowApiRequest(String url, String appid, String appSecret) {
super(url... |
mattrpav/org.ops4j.pax.logging | pax-logging-samples/perfs/src/main/java/org/ops4j/pax/logging/example/Activator.java | /*
* Copyright 2005 <NAME>.
*
* 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... |
helgifr/comeon-javascript-test | src/components/user-route/index.js | <reponame>helgifr/comeon-javascript-test<filename>src/components/user-route/index.js
import UserRoute from './UserRoute';
export default UserRoute; |
DucPhamTV/Bank | v1/confirmation_blocks/models/confirmation_block.py | from uuid import uuid4
from django.db import models
from thenewboston.constants.network import BLOCK_IDENTIFIER_LENGTH
from thenewboston.models.created_modified import CreatedModified
from v1.blocks.models.block import Block
from v1.validators.models.validator import Validator
class ConfirmationBlock(CreatedModifie... |
upane/qqbot | src/main/java/com/handcraft/controller/LocalSaveJPGController.java | <reponame>upane/qqbot<gh_stars>1-10
package com.handcraft.controller;
import com.handcraft.service.LocalPicService;
import com.handcraft.util.StringUtil;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestPa... |
andrii/hew | spec/hew/attributes/text_attribute_spec.rb | require 'spec_helper'
describe Hew::Attributes::TextAttribute do
let(:attribute) { Hew::Attributes::TextAttribute.new('apartment', 'description') }
it 'returns a create value' do
_(attribute.create_value).must_equal 'MyText'
end
it 'returns an update value' do
_(attribute.update_value).must_equal 'Up... |
LetsCloud/hw-gae | hw-gae-client_fro/src/main/java/hu/hw/cloud/client/fro/config/AbstractConfigPresenter.java | /**
*
*/
package hu.hw.cloud.client.fro.config;
import java.util.ArrayList;
import java.util.List;
import java.util.logging.Logger;
import com.google.gwt.event.shared.GwtEvent;
import com.google.web.bindery.event.shared.EventBus;
import com.gwtplatform.mvp.client.HasUiHandlers;
import com.gwtplatform.mvp.client.Pr... |
agardiner/ess4r | lib/ess4r/cube/loads.rb | <reponame>agardiner/ess4r
require_relative 'load_errors'
class Essbase
# Define methods for loading data and building dimensions.
module Loads
include_package 'com.essbase.api.datasource'
# @!macro [new] load_notes
#
# If records are rejected during the load, they can be... |
zhasm/onecloud | pkg/image/models/quotas.go | // Copyright 2019 Yunion
//
// 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 writi... |
markmuetz/cosmic | ctrl/UM_N1280/MASS/u-al508_ap9_precip.py | <filename>ctrl/UM_N1280/MASS/u-al508_ap9_precip.py
import sys
sys.path.insert(0, '.')
from common import AP9_TOTAL_RAIN_SNOW_ONLY, BASE_OUTPUT_DIRPATH
AP9_TOTAL_RAIN_SNOW_ONLY['start_year_month'] = (2008, 4)
AP9_TOTAL_RAIN_SNOW_ONLY['end_year_month'] = (2009, 12)
ACTIVE_RUNIDS = ['u-al508']
MASS_INFO = {}
MASS_INFO[... |
S2-group/Lacuna-evaluation | subjects/lacunaWebPages/stackexchange.com/stackexchange.com/1/lacuna_cache/imported_46ytw6.js | // LACUNA LAZY LOAD FALLBACK
function lacuna_lazy_load(id, callback){
fetch("http://127.0.0.1:8125/lazyload/", {
method: "POST",
headers: { "Accept": "application/json", "Content-Type": "application/json" },
body: JSON.stringify({id})
}).then(response => {
return response.text();... |
lizhifuabc/spring-boot-learn | doc/src/main/java/com/doc/demo/SynchronizedDemo.java | package com.doc.demo;
import lombok.SneakyThrows;
import lombok.extern.slf4j.Slf4j;
/**
* SynchronizedDemo
*
* @author lizhifu
* @date 2021/1/15
*/
@Slf4j
public class SynchronizedDemo {
static int j = 0;
@SneakyThrows
public synchronized void increase(){
Thread.sleep(150);
log.info("... |
if-pan-zpp/mdk | mdk/src/system/State.cpp | #include "system/State.hpp"
#include "simul/Simulation.hpp"
using namespace mdk;
void State::exportTo(Model &model) const {
for (int i = 0; i < model.n; ++i) {
auto& res = model.residues[i];
res.r = r[i];
res.v = v[i];
}
}
void State::bind(Simulation &simul) {
auto& model = simul.d... |
TencentCloud/tencentcloud-sdk-cpp-intl-en | gaap/include/tencentcloud/gaap/v20180529/model/ModifyRuleAttributeRequest.h | /*
* Copyright (c) 2017-2019 THL A29 Limited, a Tencent company. 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.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
... |
shengxinhu/tvm | tests/python/unittest/test_target_codegen_bool.py | # 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 ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not u... |
Haakenlid/tassen | webpack/src/universitas/components/PageSwitch/PageSwitch.js | <reponame>Haakenlid/tassen<filename>webpack/src/universitas/components/PageSwitch/PageSwitch.js<gh_stars>10-100
import { withErrorBoundary } from 'react-error-boundary'
import { Helmet } from 'react-helmet'
import { connect } from 'react-redux'
import { TransitionGroup, CSSTransition } from 'react-transition-group'
imp... |
ogonkov/djanjucks | src/tags/FirstOf.js | <gh_stars>1-10
import Tag from './Tag';
class FirstOfTag extends Tag {
constructor() {
super();
this.tags = ['firstof'];
}
run(context) {
// Check the arguments for a truthy value
for (let i = 1; i < arguments.length; i += 1) {
if (arguments[i]) {
return arguments[i];
}
}... |
coclar/pointlike | python/uw/stacklike/stcaldb.py | import astropy.io.fits as pf
import numpy as np
import os as os
import scipy.integrate as si
from uw.stacklike.angularmodels import PSF
class IrfLoader(object):
def __init__(self,name):
self.cdir = os.environ['CALDB']+'/data/glast/lat/bcf/'
self.fpsffile = self.cdir+'psf/psf_%s_front.fits'%nam... |
sebeier/biosamples-v4 | models/core/src/main/java/uk/ac/ebi/biosamples/model/SampleFacetValue.java | <filename>models/core/src/main/java/uk/ac/ebi/biosamples/model/SampleFacetValue.java
/*
* Copyright 2019 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 License at
*... |
leikong/service-fabric | src/prod/src/pal/src/internal/palrt.cpp | <reponame>leikong/service-fabric
// ------------------------------------------------------------
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License (MIT). See License.txt in the repo root for license information.
// -----------------------------------------------------------... |
wnsdudSoftkim/EP2021 | FullStack/ch10-photo-app/src/CreatePost.js | import React, { useState } from 'react';
import { Button, Input } from 'antd';
import { v4 as uuid } from 'uuid';
import { createPost } from './graphql/mutations';
import { API, graphqlOperation, Storage } from 'aws-amplify';
const initialFormState = {
title: '',
image: {},
};
function CreatePost({ updateViewStat... |
groupon/nakala | src/main/java/com/groupon/nakala/core/Token.java | /*
Copyright (c) 2013, Groupon, Inc.
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
met:
Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disc... |
eivindj-nordic/sdk-zephyr | drivers/sensor/sgp40/sgp40.c | <gh_stars>10-100
/*
* Copyright (c) 2021 <NAME>
*
* SPDX-License-Identifier: Apache-2.0
*/
#define DT_DRV_COMPAT sensirion_sgp40
#include <device.h>
#include <drivers/i2c.h>
#include <kernel.h>
#include <drivers/sensor.h>
#include <logging/log.h>
#include <pm/device.h>
#include <sys/byteorder.h>
#include <sys/crc... |
terasoluna-batch/terasoluna-batch | terasoluna-batch/src/main/java/jp/terasoluna/fw/batch/exception/BatchException.java | <gh_stars>10-100
/*
* Copyright (c) 2011 NTT DATA 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
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless ... |
woohoou/ember-paper | tests/dummy/app/controllers/demo/tabs.js | <reponame>woohoou/ember-paper<filename>tests/dummy/app/controllers/demo/tabs.js<gh_stars>100-1000
import { inject as service } from '@ember/service';
import { readOnly, reads } from '@ember/object/computed';
import Controller from '@ember/controller';
import { computed } from '@ember/object';
import { A } from '@ember/... |
Sticksword/nypr-design-system | addon/components/nypr-o-article-footer.js | // BEGIN-SNIPPET nypr-o-article-footer.js
import Component from '@ember/component';
import { debounce, bind } from '@ember/runloop';
import layout from '../templates/components/nypr-o-article-footer';
/**
Article Footer layout
Usage:
```hbs
<NyprOArticleFooter as |footer|>
<footer.tags @tags={{array 'foo... |
jezze/alfi | src/resource.h | <gh_stars>10-100
#define RESOURCE_PAGESIZE 0x1000
struct resource
{
struct list_item item;
char url[URL_SIZE];
void *data;
unsigned int size;
unsigned int count;
unsigned int refcount;
int index;
int w;
int h;
int n;
};
void resource_load(struct resource *resour... |
LukasHabring/api | c/github.com/TheThingsNetwork/api/broker/broker.pb-c.h | <reponame>LukasHabring/api
/* Generated by the protocol buffer compiler. DO NOT EDIT! */
/* Generated from: github.com/TheThingsNetwork/api/broker/broker.proto */
#ifndef PROTOBUF_C_github_2ecom_2fTheThingsNetwork_2fapi_2fbroker_2fbroker_2eproto__INCLUDED
#define PROTOBUF_C_github_2ecom_2fTheThingsNetwork_2fapi_2fbro... |
djandrewd/photogramm | photo-service/images-data-module/src/main/java/ua/danit/photogramm/imgs/model/HistoryAction.java | <gh_stars>0
package ua.danit.photogramm.imgs.model;
import java.time.Instant;
/**
* History social action made by user: like, comment, share etc.
*
* @author <NAME>
*/
public interface HistoryAction {
/**
* Gets user id as author of event.
*
* @return the user nickname, author of action.
*/
String... |
flowmemo/leetcode-in-js | test/solution/575.js | // 575. Distribute Candies
const data = [
{
input: [[1, 1, 2, 2, 3, 3]],
ans: 3
},
{
input: [[1, 1, 2, 3]],
ans: 2
},
{
input: [[1, 2, 3, 4, 5, 6]],
ans: 3
}
]
module.exports = {
data,
checker: require('../checkers.js').normalChecker
}
|
ScalablyTyped/SlinkyTyped | p/powerapps-component-framework/src/main/scala/typingsSlinky/powerappsComponentFramework/ComponentFramework/DeviceApi.scala | package typingsSlinky.powerappsComponentFramework.ComponentFramework
import typingsSlinky.powerappsComponentFramework.anon.Accuracy
import org.scalablytyped.runtime.StObject
import scala.scalajs.js
import scala.scalajs.js.`|`
import scala.scalajs.js.annotation.{JSGlobalScope, JSGlobal, JSImport, JSName, JSBracketAcces... |
darkness463/Leetcode-in-Java | src/com/darkness463/leetcode/array/ContainsDuplicate.java | <reponame>darkness463/Leetcode-in-Java<filename>src/com/darkness463/leetcode/array/ContainsDuplicate.java<gh_stars>0
package com.darkness463.leetcode.array;
import java.util.Arrays;
import java.util.HashSet;
import java.util.Set;
/**
* 217. 存在重复元素
* 给定一个整数数组,判断是否存在重复元素。
* <p>
* 如果任何值在数组中出现至少两次,函数返回 true。如果数组中每个元素... |
foss4/pontoon | pontoon/in_context/urls.py | <gh_stars>1000+
from django.urls import path
from django.views.generic import RedirectView
from . import views
urlpatterns = [
# In-context demo
path(
"in-context/",
views.in_context,
name="pontoon.in_context",
),
# Legacy: Redirect to /in-context
path(
"intro/",
... |
rrehbein/Ariente | src/main/java/mcjty/ariente/blocks/generators/PowerCombinerTile.java | <reponame>rrehbein/Ariente<filename>src/main/java/mcjty/ariente/blocks/generators/PowerCombinerTile.java
package mcjty.ariente.blocks.generators;
import mcjty.ariente.Ariente;
import mcjty.ariente.cables.CableColor;
import mcjty.ariente.cables.ConnectorTileEntity;
import mcjty.ariente.gui.HelpBuilder;
import mcjty.ari... |
pacey/aws-sdk-java | aws-java-sdk-transfer/src/main/java/com/amazonaws/services/transfer/model/UpdateServerRequest.java | <filename>aws-java-sdk-transfer/src/main/java/com/amazonaws/services/transfer/model/UpdateServerRequest.java
/*
* Copyright 2014-2019 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
* th... |
topillar/PuTTY-ng | library/base/algorithm/libjpeg_turbo/rrutil.h | /* Copyright (C)2004 Landmark Graphics Corporation
* Copyright (C)2005 Sun Microsystems, Inc.
* Copyright (C)2010 <NAME>
*
* This library is free software and may be redistributed and/or modified under
* the terms of the wxWindows Library License, Version 3.1 or (at your option)
* any later version. The full lic... |
ggwhsd/CPPStudy | Linux/13socket/udp_group_brodcast/udp_g_brodcast_recv.c | <filename>Linux/13socket/udp_group_brodcast/udp_g_brodcast_recv.c
#include <sys/types.h>
#include <sys/socket.h>
#include <arpa/inet.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <netdb.h>
#include <errno.h>
#define BUFLEN 255
void print_exit(char* con)
{
printf("%s",con);
exit(EXIT_FAIL... |
bangaman/netlifywebb | mungo/session.go |
package mungo
import (
"github.com/gorilla/sessions"
)
var (
Store = sessions.NewCookieStore([]byte("top-name"))
) |
qq1367159064/smilemall | smilemall-ware/src/main/java/cn/smile/smilemall/ware/feign/ProdcutFeignImpl.java | <reponame>qq1367159064/smilemall
package cn.smile.smilemall.ware.feign;
import cn.smile.common.utils.R;
import org.springframework.stereotype.Service;
/**
* @author Smile
* @Documents
* @date 2021-01-2021/1/28/028
*/
@Service
public class ProdcutFeignImpl implements ProdcutFeign {
@Override
public R info(Long s... |
EvanMorcom/Software | src/firmware_new/boards/frankie_v1/io/allegro_a3931_motor_driver.h | <gh_stars>0
#pragma once
/**
* This file is an abstraction around the Allegro A3931 Motor Driver
*/
#include "firmware_new/boards/frankie_v1/Drivers/STM32H7xx_HAL_Driver/Inc/stm32h7xx_hal.h"
#include "firmware_new/boards/frankie_v1/io/gpio_pin.h"
#include "firmware_new/boards/frankie_v1/io/pwm_pin.h"
typedef enum
{... |
Microchip-MPLAB-Harmony/reference_apps | apps/sam_e51_cnano/same51n_mikroe_click/eink_bundle/firmware/src/click_routines/eink_bundle/eink_bundle_font.c | <filename>apps/sam_e51_cnano/same51n_mikroe_click/eink_bundle/firmware/src/click_routines/eink_bundle/eink_bundle_font.c
/**************************CHANGE LIST **************************************
*
* Date Software Version Initials Description
* 28/01/2020 1.0 MK Modified.
* 15/04... |
v0lkan/o2.js | draft/examples/widget-demo/api.widget.wwwroot/static/lib/o2.js/o2.dom.core.js | <reponame>v0lkan/o2.js
/**
* @module dom.core
* @requires core
* @requires dom.constants
* @requires dom.style
*
* <!--
* This program is distributed under
* the terms of the MIT license.
* Please see the LICENSE file for details.
*
* lastModified: 2012-06-03 00:12:56.288837
* -->
*
* <p>A cross-bro... |
wohaaitinciu/zpublic | 3rdparty/stlsoft/include/winstl/toolhelp/error/exceptions.hpp | /* /////////////////////////////////////////////////////////////////////////
* File: winstl/toolhelp/error/exceptions.hpp
*
* Purpose: Exception classes for TOOLHELP components.
*
* Created: 21st May 2005
* Updated: 10th August 2009
*
* Thanks: To Pablo for contributing this great librar... |
taowu750/LeetCodeJourney | src/training/binarysearch/E1044_Hard_LongestDuplicateSubstring.java | package training.binarysearch;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.Test;
import java.util.HashMap;
import java.util.Map;
import java.util.function.UnaryOperator;
/**
* 1044. 最长重复子串: https://leetcode-cn.com/problems/longest-duplicate-substring/
*
* 给出一个字符串 S,考虑其所有重复子串(S 的连续子串,出现两次... |
cybervisiontech/coopr | coopr-e2e/test/e2e/redirects.js | /**
* e2e tests for generic redirects
*/
describe('redirects', function() {
it('should show a soft 404 when navigatin to /whatever', function() {
browser.get('/whatever');
expect(
browser.getLocationAbsUrl()
).toMatch(/\/whatever$/);
expect(
element(by.css('main .jumbotron')).getText... |
justacoder/mica | src/core/MiAttributes.java | <reponame>justacoder/mica
/*
***************************************************************************
* Mica - the Java(tm) Graphics Framework *
***************************************************************************
* NOTICE: Permission to use, copy, and modify this softwar... |
Bradicus/XCTE3 | lib/plugins_core/lang_ruby/method_constructor.rb | ##
#
# Copyright (C) 2008 <NAME>
# This file is released under the zlib/libpng license, see license.txt in the
# root directory
#
# This plugin creates a constructor for a class
require 'x_c_t_e_plugin.rb'
require 'plugins_core/lang_ruby/x_c_t_e_ruby.rb'
class XCTERuby::MethodConstructor < XCTEPlugin
def initiali... |
lsdlab/djshop_toturial | apps/products/urls.py | <filename>apps/products/urls.py
from django.urls import include, path
from rest_framework.routers import DefaultRouter
from .views import (CategoryViewSet, ArticleViewSet, ProductsViewSet, ProductSpecViewSet,
ProductReviewViewSet, ProductSpecReviewViewSet,
ProductReviewAppendVie... |
tiwer/letv | src/main/java/cn/jpush/a/a/ah.java | package cn.jpush.a.a;
public final class ah {
}
|
isaackwan/jsdelivr | files/bluebird/0.9.10-1/bluebird.js | /**
* bluebird build version 0.9.10-0
* Features enabled: core, race, any, call_get, filter, generators, map, nodeify, promisify, props, reduce, settle, some, progress, cancel, complex_thenables, synchronous_inspection
* Features disabled: simple_thenables
*/
/**
* @preserve Copyright (c) 2013 <NAME>
*
* Permiss... |
ejc123/geotrellis | spark/src/test/scala/geotrellis/spark/cmd/BuildPyramidSpec.scala | /*
* Copyright (c) 2014 DigitalGlobe.
*
* 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 agree... |
surrealdb/ember-surreal | addon/services/surreal.js | <reponame>surrealdb/ember-surreal
import Service from '@ember/service';
import Evented from '@ember/object/evented';
import { computed } from '@ember/object';
import { A } from '@ember/array';
import { key } from '../utils/conf';
import guid from '../utils/guid';
import { Promise } from 'rsvp';
import Config from '../-... |
lionelpa/openvalidation | openvalidation-common/src/main/java/io/openvalidation/common/ast/ASTActionError.java | /*
* Copyright 2019 <NAME>
*
* 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 ... |
sullis/mockserver | mockserver-core/src/test/java/org/mockserver/serialization/java/NottableStringToJavaSerializerTest.java | package org.mockserver.serialization.java;
import org.junit.Test;
import static org.junit.Assert.assertEquals;
import static org.mockserver.model.NottableString.string;
/**
* @author jamesdbloom
*/
public class NottableStringToJavaSerializerTest {
@Test
public void shouldSerializeNottedString() {
... |
davidbebangarang/gesbonos | frontend/src/__mocks__/BonoMock.js | <gh_stars>0
const BonoMock = {
"idBono": "1",
"titulo": "Masaje relajante",
"ubicacion": "Las Americas",
"valor": "90",
"precio": "55.90",
"tiempo": "",
"textoAdicional":"",
"descripcion": "Lorem Ipsum is simply dummy text of the printing and types... |
cooperative-humans/localorbit | db/migrate/20140319184312_add_facebook_and_twitter_to_organizations.rb | <filename>db/migrate/20140319184312_add_facebook_and_twitter_to_organizations.rb
class AddFacebookAndTwitterToOrganizations < ActiveRecord::Migration
def change
add_column :organizations, :facebook, :string
add_column :organizations, :twitter, :string
end
end
|
mwarkentin/homebrew-versions | Casks/command-line-tools-lion.rb | <gh_stars>0
class CommandLineToolsLion < Cask
version 'lion_april_2013'
sha256 '20a3e1965c685c6c079ffe89b168c3975c9a106c4b33b89aeac93c8ffa4e0523'
url 'http://devimages.apple.com/downloads/xcode/command_line_tools_for_xcode_os_x_lion_april_2013.dmg'
homepage 'https://developer.apple.com/xcode/downloads/'
lice... |
ahota/visit_ospray | databases/IDX/avtIDXFileFormat.h | <gh_stars>0
/*****************************************************************************
*
* Copyright (c) 2000 - 2013, Lawrence Livermore National Security, LLC
* Produced at the Lawrence Livermore National Laboratory
* LLNL-CODE-442911
* All rights reserved.
*
* This file is part of VisIt. For details, see https:... |
guychris/canvas | canvas_modules/common-canvas/__tests__/common-properties/panels/summary-test.js | /*
* Copyright 2017-2020 IBM 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
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agree... |
Eng-RSMY/OpenPNM | OpenPNM/Geometry/__Cube_and_Cuboid__.py | # -*- coding: utf-8 -*-
"""
===============================================================================
Cube_and_Cuboid -- A standard Cubic pore and Cuboic throat model
===============================================================================
"""
from OpenPNM.Geometry import models as gm
from OpenPNM.Geomet... |
sleyzerzon/soar | Deprecated/GGP/translator/src/Model3.py | from PositionIndex import PositionIndex
from GDL import *
import pdb
class Model:
def __init__(self):
self.__grounds = set()
def __iter__(self):
return iter(self.__grounds)
def __eq__(self, other):
if not isinstance(other, Model): return False
return self.__grounds == other.__grounds
def add_ground(s... |
bhojpur/web | pkg/app/testing_test.go | <gh_stars>0
package app
// Copyright (c) 2018 Bhojpur Consulting Private Limited, India. All rights reserved.
// 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... |
DS3Lab/LambdaML | archived/functions/cifar10/trigger.py | <reponame>DS3Lab/LambdaML
import os
import boto3
import json
def handler(event,context):
dataset_name = 'cifar10'
bucket_name = 'cifar10dataset'
key = 'cifar-10-python.tar.gz'
num_workers = 10
data_path = os.path.join(os.sep, 'tmp', 'data')
# preprocess_start = time.time()
# ... |
cuichuanteng/njs | test/js/promise_prototype_reject_type_confusion.t.js | /*---
includes: []
flags: [async]
---*/
Symbol.__proto__ = new Promise(()=>{});
Promise.reject(Symbol)
.then(v => $DONOTEVALUATE())
.catch(err => assert.sameValue(err.name, 'Symbol'))
.then($DONE, $DONE);
|
all-of-us/raw-data-repository | rdr_service/lib_fhir/fhirclient_3_0_0/models/questionnaireresponse_tests.py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# Generated from FHIR 3.0.0.11832 on 2017-03-22.
# 2017, SMART Health IT.
import io
import json
import os
import unittest
from . import questionnaireresponse
from .fhirdate import FHIRDate
class QuestionnaireResponseTests(unittest.TestCase):
def instantiate_fro... |
ColiseumSoft786/Cropability | node_modules/ng2-archwizard/dist/navigation/navigation-mode.provider.js | import { FreeNavigationMode } from './free-navigation-mode';
import { SemiStrictNavigationMode } from './semi-strict-navigation-mode';
import { StrictNavigationMode } from './strict-navigation-mode';
/**
* A factory method used to create [[NavigationMode]] instances
*
* @param {WizardComponent} wizard The wizard, fo... |
themlstudent/MasteringDataStructure | Coding Blocks/Remove_Duplicate_Frrom_String.cpp | #include<iostream>
#include<cstring>
using namespace std;
// remove consecutive duplicate characters from a string
//ccoooding ---> coding
void remove(char a[])
{
int l=strlen(a);
if(l==1 or l==0)
{
return;
}
int prev=0;
for (int current =1;current<l;current++)
{
if (a[current] !=a[prev])
{... |
davidkeen/amee-platform | amee-platform-service/src/main/java/com/amee/service/locale/LocaleServiceImpl.java | package com.amee.service.locale;
import com.amee.base.transaction.TransactionEvent;
import com.amee.domain.*;
import com.amee.domain.data.DataCategory;
import com.amee.domain.data.ItemValueDefinition;
import com.amee.domain.data.LocaleName;
import com.amee.domain.item.BaseItemValue;
import com.amee.domain.item.data.Da... |
kdavisk6/feignx | core/src/main/java/feign/contract/TargetDefinition.java | /*
* Copyright 2019-2021 OpenFeign Contributors
*
* 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 app... |
YellowRainBoots/2.0 | homepairs/HomepairsApp/Apps/PropertyManagers/urls.py | from django.urls import path
from .views import LoginView, RegisterView, TenantControlView
urlpatterns = [
path('login/', LoginView.as_view(), name='pm_login'),
path('register/', RegisterView.as_view(), name='pm_register'),
path('tenantEdit/', TenantControlView.as_view(), name='ten_edit')
]
|
ADVRHumanoids/DrivingFramework | controllers/controllers/controllers_wheels/include/mgnss/controllers/devel/contact_point_zmp_v2.h | <reponame>ADVRHumanoids/DrivingFramework
#ifndef __MWOIBN_HIERARCHICAL_CONTROL_TASKS_CONTACT_POINT_ZMP_V2_H
#define __MWOIBN_HIERARCHICAL_CONTROL_TASKS_CONTACT_POINT_ZMP_V2_H
#include "mwoibn/hierarchical_control/tasks/contact_point_3D_rbdl_task.h"
#include "mwoibn/robot_points/point.h"
#include "mwoibn/robot_points/g... |
Diplomatiq/diplomatiq-backend | src/main/java/org/diplomatiq/diplomatiqbackend/repositories/UserDeviceRepository.java | <reponame>Diplomatiq/diplomatiq-backend<filename>src/main/java/org/diplomatiq/diplomatiqbackend/repositories/UserDeviceRepository.java
package org.diplomatiq.diplomatiqbackend.repositories;
import org.diplomatiq.diplomatiqbackend.domain.entities.concretes.UserDevice;
import org.springframework.data.neo4j.repository.Ne... |
gapatmej/trains | src/main/java/ec/com/gapatmej/entities/impl/Way.java | package ec.com.gapatmej.entities.impl;
import ec.com.gapatmej.entities.IWay;
public class Way<T> implements IWay<T> {
private final T startTown;
private final T endTown;
private final int distance;
public Way(T start, T end) {
this.startTown = start;
this.endTown = end;
this.... |
ZhangUranus/partner-fq | framework/base/src/org/ofbiz/base/util/collections/GenericMapValues.java | <filename>framework/base/src/org/ofbiz/base/util/collections/GenericMapValues.java<gh_stars>0
/*******************************************************************************
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with... |
koifans/WALinuxAgent | azurelinuxagent/ga/exthandlers.py | # Microsoft Azure Linux Agent
#
# Copyright Microsoft 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
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by app... |
rs9899/Parsing-R-CNN | rcnn/modeling/fpn/FPN.py | <reponame>rs9899/Parsing-R-CNN
import torch
import torch.nn as nn
import torch.nn.functional as F
from models.imagenet.utils import convert_conv2convws_model
from utils.net import make_conv
from rcnn.core.config import cfg
from rcnn.modeling import registry
# ---------------------------------------------------------... |
bIoTopeH2020project/O-MI | O-MI-Node/src/main/scala/types/Odf/parsing/StreamParser.scala | <filename>O-MI-Node/src/main/scala/types/Odf/parsing/StreamParser.scala<gh_stars>10-100
/*+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+ Copyright (c) 2019 Aalto University. +
+ ... |
ServiceInnovationLab/feijoa | spec/features/home_spec.rb | <reponame>ServiceInnovationLab/feijoa<gh_stars>1-10
# frozen_string_literal: true
require 'rails_helper'
RSpec.describe '/', type: :feature do
it 'shows a fancy fruit' do
visit root_path
expect(page).to have_text('Feijoa')
Percy.snapshot(page, name: 'homepage')
end
end
|
Jeremy-Chau/SJSU-Dev2 | firmware/library/L1_Drivers/test/pin_test.cpp | // Test for Pin class.
// Using a test by side effect on the LPC_IOCON register
#include "L0_LowLevel/LPC40xx.h"
#include "L1_Drivers/pin.hpp"
#include "L5_Testing/testing_frameworks.hpp"
TEST_CASE("Testing Pin", "[pin_configure]")
{
// Simulated local version of LPC_IOCON register to verify register
// manipulati... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.