text:
using System;
using System.Collections.Generic;
using System.Linq;
using MCSharp.World;
namespace MCSharp
{
    public class CmdDoor : Command
    {
        public byte[] ignoreList = { 255, 255, 255, 255, 255, 255, 255 };
        public byte type = (byte)0;
        public Block opMats = new Block();

        // Constructor
        public CmdDoor(CommandGroup g, GroupEnum group, string name) : base(g, group, name) { blnConsoleSupported = false; /* By default no console support*/ }

        // Command usage help
        public override void Help(Player p)
        {
            p.SendMessage("/door - Convert all blocks in an area to door_material");
            p.SendMessage("/door <block(s)>  ignores that block, max 7");
        }

        // Code to run when used by a player
        public override void Use(Player p, string message)
        {
            // Clear previously ignored blocks
            for (int i = 0; i < ignoreList.Length - 1; i++)
            {
                ignoreList[i] = 255;
            }
            int counter = 0;
            CatchPos cpos = new CatchPos(); cpos.solid = SolidType.solid; unchecked { cpos.type = (byte)-1; }
            cpos.x = 0; cpos.y = 0; cpos.z = 0; p.blockchangeObject = cpos;
            if (message != "")
            {
                // Here we can use the same principle as searching through opMats.
                // This function ignores op_material for security reasons.
                // This function also ignores any non-doorifiable block (ie: air, water, lava...etc)
                message = message.ToLower();
                message = " " + message;  // Add the whitespace back to work with the ignore list code below

                for (int i = 0; i < opMats.doorBlocks.Length; i++)
                {
                    if ((message.Contains(" " + Block.Name(opMats.doorBlocks[i]))) || (message.Contains(" " + Block.Name(opMats.regBlocks[i]))))
                    {
                        ignoreList[counter] = opMats.doorBlocks[i];
                        counter += 1;
                        if (counter > ignoreList.Length - 1)
                        {
                            break;
                        }
                    }
                }
            } // Not allowing user to use "all" because turning a map into door_material would be pointless
              // User can still manually do it by placing blocks.
            p.SendMessage("Place two blocks to determine the edges.");
            p.ClearBlockchange();
            p.Blockchange += new Player.BlockchangeEventHandler(Blockchange1);
        }

        public void Blockchange1(Player p, ushort x, ushort y, ushort z, byte type)
        {
            p.ClearBlockchange();
            byte b = p.level.GetTile(x, y, z); //get the tile type of first set and set that to byte b
            p.SendBlockchange(x, y, z, b);
            CatchPos bp = (CatchPos)p.blockchangeObject;
            bp.x = x; bp.y = y; bp.z = z; p.blockchangeObject = bp;
            p.Blockchange += new Player.BlockchangeEventHandler(Blockchange2);
        }
        public void Blockchange2(Player p, ushort x, ushort y, ushort z, byte type)
        {
            p.ClearBlockchange();
            byte b = p.level.GetTile(x, y, z);
            p.SendBlockchange(x, y, z, b);
            CatchPos cpos = (CatchPos)p.blockchangeObject;
            unchecked { if (cpos.type != (byte)-1) { type = cpos.type; } }
            List<Pos> buffer = new List<Pos>();
            switch (cpos.solid)
            {
                case SolidType.solid:
                    if (!Server.operators.Contains(p.name))
                    {
                        int attemptedLimit = (Math.Abs(cpos.x - x) * Math.Abs(cpos.y - y) * Math.Abs(cpos.z - z));
                        if (attemptedLimit > p.group.CuboidLimit && p.group.CuboidLimit != 0) //OPERATOR door LIMIT, same as cuboid
                        {
                            p.SendMessage("You're trying to convert " + attemptedLimit + " blocks.");
                            p.SendMessage("Your block limit is " + p.group.CuboidLimit.ToString() + " blocks. Build in stages.");
                            return;
                        }
                    }
                    buffer.Capacity = Math.Abs(cpos.x - x) * Math.Abs(cpos.y - y) * Math.Abs(cpos.z - z);
                    for (ushort xx = Math.Min(cpos.x, x); xx <= Math.Max(cpos.x, x); ++xx)
                        for (ushort yy = Math.Min(cpos.y, y); yy <= Math.Max(cpos.y, y); ++yy)
                            for (ushort zz = Math.Min(cpos.z, z); zz <= Math.Max(cpos.z, z); ++zz)
                                /*if (p.level.GetTile(xx, yy, zz) != type) {*/
                                BufferAdd(buffer, xx, yy, zz); //}
                    break;
            }

            p.SendMessage("Converting " + buffer.Count.ToString() + " blocks into door_material.");

            // Disable physics before changing the blocks
            Physics physicsSetting = p.level.Physics;
            p.level.Physics = Physics.Off;
            p.level.ClearPhysics();

            // Because we are calling ClearPhysics() we do not need to account for doorair_material. These materials will be
            // converted back into door_material automatically.

            buffer.ForEach(delegate(Pos pos)
            {
                byte oldBlock = p.level.GetTile(pos.x, pos.y, pos.z); //Get the block that is there at the moment
                byte newBlock = Block.convertDoor(oldBlock);
                if (newBlock != oldBlock)  // if the block is doorifiable
                {
                    if (!opMats.doorBlocks.Contains(oldBlock)) // if the block is not already a door
                    {
                        if (!ignoreList.Contains(newBlock)) // if the new block is not being ignored
                        {
                            p.level.Blockchange(p, pos.x, pos.y, pos.z, newBlock); // send converted reg_material
                        }
                    }
                }
            });

            p.level.Physics = physicsSetting;
            p.SendMessage("Conversion complete.");
        }

        void BufferAdd(List<Pos> list, ushort x, ushort y, ushort z)
        {
            Pos pos; pos.x = x; pos.y = y; pos.z = z; list.Add(pos);
        }
    }
}


text:
Using JavaScript Embedding Method

The chart will appear within this DIV. This text will be replaced by the chart.

redpajama_set_name: RedPajamaGithub


text:
//=============================================================================================================

#ifndef MNEANALYZE_SOURCELOCALIZATION_H
#define MNEANALYZE_SOURCELOCALIZATION_H

//=============================================================================================================
// INCLUDES
//=============================================================================================================

#include "sourcelocalization_global.h"

#include <anShared/Plugins/abstractplugin.h>

//=============================================================================================================
// QT INCLUDES
//=============================================================================================================

#include <QtWidgets>
#include <QtCore/QtPlugin>

//=============================================================================================================
// FORWARD DECLARATIONS
//=============================================================================================================

namespace ANSHAREDLIB {
    class Communicator;
}

//=============================================================================================================
// DEFINE NAMESPACE SOURCELOCALIZATIONPLUGIN
//=============================================================================================================

namespace SOURCELOCALIZATIONPLUGIN
{

//=============================================================================================================
// SOURCELOCALIZATIONPLUGIN FORWARD DECLARATIONS
//=============================================================================================================

//=============================================================================================================
/**
 * SourceLocalization Plugin
 *
 * @brief The sourcelocalization class provides a plugin for computing averages.
 */
class SOURCELOCALIZATIONSHARED_EXPORT SourceLocalization : public ANSHAREDLIB::AbstractPlugin
{
    Q_OBJECT
    Q_PLUGIN_METADATA(IID "ansharedlib/1.0" FILE "sourcelocalization.json") //New Qt5 Plugin system replaces Q_EXPORT_PLUGIN2 macro
    // Use the Q_INTERFACES() macro to tell Qt's meta-object system about the interfaces
    Q_INTERFACES(ANSHAREDLIB::AbstractPlugin)

public:
    //=========================================================================================================
    /**
     * Constructs an SourceLocalization object.
     */
    SourceLocalization();

    //=========================================================================================================
    /**
     * Destroys the SourceLocalization object.
     */
    ~SourceLocalization() override;

    // AbstractPlugin functions
    virtual QSharedPointer<AbstractPlugin> clone() const override;
    virtual void init() override;
    virtual void unload() override;
    virtual QString getName() const override;

    virtual QMenu* getMenu() override;
    virtual QDockWidget* getControl() override;
    virtual QWidget* getView() override;
    virtual QString getBuildInfo() override;

    virtual void handleEvent(QSharedPointer<ANSHAREDLIB::Event> e) override;
    virtual QVector<ANSHAREDLIB::EVENT_TYPE> getEventSubscriptions() const override;

private:
    QPointer<ANSHAREDLIB::Communicator>                     m_pCommu;                   /**< To broadcst signals. */
};

} // NAMESPACE

#endif // MNEANALYZE_SOURCELOCALIZATION_H


text:
package google

import (
	"bytes"
	"fmt"
	"os"
	"os/exec"
	"text/template"
	"time"

	"github.com/golang/glog"
)

var machineControllerImage = "gcr.io/k8s-cluster-api/machine-controller:0.19"

func init() {
	if img, ok := os.LookupEnv("MACHINE_CONTROLLER_IMAGE"); ok {
		machineControllerImage = img
	}
}

func CreateMachineControllerPod(token string) error {
	tmpl, err := template.ParseFiles("cloud/google/pods/machine-controller.yaml")
	if err != nil {
		return err
	}

	type params struct {
		Token string
		Image string
	}

	var tmplBuf bytes.Buffer
	err = tmpl.Execute(&tmplBuf, params{
		Token: token,
		Image: machineControllerImage,
	})
	if err != nil {
		return err
	}

	maxTries := 5
	for tries := 0; tries < maxTries; tries++ {
		err = createPod(tmplBuf.Bytes())
		if err == nil {
			return nil
		} else {
			if tries < maxTries-1 {
				glog.Info("Error scheduling machine controller. Will retry...\n")
				time.Sleep(3 * time.Second)
			}
		}
	}
	if err != nil {
		return fmt.Errorf("couldn't start machine controller: %v\n", err)
	} else {
		return nil
	}
}

func createPod(manifest []byte) error {
	cmd := exec.Command("kubectl", "create", "-f", "-")
	stdin, err := cmd.StdinPipe()
	if err != nil {
		return err
	}

	go func() {
		defer stdin.Close()
		stdin.Write(manifest)
	}()

	out, err := cmd.CombinedOutput()
	if err == nil {
		return nil
	} else {
		return fmt.Errorf("couldn't create pod: %v, output: %s", err, string(out))
	}
}


text:
package com.tango.BucketSyncer.KeyJobs;

import com.amazonaws.services.s3.model.*;
import com.tango.BucketSyncer.*;
import com.tango.BucketSyncer.ObjectSummaries.ObjectSummary;
import lombok.extern.slf4j.Slf4j;
import org.apache.http.HttpStatus;

import java.util.Date;

/**
 * Handles a single key. Determines if it should be copied, and if so, performs the copy operation.
 */
@Slf4j
public class S32S3KeyCopyJob extends S32S3KeyJob {

    protected String keydest;

    public S32S3KeyCopyJob(Object sourceClient,
                           Object destClient,
                           MirrorContext context,
                           ObjectSummary summary,
                           Object notifyLock) {
        super(sourceClient, destClient, context, summary, notifyLock);

        keydest = summary.getKey();
        final MirrorOptions options = context.getOptions();
        if (options.hasDestPrefix()) {
            keydest = keydest.substring(options.getPrefixLength());
            keydest = options.getDestPrefix() + keydest;
        }
    }

    @Override
    public void run() {
        final MirrorOptions options = context.getOptions();
        final String key = summary.getKey();
        try {
            if (!shouldTransfer()) {
                return;
            }
            final ObjectMetadata sourceMetadata = getObjectMetadata(options.getSourceBucket(), key, options);
            final AccessControlList objectAcl = getAccessControlList(options, key);

            if (options.isDryRun()) {
                log.info("Would have copied {} to destination: {}", key, keydest);
            } else {
                if (keyCopied(sourceMetadata, objectAcl)) {
                    context.getStats().objectsCopied.incrementAndGet();
                } else {
                    context.getStats().copyErrors.incrementAndGet();
                    //add fail-copied key to errorKeyList
                    context.getStats().errorKeyList.add(key);
                }
            }
        } catch (Exception e) {
            log.error("Error copying key: {}: {}", key, e);

        } finally {
            synchronized (notifyLock) {
                notifyLock.notifyAll();
            }
            if (options.isVerbose()) {
                log.info("Done with {}", key);
            }
        }
    }

