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">
	<modelVersion>4.0.0</modelVersion>

	<groupId>com.noah</groupId>
	<artifactId>cms</artifactId>
	<version>0.0.5-SNAPSHOT</version>
	<packaging>jar</packaging>

	<name>cms</name>
	<description>Clinic Management System</description>

	<scm>
		<url>https://github.com/inoah1/cms</url>
		<connection>scm:git:https://github.com/inoah1/cms.git</connection>
		<developerConnection>scm:git:git@github.com:inoah1/cms.git</developerConnection>
		<tag>HEAD</tag>
	</scm>

	<licenses>
		<license>
			<name>MIT License</name>
			<url>http://www.opensource.org/licenses/mit-license.php</url>
			<distribution>repo</distribution>
		</license>
	</licenses>

	<parent>
		<groupId>org.springframework.boot</groupId>
		<artifactId>spring-boot-starter-parent</artifactId>
		<version>1.5.6.RELEASE</version>
		<relativePath /> <!-- lookup parent from repository -->
	</parent>

	<properties>
		<maven.build.timestamp.format>yyyy-MM-dd HH:mm</maven.build.timestamp.format>
		<build.timestamp>${maven.build.timestamp}</build.timestamp>
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
		<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
		<java.version>1.8</java.version>
		<vaadin.version>8.1.0</vaadin.version>
		<guava.version>21.0</guava.version>
		<productionMode>false</productionMode>
	</properties>

	<dependencies>
		<!-- Spring boot JPA -->
		<dependency>
			<groupId>org.springframework.boot</groupId>
			<artifactId>spring-boot-starter-data-jpa</artifactId>
		</dependency>
		<!-- Spring boot Vaadin -->
		<dependency>
			<groupId>com.vaadin</groupId>
			<artifactId>vaadin-spring-boot-starter</artifactId>
		</dependency>
		<!-- Spring boot Devtools -->
		<dependency>
			<groupId>org.springframework.boot</groupId>
			<artifactId>spring-boot-devtools</artifactId>
			<scope>runtime</scope>
		</dependency>
		<!-- H2 database -->
		<dependency>
			<groupId>com.h2database</groupId>
			<artifactId>h2</artifactId>
			<scope>runtime</scope>
		</dependency>
		<!-- Spring boot testing -->
		<dependency>
			<groupId>org.springframework.boot</groupId>
			<artifactId>spring-boot-starter-test</artifactId>
			<scope>test</scope>
		</dependency>
		<!-- Apache commons -->
        <dependency>
            <groupId>org.apache.commons</groupId>
            <artifactId>commons-lang3</artifactId>
            <version>3.5</version>
        </dependency>
        <!-- Guava -->
        <dependency>
            <groupId>com.google.guava</groupId>
            <artifactId>guava</artifactId>
            <version>${guava.version}</version>
        </dependency>
        <!-- Jetbrains annotations for Nullable/NotNull -->
        <dependency>
            <groupId>org.jetbrains</groupId>
            <artifactId>annotations</artifactId>
            <version>13.0</version>
        </dependency>
        <!-- Jasypt simple encryption library -->
        <dependency>
            <groupId>org.jasypt</groupId>
            <artifactId>jasypt</artifactId>
            <version>1.9.2</version>
        </dependency>
        <!-- Vaadin push support -->
        <dependency>
            <groupId>com.vaadin</groupId>
            <artifactId>vaadin-push</artifactId>
        </dependency>
        <!-- Viritin a.k.a. Vaadin commons -->
        <dependency>
            <groupId>org.vaadin</groupId>
            <artifactId>viritin</artifactId>
            <version>2.0.beta2</version>
        </dependency>
        <!-- Spring boot Bitronix JTA -->
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-jta-bitronix</artifactId>
        </dependency>
	</dependencies>

	<dependencyManagement>
		<dependencies>
			<dependency>
				<groupId>com.vaadin</groupId>
				<artifactId>vaadin-bom</artifactId>
				<version>${vaadin.version}</version>
				<type>pom</type>
				<scope>import</scope>
			</dependency>
		</dependencies>
	</dependencyManagement>

	<build>
		<resources>
			<resource>
				<directory>src/main/resources</directory>
				<filtering>true</filtering>
			</resource>
			<resource>
				<directory>src/main/webapp</directory>
			</resource>
		</resources>

		<plugins>
			<!-- Set maven compiler level -->
			<plugin>
				<artifactId>maven-compiler-plugin</artifactId>
				<configuration>
					<source>1.8</source>
					<target>1.8</target>
				</configuration>
			</plugin>
			<!-- Clean VAADIN widgetsets -->
			<plugin>
				<artifactId>maven-clean-plugin</artifactId>
				<configuration>
					<filesets>
						<fileset>
							<directory>src/main/webapp/VAADIN/widgetsets</directory>
						</fileset>
						<fileset>
							<directory>src/main/webapp/VAADIN/gwt-unitCache</directory>
						</fileset>
					</filesets>
				</configuration>
			</plugin>
			<!-- Vaadin plugin -->
            <plugin>
                <groupId>com.vaadin</groupId>
                <artifactId>vaadin-maven-plugin</artifactId>
                <version>${vaadin.version}</version>
                <configuration>
                	<extraJvmArgs>-Xmx1G -Xss1024k</extraJvmArgs>
					<webappDirectory>${basedir}/src/main/webapp/VAADIN/widgetsets</webappDirectory>
					<hostedWebapp>${basedir}/src/main/webapp/VAADIN/widgetsets</hostedWebapp>
					<noServer>true</noServer>
					<draftCompile>false</draftCompile>
					<style>OBF</style>
					<compileReport>true</compileReport>
					<runTarget>http://localhost:8080/</runTarget>
                    <modules>
                        <module>AppWidgetset</module>
                    </modules>
                </configuration>
                <executions>
                    <execution>
                        <goals>
                            <goal>resources</goal>
                            <goal>update-theme</goal>
                            <goal>update-widgetset</goal>
                            <goal>compile-theme</goal>
                            <goal>compile</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
			<!-- Spring boot plugin -->
			<plugin>
				<groupId>org.springframework.boot</groupId>
				<artifactId>spring-boot-maven-plugin</artifactId>
			</plugin>
			<!-- Generate build number -->
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>buildnumber-maven-plugin</artifactId>
                <version>1.4</version>
                <executions>
                    <execution>
                        <id>generate-buildnumber</id>
                        <phase>validate</phase>
                        <goals>
                            <goal>create</goal>
                        </goals>
                        <configuration>
                            <doCheck>false</doCheck>
                            <doUpdate>false</doUpdate>
                            <getRevisionOnlyOnce>false</getRevisionOnlyOnce>
                            <buildNumberPropertyName>build.revision</buildNumberPropertyName>
                            <revisionOnScmFailure>UNKNOWN</revisionOnScmFailure>
                            <shortRevisionLength>7</shortRevisionLength>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <!-- Filter resources -->
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-resources-plugin</artifactId>
                <configuration>
                    <nonFilteredFileExtensions>
                        <nonFilteredFileExtension>ttf</nonFilteredFileExtension>
                        <nonFilteredFileExtension>woff</nonFilteredFileExtension>
                        <nonFilteredFileExtension>woff2</nonFilteredFileExtension>
                    </nonFilteredFileExtensions>
                </configuration>
            </plugin>
		</plugins>
	</build>

	<repositories>
        <repository>
            <id>vaadin-addons</id>
            <url>http://vaadin.com/nexus/content/repositories/vaadin-addons/</url>
        </repository>
    </repositories>

</project>


text:
namespace ash {

// TODO(jdufault): Remove Network prefix from NetworkError associated classes.
// See crbug.com/672142
class NetworkError {
 public:
  enum UIState {
    UI_STATE_UNKNOWN = 0,
    UI_STATE_UPDATE,
    UI_STATE_SIGNIN,
    UI_STATE_SUPERVISED,
    UI_STATE_KIOSK_MODE,
    UI_STATE_LOCAL_STATE_ERROR,
    UI_STATE_AUTO_ENROLLMENT_ERROR,
    UI_STATE_ROLLBACK_ERROR,
  };

  enum ErrorState {
    ERROR_STATE_UNKNOWN = 0,
    ERROR_STATE_PORTAL,
    ERROR_STATE_OFFLINE,
    ERROR_STATE_PROXY,
    ERROR_STATE_AUTH_EXT_TIMEOUT,
    ERROR_STATE_NONE,
    // States above are being logged to histograms.
    // Please keep ERROR_STATE_NONE as the last one of the histogram values.
    // ERROR_STATE_KIOSK_ONLINE is a special case (not an actual error) and is
    // not reported in histogram.
    ERROR_STATE_KIOSK_ONLINE,
  };

  // Possible network error reasons.
  enum ErrorReason {
    ERROR_REASON_PROXY_AUTH_CANCELLED = 0,
    ERROR_REASON_PROXY_AUTH_SUPPLIED = 1,
    ERROR_REASON_PROXY_CONNECTION_FAILED = 2,
    ERROR_REASON_PROXY_CONFIG_CHANGED = 3,
    ERROR_REASON_LOADING_TIMEOUT = 4,
    ERROR_REASON_PORTAL_DETECTED = 5,

    // Reason for a case when default network has changed.
    ERROR_REASON_NETWORK_STATE_CHANGED = 6,

    // Reason for a case when JS side requires error screen update.
    ERROR_REASON_UPDATE = 7,
    ERROR_REASON_FRAME_ERROR = 8,

    // Used as an "uninitialized" state for cases when limiting number of
    // GAIA reloads due to a single network error reason.
    ERROR_REASON_NONE = 9
  };

  static const char* ErrorReasonString(ErrorReason reason);
};

}  // namespace ash

// TODO(https://crbug.com/1164001): remove after the //chrome/browser/chromeos
// source migration is finished.
namespace chromeos {
using ::ash::NetworkError;
}

#endif  // CHROME_BROWSER_ASH_LOGIN_SCREENS_NETWORK_ERROR_H_

redpajama_set_name: RedPajamaGithub


text:
#ifndef __FORK_COMMON_IMAGE_READER_H__
#define __FORK_COMMON_IMAGE_READER_H__

#include "Video/FileHandler/ImageReader.h"

namespace Fork
{

namespace Video
{

class CommonImageReader : public ImageReader
{

    public:

        ImageUBytePtr ReadImage(const std::string& filename);
        ImageFloatPtr ReadImageHDR(const std::string& filename, float gamma = 2.2f, float scale = 1.0f);

};

} // /namespace Video

} // /namespace Fork

#endif

// ========================


text:
/*global require: false, module: false */
"use strict";

var mod = function(
  _,
  Promise,
  Logger,
  Options,
  StateGuard,
  Runtime,
  ProcessKeepAlive
) {
  var Log = Logger.create("App");

  var App = function() {
    this.initialize.apply(this, arguments);
  };

  _.extend(App.prototype, {
    initialize: function(opts) {
      opts = Options.fromObject(opts);
      this._guard = new StateGuard(["starting", "started", "stopping", "stopped"]);
      this._rawConfig = opts.getOrError("configuration");
      this._config = Options.fromObject(this._rawConfig);

      // The default Runtime has sensible defaults.
      this._runtime = opts.getOrElseFn("runtime", function() {
        return new Runtime();
      });

      this._keepAlive = new ProcessKeepAlive({
        scheduler: this._runtime.scheduler()
      });

      var up   = opts.getOrElse("up"),
          down = opts.getOrElse("down");

      if (up) {
        this.up = Promise.method(_.bind(function() {
          return up.call(this, this._config);
        }, this));
      }

      if (down) {
        this.down = Promise.method(_.bind(function() {
          return down.call(this, this._config);
        }, this));
      }

    },

    start: Promise.method(function() {
      Log.debug("Starting App");
      this._guard
        .deny("starting")
        .apply("starting");

      this._keepAlive.start();
      Log.debug("Calling App#up()");

      return this.up()
        .then(this._guard.applyAsyncFn("started"));
    }),

    stop: Promise.method(function() {
      Log.debug("Stopping App");
      this._guard
        .deny("stopping")
        .apply("stopping");

      this._keepAlive.stop();
      Log.debug("Calling App#down()");

      return this.down()
        .then(this._guard.applyAsyncFn("stopped"));
    }),

    /**
     * Returns the requested configuration value, or throws an error.
     * @param key the configuration key request from the Configuration.
     * @returns {Object}
     */
    config: function(key) {
      return this._config.getOrError(key);
    },

    /**
     * TODO: Doc. Subclass should override.
     */
    up: Promise.method(function() {}),

    /**
     * TODO: Doc. Subclass should override.
     */
    down: Promise.method(function() {})
  });

  return App;
};

