code stringlengths 2 1.05M |
|---|
var mongoose = require('mongoose');
var Schema = mongoose.Schema;
// var TravelSchema = new Schema({
// name: String,
// ingreso:{ type: Date, default: Date.now },
// details: String,
// pagado: { type: Boolean, default: false },
// costo: { type: Number, default: 0 }
// children:[{ typ... |
/*
Server the HTML part of pages
*/
let _ = require('underscore'),
caps = require('../caps'),
common = require('../../common'),
config = require('../../config'),
db = require('../../db'),
express = require('express'),
hooks = require('../../util/hooks'),
Render = require('../render'),
state = require('../sta... |
/** @description
* Flags all children nodes of a paper element as children of that paper element. This excludes
* other paper elements, however.
* @param {void} void
* @return {void} void
* @dependency {React.state} token
*/
const flagChildren = {
_flagChildrenNodes: function () {
... |
/*! React Starter Kit | MIT License | http://www.reactstarterkit.com/ */
import React, { PropTypes } from 'react';
import demoStyles from '../demo.css';
import withStyles from '../../../decorators/withStyles';
import Dispatcher from '../../../core/Dispatcher';
import DemoBase from '../DemoBase';
/*===================... |
import Ember from 'ember';
import PasteOptionsMixin from '../../../mixins/paste-options';
import { module, test } from 'qunit';
module('Unit | Mixin | paste options');
// Replace this with your real tests.
test('it works', function(assert) {
let PasteOptionsObject = Ember.Object.extend(PasteOptionsMixin);
let sub... |
/**
* Created by lcz on 16/11/17.
*/
"use strict"
var execShellCmds = require('../execShellCmds')
var cmds = [
'echo \'GitLab Server: 127.0.0.1\' > /tmp/gitlabhook.tmp\necho \'Repository: jfjun-fp\' >> /tmp/gitlabhook.tmp\necho $(date) >> /tmp/gitlabhook.tmp\n',
'echo `date`',
]
execShellCmds(cmds); |
module.exports = env => env === 'production' ? require('./prod') : require('./dev') |
'use strict';
describe('Directive: CareerPortalSideBar', function () {
beforeEach(function () {
// Mock configuration
module(function ($provide) {
$provide.constant('configuration', {
"acceptedResumeTypes": [
"html",
"text",
... |
import React from 'react';
import CloseButton from './closebutton';
import '../styles/components/windowtitle.scss';
const WindowTitle = (props) => {
return (
<div className='window-title handle'>
<h1 className='window-title__heading'>
{props.title}
</h1>
<CloseButton onClick={() => prop... |
zn.define(function () {
return zn.Class("zn.db.common.model.Attachment", zn.db.data.Model, {
properties: {
zn_attachment_file_ids: {
value: null,
type: ['varchar', 250],
ignore: true,
default: ','
},
zn_atta... |
'use strict';
// Use application configuration module to register a new module
ApplicationConfiguration.registerModule('address-type');
|
/*
global RevealMarkdown, RevealHighlight, RevealSearch, RevealNotes, RevealMath, RevealZoom, Reveal, mermaid, RevealMenu
*/
import * as params from '@params';
import {fixMermaid} from './wowchemy-utils';
// Enable core slide features.
var enabledPlugins = [RevealMarkdown, RevealHighlight, RevealSearch, RevealNote... |
/* eslint-disable import/no-extraneous-dependencies */
const path = require('path');
const webpack = require('webpack');
const CopyWebpackPlugin = require('copy-webpack-plugin');
const OfflinePlugin = require('offline-plugin');
const HtmlWebpackPlugin = require('html-webpack-plugin');
const BabiliPlugin = require("babi... |
#!/usr/bin/env node
var accumulator = require('./lib/accumulator'),
options = require('./lib/options'),
interval = options.parsed.interval,
failure = 1,
success = 0,
timeout = options.parsed.timeout;
if (options.parsed.verbose) {
console.log('Waiting up to', Math.round(timeout/1000), 'seconds fo... |
const { parse, decode: decodeV0 } = require('../v0/response')
/**
* Starting in version 1, on quota violation, brokers send out responses before throttling.
* @see https://cwiki.apache.org/confluence/display/KAFKA/KIP-219+-+Improve+quota+communication
*
* CreatePartitions Response (Version: 0) => throttle_time_ms ... |
/**
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*
* @flow strict
*/
export const enableUserTimingAPI = __DEV__;
// Helps identify side effects in begin-phase lifecycle hooks and ... |
"use strict";
describe("formatter/jsonFormatter", () => {
var formatter;
beforeEach(() => {
formatter = jasmine.formatter("jsonFormatter");
});
it("encodes a Buffer as base64", () => {
var buff, result;
buff = Buffer.from("abc", "binary");
result = formatter(buff);
... |
var ListFilter = Guirunt.View.extend({
_construct: function(nodeList) {
this.targets = [];
this.factory(nodeList);
this.genComponent();
},
factory: function(nodeList) {
var i = -1,
size = nodeList.length;
while ( nodeList[++i] ) ... |
import React from 'react';
import IconBase from './../components/IconBase/IconBase';
export default class IosCloudOutline extends React.Component {
render() {
if(this.props.bare) {
return <g>
<path d="M399.3,232.8c0-1.2,0.2-2.4,0.2-3.6c0-64.3-52.8-117.2-116.8-117.2c-46.1,0-85.8,27.9-104.4,67c-8.1-4.1-17.1-6.4-26.... |
'use strict';
Object.defineProperty(exports, "__esModule", {
value: true
});
var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("val... |
import Ember from 'ember';
import C3AbstractChart from './c3-abstract-chart';
import C3AbstractBidimensionalChartMixin from '../mixins/c3-abstract-bidimensional-chart-mixin';
export default C3AbstractChart.extend(C3AbstractBidimensionalChartMixin, {
getFormattedData() {
return this.bidimensionalChartDefaultForma... |
import App from '../App'
// 懒加载
export default [{
path: '/',
component: App,
children: [{
path: '/',
component: r => require.ensure([], () => r(require('../page/login/login.vue')), 'login')
},{
path: '/main',
component: r => require.ensure([], () => r(require('../page/mai... |
// local
import * as task_constants from '../task.constants';
export function tasks_text_filter (state = task_constants.DEFAULT_TEXT_FILTER_STATE, action) {
switch (action.type) {
case task_constants.ACTION_SET_TEXT_FILTER:
return action.value;
case task_constants.ACTION_RESET_TEXT_F... |
var hasValueHelper = require('../utils/hasValue.js')
var transformPathToArray = require('./../utils/transformPathToArray.js')
function validateHasValue (fieldPath) {
function action (context) {
var input = context.input
var state = context.state
var pathToField = transformPathToArray(fieldPath || input.f... |
import React from 'react';
import Component from './../Core/Component';
class Menu extends Component {
}
Menu.defaultProps = {
id: null,
label: null,
icon: null,
order: 100,
role: null,
route: null,
level: 0,
overwriteExisting: false,
apps: []
};
export default Menu; |
var url = require("url");
var path = require('path');
function route(handle, request, response, pool) {
var pathname = url.parse(request.url).pathname;
console.log("Request for " + pathname + " received.");
if (typeof handle[pathname] === 'function') {
handle[pathname](request, response, pool);
} else {
consol... |
'use strict';
var express = require('express'),
request = require('request'),
router = express.Router(),
datetime = require('../utils/datetime'),
maps = require('../maps'),
ex = require('../utils/error'),
OAuth = require('../utils/oauth');
/* GET status */
router.get('/... |
// Copyright 2015-2018 FormBucket LLC
import { ERRORTYPES as error } from "./error";
// Exact compares two values and only returns true if they meet strict equivalence.
export default function exact(a, b) {
return a === b;
}
|
import styled from "styled-components";
import { PropTypes } from "prop-types";
import { spacingScale } from "style/styleFunctions";
import { FONT_WEIGHT_SEMIBOLD } from "style/styleVariables";
const Runtime = styled.span`
color: ${props => props.cardFontColor};
font-weight: ${FONT_WEIGHT_SEMIBOLD};
text-align: ... |
/**************************************\
| JavaScript for jsCalculator |
| Peter Sim, November, 2017 |
\**************************************/
const MAXDIGITS = 14 // maximum number of digits to display
const DIGITS = '01234567890.'
const OPCODES = '+-*/% x2 sr pm'
const TIMES = '\u00D7'... |
import * as React from 'react';
import PropTypes from 'prop-types';
import clsx from 'clsx';
import withStyles from '../styles/withStyles';
import useTheme from '../styles/useTheme';
import capitalize from '../utils/capitalize';
export const styles = (theme) => {
return {
/* Styles applied to the root element. *... |
var Job = require('./job');
module.exports = {
crawl: function (baseUrl, options, handler, finish) {
var job = new Job(options, handler, finish);
job.crawl(baseUrl);
}
};
|
/**
* Created by samhwawng1990@gmail.com on 2017/1/3.
*/
"use strict";
const {
UserInfo: UserInfoDal,
UserPassword: UserPasswordDal
} = require('../../../libs/dal/index');
const PlanerError = require('../../../libs/utils/error');
const APIBase = require('../../../libs/modules/API/index');
function* createUser... |
var logger = require('../lib/logger');
var _ = require('underscore');
var Tile = require('../models/tile');
// ----------------------------------------------------------------------------
// constructor:
function Page(store, key, templateStore) {
logger.debug("Page::constructor: store =>", typeof(store), "; key =>"... |
module.exports = function (step, apitance) {
step.addDefinition('I send the request')
step.addDefinition('[I]? send the request')
step.addHandler(function (next) {
next()
})
}
|
(function (angular) {
'use strict';
angular.module('ac.tabloSync', [])
.directive('tabloSync', [function () {
return {
restrict: 'E',
replace: true,
templateUrl: '/assets/tablo_connect/ng_app/modules/tablo_sync/templates/tablo_sync.html',
controller: ['$scope',... |
exports.view = function(req, res) {
//console.log(data);
res.render('resources');
}; |
$(function(){
$("#file_table_element_rename").dialog({
autoOpen: false,
height: 135,
width: 350,
modal: true,
buttons: {
Cancel: function() { $(this).dialog('close'); },
Rename: function() {
$('#submit_button_rename').click();
$(this).dialog('close');
}
},
clo... |
var searchData=
[
['search_2ejs',['search.js',['../search_8js.html',1,'']]],
['searchdata_2ejs',['searchdata.js',['../searchdata_8js.html',1,'']]],
['sem_2ec',['sem.c',['../sem_8c.html',1,'']]],
['sem_2eh',['sem.h',['../sem_8h.html',1,'']]],
['separation_2ec',['separation.c',['../separation_8c.html',1,'']]],
... |
var functions_func =
[
[ "a", "functions_func.html", null ],
[ "b", "functions_func_b.html", null ],
[ "c", "functions_func_c.html", null ],
[ "d", "functions_func_d.html", null ],
[ "e", "functions_func_e.html", null ],
[ "f", "functions_func_f.html", null ],
[ "g", "functions_func_g.html",... |
'use strict';
/**
* Module dependencies.
*/
exports.index = function(req, res) {
res.render('index', {
user: req.user || null,
image: req.image || null,
request: req
});
}; |
// Load index.html in a regular window and display it
var size = { width: 600, height: 500 };
var win = App.createWindow({
uri: 'index.html',
// name: 'main',
rect: {
origin: {x: Math.floor((screen.width / 2) - (size.width / 2)) , y: Math.floor((screen.height / 2) - (size.height / 2)) + 50},
size: size
},
... |
version https://git-lfs.github.com/spec/v1
oid sha256:f58cfbba2d7ccf33578703d4dc017e9f7eac9d08ad8f4f52e00e8287dbeb3e53
size 4971
|
import React from 'react';
import { shallow } from 'enzyme';
import { TableHeader, TableHeaderItem } from '../../src/index';
describe('<TableHeader />', () => {
it('should render a table header div', () => {
const table = shallow(
<TableHeader>
<TableHeaderItem>Header Item</TableHeaderItem>
<... |
export default {
'name-placeholder': 'Attribute name',
'caption-placeholder': 'Attribute caption',
};
|
/* global describe, it, expect, beforeEach */
import React from "react";
import {shallow} from "enzyme";
import Rule from "./Rule";
import {ActionElement, ValueSelector, ValueEditor} from "./controls/index";
describe("<Rule />", () => {
let controls;
let classNames;
let schema;
let props;
beforeEach(() => {... |
// Copyright 2015 Bobby Powers. All rights reserved.
// Use of this source code is governed by the MIT
// license that can be found in the LICENSE file.
module.exports = require('bindings')('priority');
|
import React, {Component, PropTypes} from 'react';
import {getSelection, setSelection} from './domElementSelection';
import abstractNumberInput from './abstract-number-format-input/index';
export default class NumberFormatInput extends Component {
componentDidUpdate() {
if (this.nextSelection) setSelection(this.... |
// This is a manifest file that'll be compiled into application.js, which will include all the files
// listed below.
//
// Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
// or vendor/assets/javascripts of plugins, if any, can be referenced here using a relative pat... |
var mongoose = require('mongoose')
mongoose.Promise = global.Promise
const config = require('../config')
let connectionAttempts = 0
function connectAndRetry(logger){
connectionAttempts++
const mongoURI = `${config.mongo.host}/${config.mongo.db}`
const mongoOptions = config.mongo.options || {}
logger.... |
/**
* @overview datejs
* @version 1.0.0-rc3
* @author Gregory Wild-Smith <gregory@wild-smith.com>
* @copyright 2015 Gregory Wild-Smith
* @license MIT
* @homepage https://github.com/abritinthebay/datejs
*/
/*
2015 Gregory Wild-Smith
@license MIT
@homepage https://github.com/abritinthebay/datejs
2015 Gregory ... |
export { default } from 'ember-tumblr/components/tumblr-blog'; |
import getContactDisplayName from '../getContactDisplayName';
describe('getContactDisplayName', () => {
it('should render Firstname LASTNAME', () => {
const displayName = getContactDisplayName({firstname: 'John', lastname: 'Vamos'});
expect(displayName).toBe('John VAMOS');
});
it('should d... |
window.Threebox = require('./src/Threebox.js'),
window.THREE = require('./src/three.js')
|
"use strict";
var helpers = require("./helpers");
var Commands;
/**
* @module Commands
* @description Method for [Wrapper for AT&T M2X Commands API]{@link https://m2x.att.com/developer/documentation/v2/commands} endpoint.
* @param client {object}
* @constructor
*/
Commands = function(client) {
this.client =... |
/**
*
SQLQueryParser:
table: table-name
db: mysql-instance
auth(conn, record, done(err, authorized)): If authorized, message should get pushed to user, else not
preParser(conn, query, done(err, query)): Modifies query before running
SQLMutationParser:
table: table-name
keyField: primary-k... |
var fs=require('fs'),
parse = require('csv-parse'),
pd = require('pretty-data').pd,
_ = require('lodash'),
content = fs.readFileSync('input.csv', 'utf-8'),
nested = {},
parsed;
parse(content, function(err, output) {
parsed = output;
// slice to eliminate the first row, containing the CSV he... |
'use strict';
angular
.module('services')
.factory('DocumentService', ['$state', '_','$http','config','$q', DocumentService]);
function DocumentService($state, _, $http, config, $q) {
return {
list : List,
create : Create,
delete : Delete,
add : Add
};
function List(db_na... |
function turnObjIntoJSON(arr) {
let object = {};
for(let i =0; i<arr.length;i++){
let currentObject = arr[i].split(" -> ");
if(currentObject[1] == Number(currentObject[1])){
currentObject[1]=Number(currentObject[1]);
}
object[currentObject[0]]=currentObject[1];
}
... |
module.exports = function (grunt) {
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
jshint: {
jshintrc: '.jshintrc',
app: ['src/<%= pkg.name %>.js', 'example/*.js'],
gruntfile: ['Gruntfile.js']
},
clean: {
build: ['dist/*', 'example/dist/*'],
tmp: ['tmp']
},
useminPrepare: {... |
import Entity from './Entity';
/**
* @class Enemy
*
* @description base class for all game enemies
*
* @extends {Entity}
*/
export default class Attack extends Entity {
constructor(game, x, y, sprite, lives, speed, id) {
super(game, x, y, sprite, lives);
this.id = id;
this.speed = spee... |
version https://git-lfs.github.com/spec/v1
oid sha256:10d4923ace20ca5677aec62ed89f33e1565938feee97a4cdea403aae28fdb301
size 17341
|
var tweets;
var currentTweetIndex;
var totalTweets;
var timerTwitter;
$(function(){
$('.scroll-pane').jScrollPane();
bindEvents();
onScroll();
getTweets();
timerTwitter = setInterval(function() {
getTweets();
}, 60000);
$('#maps').bind('click', function() {
$('#comboDistricts').addCl... |
export class Database {
get info() {
return 'real database info';
}
};
|
var LocalPager = (function () {
function LocalPager() {
}
LocalPager.paginate = function (data, page, perPage) {
return data.slice(perPage * (page - 1), perPage * page);
};
return LocalPager;
}());
export { LocalPager };
//# sourceMappingURL=local.pager.js.map |
import _ from 'lodash';
let ArticleService = {};
ArticleService.loadArticle = function(quickstarts, payload) {
let {quickstartId, platformId, articleId, clientId} = payload;
let tokens = ['/docs'];
if (quickstartId) tokens.push(quickstarts[quickstartId].slug);
if (platformId) tokens.push(platformId);
... |
(function () {
'use strict';
var gulp = require('gulp');
module.exports = function () {
gulp.watch('./**/*.js', ['lint']);
};
}());
|
// Configuration for your app
const path = require('path')
module.exports = function (ctx) {
return {
// app boot file (/src/boot)
// --> boot files are part of "main.js"
boot: [
'components'
],
css: [
'app.sass'
],
extras: [
'roboto-font',
'material-icons'
]... |
SpotlightAssistant = Class.create(Whendle.Spotlight.View, {
SLIDE_FREQUENCY: 10,
initialize: function($super, id) {
$super();
this.presenter = new Whendle.Spotlight.Presenter(this);
this.id = id;
},
extent: function() {
var viewport = Mojo.View.getViewportDimensions(this.controller.document);
var heade... |
'use strict';
Object.defineProperty(exports, "__esModule", {
value: true
});
var _ora = require('ora');
var _ora2 = _interopRequireDefault(_ora);
var _chalk = require('chalk');
var _chalk2 = _interopRequireDefault(_chalk);
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: ob... |
/**
* Name: SVG handler
* Author: Graffino (http://www.graffino.com)
* Plugin: https://github.com/jonathantneal/svg4everybody
*/
Object.assign($graffino, {
svgHandler: {
name: 'svg-handler',
// Plugin options
options: {
hook: 'PLUGINS',
autoInit: true,
debug: false
},
// ... |
version https://git-lfs.github.com/spec/v1
oid sha256:9a18827cbcbc9142683fd4eab8fdfa79cd4850b151b459052ec906564129e321
size 876
|
describe('assessment: linkUsedForAlternateContent', function () {
var client, assessments, quailResults, cases;
// Evaluate the test page with Quail.
describe('the non-match case', function () {
before('load webdrivers and run evaluations with Quail', function () {
return quailTestRunner.setup({
... |
import jwt from 'jsonwebtoken'
import crypto from 'crypto'
import bcrypt from 'bcrypt-nodejs'
import fs from 'fs'
import path from 'path'
import getUser from '../helpers/get-user'
import User from '../models/userModel'
const { SECRET_TOKEN } = process.env
//
// check the username and password and returns token if ve... |
8.0-alpha3:c6c7931e9d246a88a24f3df5d4d5ba2e56a9cb7bf6f7e167cf00fd184ee5f99d
8.0-alpha4:c6c7931e9d246a88a24f3df5d4d5ba2e56a9cb7bf6f7e167cf00fd184ee5f99d
8.0-alpha5:c6c7931e9d246a88a24f3df5d4d5ba2e56a9cb7bf6f7e167cf00fd184ee5f99d
8.0-alpha6:c6c7931e9d246a88a24f3df5d4d5ba2e56a9cb7bf6f7e167cf00fd184ee5f99d
8.0-alpha7:c6c79... |
import React from "react";
import {connect} from "react-redux";
import {Link} from "react-router-dom";
// Home page component
class Home extends React.Component {
constructor(props){
super(props);
this.props.dispatch({type:"GET_SESSION"});
}
logout(){
this.props.dispatch({type:"USER_LOGOUT"});
}... |
var endOfLine = require('os').EOL;
var outputResult = function (status, results, errors, preventExit) {
process.stdout.write(status);
process.stdout.write(endOfLine);
if (!results) {
process.stdout.write("");
process.stdout.write(endOfLine);
}
else {
if (typeof results === ... |
openFarmApp.config([
'$locationProvider',
function($locationProvider) {
$locationProvider.html5Mode(false).hashPrefix('!');
},
]);
openFarmApp.controller('newGuideCtrl', [
'$scope',
'$http',
'$q',
'guideService',
'stageService',
'$location',
'localStorageService',
'alertsService',
'$rootSco... |
import {v2f, f2v} from './canvasUtils'
export function generateUuid() {
// https://github.com/GoogleChrome/chrome-platform-analytics/blob/master/src/internal/identifier.js
// const FORMAT: string = "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx";
let chars = "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".split("");
for... |
'use strict';
var KEY_CODES = require('./KEY_CODES');
var TEMPLATES = require('./TEMPLATES');
var templateUtils = require('./templateUtils');
var $ = require('jquery');
var _ = require('underscore');
var Mustache = require('Mustache');
var MicroEvent = require('./MicroEvent');
function createPopup(){
return $('<... |
var createServer = require("http").createServer;
var readFile = require("fs").readFile;
var sys = require("sys");
var url = require("url");
DEBUG = false;
var fu = exports;
var NOT_FOUND = "Not Found\n";
function notFound(req, res) {
res.writeHead(404, { "Content-Type": "text/plain"
, "Content... |
/* eslint-disable class-methods-use-this */
/**
* The executor class to be used with the @{Middleware}} class.
* This class implements Exectorable interface:
*
* interface Exectorable {
* isMatched(): Boolean
* exec(): Object
* }
*
*/
export default class Exector {
/**
* isMatching to be hooked up to... |
/* Use this old export style until sequelize cli supports es6 syntax */
function defaultExport() {}
defaultExport.DB_TYPES = {
POSTGRES: 'POSTGRES'
};
module.exports = defaultExport;
|
class Ground {
constructor(ctx, x) {
this.ctx = ctx;
this.x = x;
this.y = 540;
this.backgroundImage = new Image();
this.backgroundImage.src = '../assets/images/background.png';
}
get draw () {
this.ctx.drawImage(this.backgroundImage, this.x, this.y);
this.ctx.drawImage(this.background... |
var searchData=
[
['eftype',['EfType',['../class_politechnikon_1_1game__elements_1_1_item.html#a18a68c2635fc85bbe1c5bd72b01e9807',1,'Politechnikon::game_elements::Item']]],
['equipment',['Equipment',['../class_politechnikon_1_1game__elements_1_1_avatar.html#adad64e62c6625e74e90e1ad4c01f2a1d',1,'Politechnikon::game_... |
import * as actions from 'redux/actions'
export default async (
dispatch,
adjudicatorTest,
onChangeEdit,
pm,
dpm,
gw,
gr,
lo,
dlo,
ow,
or
) => {
let body = {
theme: adjudicatorTest.theme,
motion: adjudicatorTest.motion,
pm: pm,
dpm: dpm,
gw: gw,
gr: gr,
lo: lo,
d... |
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
*
* Code generated by Microsoft (R) AutoRest Code Generator 0.14.0.0
* Changes may cause incorrect behavior and will be lost if the code is
* regenerate... |
'use strict';
/* jshint loopfunc:true */
var EventEmitter = require('events').EventEmitter;
var util = require('util');
var redis = require('redis');
var consolelogger = require('./consolelogger');
var commands = require('./commands');
var StateManager = require('./statemanager');
var shardProxy = require('./shardprox... |
var kTAG_NID= '_id';
var kTAG_LID= '1';
var kTAG_GID= '2';
var kTAG_UID= '3';
var kTAG_PID= '4';
var kTAG_SYNONYMS= '5';
var kTAG_DOMAIN= '6';
var kTAG_AUTHORITY= '7';
var kTAG_CATEGORY= '8';
var kTAG_KIND= '9';
var kTAG_TYPE= '10';
var kTAG_CLASS= '11';
var kTAG_NAMESPACE= '12';
var kTAG_INPUT= '13';
var kTAG_PATTERN=... |
/*
* src/core/EventHandler.js
* Author: H.Alper Tuna <halpertuna@gmail.com>
* Date: 07.08.2016
*/
define(['./createClass'], function (createClass) {
/**
* EventHandler class.
* @class core/EventHandler
* @augments core/createClass
*/
return createClass(/** @lends core/EventHandler# */{
/*
... |
var variable = "value4";
if (variable == "value1") console.log("action1();");
else if (variable == "value2") console.log("action2();");
else if (variable == "value3") console.log("action3();");
else console.log("defaultAction();");
// -> defaultAction();
|
var util = require('util')
var Device = require('zetta-device')
var ShutterContact = module.exports = function (device, client) {
this.name = device.NAME
this.serialNumber = device.ADDRESS
this.model = device.TYPE
this._client = client
this._device = device
this.state = ''
const channel = this._device.C... |
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
/**
* 遷移プロセス管理
*
* @since 0.1.0
* @param name トランジション名
* @param process プロセス
*/
var PsycleTransition = /** @class */ (function () {
function PsycleTransition(name, process) {
this.name = name;
$.extend(this, process);... |
var request = require('request');
module.exports = function (opt) {
if (!opt) {
return Promise.reject(new Error('iso-request-core without input!'));
}
if (!opt.url) {
return Promise.reject(new Error('iso-request-core without url, input:' + JSON.stringify(opt)));
}
return new Promi... |
'use strict';
// définition de la classe Program
var Program = function()
{
this.pen = new Pen();
this.slate = new Slate(this.pen);
this.colorPalette = new ColorPalette();
};
// définition des méthodes
Program.prototype.onClickPenColor = function(event)
{
var buttonColor;
var penColor;
button... |
var express = require('express')
var router = express.Router()
var Datastore = require('nedb')
var settings = require('./../settings')
var documentFactory = require('./../src/document.js')
var db = new Datastore({ filename: settings.directory + 'meta.db', autoload: true })
router.get('/list', function(request, respo... |
const bitcoin = require('../../')
const { describe, it } = require('mocha')
const regtestUtils = require('./_regtest')
const NETWORK = regtestUtils.network
const keyPairs = [
bitcoin.ECPair.makeRandom({ network: NETWORK }),
bitcoin.ECPair.makeRandom({ network: NETWORK })
]
console.warn = () => {} // Silence the De... |
const _ = require('lodash');
const os = require('os');
const path = require('path');
const fs = require('fs');
const sf = require('sf');
const tar = require('tar-fs');
const net = require('net');
function getHostIp() {
const ip = _.chain(os.networkInterfaces())
.values()
.flatten()
.filter((val) => (val.... |
(function(){
'use strict';
manu.getLength = function(){
return this.logger.get('length');
};
})();
|
var clv = require("../../../../index.js");
var assert = require("assert");
describe("Generated test - ins/ins/ins/ins/undo/ins/rm/rm/rm/ins - 10-ops-0dd56d19-2670-4427-b85d-59be0b2d59bb", function() {
var doc1 = new clv.string.Document("3c0a00d0-537f-11e7-a68f-cd2ea9e90d51", 0, null);
var doc2 = new clv.string.Doc... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.