text:
"use strict";
/*******************
 * App
 * Main bot process
 *******************/

const Discord = require("discord.js");
const fs = require('fs');

// First check if our config file exists
if (!fs.existsSync('./config.js')) {
    console.log('No config found! Generating one with the default options.');
    fs.writeFileSync("./config.js", fs.readFileSync('./config-example.js'));
}

// Check if perms file exists
if (!fs.existsSync('./perms.json')) {
    console.log('Perms.json doesn\'t exist. Creating one with default settings.');
    fs.writeFileSync('./perms.json', JSON.stringify({"broadcast": [], "mod": [], "admin": []}));
}

//create the bot object
const bot = exports.bot = new Discord.Client();
//Load up our globals
global.Config = require('./config.js');
global.Tools = require('./tools.js');
//Require the command parser
const commandParser = require('./command-parser.js');

try {
    if (Config.token) {
        console.log('Bot token specified. Logging in...');
        bot.login(Config.token);
    } else {
        console.log('No token specified. Logging into a user account...');
        bot.login(Config.email, Config.password);
    }
} catch (e) {
    console.log('The login failed! Error message:\n' + e);
    process.exit(1);
}

bot.on("ready", () => {
    console.log('Bot succesfully connected! Awaiting commands.');
});

// Listen for messages
bot.on("message", (msg) => {
    let dm = false;
    let user = msg.member || msg.user || msg.author;
    if (user && user.bot) return;
    if (msg.channel.type === 'dm') { //Simple DM check
        //user = msg.author;
        dm = true;
    }
    let roles = user.roles || {};
    commandParser.parseMsg(user, roles, msg.channel, msg.content, dm);
});

// Close our process when we disconnect
bot.on("disconnected", () => {
    console.log("The bot has been disconnected! Exiting...");
	process.exit(1);

});


text:
using content::BrowserThread;

namespace component_updater {

namespace {

///////////////////////////////////////////////////////////////////////////////
// In charge of blocking url requests until the |crx_id| component has been
// updated. This class is touched solely from the IO thread. The UI thread
// can post tasks to it via weak pointers. By default the request is blocked
// unless the CrxUpdateService calls Unblock().
// The lifetime is controlled by Chrome's resource loader so the component
// updater cannot touch objects from this class except via weak pointers.
class CUResourceThrottle : public content::ResourceThrottle,
                           public base::SupportsWeakPtr<CUResourceThrottle> {
 public:
  CUResourceThrottle();
  virtual ~CUResourceThrottle();

  // Overriden from ResourceThrottle.
  virtual void WillStartRequest(bool* defer) OVERRIDE;
  virtual void WillRedirectRequest(const GURL& new_url, bool* defer) OVERRIDE;
  virtual const char* GetNameForLogging() const OVERRIDE;

  // Component updater calls this function via PostTask to unblock the request.
  void Unblock();

  typedef std::vector<base::WeakPtr<CUResourceThrottle> > WeakPtrVector;

 private:
  enum State { NEW, BLOCKED, UNBLOCKED };

  State state_;
};

CUResourceThrottle::CUResourceThrottle() : state_(NEW) {
  DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
}

CUResourceThrottle::~CUResourceThrottle() {
  DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
}

void CUResourceThrottle::WillStartRequest(bool* defer) {
  if (state_ != UNBLOCKED) {
    state_ = BLOCKED;
    *defer = true;
  } else {
    *defer = false;
  }
}

void CUResourceThrottle::WillRedirectRequest(const GURL& new_url, bool* defer) {
  WillStartRequest(defer);
}

const char* CUResourceThrottle::GetNameForLogging() const {
  return "ComponentUpdateResourceThrottle";
}

void CUResourceThrottle::Unblock() {
  DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
  if (state_ == BLOCKED)
    controller()->Resume();
  state_ = UNBLOCKED;
}

void UnblockThrottleOnUIThread(base::WeakPtr<CUResourceThrottle> rt) {
  BrowserThread::PostTask(BrowserThread::IO,
                          FROM_HERE,
                          base::Bind(&CUResourceThrottle::Unblock, rt));
}

}  // namespace

content::ResourceThrottle* GetOnDemandResourceThrottle(
    ComponentUpdateService* cus,
    const std::string& crx_id) {
  DCHECK_CURRENTLY_ON(BrowserThread::IO);

  // We give the raw pointer to the caller, who will delete it at will
  // and we keep for ourselves a weak pointer to it so we can post tasks
  // from the UI thread without having to track lifetime directly.
  CUResourceThrottle* rt = new CUResourceThrottle;
  BrowserThread::PostTask(
      BrowserThread::UI,
      FROM_HERE,
      base::Bind(&ComponentUpdateService::MaybeThrottle,
                 base::Unretained(cus),
                 crx_id,
                 base::Bind(&UnblockThrottleOnUIThread, rt->AsWeakPtr())));
  return rt;
}

}  // namespace component_updater

redpajama_set_name: RedPajamaGithub


text:
<!DOCTYPE html>

        <title>FGC DESIGNS | Resume </title>

        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">
        <meta http-equiv="X-UA-Compatible" content="IE=edge">

        <link rel="stylesheet" href="assets/css/bootstrap.min.css">
        <link rel="stylesheet" href="assets/css/font-awesome.min.css">
        <link rel="stylesheet" href="assets/css/animate.css">
        <link rel="stylesheet" href="assets/css/owl.carousel.css">
        <link rel="stylesheet" href="assets/css/owl.theme.css">
        <link rel="stylesheet" href="assets/css/style.css">

                        <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#main-nav-collapse">
                            Toggle navigation

                        </button>

                            FGC Designs

                                Home

                                Portfolio

                                Services

                                         Graphic Design

                                        Web Design

                                        Social Media Management

                                        Tutoring

                                About

                                Contact

home

resume

Fabiana Gautier Cuenca's Resume

					<embed src="fgc/FGC_Resume.pdf" width="800px" height="850px" />

Useful Links

Resume

Instagram

Resume

Portfolio

Recent News

                                                Just got accepted to Ironhack Miami  and won the Facebook Scholarship for Web Development Bootcamp! Starting on August 19.

Jun 13, 2019

E-News-Letter

Sign up for our mailing list to get latest updates and offers

                                <input class="form-control" type="text" placeholder="Email address">

We respect your privacy

FGC Designs

                                Graphic Design, Web Design, Social Media Management and more.

                                    @fgcdesigns

                                    fagautiercuenca@gmail.com

                            ©FGC Desings

                                ©FGC Designs | By: Fabiana Gautier Cuenca


text:
from __future__ import print_function

import numpy
import time
from scipy.sparse import csr_matrix
from itertools import chain
from collections import OrderedDict

import kernel_tuner

def tune():
    with open('spmv.cu', 'r') as f:
        kernel_string = f.read()

    nrows = numpy.int32(128*1024)
    ncols = 64*1024
    nnz = int(nrows*ncols*0.001)
    #problem_size = (nrows, 1)
    problem_size = nrows

    #generate sparse matrix in CSR
    rows = numpy.asarray([0]+sorted(numpy.random.rand(nrows-1)*nnz)+[nnz]).astype(numpy.int32)
    cols = (numpy.random.rand(nnz)*ncols).astype(numpy.int32)
    vals = numpy.random.randn(nnz).astype(numpy.float32)

    #input and output vector  (y = matrix * x)
    x = numpy.random.randn(ncols).astype(numpy.float32)
    y = numpy.zeros(nrows).astype(numpy.float32)

    args = [y, rows, cols, vals, x, nrows]

    tune_params = OrderedDict()
    tune_params["block_size_x"] = [32*i for i in range(1,33)]
    tune_params["threads_per_row"] = [1, 32]
    tune_params["read_only"] = [0, 1]

    grid_div_x = ["block_size_x/threads_per_row"]

    #compute reference answer using scipy.sparse
    row_ind = list(chain.from_iterable([[i] * (rows[i+1]-rows[i]) for i in range(nrows)]))
    matrix = csr_matrix((vals, (row_ind, cols)), shape=(nrows, ncols))
    start = time.time()
    expected_y = matrix.dot(x)
    end = time.time()
    print("computing reference using scipy.sparse took: " + str(start-end / 1000.0) + " ms.")

    answer = [expected_y, None, None, None, None, None]

    return kernel_tuner.tune_kernel("spmv_kernel", kernel_string,
        problem_size, args, tune_params,
        grid_div_x=grid_div_x, verbose=True, answer=answer, atol=1e-4)

if __name__ == "__main__":
    tune()


text:
montyhallproblem
================

a website to prove the solution to monty hall problem


