text:
JBWebViewController
===================

A drop-in Facebook inspired modal web browser.

## Video Demo

## Installation

### CocoaPods
The recommended approach for installing JBWebViewController is through the package manager [CocoaPods](http://cocoapods.org/), which is widely used by iOS & Mac developers.

Simply add the following line to your Podfile:
```ruby
pod "JBWebViewController"
```

### Manual Install
Drag the JBWebViewController folder into your Xcode project, you may need to check the box "Copy items into destination group's folder (if needed)".

JBWebViewController needs the following third-party libraries:
* [ARChromeActivity](https://github.com/alextrob/ARChromeActivity)
* [ARSafariActivity](https://github.com/alexruperez/ARSafariActivity)
* [NJKWebViewProgress](https://github.com/ninjinkun/NJKWebViewProgress)

## Apps using JBWebViewController
- [Copenhagen Fashion Week®](http://itunes.apple.com/app/id901148180?mt=8)
- [Ookull](http://itunes.apple.com/app/id934603488?mt=8)

Feel free to add your app to the list.

## How to use
JBWebViewController is ment to be shown modally, which is recommended to be down with it's built in show functionality. Whilst not being recommended, it is however possible to present JBWebViewController outside a modal view controller. JBWebViewController should always be connected to a UINavigationController.

#### Presenting JBWebViewController
```objectivec
JBWebViewController *controller = [[JBWebViewController alloc] initWithUrl:[NSURL URLWithString:@"http://www.apple.com/iphone/"]];

[controller show];
```

#### Presenting JBWebViewController with block
```objectivec
JBWebViewController *controller = [[JBWebViewController alloc] initWithUrl:[NSURL URLWithString:@"http://www.apple.com/iphone/"]];

[controller showControllerWithCompletion:^(JBWebViewController *controller) {
    NSLog(@"Controller has arrived.");
}];
```

#### Localization
```objectivec
[controller setLoadingString:@"Chargement.."];
```

#### Navigate to URL
```objectivec
[controller navigateToURL:[NSURL URLWithString:@"http://www.apple.com/ios/"]];
```

#### Load custom NSURLRequest
```objectivec
NSURLRequest *request = [NSURLRequest requestWithURL:[NSURL URLWithString:@"http://developer.apple.com/"]];
[controller loadRequest:request];
```

#### Reload current page
```objectivec
[controller reload];
```

#### Manually setting controller title
```objectivec
[controller setWebTitle:@"The quick brown fox"];
```

#### Getting controller title
```objectivec
NSString *controllerTitle = [controller getWebTitle];
```

#### Manually setting controller subtitle
```objectivec
[controller setWebSubtitle:@"foo bar"];
```

#### Getting controller subtitle
```objectivec
NSString *controllerSubtitle = [controller getWebSubtitle];
```

#### Hide URL
```objectivec
controller.hideAddressBar = YES;
```

#### Access UIWebView
The UIWebView used in the controller is now pubic.
```objectivec
UIWebView *webView;
```

## Icons
Free icons by [Icons8](http://icons8.com/) under [Creative Commons Attribution-NoDerivs 3.0 Unported](https://creativecommons.org/licenses/by-nd/3.0/).

## Contact

Mention me on Twitter ([@JonasBoserup](https://twitter.com/JonasBoserup)) or email me ([Profile](https://github.com/boserup)).

## License

JBWebViewController is available under the MIT license. See the LICENSE file for more info.

redpajama_set_name: RedPajamaGithub


text:
Kore task example.

This example creates an asynchronous task from the page handler
that performs a POST to the same server and fetches its data
before returning to the client.

Build:
```
	$ kore build
```

Run:
```
	$ kore run
```

Test:
```
	$ curl -i -k https://127.0.0.1:8888/?user=astring
	The returned data must match what you supplied in user ([a-z] string)
```


text:
<?php

namespace Symfony\Cmf\Bundle\RoutingExtraBundle\Tests\DependencyInjection\Compiler;

use Symfony\Cmf\Bundle\RoutingExtraBundle\DependencyInjection\Compiler\RouteEnhancerPass;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\DependencyInjection\Definition;

class RouteEnhancerPassTest extends \PHPUnit_Framework_TestCase
{
    public function testRouteEnhancerPass()
    {
        $serviceIds = array(
            'test_enhancer' => array(
                0 => array(
                    'id' => 'foo_enhancer'
                )
            ),
        );

        $definition = new Definition('router');
        $builder = $this->getMock('Symfony\Component\DependencyInjection\ContainerBuilder');
        $builder->expects($this->at(0))
            ->method('hasDefinition')
            ->will($this->returnValue(true));
        $builder->expects($this->once())
            ->method('findTaggedServiceIds')
            ->will($this->returnValue($serviceIds));
        $builder->expects($this->once())
            ->method('getDefinition')
            ->with('symfony_cmf_routing_extra.dynamic_router')
            ->will($this->returnValue($definition));

        $pass = new RouteEnhancerPass();
        $pass->process($builder);
        $calls = $definition->getMethodCalls();
        $this->assertEquals(1, count($calls));
        $this->assertEquals('addRouteEnhancer', $calls[0][0]);
    }
}


text:
// Generated by delombok at Thu Nov 16 13:48:05 CST 2017
package com.egzosn.pay.paypal.bean.order;

import com.alibaba.fastjson.annotation.JSONField;

public class Phone{
	/**
	 * Country code (from in E.164 format)
	 */
	@JSONField(name = "country_code")
	private String countryCode;
	/**
	 * In-country phone number (from in E.164 format)
	 */
	@JSONField(name = "national_number")
	private String nationalNumber;
	/**
	 * Phone extension
	 */
	private String extension;

	/**
	 * Default Constructor
	 */
	public Phone() {
	}

	public Phone(String countryCode, String nationalNumber) {
		this.countryCode = countryCode;
		this.nationalNumber = nationalNumber;
	}

	public String getCountryCode() {
		return this.countryCode;
	}

	public String getNationalNumber() {
		return this.nationalNumber;
	}

	public String getExtension() {
		return this.extension;
	}

	public Phone setCountryCode(final String countryCode) {
		this.countryCode = countryCode;
		return this;
	}

	public Phone setNationalNumber(final String nationalNumber) {
		this.nationalNumber = nationalNumber;
		return this;
	}

	public Phone setExtension(final String extension) {
		this.extension = extension;
		return this;
	}

	@Override
	public boolean equals(final Object o) {
		if (o == this) return true;
		if (!(o instanceof Phone)) return false;
		final Phone other = (Phone) o;
		if (!other.canEqual((Object) this)) return false;
		if (!super.equals(o)) return false;
		final Object this$countryCode = this.getCountryCode();
		final Object other$countryCode = other.getCountryCode();
		if (this$countryCode == null ? other$countryCode != null : !this$countryCode.equals(other$countryCode)) return false;
		final Object this$nationalNumber = this.getNationalNumber();
		final Object other$nationalNumber = other.getNationalNumber();
		if (this$nationalNumber == null ? other$nationalNumber != null : !this$nationalNumber.equals(other$nationalNumber)) return false;
		final Object this$extension = this.getExtension();
		final Object other$extension = other.getExtension();
		if (this$extension == null ? other$extension != null : !this$extension.equals(other$extension)) return false;
		return true;
	}

	protected boolean canEqual(final Object other) {
		return other instanceof Phone;
	}

	@Override
	public int hashCode() {
		final int PRIME = 59;
		int result = 1;
		result = result * PRIME + super.hashCode();
		final Object $countryCode = this.getCountryCode();
		result = result * PRIME + ($countryCode == null ? 43 : $countryCode.hashCode());
		final Object $nationalNumber = this.getNationalNumber();
		result = result * PRIME + ($nationalNumber == null ? 43 : $nationalNumber.hashCode());
		final Object $extension = this.getExtension();
		result = result * PRIME + ($extension == null ? 43 : $extension.hashCode());
		return result;
	}
}


text:
#define CRAP_DL 1

#include <cstdio>
#include "convert.h"
#include "../../default/include/keyboardlistener.h"
#include "plugin.h"
#include "node.h"
#include "componenttype.h"
#include "inputmanagerbase.h"
#include "keyboardinput.h"
#include "system.h"

namespace crap
{

KeyboardListener::KeyboardListener( void ) :
		_modifier(0), _key(0)
{
	REGISTER_CLASS_ATTRIBUTE( KeyboardListener, key, char )
	REGISTER_CLASS_ATTRIBUTE( KeyboardListener, modifier, uint32_t )
	REGISTER_CLASS_ATTRIBUTE( KeyboardListener, message, string_hash )
}

KeyboardListener::~KeyboardListener( void )
{

}

void KeyboardListener::init( System* system )
{
	InputManagerBase* imanager = system->getSubSystem<InputManagerBase>("InputManager");
	KeyboardInput* keyboardInput = (KeyboardInput*)imanager->getInputHandle("Keyboard");

	keyboardInput->addListener<KeyboardListener, &KeyboardListener::keyboardCallback>(this, _key, _modifier);
}

void KeyboardListener::deinit( System* system )
{
	InputManagerBase* imanager = system->getSubSystem<InputManagerBase>("InputManager");
	KeyboardInput* keyboardInput = (KeyboardInput*)imanager->getInputHandle("Keyboard");

	keyboardInput->removeListener<KeyboardListener, &KeyboardListener::keyboardCallback>(this);
}

void KeyboardListener::keyboardCallback( uint32_t state )
{
	_node->sendChidren( _message, &state );
}

} //namespace crap


text:
// Reproducing this bug only requires an EMCP version of the
// RedefineSubclassWithTwoInterfacesImpl class so
// RedefineSubclassWithTwoInterfacesImpl.java and
// RedefineSubclassWithTwoInterfacesImpl_1.java are identical.
public class RedefineSubclassWithTwoInterfacesImpl
                 extends RedefineSubclassWithTwoInterfacesTarget
                 implements RedefineSubclassWithTwoInterfacesIntf1,
                            RedefineSubclassWithTwoInterfacesIntf2 {
    // This class is acting in the role of:
    // wlstest.unit.diagnostics.common.apps.echoejb.EchoBean4_nh7k_Impl
}


text:
import sys

from distutils.core import setup, Extension

if sys.version_info[0] == 3:    # "using Python 3"
    ext = Extension("dist", sources=["src/py3/dist.c"])
elif sys.version_info[0] == 2:  # "using Python 2"
    ext = Extension("dist", sources=["src/py2/dist.c"])
else:
    raise NotImplementedError("Not implemented for your python version")

setup(
    name="dist",
    version="1.0.3",
    description="Compute distance between two coordinates on the map",
    author='Eugene Duboviy',
    author_email='eugene.dubovoy@gmail.com',
    url='https://github.com/duboviy/dist',
    download_url = 'https://github.com/duboviy/dist/tarball/1.0.3',
    keywords = ['distance', 'coordinates', 'map', 'performance'],
    classifiers=[
      "Programming Language :: Python",
      "Programming Language :: Python :: 3",
      "Intended Audience :: Developers",
      "License :: OSI Approved :: MIT License",
      "Operating System :: OS Independent",
      "Topic :: Software Development :: Libraries :: Python Modules",
    ],
    long_description="""
As more and more apps are using maps, the more demand for geolocation capabilities increase.
Geolocation is about the reporting of your location to other users,
as well as associating real-world locations (such as landmarks) to your location.
This repo helps to accurately calculate the distance between two locations
and presents a time efficient practical solution,
that is almost 3 times faster than similar fast pure python implementation.
""",
    ext_modules=[ext],
)


text:
<?php

namespace Liip\ImagineBundle\Tests\Functional\Binary;

use Liip\ImagineBundle\Tests\Functional\AbstractWebTestCase;

class MimeTypeGuesserTest extends AbstractWebTestCase
{
    public function testCouldBeGetFromContainerAsService()
    {
        $this->createClient();

        $this->assertInstanceOf(
            '\Symfony\Component\HttpFoundation\File\MimeType\MimeTypeGuesser',
            self::$kernel->getContainer()->get('liip_imagine.mime_type_guesser')
        );
    }
}


text:
=========
 Utility
=========

.. automodule:: impyute.util
    :members:


text:
SwitchFilterCommand::SwitchFilterCommand(QObject *parent) :
    GitlAbstractCommand(parent)
{
}

bool SwitchFilterCommand::execute(GitlCommandParameter &rcInputArg, GitlCommandParameter &rcOutputArg)
{
    ModelLocator* pModel = ModelLocator::getInstance();
    FilterLoader* pFilterLoader = &pModel->getDrawEngine().getFilterLoader();
    QString strFiltername = rcInputArg.getParameter("filter_name").toString();
    bool bEnable = rcInputArg.getParameter("filter_enable").toBool();
    AbstractFilter* pcFilter = pFilterLoader->getFilterByName(strFiltername);
    if( pcFilter == NULL )
    {
        qCritical() << QString("Cannot find filter %1").arg(strFiltername);
        return false;
    }
    pcFilter->setEnable(bEnable);
    /// refresh
    GitlIvkCmdEvt cRefreshEvt("refresh_screen");
    cRefreshEvt.dispatch();
    ///
    rcOutputArg.setParameter("filter_names",  QVariant::fromValue(pFilterLoader->getFilterNames())  );
    rcOutputArg.setParameter("filter_status", QVariant::fromValue(pFilterLoader->getEnableStatus()) );
    return true;
}


text:
define(function(require, exports, module) {
    'use strict';

    const template = require('tpl-loader!orofilter/templates/filter/filter-hint.html');
    const _ = require('underscore');
    const BaseView = require('oroui/js/app/views/base/view');
    let config = require('module-config').default(module.id);
    const FilterTemplate = require('orofilter/js/filter-template');

    config = _.extend({
        inline: true,
        selectors: {
            filters: '.filter-container',
            itemHint: '.filter-item-hint',
            itemsHint: '.filter-items-hint',
            hint: '.filter-criteria-hint',
            reset: '.reset-filter-button'
        }
    }, config);

    const FilterHint = BaseView.extend(_.extend({}, FilterTemplate, {
        /**
         * @property
         */
        filter: null,

        /**
         * @property {String}
         */
        label: '',

        /**
         * @property {String}
         */
        hint: '',

        /**
         * @property {String}
         */
        template: template,

        /**
         * @property {Boolean}
         */
        inline: config.inline,

        /**
         * @property {Object}
         */
        selectors: config.selectors,

        /**
         * @property {Object}
         */
        events: {
            'click .reset-filter': '_onClickResetFilter'
        },

        /**
         * @inheritDoc
         */
        constructor: function FilterHint(options) {
            FilterHint.__super__.constructor.call(this, options);
        },

        /**
         * @inheritDoc
         */
        initialize: function(options) {
            const opts = _.pick(options || {}, 'filter');
            _.extend(this, opts);

            this.templateTheme = this.filter.templateTheme;
            this.label = this.filter.label;
            this.hint = this.filter._getCriteriaHint();

            this._defineTemplate();

            FilterHint.__super__.initialize.call(this, options);
        },

        render: function() {
            this.setElement(this.template({
                label: this.inline ? null : this.label,
                allowClear: this.filter.allowClear
            }));

            if (this.filter.selectWidget) {
                this.filter.selectWidget.multiselect('getButton').hide();
            }

            if (this.inline) {
                this.filter.$el.find(this.selectors.itemHint).append(this.$el);
            } else {
                this.filter.$el.closest(this.selectors.filters).find(this.selectors.itemsHint)
                    .find(this.selectors.reset).before(this.$el);
            }

            this.visible = true;

            this.update(this.hint);
        },

        /**
         * @param {String|Null} hint
         * @returns {*}
         */
        update: function(hint) {
            this.$el.find(this.selectors.hint).html(_.escape(hint));
            if (!this.inline && hint === null) {
                if (this.visible) {
                    this.$el.hide();
                    this.visible = false;
                }
            } else {
                if (!this.visible) {
                    this.$el.show();
                    this.visible = true;
                }
            }
            return this;
        },

        /**
         * Handles click on filter reset button
         *
         * @param {jQuery.Event} e
         * @private
         */
        _onClickResetFilter: function(e) {
            e.stopPropagation();
            this.trigger('reset');
        }
    }));

    return FilterHint;
});


text:
define(['text!../config.json'], function(config){
  config = JSON.parse(config);
  config.debug = window.location.href.indexOf('debug') >= 0;
  config.AI = window.location.href.indexOf('ai') >= 0;
  config.open = window.location.href.indexOf('open') >= 0;
  return config;
});


text:
package com.dream.android.sample.lib.widget.hint;

import android.content.Context;
import android.content.res.TypedArray;
import android.graphics.drawable.Drawable;
import android.util.AttributeSet;
import android.view.LayoutInflater;
import android.view.View;
import android.widget.FrameLayout;
import android.widget.TextView;
import com.dream.android.sample.lib.R;

public class NoContentView extends FrameLayout {

    private TextView tvContent;

    private TextView tvFunc;

    private EmptyListener listener;

    public NoContentView(Context context) {
        super(context);
        init(context, null);
    }

    public NoContentView(Context context, AttributeSet attrs) {
        super(context, attrs);
        init(context, attrs);
    }

    public NoContentView(Context context, AttributeSet attrs, int defStyleAttr) {
        super(context, attrs, defStyleAttr);
        init(context, attrs);
    }

    private void init(Context context, AttributeSet attrs) {
        LayoutInflater.from(getContext()).inflate(R.layout.layout_no_content, this);
        tvContent = (TextView) findViewById(R.id.tv_content);
        tvFunc = (TextView) findViewById(R.id.btn_func);
        String title = null;
        int color = getContext().getResources().getColor(R.color.font_gray);
        float titleSize = 16;
        Drawable drawable = null;
        Drawable btnDrawable = null;
        String func = null;
        if(attrs != null) {
            TypedArray ta = context.obtainStyledAttributes(attrs, R.styleable.NoContentView);
            title = ta.getString(R.styleable.NoContentView_ncContent);
            color = ta.getColor(R.styleable.NoContentView_ncColor, getContext().getResources().getColor(R.color.font_gray));
            titleSize = ta.getDimension(R.styleable.NoContentView_ncSize, 16);
            drawable = ta.getDrawable(R.styleable.NoContentView_ncImage);
            func = ta.getString(R.styleable.NoContentView_ncBtnText);
            btnDrawable = ta.getDrawable(R.styleable.NoContentView_ncBtnBg);
            ta.recycle();
        }
        if(title == null) title = getContext().getString(R.string.default_no_content_hint);
        tvContent.setText(title);
        tvContent.setTextColor(color);
        tvContent.setTextSize(titleSize);
        if(drawable != null) tvContent.setCompoundDrawables(null, drawable, null, null);
        tvFunc.setVisibility(func != null || btnDrawable != null ? View.VISIBLE : View.INVISIBLE);
        if(func != null) tvFunc.setText(func);
        if(btnDrawable != null) tvFunc.setBackgroundDrawable(btnDrawable);
        tvFunc.setOnClickListener(onClickListener);
        setOnClickListener(onClickListener);
    }

    public void setContent(String content) {
        tvContent.setText(content);
    }

    private OnClickListener onClickListener = new OnClickListener() {
        @Override
        public void onClick(View v) {
            if(R.id.btn_func == v.getId()) {
                if(listener != null) {
                    listener.onEmptyClicked();
                }
            }
        }
    };

    public void setImageResource(int resId) {
        tvContent.setCompoundDrawablesWithIntrinsicBounds(0, resId, 0, 0);
    }

    public void setBtnText(String btnText) {
        if(btnText == null) {
            tvFunc.setVisibility(View.INVISIBLE);
        } else {
            tvFunc.setVisibility(View.VISIBLE);
            tvFunc.setText(btnText);
        }
    }

    public void setListener(EmptyListener listener) {
        this.listener = listener;
    }

    public interface EmptyListener {
        void onEmptyClicked();
    }
}


text:
title: Failing is hard
author: Filip Bunkens
type: post
date: 2014-12-17
url: /blog/20141217_failing-hard
categories: [ "Varia" ]
tags: ["Varia"]
format: gallery
---
First of all, I have to say, that I don't really know what I want to achieve with this post. It's something that has been bothering me for some time and I'm writing it here to get it of my chest.

[][1]

The following is my personal experience. When I made the choice to become freelancer I would have never expected that it would have this big of a effect on me. In that period I have had my fair share of past dues, bailiffs, notifications of foreclosure of my things, phone calls from the bank. It has been that bad that in July 2013 I was 2 days from bankrupt.

Do I tell you this, because I want your pity, no not at all. The reasons were plenty, by myself aswel outside factors. But what I want to tell is more how these things have impacted my life in more ways than I could imagine.

During the last 6 years, I lived in a constant state of stress, let me give you some exampels.

  * Every time I went to the mailbox, I expected the worst
  * Every car that stopped in the street, I feared it was a bailiff
  * With every telephone I had the fear of needing to find a new excuse why I didn't pay yet.
  * Every time I came home, I checked the door for scratch marks of the locksmith, because the bailiff passed to write up my things
  * Every doorbell, I hid my important things
  * Every time I checked my account, I wondered what to pay first
  * Every moment of the day I was looking for creative solutions to pay something and still being able to live

That are only the small things, I had learned to hate and evade the question: “How are you doing?”. I didn't want anybody to know that it wasn't well, not that anybody wanted to hear that anyway. So I kept the charade going

But I wasn't sleeping anymore, I stopped eating, I only drank water. I had small panic attacks. I hope for some good luck and started playing on the lottery, against my better judgement. I hoped for accounting mistakes from my clients, I stopped taking phone calls from unknown numbers

I hoped that hiding would solve my problems, but actually I was slowly killing myself, mentally and physically. I supposed it was part of the entrepreneur experience, as nobody was talking about it. Even those admitting to failure on the Fail conferences, never talked about the negative effects, only about getting up after you fall. So I must have been exaggerating.

One day I decided to stop hiding and just told everybody that asked, no it's not well. As I made the click, it seemed that all felt in place. When the day came that I almost payed off all of my debts, it thought great, from now on it will be all better.

However, with my debt, I also lost my drive. I do realise I'm still not safe but I'm tired, I can't go at 250% anymore. I'm still doing 90%, but that feels like standing still. I'm tired, empty, broken. I'm still passionate about photography and my jobs, but all other work is too much.

At least that is the feeling I'm having for the last months. So when yesterday, on the Failing Forward conference I heard every speaker talk about failure as a stepping stone to success, I had a bad taste with all that. Failing is not only a stepping stone, but also very tiresome and hard. You only get hit by it afterwards. You only know what it took, the moment you get up again.

By the way I still expect the worst, I'm still a bit anxious when opening the mailbox, going to the door or arriving home.

 [1]: /wp-content/uploads/2014/12/20141005_florian_annick-9449.jpg


text:
// --------------------------------------------------------------------------------------------------------------------
// <copyright file="LegacyMediaPickerPropertyConverter.cs" company="Umbraco">
//   Umbraco
// </copyright>
// <summary>
//   The multiple media picker property editor converter.
// </summary>
// --------------------------------------------------------------------------------------------------------------------

using System;
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Linq;

using Umbraco.Core;
using Umbraco.Core.Configuration;
using Umbraco.Core.Logging;
using Umbraco.Core.Models;
using Umbraco.Core.Models.PublishedContent;
using Umbraco.Core.PropertyEditors;
using Umbraco.Core.PropertyEditors.ValueConverters;
using Umbraco.Core.Services;

namespace Umbraco.Web.PropertyEditors.ValueConverters
{
    /// <summary>
    /// The multiple media picker and double legacy media picker property value converter, should be deleted for v8
    /// </summary>
    [DefaultPropertyValueConverter(typeof(MustBeStringValueConverter))]
    public class LegacyMediaPickerPropertyConverter : PropertyValueConverterBase, IPropertyValueConverterMeta
    {
        private readonly IDataTypeService _dataTypeService;

        //TODO: Remove this ctor in v8 since the other one will use IoC
        public LegacyMediaPickerPropertyConverter()
            : this(ApplicationContext.Current.Services.DataTypeService)
        {
        }

        public LegacyMediaPickerPropertyConverter(IDataTypeService dataTypeService)
        {
            if (dataTypeService == null) throw new ArgumentNullException("dataTypeService");
            _dataTypeService = dataTypeService;
        }

        /// <summary>
        /// Checks if this converter can convert the property editor and registers if it can.
        /// </summary>
        /// <param name="propertyType">
        /// The property type.
        /// </param>
        /// <returns>
        /// The <see cref="bool"/>.
        /// </returns>
        public override bool IsConverter(PublishedPropertyType propertyType)
        {
            if (UmbracoConfig.For.UmbracoSettings().Content.EnablePropertyValueConverters && propertyType.PropertyEditorAlias.Equals(Constants.PropertyEditors.MultipleMediaPickerAlias))
            {
                return true;
            }

            if (UmbracoConfig.For.UmbracoSettings().Content.EnablePropertyValueConverters && propertyType.PropertyEditorAlias.Equals(Constants.PropertyEditors.MediaPickerAlias))
            {
                // this is the double legacy media picker, it can pick only single media items
                return true;
            }

            return false;
        }

        /// <summary>
        /// Convert the raw string into a nodeId integer array or a single integer
        /// </summary>
        /// <param name="propertyType">
        /// The published property type.
        /// </param>
        /// <param name="source">
        /// The value of the property
        /// </param>
        /// <param name="preview">
        /// The preview.
        /// </param>
        /// <returns>
        /// The <see cref="object"/>.
        /// </returns>
        public override object ConvertDataToSource(PublishedPropertyType propertyType, object source, bool preview)
        {
            if (IsMultipleDataType(propertyType.DataTypeId, propertyType.PropertyEditorAlias))
            {
                var nodeIds =
                    source.ToString()
                        .Split(new[] { "," }, StringSplitOptions.RemoveEmptyEntries)
                        .Select(int.Parse)
                        .ToArray();
                return nodeIds;
            }

            var attemptConvertInt = source.TryConvertTo<int>();
            if (attemptConvertInt.Success)
            {
                return attemptConvertInt.Result;
            }
            else
            {
                var nodeIds =
                   source.ToString()
                       .Split(new[] { "," }, StringSplitOptions.RemoveEmptyEntries)
                       .Select(int.Parse)
                       .ToArray();

                if (nodeIds.Length > 0)
                {
                    var error =
                        string.Format(
                            "Data type \"{0}\" is not set to allow multiple items but appears to contain multiple items, check the setting and save the data type again",
                            ApplicationContext.Current.Services.DataTypeService.GetDataTypeDefinitionById(
                                propertyType.DataTypeId).Name);

                    LogHelper.Warn<LegacyMediaPickerPropertyConverter>(error);
                    throw new Exception(error);
                }
            }

            return null;
        }

        /// <summary>
        /// Convert the source nodeId into a IPublishedContent or IEnumerable of IPublishedContent (or DynamicPublishedContent) depending on data type setting
        /// </summary>
        /// <param name="propertyType">
        /// The published property type.
        /// </param>
        /// <param name="source">
        /// The value of the property
        /// </param>
        /// <param name="preview">
        /// The preview.
        /// </param>
        /// <returns>
        /// The <see cref="object"/>.
        /// </returns>
        public override object ConvertSourceToObject(PublishedPropertyType propertyType, object source, bool preview)
        {
            if (source == null)
            {
                return null;
            }

            if (UmbracoContext.Current == null)
            {
                return null;
            }

            var umbHelper = new UmbracoHelper(UmbracoContext.Current);

            if (IsMultipleDataType(propertyType.DataTypeId, propertyType.PropertyEditorAlias))
            {
                var nodeIds = (int[])source;
                var multiMediaPicker = Enumerable.Empty<IPublishedContent>();
                if (nodeIds.Length > 0)
                {
                    multiMediaPicker =  umbHelper.TypedMedia(nodeIds).Where(x => x != null);
                }

                // in v8 should return multiNodeTreePickerEnumerable but for v7 need to return as PublishedContentEnumerable so that string can be returned for legacy compatibility
                return new PublishedContentEnumerable(multiMediaPicker);
            }

            // single value picker
            var nodeId = (int)source;

            return umbHelper.TypedMedia(nodeId);
        }

        /// <summary>
        /// The get property cache level.
        /// </summary>
        /// <param name="propertyType">
        /// The property type.
        /// </param>
        /// <param name="cacheValue">
        /// The cache value.
        /// </param>
        /// <returns>
        /// The <see cref="PropertyCacheLevel"/>.
        /// </returns>
        public PropertyCacheLevel GetPropertyCacheLevel(PublishedPropertyType propertyType, PropertyCacheValue cacheValue)
        {
            PropertyCacheLevel returnLevel;
            switch (cacheValue)
            {
                case PropertyCacheValue.Object:
                    returnLevel = PropertyCacheLevel.ContentCache;
                    break;
                case PropertyCacheValue.Source:
                    returnLevel = PropertyCacheLevel.Content;
                    break;
                case PropertyCacheValue.XPath:
                    returnLevel = PropertyCacheLevel.Content;
                    break;
                default:
                    returnLevel = PropertyCacheLevel.None;
                    break;
            }

            return returnLevel;
        }

        /// <summary>
        /// The get property value type.
        /// </summary>
        /// <param name="propertyType">
        /// The property type.
        /// </param>
        /// <returns>
        /// The <see cref="Type"/>.
        /// </returns>
        public Type GetPropertyValueType(PublishedPropertyType propertyType)
        {
            return IsMultipleDataType(propertyType.DataTypeId, propertyType.PropertyEditorAlias) ? typeof(IEnumerable<IPublishedContent>) : typeof(IPublishedContent);
        }

        /// <summary>
        /// The is multiple data type.
        /// </summary>
        /// <param name="dataTypeId">
        /// The data type id.
        /// </param>
        /// <param name="propertyEditorAlias"></param>
        /// <returns>
        /// The <see cref="bool"/>.
        /// </returns>
        private bool IsMultipleDataType(int dataTypeId, string propertyEditorAlias)
        {
            // GetPreValuesCollectionByDataTypeId is cached at repository level;
            // still, the collection is deep-cloned so this is kinda expensive,
            // better to cache here + trigger refresh in DataTypeCacheRefresher

            return Storages.GetOrAdd(dataTypeId, id =>
            {
                var preVals = _dataTypeService.GetPreValuesCollectionByDataTypeId(id).PreValuesAsDictionary;

                if (preVals.ContainsKey("multiPicker"))
                {
                    var preValue = preVals
                        .FirstOrDefault(x => string.Equals(x.Key, "multiPicker", StringComparison.InvariantCultureIgnoreCase))
                        .Value;

                    return preValue != null && preValue.Value.TryConvertTo<bool>().Result;
                }

                //in some odd cases, the pre-values in the db won't exist but their default pre-values contain this key so check there
                var propertyEditor = PropertyEditorResolver.Current.GetByAlias(propertyEditorAlias);
                if (propertyEditor != null)
                {
                    var preValue = propertyEditor.DefaultPreValues
                        .FirstOrDefault(x => string.Equals(x.Key, "multiPicker", StringComparison.InvariantCultureIgnoreCase))
                        .Value;

                    return preValue != null && preValue.TryConvertTo<bool>().Result;
                }

                return false;
            });
        }

        private static readonly ConcurrentDictionary<int, bool> Storages = new ConcurrentDictionary<int, bool>();

        internal static void ClearCaches()
        {
            Storages.Clear();
        }
    }
}


text:
package Sorting.Sorting;

import static org.junit.Assert.*;

import org.junit.Test;

public class RangeTest {

@Test

	public void shouldSayIs15InRange()
	{
		Range range= new Range(10,20);
	assertTrue("nie jest", range.isInRange(12));

	}

}


text:
package org.apache.druid.query.aggregation.hyperloglog;

import org.apache.druid.data.input.InputRow;
import org.apache.druid.hll.HyperLogLogCollector;
import org.apache.druid.hll.HyperLogLogHash;
import org.apache.druid.segment.GenericColumnSerializer;
import org.apache.druid.segment.column.ColumnBuilder;
import org.apache.druid.segment.data.GenericIndexed;
import org.apache.druid.segment.data.ObjectStrategy;
import org.apache.druid.segment.serde.ComplexColumnPartSupplier;
import org.apache.druid.segment.serde.ComplexMetricExtractor;
import org.apache.druid.segment.serde.ComplexMetricSerde;
import org.apache.druid.segment.serde.LargeColumnSupportedComplexColumnSerializer;
import org.apache.druid.segment.writeout.SegmentWriteOutMedium;

import java.nio.ByteBuffer;
import java.util.Comparator;
import java.util.List;

public class HyperUniquesSerde extends ComplexMetricSerde
{
  private static Comparator<HyperLogLogCollector> comparator =
      Comparator.nullsFirst(Comparator.comparing(HyperLogLogCollector::toByteBuffer));

  private final HyperLogLogHash hyperLogLogHash;

  public HyperUniquesSerde()
  {
    this(HyperLogLogHash.getDefault());
  }

  public HyperUniquesSerde(HyperLogLogHash hyperLogLogHash)
  {
    this.hyperLogLogHash = hyperLogLogHash;
  }

  @Override
  public String getTypeName()
  {
    return "hyperUnique";
  }

  @Override
  public ComplexMetricExtractor<HyperLogLogCollector> getExtractor()
  {
    return new ComplexMetricExtractor<HyperLogLogCollector>()
    {
      @Override
      public Class<HyperLogLogCollector> extractedClass()
      {
        return HyperLogLogCollector.class;
      }

      @Override
      public HyperLogLogCollector extractValue(InputRow inputRow, String metricName)
      {
        Object rawValue = inputRow.getRaw(metricName);

        if (rawValue instanceof HyperLogLogCollector) {
          return (HyperLogLogCollector) rawValue;
        } else {
          HyperLogLogCollector collector = HyperLogLogCollector.makeLatestCollector();

          List<String> dimValues = inputRow.getDimension(metricName);
          if (dimValues == null) {
            return collector;
          }

          for (String dimensionValue : dimValues) {
            collector.add(hyperLogLogHash.hash(dimensionValue));
          }
          return collector;
        }
      }
    };
  }

  @Override
  public void deserializeColumn(ByteBuffer byteBuffer, ColumnBuilder columnBuilder)
  {
    final GenericIndexed column = GenericIndexed.read(byteBuffer, getObjectStrategy(), columnBuilder.getFileMapper());
    columnBuilder.setComplexColumnSupplier(new ComplexColumnPartSupplier(getTypeName(), column));
  }

  @Override
  public ObjectStrategy getObjectStrategy()
  {
    return new ObjectStrategy<HyperLogLogCollector>()
    {
      @Override
      public Class<HyperLogLogCollector> getClazz()
      {
        return HyperLogLogCollector.class;
      }

      @Override
      public HyperLogLogCollector fromByteBuffer(ByteBuffer buffer, int numBytes)
      {
        // make a copy of buffer, because the given buffer is not duplicated in HyperLogLogCollector.makeCollector() and
        // stored in a field.
        final ByteBuffer readOnlyBuffer = buffer.asReadOnlyBuffer();
        readOnlyBuffer.limit(readOnlyBuffer.position() + numBytes);
        return HyperLogLogCollector.makeCollector(readOnlyBuffer);
      }

      @Override
      public byte[] toBytes(HyperLogLogCollector collector)
      {
        if (collector == null) {
          return new byte[]{};
        }
        ByteBuffer val = collector.toByteBuffer();
        byte[] retVal = new byte[val.remaining()];
        val.asReadOnlyBuffer().get(retVal);
        return retVal;
      }

      @Override
      public int compare(HyperLogLogCollector o1, HyperLogLogCollector o2)
      {
        return comparator.compare(o1, o2);
      }
    };
  }

  @Override
  public GenericColumnSerializer getSerializer(SegmentWriteOutMedium segmentWriteOutMedium, String column)
  {
    return LargeColumnSupportedComplexColumnSerializer.create(segmentWriteOutMedium, column, this.getObjectStrategy());
  }

}


text:
package org.vitrivr.cineast.core.segmenter;

import org.vitrivr.cineast.core.color.FuzzyColorHistogramQuantizer;
import org.vitrivr.cineast.core.data.Histogram;

public class FuzzyColorHistogram extends Histogram {

	public FuzzyColorHistogram() {
		super(FuzzyColorHistogramQuantizer.Color.values().length);
		int i = 0;
		for(FuzzyColorHistogramQuantizer.Color c : FuzzyColorHistogramQuantizer.Color.values()){
			this.binNames.put(c.toString(), i++);
		}
	}

	@Override
	public boolean areCompatible(Histogram hist) {
		return hist instanceof FuzzyColorHistogram;
	}

	public void add(FuzzyColorHistogramQuantizer.Color color){
		int index = this.binNames.get(color.toString());
		this.bins[index]++;
	}

	public double getBin(FuzzyColorHistogramQuantizer.Color color){
		return getBin(color.toString());
	}

}


text:
package org.apache.sshd.common.digest;

import org.apache.sshd.common.NamedFactory;
import org.apache.sshd.common.OptionalFeature;

/**
 * @author Apache MINA SSHD Project
 */
// CHECKSTYLE:OFF
public interface DigestFactory extends DigestInformation, NamedFactory<Digest>, OptionalFeature {
    // nothing extra
}
// CHECKSTYLE:ON


text:
package org.elasticsearch.action.ingest;

import org.elasticsearch.action.Action;
import org.elasticsearch.client.ElasticsearchClient;

public class SimulatePipelineAction extends Action<SimulatePipelineRequest, SimulatePipelineResponse, SimulatePipelineRequestBuilder> {

    public static final SimulatePipelineAction INSTANCE = new SimulatePipelineAction();
    public static final String NAME = "cluster:admin/ingest/pipeline/simulate";

    public SimulatePipelineAction() {
        super(NAME);
    }

    @Override
    public SimulatePipelineRequestBuilder newRequestBuilder(ElasticsearchClient client) {
        return new SimulatePipelineRequestBuilder(client, this);
    }

    @Override
    public SimulatePipelineResponse newResponse() {
        return new SimulatePipelineResponse();
    }
}


text:
<!DOCTYPE html>

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

    <title>Tourist Spot</title>

    <link href="css/bootstrap.min.css" rel="stylesheet">

    <link href="css/portfolio-item.css" rel="stylesheet">

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

                </button>
                Explore

                        Country

                        Subscribe

                        Sign In

Tourist Spots

Theme Parks

A group of entertainment attractions, rides, and other events in a location for the enjoyment of large numbers of people. Amusement parks have a fixed location, as opposed to travelling funfairs and traveling carnivals, and are more elaborate than simple city parks or playgrounds, usually providing attractions meant to cater specifically to certain age groups, as well as some that are aimed towards all ages. Theme parks, a specific type of amusement park, are usually much more intricately themed to a certain subject or group of subjects than normal amusement parks.

More

Copyright © Your Website 2017


text:
#ifndef __FSL_PIT_HAL_H__
#define __FSL_PIT_HAL_H__

#include <assert.h>
#include <stdint.h>
#include <stdbool.h>
#include "fsl_device_registers.h"

/*!
 * @addtogroup pit_hal
 * @{
 */

/*******************************************************************************
 * Definitions
 ******************************************************************************/

/*! @brief Error codes for PIT driver. */
typedef enum _pit_status
{
    kStatus_PIT_Success = 0x00U,
    kStatus_PIT_Fail    = 0x01U
} pit_status_t;

/*******************************************************************************
 * API
 ******************************************************************************/

#if defined(__cplusplus)
extern "C" {
#endif

/*!
 * @name Initialization
 * @{
 */

/*!
 * @brief Enables the PIT module.
 *
 * This function enables the PIT timer clock (Note: this function does not un-gate
 * the system clock gating control). It should be called before any other timer
 * related setup.
 *
 * @param base Base address for current PIT instance.
 */
static inline void PIT_HAL_Enable(PIT_Type * base)
{
    PIT_BWR_MCR_MDIS(base, 0U);
}

/*!
 * @brief Disables the PIT module.
 *
 * This function disables all PIT timer clocks(Note: it does not affect the
 * SIM clock gating control).
 *
 * @param base Base address for current PIT instance.
 */
static inline void PIT_HAL_Disable(PIT_Type * base)
{
    PIT_BWR_MCR_MDIS(base, 1U);
}

/*!
 * @brief Configures the timers to continue  running or to stop in debug mode.
 *
 * In debug mode, the timers may or may not be frozen, based on the configuration of
 * this function. This is intended to aid software development, allowing the developer
 * to halt the processor, investigate the current state of the system (for example,
 * the timer values), and  continue the operation.
 *
 * @param base Base address for current PIT instance.
 * @param timerRun Timers run or stop in debug mode.
 *        - true:  Timers continue to run in debug mode.
 *        - false: Timers stop in debug mode.
 */
static inline void PIT_HAL_SetTimerRunInDebugCmd(PIT_Type * base, bool timerRun)
{
    PIT_BWR_MCR_FRZ(base, !timerRun);
}

#if FSL_FEATURE_PIT_HAS_CHAIN_MODE
/*!
 * @brief Enables or disables the timer chain with the previous timer.
 *
 * When a timer has a chain mode enabled, it  only counts after the previous
 * timer has expired. If the timer n-1 has counted down to 0, counter n
 * decrements the value by one. This allows the developers to chain timers together
 * and form a longer timer. The first timer (timer 0) cannot be chained to any
 * other timer.
 *
 * @param base Base address for current PIT instance.
 * @param channel  Timer channel number which is chained with the previous timer.
 * @param enable Enable or disable chain.
 *        - true:  Current timer is chained with the previous timer.
 *        - false: Timer doesn't chain with other timers.
 */
static inline void PIT_HAL_SetTimerChainCmd(PIT_Type * base, uint32_t channel, bool enable)
{
    assert(channel < FSL_FEATURE_PIT_TIMER_COUNT);
    PIT_BWR_TCTRL_CHN(base, channel, enable);
}

#endif /* FSL_FEATURE_PIT_HAS_CHAIN_MODE*/

/* @} */

/*!
 * @name Timer Start and Stop
 * @{
 */

/*!
 * @brief Starts the timer counting.
 *
 * After calling this function, timers load the start value as specified by the function
 * PIT_HAL_SetTimerPeriodByCount(PIT_Type * base, uint32_t channel, uint32_t count), count down to
 * 0, and  load the respective start value again. Each time a timer reaches 0,
 * it generates a trigger pulse and sets the time-out interrupt flag.
 *
 * @param base Base address for current PIT instance.
 * @param channel Timer channel number
 */
static inline void PIT_HAL_StartTimer(PIT_Type * base, uint32_t channel)
{
    assert(channel < FSL_FEATURE_PIT_TIMER_COUNT);
    PIT_BWR_TCTRL_TEN(base, channel, 1U);
}

/*!
 * @brief Stops the timer from counting.
 *
 * This function stops every timer from counting. Timers reload their periods
 * respectively after they call the PIT_HAL_StartTimer the next time.
 *
 * @param base Base address for current PIT instance.
 * @param channel Timer channel number
 */
static inline void PIT_HAL_StopTimer(PIT_Type * base, uint32_t channel)
{
    assert(channel < FSL_FEATURE_PIT_TIMER_COUNT);
    PIT_BWR_TCTRL_TEN(base, channel, 0U);
}

/*!
 * @brief Checks to see whether the current timer is started or not.
 *
 * @param base Base address for current PIT instance.
 * @param channel Timer channel number
 * @return Current timer running status
 *         -true: Current timer is running.
 *         -false: Current timer has stopped.
 */
static inline bool PIT_HAL_IsTimerRunning(PIT_Type * base, uint32_t channel)
{
    assert(channel < FSL_FEATURE_PIT_TIMER_COUNT);
    return PIT_BRD_TCTRL_TEN(base, channel);
}

/* @} */

/*!
 * @name Timer Period
 * @{
 */

/*!
 * @brief Sets the timer period in units of count.
 *
 * Timers begin counting from the value set by this function.
 * The counter period of a running timer can be modified by first stopping
 * the timer, setting a new load value, and  starting the timer again. If
 * timers are not restarted, the new value is loaded after the next trigger
 * event.
 *
 * @param base Base address for current PIT instance.
 * @param channel Timer channel number
 * @param count Timer period in units of count
 */
static inline void PIT_HAL_SetTimerPeriodByCount(PIT_Type * base, uint32_t channel, uint32_t count)
{
    assert(channel < FSL_FEATURE_PIT_TIMER_COUNT);
    PIT_WR_LDVAL(base, channel, count);
}

/*!
 * @brief Returns the current timer period in units of count.
 *
 * @param base Base address for current PIT instance.
 * @param channel Timer channel number
 * @return Timer period in units of count
 */
static inline uint32_t PIT_HAL_GetTimerPeriodByCount(PIT_Type * base, uint32_t channel)
{
    assert(channel < FSL_FEATURE_PIT_TIMER_COUNT);
    return PIT_RD_LDVAL(base, channel);
}

/*!
 * @brief Reads the current timer counting value.
 *
 * This function returns the real-time timer counting value, in a range from 0 to a
 * timer period.
 *
 * @param base Base address for current PIT instance.
 * @param channel Timer channel number
 * @return Current timer counting value
 */
static inline uint32_t PIT_HAL_ReadTimerCount(PIT_Type * base, uint32_t channel)
{
    assert(channel < FSL_FEATURE_PIT_TIMER_COUNT);
    return PIT_RD_CVAL(base, channel);
}

#if FSL_FEATURE_PIT_HAS_LIFETIME_TIMER
/*!
 * @brief Reads the current lifetime counter value.
 *
 * The lifetime timer is a 64-bit timer which chains timer 0 and timer 1 together.
 * Timer 0 and 1 are chained by calling the PIT_HAL_SetTimerChainCmd
 * before using this timer. The period of lifetime timer is equal to the "period of
 * timer 0 * period of timer 1". For the 64-bit value, the higher 32-bit has
 * the value of timer 1, and the lower 32-bit has the value of timer 0.
 *
 * @param base Base address for current PIT instance.
 * @return Current lifetime timer value
 */
uint64_t PIT_HAL_ReadLifetimeTimerCount(PIT_Type * base);
#endif /*FSL_FEATURE_PIT_HAS_LIFETIME_TIMER*/

/* @} */

/*!
 * @name Interrupt
 * @{
 */

/*!
 * @brief Enables or disables the timer interrupt.
 *
 * If enabled, an interrupt happens when a timeout event occurs
 * (Note: NVIC should be called to enable pit interrupt in system level).
 *
 * @param base Base address for current PIT instance.
 * @param channel  Timer channel number
 * @param enable Enable or disable interrupt.
 *        - true:  Generate interrupt when timer counts to 0.
 *        - false: No interrupt is generated.
 */
static inline void PIT_HAL_SetIntCmd(PIT_Type * base, uint32_t channel, bool enable)
{
    assert(channel < FSL_FEATURE_PIT_TIMER_COUNT);
    PIT_BWR_TCTRL_TIE(base, channel, enable);
}

/*!
 * @brief Checks whether the timer interrupt is enabled or not.
 *
 * @param base Base address for current PIT instance.
 * @param channel  Timer channel number
 * @return Status of enabled or disabled interrupt
 *        - true: Interrupt is enabled.
 *        - false: Interrupt is disabled.
 */
static inline bool PIT_HAL_GetIntCmd(PIT_Type * base, uint32_t channel)
{
    assert(channel < FSL_FEATURE_PIT_TIMER_COUNT);
    return PIT_BRD_TCTRL_TIE(base, channel);
}

/*!
 * @brief Clears the timer interrupt flag.
 *
 * This function clears the timer interrupt flag after a timeout event
 * occurs.
 *
 * @param base Base address for current PIT instance.
 * @param channel Timer channel number
 */
static inline void PIT_HAL_ClearIntFlag(PIT_Type * base, uint32_t channel)
{
    assert(channel < FSL_FEATURE_PIT_TIMER_COUNT);
    /* Write 1 will clear the flag. */
    PIT_WR_TFLG(base, channel, 1U);
}

/*!
 * @brief Reads the current timer timeout flag.
 *
 * Every time the timer counts to 0, this flag is set.
 *
 * @param base Base address for current PIT instance.
 * @param channel Timer channel number
 * @return Current status of the timeout flag
 *         - true:  Timeout has occurred.
 *         - false: Timeout has not yet occurred.
 */
static inline bool PIT_HAL_IsIntPending(PIT_Type * base, uint32_t channel)
{
    assert(channel < FSL_FEATURE_PIT_TIMER_COUNT);
    return PIT_RD_TFLG(base, channel);
}

/* @} */

#if defined(__cplusplus)
}
#endif

/*! @}*/

#endif /* __FSL_PIT_HAL_H__*/
/*******************************************************************************
* EOF
*******************************************************************************/


text:
@font-face {
    font-family: 'lucida grande';
    src: url('../fonts/6216-webfont.eot');
    src: url('../fonts/6216-webfont.eot?#iefix') format('embedded-opentype'),
         url('../fonts/6216-webfont.woff') format('woff'),
         url('../fonts/6216-webfont.ttf') format('truetype'),
         url('../fonts/6216-webfont.svg#lucida_granderegular') format('svg');
    font-weight: normal;
    font-style: normal;

}
/* RESET ---------------------------------------------------------*/
html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td,
article, aside, canvas, details, embed,
figure, figcaption, footer, header, hgroup,
menu, nav, output, ruby, section, summary,
time, mark, audio, video {
	margin: 0;
	padding: 0;
	border: 0;
	font-size: 100%;
	/*font: inherit;*/
	vertical-align: baseline;
}
body { line-height: 1; }
ol, ul { list-style: none; }
blockquote, q { quotes: none; }
blockquote:before, blockquote:after,
q:before, q:after { content: ''; content: none; }
table{ border-collapse: collapse; border-spacing: 0; }
a{ text-decoration: none; }

hr{
	display: none;
}
/* /RESET ---------------------------------------------------------*/
/* COPRS ----------------------------------------------------------*/
body{
	background: whitesmoke;
        /*background: #D7DEE9;*/
	height: 100%;
        font-family: "lucida grande", tahoma, verdana, arial, sans-serif;
}
.fb-like {
    position: absolute !important;
    top: 60px;
    right: 0px;
}
#page {
    position: relative;
    width: 710px;
    margin: 90px auto 50px;
    background: #fff;
    min-height: 450px;
    height: auto !important;
    height: 100%;
    box-shadow: 7px 7px 10px gray;
    border: 1px solid #999;
    border-radius: 5px;
}
#header a {
    width: 300px;
    height: 155px;
    display: block;
}
#logo {
	background: url('../images/logo.png') no-repeat 0 0;
	width: 300px;
	height: 155px;
	text-indent: -9999px;
        /*display: none;*/
}
#header a #logo{
    -webkit-transition: -webkit-transform 0.1s ease-in-out;/* Utilisé pour la transition sur chrome et safari */
    -moz-transition: -moz-transform 0.1s ease-in-out;/* Utilisé pour la transition sur Firefox */
    transition: transform 0.1s ease-in-out;
}
#header a:hover #logo{
    -moz-transform:rotate(7deg);
    -webkit-transform:rotate(7deg);
    -o-transform:rotate(7deg);
}

#header{
	position: absolute;
	top: 0;
	left: 50%;
	width: 710px;
	margin-left: -355px;
	z-index: 10;
}
#contenu {
    position: relative;
    /*min-height: 350px;*/
    margin-top: 130px;
    margin-left: 20px;
}
.push {margin-top: 175px;}
.push, #footer{
	height: 142px;
}
#cadreFooter{
	position: relative;
	margin: 0 auto;
	width: 710px;
}
#preload {
    width: 100%;
    height: 100%;
    position: absolute;
    background-color: #484848;
    z-index: 9999;
    border-radius: 3px;
}
#content {
    width: 400px;
    height: 200px;
    position: relative;
    top: 190px;
    margin: 0 auto;
}
#content img {
    margin-left: 45px;
}
#preload h2 {
    font-weight: 100;
    font-size: 16px;
    text-align: center;
    color: #f1f1f1;
    letter-spacing: 1px;
    margin-bottom: 20px;
}
#infoCharg {
text-align: center;
margin-left: -20px;
}
#preload p {
    font-weight: 300;
    font-size: 14px;
    color: #8e8e8e;
    display: inline-block;
}
.efface{display: none;}
/* /COPRS ---------------------------------------------------------*/
/* CONTENU --------------------------------------------------------*/
.navigation {
    position: relative;
    width: 667px;
    background: #fff;
    margin-bottom: 30px;
}
.navigation h2{
    margin-bottom: 10px;
}
.navigation > .toggleSubMenu ul li a{
	/*display: block;
	background: white;*/
        color: #000;
}
.navigation > .toggleSubMenu {
    position: relative;
    width: 667px;
}
.navigation > .toggleSubMenu > a {
    display: block;
    width: 657px;
    height: 65px;
    font-size: 25px;
    padding-left: 10px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid #d1d2d4;
    line-height: 62px;
}
#cadreImgTheme {
    position: relative;
    top: 67px;
    width: 667px;
    height: 67px;
    overflow: hidden;
    margin-left: 1px;
    margin-top: -67px;
}
.imgTheme{
    width: 667px;
    height: auto;
}
.imgQuizz {
    width: 210px;
    height: auto;
}
.navigation li ul {
    width: 661px;
    padding-left: 6px;
    border: 1px solid #d1d2d4;
    display: none;
}
.subMenu li {
    display: inline-block;
    width: 209px;
    margin-top: 10px;
    margin-right: 7px;
    /*margin-right: 10px;
    float: left;*/
}
.titleQuizz {
    display: block !important;
    width: 210px;
    text-align: center;
    float: left;
}
.toggleSubMenu .closeMenu, .toggleSubMenu .openMenu {
    position: absolute;
    top: 0px;
    right: 5px;
    color: #fff;
    font-size: 30px;
}
.open a .openMenu{display: block !important;}
.open a .closeMenu{display: none !important;}
.closeMenu{display: block;}
.openMenu{display: none;}
.infoRight {
    position: absolute;
    right: 5px;
    bottom: 5px;
    color: #fff;
    font-size: 13px;
}
.infoRight.begin {
    bottom: 25px;
}
#pk {
    margin-bottom: 45px;
}
#pk .lienAccueil {
    position: relative;
    top: 24px;
}
.navigation .lienAccueil {
    width: 100px;
    font-size: 14px;
    display: block;
    line-height: 5px;
    left: 0;
    margin-left: 106px;
}
.navigation .lienAccueil:hover{
   top: 2px;
   margin-left: 108px;
}
.lienAccueil {
    display: inline-block;
    width: 200px;
    height: 30px;
    background: #3b5998 !important;
    color: #fff !important;
    border: 2px solid whitesmoke;
    border-radius: 6px;
    text-align: center;
    line-height: 30px;
    box-shadow: 3px 3px 5px gray;
    position: relative;
    left: 50%;
    margin-left: -110px;
    margin-bottom: 30px;
}
.lienAccueil:hover {
    box-shadow: 1px 1px 4px gray;
    position: relative;
    top: 2px;
    margin-left: -108px;
}
/* /CONTENU-------------------------------------------------------- */
/* FB CSS-------------------------------------------------------- */
label{
    padding-top: 4px;
    padding-right: 6px;
    font-size: 15px;
    font-weight: bold;
    line-height: 14px;
    float: left;
    width: 110px;
    /*text-align: right;*/
    color: #666666;
}
table{
    margin-top: 10px;
}
q:before,
q:after,
blockquote:before,
blockquote:after {
  content: "";
}
html {
  font-size: 100%;
  -webkit-text-size-adjust: 100%;
  -ms-text-size-adjust: 100%;
}
a:focus {
  outline: thin dotted;
}
a:hover, a:active {
  outline: 0;
}
article,
aside,
details,
figcaption,
figure,
footer,
header,
hgroup,
nav,
section {
  display: block;
}
audio, canvas, video {
  display: inline-block;
  *display: inline;
  *zoom: 1;
}
audio:not([controls]) {
  display: none;
}
sub, sup {
  font-size: 75%;
  line-height: 0;
  position: relative;
  vertical-align: baseline;
}
sup {
  top: -0.5em;
}
sub {
  bottom: -0.25em;
}
img {
  border: 0;
  -ms-interpolation-mode: bicubic;
}
button,
input,
select,
textarea {
  font-size: 100%;
  margin: 0;
  vertical-align: baseline;
  *vertical-align: middle;
}
button, input {
  line-height: normal;
  *overflow: visible;
}
button::-moz-focus-inner, input::-moz-focus-inner {
  border: 0;
  padding: 0;
}
button,
input[type="button"],
input[type="reset"],
input[type="submit"] {
  cursor: pointer;
  -webkit-appearance: button;
}
input[type="search"] {
  -webkit-appearance: textfield;
  -webkit-box-sizing: content-box;
  -moz-box-sizing: content-box;
  box-sizing: content-box;
}
input[type="search"]::-webkit-search-decoration {
  -webkit-appearance: none;
}
textarea {
  overflow: auto;
  vertical-align: top;
}
.toggleSubMenu > a {
  color: #fff;
  text-decoration: none;
  line-height: inherit;
  font-weight: inherit;
}
.toggleSubMenu > a:hover {
  color: #3b5998;
  /*text-decoration: underline;*/
}
hr {
  margin: 20px 0 19px;
  border: 0;
  border-bottom: 1px solid #eee;
}
strong {
  font-style: inherit;
  font-weight: bold;
}
em {
  font-style: italic;
  font-weight: inherit;
  line-height: inherit;
}
form {
  margin-bottom: 14px;
}
fieldset {
  margin-bottom: 14px;
  padding-top: 14px;
}
fieldset legend {
  display: block;
  padding-left: 150px;
  font-size: 16.5px;
  line-height: 1;
  color: #333333;
  *padding: 0 0 5px 145px;
  /* IE6-7 */

  *line-height: 1.5;
  /* IE6-7 */

}
form .clearfix {
  margin-bottom: 14px;
  zoom: 1;
}
form .clearfix:before, form .clearfix:after {
  display: table;
  content: "";
  zoom: 1;
}
form .clearfix:after {
  clear: both;
}
input,
select,
textarea {
  font-family: "lucida grande", tahoma, verdana, arial, sans-serif;
  font-size: 11px;
  font-weight: normal;
  line-height: 14px;
}
form .input {
  margin-left: 150px;
}
input[type=checkbox], input[type=radio] {
  cursor: pointer;
}
input,
textarea,
select,
.uneditable-input {
  display: inline-block;
  width: 210px;
  height: 14px;
  padding: 4px;
  font-size: 11px;
  margin-bottom: 15px;
  line-height: 14px;
  color: #666666;
  border: 1px solid #d4dae8;
  -webkit-border-radius: 0px;
  -moz-border-radius: 0px;
  border-radius: 0px;
}
select {
  padding: 2px;
  padding: initial;
}
input[type=checkbox], input[type=radio] {
  width: auto;
  height: auto;
  padding: 0;
  margin: 3px 0;
  *margin-top: 0;
  /* IE6-7 */

  line-height: normal;
  border: none;
}
input[type=file] {
  background-color: #ffffff;
  padding: initial;
  border: initial;
  line-height: initial;
  -webkit-box-shadow: none;
  -moz-box-shadow: none;
  box-shadow: none;
}
input[type=button], input[type=reset], input[type=submit] {
  width: auto;
  height: auto;
}
select, input[type=file] {
  height: 21px;
  *height: auto;
  line-height: 21px;
  *margin-top: 4px;
  /* For IE7, add top margin to align select with labels */

}
select[multiple] {
  height: inherit;
  background-color: #ffffff;
}
textarea {
  height: auto;
}
.uneditable-input {
  background-color: #ffffff;
  display: block;
  border-color: #eee;
  -webkit-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.025);
  -moz-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.025);
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.025);
  cursor: not-allowed;
}
:-moz-placeholder {
  color: #999999;
}
::-webkit-input-placeholder {
  color: #999999;
}
input, textarea {
  -webkit-transition: border linear 0.2s, box-shadow linear 0.2s;
  -moz-transition: border linear 0.2s, box-shadow linear 0.2s;
  -ms-transition: border linear 0.2s, box-shadow linear 0.2s;
  -o-transition: border linear 0.2s, box-shadow linear 0.2s;
  transition: border linear 0.2s, box-shadow linear 0.2s;
  -webkit-box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
  -moz-box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
}
input:focus, textarea:focus {
  outline: 0;
  border-color: rgba(82, 168, 236, 0.8);
  -webkit-box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1), 0 0 8px rgba(82, 168, 236, 0.6);
  -moz-box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1), 0 0 8px rgba(82, 168, 236, 0.6);
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1), 0 0 8px rgba(82, 168, 236, 0.6);
}
input[type=file]:focus, input[type=checkbox]:focus, select:focus {
  -webkit-box-shadow: none;
  -moz-box-shadow: none;
  box-shadow: none;
  outline: 1px dotted #666;
}
/* /FB CSS------------------------------------------------------- */

