text:
This **Getting Started with Elastic Stack** example provides sample files to ingest, analyze and alert on **Auditd Logs in the CEF Format** using the Elastic Stack.

Included are example Watches for proactively monitoring this data for possible security incidents.  These examples support the Security Analytics blog post series, specifically:

* [Integrating Elasticsearch with ArcSight SIEM - Part 5](https://www.elastic.co/blog/integrating-elasticsearch-with-arcsight-siem-part-5).
* [Integrating Elasticsearch with ArcSight SIEM - Using Machine Learning - Part 6](https://www.elastic.co/blog/integrating-elasticsearch-with-arcsight-siem-part-6).

The examples complement the above blog posts, providing a means to:

- [Detect New Processes](https://github.com/elastic/examples/blob/master/Security%20Analytics/auditd_analysis/example_1/README.md) - Detect a new process signature occuring on a server in the last N minutes, that has not occurred on the server historically.
- [Detect an Unusual Process](https://github.com/elastic/examples/blob/master/Security%20Analytics/auditd_analysis/example_2/README.md) - Detect an unusual process on a server using X-Packs Machine Learning capabilities. Unusual here is defined as statistically rare within the context of a specific server.

Both examples utilise:

- [auditd_analysis_logstash.conf](https://raw.githubusercontent.com/elastic/examples/master/Security%20Analytics/audidt_analysis/auditd_analysis_logstash.conf) - An appropriate Logstash configuration for indexing the above CEF data. This configuration creates a `process_signature` field for the first example.
- [cef_template.json](https://github.com/elastic/examples/blob/master/Common%20Data%20Formats/cef/logstash/pipeline/cef_template.json) -  This will be installed when Logstash is run with the above configuration.
- [simulate_watch.py](https://github.com/elastic/examples/blob/master/Security%20Analytics/auditd_analysis/simulate_watch.py) - A convenience script to execute the above watch. In order to test this watch against the provided test data set, this script which performs a "sliding window" execution of the watch.
This repeatedly executes the watch, each time adjusting the date filters to target the next 5 minute time range thus simulating the execution against a live stream of several days of data in a few seconds.
- [requirements.txt](https://github.com/elastic/examples/blob/master/Security%20Analytics/auditd_analysis/requirements.txt) - Python dependencies for pip

## Versions

The examples has been tested with the following versions:

- Elasticsearch 5.5
- Logstash 5.5 with [CEF codec](https://www.elastic.co/guide/en/logstash/current/plugins-codecs-cef.html)
- Kibana 5.5
- X-Pack 5.5
- Python 3.5 with Elasticsearch dependency

## Installation & Setup

* Follow the [Installation & Setup Guide](https://github.com/elastic/examples/blob/master/Installation%20and%20Setup.md) to install and test the Elastic Stack (*you can skip this step if you have a working installation of the Elastic Stack,*)

* Install the X-Pack in Kibana and Elasticsearch

  ```shell
  <path_to_elasticsearch_root_dir>/elasticsearch-plugin install x-pack
  <path_to_kibana_root_dir>/bin/kibana-plugin install x-pack
  ```

* Run Elasticsearch & Kibana
  ```shell
  <path_to_elasticsearch_root_dir>/bin/elasticsearch
  <path_to_kibana_root_dir>/bin/kibana
  ```

* Check that Elasticsearch and Kibana are up and running.
  - Open `localhost:9200` in web browser -- should return a json message indicating ES is running.
  - Open `localhost:5601` in web browser -- should display Kibana UI.

  **Note:** By default, Elasticsearch runs on port 9200, and Kibana run on ports 5601. If you changed the default ports, change the above calls to use the appropriate ports.
  The cluster will be secured using basic auth. If changing the default credentials of `elastic` and `changeme` as described [here](https://www.elastic.co/guide/en/x-pack/current/security-getting-started.html), ensure the logstash configuration file is updated.

## Setup Python

* Install Python 3.5.x
* Ensure pip is installed
* Install dependencies using pip i.e. `pip install -r requirements.txt`

## Follow specific example instructions

Example specific instructions should be followed, either:

- [Detect New Processes](https://github.com/elastic/examples/blob/master/Security%20Analytics/auditd_analysis/example_1/README.md) for [Integrating Elasticsearch with ArcSight SIEM - Part 5](https://www.elastic.co/blog/integrating-elasticsearch-with-arcsight-siem-part-5).
- [Detect an Unusual Process](https://github.com/elastic/examples/blob/master/Security%20Analytics/auditd_analysis/example_2/README.md) for [Integrating Elasticsearch with ArcSight SIEM - Using Machine Learning - Part 6](https://www.elastic.co/blog/integrating-elasticsearch-with-arcsight-siem-part-6).

## We would love your feedback!

If you found this example helpful, and would like more such Getting Started examples for other standard formats, we would love to hear from you. If you would like to contribute Getting Started examples to this repo, we'd love that too!


text:
var Reflux = require('reflux');
var generatedWordsActions = require('../actions/actions').generatedWordsActions;
var _ = require('lodash');

var idCounter = 0;

module.exports = Reflux.createStore({
	listenables: generatedWordsActions,

	init: function () {
		this.list = [];
	},
	getInitialState: function () {
		return this.list;
	},

	updateList: function (list) {
		this.list = list;
		this.trigger(list);
	},
	updateListIfSizeChanged: function (list) {
		if (list.length == this.list.length) {
			return;
		}
		this.updateList(list);
	},

	listDoesNotContain: function (word) {
		return _.findIndex(this.list, function (item) {
				return item.word == word;
			}) < 0;
	},

	onAdd: function (words) {
		if (!_.isArray(words)) {
			words = [words];
		}
		words = words.filter(this.listDoesNotContain);
		if (words.length <= 0) {
			return;
		}
		this.updateListIfSizeChanged(this.list.concat(words.map(function (word) {
			return {
				key: ++idCounter,
				word: word
			};
		})));
	},

	onRemove: function (word) {
		this.updateListIfSizeChanged(_.filter(this.list, function (item) {
			return item.word !== word;
		}));
	},

	onClear: function () {
		this.updateListIfSizeChanged([]);
	}
});

redpajama_set_name: RedPajamaGithub


text:
'use strict';

const models = require('./index');

/**
 * Product information.
 *
 */
class VirtualMachineProductProperties {
  /**
   * Create a VirtualMachineProductProperties.
   * @member {string} [version] Specifies product version.
   * @member {object} [osDiskImage] OS disk image used by product.
   * @member {string} [osDiskImage.operatingSystem] OS operating system type.
   * Possible values include: 'None', 'Windows', 'Linux'
   * @member {string} [osDiskImage.sourceBlobSasUri] SAS key for source blob.
   * @member {array} [dataDiskImages] List of attached data disks.
   */
  constructor() {
  }

  /**
   * Defines the metadata of VirtualMachineProductProperties
   *
   * @returns {object} metadata of VirtualMachineProductProperties
   *
   */
  mapper() {
    return {
      required: false,
      serializedName: 'VirtualMachineProductProperties',
      type: {
        name: 'Composite',
        className: 'VirtualMachineProductProperties',
        modelProperties: {
          version: {
            required: false,
            readOnly: true,
            serializedName: 'version',
            type: {
              name: 'String'
            }
          },
          osDiskImage: {
            required: false,
            readOnly: true,
            serializedName: 'osDiskImage',
            type: {
              name: 'Composite',
              className: 'OsDiskImage'
            }
          },
          dataDiskImages: {
            required: false,
            readOnly: true,
            serializedName: 'dataDiskImages',
            type: {
              name: 'Sequence',
              element: {
                  required: false,
                  serializedName: 'DataDiskImageElementType',
                  type: {
                    name: 'Composite',
                    className: 'DataDiskImage'
                  }
              }
            }
          }
        }
      }
    };
  }
}

module.exports = VirtualMachineProductProperties;


text:
#ifndef __PHYSICSDYNAMIC_H__
#define __PHYSICSDYNAMIC_H__

#include "stdneb.h"
#include "PhysicsEntity.h"
#include "PhysicsDeclaration.h"

namespace App
{
	class PhysicsBodyComponent;
	using namespace physx;

	class PhysicsDynamic : public PhysicsEntity
	{
		__DeclareSubClass(PhysicsDynamic, PhysicsEntity)
	public:
		enum ForceType
		{
			FORCE_NORMAL,
			FORCE_IMPULSE,
			FORCE_VELOCITY_CHANGE,
			FORCE_ACCELERATION
		};

		PhysicsDynamic();
		virtual ~PhysicsDynamic();

	public:
		bool	OnCreate(GPtr<PhysicsBodyComponent> body);
		bool	OnDestory();
		void	OnShapeReBuild(PhysicsShape* shape);

		void	Save(AppWriter* pSerialize);
		void	Load(Version ver, AppReader* pReader);

	public:
		bool	IsValid() { return m_pPxActor != NULL; }
		bool	IsJointFather() { return m_bJointFather; }
		bool	IsUseGravity() { return m_bUseGravity; }
		bool	IsKinematic() { return m_bKinematic; }
		void	SetJointFather(bool joint);
		void	SetUseGravity(bool usege);
		void	SetKinematic(bool kinematic);

		float	GetMass();

		void	SetLinearDamping(float damping);
		float	GetLinearDamping() { return m_fLinearDamping; }
		void	SetAngularDamping(float damping);
		float	GetAngularDamping() { return m_fAngularDamping; }
		void	SetMaxAngularVel(float vel);
		float	GetMaxAngularVel() { return m_fMaxAngularVel; }
		void	SetSleepThreshold(float threshold);
		float	GetSleepThreshold() { return m_fSleepThreshold; }

		void SetConstantForce(const Math::float3& force) { m_vContantForce = force; }
		const Math::float3& GetConstantForce() { return m_vContantForce; }
		void SetConstantVelocity(const Math::float3& velocity) { m_vContantVelocity = velocity; }
		const Math::float3& GetConstantVelocity() { return m_vContantVelocity; }
		void SetConstantTorques(const Math::float3& torques) { m_vContantTorques = torques; }
		const Math::float3& GetConstantTorques() { return m_vContantTorques; }
		void SetConstantAngularVel(const Math::float3& velocity) { m_vContantAngularVel = velocity; }
		const Math::float3& GetConstantAngularVel() { return m_vContantAngularVel; }
		void SetLinearVelocity(Math::float3& vel);
		void SetAngularVelocity(Math::float3& vel);
		Math::float3 GetLinearVelocity() const;
		Math::float3 GetAngularVelocity() const;

		void AddForce(const Math::float3& force,ForceType forcetype = FORCE_NORMAL,bool bWakeUp = true);
		void AddForceAtPos(const Math::float3& force,const Math::float3& pos,ForceType forcetype = FORCE_NORMAL,bool bWakeUp = true);
		void AddForceAtLocalPos(const Math::float3& force,const Math::float3& pos,ForceType forcetype = FORCE_NORMAL,bool bWakeUp = true);
		void AddLocalForceAtPos(const Math::float3& force,const Math::float3& pos,ForceType forcetype = FORCE_NORMAL,bool bWakeUp = true);
		void AddLocalForceAtLocalPos(const Math::float3& force,const Math::float3& pos,ForceType forcetype = FORCE_NORMAL,bool bWakeUp = true);
		void AddTorque(const Math::float3& torque,ForceType forcetype = FORCE_NORMAL,bool bWakeUp = true);

		void	Move(const Math::float3& dir);
		void	MoveToPostion(const Math::float3& pos);
		void	Rotate(const Math::quaternion& quat);
		void	RotateToRotation(const Math::quaternion& quat);

		void	Tick(float time);

		bool	CopyFrom(GPtr<PhysicsEntity> src);
	protected:
		void	UpdateEntityMass();
		PxRigidActor* GetRigidActor();
		void	CaptureShapeFromChildren();
		void	ReleaseChildShape();

	private:
		PxRigidDynamic* m_pPxActor;

		bool		m_bJointFather;
		bool		m_bUseGravity;
		bool		m_bKinematic;
		float		m_fLinearDamping;
		float		m_fAngularDamping;
		float		m_fMaxAngularVel;
		float		m_fSleepThreshold;
		Math::float3 m_vContantForce;
		Math::float3 m_vContantVelocity;
		Math::float3 m_vContantTorques;
		Math::float3 m_vContantAngularVel;
	};
}
#endif


text:
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.

namespace Microsoft.AspNetCore.Mvc.ModelBinding.Binders;

public class BinderTypeModelBinderProviderTest
{
    [Fact]
    public void Create_WhenBinderTypeIsNull_ReturnsNull()
    {
        // Arrange
        var provider = new BinderTypeModelBinderProvider();

        var context = new TestModelBinderProviderContext(typeof(Person));

        // Act
        var result = provider.GetBinder(context);

        // Assert
        Assert.Null(result);
    }

    [Fact]
    public void Create_WhenBinderTypeIsSet_ReturnsBinder()
    {
        // Arrange
        var provider = new BinderTypeModelBinderProvider();

        var context = new TestModelBinderProviderContext(typeof(Person));
        context.BindingInfo.BinderType = typeof(NullModelBinder);

        // Act
        var result = provider.GetBinder(context);

        // Assert
        Assert.IsType<BinderTypeModelBinder>(result);
    }

    private class Person
    {
        public string Name { get; set; }

        public int Age { get; set; }
    }

    private class NullModelBinder : IModelBinder
    {
        public Task BindModelAsync(ModelBindingContext bindingContext)
        {
            return Task.FromResult(0);
        }
    }
}


text:
#include <list>
#include <string>

#include "gtest/gtest.h"
#include "gmock/gmock.h"

#include "records/ContainerLaunchContext.h"

using std::list;
using std::string;
using namespace libyarn;
using namespace testing;

class TestContainerLaunchContext: public ::testing::Test {
protected:
	ContainerLaunchContext containerContext;
};

TEST_F(TestContainerLaunchContext, TestGetLocalResources)
{
	list<StringLocalResourceMap> maps;
	list<StringLocalResourceMap> retMaps;
	StringLocalResourceMap map;
	maps.push_back(map);

	containerContext.setLocalResources(maps);
	retMaps = containerContext.getLocalResources();

	/* The operator '==' is not defined for class StringLocalResrouceMap,
	   so we can't compare list and retMaps here. */

	SUCCEED();
}

TEST_F(TestContainerLaunchContext, TestGetServiceData)
{
	list<StringBytesMap> maps;
	list<StringBytesMap> retMaps;
	StringBytesMap map;
	maps.push_back(map);

	containerContext.setServiceData(maps);
	retMaps = containerContext.getServiceData();

	/* The operator '==' is not defined for class StringBytesMap,
	   so we can't compare list and retMaps here. */

	SUCCEED();
}

TEST_F(TestContainerLaunchContext, TestGetEnvironment)
{
	list<StringStringMap> maps;
	list<StringStringMap> retMaps;
	StringStringMap map;
	maps.push_back(map);

	containerContext.setEnvironment(maps);
	retMaps = containerContext.getEnvironment();

	/* The operator '==' is not defined for class StringStringMap,
	   so we can't compare list and retMaps here. */

	SUCCEED();
}

TEST_F(TestContainerLaunchContext, TestGetApplicationACLs)
{
	list<ApplicationACLMap> maps;
	list<ApplicationACLMap> retMaps;
	ApplicationACLMap map;
	maps.push_back(map);

	containerContext.setApplicationACLs(maps);
	retMaps = containerContext.getApplicationACLs();

	/* The operator '==' is not defined for class ApplicationACLMap,
	   so we can't compare list and retMaps here. */

	SUCCEED();
}

TEST_F(TestContainerLaunchContext, TestGetTokens)
{
	string tokens("tokens");
	string retTokens;

	containerContext.setTokens(tokens);
	retTokens = containerContext.getTokens();

	EXPECT_EQ(tokens, retTokens);
}

TEST_F(TestContainerLaunchContext, TestGetCommand)
{
	list<string> commands;
	list<string> retCommands;
	string command("command");
	commands.push_back(command);

	containerContext.setCommand(commands);
	retCommands = containerContext.getCommand();

	EXPECT_EQ(commands, retCommands);
}


text:
<?php

namespace Tests\AppBundle\Service;

use AppBundle\Entity\User;
use AppBundle\Service\DemoService;
use AppBundle\Service\RegistrationService;
use PHPUnit_Framework_MockObject_MockObject;
use PHPUnit_Framework_TestCase;
use Symfony\Component\EventDispatcher\EventDispatcher;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\Security\Core\Encoder\PlaintextPasswordEncoder;

class DemoServiceTest extends PHPUnit_Framework_TestCase
{
    /**
     * @var PHPUnit_Framework_MockObject_MockObject|\FOS\UserBundle\Doctrine\UserManagerInterface
     */
    private $userManagerMock;

    public function setUp()
    {
        $this->userManagerMock = $this->getMockBuilder('FOS\UserBundle\Doctrine\UserManager')
            ->disableOriginalConstructor()->getMock();
    }

    public function testThatDemoModeIsRecognized()
    {
        $request = Request::create('/demo/testcases/', 'GET');

        $ds = new DemoService(
            $this->userManagerMock,
            'demo-user@journeymonitor.com',
            '/demo/'
        );

        $this->assertTrue($ds->isDemoMode($request));
    }

    public function testThatDemoModeIsNotRecognized()
    {
        $request = Request::create('/foo/demo/testcases/', 'GET');

        $ds = new DemoService(
            $this->userManagerMock,
            'demo-user@journeymonitor.com',
            '/demo/'
        );

        $this->assertFalse($ds->isDemoMode($request));
    }

    public function testThatDemoUserIsReturned()
    {
        $this->userManagerMock->expects($this->once())
            ->method('findUserByEmail')
            ->with('demo-user@journeymonitor.com')
            ->willReturn('demo');

        $request = Request::create('/demo/testcases/', 'GET');

        $daus = new DemoService(
            $this->userManagerMock,
            'demo-user@journeymonitor.com',
            '/demo/'
        );

        $this->assertSame('demo', $daus->getUser($request, 'real'));
    }

    public function testThatDemoUserIsNotReturned()
    {
        $this->userManagerMock->expects($this->never())
            ->method('findUserByEmail');

        $request = Request::create('/testcases/', 'GET');

        $daus = new DemoService(
            $this->userManagerMock,
            'demo-user@journeymonitor.com',
            '/demo/'
        );

        $this->assertSame('real', $daus->getUser($request, 'real'));
    }

    public function testThatRealUserIsReturnedIfDemoUserNotFound()
    {
        $this->userManagerMock->expects($this->once())
            ->method('findUserByEmail')
            ->with('demo-user@journeymonitor.com')
            ->willReturn(null);

        $request = Request::create('/demo/testcases/', 'GET');

        $daus = new DemoService(
            $this->userManagerMock,
            'demo-user@journeymonitor.com',
            '/demo/'
        );

        $this->assertSame('real', $daus->getUser($request, 'real'));
    }
}


text:
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
    <item android:state_pressed="true"
        android:drawable="@drawable/green_apptheme_btn_default_focused_holo_dark" />
    <item android:state_focused="true" android:state_enabled="true"
        android:drawable="@drawable/green_apptheme_btn_default_focused_holo_dark" />
    <item android:state_enabled="true"
        android:drawable="@drawable/green_apptheme_btn_default_pressed_holo_dark" />
    <item android:state_focused="true"
        android:drawable="@drawable/green_apptheme_btn_default_disabled_focused_holo_dark" />
    <item
        android:drawable="@drawable/green_apptheme_btn_default_pressed_holo_dark" />
</selector>


text:
import * as fs from 'fs';
import * as path from 'path';
import { promisify } from 'util';

import * as del from 'del';

import { doGitCommits } from './setup/do-git-commits';
import { getGitTags } from './utilities/get-git-tags';
import { GitConventionalCommit } from './interfaces/git-conventional-commit.interface';
import { GithubRelease, getGithubReleases } from './utilities/get-github-releases';
import { initialPackageJson } from './data/initial-package-json';
import { PackageJson } from '../src/interfaces/package-json.interface';
import { parseChangelog } from './utilities/parse-changelog';
import { preparedCommits } from './data/prepared-commits';
import { run } from './utilities/run';
import { setGithubDefaultBranch } from './utilities/set-github-default-branch';
import { setupGitRepository } from '././setup/setup-git-repository';
import { setupMocks } from './setup/setup-mocks';
import { testChangelogBreakingChange } from './shared/test-changelog-breaking-change';
import { testChangelogChange } from './shared/test-changelog-change';
import { testChangelogFooter } from './shared/test-changelog-footer';
import { testChangelogHeader } from './shared/test-changelog-header';

const readFileAsync = promisify( fs.readFile );
const mkdirAsync = promisify( fs.mkdir );

/**
 * Automatic Release: end-to-end
 *
 * This test suite is a complete end-to-end test for automatic releases, covering both a first release as well as a 'normal' release after
 * that. It has been written in a way to reflect real use cases, to work in real environments and circumstances - meaning that we use the
 * real dependencies and their code (no mocks or stubs), set up an actual Git repository (connected to a real GitHub remote repository),
 * write files to the disk and do commits as usual and actually communicate with real backend systems. If mocks are being used, they only
 * exist in order to manipulate the working directory (JavaScript execution context), necessary to make automatic release work in the dist
 * test folder.
 *
 * Note: Usually, this test should run green within under a minute.
 */
describe( 'Automatic Release: end-to-end', () => {

	let originalProcessCwd: () => string;
	let commits: Array<GitConventionalCommit> = [];
	const projectPath: string = path.resolve( process.cwd(), 'dist-test' );
	const expectedFirstRelease: string = '1.0.0';
	const expectedSecondRelease: string = '1.1.0';

	// Setup
	beforeAll( async() => {

		// Prepare folder (before changing working directory!!)
		await del( projectPath );
		await mkdirAsync( projectPath );

		// Change working directory to test output folder
		originalProcessCwd = process.cwd
		process.cwd = () => projectPath;

		// Setup repository & mocks
		setupMocks( projectPath );
		await setupGitRepository( projectPath, true, initialPackageJson );

	} );

	afterAll( async() => {

		process.cwd = originalProcessCwd;

		// Switch the GitHub repository default branch away from master, then back to master. Eventually, this removes the 'testing' repo
		// from contribution counting -- force-pushing branches & commits 'overwrites' / invalidates previous commits, and switching the
		// default branch results in contribution re-counting. #honesty #weird #idontmaketwohundredcontributionsaday
		await setGithubDefaultBranch( 'develop' );
		await setGithubDefaultBranch( 'master' );

	} );

	describe( 'First Release', () => {

		beforeAll( async() => {

			// Do commits (one for every release type)
			const firstReleaseCommits: Array<GitConventionalCommit> = await doGitCommits(
				projectPath,
				true,
				preparedCommits.none[ 0 ],
				preparedCommits.minor[ 0 ],
				preparedCommits.patch[ 0 ],
				preparedCommits.major[ 0 ]
			);
			commits = [ ...commits, ...firstReleaseCommits ];

			// Run automatic release (the test cases will check the result)
			const automaticRelease: () => Promise<void> = ( await import( './../index' ) ).automaticRelease;
			await automaticRelease();

		} );

		it ( 'should set the correct version in the "package.json" file', async() => {

			const packageJson: PackageJson = JSON.parse( await readFileAsync( path.resolve( projectPath, 'package.json' ), 'utf-8' ) );

			expect( packageJson.version ).toBe( expectedFirstRelease );

		} );

		it ( 'should write the "CHANGELOG.md" file', async() => {

			// Get date, get changelog
			const today: string = new Date().toISOString().split( 'T' )[ 0 ];
			const changelog: string = await readFileAsync( path.resolve( projectPath, 'CHANGELOG.md' ), 'utf-8' );
			const [ changelogHeader, changelogContent, changelogFooter ]: Array<Array<string>> = parseChangelog( changelog );

			// Check changelog header & footer
			testChangelogHeader( changelogHeader, initialPackageJson.repository.url );
			testChangelogFooter( changelogFooter );

			// Check changelog content
			expect( changelogContent.length ).toBe( 17 );
			expect( changelogContent[ 0 ] ).toBe( `## [${ expectedFirstRelease }](${ initialPackageJson.repository.url }/releases/tag/${ expectedFirstRelease }) (${ today })` );
			expect( changelogContent[ 1 ] ).toBe( '' );
			expect( changelogContent[ 2 ] ).toBe( '### Features' );
			expect( changelogContent[ 3 ] ).toBe( '' );
			testChangelogChange( changelogContent[ 4 ], commits[ 1 ], initialPackageJson.repository.url );
			expect( changelogContent[ 5 ] ).toBe( '' );
			expect( changelogContent[ 6 ] ).toBe( '### Performance Improvements' );
			expect( changelogContent[ 7 ] ).toBe( '' );
			testChangelogChange( changelogContent[ 8 ], commits[ 2 ], initialPackageJson.repository.url );
			expect( changelogContent[ 9 ] ).toBe( '' );
			expect( changelogContent[ 10 ] ).toBe( '### Refactoring' );
			expect( changelogContent[ 11 ] ).toBe( '' );
			testChangelogChange( changelogContent[ 12 ], commits[ 3 ], initialPackageJson.repository.url );
			expect( changelogContent[ 13 ] ).toBe( '' );
			expect( changelogContent[ 14 ] ).toBe( '### BREAKING CHANGES' );
			expect( changelogContent[ 15 ] ).toBe( '' );
			testChangelogBreakingChange( changelogContent[ 16 ], commits[ 3 ] );

		} );

		it ( 'should make the release commit', async() => {

			const releaseCommit = ( await run( 'git show -s --format=%s', projectPath ) ).replace( /\r?\n/, '' );

			expect( releaseCommit ).toBe( `Release ${ expectedFirstRelease } [skip ci]` );

		} );

		it ( 'should create the release tag', async() => {

			const gitTags: Array<string> = await getGitTags( projectPath );

			expect( gitTags.length ).toBe( 1 );
			expect( gitTags[ 0 ] ).toBe( expectedFirstRelease );

		} );

		it ( 'should update the branches', async() => {

			const developMasterDiff = ( await run( 'git diff origin/develop origin/master', projectPath ) );

			expect( developMasterDiff ).toBe( '' );

		} );

		it ( 'should create the GitHub release', async() => {

			const githubReleases: Array<GithubRelease> = await getGithubReleases();
			const githubFirstReleaseContent: Array<string> = githubReleases[ 0 ].body.split( /\r?\n/ );

			expect( githubReleases.length ).toBe( 1 );

			// Check changelog details
			expect( githubReleases[ 0 ].tag_name ).toBe( expectedFirstRelease );
			expect( githubReleases[ 0 ].name ).toBe( expectedFirstRelease );
			expect( githubReleases[ 0 ].target_commitish ).toBe( 'master' );

			// Check changelog content
			expect( githubFirstReleaseContent.length ).toBe( 16 );
			expect( githubFirstReleaseContent[ 0 ] ).toBe( '### Features' );
			expect( githubFirstReleaseContent[ 1 ] ).toBe( '' );
			testChangelogChange( githubFirstReleaseContent[ 2 ], commits[ 1 ], initialPackageJson.repository.url );
			expect( githubFirstReleaseContent[ 3 ] ).toBe( '' );
			expect( githubFirstReleaseContent[ 4 ] ).toBe( '### Performance Improvements' );
			expect( githubFirstReleaseContent[ 5 ] ).toBe( '' );
			testChangelogChange( githubFirstReleaseContent[ 6 ], commits[ 2 ], initialPackageJson.repository.url );
			expect( githubFirstReleaseContent[ 7 ] ).toBe( '' );
			expect( githubFirstReleaseContent[ 8 ] ).toBe( '### Refactoring' );
			expect( githubFirstReleaseContent[ 9 ] ).toBe( '' );
			testChangelogChange( githubFirstReleaseContent[ 10 ], commits[ 3 ], initialPackageJson.repository.url );
			expect( githubFirstReleaseContent[ 11 ] ).toBe( '' );
			expect( githubFirstReleaseContent[ 12 ] ).toBe( '### BREAKING CHANGES' );
			expect( githubFirstReleaseContent[ 13 ] ).toBe( '' );
			testChangelogBreakingChange( githubFirstReleaseContent[ 14 ], commits[ 3 ] );
			expect( githubFirstReleaseContent[ 15 ] ).toBe( '' );

		} );

	} );

	describe( 'Second Release', () => {

		beforeAll( async() => {

			// Do commits (resulting in 'minor' release)
			const secondReleaseCommits: Array<GitConventionalCommit> = await doGitCommits(
				projectPath,
				true,
				preparedCommits.patch[ 1 ],
				preparedCommits.minor[ 1 ],
			);
			commits = [ ...commits, ...secondReleaseCommits ];

			// Run automatic release (the test cases will check the result)
			const automaticRelease: () => Promise<void> = ( await import( './../index' ) ).automaticRelease;
			await automaticRelease();

		} );

		it ( 'should set the correct version in the "package.json" file', async() => {

			const packageJson: PackageJson = JSON.parse( await readFileAsync( path.resolve( projectPath, 'package.json' ), 'utf-8' ) );

			expect( packageJson.version ).toBe( expectedSecondRelease );

		} );

		it ( 'should write the "CHANGELOG.md" file', async() => {

			// Get date, get changelog
			const today: string = new Date().toISOString().split( 'T' )[ 0 ];
			const changelog: string = await readFileAsync( path.resolve( projectPath, 'CHANGELOG.md' ), 'utf-8' );
			const [ changelogHeader, changelogContent, changelogFooter ]: Array<Array<string>> = parseChangelog( changelog );

			// Check changelog header & footer
			testChangelogHeader( changelogHeader, initialPackageJson.repository.url );
			testChangelogFooter( changelogFooter );

			// Release '1.1.0'
			expect( changelogContent.length ).toBe( 29 );
			expect( changelogContent[ 0 ] ).toBe( `## [${ expectedSecondRelease }](${ initialPackageJson.repository.url }/releases/tag/${ expectedSecondRelease }) (${ today })` );
			expect( changelogContent[ 1 ] ).toBe( '' );
			expect( changelogContent[ 2 ] ).toBe( '### Features' );
			expect( changelogContent[ 3 ] ).toBe( '' );
			testChangelogChange( changelogContent[ 4 ], commits[ 5 ], initialPackageJson.repository.url );
			expect( changelogContent[ 5 ] ).toBe( '' );
			expect( changelogContent[ 6 ] ).toBe( '### Bug Fixes' );
			expect( changelogContent[ 7 ] ).toBe( '' );
			testChangelogChange( changelogContent[ 8 ], commits[ 4 ], initialPackageJson.repository.url );

			expect( changelogContent[ 9 ] ).toBe( '' );
			expect( changelogContent[ 10 ] ).toBe( '<br>' );
			expect( changelogContent[ 11 ] ).toBe( '' );

			// Release '1.0.0'
			expect( changelogContent[ 12 ] ).toBe( `## [${ expectedFirstRelease }](${ initialPackageJson.repository.url }/releases/tag/${ expectedFirstRelease }) (${ today })` );
			expect( changelogContent[ 13 ] ).toBe( '' );
			expect( changelogContent[ 14 ] ).toBe( '### Features' );
			expect( changelogContent[ 15 ] ).toBe( '' );
			testChangelogChange( changelogContent[ 16 ], commits[ 1 ], initialPackageJson.repository.url );
			expect( changelogContent[ 17 ] ).toBe( '' );
			expect( changelogContent[ 18 ] ).toBe( '### Performance Improvements' );
			expect( changelogContent[ 19 ] ).toBe( '' );
			testChangelogChange( changelogContent[ 20 ], commits[ 2 ], initialPackageJson.repository.url );
			expect( changelogContent[ 21 ] ).toBe( '' );
			expect( changelogContent[ 22 ] ).toBe( '### Refactoring' );
			expect( changelogContent[ 23 ] ).toBe( '' );
			testChangelogChange( changelogContent[ 24 ], commits[ 3 ], initialPackageJson.repository.url );
			expect( changelogContent[ 25 ] ).toBe( '' );
			expect( changelogContent[ 26 ] ).toBe( '### BREAKING CHANGES' );
			expect( changelogContent[ 27 ] ).toBe( '' );
			testChangelogBreakingChange( changelogContent[ 28 ], commits[ 3 ] );

		} );

		it ( 'should make the release commit', async() => {

			const releaseCommit = ( await run( 'git show -s --format=%s', projectPath ) ).replace( /\r?\n/, '' );

			expect( releaseCommit ).toBe( `Release ${ expectedSecondRelease } [skip ci]` );

		} );

		it ( 'should create the release tag', async() => {

			const gitTags: Array<string> = await getGitTags( projectPath );

			expect( gitTags.length ).toBe( 2 );
			expect( gitTags[ 0 ] ).toBe( expectedFirstRelease );
			expect( gitTags[ 1 ] ).toBe( expectedSecondRelease );

		} );

		it ( 'should update the branches', async() => {

			const developMasterDiff = ( await run( 'git diff origin/develop origin/master', projectPath ) );

			expect( developMasterDiff ).toBe( '' );

		} );

		it ( 'should create the GitHub release', async() => {

			const githubReleases: Array<GithubRelease> = await getGithubReleases();
			const githubSecondReleaseContent: Array<string> = githubReleases[ 1 ].body.split( /\r?\n/ );
			const githubFirstReleaseContent: Array<string> = githubReleases[ 0 ].body.split( /\r?\n/ );

			// Check changelog details
			expect( githubReleases[ 1 ].tag_name ).toBe( expectedSecondRelease );
			expect( githubReleases[ 1 ].name ).toBe( expectedSecondRelease );
			expect( githubReleases[ 1 ].target_commitish ).toBe( 'master' );

			// Check changelog content
			expect( githubSecondReleaseContent.length ).toBe( 8 );
			expect( githubSecondReleaseContent[ 0 ] ).toBe( '### Features' );
			expect( githubSecondReleaseContent[ 1 ] ).toBe( '' );
			testChangelogChange( githubSecondReleaseContent[ 2 ], commits[ 5 ], initialPackageJson.repository.url );
			expect( githubSecondReleaseContent[ 3 ] ).toBe( '' );
			expect( githubSecondReleaseContent[ 4 ] ).toBe( '### Bug Fixes' );
			expect( githubSecondReleaseContent[ 5 ] ).toBe( '' );
			testChangelogChange( githubSecondReleaseContent[ 6 ], commits[ 4 ], initialPackageJson.repository.url );
			expect( githubSecondReleaseContent[ 7 ] ).toBe( '' );

			// Check changelog details
			expect( githubReleases[ 0 ].tag_name ).toBe( expectedFirstRelease );
			expect( githubReleases[ 0 ].name ).toBe( expectedFirstRelease );
			expect( githubReleases[ 0 ].target_commitish ).toBe( 'master' );

			// Check changelog content
			expect( githubFirstReleaseContent.length ).toBe( 16 );
			expect( githubFirstReleaseContent[ 0 ] ).toBe( '### Features' );
			expect( githubFirstReleaseContent[ 1 ] ).toBe( '' );
			testChangelogChange( githubFirstReleaseContent[ 2 ], commits[ 1 ], initialPackageJson.repository.url );
			expect( githubFirstReleaseContent[ 3 ] ).toBe( '' );
			expect( githubFirstReleaseContent[ 4 ] ).toBe( '### Performance Improvements' );
			expect( githubFirstReleaseContent[ 5 ] ).toBe( '' );
			testChangelogChange( githubFirstReleaseContent[ 6 ], commits[ 2 ], initialPackageJson.repository.url );
			expect( githubFirstReleaseContent[ 7 ] ).toBe( '' );
			expect( githubFirstReleaseContent[ 8 ] ).toBe( '### Refactoring' );
			expect( githubFirstReleaseContent[ 9 ] ).toBe( '' );
			testChangelogChange( githubFirstReleaseContent[ 10 ], commits[ 3 ], initialPackageJson.repository.url );
			expect( githubFirstReleaseContent[ 11 ] ).toBe( '' );
			expect( githubFirstReleaseContent[ 12 ] ).toBe( '### BREAKING CHANGES' );
			expect( githubFirstReleaseContent[ 13 ] ).toBe( '' );
			testChangelogBreakingChange( githubFirstReleaseContent[ 14 ], commits[ 3 ] );
			expect( githubFirstReleaseContent[ 15 ] ).toBe( '' );

		} );

	} );

} );


text:
import React from 'react';

const FakeIcon = () => {
  return (
    <svg version="1.1" viewBox="0 0 24 24.3616"
      width="24px" height="24px" role="img" />
  );
};
FakeIcon.icon = true;
FakeIcon.displayName = 'Fake';

export default FakeIcon;


text:
#include "Layer.h"
#include "NormLayer.h"
#include "paddle/math/BaseMatrix.h"
#include "paddle/math/Matrix.h"

namespace paddle {

MatrixPtr CrossChannelNormLayer::createSampleMatrix(MatrixPtr data,
                                                    size_t iter,
                                                    size_t spatialDim) {
  return Matrix::create(data->getData() + iter * channels_ * spatialDim,
                        channels_,
                        spatialDim,
                        false,
                        useGpu_);
}

MatrixPtr CrossChannelNormLayer::createSpatialMatrix(MatrixPtr data,
                                                     size_t iter,
                                                     size_t spatialDim) {
  return Matrix::create(
      data->getData() + iter * spatialDim, 1, spatialDim, false, useGpu_);
}

bool CrossChannelNormLayer::init(const LayerMap& layerMap,
                                 const ParameterMap& parameterMap) {
  Layer::init(layerMap, parameterMap);
  CHECK(parameters_[0]);
  const NormConfig& conf = config_.inputs(0).norm_conf();
  channels_ = conf.channels();
  scale_.reset(new Weight(channels_, 1, parameters_[0]));
  return true;
}

void CrossChannelNormLayer::forward(PassType passType) {
  Layer::forward(passType);
  MatrixPtr inV = getInputValue(0);

  size_t batchSize = inV->getHeight();
  size_t dataDim = inV->getWidth();
  CHECK_EQ(getSize(), dataDim);

  reserveOutput(batchSize, dataDim);
  MatrixPtr outV = getOutputValue();
  size_t spatialDim = dataDim / channels_;

  Matrix::resizeOrCreate(dataBuffer_, batchSize, dataDim, false, useGpu_);
  Matrix::resizeOrCreate(spatialBuffer_, 1, spatialDim, false, useGpu_);
  Matrix::resizeOrCreate(normBuffer_, batchSize, spatialDim, false, useGpu_);

  inV->square2(*dataBuffer_);
  for (size_t i = 0; i < batchSize; i++) {
    const MatrixPtr inVTmp = createSampleMatrix(inV, i, spatialDim);
    const MatrixPtr dataTmp = createSampleMatrix(dataBuffer_, i, spatialDim);
    MatrixPtr outVTmp = createSampleMatrix(outV, i, spatialDim);
    MatrixPtr normTmp = createSpatialMatrix(normBuffer_, i, spatialDim);

    // compute norm.
    spatialBuffer_->sumCols(*dataTmp, 1, 0);
    // add eps to avoid overflow
    spatialBuffer_->add(1e-6);
    spatialBuffer_->sqrt2(*spatialBuffer_);
    normTmp->copyFrom(*spatialBuffer_);
    outVTmp->copyFrom(*inVTmp);
    outVTmp->divRowVector(*spatialBuffer_);
    // scale the layer.
    outVTmp->mulColVector(*scale_->getW());
  }
}

void CrossChannelNormLayer::backward(const UpdateCallback& callback) {
  MatrixPtr inG = getInputGrad(0);
  MatrixPtr inV = getInputValue(0);
  MatrixPtr outG = getOutputGrad();
  MatrixPtr outV = getOutputValue();

  size_t batchSize = inG->getHeight();
  size_t dataDim = inG->getWidth();
  size_t spatialDim = dataDim / channels_;

  MatrixPtr inGBuffer;
  Matrix::resizeOrCreate(inGBuffer, channels_, spatialDim, false, useGpu_);

  dataBuffer_->dotMul(*outG, *outV);
  Matrix::resizeOrCreate(scaleDiff_, channels_, 1, false, useGpu_);
  Matrix::resizeOrCreate(channelBuffer_, channels_, 1, false, useGpu_);
  Matrix::resizeOrCreate(sampleBuffer_, channels_, spatialDim, false, useGpu_);
  scaleDiff_->zeroMem();
  for (size_t i = 0; i < batchSize; i++) {
    MatrixPtr outGTmp = createSampleMatrix(outG, i, spatialDim);
    const MatrixPtr dataTmp = createSampleMatrix(dataBuffer_, i, spatialDim);
    const MatrixPtr inVTmp = createSampleMatrix(inV, i, spatialDim);
    const MatrixPtr inGTmp = createSampleMatrix(inG, i, spatialDim);
    const MatrixPtr normTmp = createSpatialMatrix(normBuffer_, i, spatialDim);

    channelBuffer_->sumRows(*dataTmp, 1, 0);
    channelBuffer_->dotDiv(*channelBuffer_, *(scale_->getW()));
    // store a / scale[i] in scaleDiff_ temporary
    scaleDiff_->add(*channelBuffer_, 1.);

    sampleBuffer_->dotMul(*inVTmp, *outGTmp);
    spatialBuffer_->sumCols(*sampleBuffer_, 1., 0.);
    // scale the grad
    inGBuffer->copyFrom(*inVTmp);
    inGBuffer->mulRowVector(*spatialBuffer_);
    // divide by square of norm
    spatialBuffer_->dotMul(*normTmp, *normTmp);
    inGBuffer->divRowVector(*spatialBuffer_);
    // subtract
    inGBuffer->add(*outGTmp, -1, 1);
    // divide by norm
    inGBuffer->divRowVector(*normTmp);
    // scale the diff
    inGBuffer->mulColVector(*scale_->getW());

    inGTmp->add(*inGBuffer);
  }
  // updata scale
  if (scale_->getWGrad()) scale_->getWGrad()->add(*scaleDiff_);
  scale_->getParameterPtr()->incUpdate(callback);
}

}  // namespace paddle


text:
set -e

rm -rf .build
mkdir .build

npm run lint:all

npm run bundle:test
npm run test:chrome
npm run test:electron
npm run test:coverage

npm run report:coveralls

echo "build complete"


text:
'use strict';

const GraphQL = {
  error: require('graphql/error'),
  language: require('graphql/language'),
  language_parser: require('graphql/language/parser'),
  language_source: require('graphql/language/source'),
  type: require('graphql/type'),
  type_introspection: require('graphql/type/introspection'),
  utilities: require('graphql/utilities'),
  utilities_buildClientSchema: require('graphql/utilities/buildClientSchema'),
  validation: require('graphql/validation'),
  validation_rules_KnownFragmentNames: require('graphql/validation/rules/KnownFragmentNames'),
  validation_rules_NoUndefinedVariables: require('graphql/validation/rules/NoUndefinedVariables'),
  validation_rules_NoUnusedFragments: require('graphql/validation/rules/NoUnusedFragments'),
  validation_rules_ScalarLeafs: require('graphql/validation/rules/ScalarLeafs'),
  validation_validate: require('graphql/validation/validate'),
};

module.exports = GraphQL;


text:
title: "About"
date: 2015-05-18 22:01:55
---

![Bob](index/bob.jpg)

Bob Holt has been gardening in the Monadnock Region of New Hampshire since just about yesterday. Son of a Master Gardener and neighbor to an organic farming legend, all mistakes are his own.


text:
import { ChartEvaluation32 } from "../../";

export = ChartEvaluation32;


text:
package org.ormma.controller.util;

import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;

import org.ormma.controller.OrmmaDisplayController;

/**
 * The Class OrmmaConfigurationBroadcastReceiver.
 */
public class OrmmaConfigurationBroadcastReceiver extends BroadcastReceiver {

	private OrmmaDisplayController mOrmmaDisplayController;

	/**
	 * The m last orientation.
	 */
	private int mLastOrientation;

	/**
	 * Instantiates a new ormma configuration broadcast receiver.
	 *
	 * @param ormmaDisplayController the ormma display controller
	 */
	public OrmmaConfigurationBroadcastReceiver(OrmmaDisplayController ormmaDisplayController) {
		mOrmmaDisplayController = ormmaDisplayController;
		mLastOrientation = mOrmmaDisplayController.getOrientation();
	}

	/* (non-Javadoc)
	 * @see android.content.BroadcastReceiver#onReceive(android.content.Context, android.content.Intent)
	 */
	@Override
	public void onReceive(Context context, Intent intent) {
		String action = intent.getAction();
		if (action.equals(Intent.ACTION_CONFIGURATION_CHANGED)) {
			int orientation = mOrmmaDisplayController.getOrientation();
			if (orientation != mLastOrientation) {
				mLastOrientation = orientation;
				mOrmmaDisplayController.onOrientationChanged(mLastOrientation);
			}
		}
	}

}


text:
Pagination Class
################

CodeIgniter's Pagination class is very easy to use, and it is 100%
customizable, either dynamically or via stored preferences.

.. contents::
  :local:

.. raw:: html

If you are not familiar with the term "pagination", it refers to links
that allows you to navigate from page to page, like this::

	« First  < 1 2 3 4 5 >  Last »

*******
Example
*******

Here is a simple example showing how to create pagination in one of your
:doc:`controller <../general/controllers>` methods::

	$this->load->library('pagination');

	$config['base_url'] = 'http://example.com/index.php/test/page/';
	$config['total_rows'] = 200;
	$config['per_page'] = 20;

	$this->pagination->initialize($config);

	echo $this->pagination->create_links();

Notes
=====

The ``$config`` array contains your configuration variables. It is passed to
the ``$this->pagination->initialize()`` method as shown above. Although
there are some twenty items you can configure, at minimum you need the
three shown. Here is a description of what those items represent:

-  **base_url** This is the full URL to the controller class/function
   containing your pagination. In the example above, it is pointing to a
   controller called "Test" and a function called "page". Keep in mind
   that you can :doc:`re-route your URI <../general/routing>` if you
   need a different structure.
-  **total_rows** This number represents the total rows in the result
   set you are creating pagination for. Typically this number will be
   the total rows that your database query returned.
-  **per_page** The number of items you intend to show per page. In the
   above example, you would be showing 20 items per page.

The ``create_links()`` method returns an empty string when there is no
pagination to show.

Setting preferences in a config file
====================================

If you prefer not to set preferences using the above method, you can
instead put them into a config file. Simply create a new file called
pagination.php, add the ``$config`` array in that file. Then save the file
in *application/config/pagination.php* and it will be used automatically.
You will NOT need to use ``$this->pagination->initialize()`` if you save
your preferences in a config file.

**************************
Customizing the Pagination
**************************

The following is a list of all the preferences you can pass to the
initialization function to tailor the display.

**$config['uri_segment'] = 3;**

The pagination function automatically determines which segment of your
URI contains the page number. If you need something different you can
specify it.

**$config['num_links'] = 2;**

The number of "digit" links you would like before and after the selected
page number. For example, the number 2 will place two digits on either
side, as in the example links at the very top of this page.

**$config['use_page_numbers'] = TRUE;**

By default, the URI segment will use the starting index for the items
you are paginating. If you prefer to show the the actual page number,
set this to TRUE.

**$config['page_query_string'] = TRUE;**

By default, the pagination library assume you are using :doc:`URI
Segments <../general/urls>`, and constructs your links something
like::

	http://example.com/index.php/test/page/20

If you have ``$config['enable_query_strings']`` set to TRUE your links
will automatically be re-written using Query Strings. This option can
also be explicitly set. Using ``$config['page_query_string']`` set to TRUE,
the pagination link will become::

	http://example.com/index.php?c=test&m=page&per_page=20

Note that "per_page" is the default query string passed, however can be
configured using ``$config['query_string_segment'] = 'your_string'``

**$config['reuse_query_string'] = FALSE;**

By default your Query String arguments (nothing to do with other
query string options) will be ignored. Setting this config to
TRUE will add existing query string arguments back into the
URL after the URI segment and before the suffix.::

	http://example.com/index.php/test/page/20?query=search%term

This helps you mix together normal :doc:`URI Segments <../general/urls>`
as well as query string arguments, which until 3.0 was not possible.

**$config['prefix'] = '';**

A custom prefix added to the path. The prefix value will be right before
the offset segment.

**$config['suffix'] = '';**

A custom suffix added to the path. The suffix value will be right after
the offset segment.

**$config['use_global_url_suffix'] = FALSE;**

When set to TRUE, it will **override** the ``$config['suffix']`` value and
instead set it to the one that you have in ``$config['url_suffix']`` in
your **application/config/config.php** file.

***********************
Adding Enclosing Markup
***********************

If you would like to surround the entire pagination with some markup you
can do it with these two preferences:

**$config['full_tag_open'] = '
';**

The opening tag placed on the left side of the entire result.

**$config['full_tag_close'] = '
';**

The closing tag placed on the right side of the entire result.

**************************
Customizing the First Link
**************************

**$config['first_link'] = 'First';**

The text you would like shown in the "first" link on the left. If you do
not want this link rendered, you can set its value to FALSE.

.. note:: This value can also be translated via a language file.

**$config['first_tag_open'] = '
';**

The opening tag for the "first" link.

**$config['first_tag_close'] = '
';**

The closing tag for the "first" link.

**$config['first_url'] = '';**

An alternative URL to use for the "first page" link.

*************************
Customizing the Last Link
*************************

**$config['last_link'] = 'Last';**

The text you would like shown in the "last" link on the right. If you do
not want this link rendered, you can set its value to FALSE.

.. note:: This value can also be translated via a language file.

**$config['last_tag_open'] = '
';**

The opening tag for the "last" link.

**$config['last_tag_close'] = '
';**

The closing tag for the "last" link.

***************************
Customizing the "Next" Link
***************************

**$config['next_link'] = '>';**

The text you would like shown in the "next" page link. If you do not
want this link rendered, you can set its value to FALSE.

.. note:: This value can also be translated via a language file.

**$config['next_tag_open'] = '
';**

The opening tag for the "next" link.

**$config['next_tag_close'] = '
';**

The closing tag for the "next" link.

*******************************
Customizing the "Previous" Link
*******************************

**$config['prev_link'] = '<';**

The text you would like shown in the "previous" page link. If you do not
want this link rendered, you can set its value to FALSE.

.. note:: This value can also be translated via a language file.

**$config['prev_tag_open'] = '
';**

The opening tag for the "previous" link.

**$config['prev_tag_close'] = '
';**

The closing tag for the "previous" link.

***********************************
Customizing the "Current Page" Link
***********************************

**$config['cur_tag_open'] = '';**

The opening tag for the "current" link.

**$config['cur_tag_close'] = '';**

The closing tag for the "current" link.

****************************
Customizing the "Digit" Link
****************************

**$config['num_tag_open'] = '
';**

The opening tag for the "digit" link.

**$config['num_tag_close'] = '
';**

The closing tag for the "digit" link.

****************
Hiding the Pages
****************

If you wanted to not list the specific pages (for example, you only want
"next" and "previous" links), you can suppress their rendering by
adding::

	 $config['display_pages'] = FALSE;

****************************
Adding attributes to anchors
****************************

If you want to add an extra attribute to be added to every link rendered
by the pagination class, you can set them as key/value pairs in the
"attributes" config::

	// Produces: class="myclass"
	$config['attributes'] = array('class' => 'myclass');

*****************************
Disabling the "rel" attribute
*****************************

By default the rel attribute is dynamically generated and appended to
the appropriate anchors. If for some reason you want to turn it off,
you can pass boolean FALSE as a regular attribute

::

	$config['attributes']['rel'] = FALSE;

***************
Class Reference
***************

.. php:class:: CI_Pagination

	.. php:method:: initialize([$params = array()])

		:param	array	$params: Configuration parameters
		:returns:	CI_Pagination instance (method chaining)
		:rtype:	CI_Pagination

		Initializes the Pagination class with your preferred options.

	.. php:method:: create_links()

		:returns:	HTML-formatted pagination
		:rtype:	string

		Returns a "pagination" bar, containing the generated links or an empty string if there's just a single page.


text:
<?php
$db_config = include_once (PINPHP_PATH . 'data/config/db.php');
$uc_config =  array(
    'DEFAULT_MODULE' => 'index',
);
return array_merge($db_config, $uc_config);


text:
//
//     Kerbal Engineer Redux
//
//     Copyright (C) 2014 CYBUTEK
//
//     This program is free software: you can redistribute it and/or modify
//     it under the terms of the GNU General Public License as published by
//     the Free Software Foundation, either version 3 of the License, or
//     (at your option) any later version.
//
//     This program is distributed in the hope that it will be useful,
//     but WITHOUT ANY WARRANTY; without even the implied warranty of
//     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
//     GNU General Public License for more details.
//
//     You should have received a copy of the GNU General Public License
//     along with this program.  If not, see <http://www.gnu.org/licenses/>.
//

#region Using Directives

using System;

using KerbalEngineer.Flight.Sections;
using KerbalEngineer.Helpers;

#endregion

namespace KerbalEngineer.Flight.Readouts.Orbital.ManoeuvreNode
{
    public class NodeTimeToHalfBurn : ReadoutModule
    {
        #region Constructors

        public NodeTimeToHalfBurn()
        {
            this.Name = "Time to Manoeuvre Burn";
            this.Category = ReadoutCategory.GetCategory("Orbital");
            this.HelpString = String.Empty;
            this.IsDefault = true;
        }

        #endregion

        #region Methods: public

        public override void Draw(SectionModule section)
        {
            if (!ManoeuvreProcessor.ShowDetails)
            {
                return;
            }

            this.DrawLine("Time to Node Burn", TimeFormatter.ConvertToString(ManoeuvreProcessor.UniversalTime - ManoeuvreProcessor.HalfBurnTime - Planetarium.GetUniversalTime()), section.IsHud);
        }

        public override void Reset()
        {
            ManoeuvreProcessor.Reset();
        }

        public override void Update()
        {
            ManoeuvreProcessor.RequestUpdate();
        }

        #endregion
    }
}


text:
#if !defined(TINYDEMO_INVITE_H)
#define TINYDEMO_INVITE_H

#include "demo_config.h"

#include "common.h"

_BEGIN_DECLS

int invite_handle_event(const tsip_event_t *sipevent);
tsip_ssession_id_t invite_handle_cmd(cmd_type_t cmd, const opts_L_t* opts);

_END_DECLS

#endif /* TINYDEMO_INVITE_H */


text:
package me.winter.boing.simulation;

import me.winter.boing.colliders.Box;
import me.winter.boing.colliders.Circle;
import me.winter.boing.impl.BodyImpl;
import me.winter.boing.resolver.CollisionResolver;
import me.winter.boing.resolver.VelocityResolver;
import me.winter.boing.simulation.simulator.BoingSimulator;
import me.winter.boing.testimpl.BouncingBallImpl;
import me.winter.boing.testimpl.TestPhysicsWorldImpl;
import org.junit.Ignore;
import org.junit.Test;

/**
 * Undocumented :(
 * <p>
 * Created by Alexander Winter on 2017-04-11.
 */
@Ignore
public class VelocityResolverSimulation
{

	@Test
	public void testCirclesInBox()
	{
		CollisionResolver resolver = new VelocityResolver();
		TestPhysicsWorldImpl world = new TestPhysicsWorldImpl(resolver);

		BouncingBallImpl solid = new BouncingBallImpl();

		solid.getPosition().set(50, 50);
		solid.addCollider(new Circle(solid, 0, 0, 25));
		solid.getVelocity().set(179, 150);

		world.add(solid);

		BouncingBallImpl solid2 = new BouncingBallImpl();

		solid2.getPosition().set(500, 50);
		solid2.addCollider(new Circle(solid2, 0, 0, 20));
		solid2.getVelocity().set(-150, 150);

		world.add(solid2);

		BouncingBallImpl solid3 = new BouncingBallImpl();

		solid3.getPosition().set(300, 500);
		solid3.addCollider(new Circle(solid3, 0, 0, 25));
		solid3.getVelocity().set(0, -100);

		world.add(solid3);

		BouncingBallImpl solid4 = new BouncingBallImpl();

		solid4.getPosition().set(500, 500);
		solid4.addCollider(new Circle(solid4, 0, 0, 25));
		solid4.getVelocity().set(-100, -100);

		world.add(solid4);

		for(int i = 20; i < 800; i+= 20)
		{
			BouncingBallImpl wall1 = new BouncingBallImpl();

			wall1.getPosition().set(i, 0);
			wall1.addCollider(new Circle(wall1, 0, 0, 10));
			wall1.getVelocity().set(0, 0);

			world.add(wall1);
		}

		for(int i = 20; i < 800; i+= 20)
		{
			BouncingBallImpl wall1 = new BouncingBallImpl();

			wall1.getPosition().set(i, 600);
			wall1.addCollider(new Circle(wall1, 0, 0, 10));
			wall1.getVelocity().set(0, 0);

			world.add(wall1);
		}

		for(int i = 20; i < 600; i+= 20)
		{
			BouncingBallImpl wall1 = new BouncingBallImpl();

			wall1.getPosition().set(0, i);
			wall1.addCollider(new Circle(wall1, 0, 0, 10));
			wall1.getVelocity().set(0, 0);

			world.add(wall1);
		}

		for(int i = 20; i < 600; i+= 20)
		{
			BouncingBallImpl wall1 = new BouncingBallImpl();

			wall1.getPosition().set(800, i);
			wall1.addCollider(new Circle(wall1, 0, 0, 10));
			wall1.getVelocity().set(0, 0);

			world.add(wall1);
		}
		new BoingSimulator(world, 60f).start();
	}

	@Test
	public void testBoxBouncingOnBoxX()
	{
		CollisionResolver resolver = new VelocityResolver();
		TestPhysicsWorldImpl world = new TestPhysicsWorldImpl(resolver);

		BouncingBallImpl solid = new BouncingBallImpl();
		solid.getPosition().set(400, 400);
		solid.addCollider(new Box(solid, 0, 0, 40, 25));
		solid.getVelocity().set(-50, 0);
		world.add(solid);

		BouncingBallImpl solid2 = new BouncingBallImpl();
		solid2.getPosition().set(650, 400);
		solid2.addCollider(new Box(solid2, 0, 0, 80, 100));
		solid2.getVelocity().set(-60, 0);
		world.add(solid2);

		BouncingBallImpl solid3 = new BouncingBallImpl();
		solid3.getPosition().set(280, 400);
		solid3.addCollider(new Box(solid3, 0, 0, 50, 50));
		solid3.getVelocity().set(-10, 0);
		world.add(solid3);

		new BoingSimulator(world, 60f).start();
	}

	@Test
	public void testBoxBouncingOnBoxY()
	{
		CollisionResolver resolver = new VelocityResolver();
		TestPhysicsWorldImpl world = new TestPhysicsWorldImpl(resolver);

		BouncingBallImpl solid = new BouncingBallImpl();
		solid.getPosition().set(400, 400);
		solid.addCollider(new Box(solid, 0, 0, 40, 25));
		solid.getVelocity().set(0, -50);
		world.add(solid);

		BouncingBallImpl solid2 = new BouncingBallImpl();
		solid2.getPosition().set(400, 650);
		solid2.addCollider(new Box(solid2, 0, 0, 80, 100));
		solid2.getVelocity().set(0, -60);
		world.add(solid2);

		BouncingBallImpl solid3 = new BouncingBallImpl();
		solid3.getPosition().set(400, 280);
		solid3.addCollider(new Box(solid3, 0, 0, 50, 50));
		solid3.getVelocity().set(0, -10);
		world.add(solid3);

		new BoingSimulator(world, 60f).start();
	}

	@Test
	public void testBoxWideBounce()
	{
		CollisionResolver resolver = new VelocityResolver();
		TestPhysicsWorldImpl world = new TestPhysicsWorldImpl(resolver);

		BodyImpl ground = new BodyImpl();
		ground.getPosition().set(400, 0);
		ground.addCollider(new Box(ground, 0, 0, 800, 100));
		world.add(ground);

		BouncingBallImpl box = new BouncingBallImpl();
		box.getPosition().set(100, 125);
		box.addCollider(new Box(box, 0, 0, 50, 50));
		box.getVelocity().set(150, -20);
		world.add(box);

		new BoingSimulator(world, 60f).start();
	}

	@Test
	public void testBoxesInBallCage()
	{
		CollisionResolver resolver = new VelocityResolver();
		TestPhysicsWorldImpl world = new TestPhysicsWorldImpl(resolver);

		BouncingBallImpl solid = new BouncingBallImpl();
		solid.getPosition().set(400, 400);
		solid.addCollider(new Box(solid, 0, 0, 40, 25));
		solid.getVelocity().set(-50, -20);
		world.add(solid);

		BouncingBallImpl solid2 = new BouncingBallImpl();
		solid2.getPosition().set(650, 400);
		solid2.addCollider(new Box(solid2, 0, 0, 80, 100));
		solid2.getVelocity().set(-60, 30);
		world.add(solid2);

		BouncingBallImpl solid3 = new BouncingBallImpl();
		solid3.getPosition().set(280, 400);
		solid3.addCollider(new Box(solid3, 0, 0, 50, 50));
		solid3.getVelocity().set(-10, 25);
		world.add(solid3);

		for(int i = 20; i < 800; i+= 20)
		{
			BouncingBallImpl wall1 = new BouncingBallImpl();
			wall1.getPosition().set(i, 0);
			wall1.addCollider(new Circle(wall1, 0, 0, 10));
			wall1.getVelocity().set(0, 0);
			world.add(wall1);
		}

		for(int i = 20; i < 800; i+= 20)
		{
			BouncingBallImpl wall1 = new BouncingBallImpl();
			wall1.getPosition().set(i, 600);
			wall1.addCollider(new Circle(wall1, 0, 0, 10));
			wall1.getVelocity().set(0, 0);
			world.add(wall1);
		}

		for(int i = 20; i < 600; i+= 20)
		{
			BouncingBallImpl wall1 = new BouncingBallImpl();
			wall1.getPosition().set(0, i);
			wall1.addCollider(new Circle(wall1, 0, 0, 10));
			wall1.getVelocity().set(0, 0);
			world.add(wall1);
		}

		for(int i = 20; i < 600; i+= 20)
		{
			BouncingBallImpl wall1 = new BouncingBallImpl();
			wall1.getPosition().set(800, i);
			wall1.addCollider(new Circle(wall1, 0, 0, 10));
			wall1.getVelocity().set(0, 0);
			world.add(wall1);
		}

		new BoingSimulator(world, 60f).start();
	}

	@Test
	public void testCircleBouncingBetween2Circles()
	{
		CollisionResolver resolver = new VelocityResolver();
		TestPhysicsWorldImpl world = new TestPhysicsWorldImpl(resolver);

		BouncingBallImpl solid = new BouncingBallImpl();
		solid.getPosition().set(400, 400);
		solid.addCollider(new Circle(solid, 0, 0, 25));
		solid.getVelocity().set(50, 0);
		world.add(solid);

		BouncingBallImpl solid2 = new BouncingBallImpl();
		solid2.getPosition().set(550, 400);
		solid2.addCollider(new Circle(solid2, 0, 0, 50));
		solid2.getVelocity().set(0, 0);
		world.add(solid2);

		BouncingBallImpl solid3 = new BouncingBallImpl();
		solid3.getPosition().set(250, 400);
		solid3.addCollider(new Circle(solid3, 0, 0, 50));
		solid3.getVelocity().set(0, 0);
		world.add(solid3);

		new BoingSimulator(world, 60f).start();
	}

	@Test
	public void testCircleColling2Circles()
	{
		CollisionResolver resolver = new VelocityResolver();
		TestPhysicsWorldImpl world = new TestPhysicsWorldImpl(resolver);

		BouncingBallImpl solid = new BouncingBallImpl();
		solid.getPosition().set(400, 400);
		solid.addCollider(new Circle(solid, 0, 0, 25));
		solid.getVelocity().set(0, -50);
		world.add(solid);

		BouncingBallImpl solid2 = new BouncingBallImpl();
		solid2.getPosition().set(450, 100);
		solid2.addCollider(new Circle(solid2, 0, 0, 50));
		solid2.getVelocity().set(0, 0);
		world.add(solid2);

		BouncingBallImpl solid3 = new BouncingBallImpl();
		solid3.getPosition().set(350, 100);
		solid3.addCollider(new Circle(solid3, 0, 0, 50));
		solid3.getVelocity().set(0, 0);
		world.add(solid3);

		new BoingSimulator(world, 60f).start();
	}
}


text:
package org.apache.activemq.artemis.api.core.management;

import java.text.DateFormat;
import java.util.Date;

import org.apache.activemq.artemis.core.messagecounter.MessageCounter;
import org.apache.activemq.artemis.utils.json.JSONObject;

/**
 * Helper class to create Java Objects from the
 * JSON serialization returned by {@link QueueControl#listMessageCounter()}.
 */
public final class MessageCounterInfo {

   private final String name;

   private final String subscription;

   private final boolean durable;

   private final long count;

   private final long countDelta;

   private final int depth;

   private final int depthDelta;

   private final String lastAddTimestamp;

   private final String udpateTimestamp;

   /**
    * Returns a JSON String serialization of a {@link MessageCounter} object.
    *
    * @param counter
    * @return
    * @throws Exception
    */
   public static String toJSon(final MessageCounter counter) throws Exception {
      DateFormat dateFormat = DateFormat.getDateTimeInstance(DateFormat.SHORT, DateFormat.MEDIUM);

      JSONObject json = new JSONObject(counter);
      String lastAddTimestamp = dateFormat.format(new Date(counter.getLastAddedMessageTime()));
      json.put("lastAddTimestamp", lastAddTimestamp);
      String updateTimestamp = dateFormat.format(new Date(counter.getLastUpdate()));
      json.put("updateTimestamp", updateTimestamp);

      return json.toString();
   }

   /**
    * Returns an array of RoleInfo corresponding to the JSON serialization returned
    * by {@link QueueControl#listMessageCounter()}.
    */
   public static MessageCounterInfo fromJSON(final String jsonString) throws Exception {
      JSONObject data = new JSONObject(jsonString);
      String name = data.getString("destinationName");
      String subscription = data.getString("destinationSubscription");
      boolean durable = data.getBoolean("destinationDurable");
      long count = data.getLong("count");
      long countDelta = data.getLong("countDelta");
      int depth = data.getInt("messageCount");
      int depthDelta = data.getInt("messageCountDelta");
      String lastAddTimestamp = data.getString("lastAddTimestamp");
      String updateTimestamp = data.getString("updateTimestamp");

      return new MessageCounterInfo(name, subscription, durable, count, countDelta, depth, depthDelta, lastAddTimestamp, updateTimestamp);
   }

   // Constructors --------------------------------------------------

   public MessageCounterInfo(final String name,
                             final String subscription,
                             final boolean durable,
                             final long count,
                             final long countDelta,
                             final int depth,
                             final int depthDelta,
                             final String lastAddTimestamp,
                             final String udpateTimestamp) {
      this.name = name;
      this.subscription = subscription;
      this.durable = durable;
      this.count = count;
      this.countDelta = countDelta;
      this.depth = depth;
      this.depthDelta = depthDelta;
      this.lastAddTimestamp = lastAddTimestamp;
      this.udpateTimestamp = udpateTimestamp;
   }

   // Public --------------------------------------------------------

   /**
    * Returns the name of the queue.
    */
   public String getName() {
      return name;
   }

   /**
    * Returns the name of the subscription.
    */
   public String getSubscription() {
      return subscription;
   }

   /**
    * Returns whether the queue is durable.
    */
   public boolean isDurable() {
      return durable;
   }

   /**
    * Returns the number of messages added to the queue since it was created.
    */
   public long getCount() {
      return count;
   }

   /**
    * Returns the number of messages added to the queue since the last counter sample.
    */
   public long getCountDelta() {
      return countDelta;
   }

   /**
    * Returns the number of messages currently in the queue.
    */
   public int getDepth() {
      return depth;
   }

   /**
    * Returns the number of messages in the queue since last counter sample.
    */
   public int getDepthDelta() {
      return depthDelta;
   }

   /**
    * Returns the timestamp of the last time a message was added to the queue.
    */
   public String getLastAddTimestamp() {
      return lastAddTimestamp;
   }

   /**
    * Returns the timestamp of the last time the queue was updated.
    */
   public String getUdpateTimestamp() {
      return udpateTimestamp;
   }
}


text:
using System;
using Groorine.Helpers;

namespace Groorine.DataModel
{
	public class Channel : BindableBase, IChannel
	{
		private byte _panpot;
		private byte _volume;
		private byte _expression;
		private int _pitchbend;
		private short _tweak;
		private short _noteShift;
		private short _bendRange;
		private double _freqExts;

		public byte Panpot
		{
			get { return _panpot; }
			set { SetProperty(ref _panpot, value); }
		}

		public byte Volume
		{
			get { return _volume; }
			set { SetProperty(ref _volume, value); }
		}

		private void CheckCc(byte ccValue)
		{
			if (ccValue > 127)
				throw new ArgumentOutOfRangeException(nameof(ccValue));
		}

		public byte Expression
		{

			get { return _expression; }
			set { SetProperty(ref _expression, value); }
		}

		public int Pitchbend
		{
			get { return _pitchbend; }
			set
			{
				SetProperty(ref _pitchbend, value);
				FreqExts = GetFreqExts();
			}
		}

		public short Tweak
		{
			get { return _tweak; }
			set
			{
				SetProperty(ref _tweak, value);
				FreqExts = GetFreqExts();
			}
		}

		public short NoteShift
		{
			get { return _noteShift; }
			set
			{
				SetProperty(ref _noteShift, value);
				FreqExts = GetFreqExts();
			}
		}

		public short BendRange
		{
			get { return _bendRange; }
			set
			{
				SetProperty(ref _bendRange, value);
				FreqExts = GetFreqExts();
			}
		}

		public double FreqExts
		{
			get { return _freqExts; }
			set { SetProperty(ref _freqExts, value); }
		}

		internal Channel(byte panpot, byte volume, byte expression, short tweak, short noteShift, short bendRange)
		{
			Panpot = panpot;
			Volume = volume;
			Expression = expression;
			Tweak = tweak;
			NoteShift = noteShift;
			BendRange = bendRange;
			Pitchbend = 0;
			FreqExts = GetFreqExts();
		}

		internal Channel() : this(64, 100, 100, 0, 0, 2) { }

		public double GetFreqExts() => _freqExts = Math.Pow(2, (Pitchbend / 8192d) * (BendRange / 12d)) * Math.Pow(2, (Tweak / 8192d) * (2 / 12d)) * Math.Pow(2, NoteShift / 12d);
	}
}


text:
package org.smslib;

import javax.crypto.spec.SecretKeySpec;
import junit.framework.TestCase;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.smslib.callback.IDeliveryReportCallback;
import org.smslib.callback.IInboundMessageCallback;
import org.smslib.callback.events.DeliveryReportCallbackEvent;
import org.smslib.callback.events.InboundMessageCallbackEvent;
import org.smslib.crypto.AESKey;
import org.smslib.gateway.modem.Modem;
import org.smslib.message.OutboundEncryptedMessage;
import org.smslib.message.OutboundMessage;

public class Test_IPModem extends TestCase
{
	static Logger logger = LoggerFactory.getLogger(Test_IPModem.class);

	public static String RECIPIENT = "";

	public class InboundMessageCallback implements IInboundMessageCallback
	{
		@Override
		public boolean process(InboundMessageCallbackEvent event)
		{
			logger.info("[InboundMessageCallback] " + event.getMessage().toShortString());
			logger.info(event.getMessage().toString());
			return true;
		}
	}

	public class DeliveryReportCallback implements IDeliveryReportCallback
	{
		@Override
		public boolean process(DeliveryReportCallbackEvent event)
		{
			logger.info("[DeliveryReportCallback] " + event.getMessage().toShortString());
			logger.info(event.getMessage().toString());
			return true;
		}
	}

	public void test() throws Exception
	{
		if (true) logger.info("IP Modem test disabled!");
		else
		{
			Service.getInstance().setInboundMessageCallback(new InboundMessageCallback());
			Service.getInstance().setDeliveryReportCallback(new DeliveryReportCallback());
			Service.getInstance().start();
			Modem gateway = new Modem("modem1", "127.0.0.1", "10000", "0000", "0000", "306942190000", "AA");
			Service.getInstance().registerGateway(gateway);
			Thread.sleep(20000);
			if (RECIPIENT.length() > 0)
			{
				logger.info("Sending a simple test message...");
				Service.getInstance().send(new OutboundMessage(RECIPIENT, "Test"));
				Thread.sleep(20000);
				logger.info("Sending an encrypted message...");
				Service.getInstance().getKeyManager().registerKey(RECIPIENT, new AESKey(new SecretKeySpec("0011223344556677".getBytes(), "AES")));
				Service.getInstance().send(new OutboundEncryptedMessage(RECIPIENT, "Test".getBytes()));
				Thread.sleep(20000);
			}
			Service.getInstance().unregisterGateway(gateway);
			try
			{
				gateway.refreshDeviceInfo();
				throw new RuntimeException("Should never get here!");
			}
			catch (Exception e)
			{
				//
			}
			Service.getInstance().stop();
			Service.getInstance().terminate();
		}
	}
}


text:
// Generated by Haxe 3.4.0
#ifndef INCLUDED_kha_audio2_ogg_vorbis_data_Header
#define INCLUDED_kha_audio2_ogg_vorbis_data_Header

#ifndef HXCPP_H
#include <hxcpp.h>
#endif

HX_DECLARE_STACK_FRAME(_hx_pos_5d80631968e67c5f_37_new)
HX_DECLARE_CLASS4(kha,audio2,ogg,vorbis,VorbisDecodeState)
HX_DECLARE_CLASS5(kha,audio2,ogg,vorbis,data,Codebook)
HX_DECLARE_CLASS5(kha,audio2,ogg,vorbis,data,Comment)
HX_DECLARE_CLASS5(kha,audio2,ogg,vorbis,data,Floor)
HX_DECLARE_CLASS5(kha,audio2,ogg,vorbis,data,Header)
HX_DECLARE_CLASS5(kha,audio2,ogg,vorbis,data,Mapping)
HX_DECLARE_CLASS5(kha,audio2,ogg,vorbis,data,Mode)
HX_DECLARE_CLASS5(kha,audio2,ogg,vorbis,data,Residue)

namespace kha{
namespace audio2{
namespace ogg{
namespace vorbis{
namespace data{

class HXCPP_CLASS_ATTRIBUTES Header_obj : public hx::Object
{
	public:
		typedef hx::Object super;
		typedef Header_obj OBJ_;
		Header_obj();

	public:
		enum { _hx_ClassId = 0x3258cf5d };

		void __construct();
		inline void *operator new(size_t inSize, bool inContainer=true,const char *inName="kha.audio2.ogg.vorbis.data.Header")
			{ return hx::Object::operator new(inSize,inContainer,inName); }
		inline void *operator new(size_t inSize, int extra)
			{ return hx::Object::operator new(inSize+extra,true,"kha.audio2.ogg.vorbis.data.Header"); }

		hx::ObjectPtr< Header_obj > __new() {
			hx::ObjectPtr< Header_obj > __this = new Header_obj();
			__this->__construct();
			return __this;
		}

		static hx::ObjectPtr< Header_obj > __alloc(hx::Ctx *_hx_ctx) {
			Header_obj *__this = (Header_obj*)(hx::Ctx::alloc(_hx_ctx, sizeof(Header_obj), true, "kha.audio2.ogg.vorbis.data.Header"));
			*(void **)__this = Header_obj::_hx_vtable;
{
            	HX_STACKFRAME(&_hx_pos_5d80631968e67c5f_37_new)
            	HX_STACK_THIS(__this)
            	}

			return __this;
		}

		static void * _hx_vtable;
		static Dynamic __CreateEmpty();
		static Dynamic __Create(hx::DynamicArray inArgs);
		//~Header_obj();

		HX_DO_RTTI_ALL;
		hx::Val __Field(const ::String &inString, hx::PropertyAccess inCallProp);
		static bool __GetStatic(const ::String &inString, Dynamic &outValue, hx::PropertyAccess inCallProp);
		hx::Val __SetField(const ::String &inString,const hx::Val &inValue, hx::PropertyAccess inCallProp);
		void __GetFields(Array< ::String> &outFields);
		static void __register();
		void __Mark(HX_MARK_PARAMS);
		void __Visit(HX_VISIT_PARAMS);
		bool _hx_isInstanceOf(int inClassId);
		::String __ToString() const { return HX_HCSTRING("Header","\xad","\x7d","\x94","\x31"); }

		static void __boot();
		static int PACKET_ID;
		static int PACKET_COMMENT;
		static int PACKET_SETUP;
		static  ::kha::audio2::ogg::vorbis::data::Header read( ::kha::audio2::ogg::vorbis::VorbisDecodeState decodeState);
		static ::Dynamic read_dyn();

		int maximumBitRate;
		int nominalBitRate;
		int minimumBitRate;
		int sampleRate;
		int channel;
		int blocksize0;
		int blocksize1;
		::Array< ::Dynamic> codebooks;
		::Array< ::Dynamic> floorConfig;
		::Array< ::Dynamic> residueConfig;
		::Array< ::Dynamic> mapping;
		::Array< ::Dynamic> modes;
		 ::kha::audio2::ogg::vorbis::data::Comment comment;
		::String vendor;
};

} // end namespace kha
} // end namespace audio2
} // end namespace ogg
} // end namespace vorbis
} // end namespace data

#endif /* INCLUDED_kha_audio2_ogg_vorbis_data_Header */


text:
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android" >

    <solid android:color="#E0E0E0" />

    <stroke
        android:width="0.1dp"
        android:color="#404040" />

    <corners
        android:bottomLeftRadius="6dp"
        android:bottomRightRadius="6dp"
        android:topLeftRadius="6dp"
        android:topRightRadius="6dp" />

</shape>


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

namespace default_values
{
    class Program
    {
        static void Main(string[] args)
        {
            var dict = new Dictionary<string, string>();

            var line = Console.ReadLine();

            while (line != "end")
            {
                var tokens = line.Split(new string[] { " -> " }, StringSplitOptions.RemoveEmptyEntries);

                var key = tokens[0];
                var value = tokens[1];

                if (!dict.ContainsKey(key))
                {
                    dict.Add(key, String.Empty);
                }

                dict[key] = value;

                line = Console.ReadLine();
            }

            var replacer = Console.ReadLine();

            foreach (var kvp in dict.Where(x => x.Value != "null").OrderByDescending(x => x.Value.Length))
            {
                Console.WriteLine($"{kvp.Key} <-> {kvp.Value}");
            }
            foreach (var kvp in dict.Where(x => x.Value == "null"))
            {
                 Console.WriteLine($"{kvp.Key} <-> {replacer}");
            }
        }
    }
}


text:
// Copyright 2022 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     https://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// ** This file is automatically generated by gapic-generator-typescript. **
// ** https://github.com/googleapis/gapic-generator-typescript **
// ** All changes to this file may be overwritten. **

'use strict';

function main(name) {
  // [START osconfig_v1_generated_OsConfigService_PausePatchDeployment_async]
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The resource name of the patch deployment in the form
   *  `projects/* /patchDeployments/*`.
   */
  // const name = 'abc123'

  // Imports the Osconfig library
  const {OsConfigServiceClient} = require('@google-cloud/os-config').v1;

  // Instantiates a client
  const osconfigClient = new OsConfigServiceClient();

  async function callPausePatchDeployment() {
    // Construct request
    const request = {
      name,
    };

    // Run request
    const response = await osconfigClient.pausePatchDeployment(request);
    console.log(response);
  }

  callPausePatchDeployment();
  // [END osconfig_v1_generated_OsConfigService_PausePatchDeployment_async]
}

process.on('unhandledRejection', err => {
  console.error(err.message);
  process.exitCode = 1;
});
main(...process.argv.slice(2));


text:
import React from 'react';

/**
 * TextInput();
 *
 * Params:
 *
 * @param {string} cssClass - type attribute for input element ("text" || "paragraph")
 * @param {string || number} value - value to associate with button click (optional)
 * @param {string} label - text label for element
 * @param {function} onUpdate - function to execute when the button is clicked
 *
 * Example:
 *
  <SubmitButton
     type="text"
     label="Submit"
     name="submit_data"
     onChange={this.update}
   />
 */
export class SubmitButton extends React.Component {
  constructor(props) {
    super(props);
  };

  render() {
  	var cssClass = "btn ";

  	if (this.props.cssClass) {
  		cssClass += this.props.cssClass;
  	}

    return
{this.props.label}

  }
}


text:
package com.team254.frc2013.auto;

import com.team254.frc2013.commands.ResetDriveEncodersCommand;
import com.team254.frc2013.commands.ResetGyroCommand;
import com.team254.frc2013.commands.RunIntakeCommand;
import com.team254.frc2013.commands.SetIntakeDownCommand;
import com.team254.frc2013.commands.ShootSequenceCommand;
import com.team254.frc2013.commands.ShooterOnCommand;
import com.team254.frc2013.commands.ShooterPresetCommand;
import com.team254.frc2013.commands.WaitCommand;
import com.team254.frc2013.subsystems.Shooter;
import edu.wpi.first.wpilibj.command.CommandGroup;

/**
 * Shoots two preload discs from the front of the pyramid
 *
 * @author jonathan.chang13@gmail.com (Jonathan Chang)
 */
public class TwoDiscAutoMode extends CommandGroup {

  public TwoDiscAutoMode() {
    addSequential(new ResetDriveEncodersCommand());
    addSequential(new ResetGyroCommand());
    addSequential(new ShooterOnCommand(true));
    addSequential(new SetIntakeDownCommand());
    addSequential(new ShooterPresetCommand(Shooter.PRESET_FRONT_PYRAMID));
    addSequential(new WaitCommand(0.25));
    addSequential(new ShootSequenceCommand());
    addSequential(new ShootSequenceCommand());
    addSequential(new ShooterOnCommand(false));
    addSequential(new RunIntakeCommand(0.0));
  }
}


text:
package org.mp4parser.boxes.apple;

/**
 * Created by sannies on 10/22/13.
 */
public class Apple_atIDBox extends AppleVariableSignedIntegerBox {
    public Apple_atIDBox() {
        super("atID");
    }
}


text:
namespace attribution_reporting {
class SuitableOrigin;
}  // namespace attribution_reporting

namespace base {
class TimeDelta;
class TimeTicks;
}  // namespace base

namespace content {

class AttributionManager;

// Manages a receiver set of all ongoing `AttributionDataHost`s and forwards
// events to the AttributionManager which owns `this`. Because attributionsrc
// requests may continue until after we have detached a frame, all browser
// process data needed to validate sources/triggers is frozen and stored
// alongside each receiver.
class CONTENT_EXPORT AttributionDataHostManagerImpl
    : public AttributionDataHostManager,
      public blink::mojom::AttributionDataHost {
 public:
  explicit AttributionDataHostManagerImpl(
      AttributionManager* attribution_manager);
  AttributionDataHostManagerImpl(const AttributionDataHostManager&) = delete;
  AttributionDataHostManagerImpl& operator=(
      const AttributionDataHostManagerImpl&) = delete;
  AttributionDataHostManagerImpl(AttributionDataHostManagerImpl&&) = delete;
  AttributionDataHostManagerImpl& operator=(AttributionDataHostManagerImpl&&) =
      delete;
  ~AttributionDataHostManagerImpl() override;

  // AttributionDataHostManager:
  void RegisterDataHost(
      mojo::PendingReceiver<blink::mojom::AttributionDataHost> data_host,
      attribution_reporting::SuitableOrigin context_origin,
      bool is_within_fenced_frame) override;
  bool RegisterNavigationDataHost(
      mojo::PendingReceiver<blink::mojom::AttributionDataHost> data_host,
      const blink::AttributionSrcToken& attribution_src_token,
      AttributionInputEvent input_event,
      blink::mojom::AttributionNavigationType nav_type) override;
  void NotifyNavigationRedirectRegistration(
      const blink::AttributionSrcToken& attribution_src_token,
      std::string header_value,
      attribution_reporting::SuitableOrigin reporting_origin,
      const attribution_reporting::SuitableOrigin& source_origin,
      AttributionInputEvent input_event,
      blink::mojom::AttributionNavigationType nav_type) override;
  void NotifyNavigationForDataHost(
      const blink::AttributionSrcToken& attribution_src_token,
      const attribution_reporting::SuitableOrigin& source_origin,
      blink::mojom::AttributionNavigationType nav_type) override;
  void NotifyNavigationFailure(
      const blink::AttributionSrcToken& attribution_src_token) override;

 private:
  // Represents frozen data from the browser process associated with each
  // receiver.
  struct FrozenContext;
  struct DelayedTrigger;
  struct NavigationDataHost;

  // Represents a set of attribution sources which registered in a top-level
  // navigation redirect chain, and associated info to process them.
  struct NavigationRedirectSourceRegistrations;

  // blink::mojom::AttributionDataHost:
  void SourceDataAvailable(
      blink::mojom::AttributionSourceDataPtr data) override;
  void TriggerDataAvailable(
      blink::mojom::AttributionTriggerDataPtr data) override;

  void OnReceiverDisconnected();
  void OnSourceEligibleDataHostFinished(base::TimeTicks register_time);

  void OnRedirectSourceParsed(
      const blink::AttributionSrcToken& attribution_src_token,
      attribution_reporting::SuitableOrigin reporting_origin,
      std::string header_value,
      blink::mojom::AttributionNavigationType nav_type,
      data_decoder::DataDecoder::ValueOrError result);

  void SetTriggerTimer(base::TimeDelta delay);
  void ProcessDelayedTrigger();

  // Owns `this`.
  raw_ptr<AttributionManager> attribution_manager_;

  mojo::ReceiverSet<blink::mojom::AttributionDataHost, FrozenContext>
      receivers_;

  // Map which stores pending receivers for data hosts which are going to
  // register sources associated with a navigation. These are not added to
  // `receivers_` until the necessary browser process information is available
  // to validate the attribution sources which is after the navigation finishes.
  base::flat_map<blink::AttributionSrcToken, NavigationDataHost>
      navigation_data_host_map_;

  // Stores registrations received for redirects within a navigation with a
  // given token.
  base::flat_map<blink::AttributionSrcToken,
                 NavigationRedirectSourceRegistrations>
      redirect_registrations_;

  // The number of connected receivers that may register a source. Used to
  // determine whether to buffer triggers. Event receivers are counted here
  // until they register a trigger.
  size_t data_hosts_in_source_mode_ = 0;
  base::OneShotTimer trigger_timer_;
  base::circular_deque<DelayedTrigger> delayed_triggers_;

  base::WeakPtrFactory<AttributionDataHostManagerImpl> weak_factory_{this};
};

}  // namespace content

#endif  // CONTENT_BROWSER_ATTRIBUTION_REPORTING_ATTRIBUTION_DATA_HOST_MANAGER_IMPL_H_


text:
Simple Feedback library, forked from [fladdict/AAMFeedback](https://github.com/fladdict/AAMFeedback "fladdict/AAMFeedback").

![screenshot](http://f.cl.ly/items/291A0A2u0R2B3u3V0b3H/screenshot.png)

## Installation

	pod 'AAMFeedback', :git => 'https://github.com/PlusR/AAMFeedback.git'

## Usage

See Example

``` objc
AAMFeedbackViewController *feedbackViewController = [[AAMFeedbackViewController alloc] init];
feedbackViewController.toRecipients = @[@"YOUR_CONTACT@email.com"];
feedbackViewController.ccRecipients = nil;
feedbackViewController.bccRecipients = nil;
UINavigationController *feedbackNavigation = [[UINavigationController alloc] initWithRootViewController:feedbackViewController];
[self presentViewController:feedbackNavigation animated:YES completion:nil];
```

AAMFeedbackViewController is a UITableViewController Subclass.
You can use setting `AAMFeedbackViewController` to the view controller's custom class in storyboard.

For details, See ``FeedbackTableViewController`` of Example.

### Custom Localization

When using AAMFeedback via CocoaPods, you should following setting to custom localization.

```objc
[AAMFeedbackViewController setAlwaysUseMainBundle:YES];
```

You'll need to manually create/copy AAMLocalizable.strings to your project.

Example project:

* [PlusR/AAMFeedbackLocalizeExample](https://github.com/PlusR/AAMFeedbackLocalizeExample "PlusR/AAMFeedbackLocalizeExample")

Thanks [Move lproj directories to Appirater.bundle when using CocoaPods by eager · Pull Request #129 · arashpayan/appirater](https://github.com/arashpayan/appirater/pull/129 "Move lproj directories to Appirater.bundle when using CocoaPods by eager · Pull Request #129 · arashpayan/appirater").

## Difference from original [fladdict/AAMFeedback](https://github.com/fladdict/AAMFeedback "fladdict/AAMFeedback")

* **ARC** ed.
* Device information is defined by the use of [squarefrog/UIDeviceIdentifier](https://github.com/squarefrog/UIDeviceIdentifier "squarefrog/UIDeviceIdentifier").
* Custom BackgroundImage/Topics/Localized.string
* Added spanish locale.(thanks @ericertl)

## Contributing

1. Fork it!
2. Create your feature branch: `git checkout -b my-new-feature`
3. Commit your changes: `git commit -am 'Add some feature'`
4. Push to the branch: `git push origin my-new-feature`
5. Submit a pull request :D

## License

New BSD License