module.exports = mod(
  require("underscore"),
  require("bluebird"),
  require("../core/logging/logger"),
  require("../core/options"),
  require("../core/state-guard"),
  require("../runtime"),
  require("./internal/process-keep-alive")
);


text:
const {createDropColumnMigration} = require('../../utils');

// Preferably I could use `createIrreversibleMigration` here like
// `createIrreversibleMigration(createDropColumnMigration(...).up)` but
// that seems to throw some obscure error that I'm not sure about... something
// to look into for the future
module.exports = {
    ...createDropColumnMigration('webhooks', 'status', {}),

    down: async () => {
        // no-op: we're setting this migration to irreversible so we won't
        // execute the `down`
    },

    config: {
        irreversible: true
    }
};


text:
<?php

namespace app\controllers;

use Yii;
use yii\filters\auth\HttpBearerAuth;
use app\models\Omapuser;
use yii\filters\AccessControl;

class OmapuserController extends \yii\rest\ActiveController
{
    public $modelClass = 'app\models\Omapuser';

    public function actions()
    {
        $actions = parent::actions();
        $actions['create']['scenario'] = 'create';
        $actions['update']['scenario'] = 'update';

        return $actions;
    }

    public function behaviors()
    {
        $behaviors = parent::behaviors();
        $behaviors['authenticator'] = [
            'class' => HttpBearerAuth::className(),
            'except' => ['create', 'login', 'resetpassword'],
        ];
        /*$behaviors['access'] = [
            'class' => AccessControl::className(),
            'rules' => [
                [
                    'allow' => true,
                    'actions' => [
                        'options','login'
                    ],
                ],
                [
                    'allow' => true,
                    'roles' => [
                        'admin',
                    ],
                ],
            ],
        ];*/
        return $behaviors;
    }

    public function actionLogin()
    {
        $post = Yii::$app->request->post();
        $model = Omapuser::findOne(["email" => $post["email"]]);
        if (empty($model)) {
            return 'not_username';
        }
        if ($model->validatePassword($post["password"])) {
            $model->last_login = Yii::$app->formatter->asTimestamp(date_create());
            $model->updateCounters(['logins' => 1]);
            $model->save(false);
            return $model; //return whole user model including auth_key or you can just return $model["auth_key"];
        } else {
            return "not_password";
        }
    }
}


text:
exports.in = function(req, res, next) {

}


text:
/**
 * Classes for reading and writing glTF data, for glTF 1.0.

 *

 * In most cases, these classes should not directly be used by clients.
 */
package de.javagl.jgltf.model.io.v1;


text:
Adjunct is a set of convenience modules and mixins most of which are intended for use with Dojo, Dijit, and dgrid.  More thorough documentation of module/mixin use is coming.

# Dependencies

* Dojo
* Dijit
* dgrid
* xstyle
* knockoutjs

# Examples

## adjunct/store/Monitorable

require([
	"dojo/store/Memory",
	"adjunct/store/Monitorable"
], function (Memory, Monitorable) {
	var store = new Monitorable(new Memory({
		data: [{id: "foo", name: "Foo"}, {id: "bar", name: "Bar"}, {id: "baz", name: "Baz"}]
	}));

	store.monitor("name", function (oldValue, newValue) {
		console.log("name changed from", oldValue, "to", newValue);
	});

	var old = store.get("foo");
	old.name = "Qux";
	store.put(old);
});

## adjunct/widget/ToggleSwitch

<input type="checkbox" id="toggleSwitch" /> Foo

require([
	"adjunct/widget/form/ToggleSwitch"
], function (ToggleSwitch) {
	var toggleSwitch = new ToggleSwitch({}, "toggleSwitch");

	toggleSwitch.startup();

	toggleSwitch.on("click'", function (event) {
		console.log("Clicked!", event);
	});
});

## adjunct/widget/form/MultiItem

<div id="items"></div>

require([
	"dojo/_base/declare",
	"adjunct/widget/form/_TemplatedMixin",
	"adjunct/widget/form/MultiItem"
], function (declare, _TemplatedMixin, MultiItem) {
	var TestItem = declare(_TemplatedMixin, {
		templateString: "<div><input type='text' data-dojo-attach-point='inputNode' /></div>",
		_setValueAttr: function (value) {
			this.inputNode.value = value.value;
		},
		_setDisabledAttr: function (disabled) {
			if (this.disabled === disabled) {
				return;
			}

			this.inputNode[disabled ? "setAttribute" : "removeAttribute"]("disabled", disabled);
			this._set("disabled", disabled);
		},
		_setReadonlyAttr: function (readonly) {
			if (this.readonly === readonly) {
				return;
			}

			this.inputNode[readonly ? "setAttribute" : "removeAttribute"]("readonly", readonly);
			this._set("readonly", readonly);
		}
	});

	window.items = new MultiItem({
		itemClass: TestItem,
		addItemMessage: "Add New Test Item"
	}, "items");

	items.startup();

	items.set("value", [{
		value: "testing"
	}]);
});

## adjunct/widget/pausable

Currently <span id="state">Unpaused</span>
<button type="button" id="toggleButton">Toggle</button>

require([
	"dojo/on",
	"dijit/form/Button",
	"adjunct/widget/pauseable",
], function (on, Button, pausable) {
	var button = new Button({
		label: "Pasuable"
	});

	var handle = button.on(pausable("click"), function() {
		console.log("Button was clicked");
	});

	var state = document.getElementById("state");

	button.placeAt(document.body);

	on(document.getElementById("toggleButton"), "click", function () {
		if (handle.isPaused()) {
			handle.resume();
			state.innerHTML = "Unpaused";
		} else {
			handle.pause();
			state.innerHTML = "Paused";
		}
	});
});

## adjunct/widget/_OwnMixin

require([
	"dojo/_base/declare",
	"dojo/on",
	"adjunct/widget/_OwnMixin"
], function (declare, on, _OwnMixin) {
	var Widget = declare(_OwnMixin, {
		on: function (type, listener) {
			var handle = on(this.domNode, type, listener);
			this.own(handle);
			return handle;
		}
	});

	var widget = new Widget();
	widget.on("click", function(){...});
});

## adjunct/widget/_BindingMixin

<div id="container"></div>

require([
	"dojo/_base/declare",
	"dijit/_WidgetBase",
	"dijit/_TemplatedMixin",
	"adjunct/widget/_BindingMixin"
], function (declare, _WidgetBase, _TemplatedMixin, _BindingMixin) {
	var Widget = declare([_WidgetBase, _TemplatedMixin, _BindingMixin], {
		templateString: "
: <input type='text' data-bind='value: name' />

Unbound

",
		nameLabel: "Enter your name",
		name: "Matthew Maxwell"
	});

	window.widget = new Widget({}, "container");
	widget.startup();

	setTimeout(function () {
		widget.set("name", "Changed name");
	}, 3000);
});

## adjunct/grid/filtration/List

<div id="list"></div>

require([
	"adjunct/grid/filtration/List",
	"adjunct/grid/filtration/filters/TextBox",
	"dgrid/test/data/base"
], function (List, TextBox) {
	var list = new List({
		filterProperties: ["col1", "col3"],
		filterer: new TextBox({
			label: "Filter"
		}),
		renderRow: function (object) {
			var row = document.createElement("div");

			row.innerHTML = object.col1 + " - " + object.col3;

			return row;
		}
	}, "list");

	list.renderArray(data_list);
});

## adjunct/grid/filtration/OnDemandList

<div id="list"></div>

require([
	"adjunct/grid/filtration/OnDemandList",
	"adjunct/grid/filtration/filters/TextBox",
	"dgrid/test/data/base"
], function (OnDemandList, TextBox) {
	var list = new OnDemandList({
		store: testStore,
		filterProperties: ["col1", "col3"],
		filterer: new TextBox({
			label: "Filter"
		}),
		renderRow: function (object) {
			var row = document.createElement("div");

			row.innerHTML = object.col1 + " - " + object.col3;

			return row;
		}
	}, "list");
});

## adjunct/grid/filtration/Grid

<div id="grid"></div>

require([
	"adjunct/grid/filtration/Grid",
	"adjunct/grid/filtration/filters/TextBox",
	"dgrid/test/data/base"
], function (Grid, TextBox) {
	var grid = new Grid({
		columns: [
			new TextBox({
				label: "Column 1",
				field: "col1"
			}),
			new TextBox({
				label: "Column 3",
				field: "col3"
			})
		]
	}, "grid");

	grid.renderArray(data_list);
});

## adjunct/grid/filtration/OnDemandGrid

<div id="grid"></div>

require([
	"adjunct/grid/filtration/OnDemandGrid",
	"adjunct/grid/filtration/filters/TextBox",
	"dgrid/test/data/base"
], function (OnDemandGrid, TextBox) {
	var grid = new OnDemandGrid({
		store: testStore,
		columns: [
			new TextBox({
				label: "Column 1",
				field: "col1"
			}),
			new TextBox({
				label: "Column 3",
				field: "col3"
			})
		]
	}, "grid");
});


text:
// ----------------------------------------------------------------------------------
//
// Copyright Microsoft Corporation
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
// http://www.apache.org/licenses/LICENSE-2.0
// Unless required by applicable law or 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.
// ----------------------------------------------------------------------------------

using System.Collections.Generic;
using Microsoft.VisualStudio.TestTools.UnitTesting;

namespace Microsoft.WindowsAzure.Commands.ScenarioTest.WAPackIaaS.FunctionalTest
{
    [TestClass]
    public class GetWAPackVMRoleTests : CmdletTestCloudServiceBase
    {
        [TestInitialize]
        public void TestInitialize()
        {
            // Remove any existing VMRoles/CloudService
            this.VMRolePreTestCleanup();
            this.CloudServicePreTestCleanup();

            // Create a QuickCreateVMRole
            this.CreateVMRoleFromQuickCreate();
        }

        [TestMethod]
        [TestCategory("WAPackIaaS-All")]
        [TestCategory("WAPackIaaS-Functional")]
        [TestCategory("WAPackIaaS-CloudService")]
        public void GetWAPackVMRolesWithNoParam()
        {
            var allVMRoles = this.InvokeCmdlet(Cmdlets.GetWAPackVMRole, null);
            Assert.IsTrue(allVMRoles.Count > 0);
        }

        [TestMethod]
        [TestCategory("WAPackIaaS-All")]
        [TestCategory("WAPackIaaS-Functional")]
        [TestCategory("WAPackIaaS-CloudService")]
        public void GetWAPackVMRoleFromName()
        {
            var inputParams = new Dictionary<string, object>()
            {
                {"Name", vmRoleNameFromQuickCreate}
            };
            var vmRole = this.InvokeCmdlet(Cmdlets.GetWAPackVMRole, inputParams);
            Assert.AreEqual(1, vmRole.Count, string.Format("{0} VMRole Found, {1} VMRole Was Expected.", vmRole.Count, 1));
        }

        [TestMethod]
        [TestCategory("WAPackIaaS-All")]
        [TestCategory("WAPackIaaS-Functional")]
        [TestCategory("WAPackIaaS-CloudService")]
        public void GetWAPackVMRoleWithSameCloudServiceAndVMRoleNames()
        {
            var inputParams = new Dictionary<string, object>()
            {
                {"Name", vmRoleNameFromQuickCreate},
                {"CloudServiceName", vmRoleNameFromQuickCreate}
            };
            var vmRole = this.InvokeCmdlet(Cmdlets.GetWAPackVMRole, inputParams);
            Assert.AreEqual(1, vmRole.Count, string.Format("{0} VMRole Found, {1} VMRole Was Expected.", vmRole.Count, 1));
        }