text:
//package cmwell.ctrl.checkers
//
//import java.io.File
//import java.nio.ByteBuffer
//import java.nio.file.{Files, Paths}
//import java.util.concurrent.atomic.AtomicLong
//
//import cmwell.ctrl.config.{Config, Jvms}
//import com.typesafe.scalalogging.LazyLogging
//import k.grid.{Grid, GridJvm}
//
//import scala.concurrent.Future
//import scala.concurrent.duration._
//import akka.pattern.ask
//import akka.util.Timeout
//import cmwell.ctrl.config.Config._
//import cmwell.ctrl.utils.ProcUtil
//import k.grid.dmap.api.SettingsLong
//import k.grid.dmap.impl.persistent.PersistentDMap
//
//import scala.concurrent.ExecutionContext.Implicits.global
//import scala.util.Try
//
///**
//  * Created by michael on 7/31/16.
//  */
//
//case object GetLastWroteIndexCommandsOffset
//case class LastWroteIndexCommandsOffset(offset:Long)
//
//case class BgStateReporter(topicName : String, partition : Int) {
//
//  var lastReported = 0L
//  var l : AtomicLong = new AtomicLong()
//
//  def set(longVal: Long) = l.set(longVal)
//
//
//  if(Grid.system != null)
//    Grid.system.scheduler.schedule(0.seconds, 5.seconds) {
//      val valueToReport = l.get()
//      if(lastReported != valueToReport) {
//        PersistentDMap.set(s"cmwell.bg.write.$topicName.$partition", SettingsLong(valueToReport))
//        lastReported = valueToReport
//      }
//    }
//}
//
//object BgStateReporter {
//  var m = Map.empty[(String, Int), BgStateReporter]
//  def report(topicName : String, partition : Int, value : Long): Unit = {
//    m.get(topicName, partition) match {
//      case Some(bsr@BgStateReporter(_,_)) =>
//        bsr.set(value)
//      case None =>
//        val bsr = BgStateReporter(topicName, partition)
//        bsr.set(value)
//        m = m.updated((topicName, partition), bsr)
//    }
//  }
//}
//
//object BgChecker extends Checker with LazyLogging {
//  implicit val timeout = Timeout(3 seconds)
//  import collection.JavaConverters._
//  lazy val persistPartition = getPartition("persist_topic")
//  lazy val indexPartition = getPartition("index_topic")
//
//  case class BgData(wsWrite : Long, wsRead : Long, idxWrite : Long, idxRead : Long)
//
//
//  def getPartition(name : String) : Int = {
//    val location = Config.cmwellHome + "/app/bg/"
//    val dir = new File(location)
//    dir.listFiles().toVector.find(_.getName.contains(name)) match {
//      case Some(f) =>
//        val name = f.getName
//        Try(name.split("-|\\.")(1).toInt).getOrElse(-1)
//      case None => -1
//    }
//  }
//
//  def getReadPosition(name : String) : Long = {
//    val location = Config.cmwellHome + "/app/bg/"
//    val dir = new File(location)
//    dir.listFiles().toVector.find(_.getName.contains(name)) match {
//      case Some(f) =>
//        val fullPath = f.getAbsolutePath
//        val readBuffer = ByteBuffer.allocate(8)
//        val readChnl = Files.newByteChannel(Paths.get(fullPath))
//        readChnl.read(readBuffer)
//        readChnl.close()
//        readBuffer.flip()
//        readBuffer.getLong - 1L
//      case None =>
//        logger.error(s"Couldn't find the topic $name read position file in $location.")
//        0L
//    }
//
//
//
//
//  }
//
//  def getWsWritePosition : Future[Long] = {
//    //Grid.selectActor("")
//    (Grid.selectActor("WebWriteMonitor", GridJvm(Jvms.WS)) ? GetLastWroteIndexCommandsOffset).mapTo[LastWroteIndexCommandsOffset].map(_.offset)
//  }
//
//  def getIndexerWritePosition : Future[Long] = {
//    (Grid.selectActor("CMWellBGActor", GridJvm(Jvms.BG)) ? GetLastWroteIndexCommandsOffset).mapTo[LastWroteIndexCommandsOffset].map(_.offset)
//  }
//
//  def getBgData : Future[BgData] = {
//
////
////    for {
////      wsWritePos <- getWsWritePosition
////      idxWritePos <- getIndexerWritePosition
////    } yield {
////      val wsReadPos = getReadPosition("persist_topic")
////      val idxReadPos = getReadPosition("index_topic")
////
////      BgData(wsWritePos, wsReadPos, idxWritePos, idxReadPos)
////    }
//
//    val wsReadPos = getReadPosition("persist_topic")
//    val idxReadPos = getReadPosition("index_topic")
//
//    val wsWritePos = PersistentDMap.get(s"cmwell.bg.write.persist_topic.$persistPartition").flatMap(_.as[SettingsLong]).map(_.lng).getOrElse(0L)
//    val idxWritePos = PersistentDMap.get(s"cmwell.bg.write.index_topic.$indexPartition").flatMap(_.as[SettingsLong]).map(_.lng).getOrElse(0L)
//
//    Future.successful(BgData(wsWritePos, wsReadPos, idxWritePos, idxReadPos))
//  }
//
//  override def check: Future[ComponentState] = {
//
//    if(ProcUtil.checkIfProcessRun("bg") > 0) {
//      val lastState = getLastStates(1).headOption
//      val newState = lastState match {
//        case Some(cs : BatchState) =>
//          getBgData.map {
//            bgData =>
//              if(cs.isIndexing(bgData.wsWrite , bgData.wsRead , bgData.idxWrite , bgData.idxRead))
//                BatchOk(bgData.wsWrite , bgData.wsRead , bgData.idxWrite , bgData.idxRead, (bgData.wsRead - cs.impLocation) / (batchSampleInterval / 1000), (bgData.idxRead - cs.indexerLocation) / (batchSampleInterval / 1000))
//              else
//                BatchNotIndexing(bgData.wsWrite , bgData.wsRead , bgData.idxWrite , bgData.idxRead)
//          }
//
//        case None => getBgData.map(bgData => BatchOk(bgData.wsWrite , bgData.wsRead , bgData.idxWrite , bgData.idxRead))
//        case _ =>
//          logger.error("Wrong ComponentStatus is in BatchStates!")
//          getBgData.map(bgData => BatchOk(bgData.wsWrite , bgData.wsRead , bgData.idxWrite , bgData.idxRead))
//      }
//      newState
//    } else{
//      getBgData.map {
//        bgData => BatchDown(bgData.wsWrite , bgData.wsRead , bgData.idxWrite , bgData.idxRead)
//      }
//    }
//  }
//}


text:
#ifndef TENSORFLOW_LITE_DELEGATES_GPU_COMMON_TASK_WEIGHTS_LAYOUT_H_
#define TENSORFLOW_LITE_DELEGATES_GPU_COMMON_TASK_WEIGHTS_LAYOUT_H_

#include <vector>

namespace tflite {
namespace gpu {

enum class WeightsLayout {
  kUnknown,
  // Spatial is DHW/HW depending on amount of spatial dimensions (Depth, Height,
  // Width).
  kOSpatialIOGroupI4O4,
  kOSpatialIOGroupO4I4,
  kOICustomSpatialI4O4,
  kOICustomSpatialO4I4,
  k2DX4I4YIsSpatialIAndXIsOOGroupO4,
  k2DX4O4YIsSpatialIAndXIsOOGroupI4,
};

struct WeightsDescription {
  WeightsLayout layout;
  // applicable with layouts that have OGroup.
  int output_group_size;  // OGroup size
  // applicable with layouts that have CustomSpatial
  std::vector<int> spatial_remap;

  int GetOutputGroupSize() const;
  bool IsI4O4() const;
  bool IsO4I4() const;
};

}  // namespace gpu
}  // namespace tflite

#endif  // TENSORFLOW_LITE_DELEGATES_GPU_COMMON_TASK_WEIGHTS_LAYOUT_H_


text:
SYNONYM

#### According to
The Catalogue of Life, 3rd January 2011

#### Published in
N. Amer. Fl. (New York) 9(2): 101 (1908)

#### Original name
Trametes fumosoavellanea Romell, 1901

### Remarks
null


text:
package azkaban.dag;

import static org.assertj.core.api.Assertions.assertThat;

import java.util.ArrayList;
import java.util.List;
import javafx.util.Pair;

/**
 * Records the sequence of nodes and dag status change.
 */
class StatusChangeRecorder {

  private final List<Pair<String, Status>> sequence = new ArrayList<>();

  void recordNode(final Node node) {
    this.sequence.add(new Pair<>(node.getName(), node.getStatus()));
  }

  void recordDag(final Dag dag) {
    this.sequence.add(new Pair<>(dag.getName(), dag.getStatus()));
  }

  void verifySequence(final List<Pair<String, Status>> expectedSequence) {
    assertThat(this.sequence).isEqualTo(expectedSequence);
  }
}


text:
<?php

namespace JustBlackBird\HandlebarsHelpers\Tests\Layout;

use JustBlackBird\HandlebarsHelpers\Layout\BlockStorage;

/**
 * Test class for BlockStorage.
 *
 * @author Dmitriy Simushev <simushevds@gmail.com>
 */
class BlockStorageTest extends \PHPUnit_Framework_TestCase
{
    /**
     * Tests basic operations with storage.
     */
    public function testBasicOperations()
    {
        $storage = new BlockStorage();
        $this->assertFalse($storage->has('test'));
        $storage->set('test', 'content');
        $this->assertTrue($storage->has('test'));
        $this->assertEquals($storage->get('test'), 'content');
        $storage->set('test', 'another content');
        $this->assertEquals($storage->get('test'), 'another content');
        $storage->remove('test');
        $this->assertFalse($storage->has('test'));
        $storage->set('test', 'content');
        $storage->set('another_test', 'content');
        $storage->clear();
        $this->assertFalse($storage->has('test'));
        $this->assertFalse($storage->has('another_test'));
    }
}


text:
using System;
using System.Text;
using System.Collections.Generic;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using Common.Interfaces.DA;
using Common.Data;
using Common.Interfaces.BL;

