text stringlengths 3 1.05M |
|---|
package example.springdata.redis.repositories;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.data.redis.connection.RedisConnectionFactory;
import org.springframework.data.redis.connection.lettuce.LettuceConnectionFactory;
im... |
namespace leveldb {
// Standard Put... routines append to a string
extern void PutFixed32(std::string* dst, uint32_t value);
extern void PutFixed64(std::string* dst, uint64_t value);
extern void PutVarint32(std::string* dst, uint32_t value);
extern void PutVarint64(std::string* dst, uint64_t value);
extern void PutLen... |
package com.google.maps.android.utils.demo;
import android.graphics.Color;
import com.google.android.gms.maps.CameraUpdateFactory;
import com.google.android.gms.maps.model.BitmapDescriptorFactory;
import com.google.android.gms.maps.model.LatLng;
import com.google.android.gms.maps.model.MarkerOptions;
import com.goog... |
<?php
final class UploadArtifactBuildStepImplementation
extends VariableBuildStepImplementation {
public function getName() {
return pht('Upload Artifact');
}
public function getGenericDescription() {
return pht('Upload an artifact from a Drydock host to Phabricator.');
}
public function getDesc... |
package netflix.karyon.transport.http;
/**
* A simple wrapper over {@link io.netty.handler.codec.http.QueryStringDecoder} to also provide access to the uri string.
*
* @author Nitesh Kant
*/
public class QueryStringDecoder {
private final io.netty.handler.codec.http.QueryStringDecoder nettyDecoder;
privat... |
"""
Tests for FileBrowser sites and their views.
Note that we *dynamically generate* test cases for each deployed FileBrowser site.
This includes creation of TestCase subclasses at runtime and also creation of
instance methods from functions.
"""
# PYTHON IMPORTS
import os
import sys
import shutil
from urllib impo... |
package org.apache.drill.exec.store.mapr.db;
import com.mapr.db.impl.IdCodec;
import org.apache.commons.lang3.tuple.Pair;
import org.apache.drill.exec.physical.impl.join.RowKeyJoin;
import org.apache.drill.exec.record.AbstractRecordBatch.BatchState;
import org.apache.drill.exec.vector.ValueVector;
import com.faster... |
<?php
namespace Drupal\system\Form;
use Drupal\Core\Config\ConfigManagerInterface;
use Drupal\Core\Config\Entity\ConfigDependencyDeleteFormTrait;
use Drupal\Core\Entity\EntityManagerInterface;
use Drupal\Core\Extension\ModuleInstallerInterface;
use Drupal\Core\Form\ConfirmFormBase;
use Drupal\Core\Form\FormStateInter... |
<?php
// This is the front controller used when executing the application in the
// production environment ('prod'). See
//
// * http://symfony.com/doc/current/cookbook/configuration/front_controllers_and_kernel.html
// * http://symfony.com/doc/current/cookbook/configuration/environments.html
use Symfony\Componen... |
package com.github.pagehelper.test.basic;
import com.github.pagehelper.Page;
import com.github.pagehelper.PageHelper;
import com.github.pagehelper.model.Country;
import com.github.pagehelper.util.MybatisHelper;
import org.apache.ibatis.session.SqlSession;
import org.junit.Test;
import java.util.HashMap;
import java... |
// (C) Copyright 2015 Martin Dougiamas
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agre... |
<?php
namespace PHPMad\Rule;
class IsMultipleOrContainsRule implements Rule
{
private $multipleValue;
private $value;
public function __construct($multipleValue, $value)
{
$this->multipleValue = $multipleValue;
$this->value = $value;
}
public function check($num)
{
... |
package org.apache.camel.component.mail;
import javax.mail.BodyPart;
/**
* Resolver to determine Content-Transfer-Encoding for file attachments.
* <br/>
* Normally this will be determined automatically, this resolver can be used to
* override this behavior.
*/
public interface AttachmentsContentTransferEncoding... |
<?php
namespace spec\Gaufrette\Util;
use PHPSpec\ObjectBehavior;
class ChecksumSpec extends ObjectBehavior
{
function let()
{
$path = __DIR__.DIRECTORY_SEPARATOR.'testFile';
file_put_contents($path, 'some other content');
}
function it_calculates_checksum_from_content()
{
... |
package org.wso2.carbon.registry.migration.utils;
import java.util.HashMap;
import java.util.Map;
import org.json.simple.JSONArray;
import org.json.simple.JSONObject;
import org.json.simple.parser.JSONParser;
import org.json.simple.parser.ParseException;
import org.wso2.carbon.apimgt.impl.APIConstants;
import org.w... |
#region License
// Copyright (c) 2007 James Newton-King
//
// 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,... |
import {
CubeTexture,
DataTexture,
FileLoader,
FloatType,
HalfFloatType,
LinearEncoding,
LinearFilter,
Loader,
NearestFilter,
RGBAFormat,
RGBEEncoding,
RGBFormat,
UnsignedByteType
} from "../../../build/three.module.js";
import { RGBELoader } from "../loaders/RGBELoader.js";
var HDRCubeTextureLoader = fun... |
;(function ( $, window, document, undefined ) {
"use strict";
$.fn.shape = function(parameters) {
var
$allModules = $(this),
$body = $('body'),
time = new Date().getTime(),
performance = [],
query = arguments[0],
methodInvoked = (typeof query == '... |
'use strict';
var DESCRIPTORS = require('../internals/descriptors');
var global = require('../internals/global');
var isForced = require('../internals/is-forced');
var redefine = require('../internals/redefine');
var has = require('../internals/has');
var classof = require('../internals/classof-raw');
var inheritIfRequ... |
{% extends "block/base.html" %}
{% block title %}{{ blog.title }}|{{ confObj.title }}{% endblock %}
{% block keywords %}{{ blog.keywords }},{{ confObj.title }}{% endblock %}
{% block description %}{{ blog.summary | replace({'\n': ''}) | striptags | slice(0, 140) }}{% endblock %}
{% block sidebar %}
{% include "... |
<?php
declare (strict_types = 1);
namespace HMLB\DDDBundle\Doctrine\ORM;
use HMLB\DDD\Entity\Identity;
use HMLB\DDD\Message\Event\PersistentEvent;
use HMLB\DDDBundle\Repository\PersistentEventRepository;
/**
* ORMPersistentEventRepository.
*
* @author Hugues Maignol <hugues@hmlb.fr>
*/
class ORMPersistentEventR... |
package org.kie.dmn.feel.marshaller;
import org.kie.dmn.feel.lang.Type;
/**
* A generic marshaller interface for FEEL values
*/
public interface FEELMarshaller<T> {
/**
* Marshalls the given FEEL value into an object of type T
*
* @param value the FEEL value to be marshalled
*
* @ret... |
package com.intellij.execution.impl.statistics;
import com.intellij.execution.RunManager;
import com.intellij.execution.RunnerAndConfigurationSettings;
import com.intellij.execution.configurations.ConfigurationFactory;
import com.intellij.execution.configurations.ConfigurationType;
import com.intellij.execution.confi... |
package grpc
import (
"context"
"errors"
"io"
"math"
"strconv"
"sync"
"time"
"golang.org/x/net/trace"
"google.golang.org/grpc/balancer"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/encoding"
"google.golang.org/grpc/internal/balancerload"
"google.golang.org/grpc/internal/binarylog"
"google.go... |
package gitlab
import (
"fmt"
"net/url"
"time"
)
// DeployKeysService handles communication with the keys related methods
// of the GitLab API.
//
// GitLab API docs: https://docs.gitlab.com/ce/api/deploy_keys.html
type DeployKeysService struct {
client *Client
}
// DeployKey represents a GitLab deploy key.
type... |
package org.ws.baidu.api;
import junit.framework.TestCase;
import org.ws.httphelper.WSHttpHelper;
import java.util.HashMap;
import java.util.Map;
/**
* Created by Administrator on 15-12-11.
*/
public class TestPlaceAPI extends TestCase {
public void testRequest()throws Exception{
PlaceAPI ... |
/**
Custom module for you to write your own javascript functions
**/
var Custom = function () {
// private functions & variables
var myFunc = function(text) {
alert(text);
}
// public functions
return {
//main function
init: function () {
//initialize here som... |
int main(void) { // Some local scope.
int sum = 0, factor = 10; // Variables in scope to bind.
void BOOST_LOCAL_FUNCTION(const bind factor, bind& sum, int num) {
sum += factor * num;
} BOOST_LOCAL_FUNCTION_NAME(add)
add(1); ... |
{% load hq_shared_tags %}
{% load i18n %}
{% if show_time_notice %}{% include "hqwebapp/partials/time-notice.html"%}{% endif %}
{% block reportcontent %}
{% if report.show %}
{% if report.slug %}
<div class="hq-loading" style="display: none;">
<h4>{% trans "Loading Report" %}</h... |
class AddPrequisitesToCriteria < ActiveRecord::Migration[5.1]
def change
add_column(
:projects, :achieve_passing_status, :string, default: 'Unmet',
null: false
)
add_column :projects, :achieve_passing_justification, :text
add_column(
:proj... |
<?php
namespace Gedmo\Tree;
use Doctrine\Common\EventManager;
use Tool\BaseTestCaseORM;
use Doctrine\Common\Util\Debug,
Tree\Fixture\BehavioralCategory,
Tree\Fixture\Article,
Tree\Fixture\Comment,
Gedmo\Translatable\TranslatableListener,
Gedmo\Translatable\Entity\Translation,
Gedmo\Sluggable\S... |
#ifndef _ASM_XTALK_XTALK_H
#define _ASM_XTALK_XTALK_H
#ifndef __ASSEMBLY__
/*
* User-level device driver visible types
*/
typedef char xwidgetnum_t; /* xtalk widget number (0..15) */
#define XWIDGET_NONE -1
typedef int xwidget_part_num_t; /* xtalk widget part number */
#define XWIDGET_PART_NUM_NONE -1
typedef... |
package org.jrebirth.af.component.command.snapshot;
import java.awt.image.BufferedImage;
import java.io.File;
import java.io.IOException;
import javax.imageio.ImageIO;
import javafx.embed.swing.SwingFXUtils;
import javafx.stage.FileChooser;
import org.jrebirth.af.api.exception.CoreRuntimeException;
import org.jrebi... |
For all examples you need to run consul and registrator. Make sure you have boot2docker installed, so that you can run the examples below on your own machine.
Run consul:
```
$ docker run --name consul -d -p 8400:8400 -p 8500:8500 -p 8600:53/udp -h node1 gliderlabs/consul-server -advertise 127.0.0.1 -bootstrap
```
R... |
if (typeof (tv4.asyncValidate) === 'undefined') {
tv4.syncValidate = tv4.validate;
tv4.validate = function (data, schema, callback, checkRecursive) {
if (typeof (callback) === 'undefined') {
return this.syncValidate(data, schema, checkRecursive);
} else {
return this.asyncValidate(data, schema, callback, ch... |
module.exports = function(grunt) {
'use strict';
// Project configuration.
grunt.initConfig({
jshint: {
options: {
jshintrc: '.jshintrc'
},
all_files: ['Gruntfile.js', 'tasks/**/*.js', '<%= nodeunit.tests %>']
},
// Before ... |
import io
import xlsxwriter
from django.conf import settings
from django.http import HttpResponse
from democracy.models import SectionComment
from .section_comment import SectionCommentSerializer
class HearingReport(object):
def __init__(self, json):
self.json = json
self.buffer = io.BytesIO()... |
package org.pentaho.di.core.database;
import static org.junit.Assert.*;
import static org.mockito.Matchers.anyString;
import static org.mockito.Mockito.*;
import java.sql.Connection;
import java.sql.Driver;
import java.sql.DriverManager;
import java.util.Collections;
import java.util.List;
import java.util.Propertie... |
/*global window: false, jQuery: false, console: false, define: false */
/* Cache window, document, undefined */
(function( window, document, undefined ) {
// Uses AMD or browser globals to create a jQuery plugin.
(function( factory ) {
"use strict";
if(typeof define === 'function' && define.amd) {
define(['jquer... |
'use strict';
var Carousel = require('./lib/carousel');
module.exports = Carousel;
|
%% properties
35 value
375 value
%% globals
--]]
-- CONSTS
local debugMode = true;
-- Devices ID's
local doorID = 375;
local lightID = 35;
-- GETENV
local door, doorMT = fibaro:get(doorID, "value");
local light, lightMT = fibaro:get(lightID, "value");
local srcTrigger = fibaro:getSourceTrigger();
local srcDevice... |
var main = (function() {
// GATT Device Information Service UUIDs
var DEVICE_INFO_SERVICE_UUID = '0000180a-0000-1000-8000-00805f9b34fb';
var MANUFACTURER_NAME_STRING_UUID = '00002a29-0000-1000-8000-00805f9b34fb';
var SERIAL_NUMBER_STRING_UUID = '00002a25-0000-1000-8000-00805f9b34fb';
var HARDWARE_REV... |
typeof window !== "undefined" &&
(function webpackUniversalModuleDefinition(root, factory) {
if(typeof exports === 'object' && typeof module === 'object')
module.exports = factory();
else if(typeof define === 'function' && define.amd)
define([], factory);
else if(typeof exports === 'object')
exports["Hls"] = f... |
namespace content {
enum P2PSocketOption {
P2P_SOCKET_OPT_RCVBUF, // Receive buffer size.
P2P_SOCKET_OPT_SNDBUF, // Send buffer size.
P2P_SOCKET_OPT_DSCP, // DSCP code.
P2P_SOCKET_OPT_MAX
};
// Type of P2P Socket.
enum P2PSocketType {
P2P_SOCKET_UDP,
P2P_SOCKET_TCP_SERVER,
P2P_SOCKET_STUN_TCP_SERVE... |
namespace RDKit {
namespace CIPLabeler {
Edge *Configuration::findInternalEdge(const std::vector<Edge *> &edges,
Atom *f1, Atom *f2) {
for (const auto &edge : edges) {
if (edge->getBeg()->isDuplicate() || edge->getEnd()->isDuplicate()) {
continue;
}
if (isInter... |
<html>
<body>
This intention merges two <b>if</b> statements into one, if the second is located inside
the then-branch of the first.
</body>
</html>
|
package swarm
import (
"fmt"
"github.com/giantswarm/kocho/provider"
"github.com/giantswarm/kocho/provider/aws"
)
// ProviderManager describes available and active Providers.
type ProviderManager struct {
Providers []ProviderType
activeProviders []ProviderType
}
// ProviderType describes the type of Provi... |
from django.contrib.sites.models import Site
from oembed.tests.tests.base import BaseOEmbedTestCase
from oembed.utils import size_to_nearest, relative_to_full, load_class, cleaned_sites, scale
class OEmbedUtilsTestCase(BaseOEmbedTestCase):
def test_size_to_nearest(self):
sizes = ((100, 100), (200, 200), (... |
var NeverObservable = (function(__super__) {
inherits(NeverObservable, __super__);
function NeverObservable() {
__super__.call(this);
}
NeverObservable.prototype.subscribeCore = function (observer) {
return disposableEmpty;
};
return NeverObservable;
}(ObservableBase));
/**
... |
package com.yokmama.learn10.chapter04.lesson17.fragment;
import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import com.yokmama.learn10.chapter04.lesson17.R;
/**
* A simple {@link Fragment} subclass.
*/
publ... |
from glob import glob
from pathlib import Path
from subprocess import run
exit_code = 0
mod_path = Path(__file__).parent
for lint in glob(f"{mod_path}/lint-*.py"):
result = run([lint])
if result.returncode != 0:
print(f"^---- failure generated from {lint.split('/')[-1]}")
exit_code |= result.re... |
// Copyright 2012 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
/*
Package agent implements a client to an ssh-agent daemon.
References:
[PROTOCOL.agent]: http://www.openbsd.org/cgi-bin/cvsweb/src/usr.bin/ssh/PROTOCO... |
#ifndef GRPC_CORE_LIB_GPRPP_ATOMIC_H
#define GRPC_CORE_LIB_GPRPP_ATOMIC_H
#include <grpc/support/port_platform.h>
#include <atomic>
#include <grpc/support/atm.h>
namespace grpc_core {
enum class MemoryOrder {
RELAXED = static_cast<int>(std::memory_order_relaxed),
CONSUME = static_cast<int>(std::memory_order_... |
<?php
class Google_Service_Spanner_Operation extends Google_Model
{
public $done;
protected $errorType = 'Google_Service_Spanner_Status';
protected $errorDataType = '';
public $metadata;
public $name;
public $response;
public function setDone($done)
{
$this->done = $done;
}
public function ge... |
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:gravity="center_vertical"
android:paddingBottom="5dp"
an... |
module Requests
# This module allows you to use 'json' within specs as a shortcut for
# 'JSON.parse(response.body)'
module RequestHelpers
def json
@json ||= JSON.parse(response.body)
end
# Add support for testing `options` requests in RSpec.
# See: https://github.com/rspec/rspec-rails/issue... |
package util
import (
"context"
"github.com/apache/servicecomb-service-center/datasource/etcd/client"
"github.com/apache/servicecomb-service-center/pkg/util"
)
func FromContext(ctx context.Context) []client.PluginOpOption {
opts := make([]client.PluginOpOption, 0, 5)
switch {
case ctx.Value(util.CtxNocache) ... |
@InterfaceAudience.Private
package org.apache.hadoop.mapreduce.v2.api;
import org.apache.hadoop.classification.InterfaceAudience;
|
package invalid
import "vend/x/invalid/vendor/foo"
|
package com.macoscpoe.roombooker.injector.module;
import com.google.gson.FieldNamingPolicy;
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
import com.macoscope.mvp.model.ResponseWrapper;
import com.macoscope.network.Repository;
import com.macoscpoe.roombooker.BuildConfig;
import com.macoscpoe.roomboo... |
public class Main {
String test(String[] strings) {
StringBuilder res = new StringBuilder();
for (String s : strings) {
if (res.length() > 0) {
res.insert(0, ".");
}
res.insert(0, s);
}
return res.toString();
}
}
|
package org.apache.rya.api.resolver.impl;
import org.apache.rya.api.resolver.RyaTypeResolverException;
import org.calrissian.mango.types.LexiTypeEncoders;
import org.calrissian.mango.types.TypeEncoder;
import org.calrissian.mango.types.exception.TypeDecodingException;
import org.calrissian.mango.types.exception.Type... |
namespace foundation
{
//
// Linear Congruential Generator, implementing a recursion of the form
//
// x[n+1] = a * x[n] + b (mod m)
//
// with the following parameters (used in the BCPL language):
//
// multiplier a = 2147001325
// increment b = 715136305
// modulus m = 2^32
//
// For all practical pu... |
package config
import (
"encoding/json"
"net/http"
"net/http/httptest"
"testing"
"time"
"k8s.io/api/core/v1"
apiequality "k8s.io/apimachinery/pkg/api/equality"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/apimachinery/pkg/types"
clientscheme "k8s.io/client-go/ku... |
module Text.Documentalist.Types.DocBlock ( DocBlock(..)
, Paragraph(..)
, Span(..)
, Code(..)
, DocParam(..)
, Resu... |
"use strict";
var _stringify = require("babel-runtime/core-js/json/stringify");
var _stringify2 = _interopRequireDefault(_stringify);
var _extends2 = require("babel-runtime/helpers/extends");
var _extends3 = _interopRequireDefault(_extends2);
var _slicedToArray2 = require("babel-runtime/helpers/slicedToArray");
v... |
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
package json
import (
"bytes"
"io"
)
// A Decoder reads and decodes JSON values from an input stream.
type Decoder struct {
r io.Reader
buf []by... |
package org.apache.spark.deploy
import scala.collection.mutable
import scala.concurrent.duration._
import org.mockito.ArgumentMatchers.any
import org.mockito.Mockito.{mock, verify, when}
import org.scalatest.{BeforeAndAfterAll, PrivateMethodTester}
import org.scalatest.concurrent.Eventually._
import org.apache.spa... |
package flex2.compiler.mxml.builder;
import java.io.StringWriter;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Iterator;
import java.util.Map;
import java.util.Set;
import java.util.Stack;
import macromedia.asc.util.IntegerPool;
import flex2.compiler.CompilationUnit;
import flex2.compiler.u... |
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Documentation</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<base href="../">
<link rel="icon" href="images/favicon.ico"/>
<link rel="stylesheet" href="css/normalize.css">
<link rel="styles... |
//Not using strict: uneven strict support in browsers, #392, and causes
//problems with requirejs.exec()/transpiler plugins that may not be strict.
/*jslint regexp: true, nomen: true, sloppy: true */
/*global window, navigator, document, importScripts, setTimeout, opera */
var requirejs, require, define;
(function (g... |
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Lumino - Login</title>
<link href="css/bootstrap.min.css" rel="stylesheet">
<link href="css/datepicker3.css" rel="stylesheet">
<link href="css/styles.css" rel="stylesheet">
<!--[if lt ... |
package devtestlabs
// Copyright (c) Microsoft and contributors. 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
//
//... |
' Copyright (c) Microsoft. All Rights Reserved. Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
Imports System
Imports System.Collections.Generic
Imports System.Linq
Imports System.Text
Imports Microsoft.CodeAnalysis.Text
Imports Microsoft.CodeAnalysis.V... |
module.exports = {
entry: "./index",
stats: false
}; |
FROM balenalib/orangepi-plus2-ubuntu:xenial-run
# remove several traces of debian python
RUN apt-get purge -y python.*
# http://bugs.python.org/issue19846
# > At the moment, setting "LANG=C" on a Linux system *fundamentally breaks Python 3*, and that's not OK.
ENV LANG C.UTF-8
# install python dependencies
RUN apt-g... |
<!--
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 not use ... |
package main
import (
"bytes"
"fmt"
"go/ast"
"go/format"
"go/parser"
"go/token"
"go/types"
"log"
"sort"
"strings"
)
func main() {
// Parse a single source file.
const input = `
package main
func main() {
var f func()
// if f == nil {
// return
// }
f()
}`
fset := token.NewFileSet()
f, err := pars... |
// Excellon.h
// Copyright (c) 2009, David Nicholls, Perttu "celero55" Ahola
// This program is released under the BSD license. See the file COPYING for details.
/*
This code was moved from heekscnc to here. First it will be mainly targeted
for isolation milling.
*/
#pragma once
#include <string>
#includ... |
package org.springframework.boot.autoconfigure.jms.activemq;
import java.time.Duration;
/**
* Configuration properties for connection factory pooling.
*
* @author Stephane Nicoll
* @since 2.1.0
*/
public class PooledConnectionFactoryProperties {
/**
* Whether a PooledConnectionFactory should be created, in... |
import React, { Component } from 'react'
import './style.css'
export default class EditForm extends Component{
constructor(props){
super(props)
this.state ={
title: this.props.bookData.title,
year: this.props.bookData.year,
id: this.props.bookData.id
}
this.handleInputChange... |
#pragma comment (lib, "3rdparty/skia_lib_debug/skia_animator.lib")
#pragma comment (lib, "3rdparty/skia_lib_debug/skia_core.lib")
#pragma comment (lib, "3rdparty/skia_lib_debug/skia_effects.lib")
#pragma comment (lib, "3rdparty/skia_lib_debug/skia_images.lib")
#pragma comment (lib, "3rdparty/skia_li... |
/**
* @fileoverview Event data chunk.
*
* @author benvanik@google.com (Ben Vanik)
*/
goog.provide('wtf.io.cff.chunks.EventDataChunk');
goog.require('goog.asserts');
goog.require('wtf.io.BufferView');
goog.require('wtf.io.cff.Chunk');
goog.require('wtf.io.cff.ChunkType');
goog.require('wtf.io.cff.PartType');
goo... |
package aws
import (
"net/url"
"strings"
)
// URLHostname will extract the Hostname without port from the URL value.
//
// Copy of Go 1.8's net/url#URL.Hostname functionality.
func URLHostname(url *url.URL) string {
return stripPort(url.Host)
}
// stripPort is copy of Go 1.8 url#URL.Hostname functionality.
// ht... |
<!DOCTYPE html>
<html lang="en-us">
{% include head.html %}
<body>
{% include sidebar.html %}
<div class="menu-hint hide-on-mobile"></div>
<!-- Wrap is the content to shift when toggling the sidebar. We wrap the
content to avoid any CSS collisions with our real content. -->
<div class=... |
namespace blink {
class V8TestNode {
public:
static bool hasInstance(v8::Handle<v8::Value>, v8::Isolate*);
static v8::Handle<v8::Object> findInstanceInPrototypeChain(v8::Handle<v8::Value>, v8::Isolate*);
static v8::Handle<v8::FunctionTemplate> domTemplate(v8::Isolate*);
static TestNode* toImpl(v8::Hand... |
trap {
&$TrapHandler
}
Function ConvertTo-Boolean {
param (
$InputObject,
[Boolean] $Default = $false
)
try {
[System.Convert]::ToBoolean($InputObject)
}
catch {
$Default
}
}
Function Show-Environment {
foreach ($item in (Get-ChildItem Env:)) {
... |
<?php
defined('YII_DEBUG') or define('YII_DEBUG', true);
defined('YII_ENV') or define('YII_ENV', 'test');
defined('YII_TEST_ENTRY_URL') or define('YII_TEST_ENTRY_URL', parse_url(\Codeception\Configuration::config()['config']['test_entry_url'], PHP_URL_PATH));
defined('YII_TEST_ENTRY_FILE') or define('YII_TEST_ENT... |
package org.apache.activemq.artemis.service.extensions.tests.recovery;
import org.apache.activemq.artemis.api.core.TransportConfiguration;
import org.apache.activemq.artemis.service.extensions.xa.recovery.XARecoveryConfig;
import org.junit.Assert;
import org.junit.Test;
public class XARecoveryConfigTest {
@Test... |
'use strict';
/**
* This file contains the variables used in other gulp files
* which defines tasks
* By design, we only put there very generic config values
* which are used in several places to keep good readability
* of the tasks
*/
const path = require('path');
const gutil = require('gulp-util');
expo... |
// Copyright 2000-2018 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package com.intellij.refactoring.typeCook.deductive.builder;
import com.intellij.ide.highlighter.JavaFileType;
import com.intellij.openapi.diagnostic.Logger;
import com.intellij.... |
<?php
namespace Symfony\Component\Security\Http\Tests\EntryPoint;
use Symfony\Component\Security\Http\EntryPoint\DigestAuthenticationEntryPoint;
use Symfony\Component\Security\Core\Exception\AuthenticationException;
use Symfony\Component\Security\Core\Exception\NonceExpiredException;
class DigestAuthenticationEntr... |
package org.ontoware.rdfreactor.runtime;
import java.util.Iterator;
import org.ontoware.rdf2go.model.Model;
import org.ontoware.rdf2go.model.node.Node;
/**
*
*
* Wrapper class for an Iterator over URI or BlankNode or Literal objects, which
* are objects of triples in the RDF model. Only RDF Reacto... |
package org.apache.activemq.transport.failover;
import javax.jms.Connection;
import javax.jms.JMSException;
import javax.jms.MessageProducer;
import javax.jms.Session;
import javax.jms.TextMessage;
import java.net.URI;
import org.apache.activemq.ActiveMQConnection;
import org.apache.activemq.ActiveMQConnectionFactor... |
<?php
namespace Doctrine\Tests\Common\Cache;
use Doctrine\Common\Cache\MemcacheCache;
class MemcacheCacheTest extends CacheTest
{
private $_memcache;
public function setUp()
{
if (extension_loaded('memcache')) {
$this->_memcache = new \Memcache;
$ok = @$this->_memcache->c... |
(function (root, factory) {
//@author http://ifandelse.com/its-not-hard-making-your-library-support-amd-and-commonjs/
if (typeof module === "object" && module.exports) {
module.exports = factory(require("jquery"));
} else {
root.ssi_modal = factory(root.jQuery);
}
}(this, function... |
package com.google.android.exoplayer.text;
import com.google.android.exoplayer.ExoPlaybackException;
import com.google.android.exoplayer.MediaFormatHolder;
import com.google.android.exoplayer.SampleHolder;
import com.google.android.exoplayer.SampleSource;
import com.google.android.exoplayer.TrackRenderer;
imp... |
package org.eclipse.bpel.ui.adapters;
public class EmptyAdapter extends ActivityAdapter {
}
|
<!DOCTYPE html>
<title>Canvas test: 2d.path.lineTo.ensuresubpath.1</title>
<script src="../tests.js"></script>
<link rel="stylesheet" href="../tests.css">
<body>
<p id="passtext">Pass</p>
<p id="failtext">Fail</p>
<p class="output">These images should be identical:</p>
<canvas id="c" class="output" width="100" height="... |
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
class Logo extends CI_Controller
{
public function __construct()
{
parent::__construct();
}
public function showLogo()
{
return $this->logo_Model->find(1);
}
public function updateLogo()
{
//... |