text:
package com.taoswork.tallycheck.datasolution.mongo.core.query.criteria.predicate;

import com.taoswork.tallycheck.general.extension.collections.CollectionUtility;
import org.mongodb.morphia.query.Criteria;
import org.mongodb.morphia.query.Query;

import java.util.ArrayList;
import java.util.List;

/**
 * Created by Gao Yuan on 2015/6/17.
 */
public class StringLikePredicateProvider implements PredicateProvider<String> {
    @Override
    public <T> Criteria buildPredicate(Query<T> query, String path, List<String> directValues) {
        if (CollectionUtility.isEmpty(directValues)) {
            return null;
        }
        if (directValues.size() == 1) {
            return query.criteria(path).containsIgnoreCase(directValues.get(0));
        } else {
            List<Criteria> predicates = new ArrayList<Criteria>();
            for (String directVal : directValues) {
                Criteria predicate = query.criteria(path).containsIgnoreCase(directVal);
                predicates.add(predicate);
            }
            return query.or(predicates.toArray(new Criteria[]{}));
        }
    }
}


text:
ACCEPTED

#### According to
Index Fungorum

#### Published in
New Botanist 20(1-4): 65 (1993)

#### Original name
Asteridiella lophopetali Hosag. & Raghu

### Remarks
null

redpajama_set_name: RedPajamaGithub


text:
<?php

namespace LpFactory\Bundle\CoreBundle\Configuration;

/**
 * Class AbstractChain
 *
 * @package LpFactory\Bundle\CoreBundle\Configuration
 * @author jobou
 */
abstract class AbstractChain
{
    /**
     * @var string
     */
    protected $defaultAlias;

    /**
     * @var array
     */
    protected $items = array();

    /**
     * Constructor
     *
     * @param string $defaultAlias
     */
    public function __construct($defaultAlias = 'default')
    {
        $this->defaultAlias = $defaultAlias;
    }

    /**
     * Add an item
     *
     * @param mixed $item
     * @param string $alias
     *
     * @return $this
     */
    protected function addItem($item, $alias)
    {
        $this->items[$alias] = $item;

        return $this;
    }

    /**
     * Get item in a chain
     *
     * @param string $alias
     *
     * @return mixed
     */
    protected function getItem($alias)
    {
        if (isset($this->items[$alias])) {
            return $this->items[$alias];
        }

        if (!isset($this->items[$this->defaultAlias])) {
            throw new \LogicException('No default alias configured in '.get_class($this));
        }

        return $this->items[$this->defaultAlias];
    }
}


text:
const path = require('path')
const analyzeDirectory = require('../../../lib/path/analyzers/directory')

describe('path.analyzers.directory', () => {
  it('should not update token if already analyzed', async () => {
    const token = {
      analyzed: true
    }
    const save = {...token}

    const ret = await analyzeDirectory(token)

    expect(ret).toBeFalsy()
    expect(token).toEqual(save)
  })

  it('should return a child for each item in the directory', async () => {
    const token = {
      path: path.resolve(__dirname, '../../__fixtures__/directory')
    }

    await analyzeDirectory(token)

    expect(token.children).toEqual([
      {
        filePath: '1.txt',
        inputType: 'path',
        path: path.join(token.path, '1.txt'),
        fromUrl: undefined
      },
      {
        filePath: '2.txt',
        inputType: 'path',
        path: path.join(token.path, '2.txt'),
        fromUrl: undefined
      }
    ])
  })

  it('should set the token type to directory', async () => {
    const token = {
      path: path.resolve(__dirname, '../../__fixtures__/directory')
    }

    await analyzeDirectory(token)

    expect(token.type).toBe('directory')
  })

  it('should set the token as analyzed', async () => {
    const token = {
      path: path.resolve(__dirname, '../../__fixtures__/directory')
    }

    await analyzeDirectory(token)

    expect(token.analyzed).toBeTruthy()
  })

  it('should pass the fromUrl attribute down to children', async () => {
    const token = {
      path: path.resolve(__dirname, '../../__fixtures__/directory'),
      fromUrl: 'foo'
    }

    await analyzeDirectory(token)

    expect(token.children).toEqual([
      {
        filePath: '1.txt',
        inputType: 'path',
        path: path.join(token.path, '1.txt'),
        fromUrl: 'foo'
      },
      {
        filePath: '2.txt',
        inputType: 'path',
        path: path.join(token.path, '2.txt'),
        fromUrl: 'foo'
      }
    ])
  })
})


text:
<?php

namespace Kanboard\User\Avatar;

use Kanboard\Core\Base;
use Kanboard\Core\User\Avatar\AvatarProviderInterface;

/**
 * Avatar Local Image File Provider
 *
 * @package  avatar
 * @author   Frederic Guillot
 */
class AvatarFileProvider extends Base implements AvatarProviderInterface
{
    /**
     * Render avatar html
     *
     * @access public
     * @param  array $user
     * @param  int   $size
     * @return string
     */
    public function render(array $user, $size)
    {
        $url = $this->helper->url->href('AvatarFileController', 'image', array('user_id' => $user['id'], 'hash' => md5($user['avatar_path']), 'size' => $size));
        $title = $this->helper->text->e($user['name'] ?: $user['username']);
        return '<img src="' . $url . '" alt="' . $title . '" title="' . $title . '">';
    }

    /**
     * Determine if the provider is active
     *
     * @access public
     * @param  array $user
     * @return boolean
     */
    public function isActive(array $user)
    {
        return !empty($user['avatar_path']);
    }
}


text:
package tools;

import org.w3c.dom.Document;
import org.w3c.dom.Element;
/**
 *
 * @author broihier
 *

 * Class for creating chapter (section/category) objects
 *

 */

public class Chapter {
		private Document doc = null;
		private String status = "UNTESTED";
		private String title;
		/**
		 * Constructor for creating chapter objects
		 *
		 *

		 * Pseudo-code:
		 * {@code
		 * create a chapter table of contents DOM object;
		 * insert the title and description into the DOM;
		 * foreach test case in the test category (chapter) {
		 *     create a test case object;
		 *     add a table of contents entry to the DOM based on the status of the test case object;
		 *     update the overall status of the chapter;
		 * }
		 * write out the table of content DOM for this chapter;
		 * }
		 *

		 * @param category name that maps to 'category'.testDbCategoryTitle/Description files
		 * @param database Test database file that contains all of the unformatted document information
		 *
		 */

		public Chapter (String category, TestDatabase database) {
			DOMizeTemplate DOMizedTemplate = new DOMizeTemplate("../tools_configuration/TOC_Template.html","./"+category+"_toc.html");
			this.doc = DOMizedTemplate.getDoc();
			// insert section title into test case DOM
			Element element = Utilities.findElementById(doc,"title");
			this.title = database.getCategoryTitle();
			element.appendChild(doc.createTextNode(database.getCategoryTitle()));

			// insert section description into test case DOM
			element = Utilities.findElementById(doc,"description");
			element.appendChild(doc.createTextNode(database.getCategoryDescriptionText()));

			// insert test cases

			element = Utilities.findElementById(doc,"list");
			for (String cases : database.getIdentificationIDs()) {
				String status = (new TestCase(cases,category,database)).getStatus();
				Element listItem = doc.createElement("li");
				Element anchor = doc.createElement("a");
				anchor.setAttribute("href", category+"/"+cases+".html");
				if (status.equals("PASSED")) {
					anchor.setAttribute("style", "color: 00F000");
				} else if (status.equals("FAILED")) {
					anchor.setAttribute("style", "color: FF0000");
				}
				anchor.appendChild(doc.createTextNode(cases + " - " + database.getIdentificationText(cases)));
				listItem.appendChild(anchor);
				element.appendChild(listItem);
				updateChapterStatus(status);
			}

			// write TOC DOM
			DOMizedTemplate.writeDocument();
		}

		/**
		 * Method to return the overall status of the chapter
		 *
		 * @return status - getter
		 *
		 */
		public String getStatus() {
			return status;
		}

		/**
		 * Method to return the title of the chapter
		 *
		 * @return title - getter
		 *
		 */
		public String getTitle() {
			return title;
		}
		/**
		 * Private method to determine the overall state of the chapter based on individual test case results
		 *
		 */
		private void updateChapterStatus (String status) {
			if (status.equals("UNTESTED")) {
				if (! this.status.equals("UNTESTED")){
					this.status = "NOTDONE";
				}
			} else {
				if (status.equals("FAILED")) {
					this.status = "FAILED";
				} else {
					if (this.status.equals("UNTESTED")){
						this.status = "PASSED";
					}
				}
			}
		}
}


text:
alter table TRANSCRIPT disable constraint XSCRIPTBIGID;
alter table TRANSCRIPT disable constraint SYS_C0021192;
alter table TRANSCRIPT disable constraint SYS_C004798;
alter table TRANSCRIPT disable constraint SYS_C004799;
alter table TRANSCRIPT disable constraint SYS_C004800;
alter table TRANSCRIPT disable constraint SYS_C004801;
alter table TRANSCRIPT disable constraint SYS_C004802;

alter table TRANSCRIPT disable primary key;

--EXIT;


text:
from math import cos
from math import atan2
from math import sin
from math import pi

from Controller.DrawingObject.color import Color
from Controller.MobileObject.BaseMobileObject import BaseMobileObject
from Controller.QtToolBox import QtToolBox

__author__ = 'RoboCupULaval'

class RobotMob(BaseMobileObject):
    def __init__(self, bot_id, team_color, x=0, y=0, theta=0):
        BaseMobileObject.__init__(self, x, y, theta)
        self._bot_id = bot_id
        self._team_color = team_color
        self._display_number = False
        self._display_select = False
        self._display_vector = False
        self._radius = 180 / 2

    @property
    def id(self):
        return self._bot_id

    @property
    def radius(self):
        return self._radius * QtToolBox.field_ctrl.ratio_field_mobs

    def show_speed_vector(self):
        self._display_vector = True

    def hide_speed_vector(self):
        self._display_vector = False

    def speed_vector_isVisible(self):
        return self._display_vector

    def draw(self, painter):
        # TODO Ajouter vecteur de direction
        if self.isVisible():
            x, y, theta = QtToolBox.field_ctrl.convert_real_to_scene_pst(self._x, self._y, self._theta)
            if self._team_color == 'yellow':
                painter.setBrush(QtToolBox.create_brush(color=Color.CLEAR_YELLOW))
            else:
                painter.setBrush(QtToolBox.create_brush(color=Color.SKY_BLUE))

            if self._display_select:
                painter.setPen(QtToolBox.create_pen(color=Color.RED,
                                                    style='SolidLine',
                                                    width=2))
            else:
                painter.setPen(QtToolBox.create_pen(color=Color.BLACK,
                                                    style='SolidLine',
                                                    width=1))

            radius = self.radius * QtToolBox.field_ctrl.ratio_screen
            painter.drawEllipse(x - radius, y - radius, radius * 2, radius * 2)
            painter.drawLine(x, y, x + cos(theta) * radius, y + sin(theta) * radius)

            if self._display_number:
                painter.drawText(x + radius, y + radius * 2, '{:.1}{}'.format(self._team_color,self._bot_id))
            if self.speed_vector_isVisible():
                v_x, v_y = self._speed_vector
                x2, y2, _ = QtToolBox.field_ctrl.convert_real_to_scene_pst(self._x + v_x * 180, self._y + v_y * 180)
                painter.setPen(QtToolBox.create_pen(color=Color.RED,
                                                    width=3))
                painter.drawLine(x, y, x2, y2)
                if (v_x ** 2 + v_y ** 2) > 0.05:
                    self._draw_vector_speed(painter)

    def _draw_vector_speed(self, painter):
        v_x, v_y = self._speed_vector
        x2, y2, _ = QtToolBox.field_ctrl.convert_real_to_scene_pst(self._x + v_x * 180, self._y + v_y * 180)
        angle = atan2(v_y, v_x) + pi / 2

        # flèche gauche
        arrow_x = x2 - 5 * sin(angle + pi / 4)
        arrow_y = y2 - 5 * cos(angle + pi / 4)
        painter.drawLine(x2, y2, arrow_x, arrow_y)

        # flèche droite
        arrow_x = x2 - 5 * sin(angle - pi / 4)
        arrow_y = y2 - 5 * cos(angle - pi / 4)
        painter.drawLine(x2, y2, arrow_x, arrow_y)

    def select(self):
        self._display_select = True

    def deselect(self):
        self._display_select = False

    def isSelect(self):
        return self._display_select

    def show_number(self):
        self._display_number = True

    def hide_number(self):
        self._display_number = False

    def number_isVisible(self):
        return self._display_number

    def show_effects(self):
        self._display_effects = True

    def hide_effects(self):
        self._display_effects = False

    def effects_isVisible(self):
        return self._display_effects

    @staticmethod
    def get_datain_associated():
        return 'robot'