.flip-container {
    -webkit-perspective: 1000;
    -moz-perspective: 1000;
    perspective: 1000;
    width: 210px;
    height: 150px;
}

.flip-container:hover .flipper, .flip-container.hover .flipper {
    -webkit-transform: rotateY(180deg);
    -moz-transform: rotateY(180deg);
    transform: rotateY(180deg);
}

.flip-container, .front, .back {
    width: 210px;
    height: 150px;
    margin-bottom: 10px;
}

.flipper {
    -webkit-transition: 0.6s;
    -webkit-transform-style: preserve-3d;
    -moz-transition: 0.6s;
    -moz-transform-style: preserve-3d;
    transition: 0.6s;
    transform-style: preserve-3d;
    position: relative;
}

.front, .back {
    -webkit-backface-visibility: hidden;
    -moz-backface-visibility: hidden;
    backface-visibility: hidden;
    position: absolute;
    top: 0px;
    left: 0px;
}

.front {
    z-index: 2;
}

.back {
    -webkit-transform: rotateY(180deg);
    -moz-transform: rotateY(180deg);
    transform: rotateY(180deg);
    background: #3B5997;
    width: 200px;
    height: 140px;
    padding: 5px;
}

.navigation li{
    position:relative;
}

.navigation li .fb-like {
    position: absolute !important;
    top: 180px;
    left: 0;
}