        [TestMethod]
        [TestCategory("WAPackIaaS-All")]
        [TestCategory("WAPackIaaS-Negative")]
        [TestCategory("WAPackIaaS-Functional")]
        [TestCategory("WAPackIaaS-CloudService")]
        public void GetWAPackVMRoleFromNameDoesNotExist()
        {
            string expectedVMRoleName = "WAPackVMRoleDoesNotExist";
            var inputParams = new Dictionary<string, object>()
            {
                {"Name", expectedVMRoleName},
            };
            var vmRole = this.InvokeCmdlet(Cmdlets.GetWAPackVMRole, inputParams, nonExistantResourceExceptionMessage);
            Assert.AreEqual(0, vmRole.Count);
        }

        [TestMethod]
        [TestCategory("WAPackIaaS-All")]
        [TestCategory("WAPackIaaS-Negative")]
        [TestCategory("WAPackIaaS-Functional")]
        [TestCategory("WAPackIaaS-CloudService")]
        public void GetWAPackVMRoleFromNonExistentCloudService()
        {
            string nonExistentCloudService = "WAPackVMRoleCloudServiceNameDoesNotExist";
            var inputParams = new Dictionary<string, object>()
            {
                {"Name", vmRoleNameFromQuickCreate},
                {"CloudServiceName", nonExistentCloudService}
            };
            var vmRole = this.InvokeCmdlet(Cmdlets.GetWAPackVMRole, inputParams, nonExistantResourceExceptionMessage);
            Assert.AreEqual(0, vmRole.Count);
        }

        [TestCleanup]
        public void VMRoleCleanup()
        {
            this.RemoveVMRoles();
            this.RemoveCloudServices();
        }
    }
}


text:
require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper')

describe "/campaigns/edit" do
  include CampaignsHelper

  before do
    login_and_assign
    assign(:campaign, @campaign = FactoryGirl.create(:campaign, :user => current_user))
    assign(:users, [ current_user ])
  end

  it "cancel from campaign index page: should replace [Edit Campaign] form with campaign partial" do
    params[:cancel] = "true"

    render
    rendered.should have_rjs("campaign_#{@campaign.id}") do |rjs|
      with_tag("li[id=campaign_#{@campaign.id}]")
    end
  end

  it "cancel from campaign landing page: should hide [Edit Campaign] form" do
    controller.request.env["HTTP_REFERER"] = "http://localhost/campaigns/123"
    params[:cancel] = "true"

    render
    rendered.should include('crm.flip_form("edit_campaign"')
  end

  it "edit: should hide previously open [Edit Campaign] for and replace it with campaign partial" do
    params[:cancel] = nil
    assign(:previous, previous = FactoryGirl.create(:campaign, :user => current_user))

    render
    rendered.should have_rjs("campaign_#{previous.id}") do |rjs|
      with_tag("li[id=campaign_#{previous.id}]")
    end
  end

  it "edit: should remove previously open [Edit Campaign] if it's no longer available" do
    params[:cancel] = nil
    assign(:previous, previous = 41)

    render
    rendered.should include(%Q/crm.flick("campaign_#{previous}", "remove");/)
  end

  it "edit from campaigns index page: should turn off highlight, hide [Create Campaign], and replace current campaign with [Edit Campaign] form" do
    params[:cancel] = nil

    render
    rendered.should include(%Q/crm.highlight_off("campaign_#{@campaign.id}");/)
    rendered.should include('crm.hide_form("create_campaign")')
    rendered.should have_rjs("campaign_#{@campaign.id}") do |rjs|
      with_tag("form[class=edit_campaign]")
    end
  end

  it "edit from campaign landing page: should show [Edit Campaign] form" do
    params[:cancel] = "false"

    render
    rendered.should have_rjs("edit_campaign") do |rjs|
      with_tag("form[class=edit_campaign]")
    end
    rendered.should include('crm.flip_form("edit_campaign"')
  end

  it "should call JavaScript to set up popup Calendar" do
    params[:cancel] = nil

    render
    rendered.should include('$("campaign_name").focus()')
  end

end


text:
using Umbraco.Core.Models;

namespace Articulate.Models
{
    public interface IMasterModel : IPublishedContent
    {
        /// <summary>
        /// Returns the current theme
        /// </summary>
        string Theme { get; }
        IPublishedContent RootBlogNode { get; }
        IPublishedContent BlogArchiveNode { get; }
        string BlogTitle { get; }
        string BlogDescription { get; }
        string BlogLogo { get; }
        string BlogBanner { get; }
        int PageSize { get; }
        string DisqusShortName { get; }
        string CustomRssFeed { get; }

    }
}


text:
from enum import Enum

class ActionSpace(Enum):
  Null = 0
  Continuous = 1
  Discrete = 2


text:
Python torque submitter
-----------------------

This is as very simple hackish hack, that allows you to any serializable
python callable as a torque job.

Features:

* Allows you to send enviorment on the other side
* Allows to execute any callable function as a torque task
* Allows you to launch a bunch of taska as a torque array job.

Dependencies:

* Working python 2.7/3.4 enviorment
* Some python dependencies (see ``REQUIREMENTS``)
* Working ``qsub`` command (no need for other PBS/torque stuff).

Works by serializing the enviorment and callable function to the
enviorment variables (or enviorment variables and files).
For serialization we use ``dill`` if avilable or ``pickle``.

Enviorment can be initialized using arbirtary bash script --- this script
will be sourced before running provided python callable.

Example
=======

Example without enviorment:

.. code-block:: python

     callable = partial(print, "Hello World!")

    from torqsubmit import Submitter

    s = Submitter()
    s.tasks = [callable]
    s.submit()

Example with enviorment:

.. code-block:: python

    callable = partial(print, "Hello World!")

    from torqsubmit._submit import Submitter

    ENV = """
    source ${HOME}/.bashrc
    workon torque-submit
    export MSG="Hello World!"
    """

    def print_from_env():
        import os
        print(os.environ["MSG"])

    s = Submitter()
    s.tasks = [callable]
    s.enviorment = ENV
    s.submit()

Example submitting many tasks:

.. code-block:: python

    from __future__ import print_function
    from functools import partial

    callable = partial(print, "Hello World!")

    from torqsubmit._submit import Submitter

    ENV = """
    source ${HOME}/.bashrc
    workon torque-submit
    export MSG="Hello World!"
    """

    def print_from_env():
        import os
        print(os.environ["MSG"])

    s = Submitter()
    s.enviorment = ENV
    s.tasks = [print_from_env, print_from_env]
    s.submit()


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

namespace Loggor.Lib
{
    public class ShortLive
    {

        public class ShortLiveData
        {
            private readonly ILogWriter LogWriter = null;

            private readonly int startEventId;
            private readonly int stopEventId;
            private readonly string startMessage = string.Empty;
            private readonly string stopMessage = string.Empty;
            private readonly string title = string.Empty;
            private readonly DateTime StartTime;
            private DateTime StopTime;
            private readonly object[] args;

            public ShortLiveData(ILogWriter logWriter, int startEventId, int stopEventId, string startMessage, string stopMessage, string title, params object[] args)
            {
                this.LogWriter = logWriter;
                this.startEventId = startEventId;
                this.stopEventId = stopEventId;
                this.startMessage = startMessage;
                this.stopMessage = stopMessage;
                this.StartTime = DateTime.Now;
                this.args = args;
            }

            internal void Start()
            {
                var message = startMessage;

                switch (args == null ? 0 : Math.Min(6, args.Length))
                {
                    case 0:
                        message = string.Format(startMessage, this.StartTime);
                        break;
                    case 1:
                        message = string.Format(startMessage, args[0], this.StartTime);
                        break;
                    case 2:
                        message = string.Format(startMessage, args[0], args[1], this.StartTime);
                        break;
                    case 3:
                        message = string.Format(startMessage, args[0], args[1], args[2], this.StartTime);
                        break;
                    case 4:
                        message = string.Format(startMessage, args[0], args[1], args[2], args[3], this.StartTime);
                        break;
                    case 5:
                        message = string.Format(startMessage, args[0], args[1], args[2], args[3], args[4], this.StartTime);
                        break;
                    case 6:
                        message = string.Format(startMessage, args[0], args[1], args[2], args[3], args[4], args[5], this.StartTime);
                        break;
                }

                this.LogWriter.Log(this.startEventId, message, title, System.Diagnostics.TraceEventType.Information);
            }
            public void Stop()
            {
                this.StopTime = DateTime.Now;

                var e = this.StopTime - this.StartTime;

                var message = this.stopMessage;

                switch (args.Length)
                {
                    case 0:
                        message = string.Format(stopMessage, this.StartTime, this.StopTime, e.TotalSeconds);
                        break;
                    case 1:
                        message = string.Format(stopMessage, args[0], this.StartTime, this.StopTime, e.TotalSeconds);
                        break;
                    case 2:
                        message = string.Format(stopMessage, args[0], args[1], this.StartTime, this.StopTime, e.TotalSeconds);
                        break;
                    case 3:
                        message = string.Format(stopMessage, args[0], args[1], args[2], this.StartTime, this.StopTime, e.TotalSeconds);
                        break;
                    case 4:
                        message = string.Format(stopMessage, args[0], args[1], args[2], args[3], this.StartTime, this.StopTime, e.TotalSeconds);
                        break;
                    case 5:
                        message = string.Format(stopMessage, args[0], args[1], args[2], args[3], args[4], this.StartTime, this.StopTime, e.TotalSeconds);
                        break;
                    case 6:
                        message = string.Format(stopMessage, args[0], args[1], args[2], args[3], args[4], args[5], this.StartTime, this.StopTime, e.TotalSeconds);
                        break;
                }

                this.LogWriter.Log(this.stopEventId, message, this.title, System.Diagnostics.TraceEventType.Information);
            }
        }

        public void Execute(Action p)
        {
            var sld = Start();

            try
            {
                p();
            }
            catch (Exception)
            {
                throw;
            }
            finally
            {
                sld.Stop();
            }

        }

        public T Run<T>(Func<T> p)
        {
            T ret = default(T);

            var sld = Start();

            try
            {
                ret = p();
            }
            catch (Exception)
            {
                throw;
            }
            finally
            {
                sld.Stop();
            }

            return ret;

        }

        private readonly ShortLiveData _sld;

        public ShortLive(ILogWriter logWriter, int startEventId, string startMessage, int stopEventId, string stopMessage, string title, params object[] args)
        {
            _sld = new ShortLiveData(logWriter, startEventId, stopEventId, startMessage, stopMessage, title, args);
        }

        public ShortLiveData Start()
        {
            _sld.Start();
            return _sld;
        }
    }
}


text:
Javascript library for google's qpx express api.

WIP!!! Not yet usable, api will change!.

current working example:

```
const API_KEY = 'your key';
const q = qpx(API_KEY);
q.fields.passengers.adults(1);
q.fields.fare
  .from("LHR").to("CDG").on("2015-08-08")
  .after('18:00').before('23:59');
q.fields.price.amount(200);
q.fields.country.set('GB');
q.search();
```


text:
"""Used to operate on a sub-graph of a larger GO DAG."""

from collections import defaultdict

__copyright__ = "Copyright (C) 2016-2018, DV Klopfenstein, H Tang, All rights reserved."
__author__ = "DV Klopfenstein"

class GODagSmall(object):
    """Contains a sub-graph of the original obo from geneontology.org."""

    def __init__(self):
        # Sub-graph of input DAG. User has option of using a subset of children/parents
        self.go_sources = None
        self.go2obj = {}
        self.p_from_cs = defaultdict(set) # GO ids for child->parents
        self.c_from_ps = defaultdict(set) # GO ids for parent->children

    def num_goterms(self):
        """Return the number of GO terms in this GO DAG subgraph."""
        return len(self.go2obj)

    def get_edges(self):
        """Get the directed edges from GO term to GO term."""
        edge_from_to = []
        for parent, children in self.p_from_cs.items():
            for child in children:
                edge_from_to.append((child, parent))
        for parent, children in self.c_from_ps.items():
            for child in children:
                edge_from_to.append((child, parent))
        return edge_from_to