    boolean keyCopied(ObjectMetadata sourceMetadata, AccessControlList objectAcl) {
        boolean copied = false;
        String key = summary.getKey();
        MirrorOptions options = context.getOptions();
        boolean verbose = options.isVerbose();
        int maxRetries = options.getMaxRetries();
        MirrorStats stats = context.getStats();
        for (int tries = 0; tries < maxRetries; tries++) {
            if (verbose) {
                log.info("copying (try # {}): {} to: {}", new Object[]{tries, key, keydest});
            }
            final CopyObjectRequest request = new CopyObjectRequest(options.getSourceBucket(), key, options.getDestinationBucket(), keydest);
            request.setNewObjectMetadata(sourceMetadata);
            if (options.isCrossAccountCopy()) {
                request.setCannedAccessControlList(CannedAccessControlList.BucketOwnerFullControl);
            } else {
                request.setAccessControlList(objectAcl);
            }
            try {
                stats.copyCount.incrementAndGet();
                client.copyObject(request);
                stats.bytesCopied.addAndGet(sourceMetadata.getContentLength());
                if (verbose) {
                    log.info("successfully copied (on try #{}): {} to: {}", new Object[]{tries, key, keydest});
                }
                copied = true;
                break;
            } catch (AmazonS3Exception s3e) {
                //if return with 404 error, problem with bucket name
                if(s3e.getStatusCode() == HttpStatus.SC_NOT_FOUND){
                    log.error("Failed to access S3 bucket. Check bucket name: ", s3e);
                    System.exit(1);
                }
                log.error("s3 exception copying (try #{}) {} to: {}: {}", new Object[]{tries, key, keydest, s3e});
            } catch (Exception e) {
                log.error("unexpected exception copying (try #{}) {} to: {}: {}", new Object[]{tries, key, keydest, e});
            }
            try {
                Thread.sleep(10);
            } catch (InterruptedException e) {
                log.error("interrupted while waiting to retry key: {}: {}", key, e);
                return copied;
            }
        }
        return copied;
    }

    private boolean shouldTransfer() {
        final MirrorOptions options = context.getOptions();
        final String key = summary.getKey();
        final boolean verbose = options.isVerbose();

        if (options.hasCtime()) {
            final Date lastModified = summary.getLastModified();
            if (lastModified == null) {
                if (verbose) {
                    log.info("No Last-Modified header for key: {}", key);
                }

            } else {
                if (lastModified.getTime() < options.getMaxAge()) {
                    if (verbose) {
                        log.info("key {} (lastmod = {}) is older than {} (cutoff = {}), not copying", new Object[]{key, lastModified, options.getCtime(), options.getMaxAgeDate()});
                    }
                    return false;
                }
            }
        }
        final ObjectMetadata metadata;
        try {
            metadata = getObjectMetadata(options.getDestinationBucket(), keydest, options);
        } catch (AmazonS3Exception e) {
            if (e.getStatusCode() == HttpStatus.SC_NOT_FOUND) {
                if (verbose) {
                    log.debug("Key not found in destination bucket (will copy): {}", keydest);
                }
                return true;
            } else {
                log.warn("Error getting metadata for {} {} (not copying): {}", new Object[]{options.getDestinationBucket(), keydest, e});
                return false;
            }
        } catch (Exception e) {
            log.warn("Error getting metadata for {} {} (not copying): {}", new Object[]{options.getDestinationBucket(), keydest, e});
            return false;
        }

        if (summary.getSize() > MirrorOptions.MAX_SINGLE_REQUEST_UPLOAD_FILE_SIZE) {
            return metadata.getContentLength() != summary.getSize();
        }
        final boolean objectChanged = objectChanged(metadata);
        if (verbose && !objectChanged) {
            log.info("Destination file is same as source, not copying: {}", key);
        }

        return objectChanged;
    }

    boolean objectChanged(ObjectMetadata metadata) {
        final KeyFingerprint sourceFingerprint = new KeyFingerprint(summary.getSize(), summary.getETag());
        final KeyFingerprint destFingerprint = new KeyFingerprint(metadata.getContentLength(), metadata.getETag());
        return !sourceFingerprint.equals(destFingerprint);
    }
}


text:
<!DOCTYPE html>

		<meta charset="UTF-8"/>
		<meta name="viewport" content="width=device-width, initial-scale=1.0"/>

		<title>The Quest for the Perfect Cookie</title>
		<link rel="stylesheet" href="styles.css"/>

Background Research: Basic Cookie Recipe

First, you will do some background research to get a sense of how to prepare a basic chocolate chip cookie recipe. Follow the instructions below!

Ingredients

1 teaspoon baking soda

1 teaspoon salt

1 cup (2 sticks) butter, softened

3/4 cup granulated sugar

3/4 cup packed brown sugar

1 teaspoon vanilla extract

2 large eggs

2 cups (12-oz. pkg.) semi-sweet chocolate morsels

2 1/4 cups all-purpose flour

Instructions

Combine Flour, baking soda and salt in a small bowl.

Beat butter, granulated sugar, brown sugar and vanilla extract in large mixer bowl until creamy.

Add eggs, one at a time, beating well after each addition.

Gradually beat in flour mixture.

Stir in morsels and nuts.

Drop by rounded tablespoon onto ungreased baking sheets.

Chef's Tip:

When adding flour to electric mixer, it is important to add it gradually to prevent flour from spraying out of the bowl!

Chef's Tip:

When baking cookies, it is important to consider where the heat is coming from, especially when trying to bake cookies in a controlled situation. For most ovens, cookies should be baked on the middle racks.

How'd we do?

Take some bites of your cookie. How did they turn out? Good? Tasty? Do you wish they were more chewy? Or crispier? Bigger? Is it your perfect cookie? What could get even better?

        <textarea class="input" rows="4" id="question_howdWeDo"></textarea>

Now take a picture of your cookie using the Notebook!

Back

Continue...


text:
fs = Npm.require('fs')

Blaze.Template.registerHelper('include', function(template, data) {
  data = data || {};
  return Spacebars.toHTML(data, Assets.getText(template));
});

Blaze.Template.registerHelper('toLocaleString', function(data) {
	return moment(data).format('YYYY-MM-DD');
})


text:
require "fabrika_prazdnikof/engine"
require "fabrika_prazdnikof/db_connect"

module FabrikaPrazdnikof; end


text:
'use strict';
require('../../test.js');

var TrackLocation = rek('TrackLocation'),
	Track = rek('Track');

describe('Track tests', function() {

	var location;

	beforeEach(function() {
		location = new TrackLocation(new TrackLocation(), 'test-location', '/foo/bar');
	});

	it('should create a new Track', function() {
		var track = new Track(location, 'test.mp3');
		expect(track.getName()).toEqual('test.mp3');
		expect(track.getLocation()).toEqual(location);
		expect(track.getPath()).toEqual('/test-location/test.mp3');
		expect(track.getResourcePath()).toEqual('/foo/bar/test.mp3');
		expect(_.isEqual(location.getTracks(), [track])).toBeTruthy();
	});

	describe('when the location only contains one track', function() {
		var track;

		beforeEach(function() {
			track = new Track(location, 'test.mp3');
		});

		it('should return no next track', function() {
			expect(track.getNextTrack()).toEqual(null);
		});

		it('should return no previous track', function() {
			expect(track.getPreviousTrack()).toEqual(null);
		});
	});

	describe('when the location contains more than one track', function() {
		var firstTrack, secondTrack;

		beforeEach(function() {
			firstTrack = new Track(location, 'first.mp3');
			secondTrack = new Track(location, 'second.mp3');
		});

		it('firstTrack should return secondTrack as next track', function() {
			expect(firstTrack.getNextTrack()).toEqual(secondTrack);
		});

		it('firstTrack should return no previous track', function() {
			expect(firstTrack.getPreviousTrack()).toEqual(null);
		});

		it('secondTrack should return no next track', function() {
			expect(secondTrack.getNextTrack()).toEqual(null);
		});

		it('secondTrack should return firstTrack as previous track', function() {
			expect(secondTrack.getPreviousTrack()).toEqual(firstTrack);
		});
	});

});


text:
<?php
/**
 * Shop System Plugins:
 * - License can be found under:
 * https://github.com/wirecard/paymentSDK-php/blob/master/LICENSE
 */

namespace Page;

class PayPalCancel extends Base
{
    //include url of current page
    public $URL = '/PayPal/cancel.php';

    //page specific text that can be found in the URL
    public $pageSpecific = 'cancel';

    //page elements
    public $elements = array(
        'Transaction ID to be refunded' => "//*[@id='parentTransactionId']",
        'Cancel' => "//*[@class='btn btn-primary']",
        'Payment successfully cancelled.' => "Payment successfully cancelled.",
        'Transaction ID' => "Transaction ID",
        'Transaction Identification' => "//div[contains(@class, 'content')]/a",
        'Noted Transaction Identification' => '',

    );
}


text:
package org.sistcoop.iso4217.models.search.filters;

import javax.ejb.Local;

import org.sistcoop.iso4217.provider.Provider;

@Local
public interface CurrencyFilterProvider extends Provider {

    String getIdFilter();

    String getAlphabeticCodeFilter();

    String getNumericCodeFilter();

    String getEntityFilter();

    String getCurrencyFilter();

}


text:
<?php

namespace Hyper\Application\Controllers;

abstract class Controller
{
    public function __construct(){
    }
    public function isLogged(){
        return isset($_SESSION['id']);
    }
}


text:
<?php

use Illuminate\Foundation\Testing\WithoutMiddleware;
use Illuminate\Foundation\Testing\DatabaseMigrations;
use Illuminate\Foundation\Testing\DatabaseTransactions;
use TPTaskRunner\Jobs\Tasks\BaseTask;

class TaskSuccess2 extends BaseTask {}

class TaskAPITest extends TestCase
{
    public function test_index()
    {
        $task = factory(\TPTaskRunner\Models\Task::class)->create();

        $this->visit(URL::route('api.v1.tasks.index'))
             ->seeJson(['id' => $task->id]);
    }

    public function test_show()
    {
        $task = factory(\TPTaskRunner\Models\Task::class)->create();
        $this->assertNotNull($task);

        $this->visit(URL::route('api.v1.tasks.show', $task->id))
            ->seeJsonStructure(['id',
                'job_class',
                'is_runned',
                'is_runned_at',
                'is_failure',
                'is_failure_at',
                'is_success',
                'is_success_at',
                'next_run_at',
                'taskable_id',
                'taskable_type',
                'failure_message',
                'created_at',
                'updated_at',
                'data',
                'links' => ['show', 'run', 'rerun'],
            ])
            ->seeJson(['id' => $task->id])
            ->seeStatusCode(200);
    }

    public function test_store()
    {
        $faker = Faker\Factory::create();
        $id = $faker->uuid;

        $this->dontSeeInDatabase('tasks', ['job_class' => $id]);

        $this->post(URL::route('api.v1.tasks.store'), [
            'job_class' => $id,
            'data' => 'test-data'
        ])
            ->seeJson(['created' => true])
            ->seeStatusCode(201);

        $this->seeInDatabase('tasks', ['job_class' => $id, 'data' => 'test-data']);
    }

    public function test_update()
    {
        $faker = Faker\Factory::create();

        $task = factory(\TPTaskRunner\Models\Task::class)->create();

        $job_class = $faker->uuid;
        $data = $faker->uuid;
        $this->put(URL::route('api.v1.tasks.update', $task->id), [
            'job_class' => $job_class,
            'data' => $data
        ])
            ->seeJson(['updated' => true])
            ->seeStatusCode(200);

        $this->seeInDatabase('tasks', ['id' => $task->id, 'job_class' => $job_class, 'data' => $data]);
    }

    public function test_destroy()
    {
        $task = factory(\TPTaskRunner\Models\Task::class)->create();
        $this->assertNotNull($task);

        $this->seeInDatabase('tasks', ['id' => $task->id]);

        $this->delete(URL::route('api.v1.tasks.destroy', $task->id))
            ->seeJson(['destroy' => true])
            ->seeStatusCode(200);

        $this->dontSeeInDatabase('tasks', ['id' => $task->id]);
    }

    public function test_run()
    {
        $task = factory(\TPTaskRunner\Models\Task::class)->create();
        $task->job_class = TaskSuccess2::class;

        $this->visit(URL::route('api.v1.tasks.run', $task->id))
            ->seeJson(['run' => true])
            ->seeStatusCode(200);
    }
}


text:
package net.jonp.armi.example.chat.server;

import java.io.IOException;
import java.io.PrintStream;

import net.jonp.armi.example.chat.Shared;

/**
 * Executes a chat server.
 */
public class ServerMain
{
    private static final int BACKLOG = 3;

    private static void usage(final PrintStream out)
    {
        out.println("Usage: ChatServer [OPTION]...");
        out.println(" -p <port>  Specify the port to listen on");
        out.println("            Default: " + Shared.PORT);
        out.println(" -h         Display this message and terminate");
    }

    public static void main(final String[] args)
    {
        int port = Shared.PORT;

        try {
            for (int i = 0; i < args.length; i++) {
                if ("-p".equals(args[i])) {
                    try {
                        port = Integer.parseInt(args[++i]);
                    }
                    catch (final NumberFormatException nfe) {
                        throw new Exception("Not an integer: " + args[i]);
                    }

                    if (port < 1 || port > 65535) {
                        throw new Exception("Port must be in the range [1, 65535]");
                    }
                }
                else if ("-h".equals(args[i])) {
                    usage(System.out);
                    System.exit(0);
                }
                else {
                    throw new Exception("Unrecognized argument: " + args[i]);
                }
            }
        }
        catch (final ArrayIndexOutOfBoundsException aioobe) {
            System.err.println("Missing argument");
            usage(System.err);
            System.exit(1);
        }
        catch (final Exception e) {
            System.err.println(e.getMessage());
            usage(System.err);
            System.exit(1);
        }

        final ChatServer server;
        try {
            server = new ChatServer(null, port, BACKLOG);
        }
        catch (final IOException ioe) {
            System.err.println("Unable to start server: " + ioe.getMessage());
            System.exit(1);
            return;
        }

        server.start();
    }
}


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