.navigation li .fb_iframe_widget span, .navigation li .fb_iframe_widget iframe  {
    height:auto !important;
    width:auto !important;
}


text:
const {User} = require('./../node-samples/mongo-api/models/UserModel')

// This method is used like Middleware
let authenticate = async (req, res, next) => {
    let token = req.header('x-auth')

    if(!token) return res.status(401).json({'error': 'A valid token must be set in x-auth header!'})

    let user = null

    try {
        /**
         * User.findByToken === SchemaUser.statics.findByToken
         */
        user = await User.findByToken(token)
    } catch (e){
        // console.error(e.message)
        return res.status(401).json({'error':e.message})
    }

    if( user === null ) return res.status(404).json({'error': 'The given token is unauthorized (no such user)'})

    // мы можем произвольно добавлять поля в объекты req и res, а потом пользоваться ими в функциях-обработчиках соответсвующих запросов
    res.user = user // возможно, более правильно юзать req.user
    req.token = token // решил положить токен в request

    next()
};

module.exports = {
    authenticate
}


text:
#import <Foundation/Foundation.h>

@interface ResourceManagerUtil : NSObject

+ (void) populateResourcePopup:(NSPopUpButton*)popup resType:(int)resType allowSpriteFrames:(BOOL)allowSpriteFrames selectedFile:(NSString*)file selectedSheet:(NSString*) sheetFile target:(id)target;