namespace BL.Test
{
    /// <summary>
    /// Summary description for TradeEngineDataTest
    /// </summary>
    [TestClass]
    public class TradeEngineDataTest
    {
        public TradeEngineDataTest()
        {
            //
            // TODO: Add constructor logic here
            //
        }

        private TestContext testContextInstance;

        /// <summary>
        ///Gets or sets the test context which provides
        ///information about and functionality for the current test run.
        ///</summary>
        public TestContext TestContext
        {
            get
            {
                return testContextInstance;
            }
            set
            {
                testContextInstance = value;
            }
        }

        #region Additional test attributes
        //
        // You can use the following additional attributes as you write your tests:
        //
        // Use ClassInitialize to run code before running the first test in the class
        // [ClassInitialize()]
        // public static void MyClassInitialize(TestContext testContext) { }
        //
        // Use ClassCleanup to run code after all tests in a class have run
        // [ClassCleanup()]
        // public static void MyClassCleanup() { }
        //
        // Use TestInitialize to run code before running each test
        // [TestInitialize()]
        // public void MyTestInitialize() { }
        //
        // Use TestCleanup to run code after each test has run
        // [TestCleanup()]
        // public void MyTestCleanup() { }
        //
        #endregion

        //[TestMethod]
        //public void TestMethod1()
        //{
        //    ILazyActionManager lam = new LamMock();
        //    TradeEngineData ted = new TradeEngineData(null, lam);

        //    ted.AddOrder(DateTime.Today, 1, Common.BuySell.Buy, 1, null, Common.OrderStatus.Active, null);
        //    ted.AddOrder(DateTime.Today, 1, Common.BuySell.Buy, 1, null, Common.OrderStatus.Active, null);
        //}
    }

    internal class AccountDAMock : IAccountDA
    {
        public void DeleteAccountData(int accountID)
        {
            throw new NotImplementedException();
        }

        public Account GetAccountByID(int accountID)
        {
            throw new NotImplementedException();
        }

        public IEnumerable<Account> GetAccounts()
        {
            throw new NotImplementedException();
        }

        public IEnumerable<Cash> GetCashes(int accountID)
        {
            throw new NotImplementedException();
        }

        public IEnumerable<Cashflow> GetCashflows(int accountID)
        {
            throw new NotImplementedException();
        }

        public IEnumerable<Holding> GetHoldings(int accountID)
        {
            throw new NotImplementedException();
        }

        public IEnumerable<Order> GetOrders(int accountID)
        {
            throw new NotImplementedException();
        }

        public IEnumerable<StopOrder> GetStopOrders(int accountID)
        {
            throw new NotImplementedException();
        }

        public IEnumerable<Trade> GetTrades(int accountID)
        {
            throw new NotImplementedException();
        }

        public int InsertAccount(Account account)
        {
            throw new NotImplementedException();
        }

        public int InsertCash(Cash cash)
        {
            throw new NotImplementedException();
        }

        public int InsertCashflow(Cashflow cashflow)
        {
            throw new NotImplementedException();
        }

        public int InsertHolding(Holding holding)
        {
            throw new NotImplementedException();
        }

        public int InsertOrder(Order order)
        {
            throw new NotImplementedException();
        }

        public int InsertStopOrder(StopOrder stopOrder)
        {
            throw new NotImplementedException();
        }

        public int InsertTrade(Trade trade)
        {
            throw new NotImplementedException();
        }

        public void UpdateAccount(Account account)
        {
            throw new NotImplementedException();
        }

        public void UpdateCash(Cash cash)
        {
            throw new NotImplementedException();
        }

        public void UpdateHolding(Holding holding)
        {
            throw new NotImplementedException();
        }

        public void UpdateOrder(Order order)
        {
            throw new NotImplementedException();
        }

        public void UpdateStopOrder(StopOrder stopOrder)
        {
            throw new NotImplementedException();
        }
    }

    internal class LamMock : ILazyActionManager
    {
        public void AddAction(Action action)
        {
        }

        public void AddAction(object tag, Action action)
        {
        }

        public void DoActions()
        {
        }
    }
}


text:
import { Geometric3 } from "@geometryzen/multivectors";
import { Force } from "../core/Force";
import { ForceBody } from "../core/ForceBody";

/**
 *
 */
export class Force3 extends Force<Geometric3> {
    constructor(body: ForceBody<Geometric3>) {
        super(body);
    }
}


text:
#include "../../../../include/BP-Main.h"

// BP_PromiseDefaultRequestHandler defined here is used as a default handler for handling
// promisary requests.
BP_HTTPD_DECLARE_ACCESS_HANDLER_CALLBACK (BP_PromiseDefaultRequestHandler )
{

	// run basic prologue
	BP_REQUEST_HANDLER_BASIC_PROLOGUE;

    // attempt setup of request (required for all secure requests)
    BP_ERROR_T req_setup_result = BP_HTTPDRequestHandlerSecureAuthEntrySetupJSON(BP_HTTPD_ACCESS_HANDLER_PARAMS);
    if(!req_setup_result)
            return ERR_FAILURE;

    // ensure we have a httpd
    if(!req->httpd)
    	return ERR_FAILURE;

    /*
     *
     * TOMORROW MORNING RETURN HERE:
     *   - We need to get a hook into a running event system.
     *   - We need to determine the request query syntax by parsing json.
     *   - We need to create a new promise.
     *   - We need to route the promise to a request fufilment engine by adding an event.
     *   - We need to create an event addition reciept for the promise.
     *   - Send the reciept back to the JS UI.
     *
     */

	// return indicating success
	return ERR_SUCCESS;

}

// %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
// %%% Peer Reciept Handlers %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
// %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

// TODO: Build out peer-reciept handlers (peers request reciept tables between hosts for easier spread pickup)
BP_HTTPD_DECLARE_ACCESS_HANDLER_CALLBACK(BP_PromiseAbsorbRemotePromiseReciepts)
{

	// run basic prologue
	BP_REQUEST_HANDLER_BASIC_PROLOGUE;

	// attempt setup of request (required for all secure requests)
	BP_ERROR_T req_setup_result = BP_HTTPDRequestHandlerSecureAuthEntrySetupJSON(BP_HTTPD_ACCESS_HANDLER_PARAMS);
	if(!req_setup_result)
			return ERR_FAILURE;

	// return indicating success
	return ERR_SUCCESS;

}


text:
===============================================================================

Copyright (C) 2007-10 Asko Kauppi <akauppi@gmail.com>
Copyright (C) 2010-13 Benoit Germain <bnt.germain@gmail.com>

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.

===============================================================================
]]--

-- Lua 5.1: module() creates a global variable
-- Lua 5.2: module() is gone
-- almost everything module() does is done by require() anyway
-- -> simply create a table, populate it, return it, and be done
local lanes = {}

