repo_name
stringlengths
6
101
path
stringlengths
4
300
text
stringlengths
7
1.31M
gavinlaking/vedeu
lib/vedeu/esc/background.rb
<filename>lib/vedeu/esc/background.rb # frozen_string_literal: true module Vedeu module EscapeSequences # Provides background colour related escape sequences. # # @api public # See {file:docs/dsl/by_method/esc.md} module Background extend Forwardable extend self def_delegato...
lheureuxe13/oppia
core/controllers/base.py
# Copyright 2014 The Oppia Authors. 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 ...
ScalablyTyped/SlinkyTyped
a/aws-sdk/src/main/scala/typingsSlinky/awsSdk/workspacesMod/DefaultWorkspaceCreationProperties.scala
<reponame>ScalablyTyped/SlinkyTyped<filename>a/aws-sdk/src/main/scala/typingsSlinky/awsSdk/workspacesMod/DefaultWorkspaceCreationProperties.scala<gh_stars>10-100 package typingsSlinky.awsSdk.workspacesMod import org.scalablytyped.runtime.StObject import scala.scalajs.js import scala.scalajs.js.`|` import scala.scalajs...
bluesjjw/angel
angel-ps/core/src/main/java/com/tencent/angel/ps/io/PSModelIOExecutor.java
package com.tencent.angel.ps.io; import com.tencent.angel.conf.AngelConf; import com.tencent.angel.model.*; import com.tencent.angel.model.io.IOExecutors; import com.tencent.angel.model.output.format.*; import com.tencent.angel.ps.PSContext; import com.tencent.angel.ps.storage.matrix.ServerMatrix; import com.tencent.a...
Volas171/ReactorBot
events/Guild/guildMemberRemove.js
const Discord = require ("discord.js"); module.exports = ({client, botUtils}, member) => { newError = botUtils.newError; try { const timeProp = [1, 1000, 60000, 3600000, 86400000, 31536000000, Number.POSITIVE_INFINITY]; const timename = ["ms", "second", "minute", "hour", "day", "year", "??? Eternity"]; ...
godnoTA/acm.bsu.by
4. Алгоритмы на графах/67.1. Поиск в ширину #3566/[OK]169647.java
import java.io.*; import java.util.*; public class Search { static BufferedWriter writer; public static void main(String[] args) throws IOException { Scanner in=new Scanner (new File("input.txt")); writer = new BufferedWriter(new OutputStreamWriter(new FileOutputStream("output.txt"))); ...
prabhjyotsingh/cloudbreak
datalake/src/main/java/com/sequenceiq/datalake/flow/delete/event/StackDeletionFailedEvent.java
package com.sequenceiq.datalake.flow.delete.event; import com.sequenceiq.cloudbreak.common.event.Selectable; public class StackDeletionFailedEvent implements Selectable { private Long sdxId; private Exception exception; public StackDeletionFailedEvent(Long sdxId, Exception exception) { this.sdx...
CC3002-Metodologias/scrabble-jaedango
src/main/java/files/operations/ops/NumOps/NumOps.java
package files.operations.ops.NumOps; import files.operations.ops.Operations; /** * @author jaedango */ public abstract class NumOps implements Operations { }
reviewboard/ReviewBot
extension/reviewbotext/evolutions/old_tool_model.py
<gh_stars>10-100 from __future__ import unicode_literals from django_evolution.mutations import DeleteModel MUTATIONS = [ DeleteModel('ReviewBotTool'), ]
cpgf/cpgf
samples/tween/src/ui/paneltweentest.cpp
#include "paneltweentest.h" #include "panelcanvas.h" #include "panelease.h" #include "panelcommand.h" #include "toolpanel.h" #include "../easeinfo.h" #include "cpgf/tween/gtweenlist.h" #include "cpgf/accessor/gaccessor.h" #if defined(_WIN32) #include <windows.h> #endif #include <GL/gl.h> #include <G...
cloudmercato/python-fpb
fpb/sum/numpy.py
<reponame>cloudmercato/python-fpb<gh_stars>1-10 from fpb.base import numpy class Runner(numpy.BaseNumpy1dRunner): def run(self, data): output = self.np.sum(data, dtype="float128") return output
cnsvili/mybatis-jpa
src/main/java/com/mybatis/jpa/plugin/ResultTypePlugin.java
package com.mybatis.jpa.plugin; import com.mybatis.jpa.util.FieldReflectUtil; import java.sql.Statement; import java.util.ArrayList; import java.util.HashMap; import java.util.List; import java.util.Map; import java.util.Properties; import javax.persistence.Entity; import javax.persistence.Table; import org...
cadvena/toolbox
tests/test_ez_alchemy.py
<filename>tests/test_ez_alchemy.py import os import unittest from toolbox.ez_alchemy import EZOracle, ez_query, _Examples import pandas as pd from sqlalchemy import engine from toolbox.simple_password import get_credentials from toolbox import tb_cfg DEFAULT_USER = os.environ['username'] NoneType = type (No...
LeeHounshell/Capstone-Project
mobile/src/main/java/com/harlie/radiotheater/radiomysterytheater/utils/EpisodeRecyclerViewAdapter.java
<gh_stars>1-10 package com.harlie.radiotheater.radiomysterytheater.utils; import android.annotation.SuppressLint; import android.content.Context; import android.content.Intent; import android.content.res.Configuration; import android.database.Cursor; import android.os.Bundle; import android.view.LayoutInflater...
manujanethwidu/tirebuilderv3
src/redux/srtpob/srtpobActions.js
const { TOGGLE_SRTPOB } = require('./srtpobConstants') /*Accessed by TireBuilderView Component -->set true or false TireCodeInputComp --> set null */ const toggleSrtPob = (value) => (dispatch) => { dispatch({ type: TOGGLE_SRTPOB, payload: value }) } export { toggleSrtPob }
cbsBiram/xarala__ssr
src/cart/forms.py
from django import forms from django.utils.translation import gettext_lazy as _ COURSE_QUANTITY_CHOICES = [(i, str(i)) for i in range(1, 21)] class CartAddCourseForm(forms.Form): quantity = forms.TypedChoiceField( choices=COURSE_QUANTITY_CHOICES, coerce=int, label=_("Quantité") ) override = form...
vikash-india/DeveloperNotes2Myself
languages/python/src/concepts/P002_HelloWorld.py
<gh_stars>1-10 # Description: "Hello World" Program in Python print("Hello World!") print('Hello Again! But in single quotes') print("You can't enter double quotes inside double quoted string but can use ' like this.") print('Similarly you can enter " inside single quoted string.') print('Or you can escape singl...
vineetseraro/gps-ble-based-guard-trak
api/handlers/configuration.js
const commonHelper = require('../helpers/common'); const bluebirdPromise = require('bluebird'); const mongoose = require('mongoose'); const configHelper = require('../helpers/configuration'); const akResponse = require('../lib/respones'); const messages = require('../mappings/messagestring.json'); const clientHandler =...
BradyBromley/TubeMQ
tubemq-client/src/main/java/com/tencent/tubemq/client/producer/MessageProducer.java
/* * Tencent is pleased to support the open source community by making TubeMQ available. * * Copyright (C) 2012-2019 Tencent. 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 * ...
libero/texture
src/article/metadata/MetadataEditor.js
<filename>src/article/metadata/MetadataEditor.js import { Component, DefaultDOMElement } from 'substance'; import { Managed, OverlayCanvas } from '../../kit'; import MetadataModel from './MetadataModel'; import MetadataSection from './MetadataSection'; import MetadataSectionTOCEntry from './MetadataSectionTOCEntry'; im...
MateusMarttorelli/beecrowd_accepted_solutions_C
bee_1133.c
<filename>bee_1133.c #include <stdio.h> int main() { int x, y; scanf("%d %d", &x, &y); if (x < y) { x++; for (x; x < y; x++) { if (x % 5 == 2 || x % 5 == 3) printf("%d\n", x); } } else if (y < x) { y++; for (y; y < x; y++) { if (y % 5 == 2 || y % 5 == 3) printf("%d\n", y); } } ...
ColombiaTransit/datatools-ui
lib/common/util/json.js
<gh_stars>10-100 // @flow import { analyze } from 'jju' /** * Check if a string is valid JSON. */ export function isValidJSON (str: string): boolean { try { JSON.parse(str) } catch (e) { return false } return true } /** * Check if a string is valid JSONC that OTP should be able to * parse. OTP al...
andrasigneczi/TravelOptimiser
DataCollector/mozilla/xulrunner-sdk/include/nsIFind.h
<filename>DataCollector/mozilla/xulrunner-sdk/include/nsIFind.h /* * DO NOT EDIT. THIS FILE IS GENERATED FROM ../../../dist/idl\nsIFind.idl */ #ifndef __gen_nsIFind_h__ #define __gen_nsIFind_h__ #ifndef __gen_nsISupports_h__ #include "nsISupports.h" #endif /* For IDL files that don't want to include ...
Cinimex-Informatica/activemq
activemq-broker/src/main/java/org/apache/activemq/network/LdapNetworkConnector.java
<reponame>Cinimex-Informatica/activemq /** * 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, ...
parthosa/floodlight-plus
src/main/java/org/openflow/protocol/factory/OFMeterBandFactory.java
<filename>src/main/java/org/openflow/protocol/factory/OFMeterBandFactory.java<gh_stars>0 package org.openflow.protocol.factory; import java.nio.ByteBuffer; import java.util.List; import org.openflow.protocol.meter.OFMeterBand; import org.openflow.protocol.meter.OFMeterBandType; /** * The interface to factories use...
odwraca/nrf9160-dk-aws-fota-secure
samples/nfc/tnep_tag/src/main.c
/* * Copyright (c) 2019 Nordic Semiconductor ASA * * SPDX-License-Identifier: LicenseRef-BSD-5-Clause-Nordic */ #include <stdbool.h> #include <string.h> #include <zephyr.h> #include <sys/util.h> #include <dk_buttons_and_leds.h> #include <nfc_t4t_lib.h> #include <nfc/tnep/tag.h> #include <nfc/ndef/nfc_ndef_msg.h> ...
ppak10/audius-protocol
creator-node/src/models/clockRecord.js
'use strict' module.exports = (sequelize, DataTypes) => { // TODO - why is this not externally accessible? const SourceTableTypesObj = { AudiusUser: 'AudiusUser', Track: 'Track', File: 'File' } const ClockRecord = sequelize.define('ClockRecord', { cnodeUserUUID: { type: DataTypes.UUID, ...
dashbangsplat/-opus_alchimia
src/actors/actor/master-alchemist/movement-states/jumping.js
<reponame>dashbangsplat/-opus_alchimia import State from '../../../../generics/state'; import ChangeState from '../../../../generics/state-action/change-state'; import { startActorJumping, updateJumpingActor } from '../../../actions/movement'; import Standing from './standing'; export default class Jumping extends S...
Fighters-of-Dawn/ECommerce
backend/routes/customer.routes.js
<reponame>Fighters-of-Dawn/ECommerce<gh_stars>0 module.exports = (app) => { const customers = require('../controller/customer.controller.js'); // Create a new Customer app.post('/customers', customers.create); // Retrieve all Customers app.get('/customers', customers.findAll); };
wapache-org/openapi
openapi-generator-server/src/main/java/org/wapache/openapi/server/api/GeneratorApi.java
package org.wapache.openapi.server.api; import org.springframework.core.io.Resource; import org.springframework.http.ResponseEntity; import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.bind.annotation.RequestMapping; im...
ykrasik/jaci
jaci-cli-core/src/main/java/com/github/ykrasik/jaci/cli/assist/ParamAssistInfo.java
/****************************************************************************** * Copyright (C) 2015 <NAME> * * * * Licensed under the Apache License, Version 2.0 (the "License"); * * you m...
ethanlindley/panda3d
panda/src/char/characterJoint.h
<filename>panda/src/char/characterJoint.h<gh_stars>1-10 /** * PANDA 3D SOFTWARE * Copyright (c) Carnegie Mellon University. All rights reserved. * * All use of this software is subject to the terms of the revised BSD * license. You should have received a copy of this license along * with this source code in a f...
ckamtsikis/cmssw
Configuration/Skimming/python/pdwgSingleMu_cfi.py
<reponame>ckamtsikis/cmssw<filename>Configuration/Skimming/python/pdwgSingleMu_cfi.py import FWCore.ParameterSet.Config as cms import Configuration.Skimming.pdwgLeptonRecoSkim_cfi SingleMu = Configuration.Skimming.pdwgLeptonRecoSkim_cfi.PdwgLeptonRecoSkim.clone() SingleMu.UseMuonSelection = cms.bool(True) SingleMu.glob...
skeeey/multicloud-operators-foundation
vendor/open-cluster-management.io/addon-framework/pkg/addonmanager/controllers/agentdeploy/hookcontroller.go
<reponame>skeeey/multicloud-operators-foundation package agentdeploy import ( "context" "fmt" "github.com/openshift/library-go/pkg/controller/factory" "github.com/openshift/library-go/pkg/operator/events" "k8s.io/apimachinery/pkg/api/equality" "k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/api/m...
hjc851/Dataset2-HowToDetectAdvancedSourceCodePlagiarism
Variant Programs/2-4/27/programmer/Developer.java
package programmer; import salesperson.Yardmaster; import faker.AppendageBrake; import java.io.IOException; import java.util.Collections; import java.util.LinkedList; public abstract class Developer { public int leftDeviceClock; public int mediocreReversionMoment; public abstract void cycleIn(Serve work); p...
alessandrojean/anime-no-keiei
src/gui/components/RoundedButton.java
<gh_stars>1-10 package gui.components; import java.awt.Color; import java.awt.Component; import java.awt.Cursor; import java.awt.Dimension; import java.awt.Graphics; import java.awt.Graphics2D; import java.awt.Image; import java.awt.Insets; import java.awt.RenderingHints; import java.awt.Shape; import java...
iuskye/SREWorks
paas/appmanager/tesla-appmanager-meta-helm/src/main/java/com/alibaba/tesla/appmanager/meta/helm/repository/mapper/HelmMetaDOMapper.java
package com.alibaba.tesla.appmanager.meta.helm.repository.mapper; import com.alibaba.tesla.appmanager.meta.helm.repository.domain.HelmMetaDO; import com.alibaba.tesla.appmanager.meta.helm.repository.domain.HelmMetaDOExample; import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Param; impo...
BigMountainTiger/aws-cdk-examples
code-artifact-cdk/cdk.js
<gh_stars>1-10 #!/usr/bin/env node const cdk = require('@aws-cdk/core'); const { CodeArtifactCdkStack } = require('./stacks/code-artifact-cdk-stack'); const app = new cdk.App(); new CodeArtifactCdkStack(app, 'CodeArtifactCdkStack');
BenjaminGonvers/SAE921-GRP4100-CPlusPlus-Class-BGonvers
CPlusPlus-Class/04. EX.09 OOP Inventaire/Item.cpp
#include "Item.h" #include <iostream> item::item(std::string new_name,std::string new_description) { this->name_ = new_name; this->description_ = new_description; std::cout << "item Constructor" << std::endl; } std::string item::get_name() { return this->name_; } std::string item::get_description() { return t...
tusikalanse/acm-icpc
ProjectEuler/092.py
<filename>ProjectEuler/092.py ''' Author: tusikalanse Date: 2021-07-22 17:13:49 LastEditTime: 2021-07-22 17:27:22 LastEditors: tusikalanse Description: ''' from math import factorial cnt = dict() def gao(x: int)-> int: return sum(map(lambda x: int(x) * int(x), str(x))) for i in range(1, 10000000): if i in ...
dajohi/politeiagui
src/hooks/api/useNavigation.js
import * as act from "src/actions"; import * as sel from "src/selectors"; import { useSelector, useAction } from "src/redux"; export default function useNavigation() { const user = useSelector(sel.currentUser); const username = user && user.username; const onLogout = useAction(act.onLogout); const handleLogout...
kkcookies99/UAST
Dataset/Leetcode/train/121/274.java
<reponame>kkcookies99/UAST class Solution { public int XXX(int[] prices) { int max = 0; int min = 0; for (int i = 1; i < prices.length; i++) { if (prices[min] >= prices[i]) { min = i; }else { int price = prices[i] - prices[min]; ...
matrix-revolution/leetcode
src/main/java/com/fishercoder/solutions/_675.java
<gh_stars>1-10 package com.fishercoder.solutions; import java.util.LinkedList; import java.util.List; import java.util.PriorityQueue; import java.util.Queue; /** * 675. Cut Off Trees for Golf Event * * You are asked to cut off trees in a forest for a golf event. * The forest is represented as a non-negative 2D ma...
CrackerCat/Recaf
src/main/java/me/coley/recaf/plugin/api/ClassVisitorPlugin.java
<reponame>CrackerCat/Recaf package me.coley.recaf.plugin.api; import org.objectweb.asm.ClassVisitor; /** * Allow plugins to intercept and modify {@link ClassVisitor}. * * @author xxDark */ public interface ClassVisitorPlugin extends BasePlugin { /** * Intercepts the given {@link ClassVisitor}. * ...
AutoPacker-OSS/AutoPacker
webapp-test/src/main/java/no/autopacker/webtests/helpers/OsCheck.java
package no.autopacker.webtests.helpers; import java.util.Locale; /** * Helper class to check the operating system this Java VM runs in * <p> * Code adapted from http://stackoverflow.com/questions/228477/how-do-i-programmatically-determine-operating-system-in-java */ public final class OsCheck { // cached res...
thinking-github/nbone
nbone/nbone-core/src/test/java/org/nbone/test/TestMain.java
package org.nbone.test; import java.text.NumberFormat; import java.util.ArrayList; import java.util.HashSet; import java.util.List; import java.util.Map; import java.util.Set; import org.nbone.util.BeanMapUtils; import org.nbone.util.json.JSONOperUtils; import org.nbone.web.support.WebResultWrapper; import org.spring...
rhbvkleef/SteamBird
steambird/settings.py
import os from importlib.util import find_spec from django.utils.translation import ugettext_lazy as _ # Build paths inside the project like this: os.path.join(BASE_DIR, ...) BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) # Quick-start development settings - unsuitable for production # See h...
zmdsn/MANSP
problem/problem_based.hpp
#ifndef _PROBLEM_BASE_ #define _PROBLEM_BASE_ #include <dirent.h> #include <fstream> #include <sstream> #include <string> #include <iostream> #include <stdio.h> #include <string.h> #include <unistd.h> #include <sys/types.h> // 提供mode_t 类型 #include <sys/stat.h> // 提供属性操作函数 //#include <dirent.h> ...
rjfpeters-iefbr14/mod1-energy-guard-system
mod1-cav-service/src/main/java/tld/yggdrasill/services/cav/api/GuardEventListener.java
<gh_stars>1-10 package tld.yggdrasill.services.cav.api; import com.fasterxml.jackson.core.JsonProcessingException; import com.fasterxml.jackson.databind.ObjectMapper; import lombok.extern.slf4j.Slf4j; import org.springframework.kafka.annotation.KafkaListener; import org.springframework.kafka.support.KafkaHeaders; impo...
sowmyavasudeva/SmartBookmark
test/unittests/skills/scheduled_skills.py
<reponame>sowmyavasudeva/SmartBookmark<gh_stars>1-10 # Copyright 2017 Mycroft AI 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 # # Unl...
SuperMap/iClient-for-JavaScript
tests/REST/SpatialAnalyst/ClipParameterTest.js
<gh_stars>10-100 module("ClipParameter"); test("TestClipParameter_constructorDefault", function () { expect(6); var params = new SuperMap.REST.ClipParameter(); ok(params !== null, "params not null"); equal(params.clipDatasetName, null, "params.clipDatasetName"); equal(params.clipDatasourceName, null...
larkov/MailTrackerBlocker
MailHeaders/Catalina/MailUI/TemporaryAttachmentOpener.h
// // Generated by class-dump 3.5b1 (64 bit) (Debug version compiled Dec 3 2019 19:59:57). // // Copyright (C) 1997-2019 <NAME>. // #import "GenericAttachmentFetcher.h" @class NSString; @interface TemporaryAttachmentOpener : GenericAttachmentFetcher { NSString *_applicationPath; // 8 = 0x8 } @property(rea...
T0mmykn1fe/chaosk
src/components/RadioGroup.js
<reponame>T0mmykn1fe/chaosk<gh_stars>0 import cx from 'classnames'; import PropTypes from 'prop-types'; import React, { createContext } from 'react'; import FormLabel from './FormLabel'; import FormFooter from './FormFooter'; import Inline from './Inline'; import List from './List'; import ListItem from './ListItem'; ...
valeriocos/jbrex
org.eclipse.m2m.atl.engine.emfvm/src/org/eclipse/m2m/atl/engine/emfvm/lib/ASMModule.java
/******************************************************************************* * Copyright (c) 2007 INRIA. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at * http:/...
patvong/AvaTax-SOAP-Java-SDK
avatax4j-accountsvc/src/com/avalara/avatax/services/account/Company.java
<reponame>patvong/AvaTax-SOAP-Java-SDK<filename>avatax4j-accountsvc/src/com/avalara/avatax/services/account/Company.java /** * Company.java * * This file was auto-generated from WSDL * by the Apache Axis 1.2.1 Jun 14, 2005 (09:15:57 EDT) WSDL2Java emitter. */ package com.avalara.avatax.services.account; public c...
DeepBlue14/rqt_ide
modules/ide_old/src/SearchWidget.h
<reponame>DeepBlue14/rqt_ide<filename>modules/ide_old/src/SearchWidget.h /* * File: SearchGui.h * Module: Run * Author: <NAME> * Email: <EMAIL> * File Description: * * Created on June 6, 2015, 3:38 PM */ #ifndef SEARCH_WIDGET_H #define SEARCH_WIDGET_H #include <QWidget> #include <QLineEdit> #include <QStr...
hajin-kim/2020-HighSchool-Python-Tutoring
ch6/6_1.py
a = 100 if a < 100: print("조건이 참입니다") print("실행을 종료합니다")
usegalaxy-no/usegalaxy
venv/lib/python3.6/site-packages/ansible_collections/sensu/sensu_go/plugins/modules/secret.py
<reponame>usegalaxy-no/usegalaxy #!/usr/bin/python # -*- coding: utf-8 -*- # Copyright: (c) 2020, XLAB Steampunk <<EMAIL>> # # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) from __future__ import absolute_import, division, print_function __metaclass__ = type ANSIBLE_METADA...
anbruzga/Set-Theory-Calc
src/Sets/Controler/Calculate.java
<reponame>anbruzga/Set-Theory-Calc package Sets.Controler; import Sets.Model.*; import Sets.View.PopUp; import java.util.ArrayList; import java.util.Iterator; import java.util.Queue; import static Sets.Model.Symbols.*; public class Calculate { private static boolean syntaxCheckPassed = true; public Calculate...
EddeDev/RaybyteEngine
Raybyte/Source/Raybyte/Math/Math.h
#pragma once namespace Raybyte { namespace Math { float Repeat(float t, float length); float DeltaAngle(float current, float target); float Angle(const glm::vec3& a, const glm::vec3& b); bool DecomposeMatrix4(const glm::mat4& matrix, glm::vec3& position); bool DecomposeMatrix4(const glm::mat4& matrix, gl...
fboucher9/appl
random/appl_random_std_crypto.cpp
<gh_stars>0 /* See LICENSE for license details */ /* */ #include <stdio.h> #include <appl_status.h> #include <appl_types.h> #include <object/appl_object.h> #include <random/appl_random.h> #include <random/appl_random_std_crypto.h> #include <misc/appl_unused.h> #include <allocator/appl_allocator_handle.h> // ...
josetonyp/elements
spec/factories/elements_users.rb
FactoryGirl.define do factory :user, :class => 'Elements::User' do sequence(:name) {|n| "Name - #{n}"} sequence(:lastname) {|n| "Lastname - #{n}"} sequence(:email) {|n| "<EMAIL>"} password "<PASSWORD>" end end
appform-io/databuilderframework
src/test/java/io/appform/databuilderframework/speed/AdditonRequestData.java
<filename>src/test/java/io/appform/databuilderframework/speed/AdditonRequestData.java package io.appform.databuilderframework.speed; import io.appform.databuilderframework.model.Data; public class AdditonRequestData extends Data{ protected AdditonRequestData() { super("ADD_REQ"); } }
indunet/fastproto
src/main/java/org/indunet/fastproto/checksum/Crc16Checker.java
<reponame>indunet/fastproto /* * Copyright 2019-2021 indunet * * 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 b...
manuelecarlini/calamari-clients
dashboard/app/bower_components/dygraphs/experimental/palette/tooltip.js
// Copyright (c) 2011 Google, Inc. // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal // in the Software without restriction, including without limitation the rights // to use, copy, modify, merge, publish, ...
project-sunbird/groups
group-actors/src/main/java/org/sunbird/util/DBUtil.java
package org.sunbird.util; import java.util.HashMap; import java.util.Map; import org.apache.commons.lang3.StringUtils; import org.sunbird.common.exception.BaseException; import org.sunbird.common.util.JsonKey; import org.sunbird.helper.CassandraConnectionManager; import org.sunbird.helper.CassandraConnectionMngrFactor...
michaeldiogo253/ecommerce-api-rest
src/test/java/estudos/ecommerce/cliente/adapter/in/web/ListarTodosOsClientesControllerTestIT.java
package estudos.ecommerce.cliente.adapter.in.web; import org.junit.jupiter.api.Test; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.test.context.SpringBootTest; import org.springframework.boot.test.web.client.TestRestTemplate; import org.springframework.http.HttpStatus; ...
mfloresn90/JavaSources
vogella/de.vogella.osgi.quoteservice/src/de/vogella/osgi/quoteservice/Activator.java
<reponame>mfloresn90/JavaSources<gh_stars>0 package de.vogella.osgi.quoteservice; import org.osgi.framework.BundleActivator; import org.osgi.framework.BundleContext; import de.vogella.osgi.quote.IQuoteService; import de.vogella.osgi.quoteservice.internal.QuoteService; public class Activator implements Bundle...
MediaFire/mediafire-java-sdk
src/main/java/com/mediafire/sdk/MFActionToken.java
package com.mediafire.sdk; public class MFActionToken extends MFToken implements MediaFireActionToken { private final int type; private final long requestTime; private final int lifespan; protected MFActionToken(String sessionToken, int type, long requestTime, int lifespan) { super(sessionToke...
go2max/java-snake-game
src/view/controls/SharedResourcesView.java
package view.controls; import models.board.SharedResources; import models.palacefestival.Deck; import view.MediaController; import javax.swing.*; import java.awt.*; //TODO [Sydney] [Jorge] public class SharedResourcesView extends JPanel { private final int BORDER = 10; private final int WIDTH = (int)(Toolki...
thehyve/civic-server
app/presenters/diff_presenter.rb
class DiffPresenter include ERB::Util def initialize(changes_hash) @changes_hash = changes_hash end def as_json(options = {}) @changes_hash.each_with_object({}) do |(property_name, values), changes| (old_value, new_value) = if values.is_a?(Array) values ...
terrai/rastercube
rastercube/scripts/worldgrid_info.py
""" Print infos about a worldgrid Example invocation:: python rastercube/scripts/worldgrid_info.py --grid_root=hdfs:///user/test/ndvi """ import argparse import rastercube.jgrid as jgrid parser = argparse.ArgumentParser(description='Create NDVI/QA jgrids from HDF') parser.add_argument('--grid_root', type...
a982338665/customRPC
rpc-codec/src/test/java/pers/li/codec/JSONEncoderTest.java
<reponame>a982338665/customRPC package pers.li.codec; import org.junit.Test; import static org.junit.Assert.*; public class JSONEncoderTest { @Test public void encode() { Encoder jsonEncoder = new JSONEncoder(); TestBean testBean = new TestBean(); testBean.setAge(1); testBean...
hoshiryu/Radium-Engine
tests/ExampleApps/SimpleAnimationApp/minimalradium.hpp
#pragma once #include <Core/Animation/KeyFramedValue.hpp> #include <Core/Animation/KeyFramedValueController.hpp> #include <Core/Utils/Color.hpp> #include <Engine/Component/Component.hpp> #include <Engine/System/System.hpp> /* This file contains a minimal radium/qt application which shows the * "Simple Animation" dem...
jianjustin/mini-yeation-mall
app/src/main/java/org/mini/yeation/mall/model/GoodsModel.java
package org.mini.yeation.mall.model; import org.mini.yeation.mall.BaseApplication; import org.mini.yeation.mall.dao.GoodsCategoryDao; import org.mini.yeation.mall.domain.GoodsCategory; import org.mini.yeation.mall.model.base.BaseModel; import org.mini.yeation.mall.model.base.IModel; import org.mini.yeation.mall.utils....
thomjoy/turftest
src/jspm_packages/npm/public-encrypt@2.0.0.js
module.exports = require("npm:public-encrypt@2.0.0/browser");
advanced-software-engineering/ASE19
src/main/java/ch/uzh/ifi/seal/ase19/core/PersistenceManager.java
<gh_stars>1-10 package ch.uzh.ifi.seal.ase19.core; import cc.kave.commons.utils.io.json.JsonUtils; import ch.uzh.ifi.seal.ase19.core.models.QuerySelection; import ch.uzh.ifi.seal.ase19.core.models.ResultType; import ch.uzh.ifi.seal.ase19.core.utils.FileUtils; import org.apache.commons.lang3.tuple.Pair; import java.io...
zabi94/Covens-reborn
src/main/java/com/covens/api/cauldron/IBrewEffect.java
package com.covens.api.cauldron; import javax.annotation.Nullable; import net.minecraft.entity.Entity; import net.minecraft.entity.EntityLivingBase; import net.minecraft.potion.PotionEffect; import net.minecraft.util.EnumFacing; import net.minecraft.util.math.BlockPos; import net.minecraft.world.World; public interf...
khcitizen/tomcat-deployed
webapps/jasperserver-pro/scripts/bower_components/js-sdk/src/components/scalableTree/ScalableTree.js
<reponame>khcitizen/tomcat-deployed<filename>webapps/jasperserver-pro/scripts/bower_components/js-sdk/src/components/scalableTree/ScalableTree.js<gh_stars>0 /* * Copyright (C) 2005 - 2014 Jaspersoft Corporation. All rights reserved. * http://www.jaspersoft.com. * * Unless you have purchased a commercial license ag...
duarterafael/Conformitate
ArgoUML/argouml-app/src/org/argouml/ui/cmd/ActionAdjustSnap.java
<filename>ArgoUML/argouml-app/src/org/argouml/ui/cmd/ActionAdjustSnap.java /* $Id: ActionAdjustSnap.java 17842 2010-01-12 19:21:22Z linus $ ***************************************************************************** * Copyright (c) 2009 Contributors - see below * All rights reserved. This program and the accompany...
kassanmoor/rexray
libstorage/api/server/handlers/handlers_errors.go
<gh_stars>1-10 package handlers import ( "encoding/json" "net/http" log "github.com/sirupsen/logrus" "github.com/akutz/goof" "github.com/thecodeteam/rexray/libstorage/api/context" "github.com/thecodeteam/rexray/libstorage/api/server/httputils" "github.com/thecodeteam/rexray/libstorage/api/types" ) // errorHa...
r-korchagin/hackerrankJS
FairRations.js
"use strict"; // hackerrank question // Fair Rations /** * * @param {Array} B */ function fairRations(B) { if (B.reduce((accum,el)=>accum+el)%2!==0) return 'NO'; let count = 0; for(let i = 0; i<B.length; i++){ if(B[i] % 2 != 0){ B[i] = B[i] + 1; B[i+1] = B[i+1] + 1; ...
urxp/dRally
race___4a25ch.c
<reponame>urxp/dRally<gh_stars>10-100 #include "drally.h" extern byte ___243c60h[]; extern byte ___1e6ed0h[]; extern byte ___1de580h[]; extern byte ___243d08h[]; extern byte ___1de7d0h[]; void ___4a064h_cdecl(dword, dword, dword, dword); void race___4a25ch(void){ double d_tmp; dword eax, ebx, ecx, edx, edi...
1stmateusz/motech
platform/mds/mds/src/test/java/org/motechproject/mds/annotations/internal/LookupProcessorTest.java
package org.motechproject.mds.annotations.internal; import com.thoughtworks.paranamer.Paranamer; import org.joda.time.DateTime; import org.junit.Before; import org.junit.Test; import org.mockito.InjectMocks; import org.mockito.Mock; import org.motechproject.commons.api.Range; import org.motechproject.commons.date.mode...
ligoj/bootstrap
bootstrap-business/src/main/java/org/ligoj/bootstrap/resource/system/DateVo.java
/* * Licensed under MIT (https://github.com/ligoj/ligoj/blob/master/LICENSE) */ package org.ligoj.bootstrap.resource.system; import java.util.Date; import lombok.Getter; import lombok.Setter; /** * Date information. */ @Getter @Setter public class DateVo { /** * Application timezone identifier. */ privat...
JordanLongstaff/ian
src/main/java/com/walkertribe/ian/enums/OtherMessage.java
<filename>src/main/java/com/walkertribe/ian/enums/OtherMessage.java package com.walkertribe.ian.enums; /** * Messages that can be sent to civilian NPCs. * @author rjwut */ public enum OtherMessage implements CommsMessage { HAIL(0), TURN_TO_HEADING_0(1), TURN_TO_HEADING_90(2), TURN_TO_HEADING_180(3), TURN_TO_H...
MotorFu/SplashActivity
src/com/zxq/vo/GroupChat.java
<gh_stars>0 package com.zxq.vo; import com.zxq.db.GroupChatProvider; import com.zxq.util.TimeUtil; /** * Created by zxq on 2014/10/31. */ public class GroupChat { public long dateMilliseconds; public String date; public String message; public int come; public String jid; public String roomJi...
GadgetSeed/gadgetseed
uilib/dialogbox/netset/netset.c
<reponame>GadgetSeed/gadgetseed<filename>uilib/dialogbox/netset/netset.c /** @file @brief ネットワーク設定ダイアログボックス @date 2019.09.01 @author <NAME> */ #include "sysconfig.h" #include "netset.h" #include "str.h" #include "font.h" #include "tprintf.h" #include "net.h" #include "lwip/ip.h" #include "lwip/dns.h" #...
NodeNA/nodena-api
core/models/index.js
import { extend } from 'lodash'; // enable event listeners import './base/listeners'; /** * Expose all models */ exports = module.exports; const models = [ 'permission', 'post', 'post-meta', 'role', 'tag', 'user', 'author', 'meetup', 'event', 'token', ...
CanterburyRegionalCouncil/wab-widgets
widgets/SmartEditorEcan/nls/pt-br/strings.js
<filename>widgets/SmartEditorEcan/nls/pt-br/strings.js define({ "_widgetLabel": "Editor Inteligente", "noEditPrivileges": "Sua conta não tem permissão para criar ou modificar dados.", "widgetActive": "Ativo", "widgetNotActive": "Inativo", "pressStr": "Pressione ", "ctrlStr": " CTRL ", "snapStr": " ...
DAIAD/utility-mapreduce-
src/main/java/eu/daiad/mapreduce/hbase/model/Group.java
package eu.daiad.mapreduce.hbase.model; import java.util.ArrayList; import java.util.Arrays; import java.util.List; import org.joda.time.DateTimeZone; public class Group { private List<String> serial = new ArrayList<String>(); private List<byte[]> serialHash = new ArrayList<byte[]>(); private EnumGrou...
frederikspang/ey-cookbooks-stable-v6
custom-cookbooks/thinking_sphinx_3/custom-thinking_sphinx_3/attributes/default.rb
<reponame>frederikspang/ey-cookbooks-stable-v6<filename>custom-cookbooks/thinking_sphinx_3/custom-thinking_sphinx_3/attributes/default.rb<gh_stars>1-10 # default['sphinx']['utility_name'] = 'sphinx' # default['sphinx']['applications'] = ['todo'] # default['sphinx']['version'] = '2.2.11-2' # default['sphinx']['frequency...
devshank3/Open3D
src/Cuda/Common/Palatte.h
<gh_stars>100-1000 // // Created by wei on 4/3/19. // #pragma once #include "Common.h" #include "LinearAlgebraCuda.h" namespace open3d { namespace cuda { __HOSTDEVICE__ inline Vector3f Jet(float v, float vmin, float vmax) { Vector3f c = Vector3f::Ones(); const float dv = vmax - vmin; const float inv_dv ...
dmcnamee/snc
src/snc/simulation/store_data/json_logging.py
import logging from pythonjsonlogger import jsonlogger def set_up_json_logging(): logger = logging.getLogger() log_handler = logging.StreamHandler() formatter = jsonlogger.JsonFormatter() log_handler.setFormatter(formatter) logger.addHandler(log_handler)
supreethavadhani/metadev
fm-all/core/src/main/java/org/simplity/fm/core/datatypes/DateType.java
/* * Copyright (c) 2019 simplity.org * * 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, publis...
gov466/Embedded-C
C program/bill_soft.c
#include<stdio.h> int main() { char fud_name; int price,qty; printf("enter the dish name: "); scanf("%s",&fud_name); printf("enter the price : "); scanf("%d",&price); printf("enter the quantity : "); scanf("%d",&qty); int sum= qty*price; printf("%d",sum); float hst = 13%sum; printf("%f",hst); float total= ...
rmnbhm/wichtelnng
src/main/java/com/romanboehm/wichtelnng/data/MonetaryAmount.java
package com.romanboehm.wichtelnng.data; import lombok.Data; import org.javamoney.moneta.Money; import javax.persistence.Column; import javax.persistence.Embeddable; import java.math.BigDecimal; @Data @Embeddable public class MonetaryAmount { @Column(nullable = false, precision = 10, scale = 2) private B...
suveng/demo
kafka/kafka-spring/src/main/java/com/my/qs/kafkademo/consumer/ConsumerKafka.java
<reponame>suveng/demo package com.my.qs.kafkademo.consumer; import org.apache.kafka.clients.consumer.*; import org.apache.kafka.common.PartitionInfo; import org.apache.kafka.common.TopicPartition; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import java...
purple-polar-bear/go-ogc-api
core/models/route.go
<filename>core/models/route.go package coremodels type Route interface { // Name of the route Name() string // List of handlers. The indexing string represents the contenttype Handlers() map[string]Handler LandingpageVisible() bool }
CuteShaun/frontend-2019-homeworks
submissions/vv2529/js-dom/script.js
// "getId" is much easier to write :) function getId(id){return document.getElementById(id)} const navbar = getId('navbar'); const main = getId('main'); /* * Events */ getId('navbar-toggle').addEventListener('click', function(){ navbar.classList.toggle('shown'); }); navbar.addEventListener('click', function(even...