+ (NSString*) relativePathFromAbsolutePath: (NSString*) path;

+ (void) setTitle:(NSString*)str forPopup:(NSPopUpButton*)popup;

@end


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

    <groupId>GroupDocs.Viewer.Examples.Java</groupId>
    <artifactId>GroupDocs.Viewer.Examples.Java</artifactId>
    <version>22.9</version>

    <properties>
        <maven.compiler.source>8</maven.compiler.source>
        <maven.compiler.target>8</maven.compiler.target>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    </properties>

    <repositories>
        <repository>
            <id>groupdocs-artifact-repository</id>
            <name>groupdocs-artifact-repository</name>
            <url>https://repository.groupdocs.com/repo/</url>
        </repository>
    </repositories>

    <dependencies>
        <dependency>
            <groupId>commons-net</groupId>
            <artifactId>commons-net</artifactId>
            <version>3.5</version>
        </dependency>
        <dependency>
            <groupId>org.apache.commons</groupId>
            <artifactId>commons-lang3</artifactId>
            <version>3.4</version>
        </dependency>
        <dependency>
            <groupId>commons-io</groupId>
            <artifactId>commons-io</artifactId>
            <version>2.8.0</version>
        </dependency>
        <dependency>
            <groupId>com.fasterxml.jackson.core</groupId>
            <artifactId>jackson-databind</artifactId>
            <version>2.12.6.1</version>
        </dependency>
        <dependency>
            <groupId>com.fasterxml.jackson.core</groupId>
            <artifactId>jackson-annotations</artifactId>
            <version>2.12.1</version>
        </dependency>
        <dependency>
            <groupId>com.groupdocs</groupId>
            <artifactId>groupdocs-viewer</artifactId>
            <version>${project.version}</version>
        </dependency>
        <dependency>
            <groupId>org.testng</groupId>
            <artifactId>testng</artifactId>
            <version>7.4.0</version>
            <scope>test</scope>
        </dependency>
    </dependencies>

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

        <plugins>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>exec-maven-plugin</artifactId>
                <version>1.6.0</version>
                <executions>
                    <execution>
                        <goals>
                            <goal>java</goal>
                        </goals>
                    </execution>
                </executions>
                <configuration>
                    <mainClass>com.groupdocs.viewer.examples.RunExamples</mainClass>
                    <cleanupDaemonThreads>false</cleanupDaemonThreads>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-plugin</artifactId>
                <version>3.0.0-M5</version>
                <configuration>
                    <useSystemClassLoader>false</useSystemClassLoader>
                    <forkCount>0</forkCount>
                    <reuseForks>false</reuseForks>
                    <runOrder>alphabetical</runOrder>
                    <parallel>none</parallel>
                    <failIfNoTests>true</failIfNoTests>
                    <suiteXmlFiles>
                        <suiteXmlFile>${project.basedir}/src/test/resources/testng.xml</suiteXmlFile>
                    </suiteXmlFiles>
                </configuration>
            </plugin>
        </plugins>
    </build>