<title>javax.swing.text.html Class Hierarchy (Java Platform SE 7 )</title>
<meta name="date" content="2014-12-18">
<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

Java™ Platform
Standard Ed. 7

Prev

Next

Frames

No Frames

All Classes

Hierarchy For Package javax.swing.text.html

Package Hierarchies:

All Packages

Class Hierarchy

java.lang.Object

javax.swing.AbstractAction (implements javax.swing.Action, java.lang.Cloneable, java.io.Serializable)

javax.swing.text.TextAction

javax.swing.text.StyledEditorKit.StyledTextAction

javax.swing.text.html.HTMLEditorKit.HTMLTextAction

javax.swing.text.html.HTMLEditorKit.InsertHTMLTextAction

javax.swing.text.AbstractDocument (implements javax.swing.text.Document, java.io.Serializable)

javax.swing.text.DefaultStyledDocument (implements javax.swing.text.StyledDocument)

javax.swing.text.html.HTMLDocument

javax.swing.text.AbstractDocument.AbstractElement (implements javax.swing.text.Element, javax.swing.text.MutableAttributeSet, java.io.Serializable, javax.swing.tree.TreeNode)

javax.swing.text.AbstractDocument.BranchElement

javax.swing.text.html.HTMLDocument.BlockElement

javax.swing.text.AbstractDocument.LeafElement

javax.swing.text.html.HTMLDocument.RunElement

javax.swing.text.AbstractWriter

javax.swing.text.html.HTMLWriter

javax.swing.text.html.MinimalHTMLWriter

javax.swing.text.html.CSS (implements java.io.Serializable)

javax.swing.text.html.CSS.Attribute

javax.swing.text.EditorKit (implements java.lang.Cloneable, java.io.Serializable)

javax.swing.text.DefaultEditorKit

javax.swing.text.StyledEditorKit

javax.swing.text.html.HTMLEditorKit (implements javax.accessibility.Accessible)

java.util.EventObject (implements java.io.Serializable)

javax.swing.event.HyperlinkEvent

javax.swing.text.html.HTMLFrameHyperlinkEvent

javax.swing.text.html.FormSubmitEvent

javax.swing.text.html.HTML

javax.swing.text.html.HTML.Attribute

javax.swing.text.html.HTML.Tag

javax.swing.text.html.HTML.UnknownTag (implements java.io.Serializable)

javax.swing.text.html.HTMLDocument.HTMLReader.TagAction

javax.swing.text.html.HTMLDocument.HTMLReader.BlockAction

javax.swing.text.html.HTMLDocument.HTMLReader.ParagraphAction

javax.swing.text.html.HTMLDocument.HTMLReader.PreAction

javax.swing.text.html.HTMLDocument.HTMLReader.CharacterAction

javax.swing.text.html.HTMLDocument.HTMLReader.HiddenAction

javax.swing.text.html.HTMLDocument.HTMLReader.IsindexAction

javax.swing.text.html.HTMLDocument.HTMLReader.SpecialAction

javax.swing.text.html.HTMLDocument.HTMLReader.FormAction

javax.swing.text.html.HTMLDocument.Iterator

javax.swing.text.html.HTMLEditorKit.HTMLFactory (implements javax.swing.text.ViewFactory)

javax.swing.text.html.HTMLEditorKit.Parser

javax.swing.text.html.HTMLEditorKit.ParserCallback

javax.swing.text.html.HTMLDocument.HTMLReader

java.awt.event.MouseAdapter (implements java.awt.event.MouseListener, java.awt.event.MouseMotionListener, java.awt.event.MouseWheelListener)

javax.swing.text.html.FormView.MouseEventListener

javax.swing.text.html.HTMLEditorKit.LinkController (implements java.awt.event.MouseMotionListener, java.io.Serializable)

javax.swing.text.html.Option (implements java.io.Serializable)

javax.swing.text.StyleContext (implements javax.swing.text.AbstractDocument.AttributeContext, java.io.Serializable)

javax.swing.text.html.StyleSheet

javax.swing.text.html.StyleSheet.BoxPainter (implements java.io.Serializable)

javax.swing.text.html.StyleSheet.ListPainter (implements java.io.Serializable)

javax.swing.text.View (implements javax.swing.SwingConstants)

javax.swing.text.ComponentView

javax.swing.text.html.FormView (implements java.awt.event.ActionListener)

javax.swing.text.html.ObjectView

javax.swing.text.CompositeView

javax.swing.text.BoxView

javax.swing.text.html.BlockView

javax.swing.text.html.ListView

javax.swing.text.FlowView

javax.swing.text.ParagraphView (implements javax.swing.text.TabExpander)

javax.swing.text.html.ParagraphView

javax.swing.text.GlyphView (implements java.lang.Cloneable, javax.swing.text.TabableView)

javax.swing.text.LabelView (implements javax.swing.text.TabableView)

javax.swing.text.html.InlineView

javax.swing.text.html.ImageView

Enum Hierarchy

java.lang.Object

java.lang.Enum<E> (implements java.lang.Comparable<T>, java.io.Serializable)

javax.swing.text.html.FormSubmitEvent.MethodType

Overview

Package

Class

Use

Tree

Deprecated

Index

Help

Java™ Platform
Standard Ed. 7

Prev

Next

Frames

No Frames

All Classes

 Submit a bug or feature
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
 Copyright © 1993, 2015, Oracle and/or its affiliates.  All rights reserved.


text:
namespace render {

DeathActionRenderer::DeathActionRenderer( int32_t Id )
    : ActionRenderer( Id )
{

}

void DeathActionRenderer::Init( const Actor& actor )
{
    SpriteCollection const& Sprites = mRenderableRepo( actor.GetId() );
    int32_t aid = AutoId( "death" );
    Sprite const& Spr = Sprites( aid );
    if( Spr.IsValid() )
    {
        mSecsToEnd = Spr.GetSecsToEnd();
    }
}

void DeathActionRenderer::FillRenderableSprites( const Actor& actor, IRenderableComponent const& renderableC, RenderableSprites_t& renderableSprites )
{
    SpriteCollection const& Sprites = mRenderableRepo( actor.GetId() );
    int32_t aid = AutoId( "death" );
    Sprite const& Spr = Sprites( aid );
    if( Spr.IsValid() )
    {
        SpritePhase const& Phase = Spr( ( int32_t )GetState() );
        renderableSprites.push_back( RenderableSprite( &actor, &renderableC, aid, &Spr, &Phase ) );
    }
}

void DeathActionRenderer::Update( double DeltaTime )
{
    double nextState = mSecsToEnd == 0 ? 100 : ( mState + 1. / mSecsToEnd * DeltaTime * 100. );

    if( nextState >= 100 )
    {
        nextState = 100.;
    }
    mState = nextState;
}

} // namespace render


text:
/**
 *
 */
package com.hcr.bdr.crm.service;

/**
 * @author seraph
 *
 */
public interface HaiziwangSkuService {

}


text:
package co.edu.javeriana.objectify.negocio;

import java.io.Serializable;
import java.time.ZonedDateTime;
import java.util.ArrayList;
import java.util.Collection;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Map;
import java.util.Set;

/**
 * Clase fachada para el sistema de música. Permite el CRUD de usuarios, artistas, albumes,
 * canciones y conciertos entre otros.
 * @author Javier Morales
 *
 */
public class Objectify implements Serializable {

	private static final long serialVersionUID = 1L;

	private Map<Long, Artista> artistas;
	private Map<Long, Concierto> conciertos;
	private Map<Long, Usuario> usuarios;

	public Objectify() {
		this.artistas = new HashMap<Long, Artista>();
		this.conciertos = new HashMap<Long, Concierto>();
		this.usuarios = new HashMap<Long, Usuario>();
	}

	/**
	 * Crea un nuevo usuario en el sistema, si el usuario es pago la fecha de vencimiento de la
	 * suscripcion es un año a partir de la fecha actual.
	 * @param nombre
	 * @param pago
	 * @return Retorna el id del usuario creado
	 */
	public long agregarUsuario(String nombre, boolean pago, ZonedDateTime fechaVencimiento) {
		Usuario usuario;
		if (pago) {
			usuario = new UsuarioPago(nombre, fechaVencimiento);
		} else {
			usuario = new UsuarioBasico(nombre);
		}
		this.usuarios.put(usuario.getId(), usuario);
		return usuario.getId();
	}

	/**
	 * Crea un nuevo artista en el sistema y retorna el id del mismo.
	 * @param nombre
	 * @param descripcion
	 * @param generos
	 * @return Retorna el id del artista creado
	 */
	public long agregarArtista(String nombre, String descripcion, Collection<Genero> generos) {
		Artista artista = new Artista(nombre, descripcion, generos);
		this.artistas.put(artista.getId(), artista);
		return artista.getId();
	}

	/**
	 * Crea un nuevo album y lo agrega al artista con el id especificado. Adicionalmente notifica a todos los
	 * usuarios que siguen al artista que el nuevo albúm esta disponible.
	 * @param idArtista
	 * @param titulo
	 * @param caratula
	 * @param exclusivo
	 */
	public void agregarAlbum(long idArtista, String titulo, String caratula, boolean exclusivo) {
		Artista artista = this.artistas.get(idArtista);
		artista.agregarAlbum(titulo, caratula, exclusivo);
	}

	/**
	 * Agrega una nueva cancion al albúm del artista especificado por idArtista.
	 * @param idArtista
	 * @param tituloAlbum
	 * @param nombre
	 * @param duracion
	 * @param rutaArchivo
	 */
	public void agregarCancion(long idArtista, String tituloAlbum, String nombre, int duracion, String rutaArchivo) {
		Artista artista = this.artistas.get(idArtista);
		artista.agregarCancion(tituloAlbum, nombre, duracion, rutaArchivo);
	}

	/**
	 * Agrega un concierto, sin artistas asignados, y lo añade a la lista de conciertos disponibles
	 * @param escenario
	 * @param ciudad
	 * @param pais
	 * @param fechaYHora
	 * @return Retorna el id del concierto creado
	 */
	public long agregarConcierto(String escenario, String ciudad, String pais, ZonedDateTime fechaYHora) {
		Concierto concierto = new Concierto(escenario, ciudad, pais, fechaYHora);
		return concierto.getId();
	}

	/**
	 * Agrega un artista a un concierto y notifica a cada uno de los seguidores del artista del mismo.
	 * @param idConcierto
	 * @param idArtista
	 */
	public void agregarArtistaConcierto(long idConcierto, long idArtista) {
		Artista artista = this.artistas.get(idArtista);
		Concierto concierto = this.conciertos.get(idConcierto);
		// Agregar un artista a un concierto le permite al concierto notificar a los seguidores por medio del artista
		concierto.agregarArtista(artista);
	}

	/**
	 * Agrega un usuario como seguidor de un artista
	 * @param idArtista
	 * @param idUsuario
	 */
	public void seguirArtista(long idArtista, long idUsuario) {
		Artista artista = this.artistas.get(idArtista);
		Usuario usuario = this.usuarios.get(idUsuario);
		usuario.seguirArtista(artista);
		artista.agregarSeguidor(usuario);
	}

	/**
	 * Remueve un usuario como seguidor de un artista
	 * @param idArtista
	 * @param idUsuario
	 */
	public void dejarDeSeguirArtista(long idArtista, long idUsuario) {
		Artista artista = this.artistas.get(idArtista);
		Usuario usuario = this.usuarios.get(idUsuario);
		usuario.dejarDeSeguirArtista(artista);
		artista.quitarSeguidor(usuario);
	}

	/**
	 * Busca entre todos los artistas en el sistema los que tienen un nombre o
	 * descripción que contenga la palabra ignorando mayusculas y minusculas.
	 * @param palabra
	 * @return Artistas con la palabra a buscar o una coleccion vacia
	 */
	public Collection<Artista> buscarArtistasPorAproximacion(String palabra) {
		Set<Artista> resultado = new HashSet<Artista>();
		palabra = palabra.toLowerCase().trim();
		for (Artista artista : this.artistas.values()){
			// Nombres de artistas
			if (artista.getNombre().toLowerCase().contains(palabra) ||
				artista.getDescripcion().toLowerCase().contains(palabra)) {
				resultado.add(artista);
			}
		}
		return resultado;
	}

