repo_name stringlengths 6 101 | path stringlengths 4 300 | text stringlengths 7 1.31M |
|---|---|---|
joeharrison91/service-manual-publisher | app/forms/guide_form.rb | class GuideForm < BaseGuideForm
attr_accessor :topic_section_id
def slug_prefix
"/service-manual"
end
private
def load_custom_attributes
self.topic_section_id = topic_section.try(:id)
end
def set_custom_attributes
if topic_section_id.present?
topic_section_guide.topic_section_id = topi... |
amolofos/kata | Problems/RemoveOneElementToMakeTheArrayStrictlyIncreasing/java/src/test/java/com/dkafetzi/kata/SolutionTest.java | package com.dkafetzi.kata;
import static org.junit.Assert.assertEquals;
import org.junit.jupiter.api.DisplayName;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.TestInfo;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
class SolutionTest {
private final static Logger LOGGER = LoggerFacto... |
suewonjp/civilizer | src/main/java/com/civilizer/web/view/TagBean.java | package com.civilizer.web.view;
import java.io.Serializable;
import com.civilizer.domain.Tag;
@SuppressWarnings("serial")
public final class TagBean implements Serializable {
private Tag tag;
// number of fragments associated with this tag only
private long fragmentCount = 0;
// number of frag... |
fosonmeng/virtual-touch | src/touchaction/constructor.js | <gh_stars>0
import {
TOUCH_ACTION_COMPUTE,
TOUCH_ACTION_NONE,
TOUCH_ACTION_PAN_X,
TOUCH_ACTION_PAN_Y,
} from './consts';
import {
DIRECTION_VERTICAL,
DIRECTION_HORIZONTAL,
} from '../input/consts';
import each from '../utils/each';
import valOrFunc from '../utils/val-or-func';
import inStr from '../utils/in... |
upperlevel/quakecraft | src/main/java/xyz/upperlevel/quakecraft/events/KillStreakReachEvent.java | <filename>src/main/java/xyz/upperlevel/quakecraft/events/KillStreakReachEvent.java<gh_stars>1-10
package xyz.upperlevel.quakecraft.events;
import lombok.Getter;
import lombok.Setter;
import org.bukkit.event.Cancellable;
import org.bukkit.event.Event;
import org.bukkit.event.HandlerList;
import xyz.upperlevel.quakecraf... |
crazymaza/job4j | chapter_002/src/main/java/ru/job4j/tracker/BaseAction.java | <filename>chapter_002/src/main/java/ru/job4j/tracker/BaseAction.java
package ru.job4j.tracker;
abstract class BaseAction implements UserAction {
private final int numberOfMenu;
private final String name;
public BaseAction(int numberOfMenu, String name) {
this.numberOfMenu = numberOfMenu;
t... |
mjung85/iotsys | iotsys-enocean-library/test/org/opencean/core/utils/BitsTest.java | <gh_stars>10-100
package org.opencean.core.utils;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertFalse;
import static org.junit.Assert.assertTrue;
import org.junit.Test;
import org.opencean.core.utils.Bits;
public class BitsTest {
@Test
public void getBitFirstB... |
jnthn/intellij-community | java/java-tests/testData/codeInsight/daemonCodeAnalyzer/quickFix/extractStreamMap/afterGeneric.java | // "Extract variable 'set' to 'map' operation" "true"
import java.util.*;
import java.util.stream.*;
public class Test {
void testMap(List<Map<String, String>> list) {
list.stream().map(Map::keySet).flatMap(set -> set.stream()).forEach(System.out::println);
}
} |
Shelvak/monitor | app/controllers/taggings_controller.rb | <reponame>Shelvak/monitor<filename>app/controllers/taggings_controller.rb
class TaggingsController < ApplicationController
respond_to :js, :json
before_action :authorize, :set_issue
before_action :set_tagging, only: [:show, :destroy]
before_action :set_title, except: [:destroy]
def new
@tagging = @issue... |
aplocon/sis | core/sis-metadata/src/main/java/org/apache/sis/internal/xml/LegacyNamespaces.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may ... |
agrc/wfrc | cypress/integration/map_widget_spec.js | describe('map-widget', () => {
it('button toggles pane visibility', () => {
cy.loadApp();
cy.findByText(/filter/i).should('be.visible');
cy.get('[title="Filter"] > .svg-inline--fa').click();
cy.findByText(/filter/i).should('not.be.visible');
cy.get('[title="Filter"] > .svg-inline--fa').click()... |
Xamaneone/Python-OOP | defining_classes _exercise/todo_list/project/test.py | from task import Task
from section import Section
import unittest
class Test(unittest.TestCase):
def test_task_init(self):
task = Task("Tst", "27.04.2020")
message = f"{task.name} - {task.due_date}"
expected = "Tst - 27.04.2020"
self.assertEqual(message, expected)
def test_c... |
Alekssasho/sge_source | libs/sge_engine/src/sge_engine/traits/TraitPath.h | #pragma once
#include "sge_engine/Actor.h"
#include "sge_utils/utils/optional.h"
namespace sge {
struct TraitPath3D;
enum BounceType {
bounceType_bounce,
bouceType_reset,
bounceType_stop,
bounceType_onForwardOffBackwards,
bounceType_idle,
};
float computePathLength(const std::vector<vec3f>& path);
vec3f sampl... |
pichsy/xbaseutils | utils/src/main/java/com/pichs/common/utils/utils/SPHelper.java | <reponame>pichsy/xbaseutils
package com.pichs.common.utils.utils;
import android.content.Context;
import com.pichs.common.utils.BaseSPHelper;
public class SPHelper extends BaseSPHelper {
private final static String spName = "xp_base_sp_helper_info";
private static SPHelper INSTANCE;
protected SPHelper... |
Marcoakira/Desafios_Python_do_Curso_Guanabara | Mundo3/Desafio101.py | # desafio101 o programa recebe a data de nascimento e retorna se a pessoa tem : voto obrigatorio, opcional, ou nao é votante.
def voto(nasc):
from datetime import date
votante = date.today().year - nasc
if votante < 16:
return print(f' voce possui {votante} anos. Ainda não pode votar')
elif v... |
EzioL/leetcode | src/main/java/_01_06_CompressString.java | <filename>src/main/java/_01_06_CompressString.java
/**
* Here be dragons !
*
* @author: Ezio
* created on 2020/3/16
*/
public class _01_06_CompressString {
static class Solution {
public String compressString(String S) {
if (S == null) {
return null;
}
... |
etrex/kamiflex | example/dialog.rb | require_relative '../lib/kamiflex'
require 'clipboard'
def border(color)
{
borderColor: color,
borderWidth: :light
}
end
def green_box(options = {})
horizontal_box **border("#00FF00").merge(options) do
yield if block_given?
end
end
def blue_box(options = {})
horizontal_box **border("#0000FF").m... |
nodejayes/ts-tooling | src/types/datetime/daterange/daterange.js | <gh_stars>0
const {TimeSpan} = require('../timespan/timespan');
/**
* some Calculations for DateTime Ranges
*
* @memberof module:types/daterange
*/
class DateRange {
/**
* the Start DateTime
*
* @readonly
* @return {DateTime}
* @example
* const a = DateTime.FromISOString('2019-01-... |
OutoftheBoxFTC/Summer-Motion-Profiling | TeamCode/src/main/java/opmode/FunctionalityTest.java | package opmode;
import com.qualcomm.robotcore.eventloop.opmode.TeleOp;
import java.util.HashMap;
import hardware.ReadData;
import hardware.Hardware;
import math.Vector4;
import state.DriveState;
import state.LogicState;
/**
* This class is a raw debug class of all sensors/functionality to test against expected beha... |
InsightEdge/xap | xap-core/xap-datagrid/src/main/java/com/j_spaces/jdbc/builder/range/FunctionCallDescription.java | /*
* Copyright (c) 2008-2016, GigaSpaces Technologies, Inc. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Un... |
knightliao/vpaas | vpaas-lc/vpaas-lc-server/vpaas-lc-server-service/vpaas-lc-server-connect/src/main/java/com/github/knightliao/vpaas/lc/server/connect/netty/statistics/service/impl/LcCounterServiceImpl.java | package com.github.knightliao.vpaas.lc.server.connect.netty.statistics.service.impl;
import com.github.knightliao.vpaas.lc.server.connect.netty.server.ILcServer;
import com.github.knightliao.vpaas.lc.server.connect.netty.server.LcServerContext;
import com.github.knightliao.vpaas.lc.server.connect.netty.service.ILcServ... |
emartech/rdb-connector-collection | redshift/src/it/scala/com/emarsys/rdb/connector/redshift/RedshiftInsertSpec.scala | <reponame>emartech/rdb-connector-collection
package com.emarsys.rdb.connector.redshift
import akka.actor.ActorSystem
import akka.testkit.TestKit
import com.emarsys.rdb.connector.redshift.utils.{SelectDbInitHelper, SelectDbWithSchemaInitHelper}
import com.emarsys.rdb.connector.test.InsertItSpec
import scala.concurrent... |
soustab10/cv-frontend | src/utils.js | import simulationArea from './simulationArea';
import {
scheduleUpdate, play, updateCanvasSet, errorDetectedSet, errorDetectedGet,
} from './engine';
window.globalScope = undefined;
window.lightMode = false; // To be deprecated
window.projectId = undefined;
window.id = undefined;
window.loading = false; // Flag - ... |
yzj97/vue-static | src/finance/api/accountCycle.js | export default {
accountCycleListPage: {
url: 'back-finance-web/accountCycleConfig/listPage.do',
method: 'post'
},
generateList: {
url: 'back-finance-web/accountCycleConfig/generate.do',
method: 'post'
},
saveAccountCycle: {
url: 'back-finance-web/accountCycleConfig/add.do',
method: 'p... |
JKot-Coder/slang | tools/gfx/vulkan/vk-util.cpp | // vk-util.cpp
#include "vk-util.h"
#include "core/slang-math.h"
#include <stdlib.h>
#include <stdio.h>
namespace gfx {
/* static */VkFormat VulkanUtil::getVkFormat(Format format)
{
switch (format)
{
case Format::R32G32B32A32_TYPELESS: return VK_FORMAT_R32G32B32A32_SFLOAT;
case Format::R3... |
abrams27/mimuw | sem2/po/kolokwia/kolos2017/src/Wyspa.java | import java.util.Arrays;
import java.util.Random;
public class Wyspa {
private Jablko[] jablonie;
private int liczbaJabloni;
public Wyspa() {
Random gen = new Random();
this.liczbaJabloni = gen.nextInt(7);
jablonie = new Jablko[liczbaJabloni];
for (int i = 0; i < liczbaJabloni; i++) {
jablonie[i]... |
mateuszchudyk/intel-graphics-compiler | visa/iga/IGALibrary/Backend/Messages/MessageDecoder.cpp | <filename>visa/iga/IGALibrary/Backend/Messages/MessageDecoder.cpp
/*========================== begin_copyright_notice ============================
Copyright (C) 2020-2021 Intel Corporation
SPDX-License-Identifier: MIT
============================= end_copyright_notice ===========================*/
#include "Message... |
SENA-CEET/1262154-G1G2-Trimestre-2 | java/poo/ClasesRelaciones/src/main/java/co/edu/sena/clasesrelaciones/asociacion/ejemplo1/APP.java | <filename>java/poo/ClasesRelaciones/src/main/java/co/edu/sena/clasesrelaciones/asociacion/ejemplo1/APP.java
package co.edu.sena.clasesrelaciones.asociacion.ejemplo1;
/**
* Created by Enrique on 13/03/2017.
*/
public class APP {
public static void main(String[] args) {
Caballo c1 = new Caballo(new Ojo("ro... |
paralin/go-rift-api | models/lol_lobby_lobby_bot_champion.go | <reponame>paralin/go-rift-api
// 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 (
"strconv"
strfmt "github.com/go-openapi/strfmt"
"github.com/go-openapi/errors"
... |
suyanlong/chain33-sdk-java | src/main/java/cn/chain33/javasdk/model/rpcresult/TxResult.java | <filename>src/main/java/cn/chain33/javasdk/model/rpcresult/TxResult.java
package cn.chain33.javasdk.model.rpcresult;
public class TxResult {
private String hash;
private Long height;
private Integer index;
public String getHash() {
return hash;
}
public void setHash(String hash) {
... |
Rexogamer/DiscordBot | src/main/java/core/commands/MbizThisYearCommand.java | <filename>src/main/java/core/commands/MbizThisYearCommand.java
package core.commands;
import core.parsers.ChartSmartYearParser;
import core.parsers.ChartableParser;
import core.parsers.params.ChartYearParameters;
import dao.ChuuService;
import java.util.Arrays;
import java.util.List;
public class MbizThisYearCommand... |
MrAwesomeRocks/caelus-cml | src/libraries/edgeMesh/edgeFormats/nas/NASedgeFormat.cpp | /*---------------------------------------------------------------------------*\
Copyright (C) 2011-2015 OpenFOAM Foundation
-------------------------------------------------------------------------------
License
This file is part of CAELUS.
CAELUS is free software: you can redistribute it and/or modify it
... |
bertux/driftctl | pkg/resource/aws/aws_sqs_queue_policy_test.go | package aws_test
import (
"testing"
"time"
"github.com/aws/aws-sdk-go/service/sqs"
"github.com/cloudskiff/driftctl/test/acceptance/awsutils"
"github.com/sirupsen/logrus"
"github.com/cloudskiff/driftctl/test/acceptance"
)
func TestAcc_AwsSqsQueuePolicy(t *testing.T) {
acceptance.Run(t, acceptance.AccTestCase{... |
sanksons/reflorest | src/common/logger/writers/stdoutwriter/impl.go | <filename>src/common/logger/writers/stdoutwriter/impl.go
package stdoutwriter
import (
"fmt"
"github.com/sanksons/reflorest/src/common/logger/formatter"
"github.com/sanksons/reflorest/src/common/logger/message"
)
//FileWriter is a file logger structure
type StdoutWriter struct {
// formatter
myFormat formatter.... |
jmasterx/StemwaterSpades | Spades Game/Game/Particle/ParticleSystem.hpp | #ifndef PARTICLE_SYSTEM_HPP
#define PARTICLE_SYSTEM_HPP
#include "Game/Particle/Particle.hpp"
#include "Game/Utility/Vec2.hpp"
#include "Game/Resource/Sprite.hpp"
#include "Game/Engine/GraphicsContext.hpp"
#include <Agui/Agui.hpp>
#include <stdlib.h>
#include <list>
#include <vector>
namespace cge
{
class ParticleSyst... |
jasonlong/classroom | spec/models/group_assignment_invitation_spec.rb | <filename>spec/models/group_assignment_invitation_spec.rb
require 'rails_helper'
RSpec.describe GroupAssignmentInvitation, type: :model do
it { is_expected.to have_one(:grouping).through(:group_assignment) }
it { is_expected.to have_one(:organization).through(:group_assignment) }
it { is_expected.to have_ma... |
naeramarth7/joynr | java/messaging/bounceproxy/bounceproxy-controller-persistence/ehcache/src/main/java/io/joynr/messaging/bounceproxy/controller/directory/ehcache/BounceProxyEhcacheAdapter.java | /*
* #%L
* %%
* Copyright (C) 2011 - 2017 BMW Car IT 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... |
tharindusathis/sourcecodes-of-CodeReadingTheOpenSourcePerspective | XFree86-3.3/xc/programs/Xserver/hw/xfree86/accel/agx/Bt481.h | /* $XFree86: xc/programs/Xserver/hw/xfree86/accel/agx/Bt481.h,v 3.4 1996/12/23 06:32:19 dawes Exp $ */
/*
* Copyright 1993 by <NAME> <<EMAIL>>
* Copyright 1994 by <NAME> <<EMAIL>>
*
* Permission to use, copy, modify, distribute, and sell this software and its
* documentation for any purpose is hereby granted with... |
agramonte/corona | librtt/Display/Rtt_PlatformBitmapTexture.h | <reponame>agramonte/corona<gh_stars>1000+
//////////////////////////////////////////////////////////////////////////////
//
// This file is part of the Corona game engine.
// For overview and more information on licensing please refer to README.md
// Home page: https://github.com/coronalabs/corona
// Contact: <EMAIL>
... |
steva44/OpenSees | SRC/element/PFEMElement/TetMeshGenerator.h | <reponame>steva44/OpenSees<filename>SRC/element/PFEMElement/TetMeshGenerator.h
/* ****************************************************************** **
** OpenSees - Open System for Earthquake Engineering Simulation **
** Pacific Earthquake Engineering Research Center **
** ... |
shineTeam7/tank | develop/server/project/base/src/main/java/com/home/base/constlist/generate/GTriggerFunctionType.java | package com.home.base.constlist.generate;
/** (generated by shine) */
public class GTriggerFunctionType
{
/** 起始 */
public static final int off=1000;
/** 计数 */
public static final int count=1001;
public static final int GTestFunc=1000;
}
|
rokkish/growi | packages/app/src/migrations/20191126173016-adjust-pages-path.js | <reponame>rokkish/growi
import mongoose from 'mongoose';
import { pathUtils, getMongoUri, mongoOptions } from '@growi/core';
import loggerFactory from '~/utils/logger';
const logger = loggerFactory('growi:migrate:adjust-pages-path');
module.exports = {
async up(db) {
logger.info('Apply migration');
mongo... |
wiltonlazary/snappydata | cluster/src/test/scala/org/apache/spark/sql/kafka010/SnappyStructuredKafkaSuite.scala | <gh_stars>1000+
/*
* Copyright (c) 2017-2019 TIBCO Software Inc. All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you
* may not use this file except in compliance with the License. You
* may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
... |
zwx14700/pravega | client/src/test/java/io/pravega/client/stream/notifications/CustomNotifier.java | <gh_stars>1-10
/**
* Copyright (c) Dell Inc., or its subsidiaries. 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... |
ppartarr/azure-sdk-for-java | sdk/resourcemanager/azure-resourcemanager-appplatform/src/main/java/com/azure/resourcemanager/appplatform/models/TestKeys.java | // Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// Code generated by Microsoft (R) AutoRest Code Generator.
package com.azure.resourcemanager.appplatform.models;
import com.azure.core.annotation.Fluent;
import com.azure.core.util.logging.ClientLogger;
import com.fasterx... |
InCadence/coalesce | src/Coalesce.Services/Search/service-data/src/test/java/com/incadencecorp/coalesce/services/search/service/rest/TemplateDataControllerTest.java | <filename>src/Coalesce.Services/Search/service-data/src/test/java/com/incadencecorp/coalesce/services/search/service/rest/TemplateDataControllerTest.java<gh_stars>1-10
/*-----------------------------------------------------------------------------'
Copyright 2017 - InCadence Strategic Solutions Inc., All Rights Reserv... |
AY2122-CS2103-W17-1/tp | src/test/java/seedu/contax/testutil/TypicalTags.java | package seedu.contax.testutil;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import seedu.contax.model.AddressBook;
import seedu.contax.model.tag.Tag;
public class TypicalTags {
public static final Tag CLIENTS = new TagBuilder().build();
public static final Tag FAMILY = new TagB... |
e-neko/react-redux-grid | src/reducers/components/plugins/pager.js | import { OrderedMap } from 'immutable';
import {
PAGE_LOCAL,
PAGE_REMOTE
} from '../../../constants/ActionTypes';
import handleActions from './../../../util/handleActions';
import {
pageLocal,
pageRemote
} from './../../actionHelpers/plugins/pager';
const initialState = new OrderedMap();
export def... |
IronTooch-Forks/guacamole-website | doc/1.4.0/libguac/search/variables_2.js | var searchData=
[
['channels_667',['channels',['../structguac__audio__stream.html#af9d1ad90194e24c2967e2f9f18de0ad6',1,'guac_audio_stream']]],
['client_668',['client',['../structguac__audio__stream.html#a1771fa5ff88b8f5d4ca4cd5e77a1ffba',1,'guac_audio_stream::client()'],['../structguac__user.html#a5e296149a26932dfe... |
benrayfield/occamsworkspace | selfContained/data/code/immutable/util/BlobUtil.java | <filename>selfContained/data/code/immutable/util/BlobUtil.java
package immutable.util;
public class BlobUtil{
public static void arraycopy(Blob from, int fromIndex, float[] to, int toIndex, int len){
for(int i=0; i<len; i++) to[toIndex+i] = from.f(fromIndex+i);
}
public static void arraycopy(Blob from, int fr... |
zhongwood/open-capacity-platform | business-center/user-center/src/main/java/com/open/capacity/user/service/SysMenuService.java | <gh_stars>10-100
package com.open.capacity.user.service;
import java.util.List;
import java.util.Set;
import com.open.capacity.model.system.SysMenu;
public interface SysMenuService {
/**
* 添加菜单
* @param menu
*/
void save(SysMenu menu);
/**
* 更新菜单
* @param menu
*/
void update(SysMenu menu);
/**
... |
vinnyfs89/vota-cultura | webapp/src/modules/conta/store/actions.js | <filename>webapp/src/modules/conta/store/actions.js
import { remove, includes } from 'lodash';
import * as usuarioService from '../service/usuario';
import * as types from './types';
import { obterInformacoesJWT } from '../../shared/service/helpers/jwt';
/* eslint-disable import/prefer-default-export */
export const ... |
NillerMedDild/MiningGadgets | src/main/java/com/direwolf20/mininggadgets/client/MiningGadgetsJEI.java | //package com.direwolf20.mininggadgets.client;
//
//import com.direwolf20.mininggadgets.client.screens.ModificationTableScreen;
//import com.direwolf20.mininggadgets.common.Config;
//import com.direwolf20.mininggadgets.common.MiningGadgets;
//import com.direwolf20.mininggadgets.common.items.MiningGadget;
//import com.d... |
andersongns/vutter-api | src/utils/helpers/hash-bcrypt-generator.js | <reponame>andersongns/vutter-api<filename>src/utils/helpers/hash-bcrypt-generator.js
const bcrypt = require('bcrypt')
const { MissingDependenceError, MissingParamError } = require('../errors')
module.exports = class HashBcryptGenerator {
constructor (salt) {
if (!salt) throw new MissingDependenceError('salt')
... |
JakeB1998/Aveona-Utility-Library | src/main/org/botka/utility/api/time/TimeConstants.java | /*
* File name: TimeConstants.java
*
* Programmer : <NAME>
* ULID: JMBOTKA
*
* Date: May 28, 2020
*
* Out Of Class Personal Program
*/
package main.org.botka.utility.api.time;
import java.time.Month;
/**
* <insert class description here>
*
* @author <NAME>
*
*/
public class TimeConstants {
public stat... |
aidan-mundy-forks/docker-cli | cli/command/trust/helpers.go | package trust
import (
"strings"
"github.com/docker/cli/cli/trust"
"github.com/theupdateframework/notary/client"
"github.com/theupdateframework/notary/tuf/data"
)
const releasedRoleName = "Repo Admin"
const releasesRoleTUFName = "targets/releases"
// isReleasedTarget checks if a role name is "released":
// eith... |
atul-vyshnav/2021_IBM_Code_Challenge_StockIT | src/StockIT-v2-release_source_from_JADX/sources/expo/modules/updates/loader/EmbeddedLoader.java | <filename>src/StockIT-v2-release_source_from_JADX/sources/expo/modules/updates/loader/EmbeddedLoader.java
package expo.modules.updates.loader;
import android.content.Context;
import expo.modules.updates.UpdatesConfiguration;
import expo.modules.updates.UpdatesUtils;
import expo.modules.updates.manifest.Manifest;
impor... |
a4x4kiwi/Exo-CC | extensions/cce/src/main/jni/lib_ccx/asf_functions.c | #include "lib_ccx.h"
#include "ccx_common_option.h"
#include "asf_constants.h"
#include "activity.h"
#include "file_buffer.h"
// Indicate first / subsequent calls to asf_get_more_data()
int firstcall;
asf_data asf_data_container;
// For ASF parsing
// 0, 1, 2, 3 means none, BYTE, WORD, DWORD
#define ASF_TypeLength(A... |
ww362034710/Gannt | gannt/lib/Scheduler/view/EventEditor.js | <filename>gannt/lib/Scheduler/view/EventEditor.js
import Popup from '../../Core/widget/Popup.js';
/**
* @module Scheduler/view/EventEditor
*/
/**
* Provided event editor dialog.
*
* @extends Core/widget/Popup
* @private
*/
export default class EventEditor extends Popup {
// Factoryable type name
static... |
tradingsecret/beam_wallet | websocket/reactor.h | <filename>websocket/reactor.h
// Copyright 2018-2020 The Beam Team
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless require... |
megakode/MegaTinyEngine | MegaTinyEngine/Resources/JSONSerialization.h | //
// Created by <NAME> on 24/06/2020.
//
#include "Vendor/json.hpp"
#include "ResourceFile.h"
#ifndef SDLTEST_JSONSERIALIZATION_H
#define SDLTEST_JSONSERIALIZATION_H
using nlohmann::json;
namespace Engine
{
/// Sprite Frame
void to_json(json& j, const SpriteFrame& frame)
{
j = json{{"x", frame.... |
vvd170501/ClickHouse | src/Functions/FunctionsStringSimilarity.cpp | <reponame>vvd170501/ClickHouse
#include <Functions/FunctionsStringSimilarity.h>
#include <Functions/FunctionFactory.h>
#include <Functions/FunctionsHashing.h>
#include <Common/HashTable/ClearableHashMap.h>
#include <Common/HashTable/Hash.h>
#include <Common/UTF8Helpers.h>
#include <Core/Defines.h>
#include <base/unal... |
VijayS02/Random-Programming-Items | PythonFiles/SUWSS/Java/jexcelapi/src/jxl/write/WritableCell.java | /*********************************************************************
*
* Copyright (C) 2002 <NAME>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the Lic... |
cclauss/xmodaler | xmodaler/optim/rmsprop.py | <gh_stars>100-1000
# Copyright 2021 JD.com, Inc., JD AI
"""
@author: <NAME>
@contact: <EMAIL>
"""
import torch
from xmodaler.config import configurable
from .build import SOLVER_REGISTRY
@SOLVER_REGISTRY.register()
class RMSprop(torch.optim.RMSprop):
@configurable
def __init__(
self,
*,
... |
xiao125/o2oMaven | src/main/java/com/imooc/o2o/dao/ShopDao.java | <reponame>xiao125/o2oMaven
package com.imooc.o2o.dao;
import com.imooc.o2o.entity.Shop;
import org.apache.ibatis.annotations.Param;
import java.util.List;
/**
* Created by Administrator on 2017/11/27.
*/
public interface ShopDao {
/**
* 分页查询店铺,可输入的条件有:店铺名(模糊),店铺状态,店铺类别,区域Id,owner
*
* @param sho... |
benpolinsky/bp_custom_fields | app/helpers/bp_custom_fields/form_helper.rb | # Add a FormHelper to fetch and display our custom fields
# There's the possibility there's too much going on in the fetch dept.
# But then I'd have to ask the end user to setup something in controllers (probably)
#
# usage:
#
# form_for(@object) do |f|
# f.bp_custom_fields
# end
module BpCustomFields
module Fo... |
Nibor007/Proyectos | src/main/java/cl/bancochile/portal/common/recaudacion/converter/DetalleContratoRes.java | <reponame>Nibor007/Proyectos
package cl.bancochile.portal.common.recaudacion.converter;
import cl.bancochile.osb.bch.neg.pagos.cobranzaexterna.consultarcobranzasexternasrs.mpi.Canal;
import cl.bancochile.osb.bch.neg.pagos.cobranzaexterna.consultarcobranzasexternasrs.mpi.ConsultarCobranzasExternasRs;
import cl.bancochi... |
DevLabsDigital/consultoria_gem | app/javascript/components/app/mock/etapasDashboard.js | const etapasDashboard = [
{
etapa: 'Apresentação do Projeto',
status: 'ok',
},
{
etapa: 'Definição dos objetivos macro do projeto',
status: 'pendente',
},
{
etapa: 'Definir equipe do projeto - LÍDER DO PROJETO',
status: 'pendente',
},
{
... |
Repast/repast.simphony | repast.simphony.data/src/repast/simphony/data2/AggregateDataSource.java | <reponame>Repast/repast.simphony
package repast.simphony.data2;
/**
* Interface for classes that can function as the source of aggregate data to be
* logged or charted.
*
* @author <NAME>
*/
public interface AggregateDataSource extends DataSource {
/**
* Gets the data using the specified iterable.
*
... |
albertdow/zinv-analysis | drawing/dist_facet.py | import numpy as np
import pandas as pd
import matplotlib.pyplot as plt
import seaborn as sns
#sns.set(style='ticks')
def dist_facet(df, bins, filepath, cfg):
plt.rcParams['xtick.top'] = False
plt.rcParams['ytick.right'] = False
with sns.plotting_context(context='paper', font_scale=1.8):
variations... |
iam-Legend/Project-Assembly | Source/FactoryGame/FGNobeliskDetonator.cpp | <gh_stars>0
// This file has been automatically generated by the Unreal Header Implementation tool
#include "FGNobeliskDetonator.h"
AFGNobeliskDetonator::AFGNobeliskDetonator(){ }
void AFGNobeliskDetonator::PostLoadGame_Implementation( int32 saveVersion, int32 gameVersion){ }
bool AFGNobeliskDetonator::ShouldSaveStat... |
sunxuia/leetcode-solution-java | src/main/java/q200/Q188_BestTimeToBuyAndSellStockIV.java | <filename>src/main/java/q200/Q188_BestTimeToBuyAndSellStockIV.java
package q200;
import java.util.Arrays;
import org.junit.runner.RunWith;
import q150.Q122_BestTimeToBuyAndSellStockII;
import q150.Q123_BestTimeToBuyAndSellStockIII;
import q350.Q309_BestTimeToBuyAndSellStockWithCooldown;
import util.runner.Answer;
impo... |
SimiaCryptus/mindseye-core | src/main/java/com/simiacryptus/mindseye/opt/orient/ValidatingOrientationWrapper.java | /*
* Copyright (c) 2019 by <NAME>.
*
* The author licenses this file 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 requ... |
whble/trunk | target/linux/ar71xx/files/arch/mips/ath79/mach-wnr2200.c | /*
* NETGEAR WNR2200 board support
*
* 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 version 2 as published
* by the Free Software Foundation.
*/
#include <linux/gpio.h>
#incl... |
mcraken/spring-scaffy | src/main/java/com/scaffy/weave/PreAuthorizeBuilder.java | package com.scaffy.weave;
import org.springframework.security.access.prepost.PreAuthorize;
import javassist.bytecode.ConstPool;
import javassist.bytecode.annotation.Annotation;
public class PreAuthorizeBuilder extends AnnotationBuilder{
private String priv;
public PreAuthorizeBuilder(String priv) {
super(Pr... |
edellano/Adenita-SAMSON-Edition-Win- | AdenitaCoreSE/source/SEAdenitaVisualModelProperties.cpp | <gh_stars>1-10
#include "SEAdenitaVisualModelProperties.hpp"
#include "SEAdenitaVisualModel.hpp"
#include "SAMSON.hpp"
#include "SBGWindow.hpp"
SEAdenitaVisualModelProperties::SEAdenitaVisualModelProperties() {
visualModel = 0;
ui.setupUi( this );
observer = new Observer(this);
ui.gboHighlight->hide();
}
SEAdeni... |
winksaville/sel4-min-sel4 | kernel/include/kernel/boot.h | /*
* Copyright 2014, General Dynamics C4 Systems
*
* This software may be distributed and modified according to the terms of
* the GNU General Public License version 2. Note that NO WARRANTY is provided.
* See "LICENSE_GPLv2.txt" for details.
*
* @TAG(GD_GPL)
*/
#ifndef __KERNEL_BOOT_H
#define __KERNEL_BOOT_H
... |
fzk466569/flask_fishbook | app/__init__.py | <reponame>fzk466569/flask_fishbook
#!/usr/bin/python
# -*- coding: utf-8 -*-
# Author: fzk
# @Time 10:53
from flask import Flask
from flask_login import LoginManager
from app.models.base import db
login_manager = LoginManager()
def create_app():
app = Flask(__name__)
app.config.from_object('app.config')
... |
cjd8363/Global-Illum | src/netpbm/10.27/netpbm-10.27/urt/rle_global.c | <reponame>cjd8363/Global-Illum<filename>src/netpbm/10.27/netpbm-10.27/urt/rle_global.c<gh_stars>1-10
/*
* This software is copyrighted as noted below. It may be freely copied,
* modified, and redistributed, provided that the copyright notice is
* preserved on all copies.
*
* There is no warranty or other guaran... |
honeytavis/cpp | Thinking_in_Cpp/I/C03/function_pointer.cc | #include <iostream>
void func() {
std::cout << "func() called..." << '\n';
}
int main()
{
void (*fp)();
fp = func;
(*fp)();
void (*fp2)() = func;
(*fp2)();
return 0;
}
|
JustDoom/riotspigot | riotspigot-library/src/main/java/de/dytanic/log/DytanicAsyncPrintStream.java | /*
* Copyright (c) <NAME> 2017
*/
package de.dytanic.log;
import java.io.OutputStream;
import java.io.PrintStream;
import java.io.UnsupportedEncodingException;
import java.nio.charset.StandardCharsets;
import java.util.concurrent.BlockingQueue;
import java.util.concurrent.LinkedBlockingQueue;
/**
* Created by Tar... |
urvashijain18/Bet-On-Better | Bet_On_Better/src/UserInterface/UserLogin.java | /*
* 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 UserInterface;
import Business.EndUser.AccountDetails;
import UserInterface.UserRole.CreateNewUser;
import Business.Advertisin... |
jskirst/edward | db/migrate/20171026162501_add_workflow_id_to_options.rb | <filename>db/migrate/20171026162501_add_workflow_id_to_options.rb
class AddWorkflowIdToOptions < ActiveRecord::Migration[5.1]
def change
add_column :options, :workflow_id, :integer
add_column :options, :token, :string
end
end
|
rita0222/FK | CLI/FK_CLI/cpp/DList_CLI.cpp | <filename>CLI/FK_CLI/cpp/DList_CLI.cpp
#include "DList_CLI.h"
namespace FK_CLI {
::FK::fk_DisplayLink * fk_DisplayLink::GetP(void)
{
return (::FK::fk_DisplayLink *)(pBase);
}
void fk_DisplayLink::CameraUpdate(void)
{
_camera = gcnew fk_Model(const_cast<::FK::fk_Model *>(GetP()->getCamera()));
... |
kokosing/hue | desktop/core/ext-py/docutils-0.14/test/functional/tests/standalone_rst_s5_html_1.py | exec(open('functional/tests/_standalone_rst_defaults.py').read())
# Source and destination file names:
test_source = 'standalone_rst_s5_html.txt'
test_destination = 'standalone_rst_s5_html_1.html'
# Keyword parameters passed to publish_file:
writer_name = 's5_html'
# Settings:
settings_overrides['theme'] = 'small-bl... |
FENIX-Platform/fenix-commons | fenix-commons-search/src/main/java/org/fao/fenix/commons/msd/dto/templates/export/metadata/SeGridSpatialRepresentation.java | package org.fao.fenix.commons.msd.dto.templates.export.metadata;
import com.fasterxml.jackson.annotation.JsonProperty;
import org.fao.fenix.commons.msd.dto.templates.ResponseHandler;
import org.fao.fenix.commons.msd.dto.type.CellGeometry;
import org.fao.fenix.commons.msd.dto.type.CellOfOrigin;
import org.fao.fenix.com... |
kyowill/derby-10.0.2.1 | java/engine/org/apache/derby/iapi/error/PublicAPI.java | /*
Derby - Class org.apache.derby.iapi.error.PublicAPI
Copyright 1999, 2004 The Apache Software Foundation or its licensors, as applicable.
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 Lice... |
logginghub/core | logginghub-client/src/main/java/com/logginghub/logging/LogEventGenerator.java | <gh_stars>0
package com.logginghub.logging;
import com.logginghub.logging.interfaces.LogEventSource;
import com.logginghub.logging.listeners.LogEventListener;
/**
* Interface for objects that receive log events and may generate new events as
* result. The events are fired back through the listener added,... |
abhiisheek/react-chatbot | src/docs/examples/ChatMsg/PlainTextChatMsg.js | import React from 'react';
import ChatMsg from 'react-chatbot/ChatMsg';
import PlainText from 'react-chatbot/PlainText';
import TextWithLink from 'react-chatbot/TextWithLink';
import types from 'react-chatbot/types';
import styles from './ChatMsg.css';
const chatMsgTypesMap = {
[types.TEXT]: PlainText,
[types.TE... |
406345/leetcode | 611_triangleNumber/main.cpp | #include "stdio.h"
#include "vector"
#include "unordered_map"
#include "set"
#include "algorithm"
using namespace std;
class Solution
{
public:
int triangleNumber(vector<int> &nums)
{
sort(nums.begin(), nums.end());
reverse(nums.begin(), nums.end());
int size = nums.size();
int... |
sirghiny/Real-Estate-Manager | api/views/auth.py | <filename>api/views/auth.py
"""Authorization functionality."""
from flask import request
from flask_restful import Resource
from api.helpers.auth import create_token
from api.helpers.general import digest
from api.helpers.validation import validate_json
from api.models import User
# pylint:disable=no-self-use
clas... |
bkaid/project-euler | problems/problem-0010/index.js | 'use strict';
const problem10 = require('./problem-0010');
let n = 2000000;
module.exports = {
description: `Find the sum of all the primes below ${n}.`,
result: () => problem10.sumOfPrimes(n)
};
|
dkBrazz/zserio | test/language/functions/java/functions/structure_parent_child_value/StructureParentChildValueTest.java | package functions.structure_parent_child_value;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertTrue;
import java.io.IOException;
import java.util.Arrays;
import org.junit.Test;
import zserio.runtime.io.ByteArrayBitStreamReader;
import zserio.runtime.io.ByteArrayBitStreamWriter;
p... |
banbao990/Java | Learning/Thinking_in_Java_4th_Edition/Chapter_17/TestCollections.java | <gh_stars>1-10
/**
* @author banbao
* @comment 修改自示例代码
*/
import java.util.Collections;
import java.util.List;
import java.util.ArrayList;
public class TestCollections {
public static void main(String...args) {
List<TestCollections> list =
new ArrayList<TestCollections>(
Co... |
msmygit/nosqlbench | nb/src/test/resources/scripts/async/cocycledelay_bursty.js | /*
*
* Copyright 2016 jshook
* 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 ... |
mcx/opensim-core | OpenSim/Common/APDMDataReader.cpp | #include <fstream>
#include "Simbody.h"
#include "Exception.h"
#include "FileAdapter.h"
#include "TimeSeriesTable.h"
#include "APDMDataReader.h"
namespace OpenSim {
const std::vector<std::string> APDMDataReader::acceleration_labels{
"/Acceleration/X", "/Acceleration/Y", "/Acceleration/Z"
};
const std::vector... |
danjung/sparsemapcontent | src/test/java/org/sakaiproject/nakamura/lite/soak/AbstractScalingClient.java | <reponame>danjung/sparsemapcontent<gh_stars>1-10
/*
* Licensed to the Sakai Foundation (SF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The SF licenses this file
* to you under the Apache License, V... |
elliotwms/benthos | lib/input/package.go | <filename>lib/input/package.go
// Package input defines consumers for aggregating data from a variety of
// sources. All consumer types must implement interface input.Type.
//
// If the source of an input consumer supports acknowledgements then the
// implementation of the input will wait for each message to reach a pe... |
cserverpaasshow/smart-OA | src/main/flow/cn/com/smart/flow/helper/FlowFormUploadFileHelper.java | package cn.com.smart.flow.helper;
import java.util.Map;
import org.springframework.web.multipart.MultipartFile;
import org.springframework.web.multipart.MultipartHttpServletRequest;
import cn.com.smart.bean.SmartResponse;
import cn.com.smart.constant.IConstant;
import cn.com.smart.flow.bean.SubmitFormData;
import cn... |
sbnair/PolkaJS | node_modules/dmg-license/lib/index.js | "use strict";
Object.defineProperty(exports, "__esModule", { value: true });
const Plist = require("plist");
const assembleLicenses_1 = require("./assembleLicenses");
const BodySpec_1 = require("./BodySpec");
exports.BodySpec = BodySpec_1.default;
const Context_1 = require("./Context");
const Labels_1 = require("./Labe... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.