text:
using TemplateMethod.Weapons;

namespace TemplateMethod.Warriors
{
    public class Grenadier : Warrior
    {
        protected override string GetWarriorName()
        {
            return "Grenadier";
        }

        protected override IWeapon GetWeaponOfChoice()
        {
            return new Grenade();
        }
    }
}


text:
<link rel="stylesheet" type="text/css" href="/stylesheets/subforum.css"></link>

Usertags:

						<?php
							foreach(accounts::get_user_tags($profile->id) as $value){
								$tag = usertags::get_by_id($value);
								echo "$tag->name
";
							}
						?>

<?php echo accounts::get_display_name($profile->id) ?>

<?php echo $profile->bio ?>

Forum posts:

									<?php foreach(forums::get_all_posts_by_poster($profile->id) as $value){
										$iconString = "";
							            if($value->locked){
							                $iconString .= "  ";
							            }
							            if($value->hidden){
							                $iconString .= "  ";
							            }
							            if($value->hidden && !usertags::user_has_permission($currUsertags, "hideunhide")){
							                continue;
							            }
							            $previewString = $value->text;
							            if(strlen($previewString) > 50){
							                $previewString = substr($previewString, 0, 50);
							                $previewString .= "...";
							            }

										$threadParentName = forums::get_by_id($value->parent)->title;
										$threadLinkID = $value->id;
										$threadTitleText = $value->title;
										if($value->type == "reply"){
											$threadParentName = forums::get_by_id(forums::get_by_id($value->parent)->parent)->title;
											$threadLinkID = $value->parent;
											$threadTitleText = $value->text;
											$previewString = "";
										}
									?>

												<a href="/thread/<?php echo $threadLinkID ?>" target="_blank" class="thread" data-toggle="tooltip" title="<?php echo $previewString ?>">
													<?php echo $threadTitleText ?><?php echo $iconString ?>
													<?php echo get_human_time($value->lastactive) ?> ago
													<?php echo $value->replies ?>
													<?php echo $threadParentName ?>

									<?php } ?>


text:
<?xml version="1.0" encoding="UTF-8"?><concept xmlns="http://www.w3.org/2004/02/skos/core#">
      <prefLabel>ESRD PATIENT</prefLabel>
      <definition>A person with irreversible and permanent kidney failure who requires a regular
         course of dialysis or kidney transplantation to maintain life.</definition>
   </concept>


text:
using UnityEngine;
using System.Collections;

public class GameControlScript : MonoBehaviour {
	public float gameTime;
	private int Score;
	private int Health;
	private int bombCount;
	private int dirtCount;
	private int coinCount;
	public Texture bombIcon;
	public Texture dirtIcon;
	public int level;
	private bool isFinishReached;

	// Use this for initialization
	void Start () {
		Score = 0;
		Health = 100;
		bombCount = 0;
		dirtCount = 0;
		coinCount = 0;
		isFinishReached = false;
	}

	// Update is called once per frame
	void Update () {
		gameTime -= Time.deltaTime;
		if (gameTime <= 0 || isFinishReached == true || Health<=0) {
			GameOver();
		}
	}

	public void bombCollected() {
		bombCount++;
	}

	public void dirtCollected() {
		dirtCount++;
	}

	public void coinCollected() {
		coinCount++;
		Score += 100;
	}

	public void finishTrophyCollected() {
		isFinishReached = true;
	}

	public void reduceHealth(int ammount){
		Health -= ammount;
	}

    public void bombUsed()
    {
        bombCount--;
    }

    public void dirtUsed()
    {
        dirtCount--;
    }

    public int getTotBomb()
    {
        return bombCount;
    }

    public int getTotDirt()
    {
        return dirtCount;
    }

	void OnGUI () {
		// Timer
		GUI.Label (new Rect (5, 5, 200, 50), "<size=20>SCORE\n"+Score+"</size>");
		GUI.Label (new Rect (Screen.width/2-75, 5, 150, 25), "<size=20>TIME LEFT</size>");

		// Life
		GUI.Label (new Rect (Screen.width/2-40, 30, 80, 25), "<size=20>"+(int)gameTime+"</size>");
		GUI.Label (new Rect (5, Screen.height-30, 200, 50), "<size=20> HEALTH = "+Health+"</size>");

		// Bomb
		GUI.DrawTexture(new Rect (Screen.width-180, Screen.height-80, 75, 75), bombIcon);
		GUI.Label (new Rect (Screen.width - 160, Screen.height - 40, 100, 50), "<size=20>"+bombCount+"</size>");

		// Dirt
		GUI.DrawTexture(new Rect (Screen.width-95, Screen.height-70, 90, 90), dirtIcon);
		GUI.Label (new Rect (Screen.width - 60, Screen.height - 40, 100, 50), "<size=20>"+dirtCount+"</size>");
	}

	private void GameOver() {
		PlayerPrefs.SetInt ("Score", Score);
		string finishStatus = isFinishReached ? "true" : "false";
		PlayerPrefs.SetString ("finishStatus", finishStatus);
		if(isFinishReached)
			PersistentScore.addHighScore(level,Score);
		Application.LoadLevel (3);
	}
}


text:
.no-support-message { display:none; }
.impress-not-supported .no-support-message { display:block; }