	/**
	 * Verifica que el usuario sea un usuario pago y en caso de serlo, y que su suscripcion
	 * se encuentre vigente, agrega la cancion correspondiente a la lista de favoritos
	 * @param idUsuario
	 * @param idArtista
	 * @param posicionCancion
	 */
	public void agregarFavoritoUsuario(long idUsuario, long idArtista, String nombreAlbum, int posicionCancion) {
		Usuario usuario = this.usuarios.get(idUsuario);
		Artista artista = this.artistas.get(idArtista);
		if (usuario instanceof UsuarioPago) {
			UsuarioPago uPago = (UsuarioPago)usuario;
			uPago.agregarFavorita(artista.buscarCancion(nombreAlbum, posicionCancion));
		}
	}

	@Override
	public String toString() {
		return "Objectify [\nartistas=" + artistas + ", \nconciertos=" + conciertos + ", \nusuarios=" + usuarios + "]";
	}

	/**
	 * Obtiene una copia de la lista de usuarios en el sistema.
	 * @return
	 */
	public Collection<Usuario> getUsuarios() {
		return new ArrayList<Usuario>(this.usuarios.values());
	}

	/**
	 * Obtiene una copia de la lista de artistas en el sistema.
	 * @return
	 */
	public Collection<Artista> getArtistas() {
		return new ArrayList<Artista>(this.artistas.values());
	}

	public Artista buscarArtistaPorId(long idArtista) {
		return this.artistas.get(idArtista);
	}

	public Usuario buscarUsuario(long id) {
		return this.usuarios.get(id);
	}

}


text:
<!doctype html>

    <title>Brython</title>
    <meta charset="UTF-8">
    <meta name=robots content="index, follow">
    <meta name=description content=Brython>
    <meta name=author content="Pierre Quentel">
    <meta name=keywords content="Python, Brython">
    <meta name=viewport content="width=device-width,initial-scale=1,maximum-scale=1">
    <link rel="icon" type="image/png" href="favicon.png" />
    Please enable Javascript to view this page correctly.
    <link rel=stylesheet href="doc/doc_brython.css">

Google Group (English)

Twitter @brython3

Brythonista (blog by Pierre Quentel)

IRC: #brython on freenode


text:
class Footprint < ActiveRecord::Base
  belongs_to :user
  belongs_to :post

  ######################################################################
  # Named scope
  ######################################################################
  scope :today, -> { where(arel_table[:created_at].gt 1.days.ago) }
end


text:
package nz.co.cyma.integrations.archigitsync.model.impl;

import java.util.ArrayDeque;
import java.util.Collection;
import java.util.Collections;
import java.util.Iterator;
import java.util.StringTokenizer;

import com.archimatetool.model.FolderType;

import nz.co.cyma.integrations.archigitsync.model.IFolderPath;

public class FolderPath implements IFolderPath, Cloneable {
	ArrayDeque<String> folderStack = new ArrayDeque<String>();
	private FolderType folderPathType = null;

	public FolderPath(FolderType folderPathType) {
		this.folderPathType = folderPathType;
	}

	public FolderPath(FolderType folderPathType, String folderPathString) {
		this.folderPathType = folderPathType;
		StringTokenizer dirs = new StringTokenizer(folderPathString, "/");
		while(dirs.hasMoreElements()) {
			this.addFolderToPath((String) dirs.nextElement());
		}
	}

	@Override
	public String getPathAsString() {
		String fullPath = null;

		//need to reverse the order when getting as a string...
		Iterator<String> i = folderStack.descendingIterator();

		while(i.hasNext()) {
			String currentFolder = i.next();
			if(fullPath ==null)
				fullPath = currentFolder;
			else
				fullPath = fullPath + "/" + currentFolder;
		}

		return (fullPath==null?"":fullPath);
	}//getPathAsString

	public String [] getPathAsArray() {
		String [] folders = new String[folderStack.size()];

		//need to reverse the order when getting as a string...
		Iterator<String> i = folderStack.descendingIterator();
		int ctr = 0;

		while(i.hasNext()) {
			folders[ctr] = i.next();
			ctr++;
		}

		return folders;
	}

	@Override
	public String getBottomFolder() {
		// TODO Auto-generated method stub
		return (folderStack.peekLast()==null?"":folderStack.peekLast());
	}

	@Override
	public String addFolderToPath(String folderName) {
		folderStack.push(folderName);
		return this.getPathAsString();
	}

	@Override
	public String moveUpFolderTree() {
		folderStack.pop();
		return this.getPathAsString();
	}

	@Override
	public String getFolderPathTypeAsString() {
		return this.folderPathType.getName();
	}

	@Override
	protected Object clone() throws CloneNotSupportedException {
		return super.clone();
	}

	public IFolderPath clonePath() {
		try {
			return (FolderPath) this.clone();
		} catch (CloneNotSupportedException e) {
			e.printStackTrace();
			return null;
		}
	}

}


text:
<!Doctype html>

<title>Week Blogs</title>

My blog posts

Home

About

Contact

blog1

blog2

blog3

blog4

blog5

blog6

blog7

blog8

blog9


text:
use strict;
use warnings;
my $readname;
while (<>) {
    my $original_line = $_;
    if (substr($original_line, 0, 1) ne "@") {
        my @fields = split("\t", $original_line);
	print "__\n" if defined $readname && $readname ne $fields[0];
        $readname = $fields[0];
    }
    print $original_line;
}


text:
<?php

namespace Faker\Provider\me_ME;

class Address extends \Faker\Provider\Address
{
    protected static $postcode = array('#####');

    protected static $streetPrefix = array(
        '',
    );

    /**
     * @link http://podgorica.mapa.in.rs/
     */
    protected static $street = array(
        '1. crnogorske brigade narodne odbrane', '1. maja', '1. proleterske brigade', '10. crnogorske brigade', '13. jula', '18. februara', '18. jula', '19. decembra', '2. crnogorskog bataljona', '2. proleterske dalmatinske brigade', '27. marta', '3. sandžačke proleterske brigade', '4. jula', '4. proleterske brigade', '5. proleterske brigade', '6. crnogorske udarne brigade', '7. omladinske brigade', '8. crnogorske udarne brigade', '8. jula', '8. marta', '9. crnogorske brigade',
        'Admirala Zmajevića', 'Aerodromska', 'Aleksandra Ace Prijića', 'Aleksandra Lesa Ivanovića', 'Aleksandra Puškina', 'Alekse Šantića', 'Alfreda Tenisona', 'Andrije Paltašića', 'Andrijevička', 'Antona Čehova', 'Arhitekte Milana Popovića', 'Arsenija Čarnojevića', 'Atinska', 'AVNOJ-a',
        'Balkanska', 'Balšića', 'Barska', 'Belvederska', 'Beogradska', 'Berska', 'Bjelasička', 'Bjelopoljska', 'Blaža Jovanovića', 'Bohinjska', 'Bokeljske mornarice', 'Bokeška', 'Bore i Ramiza', 'Borisa Kidriča', 'Boška Buhe', 'Botunska', 'Bracana Bracanovića', 'Braće Ribar', 'Branislava Lekića', 'Branka Ćopića', 'Branka Deletića', 'Branka Radičevića', 'Bratonožićka', 'Bratstva i jedinstva', 'Bregalnička', 'Buda Tomovića', 'Budvanska', 'Bulevar Džordža Vašingtona', 'Bulevar Ivana Crnojevića', 'Bulevar Mihaila Lalića', 'Bulevar revolucije', 'Bulevar Save Kovačevića',
        'Cara Lazara', 'Carev laz', 'Ceklinska', 'Cetinjski put', 'Crnogorskih serdara', 'Crnojevića', 'Cvijetna',
        'Dajbabska', 'Dalmatinska', 'Danilovgradska', 'Desanke Maksimović', 'Dositeja Obradovića', 'Dr Blaža Raičevića', 'Dr Filipa Šoća', 'Dr Milutina Kažića', 'Dr Nika Miljanića', 'Dr Saše Božovića', 'Drvarska', 'Dukljanska', 'Dunavska', 'Durmitorska', 'Dušana Duće Mugoše', 'Dušana Milutinovića', 'Dušana Vukotića', 'Džan', 'Đečevića', 'Đoka Miraševića', 'Đuje Jovanovića', 'Đure Daničića',
        'Emila Zole', 'Franca Prešerna', 'Franca Rozmana', 'Fruškogorska', 'Fundinske bitke',
        'Gavra Vukovića', 'Gavrila Principa', 'Generala Sava Orlovića', 'Georgi Dimitrova', 'Geteova', 'Goce Delčeva', 'Gojka Radonjića', 'Goranska', 'Gorička', 'Grahovačka',
        'Hajduk Veljkova', 'Hercegnovska', 'Hercegovačka', 'Husinskih rudara',
        'Igmanska', 'Ilije Milačića', 'Isidore Sekulić', 'Ivana Cankara', 'Ivana Gorana Kovačića', 'Ivana Milutinovića', 'Ivana Vujoševića', 'Ivangradska', 'Ive Andrića', 'Iveze Vukova',
        'Jadranska', 'Janka Đanovića', 'Janka Vukotića', 'Jaroslava Čermaka', 'Jelene Balšić', 'Jerevanska', 'Jezerska', 'Josipa Broza Tita', 'Jovana Cvijića', 'Jovana Ćetkovića', 'Jovana Tomaševića',
        'Kadinjača', 'Karađorđeva', 'Kninska', 'KNOJ-a', 'Kolašinska', 'Komska', 'Kosmajska', 'Kosovska', 'Kosovskih junaka', 'Koste Racina', 'Kotorska', 'Kozaračka', 'Kragujevačka', 'Kralja Nikole', 'Kraljevačka',
        'Lamela', 'Lazara Sočice', 'Lička', 'Lovćenska', 'Ludviga Kube', 'Luke Boljevića', 'Lutovačkih barjaktara', 'Ljesanska', 'Ljeskopoljska', 'Ljube Čupića', 'Ljube Nenadovića', 'Ljubljanska', 'Ljubostinjskih junaka', 'Ljubovićka',
        'Majevička', 'Manastirska', 'Marka Mašanovića', 'Marka Miljanova', 'Matije Gupca', 'Mediteranska', 'Medunska', 'Meše Selimovića', 'Mila Milunovića', 'Mila Peruničića', 'Mila Radunovića', 'Miladina Popovića', 'Milana Kuča', 'Milana Raičkovića', 'Miloja Pavlovića', 'Miloša Obilića', 'Miljana Vukova', 'Miodraga Bulatovića', 'Mirka Banjevića', 'Mirka Vešovića', 'Mitra Bakića', 'Mojkovačka', 'Mojsija Zečevića', 'Moračka', 'Moskovska', 'Moskovski most', 'Mosorska', 'Most Milenijum', 'Most žrtava 5. maja 1944.', 'Mušikića',
        'Neznanih junaka', 'Nikca od Rovina', 'Nikole Đurkovića', 'Nikole Lopičića', 'Nikole Tesle', 'Nikšićka', 'Novaka Miloševa', 'Novaka Ramova', 'Novosadska', 'Njegoševa',
        'Obala Ribnice', 'Obodska', 'Ohridska', 'Oktobarske revolucije', 'Omera Abdovića', 'Omladinskih brigada', 'Orijenska',
        'Pariske komune', 'Partizanski put', 'Pera Počeka', 'Perojska', 'Petra Kočića', 'Petra Lubarde', 'Petra Prlje', 'Pilota Cvetkovića i Milojevića', 'Piperska', 'Pivska', 'Plavska', 'Plitvička', 'Plužinska', 'Pljevaljska', 'Pohorska', 'Polimska', 'Popa Boška Popovića', 'Predraga Golubovića', 'Princa Mihaila Petrovića', 'Prištinska', 'Prolaz Generala Dožića',
        'Radnička', 'Radoja Jovanovića', 'Radomira Ivanovića', 'Radosava Burića', 'Radosava Popovića', 'Radovana Petrovića', 'Radovana Vukanovića', 'Radovana Zogovića', 'Radula Rusa Radulovića', 'Rista Stijovića', 'Rogamska', 'Rovačka', 'Ruža',
        'Sarajevska', 'Sava Lubarde', 'Sava Nikolića', 'Savska', 'Serdara Jola Piletića', 'Sergeja Jesenjina', 'Sime Matavulja', 'Simona Ivanova', 'Sitnička', 'Skadarska', 'SKOJ-a', 'Skopska', 'Slavonska', 'Slobodana Škerovića', 'Slobode', 'Sloge', 'Spasa Nikolića', 'Spasoja Raspopovića', 'Srednjoškolska', 'Stanka Dragojevića', 'Stefana Mitrova Ljubiše', 'Steva Boljevića', 'Steva Kraljevića', 'Studentska', 'Svetog Petra Cetinjskog', 'Svetozara Markovića', 'Šarkića', 'Šavnička', 'Španskih boraca', 'Špira Mugoše',
        'Tivatska', 'Trebinjska', 'Trg Božane Vučinić', 'Trg golootočkih žrtava', 'Trg Nikole Kovačevića', 'Trg republike', 'Trifuna Đukića', 'Triglavska', 'Tripa Kukolja', 'Tuška',
        'Ulcinjska', 'Užička',
        'Valtazara Bogišića', 'Vardarska', 'Vasa Raičkovića', 'Velimira Stojanovića', 'Velimira Terzića', 'Veljka Jankovića', 'Vezirov most', 'Vinogradska', 'Vitomira Vita Nikolića', 'Vlada Ćetkovića', 'Vlada Martinovića', 'Vladike Danila', 'Vladike Petra I', 'Vladike Vasilija Petrovića', 'Vojisavljevića', 'Vojislava Grujića', 'Vojvode Ilije Plamenca', 'Vojvode Mijajla Nišina', 'Vojvode Mirka Petrovića', 'Vojvode Raduna', 'Vojvode Vase Bracanova', 'Vojvođanska', 'Vrela 2.', 'Vrela 3.', 'Vrela 4.', 'Vrela 5.', 'Vrela 6.', 'Vučedolska', 'Vuka Đurovića', 'Vuka Karadžića', 'Vuka Mandušića', 'Vuka Mićunovića', 'Vukice Mitrović', 'Vukosava Božovića',
        'Zagrebačka', 'Zetskih vladara', 'Zetskog odreda', 'Zmaj Jovina', 'Žabljačka', 'Žarka Zrenjanina', 'Žikice Jovanovića Španca', 'Žrtava fašizma',
    );