lanes.configure = function( _params)

	-- This check is for sublanes requiring Lanes
	--
	-- TBD: We could also have the C level expose 'string.gmatch' for us. But this is simpler.
	--
	if not string then
		error( "To use 'lanes', you will also need to have 'string' available.", 2)
	end

	--
	-- Cache globals for code that might run under sandboxing
	--
	local assert = assert
	local string_gmatch = assert( string.gmatch)
	local select = assert( select)
	local type = assert( type)
	local pairs = assert( pairs)
	local tostring = assert( tostring)
	local error = assert( error)

	local default_params =
		{
			nb_keepers = 1,
			on_state_create = nil,
			shutdown_timeout = 0.25,
			with_timers = true,
			track_lanes = nil,
			verbose_errors = false,
			-- LuaJIT provides a thread-unsafe allocator by default, so we need to protect it when used in parallel lanes
			protect_allocator = (jit and jit.version) and true or false
		}
	local param_checkers =
		{
			nb_keepers = function( _val)
				-- nb_keepers should be a number > 0
				return type( _val) == "number" and _val > 0
			end,
			with_timers = function( _val)
				-- with_timers may be nil or boolean
				if _val then
					return type( _val) == "boolean"
				else
					return true -- _val is either false or nil
				end
			end,
			protect_allocator = function( _val)
				-- protect_allocator may be nil or boolean
				if _val then
					return type( _val) == "boolean"
				else
					return true -- _val is either false or nil
				end
			end,
			on_state_create = function( _val)
				-- on_state_create may be nil or a function
				return _val and type( _val) == "function" or true
			end,
			shutdown_timeout = function( _val)
				-- shutdown_timeout should be a number >= 0
				return type( _val) == "number" and _val >= 0
			end,
			track_lanes = function( _val)
				-- track_lanes may be nil or boolean
				return _val and type( _val) == "boolean" or true
			end,
			verbose_errors = function( _val)
				-- verbose_errors may be nil or boolean
				if _val then
					return type( _val) == "boolean"
				else
					return true -- _val is either false or nil
				end
			end
		}

	local params_checker = function( _params)
		if not _params then
			return default_params
		end
		if type( _params) ~= "table" then
			error( "Bad parameter #1 to lanes.configure(), should be a table")
		end
		-- any setting not present in the provided parameters takes the default value
		for key, value in pairs( default_params) do
			local my_param = _params[key]
			local param
			if my_param ~= nil then
				param = my_param
			else
				param = default_params[key]
			end
			if not param_checkers[key]( param) then
				error( "Bad " .. key .. ": " .. tostring( param), 2)
			end
			_params[key] = param
		end
		return _params
	end

	_params = params_checker( _params)

	local core = require "lanes.core"
	assert( type( core)=="table")

	-- configure() is available only the first time lanes.core is required process-wide, and we *must* call it to have the other functions in the interface
	if core.configure then core.configure( _params.nb_keepers, _params.on_state_create, _params.shutdown_timeout, _params.track_lanes, _params.protect_allocator, _params.verbose_errors) end

	local thread_new = assert( core.thread_new)

	local set_singlethreaded = assert( core.set_singlethreaded)

	local max_prio = assert( core.max_prio)

	lanes.ABOUT=
		{
			author= "Asko Kauppi <akauppi@gmail.com>, Benoit Germain <bnt.germain@gmail.com>",
			description= "Running multiple Lua states in parallel",
			license= "MIT/X11",
			copyright= "Copyright (c) 2007-10, Asko Kauppi; (c) 2011-12, Benoit Germain",
			version = assert( core.version)
		}

	-- Making copies of necessary system libs will pass them on as upvalues;
	-- only the first state doing "require 'lanes'" will need to have 'string'
	-- and 'table' visible.
	--
	local function WR(str)
		io.stderr:write( str.."\n" )
	end

	local function DUMP( tbl )
		if not tbl then return end
		local str=""
		for k,v in pairs(tbl) do
			str= str..k.."="..tostring(v).."\n"
		end
		WR(str)
	end

	---=== Laning ===---

	-- lane_h[1..n]: lane results, same as via 'lane_h:join()'
	-- lane_h[0]:    can be read to make sure a thread has finished (always gives 'true')
	-- lane_h[-1]:   error message, without propagating the error
	--
	--      Reading a Lane result (or [0]) propagates a possible error in the lane
	--      (and execution does not return). Cancelled lanes give 'nil' values.
	--
	-- lane_h.state: "pending"/"running"/"waiting"/"done"/"error"/"cancelled"
	--
	-- Note: Would be great to be able to have '__ipairs' metamethod, that gets
	--      called by 'ipairs()' function to custom iterate objects. We'd use it
	--      for making sure a lane has ended (results are available); not requiring
	--      the user to precede a loop by explicit 'h[0]' or 'h:join()'.
	--
	--      Or, even better, 'ipairs()' should start valuing '__index' instead
	--      of using raw reads that bypass it.
	--
	-----
	-- lanes.gen( [libs_str|opt_tbl [, ...],] lane_func ) ( [...] ) -> h
	--
	-- 'libs': nil:     no libraries available (default)
	--         "":      only base library ('assert', 'print', 'unpack' etc.)
	--         "math,os": math + os + base libraries (named ones + base)
	--         "*":     all standard libraries available
	--
	-- 'opt': .priority:  int (-2..+2) smaller is lower priority (0 = default)
	--
	--	      .cancelstep: bool | uint
	--            false: cancellation check only at pending Linda operations
	--                   (send/receive) so no runtime performance penalty (default)
	--            true:  adequate cancellation check (same as 100)
	--            >0:    cancellation check every x Lua lines (small number= faster
	--                   reaction but more performance overhead)
	--
	--        .globals:  table of globals to set for a new thread (passed by value)
	--
	--        .required:  table of packages to require
	--        ... (more options may be introduced later) ...
	--
	-- Calling with a function parameter ('lane_func') ends the string/table
	-- modifiers, and prepares a lane generator. One can either finish here,
	-- and call the generator later (maybe multiple times, with different parameters)
	-- or add on actual thread arguments to also ignite the thread on the same call.

	local valid_libs=
		{
			["package"] = true,
			["table"] = true,
			["io"] = true,
			["os"] = true,
			["string"] = true,
			["math"] = true,
			["debug"] = true,
			["bit32"] = true, -- Lua 5.2 only, ignored silently under 5.1
			--
			["base"] = true,
			["coroutine"] = true, -- part of "base" in Lua 5.1
			["lanes.core"] = true
		}

	-- PUBLIC LANES API
	local function gen( ... )
		local opt= {}
		local libs= nil
		local lev= 2  -- level for errors

		local n= select('#',...)

		if n==0 then
			error( "No parameters!" )
		end

		for i=1,n-1 do
			local v= select(i,...)
			if type(v)=="string" then
				libs= libs and libs..","..v or v
			elseif type(v)=="table" then
				for k,vv in pairs(v) do
					opt[k]= vv
				end
			elseif v==nil then
			-- skip
			else
				error( "Bad parameter: "..tostring(v) )
			end
		end

		local func= select(n,...)
		local functype = type(func)
		if functype ~= "function" and functype ~= "string" then
			error( "Last parameter not function or string: "..tostring(func))
		end

		-- Check 'libs' already here, so the error goes in the right place
		-- (otherwise will be noticed only once the generator is called)
		-- "*" is a special case that doesn't require individual checking
		--
		if libs and libs ~= "*" then
			local found = {}
			-- check that the caller only provides reserved library names
			for s in string_gmatch(libs, "[%a%d.]+") do
				if not valid_libs[s] then
					error( "Bad library name: " .. s)
				else
					found[s] = (found[s] or 0) + 1
					if found[s] > 1 then
						error( "libs specification contains '" .. s .. "' more than once")
					end
				end
			end
		end

		local prio, cs, g_tbl, package_tbl, required

		for k,v in pairs(opt) do
			if k=="priority" then prio= v
			elseif k=="cancelstep" then
				cs = (v==true) and 100 or
					(v==false) and 0 or
					type(v)=="number" and v or
					error( "Bad cancelstep: "..tostring(v), lev )
			elseif k=="globals" then g_tbl= v
			elseif k=="package" then
				package_tbl = (type( v) == "table") and v or error( "Bad package: " .. tostring( v), lev)
			elseif k=="required" then
				required= (type( v) == "table") and v or error( "Bad 'required' option: expecting table, got " .. type( v), lev)
				--..
			elseif k==1 then error( "unkeyed option: ".. tostring(v), lev )
			else error( "Bad option: ".. tostring(k), lev )
			end
		end

		if not package_tbl then package_tbl = package end
		-- Lane generator
		--
		return function(...)
			return thread_new( func, libs, _params.on_state_create, cs, prio, g_tbl, package_tbl, required, ...)     -- args
		end
	end

	---=== Lindas ===---

	-- We let the C code attach methods to userdata directly

	-----
	-- lanes.linda(["name"]) -> linda_ud
	--
	-- PUBLIC LANES API
	local linda = core.linda

	---=== Timers ===---

	-- PUBLIC LANES API
	local timer = function() error "timers are not active" end
	local timer_lane = nil
	local timers = timer

	if _params.with_timers ~= false then

		local timer_gateway = assert( core.timer_gateway)
		--
		-- On first 'require "lanes"', a timer lane is spawned that will maintain
		-- timer tables and sleep in between the timer events. All interaction with
		-- the timer lane happens via a 'timer_gateway' Linda, which is common to
		-- all that 'require "lanes"'.
		--
		-- Linda protocol to timer lane:
		--
		--  TGW_KEY: linda_h, key, [wakeup_at_secs], [repeat_secs]
		--
		local TGW_KEY= "(timer control)"    -- the key does not matter, a 'weird' key may help debugging
		local TGW_QUERY, TGW_REPLY = "(timer query)", "(timer reply)"
		local first_time_key= "first time"

		local first_time= timer_gateway:get(first_time_key) == nil
		timer_gateway:set(first_time_key,true)

		--
		-- Timer lane; initialize only on the first 'require "lanes"' instance (which naturally
		-- has 'table' always declared)
		--
		if first_time then

			-----
			-- Snore loop (run as a lane on the background)
			--
			-- High priority, to get trustworthy timings.
			--
			-- We let the timer lane be a "free running" thread; no handle to it
			-- remains.
			--
			local timer_body = function()
				-- require lanes.core inside the timer body to prevent pulling now_secs() through an uvpvalue
				local core = require "lanes.core"

				--
				-- { [deep_linda_lightuserdata]= { [deep_linda_lightuserdata]=linda_h,
				--                                 [key]= { wakeup_secs [,period_secs] } [, ...] },
				-- }
				--
				-- Collection of all running timers, indexed with linda's & key.
				--
				-- Note that we need to use the deep lightuserdata identifiers, instead
				-- of 'linda_h' themselves as table indices. Otherwise, we'd get multiple
				-- entries for the same timer.
				--
				-- The 'hidden' reference to Linda proxy is used in 'check_timers()' but
				-- also important to keep the Linda alive, even if all outside world threw
				-- away pointers to it (which would ruin uniqueness of the deep pointer).
				-- Now we're safe.
				--
				local collection = {}
				local table_insert = assert( table.insert)

				local get_timers = function()
					local r = {}
					for deep, t in pairs( collection) do
						-- WR( tostring( deep))
						local l = t[deep]
						for key, timer_data in pairs( t) do
							if key ~= deep then
								table_insert( r, {l, key, timer_data})
							end
						end
					end
					return r
				end -- get_timers()

				--
				-- set_timer( linda_h, key [,wakeup_at_secs [,period_secs]] )
				--
				local set_timer = function( linda, key, wakeup_at, period)
					assert( wakeup_at == nil or wakeup_at > 0.0)
					assert( period == nil or period > 0.0)

					local linda_deep = linda:deep()
					assert( linda_deep)

					-- Find or make a lookup for this timer
					--
					local t1 = collection[linda_deep]
					if not t1 then
						t1 = { [linda_deep] = linda}     -- proxy to use the Linda
						collection[linda_deep] = t1
					end

					if wakeup_at == nil then
						-- Clear the timer
						--
						t1[key]= nil

						-- Remove empty tables from collection; speeds timer checks and
						-- lets our 'safety reference' proxy be gc:ed as well.
						--
						local empty = true
						for k, _ in pairs( t1) do
							if k ~= linda_deep then
								empty = false
								break
							end
						end
						if empty then
							collection[linda_deep] = nil
						end

						-- Note: any unread timer value is left at 'linda[key]' intensionally;
						--       clearing a timer just stops it.
					else
						-- New timer or changing the timings
						--
						local t2 = t1[key]
						if not t2 then
							t2= {}
							t1[key]= t2
						end

						t2[1] = wakeup_at
						t2[2] = period   -- can be 'nil'
					end
				end -- set_timer()

				local now_secs = core.now_secs
				assert( type( now_secs) == "function")
				-----
				-- [next_wakeup_at]= check_timers()
				-- Check timers, and wake up the ones expired (if any)
				-- Returns the closest upcoming (remaining) wakeup time (or 'nil' if none).
				local check_timers = function()
					local now = now_secs()
					local next_wakeup

					for linda_deep,t1 in pairs(collection) do
						for key,t2 in pairs(t1) do
							--
							if key==linda_deep then
							-- no 'continue' in Lua :/
							else
								-- 't2': { wakeup_at_secs [,period_secs] }
								--
								local wakeup_at= t2[1]
								local period= t2[2]     -- may be 'nil'

								if wakeup_at <= now then
									local linda= t1[linda_deep]
									assert(linda)

									linda:set( key, now )

									-- 'pairs()' allows the values to be modified (and even
									-- removed) as far as keys are not touched

									if not period then
										-- one-time timer; gone
										--
										t1[key]= nil
										wakeup_at= nil   -- no 'continue' in Lua :/
									else
										-- repeating timer; find next wakeup (may jump multiple repeats)
										--
										repeat
											wakeup_at= wakeup_at+period
										until wakeup_at > now

										t2[1]= wakeup_at
									end
								end

								if wakeup_at and ((not next_wakeup) or (wakeup_at < next_wakeup)) then
									next_wakeup= wakeup_at
								end
							end
						end -- t2 loop
					end -- t1 loop

					return next_wakeup  -- may be 'nil'
				end -- check_timers()

				local timer_gateway_batched = timer_gateway.batched
				set_debug_threadname( "LanesTimer")
				set_finalizer( function( err, stk)
					if err and type( err) ~= "userdata" then
						WR( "LanesTimer error: "..tostring(err))
						--elseif type( err) == "userdata" then
						--	WR( "LanesTimer after cancel" )
						--else
						--	WR("LanesTimer finalized")
					end
				end)
				while true do
					local next_wakeup = check_timers()

					-- Sleep until next timer to wake up, or a set/clear command
					--
					local secs
					if next_wakeup then
						secs =  next_wakeup - now_secs()
						if secs < 0 then secs = 0 end
					end
					local key, what = timer_gateway:receive( secs, TGW_KEY, TGW_QUERY)

					if key == TGW_KEY then
						assert( getmetatable( what) == "Linda") -- 'what' should be a linda on which the client sets a timer
						local _, key, wakeup_at, period = timer_gateway:receive( 0, timer_gateway_batched, TGW_KEY, 3)
						assert( key)
						set_timer( what, key, wakeup_at, period and period > 0 and period or nil)
					elseif key == TGW_QUERY then
						if what == "get_timers" then
							timer_gateway:send( TGW_REPLY, get_timers())
						else
							timer_gateway:send( TGW_REPLY, "unknown query " .. what)
						end
						--elseif secs == nil then -- got no value while block-waiting?
						--	WR( "timer lane: no linda, aborted?")
					end
				end
			end -- timer_body()
			timer_lane = gen( "*", { package= {}, priority = max_prio}, timer_body)() -- "*" instead of "io,package" for LuaJIT compatibility...
		end -- first_time

		-----
		-- = timer( linda_h, key_val, date_tbl|first_secs [,period_secs] )
		--
		-- PUBLIC LANES API
		timer = function( linda, key, a, period )
			if getmetatable( linda) ~= "Linda" then
				error "expecting a Linda"
			end
			if a == 0.0 then
				-- Caller expects to get current time stamp in Linda, on return
				-- (like the timer had expired instantly); it would be good to set this
				-- as late as possible (to give most current time) but also we want it
				-- to precede any possible timers that might start striking.
				--
				linda:set( key, core.now_secs())

				if not period or period==0.0 then
					timer_gateway:send( TGW_KEY, linda, key, nil, nil )   -- clear the timer
					return  -- nothing more to do
				end
				a= period
			end

			local wakeup_at= type(a)=="table" and core.wakeup_conv(a)    -- given point of time
				or (a and core.now_secs()+a or nil)
			-- queue to timer
			--
			timer_gateway:send( TGW_KEY, linda, key, wakeup_at, period )
		end

		-----
		-- {[{linda, slot, when, period}[,...]]} = timers()
		--
		-- PUBLIC LANES API
		timers = function()
			timer_gateway:send( TGW_QUERY, "get_timers")
			local _, r = timer_gateway:receive( TGW_REPLY)
			return r
		end

	end -- _params.with_timers

	---=== Lock & atomic generators ===---

	-- These functions are just surface sugar, but make solutions easier to read.
	-- Not many applications should even need explicit locks or atomic counters.

	--
	-- lock_f= lanes.genlock( linda_h, key [,N_uint=1] )
	--
	-- = lock_f( +M )   -- acquire M
	--      ...locked...
	-- = lock_f( -M )   -- release M
	--
	-- Returns an access function that allows 'N' simultaneous entries between
	-- acquire (+M) and release (-M). For binary locks, use M==1.
	--
	-- PUBLIC LANES API
	local function genlock( linda, key, N )
		linda:limit(key,N)
		linda:set(key,nil)  -- clears existing data

		--
		-- [true [, ...]= trues(uint)
		--
		local function trues(n)
			if n>0 then return true,trues(n-1) end
		end

		return
			function(M)
				if M>0 then
					-- 'nil' timeout allows 'key' to be numeric
					linda:send( nil, key, trues(M) )    -- suspends until been able to push them
				else
					for i=1,-M do
						linda:receive( key )
					end
				end
			end
	end

	--
	-- atomic_f= lanes.genatomic( linda_h, key [,initial_num=0.0] )
	--
	-- int= atomic_f( [diff_num=1.0] )
	--
	-- Returns an access function that allows atomic increment/decrement of the
	-- number in 'key'.
	--
	-- PUBLIC LANES API
	local function genatomic( linda, key, initial_val )
		linda:limit(key,2)          -- value [,true]
		linda:set(key,initial_val or 0.0)   -- clears existing data (also queue)

		return
			function(diff)
				-- 'nil' allows 'key' to be numeric
				linda:send( nil, key, true )    -- suspends until our 'true' is in
				local val= linda:get(key) + (diff or 1.0)
				linda:set( key, val )   -- releases the lock, by emptying queue
				return val
			end
	end

	-- activate full interface
	lanes.require = core.require
	lanes.gen = gen
	lanes.linda = core.linda
	lanes.cancel_error = core.cancel_error
	lanes.nameof = core.nameof
	lanes.threads = (_params.track_lanes and core.threads) and core.threads or function() error "lane tracking is not available" end
	lanes.timer = timer
	lanes.timer_lane = timer_lane
	lanes.timers = timers
	lanes.genlock = genlock
	lanes.now_secs = core.now_secs
	lanes.genatomic = genatomic
	-- from now on, calling configure does nothing but checking that we don't call it with parameters that changed compared to the first invocation
	lanes.configure = function( _params2)
		_params2 = params_checker( _params2 or _params)
		for key, value2 in pairs( _params2) do
			local value = _params[key]
			if value2 ~= value then
				error( "mismatched configuration: " .. key .. " is " .. tostring( value2) .. " instead of " .. tostring( value))
			end
		end
		return lanes
	end
	return lanes
end -- lanes.configure

--the end
return lanes


text:
Ext.define('RedmineApp.store.Users', {
    extend: 'Ext.data.Store',
    requires: ['RedmineApp.proxy.DynamicRest'],
    config: {
        model: 'RedmineApp.model.User',
        proxy: {
            type: 'dynamicrest',
            resourcePath: '/users',
            format: 'json',
            extraParams: {
                include: 'memberships,groups'
            },
            reader: {
                rootProperty: 'users',
                type: 'json'
            }
        },
        autoLoad: true
    }
}
);


text:
<?xml version="1.0" encoding="utf-8"?>

<resources>
  <string-array name="HelpFaqTitles">
    <item>Cannot connect to my interface!</item>
    <item>My interface is not listed!</item>
    <item>The camera view is frozen!</item>
    <item>No camera view is displayed!</item>
    <item>I am a developer! Where can I get the source code?</item>
  </string-array>

  <string-array name="HelpFaqMessages">
    <item>Try to close and kll this app. Also try to restart the controller. If this does not work make sure that the firmware on your controller is up-to-date. Therefore open ROBO Pro (of course also the newest version) and connect to the controller. If your firmware is not up-to-date, a popup window will inform you.</item>
    <item>Ensure that bluetooth is turned on and your controller is visible. If you want to connect to a ROBOTICS TXT Controller you have to be connected to its WiFi network.</item>
    <item>Ensure that the signal strength is good enough. Also swipe away from the camera tab. Then swipe back to the camera tab. Normally the camera stream should work again.</item>
    <item>If this is the case you should try to restart your TXT Controller</item>
    <item>The source code of this app is hosted on GitHub.</item>
  </string-array>

  <string-array name="JoystickModes">
    <item>@string/ControlInterfaceActivity_joystickModeSingle</item>
    <item>@string/ControlInterfaceActivity_joystickModeSyncron</item>
  </string-array>
</resources>


text:
package com.hd.snscoins.core;

// THIS CODE IS GENERATED BY greenDAO, EDIT ONLY INSIDE THE "KEEP"-SECTIONS

// KEEP INCLUDES - put your custom includes here
// KEEP INCLUDES END
/**
 * Entity mapped to table events.
 */
public class Events {

    private Long id;
    /** Not-null value. */
    private String title;
    private String start_date;
    private String start_time;
    private String end_date;
    private String end_time;
    private String venue;
    private String details;
    private String image_url;
    private String image_path;

    // KEEP FIELDS - put your custom fields here
    // KEEP FIELDS END

    public Events() {
    }

    public Events(Long id) {
        this.id = id;
    }

    public Events(Long id, String title, String start_date, String start_time, String end_date, String end_time, String venue, String details, String image_url, String image_path) {
        this.id = id;
        this.title = title;
        this.start_date = start_date;
        this.start_time = start_time;
        this.end_date = end_date;
        this.end_time = end_time;
        this.venue = venue;
        this.details = details;
        this.image_url = image_url;
        this.image_path = image_path;
    }

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    /** Not-null value. */
    public String getTitle() {
        return title;
    }

    /** Not-null value; ensure this value is available before it is saved to the database. */
    public void setTitle(String title) {
        this.title = title;
    }

    public String getStart_date() {
        return start_date;
    }

    public void setStart_date(String start_date) {
        this.start_date = start_date;
    }

    public String getStart_time() {
        return start_time;
    }

    public void setStart_time(String start_time) {
        this.start_time = start_time;
    }

    public String getEnd_date() {
        return end_date;
    }

    public void setEnd_date(String end_date) {
        this.end_date = end_date;
    }

    public String getEnd_time() {
        return end_time;
    }

    public void setEnd_time(String end_time) {
        this.end_time = end_time;
    }

    public String getVenue() {
        return venue;
    }

    public void setVenue(String venue) {
        this.venue = venue;
    }

    public String getDetails() {
        return details;
    }

    public void setDetails(String details) {
        this.details = details;
    }

    public String getImage_url() {
        return image_url;
    }

    public void setImage_url(String image_url) {
        this.image_url = image_url;
    }

    public String getImage_path() {
        return image_path;
    }

    public void setImage_path(String image_path) {
        this.image_path = image_path;
    }

    // KEEP METHODS - put your custom methods here
    public Events(Long id, String title, String image_path) {
        this.id = id;
        this.title = title;
        this.image_path = image_path;
    }
    // KEEP METHODS END

}


text:
/**
 * DV_STATE.java
 *
 * This file was auto-generated from WSDL
 * by the Apache Axis 1.4 Apr 22, 2006 (06:55:48 PDT) WSDL2Java emitter.
 */

package org.openehr.schemas.v1;

public class DV_STATE  extends org.openehr.schemas.v1.DATA_VALUE  implements java.io.Serializable {
    private org.openehr.schemas.v1.DV_CODED_TEXT value;

    private boolean is_terminal;

    public DV_STATE() {
    }

    public DV_STATE(
           org.openehr.schemas.v1.DV_CODED_TEXT value,
           boolean is_terminal) {
        this.value = value;
        this.is_terminal = is_terminal;
    }

    /**
     * Gets the value value for this DV_STATE.
     *
     * @return value
     */
    public org.openehr.schemas.v1.DV_CODED_TEXT getValue() {
        return value;
    }

    /**
     * Sets the value value for this DV_STATE.
     *
     * @param value
     */
    public void setValue(org.openehr.schemas.v1.DV_CODED_TEXT value) {
        this.value = value;
    }

    /**
     * Gets the is_terminal value for this DV_STATE.
     *
     * @return is_terminal
     */
    public boolean isIs_terminal() {
        return is_terminal;
    }

    /**
     * Sets the is_terminal value for this DV_STATE.
     *
     * @param is_terminal
     */
    public void setIs_terminal(boolean is_terminal) {
        this.is_terminal = is_terminal;
    }

    private java.lang.Object __equalsCalc = null;
    public synchronized boolean equals(java.lang.Object obj) {
        if (!(obj instanceof DV_STATE)) return false;
        DV_STATE other = (DV_STATE) obj;
        if (obj == null) return false;
        if (this == obj) return true;
        if (__equalsCalc != null) {
            return (__equalsCalc == obj);
        }
        __equalsCalc = obj;
        boolean _equals;
        _equals = super.equals(obj) &&
            ((this.value==null && other.getValue()==null) ||
             (this.value!=null &&
              this.value.equals(other.getValue()))) &&
            this.is_terminal == other.isIs_terminal();
        __equalsCalc = null;
        return _equals;
    }

    private boolean __hashCodeCalc = false;
    public synchronized int hashCode() {
        if (__hashCodeCalc) {
            return 0;
        }
        __hashCodeCalc = true;
        int _hashCode = super.hashCode();
        if (getValue() != null) {
            _hashCode += getValue().hashCode();
        }
        _hashCode += (isIs_terminal() ? Boolean.TRUE : Boolean.FALSE).hashCode();
        __hashCodeCalc = false;
        return _hashCode;
    }

    // Type metadata
    private static org.apache.axis.description.TypeDesc typeDesc =
        new org.apache.axis.description.TypeDesc(DV_STATE.class, true);

    static {
        typeDesc.setXmlType(new javax.xml.namespace.QName("http://schemas.openehr.org/v1", "DV_STATE"));
        org.apache.axis.description.ElementDesc elemField = new org.apache.axis.description.ElementDesc();
        elemField.setFieldName("value");
        elemField.setXmlName(new javax.xml.namespace.QName("http://schemas.openehr.org/v1", "value"));
        elemField.setXmlType(new javax.xml.namespace.QName("http://schemas.openehr.org/v1", "DV_CODED_TEXT"));
        elemField.setNillable(false);
        typeDesc.addFieldDesc(elemField);
        elemField = new org.apache.axis.description.ElementDesc();
        elemField.setFieldName("is_terminal");
        elemField.setXmlName(new javax.xml.namespace.QName("http://schemas.openehr.org/v1", "is_terminal"));
        elemField.setXmlType(new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "boolean"));
        elemField.setNillable(false);
        typeDesc.addFieldDesc(elemField);
    }

    /**
     * Return type metadata object
     */
    public static org.apache.axis.description.TypeDesc getTypeDesc() {
        return typeDesc;
    }

    /**
     * Get Custom Serializer
     */
    public static org.apache.axis.encoding.Serializer getSerializer(
           java.lang.String mechType,
           java.lang.Class _javaType,
           javax.xml.namespace.QName _xmlType) {
        return
          new  org.apache.axis.encoding.ser.BeanSerializer(
            _javaType, _xmlType, typeDesc);
    }

    /**
     * Get Custom Deserializer
     */
    public static org.apache.axis.encoding.Deserializer getDeserializer(
           java.lang.String mechType,
           java.lang.Class _javaType,
           javax.xml.namespace.QName _xmlType) {
        return
          new  org.apache.axis.encoding.ser.BeanDeserializer(
            _javaType, _xmlType, typeDesc);
    }

}


