repo_name stringlengths 6 101 | path stringlengths 4 300 | text stringlengths 7 1.31M |
|---|---|---|
khy/baler | spec/url_mapping_spec.rb | require File.dirname(__FILE__) + '/spec_helper'
class UrlMappingGame
include Baler
attr_accessor :league, :season
set_remote_source(ASSET_BASE + '/parser/|filename|.html') do |source|
source.set_context 'html > body > ol > li'
source.map :league => 'h1.global.league', :use_context => false
... |
ashishbh/dropwizard | dropwizard-util/src/test/java/io/dropwizard/util/DataSizeUnitTest.java | <filename>dropwizard-util/src/test/java/io/dropwizard/util/DataSizeUnitTest.java
package io.dropwizard.util;
import org.junit.jupiter.params.ParameterizedTest;
import org.junit.jupiter.params.provider.Arguments;
import org.junit.jupiter.params.provider.MethodSource;
import java.util.function.Function;
import java.uti... |
lta-disco-unimib-it/KLFA | src-bct-porting/file/JFLAP3Codec.java | <reponame>lta-disco-unimib-it/KLFA
/*******************************************************************************
* Copyright 2019 <NAME>, <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 ... |
flydzen/ITMO_algo | course1/Laba2/L/main.cpp | <filename>course1/Laba2/L/main.cpp
#include <iostream>
#include <vector>
#include <map>
using namespace std;
template<typename T>
void merge(vector<T> &v, int left, int right, int mid) {
int u1 = left;
int u2 = mid;
vector<T> res((int) right - left);
while (u1 < mid && u2 < right) {
if (v[u1] ... |
RahulGera/RWRider | RWRider.xcframework/ios-x86_64-simulator/RWRider.framework/Headers/UIAlertController+Show.h | //
// UIAlertController+Show.h
// RideDriver
//
// Created by Kitos on 11/7/16.
// Copyright © 2016 FuelMe LLC. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface UIAlertController (Show)
@property (nonatomic, strong) UIWindow *alertWindow;
- (void)show;
- (void)show:(BOOL)animated;
@end
|
StoriCapstone/storio | client/socket.js | import io from 'socket.io-client'
import store, {getNewComment, } from './store';
const socket = io(window.location.origin)
socket.on('new-comment', comment => {
store.dispatch(getNewComment(comment))
})
socket.on('connect', () => {
console.log('Connected!')
})
export default socket
|
myoukaku/bksge | libs/core/render/src/bksge_core_render_frame_buffer.cpp | /**
* @file bksge_core_render_frame_buffer.cpp
*
* @brief FrameBuffer の実装
*
* @author myoukaku
*/
#include <bksge/fnd/config.hpp>
#if !defined(BKSGE_HEADER_ONLY)
#include <bksge/core/render/inl/frame_buffer_inl.hpp>
#endif
|
c-core-labs/Sherlock-Frontend | src/components/ItemKeywords.js | import { Box, makeStyles } from '@material-ui/core';
import Chip from '@material-ui/core/Chip'
import { secondary, themeVariables } from '../theme'
const useStyles = makeStyles((theme) => ({
root: {
display: 'flex',
justifyContent: 'left',
flexWrap: 'wrap',
listStyle: 'none',
padding: theme.spaci... |
weekend27/Thinking-in-Java | code/concurrency/BasicThreads.java | <reponame>weekend27/Thinking-in-Java
package concurrency;
public class BasicThreads {
public static void main(String[] args) {
Thread t = new Thread(new LiftOff());
t.start();
System.out.println("Waiting for Liftoff");
}
}
|
rachitananda/ProblemSolvingProblems | src/com/problem/solving/ds/tree/problem/SpiralTraversalTree.java | package com.problem.solving.ds.tree.problem;
import com.problem.solving.ds.tree.BinaryTree;
import com.problem.solving.ds.tree.Node;
import java.util.Stack;
/**
* https://www.geeksforgeeks.org/level-order-traversal-in-spiral-form/
* //TODO recursive method
*/
public class SpiralTraversalTree {
BinaryTree tree... |
antkar/syn | syn/src/main/java/org/antkar/syn/internal/bnf/BnfElement.java | <filename>syn/src/main/java/org/antkar/syn/internal/bnf/BnfElement.java<gh_stars>1-10
/*
* Copyright 2013 <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.apac... |
YangChengTeam/english_study | base/src/main/java/yc/com/base/CommonInfoHelper.java | package yc.com.base;
import android.content.Context;
import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.TypeReference;
import com.vondear.rxtools.RxLogTool;
import java.lang.reflect.Type;
/**
* Created by wanglin on 2018/2/9 11:34.
*/
public class CommonInfoHelper {
public static <T> void getO(C... |
ajitkhaparde/trex-core | src/dpdk/drivers/net/octeontx_ep/otx_ep_ethdev.c | /* SPDX-License-Identifier: BSD-3-Clause
* Copyright(C) 2021 Marvell.
*/
#include <ethdev_pci.h>
#include "otx2_common.h"
#include "otx_ep_common.h"
#include "otx_ep_vf.h"
#include "otx2_ep_vf.h"
#include "otx_ep_rxtx.h"
#define OTX_EP_DEV(_eth_dev) \
((struct otx_ep_device *)(_eth_dev)->data->dev_private)
stati... |
cwsteinbach/schedoscope | schedoscope-transformation-pig/src/test/scala/org/schedoscope/scheduler/driver/PigDriverTest.scala | <gh_stars>100-1000
/**
* Copyright 2015 Otto (GmbH & Co KG)
*
* 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... |
rolandosborne/coredb | app/src/main/java/org/coredb/service/UserService.java | package org.coredb.service;
import java.security.*;
import java.security.spec.*;
import java.util.*;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.transaction.annotation.Transactional;
import org.springframework... |
iot-block/iotchain | common/jvm/src/main/scala/jbok/common/FileUtil.scala | package jbok.common
import java.io.InputStream
import java.nio.channels.{FileLock, OverlappingFileLockException}
import java.nio.charset.{Charset, StandardCharsets}
import java.nio.file.{Path, StandardOpenOption}
import better.files.File
import cats.effect.{Resource, Sync}
import cats.implicits._
import jbok.common.l... |
dcos/dcos-installer-ui | src/js/components/icons/IconDownload.js | <reponame>dcos/dcos-installer-ui
import React from 'react';
module.exports = class IconDownload extends React.Component {
render() {
return (
<svg
className="icon icon-download"
height="16px"
viewBox="0 0 16 16"
width="16px"
{...this.props}>
<polygon points="... |
mantamusica/java_cic_grupos | grupo2.ejercicio027-master-55488720b7727e1119dc0c903221207dc74e5212/src/main/java/es/cic/curso/grupo2/ejercicio027/ui/VentanaContenidoCampos.java | package es.cic.curso.grupo2.ejercicio027.ui;
import java.util.ArrayList;
import java.util.List;
import com.vaadin.server.FontAwesome;
import com.vaadin.server.Page;
import com.vaadin.ui.Alignment;
import com.vaadin.ui.Button;
import com.vaadin.ui.HorizontalLayout;
import com.vaadin.ui.Label;
import com.vaadin.ui.Noti... |
yingjieg/jiveapps | examples/opensocial/activity/petting-zoo/js/activitydata.js | <gh_stars>10-100
/*
* Copyright 2011 <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... |
gwdg/openproject-revisions_git | db/migrate/20140530204954_add_fingerprint_to_gitolite_public_keys.rb | <filename>db/migrate/20140530204954_add_fingerprint_to_gitolite_public_keys.rb
class AddFingerprintToGitolitePublicKeys < ActiveRecord::Migration
def self.up
add_column :gitolite_public_keys, :fingerprint, :string, null: false
add_index :gitolite_public_keys, :fingerprint
end
def self.down
remove_ind... |
ikatun/nnode | build/decorating-helpers-template.js | "use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.decoratingHelpersTemplate = void 0;
const decoratingHelpersTemplate = `
var akessrfljlrgqgd_decorate = function (decorators, target, key, desc) {
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnP... |
taylorgorman/intervention | resources/scripts/user-interface/components/Page/ImportRowEmpty.js | import { __ } from '../../utils/wp';
/**
* Import Row Empty
*/
const ImportRowEmpty = () => {
return (
<div
className="
h-[44px]
lg:h-[40px]
px-16
flex
items-center
text-14
leading-none
text-gray-50
last:border-0"
>
{__('No... |
ctwardy/jacobs-vault | ais-analytics/aisanalytics/utilities.py | <gh_stars>1-10
from argparse import ArgumentParser
def cli_arguments():
parser = ArgumentParser()
parser.add_argument(
"--ais-input-table",
dest="AIS_INPUT_TABLE",
)
parser.add_argument(
"--velocities-output-table",
dest="VELOCITIES_OUTPUT_TABLE",
)
args = pa... |
adobe/reactor-extension-alloy | test/functional/dataElements/xdmObject/helpers/editor.js | /*
Copyright 2021 Adobe. All rights reserved.
This file is licensed to you 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... |
jasonwang1109/react-bootstrap-v4 | src/InputGroup.js | <gh_stars>1-10
import React from 'react';
import PropTypes from 'prop-types';
import classNames from 'classnames/bind';
class InputGroup extends React.PureComponent {
constructor(props) {
super(props);
this.state = {
label: this.props.label,
value: this.props.data,
... |
htbkoo/weight-tracker | scripts/view/dialentry.js | <filename>scripts/view/dialentry.js
/**
* Wraps around the dial component. Essentially manages the user interactions
* and passes the appropriate values to the dial. It also dispatches custom
* events when the user taps on the value in the middle.
*
* Typically the users of this are WeightEntry and HeightEntry com... |
power-electro/phantomjs-Gohstdriver-DIY-openshift | src/qt/qtbase/src/plugins/platforms/directfb/qdirectfbwindow.cpp | <filename>src/qt/qtbase/src/plugins/platforms/directfb/qdirectfbwindow.cpp
/****************************************************************************
**
** Copyright (C) 2015 The Qt Company Ltd.
** Contact: http://www.qt.io/licensing/
**
** This file is part of the plugins of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:... |
hlick14/URL-OC | serverstats/node_modules/autobahn/lib/serializer.js | <reponame>hlick14/URL-OC
///////////////////////////////////////////////////////////////////////////////
//
// AutobahnJS - http://autobahn.ws, http://wamp.ws
//
// A JavaScript library for WAMP ("The Web Application Messaging Protocol").
//
// Copyright (c) <EMAIL> Technologies GmbH and contributors
//
// Licensed... |
egregors/leetgo | solutions/s0713_subarray_product_less_than_k.go | <filename>solutions/s0713_subarray_product_less_than_k.go
/*
https://leetcode.com/problems/subarray-product-less-than-k/
Given an array of integers nums and an integer k, return the number of contiguous subarrays
where the product of all the elements in the subarray is strictly less than k.
*/
package solutions
f... |
scala-steward/bitcoin-s | wallet/src/main/scala/org/bitcoins/wallet/internal/AccountHandling.scala | package org.bitcoins.wallet.internal
import org.bitcoins.core.api.wallet.db.AccountDb
import org.bitcoins.core.hd.AddressType._
import org.bitcoins.core.hd._
import org.bitcoins.core.protocol.blockchain.{
MainNetChainParams,
RegTestNetChainParams,
SigNetChainParams,
TestNetChainParams
}
import org.bitcoins.wal... |
zubairabid/Semester6 | subjects/LData/Assignment/shallow-parser-ben-3.0.fc8/src/sl/morph/ben/analyser/my_blk_bsrch.c | /**
* File Name : my_blk_bsrch.c.c
*/
/** Fuction : my_blk_bsrch
* This function returns the ptr to the location of the key in the table, if it is present
* else returns a null
* It takes arguments: key of char type ,base of char type ,nel of int type
* width of int type and compar is function with integ... |
mudchina/es2-mudlib-utf8 | mudlib/d/green/house3.c | <filename>mudlib/d/green/house3.c<gh_stars>10-100
// Room: /d/green/house3.c
inherit ROOM;
int num_of_spider;
string call_spider();
void create()
{
set("short", "民宅");
set("long", @LONG
这是一间民宅, 屋内除了一张石床外其他一无所有. 昏暗的屋
内看来死气沉沉的, 似乎这屋子的主人很久没回来了. 屋角有一个
形状很奇怪的蜘蛛网(web).
LONG
);
set("exits", ([ /* sizeof() == 1 */
"so... |
sysidos/gollvm | unittests/TestUtils/DiffUtils.h | //===- llvm/tools/gollvm/unittests/TestUtils/DiffUtils.h --------------===//
//
// Copyright 2018 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
//
//===----------------------------------------------------------------------===... |
rubytomato/demo-java12-javalin3 | src/main/java/com/example/demo/config/DslConfigure.java | <gh_stars>0
package com.example.demo.config;
import org.jooq.Configuration;
import org.jooq.ConnectionProvider;
import org.jooq.DSLContext;
import org.jooq.SQLDialect;
import org.jooq.TransactionProvider;
import org.jooq.conf.Settings;
import org.jooq.impl.DefaultConfiguration;
import javax.sql.DataSource;
import jav... |
daemyung/gal | src/ogl/Ogl_shader.h | <reponame>daemyung/gal
//
// This file is part of the "gfx" project
// See "LICENSE" for license information.
//
#ifndef GFX_OGL_SHADER_GUARD
#define GFX_OGL_SHADER_GUARD
#include <GLES3/gl3.h>
#include "Shader.h"
namespace Gfx_lib {
//--------------------------------------------------------------------------------... |
developertqw2017/migrationDjango | Vecihi/Backend/vecihi/users/views_api.py | import json
from django.utils.decorators import method_decorator
from django.db.models import Q
from django.views.decorators.cache import cache_page
from django.contrib.auth import authenticate, login, logout
from django.contrib.auth import update_session_auth_hash
from rest_framework import permissions, status, views... |
bluebird88/HIS | HIS-master/HIS-api/src/main/java/com/neu/his/api/controller/dms/DmsHerbalPrescriptionRecordController.java | <reponame>bluebird88/HIS
package com.neu.his.api.controller.dms;
import com.neu.his.common.api.CommonResult;
import com.neu.his.common.dto.dms.DmsHerbalPrescriptionRecordParam;
import com.neu.his.common.dto.dms.DmsHerbalPrescriptionRecordResult;
import com.neu.his.component.RabbitMQOrderSender;
import com.neu.his.dms.... |
l0y/smallerc | ch03/exercises/triangle.c | <reponame>l0y/smallerc
#include <stdio.h>
int main() {
int triangleSize;
printf("Please enter a size for your triangle (1 - 20): ");
scanf("%i", &triangleSize);
if (triangleSize < 1 || triangleSize > 20) {
printf("We can't make a triangle that size. Sorry!\n");
printf("We'll use the default size of 10 ... |
JincorTech/music-ico-dashboard | src/components/common/VerifyTip/index.js | import React from 'react';
const VerifyTip = (props) => {
const {
method
} = props;
const email = (
<div>To activate account - enter PIN code from email</div>
);
const app = (
<div>To activate account - enter PIN code from Google Authenticator</div>
);
return method === 'google_auth' ? app... |
sungmen/Acmicpc_Solve | Acmicpc/C++/BOJ2696.cpp | <reponame>sungmen/Acmicpc_Solve<filename>Acmicpc/C++/BOJ2696.cpp
#include <bits/stdc++.h>
using namespace std;
int main() {
// freopen("input.in", "r", stdin);
ios_base::sync_with_stdio(false), cin.tie(nullptr), cout.tie(nullptr);
int t; cin >> t;
while (t--) {
int m; cin >> m;
priority_... |
gomeifuku/Ultraino | AcousticField3D/src/acousticfield3d/utils/ArrayUtils.java | <reponame>gomeifuku/Ultraino
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package acousticfield3d.utils;
import java.util.List;
/**
*
* @author am14010
*/
public ... |
MegRiley/cqf-ruler | src/main/java/org/opencds/cqf/qdm/fivepoint4/repository/NegativeSubstanceAdministeredRepository.java | package org.opencds.cqf.qdm.fivepoint4.repository;
import org.opencds.cqf.qdm.fivepoint4.model.NegativeSubstanceAdministered;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.stereotype.Repository;
import javax.annotation.Nonnull;
import java.util.Optional;
@Repository
public ... |
jeffpuzzo/jp-rosa-react-form-wizard | node_modules/@patternfly/react-tokens/dist/esm/c_options_menu__menu_item_icon_PaddingLeft.js | <filename>node_modules/@patternfly/react-tokens/dist/esm/c_options_menu__menu_item_icon_PaddingLeft.js
export const c_options_menu__menu_item_icon_PaddingLeft = {
"name": "--pf-c-options-menu__menu-item-icon--PaddingLeft",
"value": "1.5rem",
"var": "var(--pf-c-options-menu__menu-item-icon--PaddingLeft)"
};
export... |
Crazyhackelkorn/ArduPy | shared-bindings/util.h | /*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2017 <NAME> for Adafruit Industries
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to d... |
shuLhan/share | lib/mlog/multi_logger_example_test.go | <gh_stars>10-100
// Copyright 2021, Shulhan <<EMAIL>>. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
package mlog
import (
"bytes"
"fmt"
"log"
"os"
"github.com/shuLhan/share/api/slack"
)
func ExampleMultiLogger() {
buf := bytes.Buf... |
pdpdds/SDLGameProgramming | sdl2/flashback/systemstub.h |
/*
* REminiscence - Flashback interpreter
* Copyright (C) 2005-2018 <NAME> (<EMAIL>)
*/
#ifndef SYSTEMSTUB_H__
#define SYSTEMSTUB_H__
#include "intern.h"
#include "scaler.h"
struct PlayerInput {
enum {
DIR_UP = 1 << 0,
DIR_DOWN = 1 << 1,
DIR_LEFT = 1 << 2,
DIR_RIGHT = 1 << 3
};
enum {
DF_FASTMO... |
GrimshawA/Nephilim | source/UI/UISlider.cpp | #include <Nephilim/UI/UISlider.h>
NEPHILIM_NS_BEGIN
NEPHILIM_NS_END |
Angelussz/ProgramacionCompetitiva | pc_Clase17_5/ClimbStairs.cpp | class Solution {
public:
int climbStairs(int n) {
int re[n+1];
re[0]=1;
re[1]=1;
for(int i=2;i<=n;i++){
re[i] = re[i-1] + re[i-2];
}
return re[n];
}
}; |
aprasolova/neo-go | pkg/core/util.go | <gh_stars>0
package core
import (
"errors"
"time"
"github.com/nspcc-dev/neo-go/pkg/config"
"github.com/nspcc-dev/neo-go/pkg/config/netmode"
"github.com/nspcc-dev/neo-go/pkg/core/block"
"github.com/nspcc-dev/neo-go/pkg/core/interop/interopnames"
"github.com/nspcc-dev/neo-go/pkg/core/transaction"
"github.com/ns... |
ooz/EDLed | src/de/mpg/cbs/edledplugin/stimulus/TimetablePanel.java | package de.mpg.cbs.edledplugin.stimulus;
import java.awt.BasicStroke;
import java.awt.Color;
import java.awt.Dimension;
import java.awt.Font;
import java.awt.FontMetrics;
import java.awt.Graphics;
import java.awt.Graphics2D;
import java.awt.Point;
import java.awt.Rectangle;
import java.awt.event.KeyEvent;
import java.... |
damassa/fmon | server/src/components/images/Controller.js | const db = require('../../database');
exports.imageById = (req, res, next, id) => {
let sql = `SELECT image FROM images WHERE id = ?`;
db.connect.query(sql, [id], (err, values) => {
if(err || !values) {
return res.status(400).json({
error: err
})
}
... |
ayhanugurlu/meetinger | src/main/java/com/au/example/meetinger/service/MailServiceImpl.java | package com.au.example.meetinger.service;
import java.util.Properties;
import org.springframework.mail.SimpleMailMessage;
import org.springframework.mail.javamail.JavaMailSender;
import org.springframework.mail.javamail.JavaMailSenderImpl;
import org.springframework.stereotype.Service;
import com.au.example.meetinge... |
kagwicharles/Seniorproject-ui | node_modules/@iconify/icons-ic/sharp-sports-bar.js | var data = {
"body": "<path d=\"M21 9h-3.56c.35-.59.56-1.27.56-2c0-2.21-1.79-4-4-4c-.34 0-.66.05-.98.13A4.707 4.707 0 0 0 10 2.02c-1.89 0-3.51 1.11-4.27 2.71C4.15 5.26 3 6.74 3 8.5c0 1.86 1.28 3.41 3 3.86V21h11v-2h4V9zM7 10.5c-1.1 0-2-.9-2-2c0-.85.55-1.6 1.37-1.88l.8-.27l.36-.76C8 4.62 8.94 4.02 10 4.02c.79 0 1.39.35 ... |
BobbyWhiskey/sg-orbit | packages/react-components/src/shared/src/useControllableState.js | import { isFunction, isUndefined } from "lodash";
import { useCallback, useRef } from "react";
import { useRefState } from "./useRefState";
function validatePrerequisites(controlledValue, initialValue) {
if (!isUndefined(controlledValue) && !isUndefined(initialValue)) {
throw new Error(
"useCon... |
ScalablyTyped/SlinkyTyped | m/maxim_mazurok__gapi_dot_client_dot_bigquery/src/main/scala/typingsSlinky/maximMazurokGapiClientBigquery/gapi/client/bigquery/EvaluationMetrics.scala | <filename>m/maxim_mazurok__gapi_dot_client_dot_bigquery/src/main/scala/typingsSlinky/maximMazurokGapiClientBigquery/gapi/client/bigquery/EvaluationMetrics.scala
package typingsSlinky.maximMazurokGapiClientBigquery.gapi.client.bigquery
import org.scalablytyped.runtime.StObject
import scala.scalajs.js
import scala.scala... |
alexngn2020/airback | airback-services/src/main/java/com/airback/common/domain/OptionVal.java | <gh_stars>0
/*Domain class of table m_options*/
package com.airback.common.domain;
import com.airback.core.arguments.ValuedBean;
import com.airback.db.metadata.Column;
import com.airback.db.metadata.Table;
import java.time.LocalDateTime;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints... |
Haulmont/jmix-old | modules/core/src/main/java/io/jmix/core/impl/jpql/ErrorNodesFinder.java | <filename>modules/core/src/main/java/io/jmix/core/impl/jpql/ErrorNodesFinder.java
/*
* Copyright 2019 Haulmont.
*
* 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.apach... |
curtcox/ScreenRecorder | src/test/java/com/neomemex/fixed/FixedElementTest.java | package com.neomemex.fixed;
import com.neomemex.ocr.OCR;
import org.junit.Test;
import javax.swing.text.Element;
import static org.junit.Assert.*;
/**
* https://web.archive.org/web/20060110035515/http://java.sun.com/products/jfc/tsc/articles/text/element_interface/
*/
public class FixedElementTest {
static ... |
norishigefukushima/OpenCP | OpenCP/highDimensionalGaussianFilter.cpp | #include "highDimensionalGaussianFilter.hpp"
using namespace std;
using namespace cv;
namespace cp
{
inline double get_l2norm_maxval(const int channel)
{
return sqrt(1024*1024 * channel);
}
template<int gchannel, HDGFSchedule schedule>
void highDimensionalGaussianFilter_(const cv::Mat src, const cv::Mat guide... |
NewSpring/Heighliner | src/util/cache/memory-cache.js | import Crypto from "crypto";
export class InMemoryCache {
constructor(cache = {}, secret = "InMemoryCache") {
// XXX this is really only used for testing purposes
this.cache = cache;
this.secret = secret;
}
get(id, lookup, { ttl, cache } = { ttl: 86400, cache: true }) {
let fromCache = false;
... |
kzx1025/spark_improve | sql/core/target/java/org/apache/spark/sql/columnar/StringColumnBuilder.java | <filename>sql/core/target/java/org/apache/spark/sql/columnar/StringColumnBuilder.java
package org.apache.spark.sql.columnar;
private class StringColumnBuilder extends org.apache.spark.sql.columnar.NativeColumnBuilder<org.apache.spark.sql.catalyst.types.StringType$> {
public StringColumnBuilder () { throw new Runti... |
tonykwok/leonardosketch.amino | src/org/joshy/gfx/test/drawing/OverlayTest.java | <gh_stars>0
package org.joshy.gfx.test.drawing;
import org.joshy.gfx.Core;
import org.joshy.gfx.draw.FlatColor;
import org.joshy.gfx.draw.TransformNode;
import org.joshy.gfx.event.Callback;
import org.joshy.gfx.event.EventBus;
import org.joshy.gfx.event.MouseEvent;
import org.joshy.gfx.node.Node;
import org.joshy.gfx.... |
leaderli/li-runner-flow | node_modules/@antv/x6/es/registry/attr/raw.js | export const raw = {
xlinkHref: 'xlink:href',
xlinkShow: 'xlink:show',
xlinkRole: 'xlink:role',
xlinkType: 'xlink:type',
xlinkArcrole: 'xlink:arcrole',
xlinkTitle: 'xlink:title',
xlinkActuate: 'xlink:actuate',
xmlSpace: 'xml:space',
xmlBase: 'xml:base',
xmlLang: 'xml:lang',
p... |
hdonghong/lifeup | src/main/java/com/hdh/lifeup/controller/UserAuthController.java | package com.hdh.lifeup.controller;
import com.fasterxml.jackson.databind.JsonNode;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.google.common.collect.Lists;
import com.hdh.lifeup.config.AppConfig;
import com.hdh.lifeup.config.YbConfig;
import com.hdh.lifeup.model.constant.AuthTypeConst;
import com.hd... |
hernad/zimbra9 | zm-mailbox/store/src/java/com/zimbra/soap/DocumentHandler.java | <gh_stars>0
/*
* ***** BEGIN LICENSE BLOCK *****
* Zimbra Collaboration Suite Server
* Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015, 2016 Synacor, Inc.
*
* This program is free software: you can redistribute it and/or modify it under
* the terms of the GNU General Public Li... |
jgraber/PythonFriday | SQLAlchemy/ORM/alembic/old_migrations_for_blog_only/347126fc065d_initial_tables_orig.py | <filename>SQLAlchemy/ORM/alembic/old_migrations_for_blog_only/347126fc065d_initial_tables_orig.py
"""Initial tables
Revision ID: 347126fc065d
Revises:
Create Date: 2021-06-12 17:27:18.833477
"""
from alembic import op
import sqlalchemy as sa
# revision identifiers, used by Alembic.
revision = '<KEY>'
down_revision... |
n8225/readflow | pkg/schema/article/mutations.go | <reponame>n8225/readflow<gh_stars>0
package article
import (
"errors"
"github.com/graphql-go/graphql"
"github.com/ncarlier/readflow/pkg/helper"
"github.com/ncarlier/readflow/pkg/model"
"github.com/ncarlier/readflow/pkg/schema"
"github.com/ncarlier/readflow/pkg/schema/category"
"github.com/ncarlier/readflow/pk... |
simpleviewinc/sv-keg | repos/keg-core/core/mocks/redux/index.js | <reponame>simpleviewinc/sv-keg
export * from './connect'
export * from './store'
|
ayxue/BaiduSaxoOpenAPI | dueros/directive/Display/template/BaseTemplate.py | #!/usr/bin/env python2
# -*- encoding=utf-8 -*-
# description:
# author:jack
# create_time: 2018/5/26
"""
模板展示基类
"""
from dueros.directive.Display.template.TextStructure import TextStructure
from dueros.directive.Display.template.ImageStructure import ImageStructure
from dueros.directive.Display.template.TextTyp... |
zealoussnow/chromium | chromecast/graphics/cast_touch_event_gate_test.cc | <gh_stars>1000+
// Copyright 2018 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.
#include "chromecast/graphics/cast_touch_event_gate.h"
#include <memory>
#include "base/run_loop.h"
#include "chromecast/graphics/cast_t... |
mdrillin/modeshape | index-providers/modeshape-lucene-index-provider/src/test/java/org/modeshape/jcr/index/lucene/LuceneIndexProviderTest.java | /*
* ModeShape (http://www.modeshape.org)
*
* 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 o... |
zhangkn/iOS14Header | System/Library/PrivateFrameworks/Silex.framework/SXActionEngine.h | <reponame>zhangkn/iOS14Header
/*
* This header is generated by classdump-dyld 1.0
* on Sunday, September 27, 2020 at 11:43:30 AM Mountain Standard Time
* Operating System: Version 14.0 (Build 18A373)
* Image Source: /System/Library/PrivateFrameworks/Silex.framework/Silex
* classdump-dyld is licensed under GPLv3, Copyri... |
jasonkliu/shifts | app/controllers/hooks_controller.rb | #Allow RT to bill job. Scenarios to handle:
#1. user is not logged into Shift, so should take him to log in and bill -- login must match RT login
#2. user is logged into Shift and is different user from RT -- display error on Shift main page (dashboard)
#3. user is logged into Shift, same netid as from RT, but with in... |
350dotorg/akcrm | cms/forms.py | from actionkit import Client
from actionkit.models import CoreTag, CorePage
from django import forms
from django.conf import settings
from akcrm.cms.models import AllowedTag
class AllowedTagForm(forms.Form):
tag_name = forms.CharField(required=True)
def clean_tag_name(self):
tag_name = self.cleaned_... |
vibedrive/website | site/views/default.js | var html = require('choo/html')
var wrapper = require('../components/wrapper')
var format = require('../components/format')
module.exports = wrapper(view)
function view (state, emit) {
return html`
<div class="x xw xjc c12 p1">
<div class="p1 c8 sm-c12">
<div class="fs2 fwb">${state.page.title}</d... |
Samsung/cynara | src/cyad/CommandlineParser/RawPolicyResult.h | /*
* Copyright (c) 2015 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/LICENSE-2.0
... |
isunktheship/art-collection-repo | scripts/collection.rb | <gh_stars>0
require '../config/environment'
require 'mechanize'
require 'nokogiri'
require 'pp'
puts "Running import script..."
def get_print_uids collection_id
collection_url = "http://expressobeans.com/members/collections.php?id=#{collection_id}&ipp=500"
args = %w[isunktheship manchester1]
print_uids = []
... |
gopa1959/test | setup.py | <gh_stars>0
import os
from setuptools import setup, find_packages
import edx_data_research
# Utility function to read the README file.
# Used for the long_description. It's nice, because now 1) we have a top level
# README file and 2) it's easier to type in the README file than to put a raw
# string in below ...
de... |
watermarkchurch/broken-link-checker | test/helpers/server.js | "use strict";
const fixture = require("./fixture");
const basicAuthHeader = require("basic-auth-header");
const {createDeflate, createGzip} = require("zlib");
const {createReadStream} = require("fs");
const escapeStringRegexp = require("escape-string-regexp");
const nock = require("nock");
const {URL} = require("unive... |
dhatim/safesql | safesql/src/main/java/org/dhatim/safesql/SafeSqlImpl.java | package org.dhatim.safesql;
class SafeSqlImpl implements SafeSql {
private final String sql;
private final Object[] parameters;
private String string;
SafeSqlImpl(String sql, Object[] parameters) {
this.sql = sql;
this.parameters = parameters;
}
@Override
public Stri... |
zelros/cinnamon | src/cinnamon/drift/tests/test_xgboost_model_drift_explainer.py | <reponame>zelros/cinnamon<gh_stars>10-100
import pandas as pd, numpy as np
from numpy.testing import assert_allclose
from sklearn import datasets
from sklearn.model_selection import train_test_split
from xgboost import XGBRegressor, XGBClassifier
from cinnamon.drift import ModelDriftExplainer
from cinnamon.drift.drift_... |
tarikgwa/test | html/app/code/Magento/Msrp/view/base/web/js/msrp.js | <reponame>tarikgwa/test
/**
* Copyright © 2015 Magento. All rights reserved.
* See COPYING.txt for license details.
*/
define([
'jquery',
'underscore',
'jquery/ui',
'mage/dropdown',
'mage/template'
], function ($) {
'use strict';
$.widget('mage.addToCart', {
options: {
... |
RAVURISREESAIHARIKRISHNA/JavaSE | BufferedReadderStringDemo/src/bufferedreadderstringdemo/BufferedReadderStringDemo.java | <gh_stars>0
package bufferedreadderstringdemo;
import java.io.BufferedReader;
import java.io.InputStreamReader;
public class BufferedReadderStringDemo
{
public static void main(String[] args)
{
BufferedReader b = new BufferedReader(new InputStreamReader(System.in));
String str;
... |
piaochung/blog | Spring-Boot/core/core/src/main/java/hello/core/member/Grade.java | package hello.core.member;
public enum Grade {
BASIC, VIP
}
|
dainst/cilantro | workers/default/omp/omp_api.py | import os
import logging
import json
from urllib.request import Request, urlopen
from urllib.error import HTTPError
omp_api_uri = os.environ['OMP_URI']
auth_key = os.environ['OMP_AUTH_KEY']
log = logging.getLogger(__name__)
def publish(import_xml_file_path, press_code):
"""
Publish the documents referenced ... |
ceekay1991/AliPayForDebug | AliPayForDebug/AliPayForDebug/AlipayWallet_Headers/APLogAdditions.h | //
// Generated by class-dump 3.5 (64 bit) (Debug version compiled Sep 17 2017 16:24:48).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2015 by <NAME>.
//
#import <objc/NSObject.h>
@class NSString;
@interface APLogAdditions : NSObject
{
NSString *_deviceModel;
NSString *_language;
... |
davecramer/pljvm | plj-java/performance/src/main/java/org/postgresql/pljvm/MeasureCall.java | package org.postgresql.pljvm;
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.SQLException;
import java.sql.Statement;
public class MeasureCall {
public static void main(String []args) throws Exception{
Connection connection = createConnection("localhost", 5432, "test");
}
stati... |
AtakanFire/adlGame | source/engine/adlMemory.h | <reponame>AtakanFire/adlGame
#ifndef adl_memory_h__
#define adl_memory_h__
#define ADL_NEW(Class_name, ...) new Class_name(__VA_ARGS__);
#define ADL_DELETE(ptr) \
if(ptr != nullptr) \
{ \
delete ptr; \
ptr = nullptr; \
}
#endif // adl_memory_h__
|
oixhwotl/RecursoDeAndroidProgramming | REF/AndExam4_1/src/andexam/ver4_1/c31_gesture/TouchDump.java | <gh_stars>0
package andexam.ver4_1.c31_gesture;
import andexam.ver4_1.*;
import java.util.*;
import android.app.*;
import android.os.*;
import android.view.*;
import android.widget.*;
public class TouchDump extends Activity {
ArrayList<String> arTouch = new ArrayList<String>();
TextView mResult;
p... |
MongoTheGeek/sdl_android | sdl_android/src/main/java/com/smartdevicelink/proxy/rpc/SingleTireStatus.java | package com.smartdevicelink.proxy.rpc;
import com.smartdevicelink.proxy.RPCStruct;
import com.smartdevicelink.proxy.rpc.enums.ComponentVolumeStatus;
import java.util.Hashtable;
/**
* Tire pressure status of a single tire.
* <p><b>Parameter List</b></p>
* <table border="1" rules="all">
* <tr>
* ... |
maciej-barczak-red/pxCore | examples/pxScene2d/external/libnode-v8.9.4/deps/v8/test/mjsunit/wasm/export-global.js | // Copyright 2017 the V8 project authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
load("test/mjsunit/wasm/wasm-constants.js");
load("test/mjsunit/wasm/wasm-module-builder.js");
(function exportImmutableGlobal() {
var builder = new ... |
miguelperezcolom/mateu-financials | src/main/java/io/mateu/financials/domain/model/LitigationLogRecord.java | package io.mateu.financials.domain.model;
import io.mateu.mdd.shared.annotations.Output;
import lombok.MateuMDDEntity;
import javax.persistence.ManyToOne;
import javax.validation.constraints.NotNull;
import java.time.LocalDateTime;
@MateuMDDEntity
public class LitigationLogRecord {
@ManyToOne
@NotNull
p... |
greck2908/robot-software | master-firmware/src/gui.cpp | <gh_stars>10-100
#include <thread>
#include "gui.h"
#include <string.h>
#include <stdio.h>
#include <gfx.h>
#include "gui/Menu.h"
#include "gui/PositionPage.h"
#include "gui/MovePage.h"
#include "gui/ActuatorPage.h"
#include "gui/MenuPage.h"
#include "gui/ScorePage.h"
#include "gui/GoapActionPage.h"
#include "main.h"
#... |
hcxp/hcxp | app/graphql/resolvers/venues_resolver.rb | <reponame>hcxp/hcxp
class Resolvers::VenuesResolver
include Resolvers::ValidationResolver
def call(obj, args, ctx)
first_or_last_required!(args)
col = obj ? obj.venues : Venue.all
params = {
query: args[:query]
}
service = VenuesIndexService.new(col, params)
service.call
end
end
|
michimune/azure-cli-extensions | src/db-up/azext_db_up/util.py | <filename>src/db-up/azext_db_up/util.py
# --------------------------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for license information.
# ----------------------------... |
ivadasz/DragonFlyBSD | usr.sbin/installer/dfuibe_installer/flow.h | <reponame>ivadasz/DragonFlyBSD
/*
* Copyright (c)2004 The DragonFly Project. 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 copy... |
asceenl/lasp | lasp/lasp_atomic.py | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Provides a simple atomic variable:
>>> a = Atomic(0)
Retrieve the value
>>> b = a()
Set a new value:
>>> a <<= b
Get conversion to boolean:
>>> if a:
do something
Atomic increment:
>>> A += 1
@author: <NAME> - ASCEE
"""
from threading import Lock
class Ato... |
dtk/dtk-server | application/model/task/template/content/action_match.rb | <reponame>dtk/dtk-server
#
# Copyright (C) 2010-2016 dtk contributors
#
# This file is part of the dtk project.
#
# 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/licen... |
thariyarox/ORG-carbon-identity | components/identity/org.wso2.carbon.identity.provider/src/main/java/org/wso2/carbon/identity/provider/openid/dao/OpenIDAssociationDAO.java | /*
* Copyright 2005-2008 WSO2, Inc. (http://wso2.com)
*
* 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 applica... |
jaouahbi/VampPlugins | marsyas-vamp/marsyas/src/marsyas/marsystems/HarmonicStrength.h | /*
** Copyright (C) 1998-2010 <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 version.
**
** This program... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.