    protected static $streetNameFormats = array(
        '{{street}}',
        '{{streetPrefix}} {{street}}',
    );

    protected static $streetAddressFormats = array(
        '{{streetName}} {{buildingNumber}}',
    );

    protected static $cityFormats = array(
        '{{cityName}}',
    );

    /**
     * @link http://sh.wikipedia.org/wiki/Popis_gradova_u_Crnoj_Gori
     */
    protected static $cityNames = array(
       'Bar', 'Budva', 'Herceg Novi',
       'Kotor', 'Tivat', 'Ulcinj', 'Podgorica',
       'Cetinje', 'Nikšić', 'Danilovgrad', 'Žabljak',
       'Kolašin', 'Andrijevica', 'Berane', 'Bijelo Polje',
       'Mojkovac', 'Plav', 'Plužine', 'Pljevlja', 'Rožaje',
       'Šavnik', 'Petnjica', 'Gusinje', 'Petrovac','Sutomore',
    );

    /**
     * @link https://github.com/umpirsky/country-list/blob/master/country/cldr/sr_Latn/country.php
     */
    protected static $country = array(
        'Alandska ostrva', 'Albanija', 'Alžir', 'Američka Samoa', 'Andora', 'Angola', 'Angvila', 'Antarktika', 'Antigva i Barbuda', 'Argentina', 'Armenija', 'Aruba', 'Australija', 'Austrija', 'Avganistan', 'Azerbejdžan',
        'Bahami', 'Bahrein', 'Bangladeš', 'Barbados', 'Belgija', 'Belise', 'Belorusija', 'Benin', 'Bermuda', 'Bocvana', 'Bolivija', 'Bosna i Hercegovina', 'Božićna Ostrva', 'Brazil', 'Britanska Devičanska Ostrva', 'Britansko Indijska Okeanska Teritorija', 'Brunej', 'Bugarska', 'Burkina Faso', 'Burundi', 'Butan', 'Buve Ostrva',
        'Čad', 'Centralno Afrička Republika', 'Češka', 'Čile',
        'Crna Gora',
        'Danska', 'Demokratska Republika Kongo', 'Dijego Garsija', 'Dominika', 'Dominikanska Republika',
        'Džersi', 'Džibuti',
        'Egipat', 'Ekvador', 'Ekvatorijalna Gvineja', 'Eritreja', 'Estonija', 'Etiopija', 'Evropska unija',
        'Farska Ostrva', 'Fidži', 'Filipini', 'Finska', 'Folklandska Ostrva', 'Francuska', 'Francuska Gvajana', 'Francuska Polinezija', 'Francuske Južne Teritorije',
        'Gabon', 'Gambija', 'Gana', 'Gibraltar', 'Grčka', 'Grenada', 'Grenland', 'Gruzija', 'Guam', 'Gurnsi', 'Gvadelupe', 'Gvajana', 'Gvatemala', 'Gvineja', 'Gvineja-Bisao',
        'Haiti', 'Herd i Mekdonald Ostrva', 'Holandija', 'Holandski Antili', 'Honduras', 'Hong Kong (S. A. R. Kina)', 'Hrvatska',
        'Indija', 'Indonezija', 'Irak', 'Iran', 'Irska', 'Island', 'Istočni Timor', 'Italija', 'Izrael',
        'Jamajka', 'Japan', 'Jemen', 'Jordan', 'Južna Džordžija i Južna Sendvič Ostrva', 'Južna Koreja', 'Južnoafrička Republika',
        'Kajmanska Ostrva', 'Kambodža', 'Kamerun', 'Kanada', 'Kanarska ostrva', 'Kape Verde', 'Katar', 'Kazahstan', 'Kenija', 'Kina', 'Kipar', 'Kirgizstan', 'Kiribati', 'Kokos (Keling) Ostrva', 'Kolumbija', 'Komorska Ostrva', 'Kongo', 'Kostarika', 'Kuba', 'Kukova Ostrva', 'Kuvajt',
        'Laos', 'Lesoto', 'Letonija', 'Liban', 'Liberija', 'Libija', 'Lihtenštajn', 'Litvanija', 'Luksemburg',
        'Madagaskar', 'Mađarska', 'Majote', 'Makao (S. A. R. Kina)', 'Makedonija', 'Malavi', 'Maldivi', 'Malezija', 'Mali', 'Malta', 'Manja Udaljena Ostrva SAD', 'Maroko', 'Maršalska Ostrva', 'Martinik', 'Mauricius', 'Mauritanija', 'Meksiko', 'Mijanmar', 'Mikronezija', 'Moldavija', 'Monako', 'Mongolija', 'Monserat', 'Mozambik',
        'Namibija', 'Nauru', 'Nemačka', 'Nepal', 'Niger', 'Nigerija', 'Nikaragva', 'Niue', 'Norfolk Ostrvo', 'Norveška', 'Nova Kaledonija', 'Novi Zeland',
        'Obala Slonovače', 'Oman', 'Ostala okeanija', 'Ostrvo Asension', 'Ostrvo Kliperton', 'Ostrvo Man',
        'Pakistan', 'Palau', 'Palestinska Teritorija', 'Panama', 'Papua Nova Gvineja', 'Paragvaj', 'Peru', 'Pitcairn', 'Poljska', 'Porto Riko', 'Portugal',
        'Rejunion', 'Ruanda', 'Rumunija', 'Rusija',
        'S.A.D. Devičanska Ostrva', 'Salvador', 'Samoa', 'San Marino', 'Sao Tome i Principe', 'Saudijska Arabija', 'Sejšeli', 'Sen Pjer i Mikelon', 'Senegal', 'Sent Kits i Nevis', 'Sent Lucija', 'Sent Vinsent i Grenadini', 'Seuta i Melilja', 'Severna Koreja', 'Severna Marijanska Ostrva', 'Sijera Leone', 'Singapur', 'Sirija', 'Sjedinjene Američke Države', 'Slovačka', 'Slovenija', 'Solomonska Ostrva', 'Somalija',
        'Španija', 'Srbija', 'Šri Lanka', 'Sudan', 'Surinam', 'Sv. Bartolomej', 'Sv. Martin', 'Švajcarska', 'Svalbard i Janmajen Ostrva', 'Svazilend', 'Švedska', 'Sveta Jelena',
        'Tadžikistan', 'Tajland', 'Tajvan', 'Tanzanija', 'Togo', 'Tokelau', 'Tonga', 'Trinidad i Tobago', 'Tristan da Kunja', 'Tunis', 'Turkmenistan', 'Turks i Kajkos Ostrva', 'Turska', 'Tuvalu',
        'Uganda', 'Ujedinjeni Arapski Emirati', 'Ukrajina', 'Urugvaj', 'Uzbekistan',
        'Valis i Futuna Ostrva', 'Vanuatu', 'Vatikan', 'Velika Britanija', 'Venecuela', 'Vijetnam',
        'Zambija', 'Zapadna Sahara', 'Zimbabve',
    );

    public static function streetPrefix()
    {
        return static::randomElement(static::$streetPrefix);
    }

    public static function street()
    {
        return static::randomElement(static::$street);
    }

    public function cityName()
    {
        return static::randomElement(static::$cityNames);
    }

    public static function localCoordinates()
    {
        return array(
            'latitude' => static::latitude(42.43, 42.45),
            'longitude' => static::longitude(19.16, 19.27)
        );
    }
}


text:
Give your Jekyll posts and pages multiple URLs.

When importing your posts and pages from, say, Tumblr, it's annoying and
impractical to create new pages in the proper subdirectories so they, e.g.
`/post/123456789/my-slug-that-is-often-incompl`, redirect to the new post URL.

Instead of dealing with maintaining those pages for redirection, let
`jekyll-redirect-from` handle it for you.