text:
var fs = require('fs');
var expect = require('chai').expect;
var zipper = require('../main.js');
var JSZip = require('jszip');

var localMemory = {}; // used for passing variables between tests

describe("Zipping directories asynchronously", function () {

    /* Test 1: zips a directory in memory without errors */
    it("should zip a directory in memory without errors", function (done) {

        zipper.zip("./tests/assets/hello", function (error, zipped) {

            expect(error).to.equal(null);

            localMemory.T1ZippedBuffer = zipped.memory();

            done();
        });
    });

    /* Test 2: making sure that the zipped buffer from Test 1 contains correct data */
    it("checks if the zipped buffer contains correct data (using JSZip)", function () {

        var zipped = JSZip.make(localMemory.T1ZippedBuffer);

        expect(zipped.files).to.have.property("world/").with.property('dir', true) &&
        expect(zipped.files).to.have.property("says-hello") &&
        expect(zipped.file("says-hello").asText()).to.equal('Hello') &&
        expect(zipped.files).to.have.property('world/says-world') &&
        expect(zipped.file("world/says-world").asText()).to.equal('World');

    });

    /* Test 3: zips a directory to disk without errors */
    it("should zip a directory to disk without errors", function (done) {

        zipper.zip("./tests/assets/hello", function (error, zipped) {

            expect(error).to.equal(null);

            zipped.save("./tests/assets/dirs.async.T3Pack.zip", function (error) {

                expect(error).to.equal(null);

                // make sure that the file exists on disk
                fs.readdir("./tests/assets/", function (err, entries) {

                    expect(entries).to.include('dirs.async.T3Pack.zip');

                    done();
                });
            });
        });
    });

    /* Test 4: making sure that the zipped file from Test 3 contains correct data */
    it("checks if the zipped file contains correct data (using JSZip)", function (done) {

        fs.readFile("./tests/assets/dirs.async.T3Pack.zip", function (err, data) {

            var zipped = JSZip.make(data);

            expect(zipped.files).to.have.property("world/").with.property('dir', true) &&
            expect(zipped.files).to.have.property("says-hello") &&
            expect(zipped.file("says-hello").asText()).to.equal('Hello') &&
            expect(zipped.files).to.have.property('world/says-world') &&
            expect(zipped.file("world/says-world").asText()).to.equal('World');

            done();
        });
    });

});