# Copyright (C) 2016-2018, DV Klopfenstein, H Tang, All rights reserved.


text:
@implementation TeaInputValidation
+ (BOOL) validateStringInput: (NSString *) input ofType: (TeaInputType) type {
    BOOL result = YES;
    AlertUtility * alert = [[AlertUtility alloc] init];

    switch (type) {
        case NUMBERIC_INPUT:
            if (![self isValidNumberString: input output: nil]) {
                [alert showAlertWithTitle: @"Could not recognize number" andMessage: @"Example: 2:34 for two minutes and thirty-four seconds."];

                NSLog(@"Invalid infusion time or format!");

                result = NO;
            }

            break;
        case INFUSION_TIME_INPUT:
            if (![self isValidInfusionTimeString: input]) {
                [alert showAlertWithTitle: @"Could not recognize number" andMessage: @"Example: 34 for thirty-four seconds."];

                NSLog(@"Invalid number format!");

                result = NO;
            }

            break;
        case TEXT_INPUT:

            break;
        default:
            break;
    }

    return result;
}

+ (BOOL) isValidInfusionTimeString: (NSString *) infusionTimeString {
    BOOL result = NO;

    const char * cStr = [infusionTimeString UTF8String];

    // String should not be longer than 4 characters (excluding the terminating null)
    if (infusionTimeString.length > TIME_CHAR_LIMIT) {
        return result;
    }

    // String is allowed one ':', '.', '-', to separate minute and seconds ex: 1-22, 1:22, 1.22
    int locatedIndex = INVALID;

    for (int i = 0; i < TIME_CHAR_LIMIT; i++) {
        if (cStr[i] == ':' || cStr[i] == '.' || cStr[i] == '-') {
            // These symbols must be exactly at index 1 eg: :000, 00.0, 000- are all invalid
            if (i != 1) {
                return result;
            }

            locatedIndex = i;
        }
    }

    // Seconds can overflow but not past 99. Highest time is 9.99

    // Check if an int is parsable. If locatedIndex is Valid, check both sides of the symbol
    if (locatedIndex != INVALID) {
        NSString * sub1 = [infusionTimeString substringToIndex: locatedIndex];
        NSString * sub2 = [infusionTimeString substringFromIndex: locatedIndex + 1];

        result = [self isInfusionStringTimeWithinLimits: sub1 andSeconds: sub2];
    } else {
        result = [self isInfusionStringTimeWithinLimits: nil andSeconds: infusionTimeString];
    }

    return result;
}

// In the case of 1:2s or any other character, the 's' will be ignored by default
// Before calling this function, make sure isValidInfusionTimeString is called first to weed out invalid formatting
+ (BOOL) isInfusionStringTimeWithinLimits: (NSString *) minutes andSeconds: (NSString *) seconds {
    BOOL result = NO;

    if (seconds == nil) {
        return result;
    }

    NSInteger min, sec;

    // check seconds string
    if (![self isValidNumberString: seconds output: &sec]) {
        return result;
    }

    if (sec >= MIN_SECONDS && sec <= MAX_SECONDS) {
        result = YES;
    }

    if (minutes != nil) {
        // merge both minutes and seconds and check the resutl against the min and max limites
        // check minutes string
        if (![self isValidNumberString: minutes output: &min]) {
            return result;
        }

        if (min >= MIN_MINUTES && min <= MAX_MINUTES) {
            result = YES;
        }

        // check the merged result of minutes and seconds
        if (min * 60 + sec <= MAX_SECONDS) {
            result = YES;
        }
    }

    return result;
}

// TODO: maybe check for non numberic characters
+ (BOOL) isValidNumberString: (NSString *) numberString output: (NSInteger *) outputInt {
    BOOL result = NO;

    NSScanner * scanner = [NSScanner scannerWithString: numberString];

    NSInteger num;

    if([scanner scanInt: &num]) {
        if ([self isValidNumber: num]) {
            result = YES;
        }
    }

    if (outputInt) {
        if (result)
            *outputInt = num;
        else
            *outputInt = NSNotFound;
    }

    return result;
}

+ (BOOL) isValidNumber: (NSInteger) number {
    BOOL result = NO;

    if (number >= 0) {
        result = YES;
    }

    return result;
}
@end


text:
<?php

namespace Radic\Foundation\Bootstrap;

use Illuminate\Contracts\Foundation\Application;

class RegisterProviders
{
    /**
     * Bootstrap the given application.
     *
     * @param  \Illuminate\Contracts\Foundation\Application  $app
     * @return void
     */
    public function bootstrap(Application $app)
    {
        $app->registerConfiguredProviders();
    }
}


text:
// Copyright (c) Petabridge <https://petabridge.com/>. All rights reserved.
// Licensed under the Apache 2.0 license. See LICENSE file in the project root for full license information.
// See ThirdPartyNotices.txt for references to third party code used inside Helios.

using System.Threading;

namespace Helios.Util
{
    /// <summary>
    ///     Implementation of the java.concurrent.util AtomicReference type.
    ///     Uses <see cref="Interlocked.MemoryBarrier" /> internally to enforce ordering of writes
    ///     without any explicit locking. .NET's strong memory on write guarantees might already enforce
    ///     this ordering, but the addition of the MemoryBarrier guarantees it.
    /// </summary>
    public class AtomicReference<T> where T : class
    {
        // ReSharper disable once InconsistentNaming
        protected T atomicValue;

        /// <summary>
        ///     Sets the initial value of this <see cref="AtomicReference{T}" /> to <see cref="originalValue" />.
        /// </summary>
        public AtomicReference(T originalValue)
        {
            atomicValue = originalValue;
        }

        /// <summary>
        ///     Default constructor
        /// </summary>
        public AtomicReference()
        {
            atomicValue = default(T);
        }

        /// <summary>
        ///     The current value of this <see cref="AtomicReference{T}" />
        /// </summary>
        public T Value
        {
            get { return Volatile.Read(ref atomicValue); }
            set { Volatile.Write(ref atomicValue, value); }
        }

        #region Conversion operators

        /// <summary>
        ///     Implicit conversion operator = automatically casts the <see cref="AtomicReference{T}" /> to an instance of
        ///     <typeparam name="T"></typeparam>
        /// </summary>
        public static implicit operator T(AtomicReference<T> aRef)
        {
            return aRef.Value;
        }

        /// <summary>
        ///     Implicit conversion operator = allows us to cast any type directly into a <see cref="AtomicReference{T}" />
        ///     instance.
        /// </summary>
        /// <param name="newValue"></param>
        /// <returns></returns>
        public static implicit operator AtomicReference<T>(T newValue)
        {
            return new AtomicReference<T>(newValue);
        }

        #endregion
    }
}


text:
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="fill_parent">

    <ListView android:id="@android:id/list"
    android:layout_width="fill_parent"
    android:layout_height="fill_parent"
   	android:clickable="false"

    />

</LinearLayout>


text:
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.

using System;
using System.Threading;

namespace Microsoft.CodeAnalysis.SolutionCrawler
{
    internal partial class SolutionCrawlerRegistrationService : ISolutionCrawlerRegistrationService
    {
        /// <summary>
        /// Progress reporter
        ///
        /// this progress reporter is a best effort implementation. it doesn't stop world to find out accurate data
        ///
        /// what this reporter care is we show start/stop background work and show things are moving or paused
        /// without too much cost.
        ///
        /// due to how solution cralwer calls Start/Stop (see caller of those 2), those 2 can't have a race
        /// and that is all we care for this reporter
        /// </summary>
        internal sealed class SolutionCrawlerProgressReporter : ISolutionCrawlerProgressReporter
        {
            // we use ref count here since solution crawler has multiple queues per priority
            // where an item can be enqueued and dequeued independently.
            // first item added in any of those queues will cause the "start" event to be sent
            // and the very last item processed from those queues will cause "stop" event to be sent
            // evaluating and paused is also ref counted since work in the lower priority queue can
            // be canceled due to new higher priority work item enqueued to higher queue.
            // but before lower priority work actually exit due to cancellation, higher work could
            // start processing. causing an overlap. the ref count make sure that exiting lower
            // work doesn't flip evaluating state to paused state.
            private int _progressStartCount = 0;
            private int _progressEvaluateCount = 0;

            public event EventHandler<ProgressData>? ProgressChanged;

            public bool InProgress => _progressStartCount > 0;

            public void Start() => ChangeProgressStatus(ref _progressStartCount, ProgressStatus.Started);
            public void Stop() => ChangeProgressStatus(ref _progressStartCount, ProgressStatus.Stopped);

            private void Evaluate() => ChangeProgressStatus(ref _progressEvaluateCount, ProgressStatus.Evaluating);
            private void Pause() => ChangeProgressStatus(ref _progressEvaluateCount, ProgressStatus.Paused);

            public void UpdatePendingItemCount(int pendingItemCount)
            {
                if (_progressStartCount > 0)
                {
                    var progressData = new ProgressData(ProgressStatus.PendingItemCountUpdated, pendingItemCount);
                    OnProgressChanged(progressData);
                }
            }

            /// <summary>
            /// Allows the solution crawler to start evaluating work enqueued to it.
            /// Returns an IDisposable that the caller must dispose of to indicate that it no longer needs the crawler to continue evaluating.
            /// Multiple callers can call into this simultaneously.
            /// Only when the last one actually disposes the scope-object will the crawler
            /// actually revert back to the paused state where no work proceeds.
            /// </summary>
            public IDisposable GetEvaluatingScope()
                => new ProgressStatusRAII(this);

            private void ChangeProgressStatus(ref int referenceCount, ProgressStatus status)
            {
                var start = status is ProgressStatus.Started or ProgressStatus.Evaluating;
                if (start ? (Interlocked.Increment(ref referenceCount) == 1) : (Interlocked.Decrement(ref referenceCount) == 0))
                {
                    var progressData = new ProgressData(status, pendingItemCount: null);
                    OnProgressChanged(progressData);
                }
            }

            private void OnProgressChanged(ProgressData progressData)
                => ProgressChanged?.Invoke(this, progressData);

            private readonly struct ProgressStatusRAII : IDisposable
            {
                private readonly SolutionCrawlerProgressReporter _owner;

                public ProgressStatusRAII(SolutionCrawlerProgressReporter owner)
                {
                    _owner = owner;
                    _owner.Evaluate();
                }

                public void Dispose()
                    => _owner.Pause();
            }
        }

        /// <summary>
        /// reporter that doesn't do anything
        /// </summary>
        private class NullReporter : ISolutionCrawlerProgressReporter
        {
            public static readonly NullReporter Instance = new();

            public bool InProgress => false;

            public event EventHandler<ProgressData> ProgressChanged
            {
                add { }
                remove { }
            }
        }
    }
}


text:
#! /bin/bash

#
# Copyright 2015 Google Inc. All Rights Reserved.
#

# author: psimakov@google.com (Pavel Simakov)

#
# This script builds a distributable package of Polymer framework
# dependencies used by Course Builder.
#
# This file requires bower (http://bower.io), which can be installed
# as follows:
#   npm install -g bower
#
# To build a distributable package of all necessary components run:
#    ./bower.sh
#

# Force shell to fail on any errors.
set -e

OUTPUT_NAME="polymer-1.2.0.zip"
SCRIPT_HOME="$(dirname "$0")"

pushd $SCRIPT_HOME

echo Working in $SCRIPT_HOME.
if [ -d "./bower_components/" ]; then
  echo Error: Found existing dir $SCRIPT_HOME/bower_components/. Remove and retry.
  exit 1
fi
if [ -f "./$OUTPUT_NAME" ]; then
  echo Error: Found existing dir $SCRIPT_HOME/$OUTPUT_NAME. Remove and retry.
  exit 1
fi

echo Installing all Polymer components and dependencies.
bower install --config.interactive=false

echo Removing non-essential files from all components.
# folders */demo/*, */test/* and */tests/* and all contained files
find ./bower_components/ -path "*/demo/*" -delete
find ./bower_components/ -type d -name "demo" -delete
find ./bower_components/ -path "*/test/*" -delete
find ./bower_components/ -type d -name "test" -delete
find ./bower_components/ -path "*/tests/*" -delete
find ./bower_components/ -type d -name "tests" -delete
find ./bower_components/ -path "*/.*" -delete
find ./bower_components/ -type d -name ".*" -delete
# individual files
find ./bower_components/ -type f -name "README.md" -delete
find ./bower_components/ -type f -name "CONTRIBUTING.md" -delete
find ./bower_components/ -type f -name "bower.json" -delete