[![Build Status](https://travis-ci.org/jekyll/jekyll-redirect-from.svg?branch=master)](https://travis-ci.org/jekyll/jekyll-redirect-from)

## How it Works

Redirects are performed by serving an HTML file with an HTTP-REFRESH meta
tag which points to your destination. No `.htaccess` file, nginx conf, xml
file, or anything else will be generated. It simply creates HTML files.

## Installation

Add this line to your application's Gemfile:

    gem 'jekyll-redirect-from'

And then execute:

    $ bundle

Or install it yourself as:

    $ gem install jekyll-redirect-from

Once it's installed into your evironment, add it to your `_config.yml`:

```yaml
plugins:
  - jekyll-redirect-from
```

💡 If you are using a Jekyll version less than 3.5.0, use the `gems` key instead of `plugins`.

If you're using Jekyll in `safe` mode to mimic GitHub Pages, make sure to
add jekyll-redirect-from to your whitelist:

```yaml
whitelist:
  - jekyll-redirect-from
```

Then run `jekyll <cmd> --safe` like normal.

## Usage

The object of this gem is to allow an author to specify multiple URLs for a
page, such that the alternative URLs redirect to the new Jekyll URL.

To use it, simply add the array to the YAML front-matter of your page or post:

```yaml
title: My amazing post
redirect_from:
  - /post/123456789/
  - /post/123456789/my-amazing-post/
```

Redirects including a trailing slash will generate a corresponding subdirectory containing an `index.html`, while redirects without a trailing slash will generate a corresponding `filename` without an extension, and without a subdirectory.

For example...

```text
redirect_from:
  - /post/123456789/my-amazing-post
```

...will generate the following page in the destination:

```text
/post/123456789/my-amazing-post
```

While...

```text
redirect_from:
  - /post/123456789/my-amazing-post/
```

...will generate the following page in the destination:

```text
/post/123456789/my-amazing-post/index.html
```

These pages will contain an HTTP-REFRESH meta tag which redirect to your URL.

You can also specify just **one url** like this:

```text
title: My other awesome post
redirect_from: /post/123456798/
```

### Prefix

If `site.url` is set, its value, together with `site.baseurl`, is used as a prefix for the redirect url automatically. This is useful for scenarios where a site isn't available from the domain root, so the redirects point to the correct path. If `site.url` is not set, only `site.baseurl` is used, if set.

**_Note_**: If you are hosting your Jekyll site on [GitHub Pages](https://pages.github.com/), and `site.url` is not set, the prefix is set to the pages domain name i.e. http://example.github.io/project or a custom CNAME.

### Redirect To

Sometimes, you may want to redirect a site page to a totally different website. This plugin also supports that with the `redirect_to` key:

```yaml
title: My amazing post
redirect_to:
  - http://www.github.com
```

If you have multiple `redirect_to`s set, only the first one will be respected.

**Note**: Using `redirect_to` or `redirect_from` with collections will only work with files which are output to HTML, such as `.md`, `.textile`, `.html` etc.

## Customizing the redirect template

If you want to customize the redirect template, you can. Simply create a layout in your site's `_layouts` directory called `redirect.html`.

Your layout will get the following variables:

* `page.redirect.from` - the relative path to the redirect page
* `page.redirect.to` - the absolute URL (where available) to the target page

## Contributing

1. Fork it
2. Create your feature branch (`git checkout -b my-new-feature`)
3. Commit your changes (`git commit -am 'Add some feature'`)
4. Push to the branch (`git push origin my-new-feature`)
5. Create new Pull Request


text:
'use strict'
var test = require('test-runner')
var detect = require('feature-detect-es6')
var a = require('core-assert')
var Definitions

if (detect.all('class', 'arrowFunction', 'newArrayFeatures')) {
  Definitions = require('../lib/definitions')
} else {
  require('core-js/es6/array')
  Definitions = require('../es5/definitions')
}

test('.createOutput()', function () {
  var definitions = new Definitions([ { name: 'one', defaultValue: 'eins' } ])
  a.deepStrictEqual(definitions.createOutput(), { one: 'eins' })
})

test('.get()', function () {
  var definitions = new Definitions([ { name: 'one', defaultValue: 'eins' } ])
  a.strictEqual(definitions.get('--one').name, 'one')
})

test('.validate()', function () {
  a.throws(function () {
    var definitions = new Definitions([ { name: 'one' }, { name: 'one' } ])
  })
})


text:
import * as React from "react";
import ReactToolbox from "../index";
import { InputProps, InputTheme } from "../input/Input";

export interface AutocompleteTheme {
  /**
   * Used for a suggestion when it's active.
   */
  active?: string;
  /**
   * Used for the root element.
   */
  autocomplete?: string;
  /**
   * Used when the input is focused.
   */
  focus?: string;
  /**
   * Used to style the Input component.
   */
  input?: string;
  /**
   * Used to style each suggestion.
   */
  suggestion?: string;
  /**
   * Used to style the suggestions container.
   */
  suggestions?: string;
  /**
   * Used for the suggestions when it's opening to the top.
   */
  up?: string;
  /**
   * Classname used for a single value.
   */
  value?: string;
  /**
   * Classname used for the values container.
   */
  values?: string;
}

export interface AutocompleteProps extends InputProps {
  /**
   * Determines if user can create a new option with the current typed value.
   * @default false
   */
  allowCreate?: boolean;
  /**
   * Determines the opening direction. It can be auto, up or down.
   * @default auto
   */
  direction?: "auto" | "up" | "down";
  /**
   * If true, component will be disabled.
   * @default false
   */
  disabled?: boolean;
  /**
   * Sets the error string for the internal input element.
   * @default false
   */
  error?: React.ReactNode;
  /**
   * Whether component should keep focus after value change.
   * @default false
   */
  keepFocusOnChange?: boolean;
  /**
   * The text string to use for the floating label element.
   */
  label?: React.ReactNode;
  /**
   * If true, component can hold multiple values.
   * @default true
   */
  multiple?: boolean;
  /**
   * Callback function that is fired when component is blurred.
   */
  onBlur?: Function;
  /**
   * Callback function that is fired when the components's value changes.
   */
  onChange?: Function;
  /**
   * Callback function that is fired when component is focused.
   */
  onFocus?: Function;
  /**
   * Callback function that is fired when a key is pressed down.
   */
  onKeyDown?: Function;
  /**
   * Callback function that is fired when a key is lifted up.
   */
  onKeyUp?: Function;
  /**
   * Callback function that is fired when the components's query value changes.
   */
  onQueryChange?: Function;
  /**
   * Determines if the selected list is shown above or below input. It can be above or below.
   * @default above
   */
  selectedPosition?: "above" | "below" | "none";
  /**
   * Determines if the selected list is shown if the `value` keys don't exist in the source. Only works if passing the `value` prop as an Object.
   * @default false
   */
  showSelectedWhenNotInSource?: boolean;
  /**
   * If true, the list of suggestions will not be filtered when a value is selected.
   * @default false
   */
  showSuggestionsWhenValueIsSet?: boolean;
  /**
   * Object of key/values or array representing all items suggested.
   */
  source?: any;
  /**
   * Determines how suggestions are supplied.
   * @default start
   */
  suggestionMatch?: "disabled" | "start" | "anywhere" | "word";
  /**
   * Classnames object defining the component style.
   */
  theme?: AutocompleteTheme & InputTheme;
  /**
   * Value or array of values currently selected component.
   */
  value?: any;
  /**
   * Additional properties passed to inner Input component.
   */
  [key: string]: any;
}

export class Autocomplete extends React.Component<AutocompleteProps, {}> { }

export default Autocomplete;


text:
namespace WinBlocks.Game.Model
{
    public class Location
    {
        public int X { get; set; }
        public int Y { get; set; }

        public override bool Equals(object obj)
        {
            return Equals(obj as Location);
        }

        protected bool Equals(Location other)
        {
            return X == other.X && Y == other.Y;
        }

        public Location From(Delta delta)
        {
            return new Location {X = X + delta.X, Y = Y + delta.Y};
        }
    }
}


text:
'use strict';

/*
 * Module Definition
 *
 */

import React from 'react';

/*
 * Class Definition
 *
 */

class GoogleMap extends React.Component {
  constructor(props) {
    super(props);

    console.log(props)
  }

  /*
   * componentDidMount
   *
   */

  componentDidMount() {

  }

  /*
   * componentDidUpdate
   *
   */

  componentDidUpdate(prevProps, prevState) {

  }

  /*
   * render
   *
   */

  render() {
    return
GoogleMap
;
  }
}

/*
 * Module Export
 *
 */

export default GoogleMap;


text:
@interface KYAActivationDurationTests : XCTestCase
@end

@implementation KYAActivationDurationTests

- (void)testIndefiniteActivationDuration
{
    Auto duration = KYAActivationDuration.indefiniteActivationDuration;
    XCTAssertEqual(duration.seconds, KYAActivationDurationIndefinite);
    XCTAssertEqualObjects(duration, KYAActivationDuration.indefiniteActivationDuration);
}

- (void)testSecondsInitializer
{
    NSTimeInterval expectedSeconds = 3400.0f;
    Auto duration = [[KYAActivationDuration alloc] initWithSeconds:expectedSeconds];
    XCTAssertEqual(duration.seconds, expectedSeconds);
}

- (void)testHoursMinutesSecondsInitializer
{
    NSTimeInterval expectedSeconds = 30615;
    Auto duration = [[KYAActivationDuration alloc] initWithHours:8 minutes:30 seconds:15];
    XCTAssertEqual(duration.seconds, expectedSeconds);
}

- (void)testEquatable
{
    NSTimeInterval expectedSeconds = 30615;
    XCTAssertEqualObjects([[KYAActivationDuration alloc] initWithSeconds:expectedSeconds],
                          [[KYAActivationDuration alloc] initWithSeconds:expectedSeconds]);
    XCTAssertTrue([[[KYAActivationDuration alloc] initWithSeconds:expectedSeconds]
                   isEqualToActivationDuration:[[KYAActivationDuration alloc]
                                                initWithSeconds:expectedSeconds]]);
    XCTAssertFalse([[[KYAActivationDuration alloc] initWithSeconds:expectedSeconds]
                   isEqualToActivationDuration:[[KYAActivationDuration alloc]
                                                initWithSeconds:0]]);
}

- (void)testArchiving
{
    NSTimeInterval expectedSeconds = 30615;
    Auto duration = [[KYAActivationDuration alloc] initWithSeconds:expectedSeconds];
    NSError *error;
    Auto data = [NSKeyedArchiver archivedDataWithRootObject:duration requiringSecureCoding:YES error:&error];
    XCTAssertNotNil(data);
    XCTAssertNil(error);

    Auto unarchivedDuration = (KYAActivationDuration *)[NSKeyedUnarchiver
                                                        unarchivedObjectOfClass:[KYAActivationDuration class]
                                                        fromData:data
                                                        error:&error];
    XCTAssertNotNil(unarchivedDuration);
    XCTAssertNil(error);
    XCTAssertEqualObjects(duration, unarchivedDuration);
}

- (void)testDefaultActivationDurations
{
    Auto durations = KYAActivationDuration.defaultActivationDurations;
    XCTAssertEqual(durations.count, 7);
    XCTAssertEqual(durations[0].seconds, 300.0f);
    XCTAssertEqual(durations[1].seconds, 600.0f);
    XCTAssertEqual(durations[2].seconds, 900.0f);
    XCTAssertEqual(durations[3].seconds, 1800.0f);
    XCTAssertEqual(durations[4].seconds, 3600.0f);
    XCTAssertEqual(durations[5].seconds, 7200.0f);
    XCTAssertEqual(durations[6].seconds, 18000.0f);
}

@end


text:
package org.zalando.nakadi.exceptions.runtime;

public class DuplicatedTimelineException extends NakadiBaseException {

    public DuplicatedTimelineException(final String msg, final Exception cause) {
        super(msg, cause);
    }

}


text:
SET NOCOUNT ON
DECLARE @SQL VARCHAR(MAX)
DECLARE @ObjectType SYSNAME
DECLARE @ObjectSchema SYSNAME
DECLARE @ObjectName SYSNAME

PRINT 'Uninstalling procedures'
IF OBJECT_ID('TempDb..#R') IS NOT NULL DROP TABLE #R
SELECT
 ROW_NUMBER() OVER (ORDER BY ROUTINE_SCHEMA) AS RowId
,ROUTINE_SCHEMA
,ROUTINE_NAME
,ROUTINE_TYPE
INTO #R
FROM INFORMATION_SCHEMA.ROUTINES
WHERE ROUTINE_SCHEMA IN  ('Logger', 'LoggerBase', 'loggerbasetests')

DECLARE @Counter INT = 1
WHILE EXISTS (SELECT * FROM #R)
BEGIN
	SELECT @ObjectName = ROUTINE_NAME
	,@ObjectSchema = ROUTINE_SCHEMA
	,@ObjectType = ROUTINE_TYPE
	FROM #R
	WHERE 1=1
	AND RowID = @Counter

	SELECT @SQL = CONCAT('DROP ', @ObjectType, ' [', @ObjectSchema, '].[', @ObjectName, ']')
	DELETE FROM #R WHERE RowID = @Counter
	PRINT @SQL
	BEGIN TRY
		EXEC(@SQL)
	END TRY
	BEGIN CATCH
		INSERT INTO #T
		SELECT MAX(RowId) + 1
		,@ObjectSchema
		,@ObjectName
		,@ObjectType
		FROM #R
	END CATCH

	SELECT @Counter = MIN(RowId) FROM #R

END

PRINT 'Uninstalling tables. LoggerBase.Config_Saved will remain. You will need to remove it manually if desired.'
IF OBJECT_ID('TempDb..#T') IS NOT NULL DROP TABLE #T
SELECT
 ROW_NUMBER() OVER (ORDER BY TABLE_SCHEMA) AS RowId
 ,TABLE_SCHEMA
 ,TABLE_NAME
 ,IIF(TABLE_TYPE = 'BASE TABLE', 'TABLE', TABLE_TYPE) AS TABLE_TYPE
INTO #T
FROM INFORMATION_SCHEMA.TABLES
WHERE TABLE_SCHEMA IN ('Logger', 'LoggerBase')
AND TABLE_NAME <> 'Config_Saved'

SET @Counter = 1

WHILE EXISTS (SELECT * FROM #T)
BEGIN
	SELECT @ObjectName = TABLE_NAME
	,@ObjectSchema     = TABLE_SCHEMA
	,@ObjectType       = TABLE_TYPE
	FROM #T
	WHERE 1=1
	AND RowID = @Counter

	SELECT @SQL = CONCAT('DROP ', @ObjectType, ' [', @ObjectSchema, '].[', @ObjectName, ']')
	DELETE FROM #T WHERE RowID = @Counter
	PRINT @SQL
	BEGIN TRY
		EXEC(@SQL)
	END TRY
	BEGIN CATCH
		INSERT INTO #T
		SELECT MAX(RowId) + 1
		,@ObjectSchema
		,@ObjectName
		,@ObjectType
		FROM #T
	END CATCH

	SELECT @Counter = MIN(RowId) FROM #T

END

PRINT 'Uninstalling CLR assemblies'
IF EXISTS (SELECT * FROM sys.assemblies WHERE 1=1 AND name = 'log4mssql') DROP ASSEMBLY [log4mssql]

PRINT 'Uninstalling User-Defined types'
IF EXISTS (SELECT * FROM sys.types WHERE name = 'LogConfiguration') DROP TYPE LogConfiguration

PRINT 'Uninstalling Logger schema. LoggerBase is required by LoggerBase.Config_Saved. You will need to remove it manually if desired.'
IF EXISTS (SELECT * FROM sys.schemas WHERE name = 'Logger') DROP SCHEMA Logger
IF EXISTS (SELECT * FROM sys.schemas WHERE name = 'loggerbasetests') DROP SCHEMA loggerbasetests


text:
@echo off

rem  Vivado (TM)
rem  runme.bat: a Vivado-generated Script
rem  Copyright 1986-2015 Xilinx, Inc. All Rights Reserved.

set HD_SDIR=%~dp0
cd /d "%HD_SDIR%"
set PATH=%SYSTEMROOT%\system32;%PATH%
cscript /nologo /E:JScript "%HD_SDIR%\rundef.js" %*


text:
<?php
namespace Craft;

class ColorFieldType extends BaseFieldType
{
	// Public Methods
	// =========================================================================

	/**
	 * @inheritDoc IComponentType::getName()
	 *
	 * @return string
	 */
	public function getName()
	{
		return Craft::t('Color');
	}

	/**
	 * @inheritDoc IFieldType::defineContentAttribute()
	 *
	 * @return mixed
	 */
	public function defineContentAttribute()
	{
		return array(AttributeType::String, 'column' => ColumnType::Char, 'length' => 7);
	}

	/**
	 * @inheritDoc IFieldType::getInputHtml()
	 *
	 * @param string $name
	 * @param mixed  $value
	 *
	 * @return string
	 */
	public function getInputHtml($name, $value)
	{
		// Default to black, so the JS-based color picker is consistent with Chrome
		if (!$value)
		{
			$value = '#000000';
		}

		return craft()->templates->render('_includes/forms/color', array(
			'id'    => craft()->templates->formatInputId($name),
			'name'  => $name,
			'value' => $value,
		));
	}

	/**
	 * @inheritDoc BaseFieldType::getStaticHtml()
	 *
	 * @param mixed $value
	 *
	 * @return string
	 */
	public function getStaticHtml($value)
	{
		if ($value)
		{
			return HtmlHelper::encodeParams('

'.
				'
{bgColor}
', array('bgColor' => $value));
		}
	}
}


text:
<?php

namespace Magento\Wishlist\Model;

use Magento\Catalog\Model\Product\Exception as ProductException;
use Magento\Checkout\Helper\Cart as CartHelper;
use Magento\Checkout\Model\Cart;
use Magento\Customer\Model\Session;
use Magento\Framework\App\Response\RedirectInterface;
use Magento\Framework\Exception\LocalizedException;
use Psr\Log\LoggerInterface as Logger;
use Magento\Framework\Message\ManagerInterface as MessageManager;
use Magento\Framework\UrlInterface;
use Magento\Wishlist\Helper\Data as WishlistHelper;

/**
 * @SuppressWarnings(PHPMD.CouplingBetweenObjects)
 */
class ItemCarrier
{
    /**
     * @var \Magento\Customer\Model\Session
     */
    protected $customerSession;

    /**
     * @var LocaleQuantityProcessor
     */
    protected $quantityProcessor;

    /**
     * @var \Magento\Checkout\Model\Cart
     */
    protected $cart;

    /**
     * @var \Psr\Log\LoggerInterface
     */
    protected $logger;

    /**
     * @var \Magento\Wishlist\Helper\Data
     */
    protected $helper;

    /**
     * @var \Magento\Checkout\Helper\Cart
     */
    protected $cartHelper;

    /**
     * @var \Magento\Framework\UrlInterface
     */
    protected $urlBuilder;

    /**
     * @var \Magento\Framework\Message\ManagerInterface
     */
    protected $messageManager;

    /**
     * @var \Magento\Framework\App\Response\RedirectInterface
     */
    protected $redirector;

    /**
     * @param Session $customerSession
     * @param LocaleQuantityProcessor $quantityProcessor
     * @param Cart $cart
     * @param Logger $logger
     * @param WishlistHelper $helper
     * @param CartHelper $cartHelper
     * @param UrlInterface $urlBuilder
     * @param MessageManager $messageManager
     * @param RedirectInterface $redirector
     */
    public function __construct(
        Session $customerSession,
        LocaleQuantityProcessor $quantityProcessor,
        Cart $cart,
        Logger $logger,
        WishlistHelper $helper,
        CartHelper $cartHelper,
        UrlInterface $urlBuilder,
        MessageManager $messageManager,
        RedirectInterface $redirector
    ) {
        $this->customerSession = $customerSession;
        $this->quantityProcessor = $quantityProcessor;
        $this->cart = $cart;
        $this->logger = $logger;
        $this->helper = $helper;
        $this->cartHelper = $cartHelper;
        $this->urlBuilder = $urlBuilder;
        $this->messageManager = $messageManager;
        $this->redirector = $redirector;
    }

    /**
     * Move all wishlist item to cart
     *
     * @param Wishlist $wishlist
     * @param array $qtys
     * @return string
     * @SuppressWarnings(PHPMD.CyclomaticComplexity)
     * @SuppressWarnings(PHPMD.NPathComplexity)
     * @SuppressWarnings(PHPMD.ExcessiveMethodLength)
     */
    public function moveAllToCart(Wishlist $wishlist, $qtys)
    {
        $isOwner = $wishlist->isOwner($this->customerSession->getCustomerId());

        $messages = [];
        $addedProducts = [];
        $notSalable = [];

        $cart = $this->cart;
        $collection = $wishlist->getItemCollection()->setVisibilityFilter();

        foreach ($collection as $item) {
            /** @var $item \Magento\Wishlist\Model\Item */
            try {
                $disableAddToCart = $item->getProduct()->getDisableAddToCart();
                $item->unsProduct();

                // Set qty
                if (isset($qtys[$item->getId()])) {
                    $qty = $this->quantityProcessor->process($qtys[$item->getId()]);
                    if ($qty) {
                        $item->setQty($qty);
                    }
                }
                $item->getProduct()->setDisableAddToCart($disableAddToCart);
                // Add to cart
                if ($item->addToCart($cart, $isOwner)) {
                    $addedProducts[] = $item->getProduct();
                }
            } catch (LocalizedException $e) {
                if ($e instanceof ProductException) {
                    $notSalable[] = $item;
                } else {
                    $messages[] = __('%1 for "%2".', trim($e->getMessage(), '.'), $item->getProduct()->getName());
                }

                $cartItem = $cart->getQuote()->getItemByProduct($item->getProduct());
                if ($cartItem) {
                    $cart->getQuote()->deleteItem($cartItem);
                }
            } catch (\Exception $e) {
                $this->logger->critical($e);
                $messages[] = __('We can\'t add this item to your shopping cart right now.');
            }
        }

        if ($isOwner) {
            $indexUrl = $this->helper->getListUrl($wishlist->getId());
        } else {
            $indexUrl = $this->urlBuilder->getUrl('wishlist/shared', ['code' => $wishlist->getSharingCode()]);
        }
        if ($this->cartHelper->getShouldRedirectToCart()) {
            $redirectUrl = $this->cartHelper->getCartUrl();
        } elseif ($this->redirector->getRefererUrl()) {
            $redirectUrl = $this->redirector->getRefererUrl();
        } else {
            $redirectUrl = $indexUrl;
        }

        if ($notSalable) {
            $products = [];
            foreach ($notSalable as $item) {
                $products[] = '"' . $item->getProduct()->getName() . '"';
            }
            $messages[] = __(
                'We couldn\'t add the following product(s) to the shopping cart: %1.',
                join(', ', $products)
            );
        }

        if ($messages) {
            foreach ($messages as $message) {
                $this->messageManager->addError($message);
            }
            $redirectUrl = $indexUrl;
        }

        if ($addedProducts) {
            // save wishlist model for setting date of last update
            try {
                $wishlist->save();
            } catch (\Exception $e) {
                $this->messageManager->addError(__('We can\'t update the Wish List right now.'));
                $redirectUrl = $indexUrl;
            }

            $products = [];
            foreach ($addedProducts as $product) {
                /** @var $product \Magento\Catalog\Model\Product */
                $products[] = '"' . $product->getName() . '"';
            }

            $this->messageManager->addSuccess(
                __('%1 product(s) have been added to shopping cart: %2.', count($addedProducts), join(', ', $products))
            );

            // save cart and collect totals
            $cart->save()->getQuote()->collectTotals();
        }
        $this->helper->calculate();
        return $redirectUrl;
    }
}


text:
// Copyright (c) 2002, Eric D. Friedman All Rights Reserved.

package gnu.trove;

/**
 * This object hashing strategy uses the System.identityHashCode
 * method to provide identity hash codes.  These are identical to the
 * value produced by Object.hashCode(), even when the type of the
 * object being hashed overrides that method.
 *
 * Created: Sat Aug 17 11:13:15 2002
 *
 * @author Eric Friedman
 * @version $Id: TObjectIdentityHashingStrategy.java,v 1.8 2004/09/24 09:11:15 cdr Exp $
 */

public final class TObjectIdentityHashingStrategy<T> implements TObjectHashingStrategy<T> {
    /**
     * Delegates hash code computation to the System.identityHashCode(Object) method.
     *
     * @param object for which the hashcode is to be computed
     * @return the hashCode
     */
    @Override
    public final int computeHashCode(T object) {
        return System.identityHashCode(object);
    }

    /**
     * Compares object references for equality.
     *
     * @param o1 an Object value
     * @param o2 an Object value
     * @return true if o1 == o2
     */
    @Override
    public final boolean equals(T o1, T o2) {
        return o1 == o2;
    }
} // TObjectIdentityHashingStrategy


text:
import com.namelessmc.plugin.common.LanguageHandler;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.Test;
import org.spongepowered.configurate.ConfigurateException;
import org.spongepowered.configurate.ConfigurationNode;
import org.spongepowered.configurate.yaml.YamlConfigurationLoader;

import java.io.IOException;
import java.lang.reflect.Field;
import java.nio.file.Files;
import java.nio.file.Path;
import java.util.Arrays;
import java.util.Set;

public class LanguageHandlerTest {

	@Test
	void ensureAllFilesInLanguageSet() throws IllegalAccessException, NoSuchFieldException, IOException {
		Field field = LanguageHandler.class.getDeclaredField("LANGUAGES");
		field.setAccessible(true);
		Set<String> languageCodes = (Set<String>) field.get(null);;
		Path languagesDir = Path.of( "resources", "languages");
		Files.list(languagesDir).forEach(path -> {
			String name = path.getFileName().toString();
			String languageCode = name.substring(0, name.length() - 5);
			Assertions.assertTrue(languageCodes.contains(languageCode), "missing language " + languageCode);
		});
	}

	@Test
	void ensureTermsPresentInBase() throws ConfigurateException {
		Path path = Path.of("resources", "languages", "en_UK.yaml");
		ConfigurationNode config = YamlConfigurationLoader.builder().path(path).build().load();
		for (LanguageHandler.Term term : LanguageHandler.Term.values()) {
			Assertions.assertTrue(config.hasChild(term.path()), "base file en_UK missing term " + Arrays.toString(term.path()));
		}
	}

}


text:
@implementation ComGoogleProtobufGeneratedMessageLite

J2OBJC_IGNORE_DESIGNATED_BEGIN
- (instancetype)init {
  ComGoogleProtobufGeneratedMessageLite_init(self);
  return self;
}
J2OBJC_IGNORE_DESIGNATED_END

@end

void ComGoogleProtobufGeneratedMessageLite_init(ComGoogleProtobufGeneratedMessageLite *self) {
  ComGoogleProtobufAbstractMessageLite_init(self);
}

J2OBJC_CLASS_TYPE_LITERAL_SOURCE(ComGoogleProtobufGeneratedMessageLite)

@implementation ComGoogleProtobufGeneratedMessageLite_GeneratedExtension

- (instancetype)initWithComGoogleProtobufMessageLite:
                    (id<ComGoogleProtobufMessageLite>)containingTypeDefaultInstance
                                                       withId:(id)defaultValue
                             withComGoogleProtobufMessageLite:
                                 (id<ComGoogleProtobufMessageLite>)messageDefaultInstance
withComGoogleProtobufGeneratedMessageLite_ExtensionDescriptor:
    (ComGoogleProtobufGeneratedMessageLite_ExtensionDescriptor *)descriptor
                                                 withIOSClass:(IOSClass *)singularType {
  if (!containingTypeDefaultInstance) {
    @throw create_JavaLangIllegalArgumentException_initWithNSString_(
        @"Null containingTypeDefaultInstance");
  }
  JreStrongAssign(&self->containingTypeDefaultInstance_, containingTypeDefaultInstance);
  JreStrongAssign(&self->defaultValue_, defaultValue);
  JreStrongAssign(&self->messageDefaultInstance_, messageDefaultInstance);
  JreStrongAssign(&self->descriptor_, descriptor);
  return self;
}

- (id<ComGoogleProtobufMessageLite>)getContainingTypeDefaultInstance {
  return containingTypeDefaultInstance_;
}

- (jint)getNumber {
  return [(
      (ComGoogleProtobufGeneratedMessageLite_ExtensionDescriptor *)nil_chk(descriptor_)) getNumber];
}

- (id<ComGoogleProtobufMessageLite>)getMessageDefaultInstance {
  return messageDefaultInstance_;
}

- (ComGoogleProtobufWireFormat_FieldType *)getLiteType {
  return [((ComGoogleProtobufGeneratedMessageLite_ExtensionDescriptor *)nil_chk(
      descriptor_)) getLiteType];
}

- (id)getDefaultValue {
  return defaultValue_;
}

- (jboolean)isRepeated {
  return ((ComGoogleProtobufGeneratedMessageLite_ExtensionDescriptor *)nil_chk(descriptor_))
      ->isRepeated_;
}

- (void)dealloc {
  RELEASE_(containingTypeDefaultInstance_);
  RELEASE_(defaultValue_);
  RELEASE_(messageDefaultInstance_);
  RELEASE_(descriptor_);
  [super dealloc];
}

@end

J2OBJC_CLASS_TYPE_LITERAL_SOURCE(ComGoogleProtobufGeneratedMessageLite_GeneratedExtension)

@implementation ComGoogleProtobufGeneratedMessageLite_ExtensionDescriptor

- (instancetype)initWithComGoogleProtobufInternal_EnumLiteMap:
                    (id<ComGoogleProtobufInternal_EnumLiteMap>)enumTypeMap
                                                      withInt:(jint)number
                    withComGoogleProtobufWireFormat_FieldType:
                        (ComGoogleProtobufWireFormat_FieldType *)type
                                                  withBoolean:(jboolean)isRepeated
                                                  withBoolean:(jboolean)isPacked {
  NSObject_init(self);
  self->number_ = number;
  JreStrongAssign(&self->type_, type);
  self->isRepeated_ = isRepeated;
  self->isPacked_ = isPacked;
  return self;
}

- (jint)getNumber {
  return number_;
}

- (ComGoogleProtobufWireFormat_FieldType *)getLiteType {
  return type_;
}

- (jboolean)isRepeated {
  return isRepeated_;
}

- (jboolean)isPacked {
  return isPacked_;
}

- (void)dealloc {
  RELEASE_(type_);
  [super dealloc];
}

@end

J2OBJC_CLASS_TYPE_LITERAL_SOURCE(ComGoogleProtobufGeneratedMessageLite_ExtensionDescriptor)


text:
package com.winterwell.es.client.query;

import java.util.Collection;
import java.util.Map;

import com.winterwell.utils.containers.ArrayMap;

/**
 * See https://www.elastic.co/guide/en/elasticsearch/reference/6.3/query-dsl-mlt-query.html
 * @author daniel
 *
 */
public class MoreLikeThisQueryBuilder extends ESQueryBuilder {

	public MoreLikeThisQueryBuilder() {
		this(new ArrayMap("more_like_this", new ArrayMap()));
	}

	public MoreLikeThisQueryBuilder(Map query) {
		super(query);
	}

	public MoreLikeThisQueryBuilder(String like) {
		this();
		props.put("like", like);
	}

	public MoreLikeThisQueryBuilder setFields(Collection<String> fields) {
		props.put("fields", fields);
		return this;
	}

	public MoreLikeThisQueryBuilder setMinTermFreq(int i) {
		props.put("min_term_freq", i);
		return this;
	}

	public MoreLikeThisQueryBuilder setMinDocFreq(int i) {
		props.put("min_doc_freq", i);
		return this;
	}

}


text:
package com.amazonaws.services.iotfleetwise.model.transform;

import java.math.*;

import javax.annotation.Generated;

import com.amazonaws.services.iotfleetwise.model.*;
import com.amazonaws.transform.SimpleTypeJsonUnmarshallers.*;
import com.amazonaws.transform.*;

import com.fasterxml.jackson.core.JsonToken;
import static com.fasterxml.jackson.core.JsonToken.*;

/**
 * UpdateVehicleResult JSON Unmarshaller
 */
@Generated("com.amazonaws:aws-java-sdk-code-generator")
public class UpdateVehicleResultJsonUnmarshaller implements Unmarshaller<UpdateVehicleResult, JsonUnmarshallerContext> {

    public UpdateVehicleResult unmarshall(JsonUnmarshallerContext context) throws Exception {
        UpdateVehicleResult updateVehicleResult = new UpdateVehicleResult();

        int originalDepth = context.getCurrentDepth();
        String currentParentElement = context.getCurrentParentElement();
        int targetDepth = originalDepth + 1;

        JsonToken token = context.getCurrentToken();
        if (token == null)
            token = context.nextToken();
        if (token == VALUE_NULL) {
            return updateVehicleResult;
        }

        while (true) {
            if (token == null)
                break;

            if (token == FIELD_NAME || token == START_OBJECT) {
                if (context.testExpression("vehicleName", targetDepth)) {
                    context.nextToken();
                    updateVehicleResult.setVehicleName(context.getUnmarshaller(String.class).unmarshall(context));
                }
                if (context.testExpression("arn", targetDepth)) {
                    context.nextToken();
                    updateVehicleResult.setArn(context.getUnmarshaller(String.class).unmarshall(context));
                }
            } else if (token == END_ARRAY || token == END_OBJECT) {
                if (context.getLastParsedParentElement() == null || context.getLastParsedParentElement().equals(currentParentElement)) {
                    if (context.getCurrentDepth() <= originalDepth)
                        break;
                }
            }
            token = context.nextToken();
        }

        return updateVehicleResult;
    }

    private static UpdateVehicleResultJsonUnmarshaller instance;

    public static UpdateVehicleResultJsonUnmarshaller getInstance() {
        if (instance == null)
            instance = new UpdateVehicleResultJsonUnmarshaller();
        return instance;
    }
}


text:
<?php
namespace FrontPanels\Panels;

use FrontPanels\Entities\FrontPanelsPanelEntity;
use FrontPanels\Interfaces\InterfacePanelsProcessor;

class PanelContactsWidgetSourcesVsContactsProcessorModel extends AbstractPanelProcessorModel implements InterfacePanelsProcessor
{
	/**
	 * (non-PHPdoc)
	 * @see \FrontPanels\Interfaces\InterfacePanelsProcessor::processPanel()
	 */
	public function processPanel(FrontPanelsPanelEntity $objPanel)
	{
		if (!is_object($objPanel->get("panel_read_data")) && !is_array($objPanel->get("panel_read_data")))
		{
			return $objPanel;
		}//end if

		$html_id = str_replace(".", "", microtime(TRUE));
		$html = "";
		$html .= "
";
// 		$html .= 	"
";
// 		$html .= 	"
";
		$html .= 	"
";

		foreach ($objPanel->get("panel_read_data") as $k => $objData)
		{
			if ($objData->source == "")
			{
				$objData->source = "Not Specified";
			}//end if

			$html .= "
";
			$html .=	"" . $objData->source . "	";
			$html .= 	"" . $objData->contact_count . "	";
			$html .= "
";
		}//end foreach

		$html .=	"
";
		$html .= "
";
		$html .= "

";

		$objPanel->set("html", $html);
		return $objPanel;
	}//end function
}//end class


text:
package com.facebook.buck.event;

/**
 * Event to tell the console that it needs to flush now. This is used to ensure that all pending
 * events are written before potentially writing to stdout (which would cause certain event busses
 * to cease rendering)
 *
 * <p>Use of this class is generally an antipattern, and is only used currently to make up for some
 * shortcomings in {@link com.facebook.buck.event.listener.SuperConsoleEventBusListener}
 */
public class FlushConsoleEvent extends AbstractBuckEvent {

  public FlushConsoleEvent() {
    super(EventKey.unique());
  }

  @Override
  protected String getValueString() {
    return "flush";
  }

  @Override
  public String getEventName() {
    return "FlushConsoleEvent";
  }
}


text:
namespace crashpad {
namespace test {
namespace {

bool IsAligned(void* pointer, size_t alignment) {
  uintptr_t address = reinterpret_cast<uintptr_t>(pointer);
  return (address & (alignment - 1)) == 0;
}

TEST(AlignedAllocator, AlignedVector) {
  // Test a structure with natural alignment.
  struct NaturalAlignedStruct {
    int i;
  };

  AlignedVector<NaturalAlignedStruct> natural_aligned_vector;
  natural_aligned_vector.push_back(NaturalAlignedStruct());
  EXPECT_TRUE(
      IsAligned(&natural_aligned_vector[0], alignof(NaturalAlignedStruct)));

  natural_aligned_vector.resize(3);
  EXPECT_TRUE(
      IsAligned(&natural_aligned_vector[0], alignof(NaturalAlignedStruct)));
  EXPECT_TRUE(
      IsAligned(&natural_aligned_vector[1], alignof(NaturalAlignedStruct)));
  EXPECT_TRUE(
      IsAligned(&natural_aligned_vector[2], alignof(NaturalAlignedStruct)));

  // Test a structure that declares its own alignment.
  struct alignas(16) AlignedStruct {
    int i;
  };
  ASSERT_EQ(alignof(AlignedStruct), 16u);

  AlignedVector<AlignedStruct> aligned_vector;
  aligned_vector.push_back(AlignedStruct());
  EXPECT_TRUE(IsAligned(&aligned_vector[0], alignof(AlignedStruct)));

  aligned_vector.resize(3);
  EXPECT_TRUE(IsAligned(&aligned_vector[0], alignof(AlignedStruct)));
  EXPECT_TRUE(IsAligned(&aligned_vector[1], alignof(AlignedStruct)));
  EXPECT_TRUE(IsAligned(&aligned_vector[2], alignof(AlignedStruct)));

  // Try a custom alignment. Since the structure itself doesn't specify an
  // alignment constraint, only the base address will be aligned to the
  // requested boundary.
  AlignedVector<NaturalAlignedStruct, 32> custom_aligned_vector;
  custom_aligned_vector.push_back(NaturalAlignedStruct());
  EXPECT_TRUE(IsAligned(&custom_aligned_vector[0], 32));

  // Try a structure with a pretty big alignment request.
  struct alignas(64) BigAlignedStruct {
    int i;
  };
  ASSERT_EQ(alignof(BigAlignedStruct), 64u);

  AlignedVector<BigAlignedStruct> big_aligned_vector;
  big_aligned_vector.push_back(BigAlignedStruct());
  EXPECT_TRUE(IsAligned(&big_aligned_vector[0], alignof(BigAlignedStruct)));

  big_aligned_vector.resize(3);
  EXPECT_TRUE(IsAligned(&big_aligned_vector[0], alignof(BigAlignedStruct)));
  EXPECT_TRUE(IsAligned(&big_aligned_vector[1], alignof(BigAlignedStruct)));
  EXPECT_TRUE(IsAligned(&big_aligned_vector[2], alignof(BigAlignedStruct)));
}

void BadAlignmentTest() {
#if defined(OS_WIN)
  // Suppress the assertion MessageBox() normally displayed by the CRT in debug
  // mode.
  int previous = _CrtSetReportMode(_CRT_ASSERT, _CRTDBG_MODE_DEBUG);

  // In release mode, _CrtSetReportMode() is #defined to ((int)0), so |previous|
  // would appear unused.
  ALLOW_UNUSED_LOCAL(previous);
#endif

  // Alignment constraints must be powers of 2. 7 is not valid.
  AlignedVector<int, 7> bad_aligned_vector;
  bad_aligned_vector.push_back(0);

#if defined(OS_WIN)
  _CrtSetReportMode(_CRT_ASSERT, previous);
#endif
}

TEST(AlignedAllocatorDeathTest, BadAlignment) {
  ASSERT_DEATH(BadAlignmentTest(), "");
}

}  // namespace
}  // namespace test
}  // namespace crashpad


text:
SCRIPT_NAME=elf
TEMPLATE_NAME=generic
EXTRA_EM_FILE=genelf
OUTPUT_FORMAT="elf32-i960"
NO_RELA_RELOCS=yes
ARCH=i960
MACHINE=
TEXT_START_ADDR=0
EMBEDDED=yes
MAXPAGESIZE="CONSTANT (MAXPAGESIZE)"


text:
<?php
defined('BASEPATH') OR exit('No direct script access allowed');

class Auth extends CI_Controller
{

	public function __construct()
	{
		parent::__construct();
		$this->load->model('m_auth','auth');
	}

	public function index()
	{
		if($this->session->userdata('logged')){
			$this->load->view('dashboard/v_accueil');
		}else{
			$this->load->view('dashboard/v_login');
		}
	}

	public function connexion()
	{
		$login = $this->input->post('LoginAdmin');
		$mdp = $this->input->post('MdpAdmin');
		if($login !='' and $mdp != '')
		{
			$login = trim($login);
			$chek = $this->auth->getLogin($login,$mdp);
			if ($chek!=FALSE) {
				$nbrRow = $this->auth->countAll();
		    	$data = array(
                	'Login'=>$chek->LoginAdmin,
                	/*'Nom'=>$chek->NomAdmin,
                	'Prenom'=>$chek->PrenomAdmin,*/
                	'Logged'=>true
                );
		    	$this->session->set_userdata($data);
				echo json_encode(array("status" => "TRUE"));
		    } else {
                echo json_encode(array("status" => "FALSE"));
		    	exit();
			}
		} else {
			echo json_encode(array("status" => FALSE));
			exit();
		}
	}

	public function logout()
	{

		$this->session->unset_userdata('Login');
		$this->session->unset_userdata('Logged');
		$this->session->unset_userdata('Nom');
		$this->session->unset_userdata('Prenom');
		$this->session->sess_destroy();
		redirect(site_url());
	}
}


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/maven-v4_0_0.xsd">
  <modelVersion>4.0.0</modelVersion>
  <parent>
    <groupId>org.uberfire</groupId>
    <artifactId>uberfire-nio2-backport</artifactId>
    <version>0.4.0-SNAPSHOT</version>
  </parent>

  <artifactId>uberfire-nio2-api</artifactId>
  <packaging>jar</packaging>

  <name>Uberfire NIO.2 :: API</name>
  <description>Uberfire NIO.2 :: API</description>

  <dependencies>
    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-commons</artifactId>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-nio2-model</artifactId>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-nio2-fs</artifactId>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-nio2-jgit</artifactId>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-ext</artifactId>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>ch.qos.logback</groupId>
      <artifactId>logback-classic</artifactId>
      <scope>test</scope>
    </dependency>

  </dependencies>

</project>


text:
@interface NSString (RM)
- (NSURL *)rm_URL;
@end