/* additional styles just to make things look a bit nicer */
body { background:#EBEBEB; font:16px/24px "HelveticaNeue-Light", "Helvetica Neue Light", "Helvetica Neue", Helvetica, Arial, "Lucida Grande", sans-serif; color:#333; }
.step { width:940px; margin:0 auto 24px auto; text-align:center; }


text:
<?xml version="1.0"?>
<info>
	<id>admin_dependencies_chk</id>
	<name>ownCloud dependencies info</name>
	<licence>AGPL</licence>
	<author>Brice Maron (eMerzh)</author>
	<requiremin>4.93</requiremin>
	<shipped>true</shipped>
	<description>Display OwnCloud's dependencies informations (missings modules, ...)</description>
	<ocsid>166041</ocsid>
</info>


text: (new Int8Array(0)).filter(parseInt)


text:
using System;

namespace W3SavegameEditor.Core.Savegame.Variables
{
    public class TypedVariable : Variable
    {
        public string Type { get; set; }
        public Type ClrType { get; set; }
        public VariableValue Value { get; set; }

        public override string ToString()
        {
            return string.Format("{0} {1} {2}", Type, base.ToString(), Value);
        }
    }
}


text:
describe('client tables with various options, ensure instance independency', function(){
  require('daterangepicker/daterangepicker');
  var draw_table = require('../helpers/draw-table');
  var get_els = require('../helpers/get-els');
  data = require('../helpers/people.js')();

  var table1 = "table1";
  var table2 = "table2";

  var defaults = require('../../lib/config/defaults')();

  beforeAll(function(done){
    vm1 = draw_table(table1, data, ['id','name','birth_date'],{
      filterByColumn:true,
      pagination:{
        chunk:5
      },
      headings: {
        id:"Identifier"
      },
      templates:{
        name: "{name} is {age} years old"
      },
      perPageValues:[5,10,20,30],
       texts:{
      count:"{count} Results",
      limit:"Per page:",
      filterBy: "Search {column}" // Placeholder for search fields when filtering by column
    },
    skin:'table-bordered',
    dateFormat:'YYYY',
    footerHeadings:true
    });

    vm2 = draw_table(table2, data, ['id','name','age'],{
      pagination: {
        dropdown:true
      },
      headings: {
        id:"Index",
        name:"der Name",
        age:"der Alter"
      },
      sortable:['id','age'],
      perPage:25,
      compileTemplates:true,
      templates: {
        custom:"{id}:{age}"
      },
      texts: {
        page:'select page',
        filter:"Search"
      },
      highlightMatches:true,
      skin:'table-striped table-condensed',
      orderBy: {
        column:'age',
        ascending:false
      },
      dateColumns: ['birth_date']
    });

    setTimeout(function(){
      t1 = get_els($("#"+table1));
      t2 = get_els($("#"+table2));

      done();
    },1000);
});

it('columns', function() {

 expect(t1.headings.eq(0).text()).toBe('Identifier');
 expect(t1.headings.eq(1).text()).toBe('Name');
 expect(t1.headings.eq(2).text()).toBe('Birth date');

 expect(t2.headings.eq(0).text()).toBe('Index');
 expect(t2.headings.eq(1).text()).toBe('der Name');
 expect(t2.headings.eq(2).text()).toBe('der Alter');
});

it('sortable', function() {
    expect(t1.ths.eq(1).hasClass("VueTables__sortable")).toBe(true); // t1 name
    expect(t2.ths.eq(1).hasClass("VueTables__sortable")).toBe(false); // t2 name
    expect(t2.ths.eq(4).hasClass("VueTables__sortable")).toBe(false); // t2 custom
});

it('perPage', function() {
    expect(t1.limit.find("select").val()).toBe("10");
    expect(t2.limit.find("select").val()).toBe("25");
});

it('perPageValues', function() {
   expect(t1.limit.find("select").find("option").eq(0).text()).toBe("5");
   expect(t2.limit.find("select").find("option").eq(0).text()).toBe("10");
});

it('filterByColumn',function() {
  expect(t1.search.length).toBe(0);
  expect(t1.table.find("thead").find("tr").eq(1).length).toBe(1);
  expect(t2.search.length).toBe(1);
  expect(t2.table.find("thead").find("tr").eq(1).length).toBe(0);
});

it('templates', function() {
expect(t1.headings.eq(3).length).toBe(0);
expect(t2.headings.eq(3).text()).toBe('Custom');

expect(t1.rows.eq(3).find("td").eq(1).find("span").html()).toBe('Miss Laury Farrell is 71 years old');
expect(t2.rows.eq(0).find("td").eq(3).text()).toBe("49:119");

});

it("compileTemplates", function() {
expect(t2.rows.eq(1).find("td").eq(3).html()).toBe('41:117');
});

it("texts", function() {

 expect(t2.search.find("label").text()).toBe("Search");
 expect(t2.search.find("input").prop("placeholder")).toBe("Search query");
 expect($("#table2 .VueTables__dropdown-pagination").find("label").text()).toBe("select page");

expect(t1.table.find("thead").find("tr").eq(1).find("th").eq(0).find("input").prop("placeholder")).toBe("Search Identifier");
expect(t1.limit.find("label").text()).toBe("Per page:");
expect($("#table1 .VuePagination__count").eq(0).text()).toBe("100 Results");

});

it("skin", function() {
  expect(t1.table.prop("class")).toBe("VueTables__table table table-bordered");
  //expect(t2.table.prop("class")).toBe("VueTables__table table table-striped table-condensed");
});

it("orderBy", function() {
  expect(t1.ths.eq(0).find(".glyphicon-chevron-up").length).toBe(1);
  expect(t2.ths.eq(2).find(".glyphicon-chevron-down").length).toBe(1);

});

it("dateFormat", function() {

  expect(t1.rows.eq(0).find("td").eq(2).text()).toBe("2013");
 });

it("pagination.chunk", function() {
  expect(t1.paginationLinks.length).toBe(9); // 5 + 2 + 2
  expect($("#table1 .VueTables__dropdown-pagination").length).toBe(0);

});

it("pagination.dropdown", function() {
  expect(t2.paginationLinks.length).toBe(0);
  expect($("#table2 .VueTables__dropdown-pagination").length).toBe(1);
});

it('footerHeadings', function() {
  expect(t1.table.find("tfoot").length).toBe(1);
  expect(t2.table.find("tfoot").length).toBe(0);
});

it('dateColumns', function() {
//  expect(t1.table.find("thead").find("tr").eq(1).find("td").eq(2).find("input[type=date]").length).toBe(1);
});

  afterAll(function(){
   $("#" + table1, "#" + table2).remove();
  });
});


text:
<?xml version="1.0"?>
<project name="groovy-osgi-sample" default="print-results">

  <property name="build.dir" value="build"/>
  <property file="build.properties"/>
  <property name="groovy.jar" value="groovy-all-${groovy.version}.jar" />
  <property name="hello.bundle" value="hello-bundle-imports-groovy.jar" />
  <property name="hello.bundle.contains" value="hello-bundle-contains-groovy.jar" />
  <property name="harness.bundle" value="hello-groovy-test-harness.jar" />

  <taskdef name="groovyc"
	   classname="org.codehaus.groovy.ant.Groovyc"
	   classpathref="project.classpath"/>

  <target name="init" description="cleanup and reinitialize">
	  <path id="project.classpath">
		  <pathelement location="${osgi.jar}"/>
		  <pathelement location="${groovy.bin.dir}${file.separator}${groovy.jar}"/>
		  <pathelement location="${build.dir}${file.separator}${hello.bundle}"/>
	  </path>

	  <delete dir="${build.dir}" />
	  <mkdir dir="${build.dir}${file.separator}hello-groovy-bundle" />
	  <mkdir dir="${build.dir}${file.separator}hello-groovy-test-harness" />
  </target>

  <target name="make-hello-groovy-bundle" description="compile and build the Hello Groovy bundles">

    <groovyc destdir="${build.dir}${file.separator}hello-groovy-bundle"
	     srcdir=".${file.separator}hello-groovy-bundle"
              listfiles="true">
              <classpath refid="project.classpath"/>
    </groovyc>

    <!-- This jar file imports Groovy from the container -->
    <jar destfile="${build.dir}${file.separator}${hello.bundle}">
	    <fileset dir="${build.dir}${file.separator}hello-groovy-bundle"/>
	    <manifest>
		    <attribute name="Built-By" value="${user.name}"/>
		    <attribute name="provider" value="org.codehaus.groovy.osgi"/>
		    <attribute name="Bundle-ManifestVersion" value="2"/>
		    <attribute name="Bundle-Name" value="Groovy OSGi Example Bundle"/>
		    <attribute name="Bundle-SymbolicName" value="org.codehaus.groovy.osgi.hello-groovy-bundle"/>
		    <attribute name="Bundle-Version" value="1.0.0"/>
		    <attribute name="Bundle-Activator" value="org.codehaus.groovy.osgi.Activator"/>
		    <attribute name="Bundle-Vendor" value="Groovy"/>
		    <attribute name="Bundle-Localization" value="plugin"/>
		    <attribute name="Import-Package" value="groovy.lang;version="1.7.0.beta-1-SNAPSHOT",org.codehaus.groovy.reflection;version="1.7.0.beta-1-SNAPSHOT",org.codehaus.groovy.runtime;version="1.7.0.beta-1-SNAPSHOT",org.codehaus.groovy.runtime.callsite;version="1.7.0.beta-1-SNAPSHOT",org.w3c.dom,org.osgi.framework;version="1.3.0""/>
		    <attribute name="Export-Package" value="org.codehaus.groovy.osgi;version="1.0.0""/>
		    <attribute name="Bundle-ClassPath" value="."/>
	    </manifest>
    </jar>

    <!-- This jar includes the Groovy jar within itself-->
    <jar destfile="${build.dir}${file.separator}${hello.bundle.contains}">
	    <fileset dir="${build.dir}${file.separator}hello-groovy-bundle"/>
	    <fileset file="${groovy.bin.dir}${file.separator}${groovy.jar}" casesensitive="no" />
	    <manifest>
		    <attribute name="Built-By" value="${user.name}"/>
		    <attribute name="provider" value="org.codehaus.groovy.osgi"/>
		    <attribute name="Bundle-ManifestVersion" value="2"/>
		    <attribute name="Bundle-Name" value="Groovy OSGi Example Bundle"/>
		    <attribute name="Bundle-SymbolicName" value="org.codehaus.groovy.osgi.hello-groovy-bundle"/>
		    <attribute name="Bundle-Version" value="1.0.0"/>
		    <attribute name="Bundle-Activator" value="org.codehaus.groovy.osgi.Activator"/>
		    <attribute name="Bundle-Vendor" value="Groovy"/>
		    <attribute name="Bundle-Localization" value="plugin"/>
		    <attribute name="Import-Package" value="org.w3c.dom,org.osgi.framework;version="1.3.0""/>
		    <attribute name="Export-Package" value="org.codehaus.groovy.osgi;version="1.0.0""/>
		    <attribute name="Bundle-ClassPath" value=".,${groovy.jar}"/>
	    </manifest>
    </jar>
  </target>

  <target name="make-harness-bundle" description="Makes the test harness bundle">

	  <groovyc destdir="${build.dir}${file.separator}hello-groovy-test-harness"
		   srcdir=".${file.separator}hello-groovy-test-harness"
		   listfiles="true">
		  <classpath refid="project.classpath"/>
	  </groovyc>

	  <jar destfile="${build.dir}${file.separator}${harness.bundle}">
		  <fileset dir="${build.dir}${file.separator}hello-groovy-test-harness"/>
		  <manifest>
			  <attribute name="Built-By" value="${user.name}"/>
			  <attribute name="provider" value="org.codehaus.groovy.osgi.harness"/>
			  <attribute name="Bundle-ManifestVersion" value="2"/>
			  <attribute name="Bundle-Name" value="Groovy OSGi Test Harness"/>
			  <attribute name="Bundle-SymbolicName" value="org.codehaus.groovy.osgi.harness.hello-groovy-test-harness"/>
			  <attribute name="Bundle-Version" value="1.0.0"/>
			  <attribute name="Bundle-Activator" value="org.codehaus.groovy.osgi.harness.HarnessActivator"/>
			  <attribute name="Bundle-Vendor" value="Groovy"/>
			  <attribute name="Bundle-Localization" value="plugin"/>
			  <attribute name="Import-Package" value="org.codehaus.groovy.runtime.typehandling;version="1.0.0",org.codehaus.groovy.osgi;version="1.0.0",groovy.lang;version="1.7.0.beta-1-SNAPSHOT",org.codehaus.groovy.reflection;version="1.7.0.beta-1-SNAPSHOT",org.codehaus.groovy.runtime;version="1.7.0.beta-1-SNAPSHOT",org.codehaus.groovy.runtime.callsite;version="1.7.0.beta-1-SNAPSHOT",org.w3c.dom,org.osgi.framework;version="1.3.0""/>
			  <attribute name="Bundle-ClassPath" value="."/>
		  </manifest>
	  </jar>

  </target>

  <target name="print-results" depends="init,make-hello-groovy-bundle,make-harness-bundle" description="compile and build everything">
	<makeurl file="${basedir}/${groovy.bin.dir}/${groovy.jar}" property="groovy.jar.url"/>
	<makeurl file="${basedir}/${build.dir}/${hello.bundle}" property="hello.jar1.url"/>
	<makeurl file="${basedir}/${build.dir}/${hello.bundle.contains}" property="hello.jar2.url"/>
	<makeurl file="${basedir}/${build.dir}/${harness.bundle}" property="harness.jar.url"/>

	<echo>To run the OSGi console, run the following command:
 java -jar ${osgi.jar} -console
To install these applications in the container, run the following commands in the OSGi container:
 install ${groovy.jar.url}
 install ${hello.jar1.url}
 install ${hello.jar2.url}
 install ${harness.jar.url}
To start the applications in the container, run the following commands in the OSGi container:
 start [bundle1] [bundle2]
Where [bundle1] and [bundle] are the bundle IDs printed by the console in the previous step.</echo>
  </target>
</project>


text:
package org.dawnsci.prototype.e4.nano.handlers;

import javax.inject.Inject;

import org.eclipse.e4.core.di.annotations.Execute;
import org.eclipse.e4.core.services.events.IEventBroker;
import org.eclipse.swt.widgets.FileDialog;
import org.eclipse.swt.widgets.Shell;
public class OpenHandler {

	@Inject
	private IEventBroker eventBroker;

	@Execute
	public void execute(Shell shell){
		FileDialog dialog = new FileDialog(shell);
		String open = dialog.open();

		if (open != null) {
			eventBroker.post("orgdawnsciprototypee4nano", open);
		}
	}
}


text:
/*
  Process Connect
    - Connects a Component to a Process to receive its data as props

    export default statics(
      {
        dashboard: ['actions', 'selectors']
      },
      ({ selectors, actions }) => (
        connect(
          state => ({
            grid: selectors.grid(state)
          }),
          actions
        )(DashboardGrid)
      ),
      { prefixed: false }
    )
*/
import React from 'react'
import { getRecord, getRecords } from './registry'

export default (selected, connector, config = {}) => {
  return connector(getRecords(selected, config) || {})
}


text:
import type { Locale } from '../types'
import formatDistance from './_lib/formatDistance/index'
import formatLong from './_lib/formatLong/index'
import formatRelative from './_lib/formatRelative/index'
import localize from './_lib/localize/index'
import match from './_lib/match/index'

/**
 * @type {Locale}
 * @category Locales
 * @summary Hebrew locale.
 * @language Hebrew
 * @iso-639-2 heb
 * @author Nir Lahad [@nirlah]{@link https://github.com/nirlah}
 */
const locale: Locale = {
  code: 'he',
  formatDistance: formatDistance,
  formatLong: formatLong,
  formatRelative: formatRelative,
  localize: localize,
  match: match,
  options: {
    weekStartsOn: 0 /* Sunday */,
    firstWeekContainsDate: 1,
  },
}

export default locale


text:
FROM orchardup/python:2.7
RUN mkdir /code
WORKDIR /code
ADD requirements.txt /code/
RUN pip install -r requirements.txt
ADD . /code
ENV PYTHONUNBUFFERED 1


text:
<!DOCTYPE html>

    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">

    <title>MDInsider ♥ Open Source / Gilt's Heather Fleming Is a "Woman Who Rocks"!</title>

    <meta name="author" content="MDInsider, Inc.">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">

    <link rel="shortcut icon" href="/assets/themes//img/favicon.ico">
    <link href="/atom.xml" type="application/atom+xml" rel="alternate" title="Sitewide ATOM Feed">
    <link href="/rss.xml" type="application/rss+xml" rel="alternate" title="Sitewide RSS Feed">

    <link rel="stylesheet" href="//maxcdn.bootstrapcdn.com/font-awesome/4.3.0/css/font-awesome.min.css">
    <link rel="stylesheet" href="/assets/themes//css/github-light.css">
    <link rel="stylesheet/less" href="/assets/themes//css/style.less">

    Join MD Insider Tech
    MDInsider.com

            Categories

              <input type="search" placeholder="Search …" title="Search for:" />

            <menu id="categories-menu">

              <menuitem>
                AWS
              </menuitem>

              <menuitem>
                Leadership
              </menuitem>

              <menuitem>
                agile
              </menuitem>

              <menuitem>
                analytics
              </menuitem>

              <menuitem>
                aws
              </menuitem>

              <menuitem>
                blog
              </menuitem>

              <menuitem>
                conferences
              </menuitem>

              <menuitem>
                culture
              </menuitem>

              <menuitem>
                deployment
              </menuitem>

              <menuitem>
                front-end
              </menuitem>

              <menuitem>
                mobile
              </menuitem>

              <menuitem>
                scala
              </menuitem>

              <menuitem>
                swift
              </menuitem>

              <menuitem>
                tech
              </menuitem>

              <menuitem>
                tvOS
              </menuitem>

            </menu>
            <menu id="search-results">
            </menu>

Tech Blog

Gilt's Heather Fleming Is a "Woman Who Rocks"!

    <time>18 September 2014</time>

Fresh from her presentation (along with Gilt Director of Program Management Justin Riservato; together they are “Flemivato”) at this year’s Atlassian Summit in San Francisco, Gilt Senior Director, PMO Heather Fleming is featured in Ispossible in Tech’s “Women Who Rock” video montage. Ispossible aims to increase the number of women leaders in tech. Check out Twitter and look up the hashtags #GLOBALWOMENINTECH #ISPOSSIBLEINTECH and  #ISPOSSIBLEWWR to learn more about their awareness-raising efforts and to see videos of other “women who rock”!

    Gilt 340

    Gilt Groupe 282

    Gilt Tech 287

    gilttech 332

    Heather Fleming 16

    Justin Riservato 12

    PMO 27

    program management office 3

    women in tech 15

    Atlassian 6

    summit 1

    Join MD Insider Tech
    MDInsider.com

          © 2015 MDInsider, Inc. • Archives


text:
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
    <parent>
        <artifactId>cola-lib</artifactId>
        <groupId>com.cola.lib</groupId>
        <version>0.0.1</version>
    </parent>

    <modelVersion>4.0.0</modelVersion>
    <groupId>com.cola.lib.jpa</groupId>
    <artifactId>cola-jpa</artifactId>
    <packaging>jar</packaging>

    <dependencies>
        <dependency>
            <groupId>com.cola.lib.cache</groupId>
            <artifactId>cola-cache</artifactId>
            <version>${project.version}</version>
        </dependency>
        <dependency>
            <groupId>com.cola.lib.logging</groupId>
            <artifactId>cola-logging</artifactId>
            <version>${project.version}</version>
        </dependency>
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-data-jpa</artifactId>
        </dependency>
        <dependency>
            <groupId>com.zaxxer</groupId>
            <artifactId>HikariCP</artifactId>
        </dependency>
        <dependency>
            <groupId>com.alibaba</groupId>
            <artifactId>druid</artifactId>
        </dependency>
        <dependency>
            <groupId>mysql</groupId>
            <artifactId>mysql-connector-java</artifactId>
        </dependency>
    </dependencies>
</project>


text:
using UnityEngine;
using System.Collections;
using System.Collections.Generic;
using System;

public class HaarWavelet
{
	/// <summary>
	/// 差分と高さをまとめておくためのクラス
	/// </summary>
	public class ScalePack
	{
		float[] diff;
		float[] length;

		public int Scale { get; private set; }
		public int Size { get; private set; }
		public float[] Diff
		{
			get { return diff; }
		}
		public float[] Length
		{
			get { return length; }
		}

		public ScalePack(int size, int scale)
		{
			Scale = scale;
			Size = size;
			diff = new float[size];
			length = new float[size];
		}
	}

	float[] values = null;
	ScalePack[] packs;
	int scale;

	public HaarWavelet(int scale, float[] values, bool squared = true)
	{
		int scale_size = (int)Mathf.Log(values.Length, 2);	// 2^nに桁落とし
		int size = 1 << (scale_size - 1);

		this.values = new float[values.Length];

		if (scale_size > scale)
			throw new IndexOutOfRangeException("入力信号に対してスケールが大きすぎます : " + scale_size.ToString() + " > " + scale.ToString());

		if (!squared)	// 入力信号がn^2じゃない場合,自動的に正規化する
		{
			for (int i = 0; i < values.Length; i++)
			{
				values[i] = values[i] * values[i];	// sqrt(n^2)
			}
		}

		this.scale = scale;
		Array.Copy(values, 0, this.values, 0, size);
		InitializeSpace(scale, size);
	}

	void InitializeSpace(int scale, int size)
	{
		packs = new ScalePack[scale];

		int now = size;
		for (int i = 0; i < scale; i++)
		{
			packs[i] = new ScalePack(now, scale);
			now >>= 1;
		}
	}

	ScalePack ComputeScale(int depth_of_scale)
	{
		int prev = depth_of_scale - 1;
		for (int i = 0; i < packs[depth_of_scale].Size; i++)
		{
			int i2 = i * 2;
			int i21 = i * 2 + 1;
			packs[depth_of_scale].Diff[i] = packs[prev].Length[i2] - packs[prev].Length[i21];	// 自乗したらあかん
			packs[depth_of_scale].Length[i] = (packs[prev].Length[i2] + packs[prev].Length[i21]) * 0.5f;
		}
		return packs[depth_of_scale];
	}

	public ScalePack[] ComputeScales(int scale)
	{
		if (!(scale > 0) || scale > this.scale)
			throw new IndexOutOfRangeException("スケールは 1 以上," + scale.ToString() + " より小さい値を指定して下さい.");

		ScalePack[] scales = new ScalePack[scale];

		scales[0] = packs[0];
		for (int i = 1; i < scale; i++)
			scales[i] = ComputeScale(i);

		return scales;
	}

	public ScalePack[] ComputeScales()
	{
		return ComputeScales(scale);
	}
}


text:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Neptuo.Activators
{
    /// <summary>
    /// Factory class for the instance of <see cref="IFactory{T}"/>.
    /// </summary>
    public static class Factory
    {
        /// <summary>
        /// Creates new instance that uses <paramref name="getter"/> to providing instances.
        /// </summary>
        /// <typeparam name="T">The type of the object the factory will be creating.</typeparam>
        /// <param name="getter">Instances provider delegate.</param>
        /// <returns>The instance of the factory.</returns>
        public static IFactory<T> Getter<T>(Func<T> getter)
        {
            return new GetterFactory<T>(getter);
        }

        /// <summary>
        /// Creates new instance that uses <paramref name="getter"/> to providing instances.
        /// </summary>
        /// <typeparam name="T">The type of the object the factory will be creating.</typeparam>
        /// <param name="getter">Instances provider delegate.</param>
        /// <returns>The instance of the factory.</returns>
        public static IFactory<T, TContext> Getter<T, TContext>(Func<TContext, T> getter)
        {
            return new GetterFactory<T, TContext>(getter);
        }

        /// <summary>
        /// Create new instance from already created singleton object.
        /// </summary>
        /// <typeparam name="T">The type of the object the factory will be creating.</typeparam>
        /// <param name="instance">Singleton object.</param>
        /// <returns>The instance of the factory.</returns>
        public static IFactory<T> Instance<T>(T instance)
        {
            return new InstanceFactory<T>(instance);
        }

        /// <summary>
        /// Creates new instance from <paramref name="getter"/>.
        /// </summary>
        /// <typeparam name="T">The type of the object the factory will be creating.</typeparam>
        /// <param name="getter">The delegate to access singleton object.</param>
        /// <returns>The instance of the factory.</returns>
        public static IFactory<T> Instance<T>(Func<T> getter)
        {
            return new InstanceFactory<T>(getter);
        }

        /// <summary>
        /// Creates new instance that uses default constructor for creating instances.
        /// </summary>
        /// <typeparam name="T">The type of the object the factory will be creating.</typeparam>
        /// <returns>The instance of the factory.</returns>
        public static IFactory<T> Default<T>()
            where T  : new()
        {
            return new DefaultFactory<T>();
        }
    }
}


text:
itk_fetch_module(VariationalRegistration
  "A module to perform variational image registration. http://hdl.handle.net/10380/3460"
  GIT_REPOSITORY https://github.com/VariationalRegistration/VariationalRegistration.git
  GIT_TAG 706be428e5e90791005a0924fbc3dd8b2428bf11
  )


text:
'use strict';

var Scene2D = require('./scene2d');
var Plots = require('../plots');
var xmlnsNamespaces = require('../../constants/xmlns_namespaces');

exports.name = 'gl2d';

exports.attr = ['xaxis', 'yaxis'];

exports.idRoot = ['x', 'y'];

exports.idRegex = {
    x: /^x([2-9]|[1-9][0-9]+)?$/,
    y: /^y([2-9]|[1-9][0-9]+)?$/
};

exports.attrRegex = {
    x: /^xaxis([2-9]|[1-9][0-9]+)?$/,
    y: /^yaxis([2-9]|[1-9][0-9]+)?$/
};

exports.attributes = require('../cartesian/attributes');

exports.plot = function plotGl2d(gd) {
    var fullLayout = gd._fullLayout,
        fullData = gd._fullData,
        subplotIds = Plots.getSubplotIds(fullLayout, 'gl2d');

    for(var i = 0; i < subplotIds.length; i++) {
        var subplotId = subplotIds[i],
            subplotObj = fullLayout._plots[subplotId],
            fullSubplotData = Plots.getSubplotData(fullData, 'gl2d', subplotId);

        // ref. to corresp. Scene instance
        var scene = subplotObj._scene2d;

        // If Scene is not instantiated, create one!
        if(scene === undefined) {
            scene = new Scene2D({
                id: subplotId,
                graphDiv: gd,
                container: gd.querySelector('.gl-container'),
                staticPlot: gd._context.staticPlot,
                plotGlPixelRatio: gd._context.plotGlPixelRatio
            },
                fullLayout
            );

            // set ref to Scene instance
            subplotObj._scene2d = scene;
        }

        scene.plot(fullSubplotData, gd.calcdata, fullLayout, gd.layout);
    }
};

exports.clean = function(newFullData, newFullLayout, oldFullData, oldFullLayout) {
    var oldSceneKeys = Plots.getSubplotIds(oldFullLayout, 'gl2d');

    for(var i = 0; i < oldSceneKeys.length; i++) {
        var id = oldSceneKeys[i],
            oldSubplot = oldFullLayout._plots[id];

        // old subplot wasn't gl2d; nothing to do
        if(!oldSubplot._scene2d) continue;

        // if no traces are present, delete gl2d subplot
        var subplotData = Plots.getSubplotData(newFullData, 'gl2d', id);
        if(subplotData.length === 0) {
            oldSubplot._scene2d.destroy();
            delete oldFullLayout._plots[id];
        }
    }
};

exports.toSVG = function(gd) {
    var fullLayout = gd._fullLayout,
        subplotIds = Plots.getSubplotIds(fullLayout, 'gl2d'),
        size = fullLayout._size;

    for(var i = 0; i < subplotIds.length; i++) {
        var subplot = fullLayout._plots[subplotIds[i]],
            scene = subplot._scene2d;

        var imageData = scene.toImage('png');
        var image = fullLayout._glimages.append('svg:image');

        image.attr({
            xmlns: xmlnsNamespaces.svg,
            'xlink:href': imageData,
            x: size.l,
            y: size.t,
            width: size.w,
            height: size.h,
            preserveAspectRatio: 'none'
        });

        scene.destroy();
    }
};


text:
{% if meeting.book %}

  {{ meeting.book }}

    {% include meeting.html %}
{% else %}
  {% include meeting.html %}
{% endif %}


text:
package gov.hhs.fha.nhinc.transform.audit;

import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertNotNull;
import gov.hhs.fha.nhinc.common.auditlog.LogEventRequestType;
import gov.hhs.fha.nhinc.common.nhinccommon.AssertionType;
import gov.hhs.fha.nhinc.common.nhinccommon.HomeCommunityType;
import gov.hhs.fha.nhinc.common.nhinccommon.NhinTargetSystemType;
import gov.hhs.fha.nhinc.common.nhinccommon.UserType;
import gov.hhs.fha.nhinc.nhinclib.NhincConstants;
import oasis.names.tc.emergency.edxl.de._1.EDXLDistribution;

import org.junit.After;
import org.junit.AfterClass;
import org.junit.Before;
import org.junit.BeforeClass;
import org.junit.Test;

/**
 *
 * @author dunnek
 */
public class AdminDistTransformsTest {

    public AdminDistTransformsTest() {
    }

    @BeforeClass
    public static void setUpClass() throws Exception {
    }

    @AfterClass
    public static void tearDownClass() throws Exception {
    }

    @Before
    public void setup() {
    }

    @After
    public void tearDown() {
    }

    /**
     * Tests for null audit message if EDXLDistribution is null.
     */
    @Test
    public void testTransformEDXLDistributionRequestToAuditMsg_Empty() {
        EDXLDistribution message = new EDXLDistribution();
        AssertionType assertion = new AssertionType();

        AdminDistTransforms instance = new AdminDistTransforms();

        LogEventRequestType expResult = null;
        LogEventRequestType result = instance.transformEDXLDistributionRequestToAuditMsg(message, assertion,
                NhincConstants.AUDIT_LOG_INBOUND_DIRECTION, NhincConstants.AUDIT_LOG_ENTITY_INTERFACE);

        assertEquals(expResult, result);

    }

    /**
     * Test the HCID can be pulled from the local community for INBOUND ENTITY in the
     * audit message.
     */
    @Test
    public void testTransformEDXLDistributionRequestToAuditMsg_Good_HCIDfromLocalHCID() {
    	final String LOCAL_HCID = "1.1";
    	EDXLDistribution message = new EDXLDistribution();
        AssertionType assertion = new AssertionType();

        setUserForAssertion(assertion, LOCAL_HCID);

        AdminDistTransforms instance = new AdminDistTransforms(){
        	@Override
        	protected String getHomeCommunityFromMapping(){
        		return LOCAL_HCID;
        	}
        };

        LogEventRequestType result = instance.transformEDXLDistributionRequestToAuditMsg(message, assertion,
                NhincConstants.AUDIT_LOG_INBOUND_DIRECTION, NhincConstants.AUDIT_LOG_ENTITY_INTERFACE);

        assertNotNull(result);
        assertEquals(NhincConstants.AUDIT_LOG_INBOUND_DIRECTION, result.getDirection());
        assertEquals(NhincConstants.AUDIT_LOG_ENTITY_INTERFACE, result.getInterface());

        assertNotNull(result.getAuditMessage());
        assertEquals(1, result.getAuditMessage().getActiveParticipant().size());

        assertNotNull(result.getAuditMessage().getEventIdentification());
        assertEquals(AuditDataTransformConstants.EVENT_ID_CODE_SYS_NAME_T63, result.getAuditMessage()
                .getEventIdentification().getEventID().getCode());
        assertEquals(AuditDataTransformConstants.EVENT_ID_CODE_SYS_NAME_T63, result.getAuditMessage()
                .getEventIdentification().getEventID().getCodeSystemName());
        assertEquals(result.getAuditMessage().getAuditSourceIdentification().get(0).getAuditSourceID(), LOCAL_HCID);

    }

    /**
     * Test the HCID can be pulled from the assertion for INBOUND NHIN in the
     * audit message.
     */
    @Test
    public void testTransformEDXLDistributionRequestToAuditMsg_Good_HCIDfromAssertion() {
    	final String LOCAL_HCID = "1.1";
    	EDXLDistribution message = new EDXLDistribution();
        AssertionType assertion = new AssertionType();
        HomeCommunityType homeCommunity = new HomeCommunityType();
        homeCommunity.setHomeCommunityId(LOCAL_HCID);
        assertion.setHomeCommunity(homeCommunity);

        setUserForAssertion(assertion, LOCAL_HCID);

        AdminDistTransforms instance = new AdminDistTransforms();

        LogEventRequestType result = instance.transformEDXLDistributionRequestToAuditMsg(message, assertion,
                NhincConstants.AUDIT_LOG_INBOUND_DIRECTION, NhincConstants.AUDIT_LOG_NHIN_INTERFACE);

        assertNotNull(result);
        assertEquals(NhincConstants.AUDIT_LOG_INBOUND_DIRECTION, result.getDirection());
        assertEquals(NhincConstants.AUDIT_LOG_NHIN_INTERFACE, result.getInterface());

        assertNotNull(result.getAuditMessage());
        assertEquals(1, result.getAuditMessage().getActiveParticipant().size());

        assertNotNull(result.getAuditMessage().getEventIdentification());
        assertEquals(AuditDataTransformConstants.EVENT_ID_CODE_SYS_NAME_T63, result.getAuditMessage()
                .getEventIdentification().getEventID().getCode());
        assertEquals(AuditDataTransformConstants.EVENT_ID_CODE_SYS_NAME_T63, result.getAuditMessage()
                .getEventIdentification().getEventID().getCodeSystemName());
        assertEquals(result.getAuditMessage().getAuditSourceIdentification().get(0).getAuditSourceID(), LOCAL_HCID);

    }

    /**
     * Tests the HCID can be pulled from the target for NHINC OUTBOUND in the
     * result message.
     */
    @Test
    public void testTransformEDXLDistributionRequestToAuditMsg_Good_HCIDfromTarget() {
    	final String LOCAL_HCID = "2.2";
    	EDXLDistribution message = new EDXLDistribution();
        AssertionType assertion = new AssertionType();

        setUserForAssertion(assertion, LOCAL_HCID);

        NhinTargetSystemType target = new NhinTargetSystemType();
        HomeCommunityType homeCommunity = new HomeCommunityType();
        homeCommunity.setHomeCommunityId(LOCAL_HCID);
        target.setHomeCommunity(homeCommunity);

        AdminDistTransforms instance = new AdminDistTransforms();

        LogEventRequestType result = instance.transformEDXLDistributionRequestToAuditMsg(message, assertion,
                target, NhincConstants.AUDIT_LOG_OUTBOUND_DIRECTION, NhincConstants.AUDIT_LOG_NHIN_INTERFACE);

        assertNotNull(result);
        assertEquals(NhincConstants.AUDIT_LOG_OUTBOUND_DIRECTION, result.getDirection());
        assertEquals(NhincConstants.AUDIT_LOG_NHIN_INTERFACE, result.getInterface());

        assertNotNull(result.getAuditMessage());
        assertEquals(1, result.getAuditMessage().getActiveParticipant().size());

        assertNotNull(result.getAuditMessage().getEventIdentification());
        assertEquals(AuditDataTransformConstants.EVENT_ID_CODE_SYS_NAME_T63, result.getAuditMessage()
                .getEventIdentification().getEventID().getCode());
        assertEquals(AuditDataTransformConstants.EVENT_ID_CODE_SYS_NAME_T63, result.getAuditMessage()
                .getEventIdentification().getEventID().getCodeSystemName());
        assertEquals(result.getAuditMessage().getAuditSourceIdentification().get(0).getAuditSourceID(), LOCAL_HCID);

    }

    /**
     * Test of areRequiredUserTypeFieldsNull method, of class AdminDistTransforms.
     */
    @Test
    public void testAreRequiredUserTypeFieldsNull() {
        System.out.println("areRequiredUserTypeFieldsNull");

        AssertionType oAssertion = null;
        AdminDistTransforms instance = new AdminDistTransforms();

        boolean expResult = true;
        boolean result = instance.areRequiredUserTypeFieldsNull(oAssertion);

        assertEquals(expResult, result);

    }

    @Test
    public void testAreRequiredUserTypeFieldsNull_NoUserName() {
        System.out.println("testAreRequiredUserTypeFieldsNull_NoUserName");
        AssertionType assertion = new AssertionType();
        assertion.setUserInfo(new UserType());

        AdminDistTransforms instance = new AdminDistTransforms();

        boolean expResult = true;
        boolean result = instance.areRequiredUserTypeFieldsNull(assertion);

        assertEquals(expResult, result);

    }

    @Test
    public void testAreRequiredUserTypeFieldsNull_NoHCID() {
        System.out.println("testAreRequiredUserTypeFieldsNull_NoHCID");
        AssertionType assertion = new AssertionType();

        UserType user = new UserType();
        HomeCommunityType hc = new HomeCommunityType();

        user.setUserName("test");
        user.setOrg(hc);

        assertion.setUserInfo(user);

        AdminDistTransforms instance = new AdminDistTransforms();

        boolean expResult = true;
        boolean result = instance.areRequiredUserTypeFieldsNull(assertion);

        assertEquals(expResult, result);
    }

    @Test
    public void testAreRequiredUserTypeFieldsNull_NoHCName() {
        System.out.println("testAreRequiredUserTypeFieldsNull_NoHCName");
        AssertionType assertion = new AssertionType();

        UserType user = new UserType();
        HomeCommunityType hc = new HomeCommunityType();

        hc.setHomeCommunityId("123");

        user.setUserName("test");
        user.setOrg(hc);

        assertion.setUserInfo(user);

        AdminDistTransforms instance = new AdminDistTransforms();

        boolean expResult = true;
        boolean result = instance.areRequiredUserTypeFieldsNull(assertion);

        assertEquals(expResult, result);

    }

    @Test
    public void testAreRequiredUserTypeFieldsNull_False() {
        System.out.println("testAreRequiredUserTypeFieldsNull_False");
        AssertionType assertion = new AssertionType();

        UserType user = new UserType();
        HomeCommunityType hc = new HomeCommunityType();

        hc.setHomeCommunityId("123");
        hc.setName("test");

        user.setUserName("test");
        user.setOrg(hc);

        assertion.setUserInfo(user);

        AdminDistTransforms instance = new AdminDistTransforms();

        boolean expResult = false;
        boolean result = instance.areRequiredUserTypeFieldsNull(assertion);

        assertEquals(expResult, result);

    }

    private void setUserForAssertion(AssertionType assertion, String communityId){
    	UserType user = new UserType();
        HomeCommunityType hc = new HomeCommunityType();

        hc.setHomeCommunityId(communityId);
        hc.setName("test");

        user.setUserName("test");

        user.setOrg(hc);

        assertion.setUserInfo(user);
    }
}


text:
ACCEPTED

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

#### Published in
Afonso-Carillo & Sobrino. 2003. Phycologia 42 (2): 138-150

#### Original name
null

### Remarks
null


text:
using System;
using System.Collections.Generic;
using Iodine.Runtime;

namespace Iodine.Compiler
{
    class ControlFlowOptimization : IBytecodeOptimization
    {
        class ReachableRegion
        {
            public int Start { private set; get; }

            public int End { private set; get; }

            public int Size {
                get {
                    return this.End - this.Start;
                }
            }

            public ReachableRegion (int start, int end)
            {
                this.Start = start;
                this.End = end;
            }
        }

        public void PerformOptimization (CodeObject method)
        {
            var regions = new List<ReachableRegion> ();
            int reachableSize = 0;
            FindRegion (method, regions, 0);
            foreach (ReachableRegion region in regions) {
                reachableSize += region.Size + 1;
            }
            Instruction[] oldInstructions = method.Instructions;
            Instruction[] newInstructions = new Instruction[method.Instructions.Length];
            int next = 0;
            for (int i = 0; i < method.Instructions.Length; i++) {
                if (IsReachable (regions, i)) {
                    newInstructions [next++] = oldInstructions [i];
                } else {
                    ShiftLabels (next, oldInstructions);
                    ShiftLabels (next, newInstructions);
                }
            }

            method.Instructions = newInstructions;
        }

        private void FindRegion (CodeObject method, List<ReachableRegion> regions, int start)
        {
            if (IsReachable (regions, start)) {
                return;
            }

            for (int i = start; i < method.Instructions.Length; i++) {
                Instruction ins = method.Instructions [i];

                if (ins.OperationCode == Opcode.Jump) {
                    regions.Add (new ReachableRegion (start, i));
                    FindRegion (method, regions, ins.Argument);
                    return;
                }

                if (ins.OperationCode == Opcode.JumpIfTrue ||
                           ins.OperationCode == Opcode.JumpIfFalse ||
                           ins.OperationCode == Opcode.PushExceptionHandler) {
                    regions.Add (new ReachableRegion (start, i));
                    FindRegion (method, regions, i + 1);
                    FindRegion (method, regions, ins.Argument);
                    return;
                }

                if (ins.OperationCode == Opcode.Return) {
                    regions.Add (new ReachableRegion (start, i));
                    return;
                }
            }
            regions.Add (new ReachableRegion (start, method.Instructions.Length));
        }

        private void ShiftLabels (int start, Instruction[] instructions)
        {
            for (int i = 0; i < instructions.Length; i++) {
                Instruction ins = instructions [i];
                if (ins.OperationCode == Opcode.Jump || ins.OperationCode == Opcode.JumpIfFalse ||
                    ins.OperationCode == Opcode.JumpIfTrue ||
                    ins.OperationCode == Opcode.PushExceptionHandler) {

                    if (ins.Argument > start) {
                        instructions [i] = new Instruction (ins.Location, ins.OperationCode,
                            ins.Argument - 1);
                    }
                }

            }
        }

        private bool IsReachable (List<ReachableRegion> regions, int addr)
        {
            foreach (ReachableRegion region in regions) {
                if (region.Start <= addr && addr <= region.End) {
                    return true;
                }
            }
            return false;
        }
    }
}


text:
import discord
import logging
import random

import claspbot.utils.number as number

from discord.ext import commands

logger = logging.getLogger('discord')

class Trivial:
    """
    handle trivial commands
    """
    def __init__(self, bot):
        logger.info("Loaded extension: {}".format(self.__class__.__name__))
        self.bot = bot

    @commands.command()
    async def roll(self, message: str):
        n = number.parse_int(message)
        if n is not None:
            msg = "You rolled {}".format(random.randint(0, n))
            await self.bot.say(msg)
        else:
            await self.bot.say("Invalid number...")

    @commands.command()
    async def dice(self, message: str):
        msg = message.lower().split(sep='d', maxsplit=1)
        status = True
        print(msg)
        if len(msg) == 2:
            n, sides = number.parse_int(msg[0]), number.parse_int(msg[1])
            if n is None or sides is None:
                status = False
        else:
            status = False

        if status is True:
            total = sum([random.randint(1, sides) for i in range(n)])
            await self.bot.say("You rolled {}".format(total))
        else:
            await self.bot.say("either that's invalid or I'm dumb FeelsBadMan")

    @commands.command()
    async def avatar(self, user: discord.User):
        await self.bot.say("{}".format(user.avatar_url))

def setup(bot):
    bot.add_cog(Trivial(bot))


text:
from kolibri.utils.time import local_now
from django.conf import settings

from ..content_db_router import using_content_database
from ..models import ChannelMetadata, ChannelMetadataCache
from .channels import get_channel_ids_for_content_database_dir

def update_channel_metadata_cache():
    """
    After a channel is imported, or when the devserver is started,
    scan through the settings.CONTENT_DATABASE_DIR folder for all channel content databases,
    and pull the data from each database's ChannelMetadata object to update the ChannelMetadataCache
    object in the default database to ensure they are in sync.
    """
    db_names = get_channel_ids_for_content_database_dir(settings.CONTENT_DATABASE_DIR)
    # Delete ChannelMetadataCache objects in default db that are not found in CONTENT_DATABASE_DIR
    ChannelMetadataCache.objects.exclude(id__in=db_names).delete()
    # sync the ChannelMetadataCache objects in default db with ChannelMetadata objects in CONTENT_DATABASE_DIR
    for db_name in db_names:
        with using_content_database(db_name):
            update_values = ChannelMetadata.objects.values()[0]

        ch_metadata_obj, _ = ChannelMetadataCache.objects.update_or_create(
            id=db_name,
            defaults=update_values,
        )

        # Records a new last_updated only if channel is brand new. Does not
        # handle case where channel's version is upgraded, which is not
        # yet supported on UI anyway
        if ch_metadata_obj.last_updated is None:
            ch_metadata_obj.last_updated = local_now()
            ch_metadata_obj.save()

    # Fix #1818.1 content database files get locked (this is called on startup)
    from django.db import connections
    connections.close_all()


text: from .bid_ask_stream import ingest


text:
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
	<modelVersion>4.0.0</modelVersion>
	<groupId>com.albert.shiro</groupId>
	<artifactId>lesson-4</artifactId>
	<packaging>war</packaging>
	<version>1.0-SNAPSHOT</version>
	<name>Realm及相关</name>
	<dependencies>
		<dependency>
            <groupId>net.sf.ehcache</groupId>
            <artifactId>ehcache-core</artifactId>
            <version>2.6.6</version>
        </dependency>
		<dependency>
			<groupId>junit</groupId>
			<artifactId>junit</artifactId>
			<version>4.9</version>
		</dependency>
		<dependency>
			<groupId>commons-logging</groupId>
			<artifactId>commons-logging</artifactId>
			<version>1.1.3</version>
		</dependency>
		<dependency>
			<groupId>org.apache.shiro</groupId>
			<artifactId>shiro-core</artifactId>
			<version>1.2.2</version>
		</dependency>
		<dependency>
			<groupId>mysql</groupId>
			<artifactId>mysql-connector-java</artifactId>
			<version>5.1.25</version>
		</dependency>
		<dependency>
			<groupId>com.alibaba</groupId>
			<artifactId>druid</artifactId>
			<version>0.2.23</version>
		</dependency>
		<dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-jdbc</artifactId>
            <version>4.0.0.RELEASE</version>
        </dependency>
	</dependencies>
</project>


text:
NOTE: This is fork, `autocomplete+` was adjusted to make it work fine with `autocomplete-haxe` package(by switching to async providers + show completion on dot). You can find original repository at https://github.com/saschagehlich/autocomplete-plus

[View the changelog](https://github.com/saschagehlich/autocomplete-plus/blob/master/CHANGELOG.md)

View and insert possible completions in the editor while typing

![Autocomplete+](http://s14.directupload.net/images/140304/y7r7g5df.gif)

**Please note:** In the example above I have "Enable Auto Activation" enabled.

![Enable auto activation setting](https://cloud.githubusercontent.com/assets/119684/3029677/fab41bb0-e037-11e3-85bf-a696996f2478.png)

## Installation

You can install autocomplete+ using the Preferences pane.

## Plugins

Also grab one of these awesome additions for autocomplete+:

* [autocomplete-snippets](https://atom.io/packages/autocomplete-snippets)
* [autocomplete-paths](https://atom.io/packages/autocomplete-paths)

## Usage

Just type some stuff, autocomplete+ will automatically show you some suggestions.
Press `UP` and `DOWN` to select another suggestion, press `TAB` to confirm your selection.
Additional confirmation keymapping can be customised in your keymap.cson:
```coffeescript
".autocomplete-plus input.hidden-input":
  "enter": "autocomplete-plus:confirm"
```

## Features

* Shows autocompletion suggestions while typing
* Two modes: Live and delayed autocompletion (instant might slow down performance)
* Wordlist generation happens initially and on save (saves performance)
* Suggestions are calculated using `fuzzaldrin` (better results)
* File blacklisting
* Automatic wordlist expansion while typing

## Geeky Stuff: Adding Suggestion Providers

Since version 0.12.0, other packages are able to register suggestion providers to the autocomplete-plus package.

[See the tutorial on how to create and register suggestion providers](https://github.com/saschagehlich/autocomplete-plus/wiki/Tutorial:-Registering-and-creating-a-suggestion-provider)


text:
class S1Interval {
 public:
  // Constructor.  Both endpoints must be in the range -Pi to Pi inclusive.
  // The value -Pi is converted internally to Pi except for the Full()
  // and Empty() intervals.
  S1Interval(double lo, double hi);

  // The default constructor creates an empty interval.
  //
  // Note: Don't construct an interval using the default constructor and
  // set_lo()/set_hi().  If you need to set both endpoints, use the
  // constructor above:
  //
  //   lng_bounds_ = S1Interval(lng_lo, lng_hi);
  S1Interval();

  // Returns the empty interval.
  static S1Interval Empty();

  // Returns the full interval.
  static S1Interval Full();

  // Convenience method to construct an interval containing a single point.
  static S1Interval FromPoint(double p);

  // Convenience method to construct the minimal interval containing
  // the two given points.  This is equivalent to starting with an empty
  // interval and calling AddPoint() twice, but it is more efficient.
  static S1Interval FromPointPair(double p1, double p2);

  // Accessors methods.
  double lo() const { return bounds_[0]; }
  double hi() const { return bounds_[1]; }

  // Methods that allow the S1Interval to be accessed as a vector.  (The
  // recommended style is to use lo() and hi() whenever possible, but these
  // methods are useful when the endpoint to be selected is not constant.)
  //
  // Only const versions of these methods are provided, since S1Interval
  // has invariants that must be maintained after each update.
  double operator[](int i) const { return bounds_[i]; }
  const Vector2_d& bounds() const { return bounds_; }

  // An interval is valid if neither bound exceeds Pi in absolute value,
  // and the value -Pi appears only in the Empty() and Full() intervals.
  bool is_valid() const;

  // Return true if the interval contains all points on the unit circle.
  bool is_full() const { return lo() == -M_PI && hi() == M_PI; }

  // Return true if the interval is empty, i.e. it contains no points.
  bool is_empty() const { return lo() == M_PI && hi() == -M_PI; }

  // Return true if lo() > hi().  (This is true for empty intervals.)
  bool is_inverted() const { return lo() > hi(); }

  // Return the midpoint of the interval.  For full and empty intervals,
  // the result is arbitrary.
  double GetCenter() const;

  // Return the length of the interval.  The length of an empty interval
  // is negative.
  double GetLength() const;

  // Return the complement of the interior of the interval.  An interval and
  // its complement have the same boundary but do not share any interior
  // values.  The complement operator is not a bijection, since the complement
  // of a singleton interval (containing a single value) is the same as the
  // complement of an empty interval.
  S1Interval Complement() const;

  // Return the midpoint of the complement of the interval. For full and empty
  // intervals, the result is arbitrary. For a singleton interval (containing a
  // single point), the result is its antipodal point on S1.
  double GetComplementCenter() const;

  // Return true if the interval (which is closed) contains the point 'p'.
  bool Contains(double p) const;

  // Return true if the interior of the interval contains the point 'p'.
  bool InteriorContains(double p) const;

  // Return true if the interval contains the given interval 'y'.
  // Works for empty, full, and singleton intervals.
  bool Contains(const S1Interval& y) const;

  // Returns true if the interior of this interval contains the entire
  // interval 'y'.  Note that x.InteriorContains(x) is true only when
  // x is the empty or full interval, and x.InteriorContains(S1Interval(p,p))
  // is equivalent to x.InteriorContains(p).
  bool InteriorContains(const S1Interval& y) const;

  // Return true if the two intervals contain any points in common.
  // Note that the point +/-Pi has two representations, so the intervals
  // [-Pi,-3] and [2,Pi] intersect, for example.
  bool Intersects(const S1Interval& y) const;

  // Return true if the interior of this interval contains any point of the
  // interval 'y' (including its boundary).  Works for empty, full, and
  // singleton intervals.
  bool InteriorIntersects(const S1Interval& y) const;

  // Return the Hausdorff distance to the given interval 'y'. For two
  // S1Intervals x and y, this distance is defined by
  //     h(x, y) = max_{p in x} min_{q in y} d(p, q),
  // where d(.,.) is measured along S1.
  double GetDirectedHausdorffDistance(const S1Interval& y) const;

  // Expand the interval by the minimum amount necessary so that it
  // contains the given point "p" (an angle in the range [-Pi, Pi]).
  void AddPoint(double p);

  // Return the closest point in the interval to the given point "p".
  // The interval must be non-empty.
  double Project(double p) const;

  // Return an interval that has been expanded on each side by the given
  // distance "margin".  If "margin" is negative, then shrink the interval on
  // each side by "margin" instead.  The resulting interval may be empty or
  // full.  Any expansion (positive or negative) of a full interval remains
  // full, and any expansion of an empty interval remains empty.
  S1Interval Expanded(double margin) const;

  // Return the smallest interval that contains this interval and the
  // given interval "y".
  S1Interval Union(const S1Interval& y) const;

  // Return the smallest interval that contains the intersection of this
  // interval with "y".  Note that the region of intersection may
  // consist of two disjoint intervals.
  S1Interval Intersection(const S1Interval& y) const;

  // Return true if two intervals contains the same set of points.
  bool operator==(const S1Interval& y) const;

  // Return true if two intervals do not contain the same set of points.
  bool operator!=(const S1Interval& y) const;

  // Return true if this interval can be transformed into the given interval by
  // moving each endpoint by at most "max_error" (and without the endpoints
  // crossing, which would invert the interval).  Empty and full intervals are
  // considered to start at an arbitrary point on the unit circle, thus any
  // interval with (length <= 2*max_error) matches the empty interval, and any
  // interval with (length >= 2*Pi - 2*max_error) matches the full interval.
  bool ApproxEquals(const S1Interval& y, double max_error = 1e-15) const;

  // Low-level methods to modify one endpoint of an existing S1Interval.
  // These methods should really be private because setting just one endpoint
  // can violate the invariants maintained by S1Interval.  In particular:
  //
  //  - It is not valid to call these methods on an Empty() or Full()
  //    interval, since these intervals do not have any endpoints.
  //
  //  - It is not allowed to set an endpoint to -Pi.  (When these methods are
  //    used internally, values of -Pi have already been normalized to Pi.)
  //
  // The preferred way to modify both endpoints of an interval is to use a
  // constructor, e.g. lng = S1Interval(lng_lo, lng_hi).
  void set_lo(double p);
  void set_hi(double p);

 private:
  enum ArgsChecked { ARGS_CHECKED };

  // Internal constructor that assumes that both arguments are in the
  // correct range, i.e. normalization from -Pi to Pi is already done.
  S1Interval(double lo, double hi, ArgsChecked dummy);

  // Return true if the interval (which is closed) contains the point 'p'.
  // Skips the normalization of 'p' from -Pi to Pi.
  bool FastContains(double p) const;

  Vector2_d bounds_;
};

inline S1Interval::S1Interval(double lo, double hi) : bounds_(lo, hi) {
  if (lo == -M_PI && hi != M_PI) set_lo(M_PI);
  if (hi == -M_PI && lo != M_PI) set_hi(M_PI);
  S2_DCHECK(is_valid());
}

inline S1Interval::S1Interval(double lo, double hi, ArgsChecked dummy)
  : bounds_(lo, hi) {
  S2_DCHECK(is_valid());
}

inline S1Interval::S1Interval() : bounds_(M_PI, -M_PI) {
}

inline S1Interval S1Interval::Empty() {
  return S1Interval();
}

inline S1Interval S1Interval::Full() {
  return S1Interval(-M_PI, M_PI, ARGS_CHECKED);
}

inline bool S1Interval::is_valid() const {
  return (std::fabs(lo()) <= M_PI && std::fabs(hi()) <= M_PI &&
          !(lo() == -M_PI && hi() != M_PI) &&
          !(hi() == -M_PI && lo() != M_PI));
}

inline bool S1Interval::operator==(const S1Interval& y) const {
  return lo() == y.lo() && hi() == y.hi();
}

inline bool S1Interval::operator!=(const S1Interval& y) const {
  return !operator==(y);
}

inline void S1Interval::set_lo(double p) {
  bounds_[0] = p;
  S2_DCHECK(is_valid());
}

inline void S1Interval::set_hi(double p) {
  bounds_[1] = p;
  S2_DCHECK(is_valid());
}

inline std::ostream& operator<<(std::ostream& os, const S1Interval& x) {
  return os << "[" << x.lo() << ", " << x.hi() << "]";
}

#endif  // S2_S1INTERVAL_H_


text:
<?php

namespace Symfony\Tests\Component\HttpFoundation;

use Symfony\Component\HttpFoundation\ServerBag;

/**
 * ServerBagTest
 *
 * @author Bulat Shakirzyanov <mallluhuct@gmail.com>
 */
class ServerBagTest extends \PHPUnit_Framework_TestCase
{
    public function testShouldExtractHeadersFromServerArray()
    {
        $server = array(
            'SOME_SERVER_VARIABLE' => 'value',
            'SOME_SERVER_VARIABLE2' => 'value',
            'ROOT' => 'value',
            'HTTP_CONTENT_TYPE' => 'text/html',
            'HTTP_CONTENT_LENGTH' => '0',
            'HTTP_ETAG' => 'asdf',
            'PHP_AUTH_USER' => 'foo',
            'PHP_AUTH_PW' => 'bar',
        );

        $bag = new ServerBag($server);

        $this->assertEquals(array(
            'CONTENT_TYPE' => 'text/html',
            'CONTENT_LENGTH' => '0',
            'ETAG' => 'asdf',
            'AUTHORIZATION' => 'Basic '.base64_encode('foo:bar'),
        ), $bag->getHeaders());
    }

    public function testHttpPasswordIsOptional()
    {
        $bag = new ServerBag(array('PHP_AUTH_USER' => 'foo'));

        $this->assertEquals(array('AUTHORIZATION' => 'Basic '.base64_encode('foo:')), $bag->getHeaders());
    }
}


text:
import React from 'react';
import PropTypes from 'prop-types';

export default function Section({ header, footer, children }) {
  return (

{header}

{children}

          {footer &&
{footer}
}

  );
}

Section.propTypes = {
  header: PropTypes.node.isRequired,
  footer: PropTypes.node,
  children: PropTypes.node.isRequired
};


text:
<?php

namespace duncan3dc\LaravelTests;

class CssTest extends AbstractTest
{

    public function testString(): void
    {
        $this->assertTemplateString("<link rel='stylesheet' type='text/css' href='/css/ok.css'>", "@css('ok')");
    }

    public function testExtension(): void
    {
        $this->assertTemplateString("<link rel='stylesheet' type='text/css' href='/css/ok.css'>", "@css('ok.css')");
    }

    public function testPath(): void
    {
        $this->assertTemplateString("<link rel='stylesheet' type='text/css' href='/alt/ok.css'>", "@css('/alt/ok.css')");
    }

    public function testVariable(): void
    {
        $this->assertTemplateString("<link rel='stylesheet' type='text/css' href='<?php echo e(\$file); ?>'>", "@css(\$file)");
    }

    public function testUrl(): void
    {
        $this->assertTemplateString("<link rel='stylesheet' type='text/css' href='https://res.com/ok.css'>", "@css('https://res.com/ok.css')");
    }

    public function testInsecureUrl(): void
    {
        $this->assertTemplateString("<link rel='stylesheet' type='text/css' href='http://res.com/ok.css'>", "@css('http://res.com/ok.css')");
    }

    public function testAlternativePath(): void
    {
        $this->directives = $this->directives->withCss("styles");
        $this->assertTemplateString("<link rel='stylesheet' type='text/css' href='/styles/path1.css'>", "@css('path1')");
    }

    public function testRootPath(): void
    {
        $this->directives = $this->directives->withCss("/");
        $this->assertTemplateString("<link rel='stylesheet' type='text/css' href='/path2.css'>", "@css('path2')");
    }

    public function testNoPath(): void
    {
        $this->directives = $this->directives->withCss("");
        $this->assertTemplateString("<link rel='stylesheet' type='text/css' href='/path3.css'>", "@css('path3')");
    }
}


text:
#include <linux/module.h>
#include <sound/pcm.h>
#include <sound/soc.h>
#include <asm/mach-types.h>
#include <video/omapdss.h>

#define DRV_NAME "omap-hdmi-audio"

static struct snd_soc_dai_link omap_hdmi_dai = {
	.name = "HDMI",
	.stream_name = "HDMI",
	.cpu_dai_name = "omap-hdmi-audio-dai",
	.platform_name = "omap-pcm-audio",
	.codec_name = "hdmi-audio-codec",
	.codec_dai_name = "hdmi-hifi",
};

static struct snd_soc_card snd_soc_omap_hdmi = {
	.name = "OMAPHDMI",
	.owner = THIS_MODULE,
	.dai_link = &omap_hdmi_dai,
	.num_links = 1,
};

static int omap_hdmi_probe(struct platform_device *pdev)
{
	struct snd_soc_card *card = &snd_soc_omap_hdmi;
	int ret;

	card->dev = &pdev->dev;

	ret = snd_soc_register_card(card);
	if (ret) {
		dev_err(&pdev->dev, "snd_soc_register_card failed (%d)\n", ret);
		card->dev = NULL;
		return ret;
	}
	return 0;
}

static int omap_hdmi_remove(struct platform_device *pdev)
{
	struct snd_soc_card *card = platform_get_drvdata(pdev);

	snd_soc_unregister_card(card);
	card->dev = NULL;
	return 0;
}

static struct platform_driver omap_hdmi_driver = {
	.driver = {
		.name = DRV_NAME,
		.owner = THIS_MODULE,
	},
	.probe = omap_hdmi_probe,
	.remove = omap_hdmi_remove,
};

module_platform_driver(omap_hdmi_driver);

MODULE_AUTHOR("Ricardo Neri <ricardo.neri@ti.com>");
MODULE_DESCRIPTION("OMAP HDMI machine ASoC driver");
MODULE_LICENSE("GPL");
MODULE_ALIAS("platform:" DRV_NAME);


text:
/* Created on: 2015-08-15
 *     Author: T.Delame (tdelame@gmail.com)
 */
# ifndef GRAPHICS_ORIGIN_MATRIX_H_
# define GRAPHICS_ORIGIN_MATRIX_H_

# include "../graphics_origin.h"
# include "vec.h"

# include <glm/glm.hpp>
# include <glm/gtc/matrix_transform.hpp>
# include <glm/gtx/transform.hpp>
# include <glm/gtc/type_ptr.hpp>
# include <glm/gtc/matrix_access.hpp>
BEGIN_GO_NAMESPACE

typedef glm::tmat4x4< real, glm::highp> mat4;
typedef glm::tmat3x3< real, glm::highp> mat3;

typedef glm::tmat4x4< gl_real, glm::highp> gl_mat4;
typedef glm::tmat3x3< gl_real, glm::highp> gl_mat3;

END_GO_NAMESPACE

# include <iosfwd>

namespace std {

  GO_API std::ostream& operator<<(std::ostream& os, const GO_NAMESPACE::mat3& v);
  GO_API std::ostream& operator<<(std::ostream& os, const GO_NAMESPACE::mat4& v);
  GO_API std::ostream& operator<<(std::ostream& os, const GO_NAMESPACE::gl_mat3& v);
  GO_API std::ostream& operator<<(std::ostream& os, const GO_NAMESPACE::gl_mat4& v);

  GO_API std::istream& operator>>(std::istream& is, GO_NAMESPACE::mat3& v);
  GO_API std::istream& operator>>(std::istream& is, GO_NAMESPACE::mat4& v);
  GO_API std::istream& operator>>(std::istream& is, GO_NAMESPACE::gl_mat3& v);
  GO_API std::istream& operator>>(std::istream& is, GO_NAMESPACE::gl_mat4& v);

}

# endif /* PROJECT_NAMESPACE_MATRIX_H_ */


text:
package org.apache.camel.maven;

import java.io.File;

import org.apache.maven.plugins.annotations.Parameter;

/**
 * Base class for API based code generation MOJOs.
 */
public abstract class AbstractSourceGeneratorMojo extends AbstractGeneratorMojo {

    @Parameter(defaultValue = "${project.basedir}/src/generated/java")
    protected File generatedSrcDir;

    @Parameter(defaultValue = "${project.build.directory}/generated-test-sources/camel-component")
    protected File generatedTestDir;

    enum CompileRoots {
        source,
        test,
        all,
        none
    }

    @Parameter(defaultValue = "all", property = PREFIX + "addCompileSourceRoots")
    protected CompileRoots addCompileSourceRoots = CompileRoots.all;

    protected void setCompileSourceRoots() {
        switch (addCompileSourceRoots) {
            case source:
                project.addCompileSourceRoot(generatedSrcDir.getAbsolutePath());
                project.addCompileSourceRoot(generatedTestDir.getAbsolutePath());
                break;
            case test:
                project.addTestCompileSourceRoot(generatedSrcDir.getAbsolutePath());
                project.addTestCompileSourceRoot(generatedTestDir.getAbsolutePath());
                break;
            case all:
                project.addCompileSourceRoot(generatedSrcDir.getAbsolutePath());
                project.addTestCompileSourceRoot(generatedTestDir.getAbsolutePath());
                break;
            default:
        }
    }

}


text:
#ifndef NativeXPathNSResolver_h
#define NativeXPathNSResolver_h

#include "core/xml/XPathNSResolver.h"
#include "wtf/RefPtr.h"

namespace blink {

class Node;

class NativeXPathNSResolver final : public XPathNSResolver {
public:
    static NativeXPathNSResolver* create(PassRefPtrWillBeRawPtr<Node> node)
    {
        return new NativeXPathNSResolver(node);
    }

    virtual AtomicString lookupNamespaceURI(const String& prefix) override;

    DECLARE_VIRTUAL_TRACE();

private:
    explicit NativeXPathNSResolver(PassRefPtrWillBeRawPtr<Node>);

    RefPtrWillBeMember<Node> m_node;
};

} // namespace blink

#endif // NativeXPathNSResolver_h


text:
<?php

use Atto\JsonResponse;

class JsonResponseTest extends PHPUnit_Framework_TestCase
{
    function testConstructor()
    {
        $response = new JsonResponse();

        $this->assertInstanceOf('Atto\Response', $response);
    }
}


text:
using System;

namespace Owin.Security.Providers.VidZapper
{
    public static class VidZapperAuthenticationExtensions
    {
        public static IAppBuilder UseVidZapperAuthentication(this IAppBuilder app,
            VidZapperAuthenticationOptions options)
        {
            if (app == null)
                throw new ArgumentNullException(nameof(app));
            if (options == null)
                throw new ArgumentNullException(nameof(options));

            app.Use(typeof(VidZapperAuthenticationMiddleware), app, options);

            return app;
        }

        public static IAppBuilder UseVidZapperAuthentication(this IAppBuilder app, string clientId, string clientSecret,string host="live.vzconsole.com")
        {
            return app.UseVidZapperAuthentication(new VidZapperAuthenticationOptions
            {
                ApiKey = clientId,
                Secret = clientSecret,
                Host = host
            });
        }
    }
}


text:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">

<title>T-Index</title>
<meta name="date" content="2016-03-07">
<link rel="stylesheet" type="text/css" href="../stylesheet.css" title="Style">

JavaScript is disabled on your browser.

Skip navigation links

Overview

Package

Class

Tree

Deprecated

Index

Help

Prev Letter

Next Letter

Frames

No Frames

All Classes

A B C D E F G H I L M N O P R S T U V W

T

targetLanguage - Variable in class com.yingkan.dictionaryAPI.translationProvider

text - Static variable in class com.yingkan.mydictapp.R.id

TextAppearance_Wearable_Large - Static variable in class com.yingkan.mydictapp.R.style

TextAppearance_Wearable_Medium - Static variable in class com.yingkan.mydictapp.R.style

TextAppearance_Wearable_Small - Static variable in class com.yingkan.mydictapp.R.style

TextAppearance_WearDiag - Static variable in class com.yingkan.mydictapp.R.style

TextAppearance_WearDiag_Button - Static variable in class com.yingkan.mydictapp.R.style

TextAppearance_WearDiag_Message - Static variable in class com.yingkan.mydictapp.R.style

TextAppearance_WearDiag_Title - Static variable in class com.yingkan.mydictapp.R.style

TextView_Large - Static variable in class com.yingkan.mydictapp.R.style

TextView_Large_Light - Static variable in class com.yingkan.mydictapp.R.style

TextView_Medium - Static variable in class com.yingkan.mydictapp.R.style

TextView_Medium_Light - Static variable in class com.yingkan.mydictapp.R.style

TextView_Small - Static variable in class com.yingkan.mydictapp.R.style

TextView_Small_Light - Static variable in class com.yingkan.mydictapp.R.style

Theme_Wearable - Static variable in class com.yingkan.mydictapp.R.style

Theme_Wearable_Modal - Static variable in class com.yingkan.mydictapp.R.style

Theme_WearDiag - Static variable in class com.yingkan.mydictapp.R.style

title - Static variable in class com.yingkan.mydictapp.R.id

tmQuery(CharSequence) - Method in class com.yingkan.dictionaryAPI.Glosbe

Gives access to translation memory

top - Static variable in class com.yingkan.mydictapp.R.id

translateQuery() - Method in class com.yingkan.dictionaryAPI.Glosbe

Form the URL query for translation

translateQuery() - Method in class com.yingkan.dictionaryAPI.translationProvider

Abstract method for all the translation API provider to form corresponding URL translation query.

translationProvider - Class in com.yingkan.dictionaryAPI

This interface should be implemented by different translation service provider based on there
 (hopefully) Web API
 Created by Yingkan Chen on 06.03.2016.

translationProvider() - Constructor for class com.yingkan.dictionaryAPI.translationProvider

A B C D E F G H I L M N O P R S T U V W

Skip navigation links

Overview

Package

Class

Tree

Deprecated

Index

Help

Prev Letter

Next Letter

Frames

No Frames

All Classes


text:
//
// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, vJAXB 2.1.10 in JDK 6
// See http://java.sun.com/xml/jaxb
// Any modifications to this file will be lost upon recompilation of the source schema.
// Generated on: 2012.05.24 at 08:06:09 AM EDT
//

package com.billybyte.spanjava.generated;

import java.math.BigDecimal;
import java.math.BigInteger;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlRootElement;
import javax.xml.bind.annotation.XmlType;

/**
 *
Java class for anonymous complex type.
 *
 *
The following schema fragment specifies the expected content contained within this class.
 *
 *

 * <complexType>
 *   <complexContent>
 *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
 *       <sequence>
 *         <element ref="{}date"/>
 *         <element ref="{}dv"/>
 *         <element ref="{}dvcum"/>
 *         <element ref="{}dvs"/>
 *         <element ref="{}dvcs"/>
 *       </sequence>
 *     </restriction>
 *   </complexContent>
 * </complexType>
 *

 *
 *
 */
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "", propOrder = {
    "date",
    "dv",
    "dvcum",
    "dvs",
    "dvcs"
})
@XmlRootElement(name = "dvad")
public class Dvad {

    @XmlElement(required = true)
    protected BigInteger date;
    @XmlElement(required = true)
    protected BigDecimal dv;
    @XmlElement(required = true)
    protected BigDecimal dvcum;
    @XmlElement(required = true)
    protected BigDecimal dvs;
    @XmlElement(required = true)
    protected BigDecimal dvcs;

    /**
     * Gets the value of the date property.
     *
     * @return
     *     possible object is
     *     {@link BigInteger }
     *
     */
    public BigInteger getDate() {
        return date;
    }

    /**
     * Sets the value of the date property.
     *
     * @param value
     *     allowed object is
     *     {@link BigInteger }
     *
     */
    public void setDate(BigInteger value) {
        this.date = value;
    }

    /**
     * Gets the value of the dv property.
     *
     * @return
     *     possible object is
     *     {@link BigDecimal }
     *
     */
    public BigDecimal getDv() {
        return dv;
    }

    /**
     * Sets the value of the dv property.
     *
     * @param value
     *     allowed object is
     *     {@link BigDecimal }
     *
     */
    public void setDv(BigDecimal value) {
        this.dv = value;
    }

    /**
     * Gets the value of the dvcum property.
     *
     * @return
     *     possible object is
     *     {@link BigDecimal }
     *
     */
    public BigDecimal getDvcum() {
        return dvcum;
    }

    /**
     * Sets the value of the dvcum property.
     *
     * @param value
     *     allowed object is
     *     {@link BigDecimal }
     *
     */
    public void setDvcum(BigDecimal value) {
        this.dvcum = value;
    }

    /**
     * Gets the value of the dvs property.
     *
     * @return
     *     possible object is
     *     {@link BigDecimal }
     *
     */
    public BigDecimal getDvs() {
        return dvs;
    }

    /**
     * Sets the value of the dvs property.
     *
     * @param value
     *     allowed object is
     *     {@link BigDecimal }
     *
     */
    public void setDvs(BigDecimal value) {
        this.dvs = value;
    }

    /**
     * Gets the value of the dvcs property.
     *
     * @return
     *     possible object is
     *     {@link BigDecimal }
     *
     */
    public BigDecimal getDvcs() {
        return dvcs;
    }

    /**
     * Sets the value of the dvcs property.
     *
     * @param value
     *     allowed object is
     *     {@link BigDecimal }
     *
     */
    public void setDvcs(BigDecimal value) {
        this.dvcs = value;
    }

}


text:
var gulp = require('gulp');

gulp.task('default', ['css', 'minjs', 'js', 'html', 'ts']);
gulp.task('install', ['copy', 'img']);

/** COPY FONTS **/
gulp.task('copy', function () {
  var copy = require('gulp-copy');
  gulp.src('node_modules/font-awesome/fonts/*')
    .pipe(copy('web/assets/fonts', { prefix: 3 }));
  gulp.src('src/AppBundle/Resources/public/fonts/*')
    .pipe(copy('web/assets/fonts', { prefix: 5 }));
});

/** REDUCE IMG **/
gulp.task('img', function () {
  var img = require('gulp-image');
  gulp.src([
      'src/AppBundle/Resources/public/img/*','src/AppBundle/Resources/public/img/*',
      'src/AppBundle/Resources/public/img/*','src/AppBundle/Resources/public/img/*/*',
      'src/AppBundle/Resources/public/img/*','src/AppBundle/Resources/public/img/*/*/*'
    ])
    .pipe(img())
    .pipe(gulp.dest('web/assets/img'));

  gulp.src([
      'node_modules/leaflet/dist/images/*'
    ])
    .pipe(img())
    .pipe(gulp.dest('web/assets/img/leaflet'));
});

/** COMPILED SASS IN CSS **/
gulp.task('sass', function () {
  var sass = require('gulp-sass');
  var config = {outputStyle: 'compressed'};

  gulp.src(['src/AppBundle/Resources/public/ts/components/*/*.scss'])
    .pipe(sass(config).on('error', sass.logError))
    .pipe(gulp.dest('web/assets/js/components'));

  return gulp.src([
    'src/AppBundle/Resources/public/sass/*.scss',
    'node_modules/leaflet/dist/leaflet.css'
  ])
    .pipe(sass(config).on('error', sass.logError))
    .pipe(gulp.dest('var/assets/min/css'));
});

/** CONCATED CSS **/
gulp.task('css', ['sass'], function () {
  var concat = require('gulp-concat');
  return gulp.src([
      'node_modules/font-awesome/css/font-awesome.min.css',
      'node_modules/angular-ui-select/select.min.css',
      'node_modules/rome/dist/rome.min.css',
      'var/assets/min/css/*.css'
    ])
    .pipe(concat('style.css'))
    .pipe(gulp.dest('web/assets/css'));
});

gulp.task('ts', [], function () {
  var typescript = require('gulp-typescript');
  var config = {
    target: "ES5",
    module: "system",
    moduleResolution: "node",
    sourceMap: true,
    emitDecoratorMetadata: true,
    experimentalDecorators: true,
    removeComments: true,
    noImplicitAny: false,
  };

  gulp.src([
    'node_modules/angular2/typings/browser.d.ts',
    'src/AppBundle/Resources/public/ts/components/*/*.ts'])
    .pipe(typescript(config))
    .js.pipe(gulp.dest('var/assets/src/ts/components'));

  gulp.src([
      'node_modules/angular2/typings/browser.d.ts',
      'src/AppBundle/Resources/public/ts/*/*.ts'])
    .pipe(typescript(config))
    .js.pipe(gulp.dest('var/assets/src/ts'));
});

/** MINIFIED JS **/
gulp.task('minjs', function () {
  var uglify = require('gulp-uglify');
  gulp.src([
      'var/assets/src/js/translations/config.js',
      'var/assets/src/js/translations/*/fr.js',
      'var/assets/src/js/translations/*/en.js'
    ])
    .pipe(uglify())
    .pipe(gulp.dest('var/assets/min/js/translations'));

  gulp.src([
      'src/AppBundle/Resources/public/js/*.js',
      'node_modules/leaflet/dist/leaflet.js'
    ])
    .pipe(uglify())
    .pipe(gulp.dest('var/assets/min/js'));

  gulp.src([
      'var/assets/src/ts/*/*.js',
    ])
    .pipe(uglify())
    .pipe(gulp.dest('web/assets/js'));

  gulp.src([
      'var/assets/src/ts/components/*/*.js'
    ])
    .pipe(uglify())
    .pipe(gulp.dest('web/assets/js/components'));
});

/** CONCATED JS **/
gulp.task('js', function () {
  var concat = require('gulp-concat');
  gulp.src(['var/assets/min/js/slider.js'])
    .pipe(concat('slider.js'))
    .pipe(gulp.dest('web/assets/js'));

  gulp.src([
      'web/bundles/bazingajstranslation/js/translator.min.js',
      'var/assets/min/js/translations/config.js',
      'var/assets/min/js/translations/*/*.js',
      'var/assets/min/js/translations/*.js'
    ])
    .pipe(concat('translations.js'))
    .pipe(gulp.dest('web/assets/js'));

  gulp.src([
      'node_modules/moment/min/moment.min.js',
      'node_modules/moment/locale/fr.js',
      'var/assets/min/js/leaflet.js',
      'node_modules/angular/angular.min.js',
      'node_modules/angular-sanitize/angular-sanitize.min.js',
      'node_modules/angular-ui-select/select.min.js',
      'node_modules/rome/dist/rome.standalone.js',
      'var/assets/min/js/app.js'
    ])
    .pipe(concat('script.js'))
    .pipe(gulp.dest('web/assets/js'));

  gulp.src([
      'node_modules/angular2/bundles/angular2-polyfills.min.js',
      'node_modules/systemjs/dist/system.js',//src
      'node_modules/rxjs/bundles/Rx.min.js',
      'node_modules/angular2/bundles/angular2.min.js', //dev
      'node_modules/angular2/bundles/http.min.js', //dev
      'node_modules/angular2/bundles/router.min.js', //dev,
      'var/assets/min/js/system-loader-configuration.js',
    ])
    .pipe(concat('angular2.js'))
    .pipe(gulp.dest('web/assets/js'));
});

gulp.task('html', function () {
  var copy = require('gulp-copy');
  gulp.src('src/AppBundle/Resources/public/ts/components/*/*.html')
    .pipe(copy('web/assets/js/components', { prefix: 6 }));
});

gulp.task('watch', function () {
  gulp.watch(['src/AppBundle/Resources/public/img/*',
    'src/AppBundle/Resources/public/img/*/*',
    'src/AppBundle/Resources/public/img/*/*/*'], ['img']);

  gulp.watch(['src/AppBundle/Resources/public/sass/*.scss'], ['sass', 'css']);

  gulp.watch(['src/AppBundle/Resources/public/js/*.js'], ['minjs', 'js']);

  gulp.watch(['src/AppBundle/Resources/public/ts/components/*/*.scss'], ['sass', 'css']);

  gulp.watch(['src/AppBundle/Resources/public/ts/components/*/*.html'], ['html']);

  gulp.watch(['src/AppBundle/Resources/public/ts/*/*.ts',
    'src/AppBundle/Resources/public/ts/components/*/*.ts'], ['ts', 'minjs']);
});


text:
package org.rt.checks;

import org.rt.checks.annotation.RtCheck;
import org.rt.checks.annotation.RtChecker;

import javax.annotation.Nullable;

/**
 * Listener for checking process
 *
 * @author dsaponenko
 */
public interface RtCheckRunListener {

  /**
   * Setup invoke for every RtChecker class
   *
   * @param checker Checker instance
   * @see RtChecker
   */
  void setUp(RtChecker checker);

  /**
   * Run before every check from checker class
   *
   * @param check Check configuration
   */
  void before(RtCheck check);

  /**
   * Main method. Invoke after every check.
   *
   * @param check       Check configuration
   * @param checkResult Check result
   */
  void after(RtCheck check, RtCheckResult checkResult);

  /**
   * Finally method for every checker class
   *
   * @param checker Checker configuration
   */
  void tearDown(RtChecker checker);

  /**
   * Error run checks
   *
   * @param checker Checker configuration
   * @param check   Check configuration. May be null
   * @param ex      Exception
   */
  void error(RtChecker checker, @Nullable RtCheck check, Exception ex);
}