echo Zip things up into $SCRIPT_HOME/$OUTPUT_NAME.
cp ./bower.json ./bower_components/
pushd ./bower_components
zip -r ../$OUTPUT_NAME *
popd

echo Cleaning up
rm -rf ./bower_components/

popd

echo Done! Find results in $SCRIPT_HOME/$OUTPUT_NAME.


text:
// GapBuffer.cs
//
// Author:
//   Mike Krüger <mkrueger@novell.com>
//
// Copyright (c) 2007 Novell, Inc (http://www.novell.com)
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in
// all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.
//
//

using System;
using System.Text;
using System.Collections.Generic;

namespace XwtPlus.TextEditor
{
	public sealed class GapBuffer : IBuffer
	{
		char[] buffer = new char[0];

		int gapBegin  = 0;
		int gapEnd    = 0;
		int gapLength = 0;

		const int minGapLength = 4 * 1024;
		const int maxGapLength = 32 * 1024;

		public int TextLength {
			get {
				return buffer.Length - gapLength;
			}
		}

		public void Insert (int offset, string text)
		{
			Replace (offset, 0, text);
		}

		public void Remove (int offset, int count)
		{
			Replace (offset, count, null);
		}

		public void Remove (TextSegment segment)
		{
			Remove (segment.Offset, segment.Length);
		}

		public string GetTextAt (TextSegment segment)
		{
			return GetTextAt (segment.Offset, segment.Length);
		}

		public string Text {
			get {
				return GetTextAt (0, TextLength);
			}
			set {
				buffer = value != null ? value.ToCharArray () : new char[0];
				gapBegin = gapEnd = gapLength = 0;
			}
		}

		public char GetCharAt (int offset)
		{
			return buffer[offset < gapBegin ? offset : offset + gapLength];
		}

		public string GetTextAt (int offset, int count)
		{
			int end = offset + count;
			if (end < gapBegin)
				return new string (buffer, offset, count);
			if (offset > gapBegin)
				return new string (buffer, offset + gapLength, count);

			int leftBlockSize = gapBegin - offset;
			int rightBlockSize = end - gapBegin;
			char[] result = new char [leftBlockSize + rightBlockSize];
			Array.Copy (buffer, offset, result, 0, leftBlockSize);
			Array.Copy (buffer, gapEnd, result, leftBlockSize, rightBlockSize);
			return new string (result);
		}

		public void Replace (int offset, int count, string text)
		{
			if (!string.IsNullOrEmpty (text)) {
				PlaceGap (offset, text.Length - count);
				text.CopyTo (0, buffer, offset, text.Length);
				gapBegin += text.Length;
			} else {
				PlaceGap (offset, 0);
			}
			gapEnd   += count;
			gapLength = gapEnd - gapBegin;
			if (gapLength > maxGapLength)
				CreateBuffer (gapBegin, minGapLength);
		}

		void PlaceGap (int newOffset, int minLength)
		{
			if (gapLength < minLength) {
				if (minLength < maxGapLength) {
					CreateBuffer (newOffset, minLength + (maxGapLength - minLength) / 2);
				} else {
					CreateBuffer (newOffset, minLength + minGapLength);
				}
				return;
			}

			int delta = gapBegin - newOffset;
			if (delta > 0) {
				Array.Copy (buffer, newOffset, buffer, gapEnd - delta, delta);
			} else {
				Array.Copy (buffer, gapEnd, buffer, gapBegin, -delta);
			}
			gapBegin -= delta;
			gapEnd   -= delta;
		}

		void CreateBuffer (int gapOffset, int gapLength)
		{
			gapLength = System.Math.Max (minGapLength, gapLength);

			char[] newBuffer = new char[TextLength + gapLength];
			if (gapOffset < gapBegin) {
				Array.Copy (buffer, 0, newBuffer, 0, gapOffset);
				Array.Copy (buffer, gapOffset, newBuffer, gapOffset + gapLength, gapBegin - gapOffset);
				Array.Copy (buffer, gapEnd, newBuffer, newBuffer.Length - (buffer.Length - gapEnd), buffer.Length - gapEnd);
			} else {
				Array.Copy (buffer, 0, newBuffer, 0, gapBegin);
				Array.Copy (buffer, gapEnd, newBuffer, gapBegin, gapOffset - gapBegin);
				int lastPartLength = newBuffer.Length - (gapOffset + gapLength);
				Array.Copy (buffer, buffer.Length - lastPartLength, newBuffer, gapOffset + gapLength, lastPartLength);
			}

			gapBegin = gapOffset;
			gapEnd = gapOffset + gapLength;
			this.gapLength = gapLength;
			buffer = newBuffer;
		}

		// TODO: Optimize!
		int IBuffer.IndexOf (char c, int startIndex, int count)
		{
			return Text.IndexOf (c, startIndex, count);
		}

		int IBuffer.IndexOfAny (char[] anyOf, int startIndex, int count)
		{
			return Text.IndexOfAny (anyOf, startIndex, count);
		}

		public int IndexOf (string searchText, int startIndex, int count, StringComparison comparisonType)
		{
			return Text.IndexOf (searchText, startIndex, count, comparisonType);
		}

		int IBuffer.LastIndexOf (char c, int startIndex, int count)
		{
			return Text.LastIndexOf (c, startIndex, count);
		}

		public int LastIndexOf (string searchText, int startIndex, int count, StringComparison comparisonType)
		{
			return Text.LastIndexOf (searchText, startIndex, count, comparisonType);
		}

//		#region Search
//		unsafe int SearchForwardInternal (string pattern, int startIndex)
//		{
//			if (startIndex > gapBegin)
//				startIndex += gapLength;
//
//			int valueLen = pattern.Length;
//			if (startIndex >= buffer.Length - valueLen + 1)
//				return -1;
//
//			fixed (char* bufferPtr = buffer, patternPtr = pattern) {
//				char* ap = bufferPtr + startIndex;
//				char* bufferPhysEnd = bufferPtr + buffer.Length;
//				char* bufferEnd = bufferPhysEnd - valueLen + 1;
//				char* gapBeginPtr = bufferPtr + gapBegin;
//				char* gapEndPtr = bufferPtr + gapEnd;
//				char* stopGap = gapBeginPtr - valueLen + 1;
//				char* patternPos1Ptr = patternPtr + 1;
//				char* patternEndPtr = patternPtr + valueLen;
//				char p0 = *patternPtr;
//
//				if (ap < gapBeginPtr) {
//					if (stopGap > bufferPtr) {
//						while (ap < stopGap) {
//							if (*ap == p0) {
//								char* p = ap + 1;
//								char* v = patternPos1Ptr;
//								while (v < patternEndPtr) {
//									if (*p != *v)
//										goto NextVal;
//									v++;
//									p++;
//								}
//								return (int)(ap - bufferPtr);
//							}
//							NextVal:
//							ap++;
//						}
//					}
//
//					while (ap != gapBeginPtr) {
//						if (*ap == p0) {
//							char* p = ap + 1;
//							char* v = patternPos1Ptr;
//							while (v < patternEndPtr) {
//								if (*p != *v)
//									goto NextVal;
//								v++;
//								p++;
//								if (p == gapBeginPtr)
//									p = gapEndPtr;
//							}
//							return (int)(ap - bufferPtr);
//						}
//						NextVal:
//						ap++;
//					}
//				}
//
//				if (ap < gapEndPtr)
//					ap = gapEndPtr;
//				if (ap < bufferEnd) {
//					while (ap != bufferEnd) {
//						if (*ap == p0) {
//							char* p = ap + 1;
//							char* v = patternPos1Ptr;
//							while (v < patternEndPtr) {
//								if (*p != *v)
//									goto NextVal;
//								v++;
//								p++;
//							}
//							return (int)(ap - gapLength - bufferPtr);
//						}
//						NextVal:
//						ap++;
//					}
//				}
//			}
//			return -1;
//		}
//
//		unsafe int SearchForwardInternalIgnoreCase (string pattern, int startIndex)
//		{
//			if (startIndex > gapBegin)
//				startIndex += gapLength;
//
//			int valueLen = pattern.Length;
//			if (startIndex >= buffer.Length - valueLen + 1)
//				return -1;
//
//			fixed (char* bufferPtr = buffer, patternPtr = pattern) {
//				char* ap = bufferPtr + startIndex;
//				char* bufferPhysEnd = bufferPtr + buffer.Length;
//				char* bufferEnd = bufferPhysEnd - valueLen + 1;
//				char* gapBeginPtr = bufferPtr + gapBegin;
//				char* gapEndPtr = bufferPtr + gapEnd;
//				char* stopGap = gapBeginPtr - valueLen + 1;
//				char* patternPos1Ptr = patternPtr + 1;
//				char* patternEndPtr = patternPtr + valueLen;
//				char p0 = *patternPtr;
//
//				if (ap < gapBeginPtr) {
//					if (stopGap > bufferPtr) {
//						while (ap < stopGap) {
//							if (char.ToUpper (*ap) == p0) {
//								char* p = ap + 1;
//								char* v = patternPos1Ptr;
//								while (v < patternEndPtr) {
//									if (char.ToUpper (*p) != *v)
//										goto NextVal;
//									v++;
//									p++;
//								}
//								return (int)(ap - bufferPtr);
//							}
//							NextVal:
//							ap++;
//						}
//					}
//
//					while (ap != gapBeginPtr) {
//						if (char.ToUpper (*ap) == p0) {
//							char* p = ap + 1;
//							char* v = patternPos1Ptr;
//							while (v < patternEndPtr) {
//								if (char.ToUpper (*p) != *v)
//									goto NextVal;
//								v++;
//								p++;
//								if (p == gapBeginPtr)
//									p = gapEndPtr;
//							}
//							return (int)(ap - bufferPtr);
//						}
//						NextVal:
//						ap++;
//					}
//				}
//
//				if (ap < gapEndPtr)
//					ap = gapEndPtr;
//				if (ap < bufferEnd) {
//					while (ap != bufferEnd) {
//						if (char.ToUpper (*ap) == p0) {
//							char* p = ap + 1;
//							char* v = patternPos1Ptr;
//							while (v < patternEndPtr) {
//								if (char.ToUpper (*p) != *v)
//									goto NextVal;
//								v++;
//								p++;
//							}
//							return (int)(ap - gapLength - bufferPtr);
//						}
//						NextVal:
//						ap++;
//					}
//				}
//			}
//			return -1;
//		}
//
//		public IEnumerable<int> SearchForward (string pattern, int startIndex)
//		{
//			int idx = startIndex;
//			while ((idx = SearchForwardInternal (pattern, idx)) != -1) {
//				yield return idx;
//				idx += pattern.Length;
//			}
//		}
//
//		public IEnumerable<int> SearchForwardIgnoreCase (string pattern, int startIndex)
//		{
//			pattern = pattern.ToUpper ();
//			int idx = startIndex;
//			while ((idx = SearchForwardInternalIgnoreCase (pattern, idx)) != -1) {
//				yield return idx;
//				idx += pattern.Length;
//			}
//		}
//
//		unsafe int SearchBackwardInternal (string pattern, int startIndex)
//		{
//			int valueLen = pattern.Length;
//			if (startIndex < valueLen - 1)
//				return -1;
//			if (startIndex > gapBegin)
//				startIndex += gapLength;
//			fixed (char* bufferPtr = buffer, patternPtr = pattern) {
//				char* ap = bufferPtr + startIndex;
//				char* bufferEnd = bufferPtr + valueLen - 1;
//
//				char* bufferPhysEnd = bufferPtr + buffer.Length;
//				char* gapBeginPtr = bufferPtr + gapBegin;
//				char* gapEndPtr = bufferPtr + gapEnd;
//				char* stopGap = gapEndPtr + valueLen - 1;
//				char* patternPos1Ptr = patternPtr + valueLen - 2;
//				char* patternEndPtr = patternPtr - 1;
//				char p0 = *(patternPtr + valueLen - 1);
//
//				if (ap >= gapEndPtr) {
//					if (stopGap < bufferPhysEnd) {
//						while (ap >= stopGap) {
//							if (*ap == p0) {
//								char* p = ap - 1;
//								char* v = patternPos1Ptr;
//								while (v > patternEndPtr) {
//									if (*p != *v)
//										goto NextVal;
//									v--;
//									p--;
//								}
//								return (int)(p - gapLength - bufferPtr + 1);
//							}
//							NextVal:
//							ap--;
//						}
//					}
//
//					while (ap >= gapEndPtr) {
//						if (*ap == p0) {
//							char* p = ap - 1;
//							char* v = patternPos1Ptr;
//							while (v > patternEndPtr) {
//								if (*p != *v)
//									goto NextVal;
//								v--;
//								if (p == gapEndPtr) {
//									p = gapBeginPtr - 1;
//								} else {
//									p--;
//								}
//							}
//							if (p >= gapEndPtr)
//								return (int)(p - gapLength - bufferPtr + 1);
//							return (int)(p - bufferPtr + 1);
//						}
//						NextVal:
//						ap--;
//					}
//				}
//
//				while (ap >= bufferEnd) {
//					if (*ap == p0) {
//						char* p = ap - 1;
//						char* v = patternPos1Ptr;
//						while (v > patternEndPtr) {
//							if (*p != *v)
//								goto NextVal;
//							v--;
//							p--;
//						}
//						return (int)(p - bufferPtr + 1);
//					}
//					NextVal:
//					ap--;
//				}
//			}
//			return -1;
//		}
//
//		unsafe int SearchBackwardInternalIgnoreCase (string pattern, int startIndex)
//		{
//			int valueLen = pattern.Length;
//			if (startIndex < valueLen - 1)
//				return -1;
//			if (startIndex > gapBegin)
//				startIndex += gapLength;
//
//			fixed (char* bufferPtr = buffer, patternPtr = pattern) {
//				char* ap = bufferPtr + startIndex;
//				char* bufferEnd = bufferPtr + valueLen - 1;
//
//				char* bufferPhysEnd = bufferPtr + buffer.Length;
//				char* gapBeginPtr = bufferPtr + gapBegin;
//				char* gapEndPtr = bufferPtr + gapEnd;
//				char* stopGap = gapEndPtr + valueLen - 1;
//				char* patternPos1Ptr = patternPtr + valueLen - 2;
//				char* patternEndPtr = patternPtr - 1;
//				char p0 = *(patternPtr + valueLen - 1);
//
//				if (ap >= gapEndPtr) {
//					if (stopGap < bufferPhysEnd) {
//						while (ap >= stopGap) {
//							if (char.ToUpper (*ap) == p0) {
//								char* p = ap - 1;
//								char* v = patternPos1Ptr;
//								while (v > patternEndPtr) {
//									if (char.ToUpper (*p) != *v)
//										goto NextVal;
//									v--;
//									p--;
//								}
//								return (int)(p - gapLength - bufferPtr + 1);
//							}
//							NextVal:
//							ap--;
//						}
//					}
//
//					while (ap >= gapEndPtr) {
//						if (char.ToUpper (*ap) == p0) {
//							char* p = ap - 1;
//							char* v = patternPos1Ptr;
//							while (v > patternEndPtr) {
//								if (char.ToUpper (*p) != *v)
//									goto NextVal;
//								v--;
//								if (p == gapEndPtr) {
//									p = gapBeginPtr - 1;
//								} else {
//									p--;
//								}
//							}
//							if (p >= gapEndPtr)
//								return (int)(p - gapLength - bufferPtr + 1);
//							return (int)(p - bufferPtr + 1);
//						}
//						NextVal:
//						ap--;
//					}
//				}
//				while (ap >= bufferEnd) {
//					if (char.ToUpper (*ap) == p0) {
//						char* p = ap - 1;
//						char* v = patternPos1Ptr;
//						while (v > patternEndPtr) {
//							if (char.ToUpper (*p) != *v)
//								goto NextVal;
//							v--;
//							p--;
//						}
//						return (int)(p - bufferPtr + 1);
//					}
//					NextVal:
//					ap--;
//				}
//			}
//			return -1;
//		}
//
//		public IEnumerable<int> SearchBackward (string pattern, int startIndex)
//		{
//			int idx = startIndex;
//			while ((idx = SearchBackwardInternal (pattern, idx)) != -1) {
//				yield return idx;
//				idx -= pattern.Length;
//			}
//		}
//
//		public IEnumerable<int> SearchBackwardIgnoreCase (string pattern, int startIndex)
//		{
//			pattern = pattern.ToUpper ();
//			int idx = startIndex;
//			while ((idx = SearchBackwardInternalIgnoreCase (pattern, idx)) != -1) {
//				yield return idx;
//				idx -= pattern.Length;
//			}
//		}
//
//		/* Boyer-Moore-Horspool-Raita implementation: (but on Intel Core i brute force outpeforms it.
//
//	static int[] ProcessString (string pattern)
//	{
//		var result = new int[char.MaxValue];
//		for (int i = 0; i < result.Length; i++)
//			result[i] = pattern.Length - 1;
//		for (int i = 0; i < pattern.Length - 1; ++i) {
//			result[pattern[i]] = pattern.Length - i - 1;
//		}
//		return result;
//	}
//	unsafe static int bmhrSearchBytes (string text, string pattern, int textStart, int[] b)
//	{
//		int lastIndex = text.Length + pattern.Length - 1;
//		if (textStart >= lastIndex)
//			return -1;
//
//		int m = pattern.Length - 1;
//		int mMinusOne = pattern.Length - 2;
//
//		var last = pattern[pattern.Length - 1];
//		var first = pattern[0];
//
//		fixed (char* textPtr = text, pattenrPtr = pattern) {
//			char* i = textPtr + textStart + pattern.Length - 1;
//			char* endText = textPtr + lastIndex;
//			while (i < endText) {
//				if (*i == last) {
//					//if (*(i - m) == first) {
//						char* k = i - 1;
//						char* pp = pattenrPtr + mMinusOne;
//
//						while (pp >= pattenrPtr && *k == *pp) {
//							--k;
//							--pp;
//						}
//
//						if (pp < pattenrPtr)
//							return (int)(k - textPtr) + 1;
//				//	}
//				}
//				i += b[*i];
//			}
//		}
//		return -1;
//	}
//			 * */
//		#endregion

	}
}


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