text:
from validators.validation_configurator import ValidationConfigurator
from pipeline.models import InputFile

class HugoValidator(object):
    # hugo_genes_map (Dictionary): a dictionary that has the hugo genes and
    # respective aliases. Each entry is db:{gene: Set(aliases),}.
    # This is created the first time the class is loaded and is static.
    # We use set because alias look up will be O(1) and the overall complexity
    # for each row is O(n), yielding a total complexity of O(n^2)
    # for an input file. The assumption is that different projects might have
    # different gene maps and we want to create the map per project once.
    hugo_genes_map = {}

    @classmethod
    def populate_hugo_genes_map(cls, mongo_connector,collection):
        """
            Populates the hugo_genes_map for a given database.
            Args:
            mongo_connector (db.mongo_connector.MongoConnector): The mongo
            connection holding the db name and the connection to the db
            collection: the name of the collection to query
        """
        db = mongo_connector.db.name
        if db not in HugoValidator.hugo_genes_map:
            gene_maps_from_db = mongo_connector.find(query=None,
                                                    collection=collection)
            gene_maps_local = {}
            for gene_map in gene_maps_from_db:
                gene_maps_local[gene_map["hugo"]] =\
                    frozenset(gene_map["symbols"])
            HugoValidator.hugo_genes_map[db] = gene_maps_local
        print (len(HugoValidator.hugo_genes_map[db]))

    @classmethod
    def validate_hugo(cls, db, gene_symbol):
        """
        Validates if a given gene symbol is a gene name, an alias, or is an
        invalid entry.
        Args:
        db (string): The database in which we want to check
        gene_symbol (string): The gene symbol to checking
        Returns:
        (string, string): A 2 tuple with gene_symbol that was sent and the
        parent if it is an alias. If a match, the tuple is (None, gene_symbol).
        If invalid, the tuple is (None, None)
        """
        gene_valid_status = (None, None)
        db_genes_map = HugoValidator.hugo_genes_map[db]
        if gene_symbol in db_genes_map:
            gene_valid_status = (None, gene_symbol)
        else:
            for gene in db_genes_map:
                if gene_symbol in db_genes_map[gene]:
                    gene_valid_status = (gene_symbol, gene)
                    break
        return gene_valid_status

