repo_name stringlengths 6 101 | path stringlengths 4 300 | text stringlengths 7 1.31M |
|---|---|---|
dplbsd/soc2013 | head/sys/cam/ctl/ctl_private.h | <filename>head/sys/cam/ctl/ctl_private.h
/*-
* Copyright (c) 2003, 2004, 2005, 2008 Silicon Graphics International Corp.
* 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. Redistributio... |
ttungl/Coding-Interview-Challenge | source-code/Maximum Depth of Binary Tree 104.py | <reponame>ttungl/Coding-Interview-Challenge
# 104. Maximum Depth of Binary Tree
# <EMAIL>
# Definition for a binary tree node.
# class TreeNode(object):
# def __init__(self, x):
# self.val = x
# self.left = None
# self.right = None
class Solution(object):
def maxDepth(self, root):
... |
cool112/game | src/main/java/com/garowing/gameexp/game/rts/skill/script/effect/trigger/BlockEffectTriggerPrototype.java | <filename>src/main/java/com/garowing/gameexp/game/rts/skill/script/effect/trigger/BlockEffectTriggerPrototype.java<gh_stars>0
package com.garowing.gameexp.game.rts.skill.script.effect.trigger;
import com.garowing.gameexp.game.rts.skill.constants.SkillEventType;
import com.garowing.gameexp.game.rts.skill.constants.Trig... |
mikiec84/chantek | commands/bengwiki/command.py | from . import bengwiki
CACHEABLE = True
methods = ("define", "pagetext")
arguments = {
"expanded" : False,
"q" : {
"required" : True,
"type" : str
}
}
def run(args, method):
if method == "define":
return bengwiki.define(args["q"], expanded = args["expanded"])
elif method ==... |
donmccaughey/fiends_and_fortune | src/magic/spell.c | <reponame>donmccaughey/fiends_and_fortune
#include "spell.h"
#include <assert.h>
#include <stddef.h>
#include <base/base.h>
#include <mechanics/mechanics.h>
char const *
spell_determine(struct rnd *rnd,
enum spell_type spell_type,
int spell_level)
{
assert(spell_level >= 1);
a... |
haibowen/AndroidStudy | MyTest002/app/src/main/java/activity/ListViewActivity.java | <filename>MyTest002/app/src/main/java/activity/ListViewActivity.java<gh_stars>0
package activity;
import android.content.BroadcastReceiver;
import android.content.ContentValues;
import android.content.Context;
import android.content.Intent;
import android.content.IntentFilter;
import android.database.sqlite.SQLiteData... |
zhangwei217245/Lego | Meshwork/src/main/java/mr/x/meshwork/edge/EdgeBizFilter.java | package mr.x.meshwork.edge;
/**
* Created by zhangwei on 14-4-2.
* @author zhangwei
*/
public interface EdgeBizFilter<V> {
public boolean accept(Edge edge);
public V value();
}
|
tommorse/nrn | src/nrniv/rotate3d.cpp | #include <../../nrnconf.h>
#if HAVE_IV // to end of file
#include <math.h>
#include <InterViews/canvas.h>
#include <IV-look/kit.h>
#include <InterViews/font.h>
#include <InterViews/polyglyph.h>
#include "rot3band.h"
#include <stdio.h>
#include "nrnoc2iv.h"
#include "shape.h"
#include "ivoc.h"
#define Rotate_ "Rotate... |
mion00/predict-react | src/__tests__/reducers/Splits.test.js | <filename>src/__tests__/reducers/Splits.test.js
/**
* Created by tonis.kasekamp on 02/07/18.
*/
import splits from '../../reducers/Splits';
import {
splitFailed,
splitsFailed,
splitsRequested,
splitsRetrieved,
splitSucceeded,
submitSplit
} from '../../actions/SplitActions';
const initState = {fetchState... |
tuanzuo/redismanager | redismanager-core/src/main/java/com/tz/redismanager/strategy/queryvalue/handler/QueryListValueHandler.java | <reponame>tuanzuo/redismanager
package com.tz.redismanager.strategy.queryvalue.handler;
import com.tz.redismanager.annotation.HandlerType;
import com.tz.redismanager.domain.vo.RedisValueQueryVO;
import com.tz.redismanager.enm.HandlerTypeEnum;
import com.tz.redismanager.strategy.queryvalue.AbstractQueryValueHandler;
im... |
lofunz/mieme | MAME4all/trunk/src/vidhrdw/wc90b.cpp | <gh_stars>10-100
#include "driver.h"
#include "vidhrdw/generic.h"
unsigned char *wc90b_shared;
unsigned char *wc90b_tile_colorram, *wc90b_tile_videoram;
unsigned char *wc90b_tile_colorram2, *wc90b_tile_videoram2;
unsigned char *wc90b_scroll1xlo, *wc90b_scroll1xhi;
unsigned char *wc90b_scroll2xlo, *wc90b_scrol... |
trabab/opsgenie-cloudformation-resources | opsgenie_integration/src/main/java/com/atlassian/opsgenie/integration/ListHandler.java | package com.atlassian.opsgenie.integration;
import software.amazon.cloudformation.proxy.*;
import com.atlassian.opsgenie.integration.model.ListIntegrationResponse;
import com.atlassian.opsgenie.integration.client.OpsgenieClient;
import com.atlassian.opsgenie.integration.client.OpsgenieClientException;
import java.io.... |
mihayl1/aimp-control-plugin | src/aimp/manager_impl_common.h | <reponame>mihayl1/aimp-control-plugin
// Copyright (c) 2014, <NAME>
#pragma once
#include "../utils/scope_guard.h"
#include "../utils/sqlite_util.h"
#include "manager2.6.h"
#include "manager3.0.h"
namespace AIMPPlayer
{
inline const char* asString(AIMPManager::STATUS status)
{
switch (status) {
... |
boldak/jace-front | src/modules/vuetifydl/mixins/recordable.js | export default {
computed: {
$parameters () {
return this.$options.propsData
},
isNewRecord: function () {
return (!this.$options.primaryKey || !this.$options.propsData) || !this.$options.propsData[this.$options.primaryKey]
}
}
}
|
KenWoo/Algorithm | Algorithms/Easy/976. Largest Perimeter Triangle/answer.py | from typing import List
class Solution:
def largestPerimeter(self, A: List[int]) -> int:
A.sort()
for i in range(len(A)-3, -1, -1):
if A[i] + A[i+1] > A[i+2]:
return A[i] + A[i+1] + A[i+2]
return 0
if __name__ == "__main__":
s = Solution()
result = s.l... |
Malamut54/dbobrov | chapter_007/src/main/java/ru/job4j/task3/Main.java | <gh_stars>0
package ru.job4j.task3;
/**
* Task 3.
*
* @author <NAME> (<EMAIL>)
* @since 13.10.2017
*/
public class Main {
/**
* Stsrt program.
* @param args input args.
*/
public static void main(String[] args) {
Thread time = new Thread(new Time(100));
time.start();
}
... |
Markus-Schwer/quarkus | independent-projects/tools/codestarts/src/test/java/io/quarkus/devtools/codestarts/core/CodestartDataTest.java | package io.quarkus.devtools.codestarts.core;
import static org.assertj.core.api.Assertions.assertThat;
import static org.junit.jupiter.api.Assertions.*;
import io.quarkus.devtools.codestarts.CodestartCatalog;
import io.quarkus.devtools.codestarts.CodestartProjectGenerationTest;
import io.quarkus.devtools.codestarts.C... |
jWeb94/kit_wissenschaftliches_programmieren_fuer_ingenieure | uebung3/musterloesung/game_of_life_lsg_WS1819/functions_game.cpp | <filename>uebung3/musterloesung/game_of_life_lsg_WS1819/functions_game.cpp<gh_stars>0
#include "functions_game.h"
using namespace std;
MatrixXi create_field2d(const unsigned int nx, const unsigned int ny){
MatrixXi field=MatrixXi::Zero(nx,ny);
return field;
}
void init_field2d(MatrixXi &field, const double f... |
apache/tuscany-sca-2.x | modules/domain-node/src/test/java/org/apache/tuscany/sca/runtime/TuscanyRuntimeTestCase.java | <gh_stars>10-100
/*
* 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
*... |
bogus-sudo/ONE-1 | compiler/mir/src/mir_onnx_importer/Op/Transpose.cpp | <gh_stars>100-1000
/*
* Copyright (c) 2019 Samsung Electronics Co., Ltd. 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/LICEN... |
ali-sharif/avm | org.aion.avm.embed/test/org/aion/avm/embed/deploy/renamer/resources/ClassB.java | package org.aion.avm.embed.deploy.renamer.resources;
//NOTE: This is a copy of a test in org.aion.avm.tooling in order to support the RenameDeployTest.
public class ClassB extends ClassA implements Comparable<String>{
}
|
npocmaka/Windows-Server-2003 | enduser/netmeeting/ui/wb/user.hpp | //
// USER.HPP
// User Class
//
// Copyright Microsoft 1998-
//
#ifndef __USER_HPP_
#define __USER_HPP_
//
//
// Class: WbUser
//
// Purpose: User object recorder
//
//
class DCWbGraphicPointer;
class WbUser
{
public:
//
// Constructor
//
WbUser(POM_OBJECT hUser = NULL);
... |
3rdIteration/bip_utils | bip_utils/bip/bip39/bip39_mnemonic.py | # Copyright (c) 2021 <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, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, ... |
WhittKinley/Legos | submissions/Kinley/mygames.py | <gh_stars>0
from collections import namedtuple
from games import (Game)
class GameState:
def __init__(self, to_move, board, label=None, depth=5):
self.to_move = to_move
self.board = board
self.label = label
self.maxDepth = depth
# self.validSpaces = ()
def __str__(self)... |
ethz-asl/mav_findmine | libs/fm_control/src/position_controller.cc | <gh_stars>1-10
/*
MIT License
Copyright (c) 2020 <NAME>, ASL, ETH Zurich, Switzerland
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
... |
isawnyu/isaw.web | src/isaw.theme/isaw/theme/browser/people.py | <gh_stars>0
from Products.Five.browser import BrowserView
class PeopleView(BrowserView):
"""Base vew class for the @@people-view"""
def people(self):
brains = self._query()
result = []
for brain in brains:
profile = brain.getObject()
data = {
'i... |
hanlukman/projectD | assets/demos/complete/rotatablenodes/RotatablePorts.js | /****************************************************************************
** @license
** This demo file is part of yFiles for HTML 2.2.
** Copyright (c) 2000-2019 by yWorks GmbH, Vor dem Kreuzberg 28,
** 72070 Tuebingen, Germany. All rights reserved.
**
** yFiles demo files exhibit yFiles for HTML functionali... |
ketanchoyal/theParker | theParker/app/src/main/java/com/service/parking/theparker/View/SnackbarWrapper.java | <filename>theParker/app/src/main/java/com/service/parking/theparker/View/SnackbarWrapper.java
package com.service.parking.theparker.View;
import android.content.Context;
import android.graphics.PixelFormat;
import android.os.IBinder;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import andro... |
juandarr/ProjectEuler | 11.py | """
Finds biggest product of n digits in a 2D grid in every possible direction
Author: <NAME>
"""
import math
ar = """08 02 22 97 38 15 00 40 00 75 04 05 07 78 52 12 50 77 91 08
49 49 99 40 17 81 18 57 60 87 17 40 98 43 69 48 04 56 62 00
81 49 31 73 55 79 14 29 93 71 40 67 53 88 30 03 49 13 36 65
52 70 95 23 04 60 11 ... |
nguillaumin/nabaztag-server | net.violet.platform/src/main/java/net/violet/platform/daemons/crawlers/PurgeContentDaemon.java | <filename>net.violet.platform/src/main/java/net/violet/platform/daemons/crawlers/PurgeContentDaemon.java
package net.violet.platform.daemons.crawlers;
import net.violet.db.records.Record.RecordWalker;
import net.violet.platform.datamodel.Content;
import net.violet.platform.datamodel.Files;
import net.violet.platform.d... |
skolbin-ssi/Dynamics-365-Fraud-Protection-ManualReview | backend/queues/src/main/java/com/griddynamics/msd365fp/manualreview/queues/model/ItemEvent.java | <filename>backend/queues/src/main/java/com/griddynamics/msd365fp/manualreview/queues/model/ItemEvent.java<gh_stars>1-10
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT license.
package com.griddynamics.msd365fp.manualreview.queues.model;
import com.fasterxml.jackson.annotation.JsonTypeInfo;
import c... |
imcloudfloating/Cloud-OJ | judge-service/src/main/java/group/_204/oj/judge/config/RabbitConfig.java | <reponame>imcloudfloating/Cloud-OJ
package group._204.oj.judge.config;
import org.springframework.amqp.core.Queue;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
@Configuration
public class RabbitConfig {
public static final String JUDGE_QUEUE = "... |
forestGzh/VTK | IO/XML/vtkXMLPolyDataWriter.h | <reponame>forestGzh/VTK
/*=========================================================================
Program: Visualization Toolkit
Module: vtkXMLPolyDataWriter.h
Copyright (c) <NAME>, <NAME>, <NAME>
All rights reserved.
See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
This s... |
qq187155684/BrowserDemo | src/com/android/myapidemo/smartisan/wxapi/AllShareActivity.java |
package com.android.myapidemo.smartisan.wxapi;
import com.android.myapidemo.R;
import android.app.Activity;
import android.content.Intent;
import android.graphics.Bitmap;
import android.graphics.drawable.BitmapDrawable;
import android.graphics.drawable.Drawable;
import android.os.Bundle;
import android.os.Handler;
i... |
UNC-Libraries/hy-c | spec/helpers/blacklight/facets_helper_behavior_spec.rb | <gh_stars>1-10
require 'rails_helper'
RSpec.describe Blacklight::FacetsHelperBehavior do
# only testing overridden method
describe '#facet_display_value' do
it "is the facet value for an ordinary facet" do
allow(helper).to receive(:facet_configuration_for_field).with('simple_field').and_return(double(que... |
codaxy/cx-diagrams | docs/app/config/FourSides.js | import { Md } from '../components/Md';
import node from './Node';
export default {
...node,
gap: {
type: 'number',
key: true,
description: (
<cx>
<Md>Inner distance between the elements.</Md>
</cx>
),
},
slots: {
type: 'array',
key: true,
... |
j-boivie/fiaas-deploy-daemon | tests/fiaas_deploy_daemon/test_retry.py | <filename>tests/fiaas_deploy_daemon/test_retry.py
from requests import Response
from k8s.client import ClientError
import mock
import pytest
from fiaas_deploy_daemon.retry import retry_on_upsert_conflict, UpsertConflict, canonical_name
@pytest.mark.parametrize("status", (
400, # Bad Request
402, # Payment ... |
finnroblin/timeblock | web/node_modules/urql/dist/urql.js | var e = require("@urql/core");
var t = require("react");
var r = require("wonka");
var n = e.createClient({
url: "/graphql"
});
var u = t.createContext(n);
var i = u.Provider;
var a = u.Consumer;
u.displayName = "UrqlContext";
var s = !1;
function useClient() {
var e = t.useContext(u);
if ("production" !... |
ngomalalibo/web-librarian | src/main/java/com/pc/weblibrarian/utils/ModifyEntityContent.java | package com.pc.weblibrarian.utils;
import com.pc.weblibrarian.dataService.AuthorDataService;
import com.pc.weblibrarian.entity.Author;
import com.pc.weblibrarian.entity.PersistingBaseEntity;
import org.bson.Document;
import java.time.LocalDateTime;
public class ModifyEntityContent
{
public static <T extends Pers... |
OliCSADoerr/kresus-sa | client/components/menu/total-balance.js | import React from 'react';
import { connect } from 'react-redux';
import { get } from '../../store';
import { translate as $t } from '../../helpers';
import ColoredAmount from './colored-amount';
let TotalBalanceComponent = props => {
let totalEntries = Object.entries(props.totals);
let totalElement;
if ... |
colorshifter/caaers | caAERS/software/web/src/main/java/gov/nih/nci/cabig/caaers/web/rule/RuleAjaxObject.java | /*******************************************************************************
* Copyright SemanticBits, Northwestern University and Akaza Research
*
* Distributed under the OSI-approved BSD 3-Clause License.
* See http://ncip.github.com/caaers/LICENSE.txt for details.
******************************************... |
MatheusEwen/Exercicios_Do_CursoDePython | ExPython/CursoemVideo/ex004.py | <reponame>MatheusEwen/Exercicios_Do_CursoDePython
a = input('Digite algo: ')
print('\033[1;31mo tipo primitivo desse valor é',type(a))
print('\033[1;32msó tem espaços?:',a.isspace())
print('\033[1;33mé um número?:',a.isnumeric())
print('\033[1;34mé alfabetico?:', a.isalpha())
print('\033[1;35mé um alnumerico?:', a.isal... |
paullewallencom/java-978-1-7871-2886-6 | _src/src/BlockBreakerPanel.java | <reponame>paullewallencom/java-978-1-7871-2886-6
import java.awt.Graphics;
import java.awt.event.KeyEvent;
import java.awt.event.KeyListener;
import java.util.ArrayList;
import java.util.Random;
import javax.swing.JPanel;
public class BlockBreakerPanel extends JPanel implements KeyListener{
ArrayList<B... |
AdvancedVEXLibrary/Advanced-VEX-Library | vex/include/avl_istiny.h | #pragma once
#ifndef _AVL_ISTINY_H_
#define _AVL_ISTINY_H_
#include <math.h>
int
avl_istiny(const int geometry;
const int primnum;
const float epsilon)
{
int points[] = primpoints(geometry, primnum);
float epsilon2 = epsilon * epsilon;
for (int pt = len(points) - 2; pt > -2; --pt)
... |
lmarent/network_agents_ver2 | ClockServer/include/TimerNotification.h | #ifndef TimerNotification_INCLUDED
#define TimerNotification_INCLUDED
#include <Poco/Timer.h>
#include <Poco/Thread.h>
#include <Poco/Stopwatch.h>
#include <iostream>
namespace ChoiceNet
{
namespace Eco
{
class TimerNotification
{
public:
TimerNotification(int intervals_per_cycle);
void onEndPeriod(Poco::... |
niloc132/viola | viola-web/src/main/java/com/colinalworth/gwt/viola/web/server/JobWebService.java | package com.colinalworth.gwt.viola.web.server;
import com.colinalworth.gwt.viola.entity.CompiledProject;
import com.colinalworth.gwt.viola.entity.CompilerLog;
import com.colinalworth.gwt.viola.entity.SourceProject;
import com.colinalworth.gwt.viola.service.JobService;
import com.colinalworth.gwt.viola.service.UserServ... |
KretschiHSR/HSR-SmartProductsApp | Source/SmartProductBrowser/app/src/main/java/ch/ost/wing/smartproducts/smartproductbrowser/views/adapters/ProductsAdapter.java | package ch.ost.wing.smartproducts.smartproductbrowser.views.adapters;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.BaseAdapter;
import androidx.databinding.DataBindingUtil;
import java.util.ArrayList;
import java.util.List;
import javax.inject.In... |
pardoman/hig | packages/tabs/src/presenters/TabCloseButtonPresenter.js | <reponame>pardoman/hig
import React from "react";
import PropTypes from "prop-types";
import { CloseSUI, CloseXsUI } from "@hig/icons";
import ThemeContext from "@hig/theme-context";
import { ControlBehavior } from "@hig/behaviors";
import { cx, css } from "emotion";
import stylesheet from "./Tab.stylesheet";
export d... |
bis83/pomdog | src/SoundSystem.XAudio2/SoundEffectXAudio2.hpp | <reponame>bis83/pomdog
// Copyright (c) 2013-2015 mogemimi.
// Distributed under the MIT license. See LICENSE.md file for details.
#ifndef POMDOG_SOUNDEFFECTXAUDIO2_ED1F6835_HPP
#define POMDOG_SOUNDEFFECTXAUDIO2_ED1F6835_HPP
#include "PrerequisitesXAudio2.hpp"
#include "../Utility/Noncopyable.hpp"
#include <memory>
... |
TeamNut/CotEngine-Release | include/math/CotColor.h | #pragma once
#include "base/CotRule.h"
namespace Cot
{
class Color32;
class COT_API Color final
{
public:
union
{
struct
{
float r, g, b, a;
};
float ToArray[4];
};
Color();
Color(const float red, const float green, const float blue, const float alpha = 1.0f);
Color(const float* arra... |
pdmack/djl | examples/src/main/java/ai/djl/examples/training/util/ExampleTrainingResult.java | /*
* Copyright 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 the License. A copy of the License is located at
*
* http://aws.amazon.com/apache2.0/
*
* or in the "license" fil... |
xvwh/batch-scheduler | auth/src/main/java/com/asofdate/hauth/dao/impl/HandleLogDaoImpl.java | <filename>auth/src/main/java/com/asofdate/hauth/dao/impl/HandleLogDaoImpl.java
package com.asofdate.hauth.dao.impl;
import com.asofdate.hauth.dao.HandleLogDao;
import com.asofdate.hauth.entity.HandleLogEntity;
import com.asofdate.hauth.sql.SqlText;
import org.springframework.beans.factory.annotation.Autowired;
import ... |
PqES/ArchPython | src/Models/problem.py | class Problem:
def __init__(self, problem_type, origin_module, restrictions_broken, is_warning = False):
self.problem_type = problem_type
self.origin_module = origin_module
self.restrictions_broken = restrictions_broken
self.category = "warning" if is_warning else "problem"
... |
YDJaken/ThreeEarth | src/Renderer/Shaders/ShaderChunk/emissivemap_pars_fragment.js | <gh_stars>0
//This file is automatically rebuilt by the Speed3DGis build process.
class emissivemap_pars_fragment{static theWord() {
return "#ifdef USE_EMISSIVEMAP\n\
\n\
uniform sampler2D emissiveMap;\n\
\n\
#endif\n\
";
}} export {emissivemap_pars_fragment}; |
12589-PioneerRobotics/FtcRobotController | TeamCode/src/main/java/org/firstinspires/ftc/teamcode/tests/OpenCVTestOpMode.java | package org.firstinspires.ftc.teamcode.tests;
import com.qualcomm.robotcore.eventloop.opmode.Autonomous;
import com.qualcomm.robotcore.eventloop.opmode.LinearOpMode;
import org.firstinspires.ftc.robotcore.external.hardware.camera.WebcamName;
import org.firstinspires.ftc.teamcode.core.CVRingDetection;
import org.openf... |
Robbbert/messui | src/lib/formats/apd_dsk.h | <reponame>Robbbert/messui<filename>src/lib/formats/apd_dsk.h
// license:BSD-3-Clause
// copyright-holders:<NAME>
/*********************************************************************
formats/apd_dsk.h
Archimedes Protected Disk Image format
********************************************************************... |
meilihao/demo | etcd/lock/etcdv3.go | // from https://yemilice.com/2019/12/13/etcd%E5%88%86%E5%B8%83%E5%BC%8F%E9%94%81%E5%AE%9E%E7%8E%B0%E9%80%89%E4%B8%BB%E6%9C%BA%E5%88%B6-golang/
package main
import (
"context"
"errors"
"fmt"
"io"
"math"
"os"
"sync"
"time"
clientv3 "go.etcd.io/etcd/client/v3"
)
const (
defaultTTL = 60
formatErrT... |
HuangJie1990/Algorithms | src/c1/s5/UF.java | <filename>src/c1/s5/UF.java<gh_stars>0
package c1.s5;
public abstract class UF {
protected int[] id;
protected int count;
/*
add connection between p and q
*/
public abstract void union(int p, int q);
/*
component identifier for p(0 to N-1)
*/
public abstract int find(int i)... |
dgarson/jdbceptor | src/main/java/org/drg/jdbceptor/hibernate/InstrumentedConnectionProvider.java | package org.drg.jdbceptor.hibernate;
import com.google.common.base.Preconditions;
import org.apache.commons.lang3.StringUtils;
import org.drg.jdbceptor.api.InstrumentedConnection;
import org.drg.jdbceptor.hibernate.config.HibernateDataSourceConfiguration;
import org.drg.jdbceptor.hibernate.event.ConnectionProviderAwar... |
karussell/openlr | binary/openlr/binary/encoder/ClosedLineEncoder.java | /**
* Licensed to the TomTom International B.V. under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. TomTom International B.V.
* licenses this file to you under the Apache License,
* Version 2.0 (th... |
wanghaiyang-github/dna-cloud | bazl-dna-mix/src/main/java/com/bazl/dna/mix/model/vo/MixedSampleGeneVo.java | <filename>bazl-dna-mix/src/main/java/com/bazl/dna/mix/model/vo/MixedSampleGeneVo.java
package com.bazl.dna.mix.model.vo;
import com.bazl.dna.mix.model.po.MixedSampleGene;
import java.io.Serializable;
import java.util.Date;
import java.util.Map;
/**
* Created by Administrator on 2017/1/4.
*/
public class MixedSampl... |
rohankadekodi/compilers_project | lonestar/experimental/meshsingularities/DAGSolver3D/Node.hpp | <gh_stars>0
#ifndef NODE_HPP
#define NODE_HPP
#include <vector>
#include <string>
#include <cstdio>
#include <cstdlib>
#include "Element.hpp"
#include "EquationSystem.hpp"
#include <set>
class Mesh;
class Node {
private:
int node = -1;
Node* left = NULL;
Node* right = NULL;
Node* parent = NULL;
st... |
ryklin/master | libhid/usb-1608FS-Plus.h | <reponame>ryklin/master
/*
*
* Copyright (c) 2013 <NAME> <<EMAIL>>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later ver... |
cy15196/FastCAE | Code/HeuDataSrcIO/ProgressBar.h | <filename>Code/HeuDataSrcIO/ProgressBar.h
#ifndef PROGRESSBAR_H
#define PROGRESSBAR_H
#include <QLabel>
#include <QProgressBar>
#include <QPushButton>
#include "heudatasrcio_global.h"
class ProgressBar : public QWidget
{
Q_OBJECT
public:
int mRangeSize=100;
ProgressBar(QWidget *parent = 0);
~ProgressBar();
voi... |
vjh0107/Skellett | src/main/java/com/gmail/thelimeglass/Expressions/ExprShootGetArrow.java | package com.gmail.thelimeglass.Expressions;
import org.bukkit.entity.Entity;
import org.bukkit.event.Event;
import org.bukkit.event.entity.EntityShootBowEvent;
import org.eclipse.jdt.annotation.Nullable;
import com.gmail.thelimeglass.Utils.Annotations.Config;
import com.gmail.thelimeglass.Utils.Annotations.FullConfig... |
googleapis/googleapis-gen | google/cloud/clouddms/v1/google-cloud-clouddms-v1-java/proto-google-cloud-clouddms-v1-java/src/main/java/com/google/cloud/clouddms/v1/CloudSqlConnectionProfileOrBuilder.java | <gh_stars>1-10
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/cloud/clouddms/v1/clouddms_resources.proto
package com.google.cloud.clouddms.v1;
public interface CloudSqlConnectionProfileOrBuilder extends
// @@protoc_insertion_point(interface_extends:google.cloud.clouddms.v1.CloudSqlC... |
redlink-gmbh/redlink-nlp | ner/opennlp/ner-opennlp/src/main/java/io/redlink/nlp/opennlp/NameFinderModel.java | /*
* Copyright (c) 2022 Redlink GmbH.
*
* 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 agre... |
ResearchSoftwareInstitute/MyHPOM | hs_core/page_processors.py | """Page processors for hs_core app."""
from dateutil import parser
from functools import partial, wraps
from django.conf import settings
from django.core.exceptions import PermissionDenied
from django.forms.models import formset_factory
from mezzanine.pages.page_processors import processor_for
from hs_core.models i... |
SteveKunG/FishOfThieves | common/src/main/java/com/stevekung/fishofthieves/entity/FishVariant.java | <filename>common/src/main/java/com/stevekung/fishofthieves/entity/FishVariant.java
package com.stevekung.fishofthieves.entity;
import java.util.function.Predicate;
import com.stevekung.fishofthieves.spawn.SpawnConditionContext;
public interface FishVariant
{
String getName();
int getId();
Predicate<Spa... |
tomgratte/trakem2_to_bdv | src/main/java/bdv/img/cache/CacheIoTiming.java | <reponame>tomgratte/trakem2_to_bdv
/*
* #%L
* BigDataViewer core classes with minimal dependencies
* %%
* Copyright (C) 2012 - 2015 BigDataViewer authors
* %%
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* ... |
gelson-barros/Explica-o-apanhados-js | a3.js | console.log("2009" - "1995")//14 |
limeng32/mybatis.flying | src/test/java/indi/mybatis/flying/service2/TransactiveService3.java | package indi.mybatis.flying.service2;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Isolation;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.an... |
CourtHive/competitionFactory | src/drawEngine/governors/scoreGovernor/keyValueScore/constants.js | export const SPACE_CHARACTER = ' ';
export const OUTCOME_DEFAULT = 'DEF';
export const OUTCOME_COMPLETE = 'COMPLETED';
export const OUTCOME_WALKOVER = 'WO';
export const OUTCOME_DOUBLE_WALKOVER = 'WO/WO';
export const OUTCOME_ABANDONED = 'ABN';
export const OUTCOME_SUSPENDED = 'SUS';
export const OUTCOME_RETIREMENT = ... |
arastoul/kairosdb-client | src/main/java/org/kairosdb/client/response/QueryResult.java | /*
* Copyright 2013 Proofpoint 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 applicabl... |
johanrydstrom/FluentLenium | fluentlenium-core/src/test/java/org/fluentlenium/integration/TakeSnapshotOnLabsTest.java | <filename>fluentlenium-core/src/test/java/org/fluentlenium/integration/TakeSnapshotOnLabsTest.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/lic... |
mbostler/zenful_attribution | db/migrate/20150623154221_create_attribution_days.rb | class CreateAttributionDays < ActiveRecord::Migration[5.1]
def change
create_table :attribution_days do |t|
t.integer :portfolio_id
t.date :date
t.float :performance
t.timestamps null: false
end
end
end
|
beyzanurkarakaya/Java-Programming | Lab-Lessons/Week7/Employee3/CommissionEmployee.java | // CommissionEmployee class uses methods to manipulate its
// private instance variables.
public class CommissionEmployee {
private final String firstName;
private final String lastName;
private final String socialSecurityNumber;
private double grossSales; // gross weekly sales
private double commission... |
ajs6f/stanbol | ontologymanager/ontonet/src/main/java/org/apache/stanbol/ontologymanager/ontonet/api/ONManager.java | <gh_stars>0
/*
* 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... |
LZ0211/eReader | node_modules/Wedge-eBooks/lib/txtz/index.js | var Zip = require('../zip');
var txt = require('../txt');
function encode(str){
return str.split('').map(char=>`&#${char.charCodeAt(0)};`).join('')
}
function leftPad(str,padding,length){
str = '' + str;
if (str.length >= length){
return str;
}
for (var i=str.length;i<length;i++){
s... |
vladn-ma/vladn-ovs-doc | doxygen/ovs_all/html/search/pages_b.js | var searchData=
[
['why_20open_20vswitch_3f',['Why Open vSwitch?',['../md__home_vladn_git_ovs_WHY-OVS.html',1,'']]]
];
|
nishanttotla/cpachecker-crowdprover | src/org/sosy_lab/cpachecker/cpa/seplogic/SeplogicTransferRelation.java | <gh_stars>0
/*
* CPAchecker is a tool for configurable software verification.
* This file is part of CPAchecker.
*
* Copyright (C) 2007-2014 <NAME>
* 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.... |
Odvin/s3-uploader | services/api-server/redis/index.js | const Redis = require('ioredis');
const config = {
host: 'redis',
port: 6379
};
const redis = new Redis(config);
module.exports = redis;
|
layerzero/cc0 | src/toolchain/core/CodeDom/NopExpression.cpp | <gh_stars>0
#include "NopExpression.h"
#include "ExpressionVisitor.h"
#include <core/Type/VoidType.h>
Type* NopExpression::GetType()
{
return new VoidType();
}
Expression* NopExpression::GetLValue()
{
return NULL;
}
void NopExpression::Accept(ExpressionVisitor* visitor)
{
visitor->Visit(this);
}
NopExp... |
kagome1007/MegEngine | dnn/src/arm_common/conv_bias/int8/direct_kernels/dot_direct_nchw44_common.h | /**
* \file
* dnn/src/arm_common/conv_bias/int8/direct_kernels/dot_direct_nchw44_common.h
* MegEngine is Licensed under the Apache License, Version 2.0 (the "License")
*
* Copyright (c) 2014-2021 Megvii Inc. All rights reserved.
*
* Unless required by applicable law or agreed to in writing,
* software distribut... |
joshluisaac/powerapps-serviceengine | src/main/java/com/profitera/services/business/rpm/RPMEngineTestService.java | <gh_stars>0
package com.profitera.services.business.rpm;
import com.profitera.deployment.rmi.RPMEngineTestServiceIntf;
import com.profitera.descriptor.business.TransferObject;
import com.profitera.services.business.BusinessService;
import com.profitera.services.system.rpm.RuleTest;
public class RPMEngineTestService e... |
AntonioIonica/Automation_testing | Fuzzywuzzy_course_exercice/src/test_script.py | <gh_stars>0
"""
Fuzzywuzzy for data as cities name using partial_ratio and QRatio
"""
from fuzzywuzzy import fuzz
def test_case1(input_data, expected_data):
similarity = fuzz.partial_ratio(input_data, expected_data)
if similarity > 90:
print(f'Test passed with the score of {similarity}!')
elif 80 ... |
dgolovin/org.jboss.tools.ssp | framework/bundles/org.jboss.tools.rsp.launching/src/main/java/org/jboss/tools/rsp/eclipse/debug/core/model/IProcess.java | <filename>framework/bundles/org.jboss.tools.rsp.launching/src/main/java/org/jboss/tools/rsp/eclipse/debug/core/model/IProcess.java
/*******************************************************************************
* Copyright (c) 2000, 2005 IBM Corporation and others.
* All rights reserved. This program and the accompa... |
anipmehta/Elements_Of_Programming_Interview | src/maximum_performance_of_team/Solution.java | package maximum_performance_of_team;
import com.sun.scenario.effect.impl.sw.java.JSWEffectPeer;
import java.util.*;
public class Solution {
public static void main(String [] args){
char ch = 'a'+ 1;
System.out.println(ch);
}
class Engineer{
public int efficiency;
public in... |
imgstack/stackpath-cdn-go | models/cdn_site_script.go | <reponame>imgstack/stackpath-cdn-go
// Code generated by go-swagger; DO NOT EDIT.
package models
// This file was generated by the swagger tool.
// Editing this file might prove futile when you re-run the swagger generate command
import (
"context"
"github.com/go-openapi/errors"
"github.com/go-openapi/strfmt"
"... |
SharikaN/WebDevToolkitForDx | digexp-wcm-design/test/config.js | /*
* Copyright HCL Technologies Ltd. 2001, 2020
* 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 ... |
voku/mod-spdy | src/third_party/chromium/src/base/system_monitor/system_monitor.h | <reponame>voku/mod-spdy
// Copyright (c) 2012 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.
#ifndef BASE_SYSTEM_MONITOR_SYSTEM_MONITOR_H_
#define BASE_SYSTEM_MONITOR_SYSTEM_MONITOR_H_
#include <string>
#include <vecto... |
robertfoss/i2p.i2p-bote | core/src/test/java/i2p/bote/packet/dht/EncryptedEmailPacketTest.java | /**
* Copyright (C) 2009 <EMAIL>
*
* The GPG fingerprint for <EMAIL> is:
* 6DD3 EAA2 9990 29BC 4AD2 7486 1E2C 7B61 76DC DC12
*
* This file is part of I2P-Bote.
* I2P-Bote 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... |
ALP-active-miner/ALP | MUDetect/mubench/src/main/java/de/tu_darmstadt/stg/mudetect/ranking/NodeWeightFunction.java | package de.tu_darmstadt.stg.mudetect.ranking;
import de.tu_darmstadt.stg.mudetect.aug.model.Node;
import java.util.Collection;
public interface NodeWeightFunction {
double getWeight(Node node);
default double getWeight(Collection<Node> nodes) {
return nodes.stream().mapToDouble(this::getWeight).sum(... |
CMU-TRP/podd-api | podd/settings/base.py | # At the top of settings/base.py
# -*- encoding: utf-8 -*-
import os
from os.path import join, abspath, dirname
import raven
from celery.schedules import crontab
from datetime import timedelta
here = lambda *x: join(abspath(dirname(__file__)), *x)
PROJECT_ROOT = here("..", "..")
root = lambda *x: join(abspath(PROJEC... |
slaclab/gdml | Common/Schema/Schema/offset.h | <reponame>slaclab/gdml
//
#ifndef OFFSET_H
#define OFFSET_H 1
#include "Saxana/SAXObject.h"
#include "Schema/DimensionsType.h"
class offset : public SAXObject, public QuantityType
{
public:
offset() {
}
virtual ~offset() {
}
virtual SAXObject::Type type() {
return SAXObject::element;
}
};
#endif /... |
btjanaka/competitive-programming-solutions | uva/12532.cpp | <gh_stars>1-10
// Author: btjanaka (<NAME>)
// Problem: (UVa) 12532
#include <bits/stdc++.h>
#define GET(x) scanf("%d", &x)
#define GED(x) scanf("%lf", &x)
typedef long long ll;
using namespace std;
typedef pair<int, int> ii;
int a[100100];
struct FenwickTree {
vector<int> ft;
FenwickTree(int n) { ft.assign(n + 1... |
nik-io/uDepot | trt/src/tests/trt_epoll_echo.cc | <filename>trt/src/tests/trt_epoll_echo.cc
/*
* Copyright (c) 2020 International Business Machines
* All rights reserved.
*
* SPDX-License-Identifier: BSD-3-Clause
*
* Authors: <NAME> (<EMAIL>, <EMAIL>)
*
*/
// Spawn an echo server using trt+epoll
#include <sys/types.h>
#include <sys/socket.h>
#include <ne... |
fizquierdo/opencga | opencga-analysis/src/main/java/org/opencb/opencga/analysis/variant/VariantStorageAnalysisExecutor.java | <gh_stars>0
package org.opencb.opencga.analysis.variant;
import org.apache.commons.lang3.StringUtils;
import org.opencb.commons.datastore.core.ObjectMap;
import org.opencb.opencga.analysis.ConfigurationUtils;
import org.opencb.opencga.core.exception.AnalysisExecutorException;
import org.opencb.opencga.catalog.exceptio... |
phatblat/macOSPrivateFrameworks | PrivateFrameworks/StorageKit/SKRAIDDisk.h | <reponame>phatblat/macOSPrivateFrameworks<gh_stars>10-100
//
// Generated by class-dump 3.5 (64 bit).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2013 by <NAME>.
//
#import <StorageKit/SKDisk.h>
@class NSArray, NSDictionary, NSString;
@interface SKRAIDDisk : SKDisk
{
BOOL _isRAIDSet;
... |
emanuelepaiano/jespresso-lite | src/main/java/io/github/emanuelepaiano/jespresso/include/unifi/dto/LoginDTO.java | package io.github.emanuelepaiano.jespresso.include.unifi.dto;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* The Class LoginDTO.
*/
@Data
@NoArgsConstructor
@AllArgsConstructor
public class LoginDTO {
/** The username. */
private String username;
/** The password... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.