namespace PhysX.Samples.CharacterSample
{
	public class ControllerHitReport : UserControllerHitReport
	{
		public override void OnControllerHit(ControllersHit hit)
		{
			Console.WriteLine("Hit controller at " + hit.WorldPosition);
		}

		public override void OnObstacleHit(ControllerObstacleHit hit)
		{

		}

		public override void OnShapeHit(ControllerShapeHit hit)
		{

		}
	}
}


text:
package com.azure.resourcemanager.videoanalyzer.implementation;

import com.azure.core.http.rest.Response;
import com.azure.core.http.rest.SimpleResponse;
import com.azure.core.util.Context;
import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.videoanalyzer.fluent.OperationStatusesClient;
import com.azure.resourcemanager.videoanalyzer.fluent.models.VideoAnalyzerPrivateEndpointConnectionOperationStatusInner;
import com.azure.resourcemanager.videoanalyzer.models.OperationStatuses;
import com.azure.resourcemanager.videoanalyzer.models.VideoAnalyzerPrivateEndpointConnectionOperationStatus;

public final class OperationStatusesImpl implements OperationStatuses {
    private static final ClientLogger LOGGER = new ClientLogger(OperationStatusesImpl.class);

    private final OperationStatusesClient innerClient;

    private final com.azure.resourcemanager.videoanalyzer.VideoAnalyzerManager serviceManager;

    public OperationStatusesImpl(
        OperationStatusesClient innerClient,
        com.azure.resourcemanager.videoanalyzer.VideoAnalyzerManager serviceManager) {
        this.innerClient = innerClient;
        this.serviceManager = serviceManager;
    }

    public VideoAnalyzerPrivateEndpointConnectionOperationStatus get(
        String resourceGroupName, String accountName, String name, String operationId) {
        VideoAnalyzerPrivateEndpointConnectionOperationStatusInner inner =
            this.serviceClient().get(resourceGroupName, accountName, name, operationId);
        if (inner != null) {
            return new VideoAnalyzerPrivateEndpointConnectionOperationStatusImpl(inner, this.manager());
        } else {
            return null;
        }
    }

    public Response<VideoAnalyzerPrivateEndpointConnectionOperationStatus> getWithResponse(
        String resourceGroupName, String accountName, String name, String operationId, Context context) {
        Response<VideoAnalyzerPrivateEndpointConnectionOperationStatusInner> inner =
            this.serviceClient().getWithResponse(resourceGroupName, accountName, name, operationId, context);
        if (inner != null) {
            return new SimpleResponse<>(
                inner.getRequest(),
                inner.getStatusCode(),
                inner.getHeaders(),
                new VideoAnalyzerPrivateEndpointConnectionOperationStatusImpl(inner.getValue(), this.manager()));
        } else {
            return null;
        }
    }

    private OperationStatusesClient serviceClient() {
        return this.innerClient;
    }

    private com.azure.resourcemanager.videoanalyzer.VideoAnalyzerManager manager() {
        return this.serviceManager;
    }
}


text:
<!DOCTYPE html>

	<title>RESTO</title>

	<link rel="stylesheet" type="text/css" href="<?php echo base_url(); ?>assets/css/bootstrap.css">
	<link rel="stylesheet" type="text/css" href="<?php echo base_url(); ?>assets/css/style.css">
	<link rel="stylesheet" href="<?php echo base_url(); ?>assets/plugin/vegas/vegas.min.css">
	<link rel="stylesheet" href="<?php echo base_url(); ?>assets/plugin/pgwslideshow/pgwslideshow.css">
	<link rel="stylesheet" href="<?php echo base_url(); ?>assets/plugin/reviewblock/reviewblock.css">

	<link rel="stylesheet" href="<?php echo base_url(); ?>assets/plugin/jqueryui/jquery-ui.css">
	<link rel="stylesheet" href="<?php echo base_url(); ?>assets/plugin/datepicker/css/datepicker.css">
	<link rel="stylesheet" href="<?php echo base_url(); ?>assets/plugin/sweetalert-master/dist/sweetalert.css">

	<meta name="viewport" content="width=device-width, initial-scale=1">

	      <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1" aria-expanded="false">
	        Toggle navigation

	      </button>
	      <a class="navbar-brand" href="<?php echo base_url('utama/logged_in') ?>">Resto.com

<a href="<?= base_url('utama/pelanggan')?>">Hi, <?php echo $this->session->userdata('user_pelanggan'); ?>

<a href="<?= base_url('utama/logout')?>">Keluar

	<?php if(!empty($record_resto)): ?>
		<?php foreach ($record_resto as $row):?>

			        <img align="left" class="fb-image-lg" src="<?php echo $row->foto_resto ?>"  style="width:100%;height:350px;"alt="Profile image example"/>
			        <img align="left" class="fb-image-profile thumbnail" src="<?php echo $row->foto_resto ?>" alt="Profile image example"/>

<?php echo $row->nama_resto ?>

<?php echo $row->alamat_resto ?>

		<?php endforeach; ?>
	<?php endif; ?>

Review Pelanggan

								<?php if(!empty($record_pelanggan)){ ?>
									<?php foreach ($record_pelanggan as $row) {?>

<?php echo $row->nama_user ?>

									<?php } ?>
								<?php } ?>

										☆
										☆
										☆
										☆
										☆

								<form class="review" action="<?php echo base_url('utama/simpan_review'); ?>" method="POST">
									<input type="hidden" name="rating" id="star">
									<?php if(!empty($record_resto)){ ?>
										<?php foreach ($record_resto as $row) { ?>
											<input type="hidden" name="koderesto" value="<?php echo $row->kode_resto; ?>"></input>
											<?php } ?>
									<?php } ?>
									<?php if(!empty($record_pelanggan)){ ?>
										<?php foreach ($record_pelanggan as $row) { ?>
											<input type="hidden" name="kodepelanggan" value="<?php echo $row->id_user; ?>"></input>
											<?php } ?>
									<?php } ?>

