text stringlengths 27 775k |
|---|
@file:JvmName("MapboxConstants")
package com.mapbox.maps
import java.util.*
/**
* Name of the database file.
*/
const val DATABASE_NAME = "mbx.db"
/**
* Default Locale for data processing (ex: String.toLowerCase(com.mapbox.maps.getMAPBOX_LOCALE, "foo"))
*/
val MAPBOX_LOCALE: Locale = Locale.US
/**
* Resource ... |
# frozen_string_literal: true
require 'support/models/authorizy_cop'
require 'support/models/empty_cop'
require 'support/controllers/dummy_controller'
RSpec.describe DummyController, '#authorizy', type: :controller do
let!(:user) { User.new }
context 'when cop responds to the controller name' do
context 'whe... |
#include <GameState.hpp>
GameState::GameState(sf::RenderWindow* window)
: State(window) {
}
GameState::~GameState() {
delete m_bg[0];
delete m_bg[1];
delete im_bg;
}
void GameState::Init() {
player = new Player();
player->Init(sf::Vector2f(200.0f / 2.0f, 150.0f / 2.0f), 50.0f);
im_bg = new sf::Text... |
/*
Write a program to reverse of an integer number.
*/
#include <stdio.h>
int main(void) {
int n, rev = 0, d;
printf("Enter any integer to find it\'s reverse: ");
scanf("%d", &n);
while(n != 0) {
d = n % 10;
rev = rev * 10 + d;
n = n / 10;
}
printf("\nThe reverse of is %d", rev);
return 0;... |
package io.connectedhealth_idaas.eventbuilder.dataobjects.general;
import org.apache.commons.lang3.builder.ReflectionToStringBuilder;
public class NextofKin {
private String nextofkinSetId;
private String nextofkinNumber;
private String nextofkinName;
private String nextofkinSurName;
private Stri... |
;/*!
; @file
;
; @ingroup fapi
;
; @brief DosGetPID DOS wrapper
;
; (c) osFree Project 2018, <http://www.osFree.org>
; for licence see licence.txt in root directory, or project website
;
; This is Family API implementation for DOS, used with BIND tools
; to link required API
;
; @author Yuri Prokushev (... |
const viewport = {
data() {
return {
clientHeight: 0
}
},
created() {
this.clientHeight = document.documentElement.clientHeight || document.body.clientHeight
}
}
export default viewport
|
namespace AirlineHierarchy.TransportAircrafts.Airplanes.CargoAirplanes.Models
{
public class AirbusBelugaXL : CargoAirplane
{
public override string Model => "BelugaXL";
public override string Manufacturer => "Airbus";
public override int FlightRange => 4000;
public override ... |
using SUP_G6.DataTypes;
using SUP_G6.Interface;
using System;
using System.Collections.Generic;
using System.Text;
namespace SUP_G6.Models
{
public class GameResult : IGameResult
{
public int GameId { get; set; }
public int PlayerId { get; set; }
public string PlayerName { get; set; ... |
#!/usr/bin/env bash
# This script can be used to build the Docker images manually (outside of CI)
set -e
GIT_TAG=$1
MAIN_TAG=$2
SECOND_TAG=$3
THIRD_TAG=$4
if [[ -z "$MAIN_TAG" || -z "$GIT_TAG" ]]
then
echo "Usage:"
echo " build.sh git-tag-or-hash tag [second-tag] [third-tag]"
echo "Example:"
echo "... |
import VirtualEngine, {
VirtualRegistry as VirtualRegistryClass,
RequireResolver,
FileResolve,
EngineOptions,
RegistryOptions
} from './VirtualEngine';
import { shim } from './helpers';
import DevpackMiddleware from './DevpackMiddleware';
const devpack = DevpackMiddleware;
/**
* Instantiates the Virtual En... |
# Joplin Server Changelog
## [server-v1.7.2](https://github.com/laurent22/joplin/releases/tag/server-v1.7.4) - 2021-01-24T19:11:10Z
- Fixed: Fixed password hashing when changing password
- Improved: Many other internal changes for increased reliability
|
"""
# AccelerometerCalibrationPlots.jl
Debug plots for
[AccelerometerCalibration.jl](https://github.com/notinaboat/AccelerometerCalibration.jl)
"""
module AccelerometerCalibrationPlots
using AccelerometerCalibration
using Plots
offset_series = []
scale_series = []
rotation_series = []
function reset()
empty!(of... |
<?php
namespace Visitors;
use Illuminate\Database\Eloquent\Model;
class Visitors extends Model
{
//Modelo de la tabla y datos que recibe el arreglo
protected $table = 'visitors';
protected $fillable = array('nombre', 'apellidos', 'foto', 'motivo');
}
|
package com.yc.common.mongodb.vo;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.ToString;
import java.io.Serializable;
import java.util.List;
/**
* @description:
* @author: youcong
* @time: 2021/12/3 19:55
*/
@Data
@ToString
@NoArgsConstructor
public class PageModel implements Serializable {... |
use FindBin;
sub { [ 200, [ "Content-Type", "text/plain" ], [ "$FindBin::Bin" ] ] };
|
import { api, LightningElement } from 'lwc';
export default class Button extends LightningElement {
static delegatesFocus = true;
@api
focus() {
this.template.querySelector('button').focus();
}
}
|
package com.example.cs4518_project
import retrofit2.Call
import retrofit2.http.GET
import retrofit2.http.Query
interface RetrofitInterface {
@GET("weather")
fun getData(
@Query("lat") lat: Double,
@Query("lon") lon: Double,
@Query("appid") appid: String
): Call<WeatherData>
} |
/* $NoKeywords: $ */
/*
//
// Copyright (c) 1993-2012 Robert McNeel & Associates. All rights reserved.
// OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert
// McNeel & Associates.
//
// THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY.
// ALL IMPLIED WARRANTIES OF FITNESS FOR A... |
/**
* @file
*
* @brief
*
* @copyright BSD License (see doc/LICENSE.md or http://www.libelektra.org)
*/
#ifndef VISITOR_H
#define VISITOR_H
class TreeItem;
class TreeModel;
/**
* @brief The abstract Visitor class to support the visitor pattern.
*/
class Visitor
{
public:
/**
* @brief The abstract method ... |
#!/usr/bin/env python3
# Copyright (c) 2017 The MagnaChain Core developers
# Distributed under the MIT software license, see the accompanying
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
"""
测试:
赎回挖矿币
//赎回挖矿币, 步骤
// 1).侧链提起赎回请求.(侧链先销毁挖矿币,防止继续挖矿)
// 2).主链收到,创造新的交易,抵押币作为输入,赎回到正常地址,需要指定来自那个侧链请求
//... |
import {
Controller,
UseGuards,
Post,
Request,
Get,
HttpCode,
UseInterceptors,
ClassSerializerInterceptor
} from '@nestjs/common';
import { ApiBody, ApiBearerAuth, ApiHeader, ApiTags, ApiResponse } from '@nestjs/swagger';
import { AuthService } from './auth.service';
import { JwtAuthGuard } from './gua... |
from blackbox.handlers.databases._base import BlackboxDatabase
from blackbox.utils import run_command
from blackbox.utils.logger import log
class MongoDB(BlackboxDatabase):
"""
A Database handler that will do a mongodump for MongoDB, backing up all documents.
This will use mongodump with --gzip and --arc... |
package com.trigonated.gamecollection.di
import com.trigonated.gamecollection.api.rawg.RawgService
import dagger.Module
import dagger.Provides
import dagger.hilt.InstallIn
import dagger.hilt.components.SingletonComponent
import javax.inject.Singleton
@InstallIn(SingletonComponent::class)
@Module
class RawgApiModule {... |
using System;
namespace ZKWebStandard.Ioc
{
/// <summary>
/// Singleton reuse attribute<br/>
/// A convenient attribute from ReuseAttribute<br/>
/// 标记单例的属性<br/>
/// 继承了ReuseAttribute的便捷属性<br/>
/// </summary>
/// <seealso cref="IContainer"/>
/// <seealso cref="Container"/>
... |
$LOAD_PATH.unshift File.expand_path("../../lib", __FILE__)
require 'data-sink-client'
require 'webmock/rspec'
WebMock.disable_net_connect!
def gzip(body)
wio = StringIO.new("w")
w_gz = Zlib::GzipWriter.new(wio)
w_gz.write(body)
w_gz.close
wio.string
end
|
require 'spec_helper'
feature 'Sign Up' do
context 'with valid data' do
scenario 'create a new user' do
visit spree.signup_path
fill_in 'Email', with: 'email@person.com'
fill_in 'Password', with: 'password'
fill_in 'Password Confirmation', with: 'password'
click_button 'Create'
... |
/*
Copyright 2011-2012 Stefano Chizzolini. http://www.pdfclown.org
Contributors:
* Stefano Chizzolini (original code developer, http://www.stefanochizzolini.it)
This file should be part of the source code distribution of "PDF Clown library" (the
Program): see the accompanying README files for more info.
... |
import java.util.Scanner;
import warehouses.Cache;
import simulated.Simulator;
public class Chiral {
production.Exporter righ;
production.Exporter fh;
production.Exporter r;
java.lang.String q;
public static final double quantify = 0.6181309728629134;
public static synchronized void main(String[] align) {... |
const errorMsgGenerator = require('../../../utils/errorMessageGenerator')
const brandServices = require('../../brands/services/index-brand.service')
const imageServices = require('../../images/image-services')
const categoryServices = require('../../categories/services/index-category.service')
const productServices = r... |
// This file auto generated by plugin for ida pro. Generated code only for x64. Please, dont change manually
#pragma once
#include <common/common.h>
#include <CIndexList.hpp>
START_ATF_NAMESPACE
namespace Info
{
using CIndexListctor_CIndexList2_ptr = void (WINAPIV*)(struct CIndexList*);
... |
<?php
declare(strict_types=1);
namespace Jellyfish\LogMonolog;
use Codeception\Test\Unit;
use Jellyfish\Config\ConfigFacadeInterface;
use Jellyfish\Log\LogConstants;
use Monolog\Logger;
class LogMonologFactoryTest extends Unit
{
/**
* @var \Jellyfish\Config\ConfigFacadeInterface|\PHPUnit\Framework\MockObje... |
module ActsAsTaggableOn
class Tagging < ::ActiveRecord::Base #:nodoc:
attr_accessible :tag,
:tag_id,
:context,
:taggable,
:taggable_type,
:taggable_id,
:tagger,
:tagger_type,... |
#!/bin/bash
# Copyright 2021 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to ... |
using Microsoft.Extensions.DependencyInjection;
namespace Phema.Random
{
public static class RandomExtensions
{
public static IServiceCollection AddRandom<TRandom>(this IServiceCollection services)
where TRandom : class, IRandom
{
return services.AddScoped<IRandom, TRandom>();
}
public static bool Nex... |
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE QuasiQuotes #-}
{-# LANGUAGE TemplateHaskell #-}
module Shed.Images where
import Codec.Picture (DynamicImage (ImageRGB8), Image (..),
convertRGB8, decodeImage)
import Codec.Picture.Extra (sc... |
export const convertToDataUrl = (
file: Readonly<File>
): Promise<string | null> => {
const reader = new FileReader()
reader.readAsDataURL(file)
return new Promise(resolve => {
reader.addEventListener(
'load',
event => {
// `readAsDataURL`を用いるため、結果の型はstring
// see: https://develo... |
package monixdoc.evaluation.task
import monix.eval.{Fiber, Task}
import monix.execution.CancelableFuture
import monix.execution.Scheduler.Implicits.global
import scala.concurrent.duration._
import scala.language.postfixOps
object App15bTaskRaceMany extends App {
println("\n-----")
val ta = Task(1 + 1).delayExe... |
#!/usr/bin/env bash
# 将hello l插入text.txt的第二行
sed -e "2a" -e "hello" ./test.txt |
#pragma once
#include "parser.h"
#include <optional>
#include <utility>
namespace kapows::pc {
template <typename T> struct zero_t {
public: // typedefs
using result_type = T;
public: // observers
constexpr auto operator()(parser_input_t input) const -> parser_output_t<T> {
return std::nullopt;
}
};
// Z... |
import pygame
import time
class time_counting:
def __init__(self, time_):
self.font = pygame.font.Font(None, 25)
self.frame_rate = 60
self.time = time_
self.prev_time = time.time()
screen_size = pygame.display.get_surface().get_size()
width = screen_size[0]
... |
package org.opentorah.docbook
import org.opentorah.xml.{Attribute, Element, Parsable, Parser, Unparser}
final class OutputConfiguration(val format: String)
// TODO split out format and variant
// TODO clean up parsing/unparsing
object OutputConfiguration extends Element[OutputConfiguration]("output"):
override def... |
<?php
/**
* Created by PhpStorm
* User: Pony
* Date: 2021/12/23
* Time: 5:01 下午
*/
declare(strict_types=1);
namespace PonyCool\Es;
class Config
{
protected array $hosts;
protected string $host;
protected int $port;
protected string $scheme;
protected string $user;
protected string $pass;
... |
#!/usr/bin/env bash
for comp in `cat $1`; do
host $comp
done
|
using Xunit;
using Main.Models;
namespace MainTests.Models
{
public class Box1Tests
{
[Fact]
public void CanCreateBox()
{
var box = new Box1(30);
Assert.NotNull(box);
Assert.Equal(30, box.Length(0));
}
[Fact]
public void CanPu... |
package ledgerstate
import (
"bytes"
"encoding/binary"
"math/rand"
"sync"
"testing"
"time"
"github.com/iotaledger/hive.go/byteutils"
"github.com/iotaledger/hive.go/crypto/ed25519"
"github.com/iotaledger/hive.go/identity"
"github.com/iotaledger/hive.go/marshalutil"
"github.com/iotaledger/hive.go/objectstora... |
//------------------------------------------------------------------------------
/*
This file is part of cbcd: https://github.com/cbc/cbcd
Copyright (c) 2012, 2013 cbc Labs Inc.
Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted, pro... |
<?php
namespace Reform\Tests\Validation\Rule;
use Reform\Validation\Rule\Required;
/**
* RequiredTest
*
* @author Glynn Forrest <me@glynnforrest.com>
**/
class RequiredTest extends RuleTest
{
protected $rule;
public function setup()
{
$this->rule = new Required();
}
public function... |
#!/usr/bin/env bash
set -e
CXXFLAGS=""
if [ -f /etc/redhat-release ]; then
CXXFLAGS="-Wno-error=class-memaccess -Wno-ignored-qualifiers -Wno-stringop-truncation -Wno-cast-function-type"
fi
if [ -n "${WITH_RHEL8_RPMS}" ]; then
cd grpc
cd third_party
rmdir abseil-cpp protobuf
mv ../../abseil-cpp .
... |
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using WebWallet.Models.Enumerations;
using WebWallet.ViewModels.Constants;
using WebWallet.ViewModels.Transaction;
namespace WebWallet.ViewModels.Goal
{
public class GoalVM
{
public string Id { get; set; }
... |
<?php
/**
* Buffered query utilities.
*/
namespace PhpMyAdmin\SqlParser\Utils;
use PhpMyAdmin\SqlParser\Context;
/**
* Buffer query utilities.
*
* Implements a specialized lexer used to extract statements from large inputs
* that are being buffered. After each statement has been extracted, a lexer or
* a par... |
#!/bin/bash
subscriptionId="<TODO>"
publisherId="<TODO>"
offerId="<TODO>"
planId="<TODO>"
./AcceptAzureMarketplaceTerms.sh -i $subscriptionId -p $publisherId -o $offerId -n $planId |
module Ruhoh::Resources::Notes
class Previewer < Ruhoh::Resources::Pages::Previewer
end
end
|
# frozen_string_literal: true
FactoryBot.define do
# Define your Spree extensions Factories within this file to enable applications, and other extensions to use and override them.
#
# Example adding this to your spec_helper will load these Factories for use:
# require 'spree_sale_prices/factories'
factory :... |
<?php
namespace App\Models;
use App\Traits\OwnerConfig;
use App\Enums\PaymentStatus;
use App\Traits\EloquentHelpers;
use Illuminate\Database\Eloquent\Builder;
class Payment extends Model
{
use OwnerConfig, EloquentHelpers;
private $payEvent;
protected $fillable = [
'price',
'installment... |
fun main(args:Array<String>){
var x = 25
var y:String = "Game"
print(x)
print(y)
} |
<?php
use Symfony\Component\Dotenv\Dotenv;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\Routing\Exception\ResourceNotFoundException;
use Symfony\Component\Routing\Matcher\UrlMatcher;
use Symfony\Component\Routing\RequestContext;
require_once(__DIR_... |
const Employee = require("../lib/employee");
describe("Employee", () => {
describe("init", () => {
it("should create an instance of an employee when we call it with the new keyword", () => {
const employee1 = new Employee("Brad", 123, "bodell94@yahoo.com");
expect(employee1.name).to... |
/*
* Copyright (c) 2013 Functional Streams for Scala
*
* 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, modif... |
import { fromJS, Map } from 'immutable';
import mapPageReducer, { initialState } from '../reducer';
import { mapPageActions } from '../actions';
import {
SET_INITIAL_LOCATION,
SET_PAGE_ERROR,
SET_LOADING,
} from '../constants';
const acts = mapPageActions(result => result);
const initState = initialState.toJS()... |
package com.smict.schedule.action;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpSession;
import org.apache.struts2.ServletActionContext;
import com.opensymphony.xwork2.ActionSupport;
import com.smict.auth.Aut... |
# Nullcraft
#===========================
# TODO
#===========================
#1. Get Growth Blocks Working...
#2. Multiple Tiers, Single Effect
#3. Testing Lag and using Extremes
#4. Start on early game content
#5. undetermined... |
require 'uri'
require 'hocon/impl'
require 'hocon/impl/origin_type'
class Hocon::Impl::SimpleConfigOrigin
MERGE_OF_PREFIX = "merge of "
def self.new_file(file_path)
url = URI.join('file:///', file_path)
self.new(file_path, -1, -1,
Hocon::Impl::OriginType::FILE,
url, nil)
end
... |
<section class="circles reputation-circles">
<div class="container">
<div class="row">
<div class="col flex-col circle-col">
<div class="line line-1">
<?php hm_get_template_part( 'template-parts/progress-ring', [ 'percentage' => '94' ] ); ?>
... |
import type { Component } from "./types";
export const componentApp: Component = {
id: 0,
name: "App",
type: "svelte",
source: `<script>
import Component from './Component1.svelte';
<\/script>
<Component name={"SvelteREPL"}/>`,
};
export const component1: Component = {
id: 1,
name: "Compo... |
class Weechat < Formula
desc "Extensible IRC client"
homepage "https://www.weechat.org"
url "https://weechat.org/files/src/weechat-3.2.tar.xz"
sha256 "39a8adf374e80653c9dd2be06870341594ea081b3a9c3690132e556abf9d87a8"
license "GPL-3.0-or-later"
head "https://github.com/weechat/weechat.git"
bottle do
s... |
#!/usr/bin/env bash
SCRIPT_DIR=`dirname $0`
echo "script directory: $SCRIPT_DIR"
pushd "$SCRIPT_DIR/.."
mvn site
popd
pushd "$SCRIPT_DIR/../target/site/"
git init
git remote add javadoc https://dazraf@github.com/dazraf/vertx-futures.git
git fetch --depth=1 javadoc gh-pages
git add --all
git commit -m "javadoc"
git merg... |
---
layout: post
title: "Chennai"
date: 2017-07-21 19:25:00
categories: travel
---
<div class="post-sidebar">
<h3>Places Visited</h3>
<ul>
<li><a href="https://goo.gl/maps/JHMMfRx7Zjp" target="_blank">Chennai Government Museum</a></li>
<li><a href="http://amethystchennai.com" target="_blank">Amethyst... |
#!/usr/bin/env ruby
CWL_PATH=File.join(File.dirname(__FILE__), '..', 'examples')
if $0 == __FILE__
base_dir = File.expand_path(File.join(File.dirname(__FILE__), ".."))
lib_dir = File.join(base_dir, "lib")
test_dir = File.join(base_dir, "test")
$LOAD_PATH.unshift(lib_dir)
require 'test/unit'
exit Test:... |
using System;
namespace UnityThirdPartySdkManager.Editor.Configs
{
/// <summary>
/// 配置
/// </summary>
[Serializable]
public class Config
{
/// <summary>
/// 安卓配置
/// </summary>
public AndroidConfig android;
/// <summary>
/// ios配置
... |
require_relative 'utils'
module CartoDB
module Relocator
class QueueConsumer
include CartoDB::Relocator::Connections
def initialize(params={})
@config = params[:config]
@dbname = @config[:dbname]
@username = @config[:username]
end
def redis
@redis ||= Red... |
const ln = require('./lyrics-src/ln');
const al = require('./lyrics-src/al');
const genius = require('./lyrics-src/genius');
// LN: Lyrical Nonsense
// AL: Animelyrics
const Provider = {
LN: ln,
AL: al,
GENIUS: genius,
};
/**
* @param {String} query keyword to find lyrics
* @param {Object[]} Provider
*... |
class WeatherIconsUtil {
static const int dateTimestamp = 1614982233069;
static const Map<String, int> iconMap = {
'wi-day-sunny': 0xf00d,
'wi-day-cloudy': 0xf002,
'wi-day-cloudy-gusts': 0xf000,
'wi-day-cloudy-windy': 0xf001,
'wi-day-fog': 0xf003,
'wi-day-hail': 0xf004,
'wi-day-haze': 0... |
package com.zeynelerdi.pastryshop.repository.db
import android.arch.persistence.room.Database
import android.arch.persistence.room.RoomDatabase
import android.arch.persistence.room.TypeConverters
import com.zeynelerdi.pastryshop.bin.Pages
/**
* Created by Zeynel Erdi Karabulut on 01/06/20.
* Application database.... |
---
id: introducing-producers
title: Introducing Producers
sidebar_label: Producers
---
[producer](/docs/api/producer)s are the central concept of Engine. Engine
recommends that our components should only represent the view, and have as
little logic as possible. Producers are where the logic lives in an Engine app.
S... |
<?php
namespace App\Http\Controllers;
use Illuminate\Support\Facades\Auth;
use Illuminate\Http\Request;
use DB;
class edit_single_mndyprojectController extends Controller
{
public function showElement(){
$showUnit = DB::table('unit')->get();
return view('edit_single_mndyproject',compact('showUnit'));
}
pu... |
#!/bin/bash
# Import the lib
source extlib.bash
# sourcing example.bash.conf is implied if it exists
# Read the default command line arguments
argparser "$@"
# Ensure only one instance of this script is running
checkpid
# Validate that the correct user is running this script per the config
requireuser
# Add task t... |
// GENERATED
package com.fkorotkov.kubernetes
import io.fabric8.kubernetes.api.model.Cluster as model_Cluster
import io.fabric8.kubernetes.api.model.NamedCluster as model_NamedCluster
fun model_NamedCluster.`cluster`(block: model_Cluster.() -> Unit = {}) {
if(this.`cluster` == null) {
this.`cluster` = model_C... |
package edin.nn.sequence
import edin.general.YamlConfig
import edu.cmu.dynet.{Expression, ParameterCollection}
trait SequenceEncoderConfig{
val outDim:Int
def construct()(implicit model: ParameterCollection) : SequenceEncoder
}
object SequenceEncoderConfig{
def fromYaml(conf:YamlConfig) : SequenceEncoderCon... |
//Loja de tintas
#include <stdio.h>
int main(void){
int metros,value,latas;
printf("Insira a quantidade de metros a ser pintado: \n");
scanf("%i",&metros);
latas = metros / 3;
value = latas * 80;
printf("Você terá de comprar %i latas\n",latas);
printf("E isso custará %i \n",value);
return 0;
}
|
# ChubbyMango
a little game written by _Lua_ & _LÖVE2d_
***
__Mango__ loves eating balls(or peach?), but she can't eat the ball bigger than herself.
***
You can press key `left` and `right` to control a panel. This panel will help you to carry __Mango__!
Press key `r` to restart.
|
//multilevel Inheritance example
class Car{
public Car()
{
System.out.println("Class Car");
}
public void vehicleType()
{
System.out.println("Vehicle Type: Car");
}
}
class Maruti extends Car{
public Maruti()
{
System.out.println("Class Maruti");
}
public void brand()
{
System.out.p... |
INSERT INTO `admin_permissions` (`admin_id`, `permission_id`) VALUES
(1, 41),
(1, 42),
(1, 43),
(1, 44),
(1, 45); |
<?php namespace Rede\Gateway\Model;
use Rede\Gateway\Interfaces\Model;
/**
*
* @author Lucas Zerma - <lzerma@gmail.com>
* @since 01/04/2014
* @project www.lucaszerma.com/eredegw
* @see https://github.com/lzerma/gateway_rede
*
*/
class ContAuthTxn implements Model
{
/**
*
* @var String
... |
set -ex
# Incorporate TARGET env var to the build and test process
if [[ $TARGET != *-musl ]]; then
cargo build --target "$TARGET" --verbose
cargo test --target "$TARGET" --verbose
else
# Build with musl in a Docker container
docker build -t build-"$PROJECT_NAME" -f docker/Dockerfile-musl .
chmod -R 777 "$TR... |
# InfoPushDataArticleContent
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**text** | **String** | | [optional]
**imageUrl** | **String** | | [optional]
**onPressed** | [**InfoPushDataClickable**](InfoPushDataClickable.md) | | [optional]
|
#!/usr/bin/ruby
policies = File.read(__dir__ + "/policies.txt").split(/\n/)
valid_passwords = []
policies.each do |policy|
req, char, pass = policy.split(/\s/)
char.sub!(":","")
min, max = req.split("-")
occurrence = pass.count(char)
next unless occurrence >= min.to_i
next unless occurrence <= max.to_i
valid... |
package com.coditory.gradle.manifest
import java.net.InetAddress
interface HostNameResolver {
fun resolveHostName(): String
companion object {
val INET_HOST_NAME_RESOLVER = object : HostNameResolver {
override fun resolveHostName(): String {
return InetAddress.getLocalHost... |
#!/bin/sh
./set-project.sh
PROJECT_ID=$(gcloud config get-value project)
cd terraform
terraform init
terraform apply --var "project=$PROJECT_ID"
|
import 'package:memorizer/entities/category_content.dart';
class CategoryPageResult {
final List<CategoryContent> categories;
int get totalResults {
return categories.length;
}
CategoryPageResult.fromJSON(Map<String, dynamic> json)
: categories = (json['categories'] as List).map((json) => CategoryC... |
import set from 'set-value';
import strind from 'strind';
import { Result, Results } from './FuzzyHighlighter';
function formatResults<T>(results: Results<T>): FinalResults<T> {
const finalResults: FinalResults<T> = [];
results.forEach((result, index) => {
finalResults.push({ ...result, formatted: { ...result... |
#set -ex
if [ $# != 5 ] ; then
echo "please input args:
arg 1: image name (image name must be lowercase,eg: filereader)
arg 2: image version(Tag)
arg 3: pkg name (package must be in pkg directories )
arg 4: system (centos:7.5 or alpine or debian)
arg 5: cpu arch (amd64 or arm64)"
exit 1;
fi
ROOT=$(cd $(dir... |
using System.Collections.Generic;
using JetBrains.Annotations;
using JetBrains.Application.Threading;
using JetBrains.Diagnostics;
using JetBrains.ReSharper.Feature.Services.Intentions;
using JetBrains.ReSharper.Feature.Services.QuickFixes;
using JetBrains.ReSharper.Psi.CSharp.Tree;
using JetBrains.ReSharper.Psi.Tree;
... |
package com.louyj.dbsync.job
import com.louyj.dbsync.SystemContext
import com.louyj.dbsync.config.DatabaseConfig
import com.louyj.dbsync.dbopt.DbOperationRegister
import com.louyj.dbsync.sync.HeartbeatComponent
import org.slf4j.LoggerFactory
import java.util.concurrent.TimeUnit
/**
*
* Create at 2020/8/24 18:06<br... |
use super::*;
use crate::ids::parser::*;
use crate::scanner::Keywords;
// TODO Split lines with more than 80 characters.
// The only stuff that this formatter reorders are the the package name and imports,
// since they must appear first. Anything else, only the comments, spaces and indentantion are fixed.
pub fn for... |
module ApplicationHelper
def navbar(controller)
controller = controller.to_s
if policy(Object.const_get(controller.classify)).index?
content_tag(:li, class: controller_name == controller ? :active : nil) do
link_to controller.camelize, send("#{controller}_path")
end
end
end
def bo... |
// This module includes the embedded spritesheets. To add additional spritesheets
// update `build.rs`.
pub mod pngs {
include!(concat!(env!("OUT_DIR"), "/pngs.rs"));
}
pub mod constants;
pub mod generator;
pub mod grid_generator;
pub mod grid_renderer;
pub mod service;
pub mod sheets;
pub mod spelunkicon;
|
import pandas as pd
from pathlib import Path
from pins.rsconnect.fs import PinBundleManifest
from pins.meta import MetaFactory
p_root = Path("pins/tests/example-bundle")
p_root.parent.mkdir(parents=True, exist_ok=True)
p_index = p_root / "index.html"
p_index.write_text("<html><body>yo</body></html>")
p_data = p_roo... |
const jsdom = require('jsdom')
const chalk = require('chalk')
const SpellChecker = require('spellchecker')
module.exports = {
spellcheck: function (content, inputPath) {
if (inputPath.endsWith('.md') || inputPath.endsWith('.markdown')) {
const { JSDOM } = jsdom
const { document } = ... |
"use strict";
module.exports = context => {
return {
BinaryExpression: node => {
if (node.left.name > node.right.name) {
context.report({
node,
message: "目上の変数は比較演算子の右側に配置すべきです。"
});
}
}
};
};
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.