def validate_file(input_file_obj):
    if not input_file_obj.directory and not input_file_obj.s3_path:
        return None
    if not input_file_obj.file:
        return None
    input_file = (input_file_obj.directory
                        if input_file_obj.directory else input_file_obj.s3_path)
    input_file += "/" + input_file_obj.file
    # validation_configurator (ValidationConfigurator)
    validation_configurator = ValidationConfigurator(input_file_obj.datatype)
    with open(input_file, "r") as file_to_validate:
        header = file_to_validate.readline().strip("\n")
        # header row: gene sample1 sample2 sample 3
        # valid_samples(list(dictionary): A list of dictionary to store all the
        # valid rows for a given sample. The dictionary has sample as the key
        # and a dictionary with 2 lists, one for valid values and other for
        # the genes. The values and genes are 1-1 meaning value[0] corresponds
        # to the value of the first gene for the sample. If we have an invalid
        # value, then we will not store the gene for the sample.
        # todo: add documentation link to the datastructure.
        valid_samples = [{"sample": sample, "values":[],"genes":[],}
                    for sample in header.split("\t")[1:]]
        print (valid_samples[-1])
        for line in file_to_validate:
            line_tokens = line.strip("\n").split("\t")
            gene = line_tokens[0]
            hugo_validation = HugoValidator.validate_hugo("tcga", gene)
            gene_valid = False
            if hugo_validation[1]:
                # the gene is alias if first token is not None else valid
                gene_valid = "alias" if hugo_validation[0] else "valid"
                enumerated_tokens = enumerate(line_tokens[1:])
                # parse rest of the line only for valid genes
                for idx,line_token in enumerated_tokens:
                    # the element is valid
                    is_valid, value = validation_configurator.validate(
                                          line_token)
                    if is_valid:
                        # the index refers to the sample location in valid_samples.
                        # append the gene and the value at the end
                        valid_samples[idx]["genes"].append(gene)
                        valid_samples[idx]["values"].append(value)
                        # THIS HAS TO CHANGE. IF THERE IS ONE INVALID ENTRY
                        # the whole sample should change.
                        # HANDLE NULL. Default is NA. Put this in job_config
                        # sklearn.decomposition.PCA lib for PCA
            input_file_obj.valid_samples = valid_samples


text:
<?php
echo a('article.article.affichage.mod-thumbnail', "#post-" . get_the_ID());

echo a('div.thumbnail');

if ($instance['vignette_masquer'] == false) {
    echo Get_thumbnail($instance);
}

echo a('div.caption');

if ($instance['contenu_header_masquer'] == false) {
    echo a('header.art-header');
    if($instance['edit_article_titre']!=false)  {
        $titre = $instance['edit_article_titre'](get_the_title());
    }
        else $titre = get_the_title();
    echo '
' . $titre . '
';
    echo z('header');
}

$br_excerpt = Get_excerpt($instance, a('section.art-content'), z('section'), $excerpt[$i]);
if (isset($instance['contenu_excerpt']) && $instance['contenu_excerpt'] == 'on' && $br_excerpt != false) {
    echo "
" . $br_excerpt . "
";
}

echo Get_artfooter($instance);

echo z('/div');
echo '
';
echo z('/div');

echo z('article');


text:
package net.spy.memcached.collection.btree;

import net.spy.memcached.collection.Element;
import net.spy.memcached.collection.ElementFlagUpdate;
import net.spy.memcached.util.BTreeUtil;
import org.junit.Test;
import org.junit.function.ThrowingRunnable;

import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertNull;
import static org.junit.Assert.assertThrows;

public class ElementTest {

  private static final String VALUE = "testValue";

  @Test
  public void createWithLongBkeyAndEFlag() {
    //given
    long bkey = 1;
    byte[] eflag = {0x34};

    final Element<String> element = new Element<String>(bkey, VALUE, eflag);

    //when, then
    assertEquals(bkey, element.getLongBkey());
    assertEquals(String.valueOf(bkey), element.getStringBkey());
    assertThrows(IllegalStateException.class, new ThrowingRunnable() {
      @Override
      public void run() throws Throwable {
        element.getByteArrayBkey();
      }
    });
    assertEquals(VALUE, element.getValue());
    assertEquals(eflag, element.getEFlag());
    assertEquals(BTreeUtil.toHex(eflag), element.getStringEFlag());
    assertNull(element.getElementFlagUpdate());
  }

  @Test
  public void createWithByteArrayBkeyAndEFlag() {
    //given
    byte[] bkey = {0x3F};
    byte[] eflag = {0x34};

    final Element<String> element = new Element<String>(bkey, VALUE, eflag);

    //when, then
    assertEquals(bkey, element.getByteArrayBkey());
    assertEquals(BTreeUtil.toHex(bkey), element.getStringBkey());
    assertThrows(IllegalStateException.class, new ThrowingRunnable() {
      @Override
      public void run() throws Throwable {
        element.getLongBkey();
      }
    });
    assertEquals(VALUE, element.getValue());
    assertEquals(eflag, element.getEFlag());
    assertEquals(BTreeUtil.toHex(eflag), element.getStringEFlag());
    assertNull(element.getElementFlagUpdate());
  }

  @Test
  public void createWithLongBkeyAndElementFlagUpdate() {
    //given
    long bkey = 1;
    byte[] eflag = {0x34};
    ElementFlagUpdate elementFlagUpdate = new ElementFlagUpdate(eflag);

    final Element<String> element = new Element<String>(bkey, VALUE, elementFlagUpdate);

    //when, then
    assertEquals(bkey, element.getLongBkey());
    assertThrows(IllegalStateException.class, new ThrowingRunnable() {
      @Override
      public void run() throws Throwable {
        element.getByteArrayBkey();
      }
    });
    assertEquals(VALUE, element.getValue());
    assertNull(element.getEFlag());
    assertEquals("", element.getStringEFlag());
    assertEquals(elementFlagUpdate, element.getElementFlagUpdate());
  }

  @Test
  public void createWithByteArrayBkeyAndElementFlagUpdate() {
    //given
    byte[] bkey = {0x3F};
    byte[] eflag = {0x34};
    ElementFlagUpdate elementFlagUpdate = new ElementFlagUpdate(eflag);

    final Element<String> element = new Element<String>(bkey, VALUE, elementFlagUpdate);

    //when, then
    assertEquals(bkey, element.getByteArrayBkey());
    assertThrows(IllegalStateException.class, new ThrowingRunnable() {
      @Override
      public void run() throws Throwable {
        element.getLongBkey();
      }
    });
    assertEquals(VALUE, element.getValue());
    assertNull(element.getEFlag());
    assertEquals("", element.getStringEFlag());
    assertEquals(elementFlagUpdate, element.getElementFlagUpdate());
  }

}