<input type="text" class="form-control" placeholder="Judul Review"  name="judulreview" maxlength="100" value="">

<textarea class="form-control" rows="4" cols="74" name="isireview"  placeholder="Tuliskan komentar anda" maxlength="250"></textarea>

<button class="btn btn-small btn-success paling bawah" type="submit" name="kirim">Kirim</button>

								</form>

					<?php if(!empty($record_foto)){?>

						<?php foreach ($record_foto as $row2):?>

<img src="<?php echo $row2->path_foto ?>">

						<?php endforeach; ?>

					<?php }else{?>

					<?php } ?>

			<?php if(!empty($record_resto)){ ?>
				<?php foreach ($record_resto as $row){?>

No telfon

<?php echo $row->no_telfon; ?>

Jadwal buka

<?php echo $row->jadwal_buka; ?>

Tipe Sajian

<?php echo $row->tipe_sajian; ?>

Kisaran harga

<?php echo $row->harga_terendah; echo " - "; echo $row->harga_tertinggi?>

Pembayaran

<?php echo $row->metode_pembayaran; ?>

				<?php } ?>
			<?php } ?>

resto.com

Footer


text:
@interface NSColorPickerWheelView : NSView {

	IBOutlet id _delegate;

	NSPoint		_handleLocation;
	CGFloat		_hueValue; // Varies
	CGFloat		_saturationValue;
	CGFloat		_brightnessValue;
}

- (void)setHue:(CGFloat)hue; // 0-359
- (CGFloat)hue;

- (void)setSaturation:(CGFloat)saturation; // 0-99
- (CGFloat)saturation;

- (void)setBrightness:(CGFloat)brightness; // 0-99
- (CGFloat)brightness;

- (IBAction)brightnessChanged:(id)sender;

@end

@interface NSObject (NSColorPickerWheelViewDelegate)

- (void)colorPickerWheelView:(NSColorPickerWheelView*)view didSelectHue:(CGFloat)hue saturation:(CGFloat)saturation andBrightness:(CGFloat)brightness;

@end


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

<title>Uses of Class net.sf.jasperreports.engine.util.JRProperties.PropertySuffix (JasperReports 5.6.0 API)</title>
<meta name="date" content="2014-05-27">
<link rel="stylesheet" type="text/css" href="../../../../../../stylesheet.css" title="Style">

JavaScript is disabled on your browser.

Overview

Package

Class

Use

Tree

Deprecated

Index

Help

Prev

Next

Frames

No Frames

All Classes

Uses of Class
net.sf.jasperreports.engine.util.JRProperties.PropertySuffix

Packages that use JRProperties.PropertySuffix

Package
Description

net.sf.jasperreports.engine.util

Contains utility classes for the core library.

Uses of JRProperties.PropertySuffix in net.sf.jasperreports.engine.util

Methods in net.sf.jasperreports.engine.util that return types with arguments of type JRProperties.PropertySuffix

Modifier and Type
Method and Description

static java.util.List<JRProperties.PropertySuffix>
JRProperties.getAllProperties(JRPropertiesHolder propertiesHolder,
                java.lang.String prefix)

Deprecated.

Returns the list of all properties for a key prefix, including global
 properties.

static java.util.List<JRProperties.PropertySuffix>
JRProperties.getAllProperties(JRPropertiesMap propertiesMap,
                java.lang.String prefix)

Deprecated.

Returns the list of all properties for a key prefix, including global
 properties.

static java.util.List<JRProperties.PropertySuffix>
JRProperties.getProperties(JRPropertiesHolder propertiesHolder,
             java.lang.String prefix)

Deprecated.

Returns the list of all properties for a key prefix.

static java.util.List<JRProperties.PropertySuffix>
JRProperties.getProperties(JRPropertiesMap propertiesMap,
             java.lang.String prefix)

Deprecated.

Returns the list of all properties for a key prefix.

static java.util.List<JRProperties.PropertySuffix>
JRProperties.getProperties(java.lang.String prefix)

Deprecated.

Returns the list of all properties for a key prefix.

Overview

Package

Class

Use

Tree

Deprecated

Index

Help

Prev

Next

Frames

No Frames

All Classes

© 2001-2010 Jaspersoft Corporation www.jaspersoft.com


text:
<?php

namespace ShootProof\Cli\Test;

use \PHPUnit_Framework_TestCase;
use ShootProof\Cli\Options;
use ShootProof\Cli\Validators\EmailValidator;
use ShootProof\Cli\Validators\RequiredValidator;

class OptionsTest extends PHPUnit_Framework_TestCase
{
    protected $options;

    public function setUp()
    {
        $validators = [
            'A' => [
                new RequiredValidator,
                new EmailValidator
            ],
            'B' => new EmailValidator,
            'C' => new RequiredValidator,
            'D' => new RequiredValidator,
        ];

        $defaults = [
            'D' => 'testD',
        ];

        $this->options = new Options($validators, $defaults);
        $this->options->throwExceptions(FALSE);
    }

    public function testLoadValidateGet()
    {
        $data = [
            'A' => 'test@domain.com',
            'B' => 'test2@domain.com',
        ];

        $expected = [
            'A' => 'test@domain.com',
            'B' => 'test2@domain.com',
            'D' => 'testD',
        ];

        $this->options->loadOptionData($data, FALSE, TRUE);
        $this->assertTrue(isset($this->options->A));
        $this->assertEquals($expected['A'], $this->options->A);
        $this->assertEquals($expected, $this->options->asArray());

        // Overwrite B with an invalid value
        $this->options->loadOptionData([ 'B' => 'invalid' ], TRUE, FALSE);
        $this->assertTrue(isset($this->options->B));
        $this->assertEquals($expected['B'], $this->options->B);
        $this->assertEquals($expected, $this->options->asArray());

        // Overwrite B with a valid value
        $this->options->loadOptionData([ 'B' => 'valid@domain.com' ], TRUE, FALSE);
        $this->assertTrue(isset($this->options->B));
        $this->assertNotEquals($expected['B'], $this->options->B);
        $this->assertNotEquals($expected, $this->options->asArray());

        // Block overwriting B with a valid value
        $this->options->loadOptionData([ 'B' => $data['B'] ], FALSE, FALSE);
        $this->assertTrue(isset($this->options->B));
        $this->assertNotEquals($expected['B'], $this->options->B);
        $this->assertNotEquals($expected, $this->options->asArray());

        // Get value that isn't set
        $this->assertFalse(isset($this->options->C));
        $this->assertNull($this->options->C);

        // Get default value
        $this->assertFalse(isset($this->options->D));
        $this->assertEquals($expected['D'], $this->options->D);

        // Validate all required
        $this->assertFalse($this->options->validateAllRequired());
        $this->options->loadOptionData([ 'C' => 'testC' ], FALSE, FALSE);
        $this->assertTrue($this->options->validateAllRequired());
    }
}


text:
ACCEPTED

#### According to
Index Fungorum

#### Published in
null

#### Original name
Phoma epiparmelia Vouaux

### Remarks
null


text:
require 'test_helper'

class SiteLayoutTest < ActionDispatch::IntegrationTest
  test "layout links" do
    get root_path
    assert_template 'static_pages/home'
    assert_select "a[href=?]", root_path, count: 2
    assert_select "a[href=?]", help_path
    assert_select "a[href=?]", about_path
    assert_select "a[href=?]", contact_path
  end

  test "signup page and title" do
    get signup_path
    assert_template 'users/new'
    assert_select "title", full_title("Sign up")
  end
end


text:
@interface PodsDummy_Pods_JELibrarySample_Example : NSObject
@end
@implementation PodsDummy_Pods_JELibrarySample_Example
@end


text:
const clientFunctions = require('../api/models/invoice.js');
const _ = require('lodash');

const clientOptions = {
  tableName: 'invoices',
  underscored: true
};

module.exports = function(sequelize, DataTypes) {

  const options = _.merge(clientOptions, clientFunctions);
  const Invoice = sequelize.define('Invoice', {
    provider_id: {
      type: DataTypes.INTEGER
    },
    investor_id: {
      type: DataTypes.INTEGER
    },
    amount: {
      type: DataTypes.FLOAT
    },
    status: {
      /* eslint new-cap: ["error", { "properties": false }] */
      type: DataTypes.ENUM('new', 'pending_fund', 'funded')
    },
    created_at: {
      type: DataTypes.DATE
    },
    updated_at: {
      type: DataTypes.DATE
    }
  }, options);

  return Invoice;
};


text:
/**
 * Graphology ForceAtlas2 Layout Default Settings
 * ===============================================
 */
module.exports = {
  linLogMode: false,
  outboundAttractionDistribution: false,
  adjustSizes: false,
  edgeWeightInfluence: 1,
  scalingRatio: 1,
  strongGravityMode: false,
  gravity: 1,
  slowDown: 1,
  barnesHutOptimize: false,
  barnesHutTheta: 0.5
};


text:
ALTER TABLE SAFE_DEPOSIT_BOX
ADD COLUMN SDB_NAME_SLUG varchar(255) NOT NULL;

UPDATE SAFE_DEPOSIT_BOX
JOIN (
  select substr(PATH_TRAILING_PATH_REMOVED, LOCATE('/', PATH_TRAILING_PATH_REMOVED) + 1, LENGTH(PATH_TRAILING_PATH_REMOVED)) as SDB_NAME_SLUG, SDB_ID
  from (
    select SUBSTR(PATH, 1, LENGTH(PATH) -1) as PATH_TRAILING_PATH_REMOVED, ID as SDB_ID
    from SAFE_DEPOSIT_BOX
  ) as PATH_TRAILING_PATH_REMOVED_VIRTUAL_TABLE
) as JOINED_VIRTUAL_TABLE on SDB_ID = SAFE_DEPOSIT_BOX.ID
SET SAFE_DEPOSIT_BOX.SDB_NAME_SLUG=(JOINED_VIRTUAL_TABLE.SDB_NAME_SLUG)
WHERE JOINED_VIRTUAL_TABLE.SDB_ID = SAFE_DEPOSIT_BOX.ID;


text:
?> Represents a shop for a clash royale player.

#### Attributes
> **`legendary`** - The number of days till the user recieves a legendary chest in his shop.
**Returns:** int

> **`epic`** - The number of days till the user recieves an epic chest in his shop.
**Returns:** int

> **`arena`** - The number of days till the user recieves an arena offer in his shop.
**Returns:** int


text:
using System;
using System.Web.UI.WebControls;

using DotNetNuke.Services.Localization;

using Telerik.Web.UI;

#endregion

namespace DotNetNuke.Web.UI.WebControls
{
    public class DnnGridRatingColumn : GridRatingColumn
    {
        #region Public Properties

        public string LocalResourceFile
        {
            get
            {
                return Utilities.GetLocalResourceFile(Owner.OwnerGrid.Parent);
            }
        }

        #endregion

        #region Public Methods

        public override GridColumn Clone()
        {
            DnnGridRatingColumn dnnGridColumn = new DnnGridRatingColumn();

            //you should override CopyBaseProperties if you have some column specific properties
            dnnGridColumn.CopyBaseProperties(this);

            return dnnGridColumn;
        }

        public override void InitializeCell(TableCell cell, int columnIndex, GridItem inItem)
        {
            base.InitializeCell(cell, columnIndex, inItem);
            if (inItem is GridHeaderItem && !String.IsNullOrEmpty(HeaderText))
            {
                cell.Text = Localization.GetString(string.Format("{0}.Header", HeaderText), LocalResourceFile);
            }
        }

        #endregion
    }
}


text:
import logging
from flask import Flask
from flask.ext.appbuilder import SQLA, AppBuilder
from flask.ext.appbuilder.menu import Menu
from .sec import MySecurityManager
from .indexview import MyIndexView
from sqlalchemy.engine import Engine
from sqlalchemy import event

logging.basicConfig(format='%(asctime)s:%(levelname)s:%(name)s:%(message)s')
logging.getLogger().setLevel(logging.DEBUG)