</project>


text:
0.0.1.pre / 2014-04-27
======================

  * Finished 0.0.1.pre
  * Better i18n
  * Small design fixes
  * Moved people model into module
  * Lots of improvments
  * Better frontend
  * Basic admin area
  * First shot at organisation and business unit frontend
  * Added models
  * Added translations
  * First commit


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

using Xamarin.Forms;

namespace DemoPages
{
	public partial class PageTabbed : TabbedPage
	{
		public PageTabbed ()
		{
			InitializeComponent ();

		}
	}
}


text:
<!DOCTYPE html>

<title>eCommerce Store</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="<?php echo base_url('assets/css/bootstrap.css');?>" type="text/css" />
<link rel="stylesheet" href="<?php echo base_url('assets/css/style.css');?>" type="text/css" />
 <link rel="icon" href="<?php echo base_url('assets/images/cgcolors.png');?>" type="image/gif" sizes="16x16">
 <link href="https://fonts.googleapis.com/css?family=Lato:300,300i,400,700,700i,900" rel="stylesheet">

<a href="<?php echo base_url();?>"><img src="<?php echo base_url();?>assets/images/coming-soon-logo.png">

Toll Free Number
	+1 800. 125. 8542

Social Media Icons

  ×

<a href="<?php echo base_url();?>">Home

<a href="<?php echo base_url();?>about">About

<a href="<?php echo base_url();?>features">Features

<a href="<?php echo base_url();?>plans">Pricing

<a href="<?php echo base_url();?>faq">FAQ

<a href="<?php echo base_url();?>support">Support

☰

	  <input type="search" name="" value="" placeholder="Search" />