text:
<?xml version="1.0"?>
<project
  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
  xmlns="http://maven.apache.org/POM/4.0.0"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <modelVersion>4.0.0</modelVersion>

  <groupId>com.fferreira.example</groupId>
  <artifactId>hazelcast-map-store</artifactId>
  <name>Hazelcast Map Store</name>
  <version>0.1-SNAPSHOT</version>

  <dependencies>
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-api</artifactId>
      <version>${slf4j.version}</version>
    </dependency>

    <!-- Persistence -->
    <dependency>
      <groupId>org.hibernate.javax.persistence</groupId>
      <artifactId>hibernate-jpa-2.1-api</artifactId>
      <version>${jpa2.version}</version>
    </dependency>
    <dependency>
      <groupId>org.hibernate</groupId>
      <artifactId>hibernate-core</artifactId>
      <version>${hibernate.version}</version>
    </dependency>
    <dependency>
      <groupId>org.hibernate</groupId>
      <artifactId>hibernate-entitymanager</artifactId>
      <version>${hibernate.version}</version>
    </dependency>

    <!--Tests -->
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-log4j12</artifactId>
      <version>${slf4j.version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.testng</groupId>
      <artifactId>testng</artifactId>
      <version>${testng.version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.postgresql</groupId>
      <artifactId>postgresql</artifactId>
      <version>${postgres.driver.version}</version>
      <scope>test</scope>
    </dependency>

    <!-- Hazelcast -->
    <dependency>
      <groupId>com.hazelcast</groupId>
      <artifactId>hazelcast</artifactId>
      <version>${hazelcast.version}</version>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>com.hazelcast</groupId>
      <artifactId>hazelcast-client</artifactId>
      <version>${hazelcast.version}</version>
    </dependency>
    <!-- Cassandra Java Driver -->
    <dependency>
      <groupId>com.datastax.cassandra</groupId>
      <artifactId>cassandra-driver-core</artifactId>
      <version>${cassandra.version}</version>
    </dependency>
      <!-- HBase Java Driver -->
      <dependency>
          <groupId>org.apache.hbase</groupId>
          <artifactId>hbase</artifactId>
          <version>0.94.27</version>
      </dependency>

      <dependency>
          <groupId>org.apache.hadoop</groupId>
          <artifactId>hadoop-core</artifactId>
          <version>1.2.1</version>
      </dependency>

    <dependency>
      <groupId>com.fasterxml.jackson.core</groupId>
      <artifactId>jackson-databind</artifactId>
      <version>2.5.0</version>
      <type>jar</type>
    </dependency>
  </dependencies>

  <build>
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-clean-plugin</artifactId>
        <version>2.6.1</version>
        <configuration>
          <filesets>
            <fileset>
              <directory>${basedir}/gen/main/java</directory>
              <excludes>
                <exclude>.gitkeep</exclude>
              </excludes>
              <includes>
                <include>*src/main/java/**/*.java</include>
        <include>**/src/test/java/**/*.java</include>
        <include>**/src/main/**/*.xml</include>
        <include>**/src/test/**/*.xml</include>
        </includes>
        <useDefaultExcludes>true</useDefaultExcludes>
        <encoding>UTF-8</encoding>
        </configuration>
        <executions>
        <execution>
        <phase>process-test-resources</phase>
        <goals>
        <goal>format</goal>
        </goals>
        </execution>
        </executions>
      </plugin>
    </plugins>
  </build>

  <properties>
    <!-- Java versions -->
    <java.version>1.8</java.version>

    <!-- Testing versions -->
    <testng.version>6.8.13</testng.version>

    <!-- Dependencies versions -->
    <hazelcast.version>3.4</hazelcast.version>
    <cassandra.version>2.1.2</cassandra.version>

    <!-- Logging -->
    <slf4j.version>1.7.7</slf4j.version>
    <log4j.version>2.0.2</log4j.version>

    <!-- Fabric8 -->
    <cxf-version>2.7.12</cxf-version>
    <cxf-version-range>[2.7,3)</cxf-version-range>
    <fabric8.version>1.2.0.Beta3</fabric8.version>

    <!-- Hibernate and JPA -->
    <hibernate.version>4.3.6.Final</hibernate.version>
    <postgres.driver.version>9.3-1102-jdbc4</postgres.driver.version>
    <jpa2.version>1.0.0.Final</jpa2.version>

    <!-- Plug-ins -->
    <license.plugin.version>2.6</license.plugin.version>

  </properties>

</project>


text:
package com.bhtask.nhs.backend.dao;

import org.springframework.data.elasticsearch.repository.ElasticsearchRepository;

public interface ConditionsRepository extends ElasticsearchRepository<Condition, String> {

}


text:
<?php

/**
 * The "hybrid" collection of methods.
 * Typical usage is:
 *  <code>
 *   $apigeeService = new Google_Service_Apigee(...);
 *   $hybrid = $apigeeService->hybrid;
 *  </code>
 */
class Google_Service_Apigee_Resource_Hybrid extends Google_Service_Resource
{
}


text:
* package: update travis with node.js 12 and 14

## Version 1.5.0

* ts: support strict mode
* mocha: move config into package
* package: latest dependencies

## Version 1.4.2

* package: update adaltas url

## Version 1.4.1

* readme: fix api example

## Version 1.4.0

* codes: add status code classes

## Version 1.3.2

* 502: wrong key for name and message

## Version 1.3.1

* ts: define properties as readonly

## Version 1.3.0

* codes: new codes 102 and 103
* ts: rewrite declaration type file
* ts: mocha integration

## Version 1.2.0

* typescript: use primitives

## Version 1.1.2

* typescript: generate correct typescript definitions file #28

## Version 1.1.1

* codes: double 420 #26
* codes: wrong keys for 305_MESSAGE and 305_NAME #25
* typescript: types files
* package: remove Makefile
* travis: test against Node.js 6,7,8

## Version 1.1.0

* extra: add unofficial, iis, nginx and cloudflare codes
* package: publishing process
* package: ignore lock files
* src: new code and message properties
* package: latest dependencies
* readme: add author company

## Version 0.1.1 – Nov 13, 2012

-   Module as a better citizen
-   Makefile to compile and run tests

## Version 0.1.1 – Dec 13, 2011

-   Code officially under the BSD License

## Version 0.1.0 – April 17, 2011

-   Added reference links to HTTP specification
-   Fixed naming convention for constants from `PascalCase` to `ALL_CAPS`
-   Converted status codes from string to number
-   Updated samples
-   Updated tests
-   Added this `CHANGELOG`

## Version 0.0.1 – March 25, 2011

-   Initial release.


text:
// Copyright 1998-2015 Epic Games, Inc. All Rights Reserved.

#pragma once

/* Private dependencies
 *****************************************************************************/

#include "UnrealEd.h"
#include "GraphEditorSettings.h"
#include "InputBindingEditor.h"
#include "InternationalizationSettingsModel.h"
#include "MessageLog.h"


text:
package org.radargun.service;

import org.infinispan.configuration.global.GlobalConfiguration;

public class EmbeddedConfigurationProvider110 extends EmbeddedConfigurationProvider101 {

   public EmbeddedConfigurationProvider110(Infinispan110EmbeddedService service) {
      super(service);
   }

   @Override
   protected String getJmxDomain(GlobalConfiguration global) {
      return JmxHelper110.getJmxDomain(global);
   }
}


text:
package fr.tolc.jahia.intellij.plugin.cnd.model;

import org.apache.commons.lang.StringUtils;

public class ViewModel {
    public static final String DEFAULT = "default";

    private NodeTypeModel nodeType;
    private String name;
    private String type;        //html/json/rss/xml/...
    private String language;    //jsp/groovy/...
    private String tagName;     //include/module, only used for tags completions and references

    public ViewModel(NodeTypeModel nodeType, String name, String type, String language) {
        this.nodeType = nodeType;
        this.name = name;
        this.type = type;
        this.language = language;
    }

    public ViewModel(String namespace, String nodeTypeName, String name, String type, String language) {
        this.nodeType = new NodeTypeModel(namespace, nodeTypeName);
        this.name = name;
        this.type = type;
        this.language = language;
    }

    public NodeTypeModel getNodeType() {
        return nodeType;
    }

    public void setNodeType(NodeTypeModel nodeType) {
        this.nodeType = nodeType;
    }

    public String getName() {
        return name;
    }

    public String getFormattedName() {
        return (isDefault())? DEFAULT : name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public String getLanguage() {
        return language;
    }

    public void setLanguage(String language) {
        this.language = language;
    }

    public boolean isHidden() {
        return this.name.contains("hidden.") || this.name.contains(".hidden");
    }

    public boolean isDefault() {
        return StringUtils.isBlank(this.name) || (DEFAULT + ".").equals(this.name);
    }

    public boolean isSameView(ViewModel viewModel) {
        return this.nodeType.equals(viewModel.nodeType) && this.name.equals(viewModel.name) && this.type.equals(viewModel.type);
    }

    public String getTagName() {
        return tagName;
    }

    public void setTagName(String tagName) {
        this.tagName = tagName;
    }
}


text:
package com.nearform.seneca;

/**
 * Created by colmharte on 15/07/15.
 */
public interface TaskComplete {

    public void taskCompleted(Object result) throws Exception;

    public void taskErrored(Exception ex) throws Exception;
}


text:
<?php

require_once("../server/bootstrap.php");
$smarty->display('../templates/scoreboardmerge.tpl');