app = Flask(__name__)
app.config.from_object('config')
db = SQLA(app)

appbuilder = AppBuilder(app, db.session, indexview=MyIndexView,
                        menu=Menu(reverse=False), security_manager_class=MySecurityManager)

"""
@event.listens_for(Engine, "connect")
def set_sqlite_pragma(dbapi_connection, connection_record):
    cursor = dbapi_connection.cursor()
    cursor.execute("PRAGMA foreign_keys=ON")
    cursor.close()
"""

from app import views


text:
package com.bitdubai.fermat_dmp_plugin.layer.middleware.navigation_structure.developer.bitdubai.version_1.database;

import com.bitdubai.fermat_api.FermatException;
import com.bitdubai.fermat_api.layer.osa_android.database_system.Database;
import com.bitdubai.fermat_api.layer.osa_android.database_system.DatabaseDataType;
import com.bitdubai.fermat_api.layer.osa_android.database_system.DatabaseFactory;
import com.bitdubai.fermat_api.layer.osa_android.database_system.DatabaseTableFactory;
import com.bitdubai.fermat_api.layer.osa_android.database_system.DealsWithPluginDatabaseSystem;
import com.bitdubai.fermat_api.layer.osa_android.database_system.PluginDatabaseSystem;
import com.bitdubai.fermat_api.layer.osa_android.database_system.exceptions.CantCreateDatabaseException;
import com.bitdubai.fermat_api.layer.osa_android.database_system.exceptions.CantCreateTableException;
import com.bitdubai.fermat_api.layer.osa_android.database_system.exceptions.InvalidOwnerIdException;

import java.util.UUID;

/**
 *  The Class  com.bitdubai.fermat_dmp_plugin.layer.middleware.navigation_structure.developer.bitdubai.version_1.structure.WalletNavigationStructureMiddlewareDatabaseFactory
 * is responsible for creating the tables in the database where it is to keep the information.
 *

 *
 *  Created by Natalia on 07/08/15.
 *
 * @version 1.0
 * @since Java JDK 1.7
 */
public class WalletNavigationStructureMiddlewareDatabaseFactory implements DealsWithPluginDatabaseSystem {

    /**
     * DealsWithPluginDatabaseSystem Interface member variables.
     */
    private PluginDatabaseSystem pluginDatabaseSystem;

    /**
     * Constructor with parameters to instantiate class
     * .
     *
     * @param pluginDatabaseSystem DealsWithPluginDatabaseSystem
     */
    public WalletNavigationStructureMiddlewareDatabaseFactory(PluginDatabaseSystem pluginDatabaseSystem) {
        this.pluginDatabaseSystem = pluginDatabaseSystem;
    }

    /**
     * Create the database
     * Modified by Manuel Perez on 11/08/2015
     *
     * @param ownerId      the owner id
     * @param databaseName the database name
     * @return Database
     * @throws CantCreateDatabaseException
     */
    public Database createDatabase(UUID ownerId, String databaseName) throws CantCreateDatabaseException {
        Database database;

        /**
         * I will create the database where I am going to store the information of this wallet.
         */
        try {
            database = this.pluginDatabaseSystem.createDatabase(ownerId, databaseName);

            /**
             * Create Wallet Manager Wallets Table table.
             */
            DatabaseTableFactory table = null;
            DatabaseFactory databaseFactory = database.getDatabaseFactory();

            table=databaseFactory.newTableFactory(ownerId, WalletNavigationStructureMiddlewareDatabaseConstants.WALLET_NAVIGATION_STRUCTURE_TABLE_NAME);
            table.addColumn(WalletNavigationStructureMiddlewareDatabaseConstants.WALLET_NAVIGATION_STRUCTURE_PUBLIC_KEY, DatabaseDataType.STRING, 36, Boolean.FALSE);
            table.addColumn(WalletNavigationStructureMiddlewareDatabaseConstants.WALLET_NAVIGATION_STRUCTURE_ACTIVITY, DatabaseDataType.STRING, 36, Boolean.FALSE);
            table.addColumn(WalletNavigationStructureMiddlewareDatabaseConstants.WALLET_NAVIGATION_STRUCTURE_START_ACTIVITY, DatabaseDataType.STRING, 36, Boolean.FALSE);
            table.addColumn(WalletNavigationStructureMiddlewareDatabaseConstants.WALLET_NAVIGATION_STRUCTURE_LAST_ACTIVITY, DatabaseDataType.STRING, 36, Boolean.FALSE);

            table.addIndex(WalletNavigationStructureMiddlewareDatabaseConstants.WALLET_NAVIGATION_STRUCTURE_FIRST_KEY_COLUMN);

            databaseFactory.createTable(ownerId, table);

        }catch (CantCreateTableException cantCreateTableException) {

                throw new CantCreateDatabaseException(CantCreateDatabaseException.DEFAULT_MESSAGE, cantCreateTableException, "", "Exception not handled by the plugin, There is a problem and i cannot create the table.");

        }catch (InvalidOwnerIdException invalidOwnerId) {
            /**
             * This shouldn't happen here because I was the one who gave the owner id to the database file system,
             * but anyway, if this happens, I can not continue.
             */
            throw new CantCreateDatabaseException(CantCreateDatabaseException.DEFAULT_MESSAGE, invalidOwnerId, "", "There is a problem with the ownerId of the database.");

        } catch (CantCreateDatabaseException cantCreateDatabaseException) {
            /**
             * I can not handle this situation.
             */
            throw new CantCreateDatabaseException(CantCreateDatabaseException.DEFAULT_MESSAGE, cantCreateDatabaseException, "", "Exception not handled by the plugin, There is a problem and i cannot create the database.");

        } catch (Exception e) {
            /**
             * This shouldn't happen here because I was the one who gave the owner id to the database file system,
             * but anyway, if this happens, I can not continue.
             */
            throw new CantCreateDatabaseException(CantCreateDatabaseException.DEFAULT_MESSAGE, FermatException.wrapException(e), "", "");

        }
        return database;
    }

    /**
     * DealsWithPluginDatabaseSystem Interface implementation.
     */
    @Override
    public void setPluginDatabaseSystem(PluginDatabaseSystem pluginDatabaseSystem) {
        this.pluginDatabaseSystem = pluginDatabaseSystem;
    }
}


text:
package edu.unc.cs.robotics.math;

/**
 * Thrown when a matrix index pair (r,c) is out of bounds
 */
public class MatrixIndexOutOfBoundsException extends IndexOutOfBoundsException {

    private static final long serialVersionUID = -2395585001320676235L;

    public MatrixIndexOutOfBoundsException(Matrix m, int r, int c) {
        super(String.format("index (%d, %d) into %dx%d matrix",
            r, c, m.rows(), m.columns()));
    }
}


text:
package com.sdw.soft.extension.spring.base.propertyeditor.vo;
/**
 *
 * @author syd
 */
public class Person {

	private Computer computer;

	public Computer getComputer() {
		return computer;
	}

	public void setComputer(Computer computer) {
		this.computer = computer;
	}

}


text:
from django.conf import settings
from django.contrib.admin import ModelAdmin
from django_admin_json_editor import JSONEditorWidget

def generate_translatable_schema(model):
    """
    Generates JSON schema for JSON admin editor
    :param model: model class
    :return: JSON admin schema
    """
    # noinspection PyProtectedMember
    translatable_fields = model._meta.translatable_fields
    return {
        'type': 'object',
        'properties': {
            language: {
                'type': 'object',
                'properties': {
                    field: {
                        'type': 'string'
                    } for field in translatable_fields
                },
            } for language in settings.TRANSLATIONS_MAP
        }
    }

class TranslatableModelAdmin(ModelAdmin):
    """
    Overrides `translations` field
    """

    def formfield_for_dbfield(self, db_field, **kwargs):
        if db_field.name == 'translations':
            kwargs['widget'] = JSONEditorWidget(generate_translatable_schema(self.model), False)
        return super(TranslatableModelAdmin, self).formfield_for_dbfield(db_field, **kwargs)


text:
//
//  CShaderProgramOGL2_0.h
//  OpenJam
//
//  Created by Yevgeniy Logachev
//  Copyright (c) 2014 Yevgeniy Logachev. All rights reserved.
//
#if defined(RENDER_OGL2_0)

#ifndef CSHADERPROGRAMOGL2_0_H
#define CSHADERPROGRAMOGL2_0_H

#include "CShaderProgramOGLBase.h"

namespace jam {

class CShaderProgramOGL2_0 : public CShaderProgramOGLBase {
public:
    CShaderProgramOGL2_0();
    virtual ~CShaderProgramOGL2_0();

    virtual void Bind() override;
    virtual void Unbind() override;

    virtual void AttachShader(IShaderPtr shader) override;
    virtual void DetachShader(IShader::ShaderType shaderType) override;
    virtual bool IsShaderAttached(IShader::ShaderType shaderType) override;
    virtual bool IsValid() override;
    virtual bool Link() override;
    virtual bool IsLinked() const override;

    virtual uint32_t Attribute(const std::string& name) override;
    virtual uint32_t Uniform(const std::string& name) override;

    // Default locations
    virtual uint32_t VertexPosition() override;
    virtual uint32_t VertexNormal() override;
    virtual uint32_t VertexUV() override;
    virtual uint32_t VertexColor() override;
    virtual uint32_t MainTexture() override;
    virtual uint32_t MainColor() override;
    virtual uint32_t ProjectionMatrix() override;
    virtual uint32_t ModelMatrix() override;

    virtual uint32_t Texture(uint32_t index) override;
    virtual uint32_t DiffuseTexture() override;
    virtual uint32_t NormalTexture() override;
    virtual uint32_t SpecularTexture() override;
    virtual uint32_t EnvironmentTexture() override;

    virtual bool BindUniform1i(const std::string& uniform, int value) override;
    virtual bool BindUniform1f(const std::string& uniform, float value) override;
    virtual bool BindUniform2i(const std::string& uniform, int value1, int value2) override;
    virtual bool BindUniform2f(const std::string& uniform, float value1, float value2) override;
    virtual bool BindUniformfv(const std::string& uniform, const std::vector<float>& value) override;
    virtual bool BindUniformMatrix4x4f(const std::string& uniform, const glm::mat4x4& value) override;

    virtual const TUniInt& Uniformsi() const override;
    virtual const TUniFloat& Uniformsf() const override;
    virtual const TUniFloat& Uniformsfv() const override;
    virtual const TUniMatrix4Float& UniformsMatrix4x4f() const override;
    virtual void UpdateUniforms() const override;

private:
    uint32_t m_ProgramObject;

    std::unordered_map<std::string, uint32_t> m_CachedAttributes;
    std::unordered_map<std::string, uint32_t> m_CachedUniforms;

    bool m_IsLinked;
    std::map<IShader::ShaderType, IShaderPtr> m_AttachedShaders;

    TUniInt m_UniInt;
    TUniFloat m_UniFloat;
    TUniInt m_UniIntVec;
    TUniFloat m_UniFloatVec;
    TUniMatrix4Float m_UniMatrixFloat;
};

}; // namespace jam

#endif /* CSHADERPROGRAMOGL2_0_H */

#endif /* defined(RENDER_OGL2_0) */


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

<TITLE>
Constant Field Values (Base64 - A Public Domain Java utility for encoding and decoding Base64)
</TITLE>
<LINK REL ="stylesheet" TYPE="text/css" HREF="stylesheet.css" TITLE="Style">

      Package
      Class
      Tree
      Deprecated
      Index
      Help

 PREV
 NEXT

  FRAMES
 NO FRAMES

All Classes

Constant Field Values

Contents

Unnamed Package

Unnamed Package.*

Base64

public static final boolean
DECODE
false

public static final boolean
ENCODE
true

      Package
      Class
      Tree
      Deprecated
      Index
      Help

 PREV
 NEXT

  FRAMES
 NO FRAMES

All Classes


text:
<?php

/**
 * Starts a service
 *
 * @phpstub
 *
 * @param string $servicename
 * @param string $machine
 *
 * @return int
 */
function win32_start_service($servicename, $machine = NULL)
{
}