repo_name
stringlengths
6
101
path
stringlengths
4
300
text
stringlengths
7
1.31M
fuelingtheweb/prettier
tests/flow/recheck/e1.js
// @flow export type Action = | { type: 'FOO' } | { type: 'BAR' } ; export const LIFE = 42;
sharabeshj/course-editor-test
modules/student_groups/student_groups_tests.py
# Copyright 2016 Google Inc. 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 # # Unless required by applicable law or ...
achavan51/googleads-java-lib-master
modules/ads_lib/src/main/java/com/google/api/ads/common/lib/utils/AdsUtility.java
<reponame>achavan51/googleads-java-lib-master<gh_stars>0 // Copyright 2015 Google Inc. 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/lic...
MyJobGlasses/graphql_devise
spec/requests/mutations/register_spec.rb
# frozen_string_literal: true require 'rails_helper' RSpec.describe 'Registration process' do include_context 'with graphql query request' let(:name) { Faker::Name.name } let(:password) { <PASSWORD> } let(:email) { Faker::Internet.email } let(:redirect) { 'https://google.com' } context 'when usin...
DronM/osbe
build/templates/js20.proj-tmpl/controls/GridAjxMaster.js
<reponame>DronM/osbe<gh_stars>0 /* Copyright (c) 2016-2017 <NAME>, Katren ltd. */ /* Description */ /** Requirements * @requires * @requires core/extend.js */ /* constructor @param string id @param object options{ } */ function GridAjxMaster(id,options){ options = options || {}; this.setDetailControl(op...
JoseAVallejo12/holbertonschool-web_react
0x09-react_redux_reducer_selector/task_5/dashboard/src/schema/courses.js
<gh_stars>0 import { normalize, schema } from 'normalizr'; const courses = new schema.Entity('courses'); export const coursesNormalizer = (data) => { return normalize(data, [courses]).entities.courses; };
tirth1/JavaScript
logicalOps.js
<reponame>tirth1/JavaScript let a1 = true let a2 = false let a3 = true if(a1 && a2){ console.log('a1 and a2 are true') } else if(a2 || a3){ console.log('a2 or a3 are true') } else{ console.log('Nothing...') }
vladimirtkach/yesjob
src/sales/migrations/0006_auto_20190905_0857.py
<filename>src/sales/migrations/0006_auto_20190905_0857.py # Generated by Django 2.2 on 2019-09-05 08:57 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('sales', '0005_auto_20190904_1720'), ] operations = [ migrations.AlterField( ...
paulevsGitch/BetterNetherBeta
src/main/java/paulevs/bnb/world/biome/CorruptedLandsBiome.java
<filename>src/main/java/paulevs/bnb/world/biome/CorruptedLandsBiome.java package paulevs.bnb.world.biome; import paulevs.bnb.block.types.NetherTerrainType; import paulevs.bnb.listeners.BlockListener; import paulevs.bnb.util.BlockState; import paulevs.bnb.world.structures.NetherStructures; import java.util.Random; pu...
jacksonsr45/TravelAndCashControl
domain/use_cases/user_manager/address/UpdateAddress.java
package domain.use_cases.user_manager.address; import domain.entity.UserAddressEntity; import domain.gateway.UserAddressInterface; import domain.presenter.UserAddressPresenterInterface; import domain.requests.UpdateAddressRequest; public class UpdateAddress extends UpdateAddressFactory { public UpdateAddress(User...
ReCursia/Sonic
core/src/com/studentsteam/sonic/Main.java
<reponame>ReCursia/Sonic package com.studentsteam.sonic; import com.badlogic.gdx.graphics.g2d.SpriteBatch; import com.badlogic.gdx.Game; import com.studentsteam.sonic.screens.StartScreen; public class Main extends Game { public static int SAVE_INDEX; //Save index public static final int WIDTH = 1024; public stati...
slaveuser/blade20170127
blade-core/src/main/java/blade/BladeFilter.java
/** * Copyright (c) 2015, biezhi 王爵 (<EMAIL>) * * 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...
HakuSen/report
src/components/icons/simple/images.js
import Icon from '../Icon'; Icon.register({ images: { width: 576, height: 512, paths: [{ d: 'M480 416V432C480 458.5 458.5 480 432 480H48C21.5 480 0 458.5 0 432V176C0 149.5 21.5 128 48 128H64V336C64 380.1 99.9 416 144 416H480zM576 336V80C576 53.5 554.5 32 528 32H144C117.5 32 96 53.5 96 80V336C96 362...
harshp8l/deep-learning-lang-detection
data/test/cpp/37c879f732bb5301ed0114a2778626c2b966577aChunkHandler.cpp
<filename>data/test/cpp/37c879f732bb5301ed0114a2778626c2b966577aChunkHandler.cpp // 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, version 3.0. // This program is distributed in the hope that ...
krahman/ember-bootstrap
packages/ember-bootstrap/lib/views/breadcrumb.js
require("ember-bootstrap/mixins/item_view_title_support"); require("ember-bootstrap/mixins/first_last_view_support"); var get = Ember.get; var Bootstrap = window.Bootstrap; Bootstrap.Breadcrumb = Ember.CollectionView.extend(Bootstrap.FirstLastViewSupport, { tagName: "ul", classNames: "breadcrumb", divider: "/",...
rajeshnaroth/curator
curator-web/src/js/actions/newVideo.js
<reponame>rajeshnaroth/curator import { fetchVideoDetails } from '../api/youtube' export const FETCHED_NEW_VIDEO = 'FETCHED_NEW_VIDEO' // add new video export const fetchNewVideoFromYouTube = (videoId) => { return (dispatch) => { return fetchVideoDetails(videoId).then(videoData => { dispatch({type: FETCHED_NEW...
claytonjwong/leetcode-js
contest204.js
<filename>contest204.js /* * Weekly Contest 204 * * Rank Name Score Finish Time Q1 (3) Q2 (4) Q3 (6) Q4 (7) * 2025 / 13949 claytonjwong 7 0:50:49 0:17:53 0:40:49 *2 * * Ranking: https://leetcode.com/contest/weekly-contest-204/ranking/81/ * Screen...
k-czajka/fh
fhdp/fhdp-commons/fhdp-commons-transport/src/main/java/pl/fhframework/dp/transport/endpoints/IEndpointCfgService.java
package pl.fhframework.dp.transport.endpoints; import pl.fhframework.dp.commons.base.model.IEndpointCfgDefinition; /** * @author <a href="mailto:<EMAIL>"><NAME></a> * @version : $, : $ * @created 10/02/2021 */ public interface IEndpointCfgService { EndpointCfgDto getEndpointCfg(IEndpointCfgDefinition endpoi...
xiaohua9/project1
src/com/u1/day5/ChengFaBiao.java
<reponame>xiaohua9/project1 package com.u1.day5; /*龙小华 2019-6-28 99乘法表*/ public class ChengFaBiao { public static void main(String[] args) { for (int i=1;i<=9;i++){ for (int j=1;j<=i;j++){ System.out.print(j+"*"+i+"="+(i*j)+"\t"); } System.out.pr...
thewtex/scikit-image
skimage/io/_plugins/q_color_mixer.py
<gh_stars>1-10 # the module for the qt color_mixer plugin from qtpy import QtCore from qtpy.QtWidgets import (QWidget, QStackedWidget, QSlider, QGridLayout, QLabel, QFrame, QComboBox, QRadioButton, QPushButton) from .util import ColorMixer class IntelligentSlid...
Trydamere/shardingsphere
shardingsphere-infra/shardingsphere-infra-common/src/main/java/org/apache/shardingsphere/infra/datanode/DataNodes.java
<gh_stars>1000+ /* * 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 "Lic...
nowkoai/test
ee/spec/controllers/sitemap_controller_spec.rb
<reponame>nowkoai/test # frozen_string_literal: true require 'spec_helper' RSpec.describe SitemapController do describe '#show' do subject { get :show, format: :xml } before do allow(Gitlab).to receive(:com?).and_return(dot_com) end context 'when not Gitlab.com?' do let(:dot_com) { fal...
layered-pieces/objc-pieces
xcode-templates/rib.xctemplate/ViewControllerpresenterinteractorDelegate/___FILEBASENAME___ViewController.h
// // ___FILENAME___ // ___PROJECTNAME___ // // Created by ___FULLUSERNAME___ on ___DATE___. // Copyright ___YEAR___ ___ORGANIZATIONNAME___. All rights reserved. // #import <UIKit/UIKit.h> NS_ASSUME_NONNULL_BEGIN @class ___VARIABLE_productName___ViewController; @protocol ___VARIABLE_productName___ViewController...
ch-jin/bundle-app
client/test/components/splash/session_form_test.js
import sinon from "sinon"; import { renderComponent, renderAndUnmountComponent, expect, } from "../../test_helper"; import * as actions from "../../../actions/session_actions"; import SessionFormContainer from "../../../components/splash/SessionFormContainer"; describe("SessionFormContainer", () => { let compo...
hicham1987/CapexApp
node_modules/ngx-charts/release/area-chart/index.js
"use strict"; function __export(m) { for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p]; } __export(require('./area-chart.module')); __export(require('./area-chart.component')); __export(require('./area-chart-normalized.component')); __export(require('./area-chart-stacked.component')); __export(requ...
rien/nanoc
nanoc/spec/nanoc/regressions/gh_761_spec.rb
<gh_stars>1000+ # frozen_string_literal: true describe 'GH-761', site: true do before do File.write('content/donkey.md', 'Compiled content donkey!') File.write('layouts/foo.erb', '[<%= @item.compiled_content %>]') File.write('Rules', <<EOS) compile '/**/*' do layout '/foo.*' write '/donkey.ht...
Ujjawalgupta42/Hacktoberfest2021-DSA
04. Arrays/distribute_n_candies_k_kids.cpp
<reponame>Ujjawalgupta42/Hacktoberfest2021-DSA<gh_stars>100-1000 #include <bits/stdc++.h> using namespace std; // Function to find out the number of // candies every person received void candies(int n, int k) { // Count number of complete turns int count = 0; // Get the last term int ind = 1; // Stores the nu...
ridi/chromium-aw
src/main/java/org/chromium/network/mojom/WebSandboxFlags.java
// WebSandboxFlags.java is auto generated by mojom_bindings_generator.py, do not edit // Copyright 2014 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. // This file is autogenerated by: // mojo/public/tools/binding...
Acidburn0zzz/peridot
bin/ledger/tests/integration/merging_tests.cc
<reponame>Acidburn0zzz/peridot<filename>bin/ledger/tests/integration/merging_tests.cc<gh_stars>1-10 // 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 <map> #include <utility> #include <vector> #i...
lilsweetcaligula/MIT6.00.1x
Puzzles/checkio/Home/Median/mySolution.py
<filename>Puzzles/checkio/Home/Median/mySolution.py<gh_stars>0 def findAv(*args): return sum(args)/len(args) def checkio(data): data.sort() if ( len(data) % 2 ) == 0: return findAv( float(data[ len(data) / 2 ]), float(data[ len(data) / 2 - 1 ]) ) return data[ len(data) / 2 ]
SenthilKumarGS/TizenRT
external/include/libcxx/wctype.h
/**************************************************************************** * * Copyright 2018 Samsung Electronics 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...
TheBlankArrays/Scrapinit
server/specs/addUrlSpecs.js
<reponame>TheBlankArrays/Scrapinit var serverHost = 'http://localhost:3000'; var should = require('should'); var assert = require('assert'); var supertest = require('supertest'); var request = supertest(serverHost); var Sequelize = require('sequelize'); var db = require('../dbConfig'); var bcrypt = require('bcrypt'); v...
codyseibert/ef-cms
web-client/src/presenter/actions/setViewerCorrespondenceToDisplayAction.test.js
<filename>web-client/src/presenter/actions/setViewerCorrespondenceToDisplayAction.test.js import { applicationContextForClient as applicationContext } from '../../../../shared/src/business/test/createTestApplicationContext'; import { presenter } from '../presenter-mock'; import { runAction } from 'cerebral/test'; impor...
Jiyong-GAL/NodeShopping
testSchema.js
<reponame>Jiyong-GAL/NodeShopping<filename>testSchema.js var mongoose = require('mongoose'); var testSchema = new mongoose.Schema({ connectIP:{ type : String ,required :true } ,connectTime:String }); mongoose.model('test2',testSchema); module.exports = mongoose.model('test2');
hakandrmz/CampNotes
Hafta22OOP/src/oop2/Main.java
<reponame>hakandrmz/CampNotes package oop2; public class Main { public static void main(String[] args) { Customer corporateCustomer1 = new CorporateCustomer(1,"123456","<EMAIL>","Turkcell","1232123"); IndividualCustomer individualCustomer = new IndividualCustomer(1,"123456","<EMAIL>","Turkcell","1232123","123...
SIIS-cloud/pileus
libvirt/pileus-libvirt-1.2.12/src/esx/esx_nwfilter_driver.h
/* * esx_nwfilter_driver.h: nwfilter driver functions for managing VMware ESX * firewall rules * * Copyright (C) 2010 <NAME> <<EMAIL>> * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by t...
yufan022/tidb
expression/distsql_builtin_serial_test.go
<filename>expression/distsql_builtin_serial_test.go<gh_stars>1-10 // Copyright 2021 PingCAP, 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/...
lieff/lvg
tests/swf/trace/netstream-onmetadata.c
/* gcc `pkg-config --libs --cflags libming` netstream-onmetadata.c -o netstream-onmetadata && ./netstream-onmetadata */ #include <ming.h> int main (int argc, char **argv) { SWFMovie movie; SWFVideoStream video; SWFDisplayItem item; SWFAction action; if (Ming_init ()) return 1; Ming_useSWFVersion (7)...
murilopolese/learning-platform-gatsby
src/utils/jsonToReact.js
import React from 'react' import { Container, Grid, Box } from '@material-ui/core' import Palette from '../components/palette' import Typography from '../components/typography' import Card from '../components/card' import Button from '../components/button' import Youtube from '../components/youtubedisplay' import Image...
xxxmian/mediator-time
src/main/java/org/fmgroup/mediator/language/statement/PauseStatement.java
package org.fmgroup.mediator.language.statement; import org.antlr.v4.runtime.ParserRuleContext; import org.fmgroup.mediator.language.RawElement; import org.fmgroup.mediator.language.ValidationException; import org.fmgroup.mediator.language.generated.MediatorLangParser; import org.fmgroup.mediator.language.term.NullVal...
MOPCON/App-Android
src/containers/MissionDetail/QRCode.js
<gh_stars>1-10 import React, { Component } from 'react'; import { Text } from 'react-native'; import I18n from '../../locales'; import { MISSION_STATUS, Consumer } from '../../store'; import iconCoinImg from '../../images/icon/iconCoin.png'; import * as Style from './style'; @Consumer('missionStore') export default cl...
asiboro/asiboro.github.io
vsdoc/search--/s_329.js
search_result['329']=["topic_00000000000000A7_vars--.html","AuthenticationScheme Fields",""];
karreypradeep/BlueSpaceTechEmailApp
EmailApp/src/main/java/com/bluespacetech/security/service/UserAuthenticationProvider.java
package com.bluespacetech.security.service; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.security.authentication.BadCredentialsException; import org.springframework.security.authentication.UsernamePasswordAuthenticationToken; import org.springframework.security.authent...
coderZsq/coderZsq.practice.server
study-notes/j2ee-collection/architecture/02-分布式事务/mysql-demo/src/main/java/com/sq/demo/mysqldemo/demo/JdbcDemo.java
package com.sq.demo.mysqldemo.demo; import java.sql.Connection; import java.sql.DriverManager; import java.sql.PreparedStatement; public class JdbcDemo { public static void main(String[] args) throws Exception { String url = "jdbc:mysql://localhost:3306/test"; String user = "root"; String ...
Arronzheng/roncoo-education
roncoo-education-course/roncoo-education-course-service/src/main/java/com/roncoo/education/course/service/common/resq/ActivityCourseViewRESQ.java
<gh_stars>1-10 package com.roncoo.education.course.service.common.resq; import com.fasterxml.jackson.databind.annotation.JsonSerialize; import com.fasterxml.jackson.databind.ser.std.ToStringSerializer; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import lombok.Data; import lo...
hoojaoh/pick
safe/edit_test.go
<reponame>hoojaoh/pick package safe import ( "testing" ) func TestEdit(t *testing.T) { safe, err := createTestSafe(t, true) if err != nil { t.Error(err) } account, err := safe.Edit("foo", "Bubbles", "kitt3ns") if err != nil { t.Error(err) } if account.Username != "Bubbles" { t.Errorf("Expected username...
cotobadesign/cotoba-agent-oss
dialogue-engine/test/programytest/utils/geo/test_geonames.py
<gh_stars>100-1000 """ Copyright (c) 2020 COTOBA DESIGN, 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, mer...
huifer/action-flow
action-flow-storage/action-flow-mysql-storage/src/main/java/com/github/brick/action/flow/storage/mysql/util/MybatisUtil.java
<gh_stars>0 /* * Copyright [2022] [brick-team] * * 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 require...
nerkarso/demo
pages/_app.js
<reponame>nerkarso/demo import { AuthProvider } from '@/contexts/AuthContext'; import '@/styles/index.css'; import { pageview } from '@/utils/gtag'; import { ThemeProvider } from 'next-themes'; import Head from 'next/head'; import { useRouter } from 'next/router'; import { useEffect } from 'react'; import { Slide, Toas...
jimbethancourt/topic-viewer
TopicViewer/src/br/ufmg/aserg/topicviewer/control/semantic/SemanticTopicsCalculator.java
package br.ufmg.aserg.topicviewer.control.semantic; import java.io.IOException; import java.util.HashSet; import java.util.Set; import cern.jet.math.tdouble.DoubleFunctions; import cern.jet.math.tdouble.DoublePlusMultFirst; import org.splabs.vocabulary.filter.IdentifierFilter; import ptstemmer.exceptions.P...
agpoulsen/aem-orchestrator
src/test/java/com/shinesolutions/aemorchestrator/config/AwsConfigTest.java
<filename>src/test/java/com/shinesolutions/aemorchestrator/config/AwsConfigTest.java package com.shinesolutions.aemorchestrator.config; import com.amazonaws.ClientConfiguration; import com.amazonaws.auth.AWSCredentialsProvider; import com.shinesolutions.aemorchestrator.model.ProxyDetails; import org.junit.Before; impo...
carrenolg/golang
courses/1.Go(golang)/section_06/004-bit-shifting/main.go
package main import "fmt" // using iota with bit shift func main() { // base 10 kb := 1024 mb := kb * 1024 gb := mb * 1024 fmt.Printf("decimal:%d,\t\tbinary:%b\n", kb, kb) fmt.Printf("decimal:%d,\tbinary:%b\n", mb, mb) fmt.Printf("decimal:%d,\tbinary:%b\n", gb, gb) // using bit shift with iota const ( _ ...
wangshankun/Tengine_Atlas
executor/operator/ref/kernel/argmax/ref_argmax_int8.c
<reponame>wangshankun/Tengine_Atlas<gh_stars>10-100 static int ref_argmax_int8(int8_t* input, int8_t* output, ref_argmax_param* param) { return 0; }
stoman/CompetitiveProgramming
problems/primality/submissions/accepted/Stefan.java
<reponame>stoman/CompetitiveProgramming //Author: <NAME> import java.io.*; import java.util.*; import java.text.*; import java.math.*; import java.util.regex.*; public class Stefan { public static boolean isPrime(int n) { if(n <= 1) { return false; } for(int i = 2; i*i <= ...
R-YaTian/LC.VC.SA.Plugin
wm_sachs/dllmain.cpp
#include <windows.h> #include "CPlugin.h" BOOL WINAPI DllMain(HMODULE hDllHandle, DWORD dwReason, LPVOID lpreserved) { if (dwReason == DLL_PROCESS_ATTACH) { return (CPlugin::CheckResourceFile(hDllHandle) && CPlugin::CheckGameVersion()); } return TRUE; }
braswelljr/alGOrithm
utils/getArray.go
package utils import "fmt" func GetArray() ([]int, int, error) { // get array of integers var arrayLen int fmt.Printf("Please enter the length of the Array : ") // read the length of the array by input _, err := fmt.Scan(&arrayLen) // handle input error if err != nil { fmt.Printf("\nError : %v", err) } //...
silenc3502/PersonalProject-1
junhurkahn/BackEnd/demo/src/main/java/com/example/demo/repository/jpa/order58/VueJpaMemberWithAuthRepository.java
<gh_stars>10-100 package com.example.demo.repository.jpa.order58; import com.example.demo.entity.jpa.VueJpaMemberWithAuth; import org.springframework.data.jpa.repository.JpaRepository; import org.springframework.data.jpa.repository.Query; import java.util.Optional; public interface VueJpaMemberWithAuthRepository ext...
Anioko/TestApp
app/blueprints/marketplace/apis.py
from flask import session, render_template from flask_login import current_user from flask_restful import Resource, reqparse from app.models import User, MCart, MProduct, MShippingMethod, MCartItem, MSellerCart from app.utils import jsonify_object, db def get_current_cart(): session_id = session['cart_id'] i...
11676670/webmanager
src/main/java/com/jspxcms/common/file/LocalFileHandler.java
package com.jspxcms.common.file; import java.awt.image.BufferedImage; import java.io.File; import java.io.FileInputStream; import java.io.FileNotFoundException; import java.io.FileOutputStream; import java.io.IOException; import java.io.InputStream; import java.io.OutputStream; import java.io.OutputStreamWri...
brunomendola/querity
querity-common/src/main/java/net/brunomendola/querity/common/mapping/condition/NotConditionMapper.java
<gh_stars>1-10 package net.brunomendola.querity.common.mapping.condition; import net.brunomendola.querity.api.Condition; import net.brunomendola.querity.api.NotCondition; import net.brunomendola.querity.common.mapping.PropertyNameMapper; class NotConditionMapper implements ConditionMapper<NotCondition> { @Override ...
bhnybrohn/turbo-sniffle
src/components/home/midsection.js
import React from 'react' import Consult from '../img/services/consult.svg' import Maintananace from '../img/services/repair.svg' import Building from '../img/services/building.svg' import Settings from '../img/services/settings.svg' import './slider.css' export default function midSection() { return ( <di...
Manifesto-Digital/contentful-gatsby-netlify
src/components/download-banner/styles.js
<reponame>Manifesto-Digital/contentful-gatsby-netlify import styled from 'styled-components'; import { breakpoint } from '../theme/breakpoint'; export const Banner = styled.div` padding: ${({ theme }) => theme.spacing.standard} 0; margin-bottom: ${({ removeMarginBottom, theme }) => removeMarginBottom ? '0' : t...
mxc-foundation/lora-app-server
internal/grpcauth/grpcauth_test.go
package grpcauth import ( "context" "fmt" "strings" "testing" "time" "github.com/gofrs/uuid" "github.com/lestrrat-go/jwx/jwa" ljwt "github.com/lestrrat-go/jwx/jwt" "google.golang.org/grpc/metadata" "github.com/mxc-foundation/lpwan-app-server/internal/auth" "github.com/mxc-foundation/lpwan-app-server/inter...
hmrc/penalties-appeals-frontend
test/models/AppealDataSpec.scala
/* * Copyright 2022 HM Revenue & Customs * * 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 a...
tjim/smpcc
runtime/ot/io.go
package ot import "math/big" type NPChans struct { ParamChan chan *big.Int `fatchan:"reply"` NpRecvPk chan *big.Int `fatchan:"request"` NpSendEncs chan HashedElGamalCiph `fatchan:"reply"` } type ExtChans struct { OtExtChan chan []byte `fatchan:"request"` OtExtSelChan chan Selector `fat...
dplbsd/soc2013
head/contrib/gcclibs/libgomp/config/linux/bar.c
<reponame>dplbsd/soc2013 /* Copyright (C) 2005 Free Software Foundation, Inc. Contributed by <NAME> <<EMAIL>>. This file is part of the GNU OpenMP Library (libgomp). Libgomp is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by ...
SuperIlu/jSH
watt32-2.2dev.rel.11/src/transmit.c
<gh_stars>10-100 /*!\file transmit.c * BSD send(), sendto(), write(). */ /* BSD sockets functionality for Watt-32 TCP/IP * * Copyright (c) 1997-2002 <NAME> <<EMAIL>> * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions *...
watchd1/ZwitscherA
src/de/bsd/zwitscher/UserDetailActivity.java
package de.bsd.zwitscher; import android.app.ActionBar; import android.app.Activity; import android.content.Context; import android.content.Intent; import android.content.SharedPreferences; import android.graphics.Bitmap; import android.graphics.Color; import android.graphics.drawable.Drawable; import android.net.Uri;...
ihotray/gomedia
mp4/trun-box.go
package mp4 import "encoding/binary" // aligned(8) class TrackRunBox extends FullBox(‘trun’, version, tr_flags) { // unsigned int(32) sample_count; // // the following are optional fields // signed int(32) data_offset; // unsigned int(32) first_sample_flags; // // all fields in the following...
jacadcaps/webkitty
Source/WebCore/bindings/js/JSWorkletGlobalScopeBase.h
/* * Copyright (C) 2018 Apple 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 the above copyright * notice, this list of conditions a...
belonk/spring5-demo
04-spring-mvc/src/main/java/com/belonk/springmvc/config/RootConfig.java
package com.belonk.springmvc.config; import org.springframework.beans.factory.annotation.Configurable; import org.springframework.context.annotation.ComponentScan; import org.springframework.context.annotation.FilterType; import org.springframework.stereotype.Controller; /** * 根容器,扫描除了Controller的其他所有组件。 * <p> * Cr...
RemnevMaksim/splinter
src/main/java/ru/yandex/autoschool/splinter/di/provider/LoggerProvider.java
<reponame>RemnevMaksim/splinter<gh_stars>1-10 package ru.yandex.autoschool.splinter.di.provider; import org.apache.log4j.BasicConfigurator; import org.glassfish.hk2.api.Factory; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import ru.yandex.autoschool.splinter.application.Splinter; /** * @author Etki {@li...
svenfuchs/ripper2ruby
test/lib_test_helper.rb
$: << File.expand_path(File.dirname(__FILE__) + '/../lib') require 'pp' require 'ripper/ruby_builder' require 'ripper/event_log' require 'highlighters/ansi' require 'erb/stripper' require 'diff/lcs' require 'diff/lcs/hunk' module LibTestHelper def build(src, filename = nil) Ripper::RubyBuilder.build(src, filena...
breath-co2/hprose-nodejs
example/filter/log/logfilter.js
var hprose = require('hprose'); function log(data) { console.log(hprose.BytesIO.toString(data)); return data; } module.exports = { inputFilter: log, outputFilter: log };
andersop91/core
tests/components/homekit_controller/specific_devices/test_aqara_gateway.py
<gh_stars>1000+ """ Regression tests for Aqara Gateway V3. https://github.com/home-assistant/core/issues/20957 """ from homeassistant.components.alarm_control_panel import ( SUPPORT_ALARM_ARM_AWAY, SUPPORT_ALARM_ARM_HOME, SUPPORT_ALARM_ARM_NIGHT, ) from homeassistant.components.light import SUPPORT_BRIGHTN...
juliocnsouzadev/scala_datascience
functional_program_design_in_scala/functional_program_design_in_scala/.worksheet/src/week02.StructuralInductionOnTrees.scala
package week02 object StructuralInductionOnTrees {;import org.scalaide.worksheet.runtime.library.WorksheetSupport._; def main(args: Array[String])=$execute{;$skip(67); val x = 10;System.out.println("""x : Int = """ + $show(x ));$skip(12); val y = 5;System.out.println("""y : Int = """ + $show(y ));$skip(16);...
tiff2766/DK
DK/Libs/zstd/tests/fuzz/simple_round_trip.c
<filename>DK/Libs/zstd/tests/fuzz/simple_round_trip.c /* * Copyright (c) 2016-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under both the BSD-style license (found in the * LICENSE file in the root directory of this source tree) and the GPLv2 (found * in the COPYING file in the r...
frontful/frontful-platform
packages/frontful-resolver/resolver/Resolver.js
import {Exceptions} from './Exceptions' import {observer as mobxObserver} from 'mobx-react' import {Promisable as PromisableClass, deferred, getDisplayName, isBrowser} from 'frontful-utils' import {untracked, observable, reaction} from 'mobx' import React from 'react' let Promisable let observer if (isBrowser()) { ...
Neusoft-Technology-Solutions/aws-sdk-cpp
aws-cpp-sdk-datasync/include/aws/datasync/model/SmbVersion.h
/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include <aws/datasync/DataSync_EXPORTS.h> #include <aws/core/utils/memory/stl/AWSString.h> namespace Aws { namespace DataSync { namespace Model { enum class SmbVersion { NOT_SET...
Pioneer-Robotics/FTCPioneer2020-2021
TeamCode/src/main/java/org/firstinspires/ftc/teamcode/Autonomous/SkystoneAutoBridgeSimple.java
<filename>TeamCode/src/main/java/org/firstinspires/ftc/teamcode/Autonomous/SkystoneAutoBridgeSimple.java<gh_stars>0 package org.firstinspires.ftc.teamcode.Autonomous; import com.qualcomm.robotcore.eventloop.opmode.Autonomous; import com.qualcomm.robotcore.util.ElapsedTime; //@Autonomous(name = "SkystoneBridgeSimple",...
falko/zeebe
engine/src/main/java/io/zeebe/engine/state/DefaultZeebeDbFactory.java
/* * Zeebe Workflow Engine * Copyright © 2017 camunda services GmbH (<EMAIL>) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Affero General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your optio...
jstoobz/hack-reactor-prep
Module 1/137_getLongestOfThreeWords.js
<reponame>jstoobz/hack-reactor-prep function getLongestOfThreeWords(word1, word2, word3) { return Array.from(arguments).reduce((acc, item) => { return acc.length >= item.length ? acc : item; }); } var output = getLongestOfThreeWords('these', 'three', 'words'); console.log(output);
JoshuaMeyers/ssbio
ssbio/test/test_databases_kegg.py
import pytest import os.path as op from Bio import SeqIO from Bio.Seq import Seq from Bio.SeqRecord import SeqRecord from Bio.Alphabet import IUPAC from BCBio import GFF from ssbio.databases.kegg import KEGGProp @pytest.fixture(scope='class') def seq_record_loaded_from_file_example(fasta_path): """Original SeqReco...
opennetworkinglab/spring-open
src/main/java/net/onrc/onos/core/datagrid/web/DatagridWebRoutable.java
<reponame>opennetworkinglab/spring-open package net.onrc.onos.core.datagrid.web; import net.floodlightcontroller.restserver.RestletRoutable; import org.restlet.Context; import org.restlet.Restlet; import org.restlet.routing.Router; /** * REST API implementation for the Datagrid. */ public class DatagridWebRoutable...
Miausoft/miausp-api
src/main/java/com/miausoft/miaups/paypal/discounts/WeekendDiscount.java
<filename>src/main/java/com/miausoft/miaups/paypal/discounts/WeekendDiscount.java package com.miausoft.miaups.paypal.discounts; import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty; import org.springframework.stereotype.Component; import java.math.BigDecimal; import java.time.DayOfWeek; impor...
softicar/platform
platform-dom/src/main/java/com/softicar/platform/dom/elements/button/DomButton.java
<gh_stars>1-10 package com.softicar.platform.dom.elements.button; import com.softicar.platform.common.core.i18n.IDisplayString; import com.softicar.platform.common.core.interfaces.INullaryVoidFunction; import com.softicar.platform.common.core.interfaces.IStaticObject; import com.softicar.platform.common.io.resource.IR...
benbenwt/lisa_docker
new/libr/asm/arch/amd29k/amd29k.h
#ifndef ASM_AMD_29K_H #define ASM_AMD_29K_H #include <stdint.h> #include <r_types.h> #ifdef __cplusplus extern "C" { #endif #define CPU_29000 "29000" #define CPU_29050 "29050" typedef struct amd29k_instr_s { const char* mnemonic; ut64 op_type; ut32 operands[6]; char type[6]; } amd29k_instr...
tig/Tigger
Microsoft/SAMPLES/status/resource.h
<filename>Microsoft/SAMPLES/status/resource.h<gh_stars>1-10 #define IDM_ABOUT 100 #define IDM_FILEEXIT 101 #define IDM_NEXTMSG 102 #define IDD_TOP 200 #define IDD_BOTTOM 201 #define IDD_DESC 202
faraz891/gitlabhq
spec/migrations/reseed_merge_trains_enabled_spec.rb
<reponame>faraz891/gitlabhq # frozen_string_literal: true require 'spec_helper' require Rails.root.join('db', 'migrate', '20201112195322_reseed_merge_trains_enabled.rb') RSpec.describe ReseedMergeTrainsEnabled do describe 'migrate' do let(:project_ci_cd_settings) { table(:project_ci_cd_settings) } let(:proj...
alifoliveira/rep-estudos
test/short_list.py
<reponame>alifoliveira/rep-estudos<filename>test/short_list.py # List comprehension # method 1 syntax: # list = [] # for x in expression: # list.append(x) # Method 2 syntax: # list(map(function, sequence)) # list(map(lambda x: x*7, range(11))) # method 3 syntax: # [return for x in sequence] # [x*7 for x in range...
ityuhui/client-c
model/v1_iscsi_persistent_volume_source.c
#include <stdlib.h> #include <string.h> #include <stdio.h> #include "v1_iscsi_persistent_volume_source.h" v1_iscsi_persistent_volume_source_t *v1_iscsi_persistent_volume_source_create( int chapAuthDiscovery, int chapAuthSession, char *fsType, char *initiatorName, char *iqn, char *iscsiInterfa...
hangilc/myclinic-spring
winutil/src/main/java/jp/chang/myclinic/winutil/main/CreateShortcut.java
<filename>winutil/src/main/java/jp/chang/myclinic/winutil/main/CreateShortcut.java package jp.chang.myclinic.winutil.main; import jp.chang.myclinic.winutil.ShellLink; import java.nio.file.Path; import java.nio.file.Paths; public class CreateShortcut { public static void main(String[] args) { if ( !(args...
amallya18/TwitterRedux
app/src/main/java/com/github/anmallya/twitterredux/data/DbHelper.java
package com.github.anmallya.twitterredux.data; import com.github.anmallya.twitterredux.models.Media; import com.github.anmallya.twitterredux.models.Media_Table; import com.raizlabs.android.dbflow.sql.language.SQLite; import java.util.List; /** * Created by anmallya on 10/29/2016. */ public class DbHelper { pu...
shenkevin/B2CStore
app/src/main/java/cn/mstar/store/entity/ProIdAndNums.java
package cn.mstar.store.entity; /** * Created by Administrator on 2015/8/12. */ public class ProIdAndNums { public int proId; public int number; }
tvallin/helidon-build-tools
dev-loop/dev-loop/src/main/java/io/helidon/build/devloop/maven/MavenGoalReferenceResolver.java
/* * Copyright (c) 2020, 2021 Oracle and/or its affiliates. * * 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 ...
kal727/l5r-sandbox
server/game/cards/locations/01/plazaofpunishment.js
const DrawCard = require('../../../drawcard.js'); class PlazaOfPunishment extends DrawCard { setupCardAbilities(ability) { this.reaction({ when: { afterChallenge: ({challenge}) => challenge.winner === this.controller && challenge.challengeType === 'power' }, ...
ma6yu/Kratos
applications/RANSApplication/custom_elements/convection_diffusion_reaction_element.h
<reponame>ma6yu/Kratos // | / | // ' / __| _` | __| _ \ __| // . \ | ( | | ( |\__ ` // _|\_\_| \__,_|\__|\___/ ____/ // Multi-Physics // // License: BSD License // Kratos default license: kratos/license.txt // // Main authors: <NAME> ...
Sage-Bionetworks/Genie
genie_registry/cna.py
<gh_stars>1-10 import logging import os import pandas as pd import synapseclient from genie.example_filetype_format import FileTypeFormat from genie import process_functions logger = logging.getLogger(__name__) def validateSymbol(gene, bedDf, returnMappedDf=True): ''' Validate gene symbol Args: ...
ladaegorova18/trik-studio
qrutils/interpreter/blocks/preconditionalLoopBlock.cpp
/* Copyright 2019 CyberTech Labs 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 License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agree...
fernandoporazzi/brazilian-utils
utilities/cities/cities.go
<reponame>fernandoporazzi/brazilian-utils<filename>utilities/cities/cities.go<gh_stars>0 package cities import ( "fmt" "log" "github.com/fernandoporazzi/brazilian-utils/data" "github.com/fernandoporazzi/brazilian-utils/utilities/states" ) // GetCities returns all Brazilian cities if no state is passed as argumen...