text:
Tags represent the metadata that can be added to documentation through the `@tag`
style syntax:

    # @tagname some data
    class Foo
    end

The above example adds metadata under the name `tagname` to the Foo class object.

Tags are the best way to add arbitrary metadata when documenting an object in a
way to access it later without having to parse the entire comment string. The
rest of the document will describe the tag syntax, how to access the tag
metadata and how to extend YARD to support custom tags or override existing tags.

## Tag Syntax

Tags begin with "@tagname" at the start of a comment line. Tags can span multiple
lines if the subsequent lines are indented by more than one space. The following
syntax is valid:

    # @tagname This is
    #   tag data
    # but this is not

In the above example, "@tagname" will have the text *"This is tag data"*.

If a tag's data begins with `(see NAME)` it is considered a "reference tag".
The syntax and semantics of a reference tag are discussed in the section below
titled "[Reference Tags](#reftags)"

Although custom tags can be parsed in any way, the built-in tags follow a few
common syntax structures by convention in order to simplify the syntax. The
following syntaxes are available:

### Freeform Data

This syntax has no special syntax, it is simply a tagname followed by any
data.

    @tagname data here

### Freeform Data With Title

Occasionally a freeform tag may reserve the first line for a title (or some
other associative identifier) and treat only the subsequent indented lines as
the tag data. Two examples are the `@example` and `@overload` tags. In the case
of `@example` the first line is a title, and in the case of `@overload` the
first line is the method signature for the overload. Here is an example of both:

    @example Reverse a string
      "hello world".reverse

    @overload request(method = :get, url = 'http://example.com')
      Performs a request on +url+
      @param [Symbol] method the request method
      @param [String] url the URL to perform the request on
      @return [String] the result body (no headers)

### Data With Optional Type Information

This syntax optionally contains type information to be associated with the
tag. Type information is specified as a freeform list of Ruby types, duck
types or literal values. The following is a valid tag with type information:

    @return [String, #read] a string or object that responds to #read

### Data With Name and Optional Type Information

A special case of the above data with optional type information is the case
of tags like `@param`, where the data is further associated with a key. In
the case of `@param` the key is an argument name in the method. The following
shows how this can be used:

    @param [String] url the URL to perform the request on

Note that "url" in the above example is the key name. The syntax is of the form:

    @tagname [types] <name> <description>

As mentioned, types are optional, so the following is also valid:

    @param url the URL to perform the request on

## List of Available Tags

YARD supplies the following built-in tags:

  * `@abstract`: Marks a class/module/method as abstract with optional
    implementor information.

        @abstract Subclass and override {#run} to implement a custom Threadable class.

  * `@api`: Declares the API that the object belongs to. Does not display in
    output, but useful for performing queries (`yardoc --query`). Any text is
    allowable in this tag, and there are no predefined values(*).

        @api freeform text

    (*) Note that the special name `@api private` does display a notice in
    documentation if it is listed, letting users know that the method is not
    to be used.

  * `@attr`: Declares an attribute from the docstring of a class. Meant to be
    used on Struct classes only (classes that inherit Struct).

        @attr [Types] attribute_name a full description of the attribute

  * `@attr_reader`: Declares a readonly attribute from the docstring of a class.
    Meant to be used on Struct classes only (classes that inherit Struct). See `@attr`.

        @attr_reader [Types] name description of a readonly attribute

  * `@attr_writer`: Declares a writeonly attribute from the docstring of class.
    Meant to be used on Struct classes only (classes that inherit Struct). See `@attr`.

        @attr_writer [Types] name description of writeonly attribute

  * `@attribute`: Recognizes a DSL class method as an attribute with the given
    name. Also accepts the r, w, or rw flag to signify that the attribute is
    readonly, writeonly, or readwrite (default). Only used with DSL methods.

        @attribute [rw|r|w] NAME

  * `@author`: List the author(s) of a class/method

        @author Full Name

  * `@deprecated`: Marks a method/class as deprecated with an optional
    reason.

        @deprecated Describe the reason or provide alt. references here

  * `@example`: Show an example snippet of code for an object. The
    first line is an optional title.

        @example Reverse a string
          "mystring".reverse #=> "gnirtsym"

  * `@macro`: Registers or expands a new macro. See the [Macros](#macros)
    section for more details. Note that the name parameter is never optional.

        @macro [new|attached] macro_name
          The macro contents to expand

  * `@method`: Recognizes a DSL class method as a method with the given name
    and optional signature. Only used with DSL methods.

        @method method_signature(opts = {}, &block)

  * `@note`: Creates an emphasized note for the users to read about the
    object.

        @note This method should only be used in outer space.

  * `@option`: Describe an options hash in a method. The tag takes the
    name of the options parameter first, followed by optional types,
    the option key name, an optional default value for the key and a
    description of the option.

        # @param [Hash] opts the options to create a message with.
        # @option opts [String] :subject The subject
        # @option opts [String] :from ('nobody') From address
        # @option opts [String] :to Recipient email
        # @option opts [String] :body ('') The email's body
        def send_email(opts = {})
        end

  * `@overload`: Describe that your method can be used in various
    contexts with various parameters or return types. The first
    line should declare the new method signature, and the following
    indented tag data will be a new documentation string with its
    own tags adding metadata for such an overload.

        # @overload set(key, value)
        #   Sets a value on key
        #   @param [Symbol] key describe key param
        #   @param [Object] value describe value param
        # @overload set(value)
        #   Sets a value on the default key `:foo`
        #   @param [Object] value describe value param
        def set(*args)
        end

  * `@param`: Defines method parameters

        @param [optional, types, ...] argname description

  * `@private`: Defines an object as private. This exists for classes,
    modules and constants that do not obey Ruby's visibility rules. For
    instance, an inner class might be considered "private", though Ruby
    would make no such distinction. By declaring the @private tag, the
    class can be hidden from documentation by using the `--no-private`
    command-line switch to yardoc (see {file:README.md}).

        @private

  * `@raise`: Describes an Exception that a method may throw

        @raise [ExceptionClass] description

  * `@return`: Describes return value of method

        @return [optional, types, ...] description

  * `@scope`: Sets the scope of a DSL method. Only applicable to DSL method
    calls. Acceptable values are 'class' or 'instance'

        @scope class|instance

  * `@see`: "See Also" references for an object. Accepts URLs or
    other code objects with an optional description at the end.

        @see http://example.com Description of URL
        @see SomeOtherClass#method

  * `@since`: Lists the version the feature/object was first added

        @since 1.2.4

  * `@todo`: Marks a TODO note in the object being documented

        @todo Add support for Jabberwocky service
          There is an open source Jabberwocky library available
          at http://somesite.com that can be integrated easily
          into the project.

  * `@version`: Lists the version of a class, module or method

        @version 1.0

  * `@visibility`: Sets the visibility of a DSL method. Only applicable to
    DSL method calls. Acceptable values are public, protected, or private.

        @visibility public|protected|private

  * `@yield`: Describes the block. Use types to list the parameter
    names the block yields.

        # for block {|a, b, c| ... }
        @yield [a, b, c] Description of block

  * `@yieldparam`: Defines parameters yielded by a block

        @yieldparam [optional, types, ...] argname description

  * `@yieldreturn`: Defines return type of a block

        @yieldreturn [optional, types, ...] description

## Reference Tags

Although attempt is made in YARD to leave as many of the syntax details as
possible to the factory provider, there is a special tag syntax for referencing
tags created in other objects so that they can be reused again. This is common
when an object describes a return type or parameters that are passed through to
other methods. In such a case, it is more manageable to use the reference tag
syntax. Consider the following example:

    class User
      # @param [String] username the nam of the user to add
      # @param [Number] uid the user ID
      # @param [Number] gid the group ID
      def initialize(username, uid, gid)
      end
    end

    module UserHelper
      # @param (see User#initialize)
      def add_user(username, uid, gid)
        User.new(username, uid, gid)
      end

      # @param username (see User#initialize)
      def add_root_user(username)
        User.new(username, 0, 0)
      end
    end

Because the UserHelper module methods delegate directly to `User.new`, copying
the documentation details would be unmaintainable. In this case, the (see METHODNAME)
syntax is used to reference the tags from the User constructor to the helper methods.
For the first method, all `@param` tags are referenced in one shot, but the second
method only references one of the tags by adding `username` before the reference.

Reference tags are represented by the {YARD::Tags::RefTag} class and are created
directly during parsing by {YARD::Docstring}.

## Macros

Macros enable the documenter to write repetitive documentation once and then
re-apply it to other objects. Macros are defined on docstrings using the
`@macro` tag. The same `@macro` tag is used to expand them. The following
is an example of a simple macro declaration and expansion:

    # @macro [new] string_attr
    # @return [String] the attribute +$1+ as a String
    attr_accessor :foo

    # @macro string_attr
    attr_accessor :bar

In the above example, both attributes `foo` and `bar` will get the docstring
that includes a return tag "the attribute as a String". It would be equivalent
to writing the following:

    # @return [String] the attribute +foo+ as a String
    attr_accessor :foo

    # @return [String] the attribute +bar+ as a String
    attr_accessor :bar

### Creating a Macro

If the macro does not already exist, it will be created if:

  1. there are interpolation variables (`$1`, `$2`, `${3-5}`, etc.) in the
     docstring, or,
  2. the macro is specified with the `[new]` or `[attached]` flag.

For instance, creating a new macro might look like (see the section on
interpolation below for a description of the `$2` syntax):

    # @macro the_macro_name
    # @return [$2] the thing to return
    typed_attribute :foo, String

Or:

    # @macro [new] the_macro_name
    # Returns a string!
    def foo; end

You can also "attach" a macro to a method if it is in the class scope. In
this case, you do not need to also provide the 'new' flag, using 'attach'
is sufficient:

    # @macro [attach] the_macro_name
    #   @return [String] the string value
    def self.foo; end

Any time 'foo' is called in the class scope of an inheriting class, the macro
will automatically expand on that method call (potentially creating a new
method object). Attaching macros is discussed below.

Note that the name is never optional. Even if the macro is never re-used,
it must be named.

### Indenting the Macro Data

If a macro tag has an indented body of macro data (shown below), it will be
the only portion of the docstring saved for re-use.

    # @macro [new] macro_name
    #   The macro data is here.
    # This data is only used for the current object
    def method; end

In the above case, "The macro data is here." is the only portion that will be
re-used if the macro is called again on another object. However, for the case
of the above method, both the macro data and the local docstring will be
applied to the method, creating the docstring:

    # The macro data is here.
    # This data is only used for the current object.
    def method; end

You can therefore keep portions of docstrings local to objects even when
creating a macro, by indenting the portion of the data that should be re-
expanded, and listing the local docstring data above or below.

If there is no indented macro data, the entire docstring is saved as the
macro data. For instance,

    # @macro [new] macro_name
    # The macro data is here.
    # This data is also used for all macros.
    def method; end

In the above case, the macro 'macro_name' will always show both lines of text
when expanded on other objects.

### Attaching a Macro to a DSL (Class) Method

Macros can be created on class level methods (or class level method calls) in
order to implicitly expand a macro whenever that method is subsequently called
in a class, or any class that mixes in or inherits the method. These macros
are called "attached" and are declared with the `[attach]` flag. For instance,
a library that uses a class level method call `property` in its codebase can
document these declarations in any future call like so:

    class Resource
      # Defines a new property
      # @param [String] name the property name
      # @param [Class] type the property's type
      # @macro [attach] property
      #   @return [$2] the $1 property
      def self.property(name, type) end
    end

    class Post < Resource
      property :title, String
      property :view_count, Integer
    end

If you cannot declare the macro on the actual method declaration, you can
arbitrarily attach the macro to any method call. Suppose we only had the
Post class in our codebase, we could add the macro to the first usage of
the `property` call:

    class Post < Resource
      # @macro [attach] property
      # @return [$2] the $1 property
      property :title, String
      property :view_count, Integer
    end

### Macro Variable Interpolation Syntax

The interpolation syntax is similar to Ruby's regular expression variable syntax.
It uses $1, $2, $3, ..., referring to the Nth argument in the method call. Using
the above property example, $1 would be 'title', and $2 would be 'String'.
$0 is a special variable that refers to the method call itself, in this case
'property'. Finally, there is a $& variable which refers to the full line,
or 'property :title, String'.

#### Ranges

Ranges are also acceptable with the syntax `${N-M}`. Negative values on either
N or M are valid, and refer to indexes from the end of the list. Consider
a DSL method that creates a method using the first argument with argument
names following, ending with the return type of the method. This could be
documented as:

    # @macro dsl_method
    # @method $1(${2--2})
    # @return [${-1}] the return value of $0
    create_method_with_args :foo, :a, :b, :c, String

As described, the method is using the signature `foo(a, b, c)` and the return
type from the last argument, `String`. When using ranges, tokens are joined
with commas. Note that this includes using $0:

    $0-1 # => Interpolates to "create_method_with_args, foo"

If you want to separate them with spaces, use `$1 $2 $3 $4 ...`. Note that
if the token cannot be expanded, it will return the empty string (not an error),
so it would be safe to list `$1 $2 ... $10`, for example.

#### Escaping Interpolation

Interpolation can be escaped by prefixing the `$` with `\`, like so:

    # @macro foo
    #   I have \$2.00 USD.

## Programmatic API

### Accessing Tag Information

Tag metadata is added when a {YARD::Docstring} is added to a {file:docs/CodeObjects.md code object}
using the {YARD::CodeObjects::Base#docstring=} attribute. In addition to adding
conventional comments, tags are parsed and associated with the object. The easiest
way to access tags on an object is to use the {YARD::CodeObjects::Base#tag} and `#tags`
methods, for example:

    # Using the Foo class object from above
    obj.tags(:tagname).first.text #=> "some data"

Because multiple tags can be stored with the same name, they are stored as a list
of tags. The `#tag` method is an alias for the first item in the list of tags.
Also note that the `#tag`, `#tags` and `#has_tag?` methods are all convenience
methods that delegate to the {YARD::Docstring} object described above.

### Adding Custom Tags

The `@tagname` tag used in the above examples is clearly not part of the tags
that come with YARD. If such a tag would actually be part of documentation under
a default install, YARD would raise a warning that the tag does not exist. It is,
however, trivial to add this tag to be recognized by YARD.

All tags in YARD are added to the {YARD::Tags::Library tag library} which makes
use of a tag factory class to parse the data inside the tags. To simply add a
tag that stores simple text like our `@tagname` tag above, use:

    YARD::Tags::Library.define_tag("A Sample Tag", :tagname)

This will now allow YARD to add the metadata from `@tagname` to the docstring.

## Tag Factory Architecture

Recognizing a tag is one part of the process. Parsing the tag contents is the
second step. YARD has a tag architecture that allows developers to add or completely
change the way tags contents can be parsed.

The separation of registration and tag creation can be seen in the following
class diagram:

![Tags Architecture Class Diagram](images/tags-class-diagram.png)

### DefaultFactory

By default, YARD has a few standard syntaxes that can be parsed for tags. These
are all implemented by the {YARD::Tags::DefaultFactory} class. These syntaxes
are:

  * Standard text: no parsing is done, but text is stripped of newlines and
    multiple spaces.

  * Raw text: does no parsing at all, no stripping of newlines or spaces. This
    is best used for code snippets.

  * Raw text with title: does no parsing on the text but extracts the first line
    of the metadata as the "title", useful for tags such as `@example`:

        # @example Inspect an element
        #   myobj.inspect #=> #<Object:0x123525>

  * Text with types: parses a list of types at the beginning of the text. Types
    are optional. The standard syntax is in the form `[type1, type2, ...]`,
    for example:

        # @return [String, Symbol] a description here
        # @return description here with no types

  * Text with types and a name: parses a list of types at the beginning of text
    followed by a name and extra descriptive text. For example:

        # @param [String] str the string to reverse
        def reverse(str) '...' end

As mentioned above, this syntax is implemented by the `DefaultFactory` which can
be swapped out for any factory. In some cases, a developer may want to change
the type declaration syntax to be in the form:

    # @tagname name <Types, here> description

This can be done by simply implementing a new factory that parses the data in
this form.

### Implementing a Factory

Factories should implement the method `parse_tag` as well as any `parse_tag_SUFFIX`
method where SUFFIX refers to the suffix added when declaring the tag. For example,
a tag can also be declared as follows:

    YARD::Tags::Library.define_tag "Parameter", :param, :with_types

In such a case, the factory will be called with method `parse_tag_with_types`. In
all cases, the method should return a new {YARD::Tags::Tag} object. Generally,
the `parse_tag` methods take 2 or 3 parameters. A simple tag can be implemented
as:

    def parse_tag(tag_name, text)
      Tag.new(tag_name, text)
    end

The text parameter contains pre-parsed text with extra spaces and newlines removed.
If required, the method could also be declared with a third parameter containing
unmodified raw text:

    def parse_tag_with_raw_text(tag_name, text, raw_text)
      Tag.new(tag_name, raw_text)
    end

Note that this method would be invoked for a tag declared with the `:with_raw_text`
suffix.

### Changing the Factory

To change the factory, set the {YARD::Tags::Library.default_factory} attribute:

    YARD::Tags::Library.default_factory = MyFactory

This must be done before any parsing is done, or the factory will not be used.


text:
import { BoundingBox } from './BoundingBox';
import { Vector3 } from './Vector3';
import { Matrix4 } from './Matrix4';
import { Plane } from './Plane';

export class Frustum {

    planes: Plane[];

    boundingBox: BoundingBox;

    vertices: Float32Array[];

    setFromProjection(projectionMatrix: Matrix4): void;

    getTransformedBoundingBox(bbox: BoundingBox, matrix: Matrix4): BoundingBox;
}

redpajama_set_name: RedPajamaGithub


text:
@font-face {
font-family:'BebasNeue Book';
src:url('../fonts/BebasNeue Book.otf'),url('../fonts/BebasNeue Book.ttf');
font-weight:400;
font-style:normal
}

@font-face {
font-family:'BebasNeue Bold';
src:url('../fonts/BebasNeue Bold.otf');
font-weight:400;
font-style:normal
}

@font-face {
font-family:'BebasNeue Regular';
src:url('../fonts/BebasNeue Regular.otf');
font-weight:400;
font-style:normal
}

body {
color:#000;
font-family:'Roboto Condensed',sans-serif;
overflow-x:hidden;
text-align:center;
font-size:20px;
font-weight:300
}

html {
overflow-x:hidden
}

strong {
font-weight:400
}

a,a:focus,a:hover {
text-decoration:none
}

.center {
text-align:center
}

.left {
text-align:left
}

.right {
text-align:right
}

.white {
color:#fff
}

.breadcrumb {
background-color:transparent;
text-align:left;
padding-left:0
}

.breadcrumb li a {
color:#3FA9F5;
border-bottom:1px solid #3FA9F5;
text-decoration:none;
font-size:13px;
font-weight:200
}

.breadcrumb>li:after {
padding:0 2px 0 9px;
color:#a0a0a0;
content:"/\00a0";
font-size:13px
}

.breadcrumb>li:before,.breadcrumb>li.active:after {
display:none
}

.navbar-inverse .row-header {
display:none
}

.breadcrumb>.active {
color:#999;
font-size:13px;
font-weight:200
}

.navbar-inverse .name-brand {
color:#000;
font-size:34px;
font-weight:600;
height:inherit;
margin-right:0;
}

.p-7 {
margin-left:-7px;
margin-right:-7px
}

.p-7 [class*="col-"] {
padding-right:7px;
padding-left:7px
}

.p-3 {
margin-left:-3px;
margin-right:-3px
}

.p-3 [class*="col-"] {
padding-right:3px;
padding-left:3px
}

.block-right {
margin-top:30px
}

.footer-info {
background-color:#f5f5f5;
padding:14px 0 3px;
font-size:16px
}

a.user-link {color: #000;border-bottom: 1px solid #000;text-decoration:none;font-size:50%;}

a.user-link:focus {
outline:none
}

a.user-link > span {
font-size:200%;
line-height:normal
}

a.user-link:hover,a.user-link:active {
border-bottom:none
}

a.no-line {}

a.no-line:hover,a.no-line:active {border-bottom: 1px solid #b28a69;}

.back-btn,.next-btn,.total-btn {
display:table;
width:100%;
max-width:136px;
text-align:center;
font-size:16px;
border-radius:6px;
-webkit-border-radius:6px;
-moz-border-radius:6px
}

#jc .total-btn {
position:inherit;
margin-bottom:0;
margin-top:25px
}

#jc .captcha {
margin-bottom:10px;
cursor:pointer
}

#jc .captcha-btn {
cursor:pointer;
font-weight:400
}

#jc #comments-form-buttons a {
color:#FFF
}

#jc #comments-form-message {
margin-bottom:15px
}

#jc .comments-form-message-error {
color:#C00
}

#jc .comments-form-message-info {
color:#0C0
}

#jc .user-name {
font-size:16px
}

#jc .date-post {
color:#a0a0a0;
font-size:14px
}

#jc a.user-link {
font-size:11px
}

#jc .refresh.reveal {
max-width:280px
}

#jc {
font-size:16px;
color:#666
}

#jc h4,.comments_p {
color:#000
}

.modal .alert {
font-weight:200;
padding:0;
font-size:16px
}

.back-btn,.back-btn:hover,.back-btn:active {
color:#b4b4b4;
border:1px solid #b4b4b4;
padding:9px 0;
font-weight:200
}

.next-btn {
color:#fff!important;
background-color:#ff0042;
padding:10px 0;
font-weight:200
}

.total-btn {
color:#fff;
background-color:#feb20f;
padding:10px 0;
font-weight:200;
margin-bottom:25px;
position:absolute;
left:calc(100% - 150px);
bottom:-87px
}

.add-btn {
background-color:#3ac1e1;
margin-bottom:0;
bottom:inherit!important;
left:calc(100% - 141px)
}

a.next-btn:hover,a.total-btn:hover,a.next-btn:active,a.total-btn:active,a.add-btn:hover,a.add-btn:active {
color:#fff
}

.panel-heading .accordion-toggle:after {
content:url(../images/arrow-panel.png);
float:right;
margin-top:-3px;
color:transparent
}

.panel-heading .accordion-toggle.collapsed:after {
content:url(../images/arrow-panel.png);
-moz-transform:rotate(180deg);
-ms-transform:rotate(180deg);
-webkit-transform:rotate(180deg);
-o-transform:rotate(180deg);
transform:rotate(180deg);
margin-top:-1px
}

.w-main {
max-width:1000px;
width:100%;
padding:0;
margin:0 auto
}

.f-14 {
font-size:14px;
line-height:17px
}

.f-15 {
font-size:15px;
line-height:17px
}

.f-17 {
font-size:17px;
line-height:20px
}

.f-20 {
font-size:20px;
line-height:24px
}

.f-24 {
font-size:24px;
line-height:24px
}

.f-30 {
font-size:30px;
line-height:32px
}

.f-33 {
font-size:33px;
line-height:34px
}

.f-40 {
font-size:40px;
line-height:42px
}

.f-45 {
font-size:40px;
line-height:54px
}

.f-200 {
font-weight:200
}

.mb-0 {
margin-bottom:0!important
}

.social-media__p {
font-size:22px;
margin-bottom:12px
}

.soc {
margin-bottom:29px;
margin-top:58px
}

.soc-img {
margin:0 2px;
max-width:56px
}

.soc-footer {
margin-left:-1px
}

.form-email {
border:1px solid #b2b2b2;
font-size:13px;
border-radius:4px;
-webkit-border-radius:4px;
-moz-border-radius:4px;
-webkit-box-shadow:none;
box-shadow:none;
padding:10px 15px 9px;
font-size:15px;
margin-top:-1px;
color:#000;
width:242px;
background-color:transparent;
margin-right:7px
}

.form-email::-webkit-input-placeholder {
color:#b2b2b2
}

.form-email::-moz-placeholder {
color:#b2b2b2
}

.form-email:-moz-placeholder {
color:#b2b2b2
}

.form-email:-ms-input-placeholder {
color:#b2b2b2
}

.form-email:focus,.submit-btn:focus {
outline:none
}

.submit-for-follow {
margin-top:25px
}

.submit-btn {
background-color:#ff0042;
color:#fff;
border:2px solid #ff0042;
padding:9px 24px;
border:none;
font-size:17px;
border-radius:6px;
-webkit-border-radius:6px;
-moz-border-radius:6px
}

.submit-btn:hover {
background-color:transparent;
color:#ff0042;
border:2px solid #ff0042;
padding:7px 22px
}

.collumn-4__img {
margin-left:2px;
margin-right:15px
}

.ul-list li {
margin-bottom:8px;
list-style-type:none;
list-style-position:inside
}

.ul-list li a {
color:#000
}

.ul-list {
-webkit-padding-start:0;
list-style-position:outside;
margin-top:20px;
margin-bottom:0;
padding-left:0
}

.ul-list,.ul-list + .user-link {
font-size:15px
}

.navbar-inverse .name-brand,.navbar-inverse .name-brand:focus,.navbar-inverse .name-brand:hover,.navbar-inverse .navbar-nav>li>a,.navbar-inverse .navbar-nav>li>a:focus,.navbar-inverse .navbar-nav>li>a:hover {
color:#000;
font-size:18px;
font-weight:200;
margin:0;
}

.navbar-inverse .navbar-collapse,.navbar-inverse .navbar-form {border-color:transparent;background-color: #efbf98;margin:0;border-radius:6px;-webkit-border-radius:6px;-moz-border-radius:6px;}

.navbar-inverse .navbar-nav>li:focus,.navbar-inverse .navbar-nav>li:hover {
background-color:#ddb08b
}

.navbar-inverse .navbar-nav>li:first-child:focus,.navbar-inverse .navbar-nav>li:first-child:hover {
border-radius: 6px 0px 0px 6px;
-moz-border-radius: 6px 0px 0px 6px;
-webkit-border-radius: 6px 0px 0px 6px;
}

.navbar-inverse .navbar-nav>li:last-child:focus,.navbar-inverse .navbar-nav>li:last-child:hover {
border-radius: 0 6px 6px 0;
-moz-border-radius: 0 6px 6px 0;
-webkit-border-radius: 0 6px 6px 0;
}

.navbar-inverse .navbar-nav>li>a:focus,.navbar-inverse .navbar-nav>li>a:hover {
color:#000!important
}

.navbar-inverse {
background-color:#fff;
border-color:#f2f2f2
}

.navbar-header {
margin-top:4px
}

.navbar-inverse .navbar-nav>.active>a,.navbar-inverse .navbar-nav>.active>a:focus,.navbar-inverse .navbar-nav>.active>a:hover {
background-color:transparent
}

.navbar-inverse .name-brand:focus,.navbar-inverse .navbar-nav>li>a:focus,.navbar-inverse .navbar-nav>.active>a:focus,.icon-search,.theme-block button {
outline:none
}

.navbar-toggle {
background-color:#000
}

.navbar-nav>li>a {
position:relative;
display:block;
padding:0 15px
}

.container-2 {
margin-top:104px
}

a.login {
font-size:18px;
color:#000;
border:1px solid #000;
border-radius:6px;
-webkit-border-radius:6px;
-moz-border-radius:6px;
padding:4px 25px 7px 23px;
font-weight:200
}

a.login:hover,a.login:active {
background-color:#000;
color:#fff
}

a.login:focus,.enter-input:focus,.close:focus {
outline:none
}

a.enter-btn {
margin:25px auto 0!important;
max-width:100%!important;
padding:12px 0;
font-size:18px
}

.thumbnail-slider {
position:relative;
overflow:hidden;
border-radius:6px 0 0 6px;
-webkit-border-radius:6px 0 0 6px;
-moz-border-radius:6px 0 0 6px;
background-color:rgba(0,0,0,0.5)
}

.thumbnail-slider__img {
position:absolute;
left:50%;
top:50%;
object-fit:cover!important;
-webkit-transform:translate(-50%,-50%);
-ms-transform:translate(-50%,-50%);
transform:translate(-50%,-50%);
z-index:-1
}

.thumbnail-slider__img,.thumbnail-slider {
width:431px;
height:458px
}

.carousel-control img {
margin-top:236px;
padding:0 15px
}

.carousel-caption {
position:absolute;
bottom:139px!important;
text-shadow:none;
padding:0 49px;
right:0;
left:0
}

.carousel-caption h3 {
font-size:30px;
font-weight:200;
line-height:35px;
position:relative
}

.carousel-caption h3::before {
content:url(../images/only-logo.png);
position:absolute;
top:-85px;
left:0;
right:0
}

.enter-input {
border-radius:6px;
-webkit-border-radius:6px;
-moz-border-radius:6px;
border:1px solid #ccc;
font-weight:200;
font-size:14px;
padding:8px 19px;
width:100%;
margin-bottom:3px
}

.table-registration {
display:table;
width:100%
}

.table-registration .carousel {
width:431px
}

.table-registration .carousel,.table-registration .modal-content {
display:table-cell;
vertical-align:middle
}

.select-style select::-ms-expand {
display:none
}

.table-registration .block-enter {
margin-left:0;
max-width:100%
}

.table-registration .modal-body,.table-registration .modal-header,.table-registration .modal-footer {
padding-left:36px;
padding-right:36px
}

.table-registration .modal-header {
padding-top:13px
}

.table-registration .modal-body {
padding-bottom:0
}

.table-registration .modal-footer {
text-align:left;
padding-bottom:6px
}

.table-registration a.enter-btn {
margin:15px auto 0!important
}

input.check-reg[type=checkbox] {
visibility:hidden;
position:absolute
}

input.check-reg[type=checkbox] + label:before {
border-radius:0;
height:19px;
width:19px;
border:1px solid #d9d9d9;
border-radius:4px;
background-color:#f8f8f8;
content:" ";
display:block;
position:absolute;
left:33px;
vertical-align:baseline;
margin:1px 13px -2px 4px
}

input.check-reg[type=checkbox]:checked + label:before {
background-image:url(../images/checkbox.png);
background-repeat:no-repeat;
background-position:50% 50%;
border:none;
height:20px;
width:20px;
margin-right:12px;
margin-left:4px;
margin-bottom:-5px
}

.label-reg {
font-weight:200;
color:#999;
padding-left:29px;
display:table-cell;
vertical-align:middle;
padding-top:10px;
font-size:14px;
line-height:19px
}

.carousel-indicators .active {
width:8px;
height:8px;
margin:0 5px
}

.carousel-indicators li {
width:8px;
height:8px;
margin:0 5px;
background-color:#fff
}

.close {font-size: 46px;font-weight:200;color: #000;filter:alpha(opacity=100);opacity:1;float:none;position:absolute;right: -52px;top: -1px;background-color: #e8b78f !important;text-shadow: none;border-radius: 100%;padding: 0 9px 6px 9px!important;line-height: 34px;}
.close:focus, .close:hover {
    filter: alpha(opacity=100);
    opacity: 1;
}
.block-enter {
width:100%;
max-width:248px;
margin:0 auto
}

.modal-open .modal,.modal-open {
padding-right:0!important
}

.modal-content {position: relative;}
.modal-content .table-info__img {
    width: 100% !important;
    max-width: 900px;
    border: none;
}
.modal-header {
border-bottom:none;
padding:30px 15px 2px
}

.modal-center {display:table;width:100%;height:100%;max-width: 900px;margin:auto;}

#registration .modal-center {
max-width:862px
}

#registration .modal-content {
border-radius:0 6px 6px 0
}

.modal-dialog {
margin:auto;
display:table-cell;
vertical-align:middle
}

.modal-footer {
text-align:center;
border-top:none;
font-weight:200;
padding-top:5px;
padding-bottom:0
}

.modal-footer-enter {
padding-bottom:20px
}

.modal-footer a {
font-size:39%;
font-size:200
}

.modal {
z-index:10400
}

.modal-title {
font-size:21px
}

a.to-main {
font-size:18px;
color:#38B6D9;
border:1px solid #38B6D9;
border-radius:6px;
-webkit-border-radius:6px;
-moz-border-radius:6px;
padding:10px 28px
}

a.to-main:hover,a.to-main:active {
background-color:#38B6D9;
color:#fff
}

.block-search {
display:inline-block;
vertical-align:middle;
position:relative;
width:196px;
margin-right:85px;
border-radius:6px;
-webkit-border-radius:6px;
-moz-border-radius:6px
}

.form-control-search {
width:100%;
border-color:#999!important
}

.icon-search,.form-control-search,.notification,.avatar {
display:inline-block;
vertical-align:middle
}

.form-control {
color:#000;
border:1px solid #CCC;
border-radius:6px;
-webkit-border-radius:6px;
-moz-border-radius:6px;
-webkit-box-shadow:none;
box-shadow:none;
padding:8px 9px;
font-size:13px
}

.form-control::-webkit-input-placeholder {
color:#999
}

.form-control::-moz-placeholder {
color:#999
}

.form-control:-moz-placeholder {
color:#999
}

.form-control:-ms-input-placeholder {
color:#999
}

.icon-search {
display:inline-block;
width:15px;
height:16px;
background-image:url(../images/element.png);
background-color:transparent;
border:none;
margin-left:-31px;
margin-top:-2px;
position:absolute;
top:10px;
right:13px;
background-repeat:no-repeat;
outline:none
}

.design a.user-link {
display:inline-block;
margin-left:3px
}

select:focus {
-webkit-box-shadow:none!important;
box-shadow:none!important
}

@media (min-width: 1200px) {
.container,.w-main {
max-width:1000px;
width:100%;
padding:0;
margin:0 auto
}
}

@media (min-width: 768px) {
.modal-dialog {
width:342px
}

.navbar-nav {
float:none;
margin:0 auto
}

.navbar-nav>li {float:left;border-right: 1px solid #656565;padding:10px 0;}

.navbar-nav-item:first-child:nth-last-child(4),
.navbar-nav-item:first-child:nth-last-child(4) ~ li{
    width: 25%;
}
.navbar-nav-item:first-child:nth-last-child(5),
.navbar-nav-item:first-child:nth-last-child(5) ~ li{
    width: 20%;
}

.navbar-nav>li:last-child {
border-right:none
}

.navbar-header {
float:none;
display:block;
width:100%;
margin:0 auto;
text-align:center;
padding-right:0
}

.navbar>.container .navbar-brand,.navbar>.container-fluid .navbar-brand {
width:100%;
margin:0 auto
}

.navbar-brand>img {
	display:block;
	margin:0 auto 10px;
	height: 150px;
	-webkit-background-size: contain;
    background-size: contain;
    -moz-background-size: contain;
    -o-background-size: contain;
}
}

@media (min-width: 992px) {
.container {
width:1000px
}
}

@media (max-width: 1020px) {
.navbar-header {
margin-top:0;
float:none
}

.navbar-left,.navbar-right {
float:none!important
}

.navbar-toggle {
display:block
}

.navbar-collapse {
border-top:1px solid transparent;
box-shadow:inset 0 1px 0 rgba(255,255,255,0.1)
}

.navbar-fixed-top {
top:0;
border-width:0 0 1px;
border-bottom-width:2px
}

.navbar-collapse.collapse {
display:none!important
}

.navbar-nav {
float:none!important;
margin:7.5px auto
}

.navbar-nav>li {
float:none;
width:100%;
border-right:none;
padding:0
}

.navbar-nav>li>a {
padding-top:10px;
padding-bottom:10px
}

.collapse.in {
display:block!important
}

.container {
width:100%;
padding:0 50px
}

.navbar-inverse .navbar-toggle .icon-bar {background-color: #efbf98;}

.navbar-inverse .navbar-toggle {
border-color:#fff;
margin-top:0;
margin-bottom:0
}

.navbar-toggle {
background-color:#fff
}

.navbar-toggle .icon-bar {
width:75px;
height:8px;
border-radius:0;
-webkit-border-radius:0;
-moz-border-radius:0
}

.navbar-toggle .icon-bar+.icon-bar {
margin-top:16px
}

.navbar-toggle {
padding:33px 0 29px 10px;
margin-right:0
}

.navbar-inverse .name-brand {
width:350px;
padding-left:0
}

.navbar-inverse .navbar-toggle:focus,.navbar-inverse .navbar-toggle:hover {
background-color:#fff
}

.collapse.in {
width:100%;
margin:0
}

.block-right {
display:none
}

#navbar {
float:none
}

.container-2 {
margin-top:130px
}

.w-main {
padding:0 10px
}

.navbar>.container .navbar-brand,.navbar>.container-fluid .navbar-brand {
width:126px;
margin:0 auto;
padding:10px 0
}

.navbar-brand>img {display:inherit;margin:0;height: 100px;}

.close {
    right: 7px;
    top: 4px;
}
}

@media (max-width: 1150px) {
.footer-info .col-xs-4 .pull-right,.footer-info .col-xs-4 .pull-left {
float:none!important
}
}

@media (max-width: 830px) {
.footer-info .col-xs-4 {
width:100%;
text-align:center
}
}

@media (max-width: 544px) {
.navbar-toggle .icon-bar {
width:38px;
height:2px
}

.navbar-toggle .icon-bar+.icon-bar {
margin-top:10px
}

.logo-main {
max-width:155px;
margin-left:0
}

.navbar-brand>img {display:initial;height: 48px;}

.navbar-inverse .name-brand {
width:inherit
}

.navbar-brand {
padding:16px 0;
margin-bottom:0
}

.navbar>.container .navbar-brand,.navbar>.container-fluid .navbar-brand {
width:55px
}

.navbar-toggle {
padding:23px 0 9px 10px;
margin:0
}

.container {
padding:0 33px
}

.container-2 {
margin-top:85px
}

.submit-btn,.form-email {
display:block;
width:100%;
margin-bottom:10px
}

.f-30,.social-media__p {
font-size:20px;
line-height:24px
}

.f-20 {
font-size:17px;
line-height:20px
}

.f-45,.tel-company {
font-size:30px;
line-height:38px
}

.f-33 {
font-size:22px;
line-height:26px
}

.f-40 {
font-size:25px;
line-height:28px
}

.platform__p {
font-size:20px;
line-height:26px
}

.block-platform__img {
margin-left:0;
margin-right:4px
}

.soc-img {
margin:0 1px;
max-width:48px
}
}

@media (max-width: 350px) {
.collumn-4__img {
margin-left:auto;
margin-right:auto;
margin-bottom:5px;
display:block
}
}

.info-href,.info-href:hover {
color:#FFF
}

#modlgn-remember {
margin-right:5px
}

#form-login-remember,#form-login-remember label {
font-size:16px;
font-weight:200
}

#form-login-submit .enter-btn {
margin:13px auto 9px!important;
max-width:100%!important;
padding:12px 0;
font-size:18px;
border:none
}


text:
package radlab.rain.communication;

import java.util.LinkedList;

public class TrackListReplyMessage extends RainMessage
{
	public TrackListReplyMessage()
	{
		this._header = new MessageHeader( MessageHeader.VERSION_1, MessageHeader.TRACK_LIST_REPLY_MSG_TYPE );
	}

	/**
	 *
	 */
	private static final long serialVersionUID = 1L;
	public LinkedList<String> _trackNames = new LinkedList<String>();
}


text:
// Author: jcrowell@google.com (Jeffrey Crowell)

#include "pagespeed/kernel/util/brotli_inflater.h"

#include "pagespeed/kernel/base/gtest.h"
#include "pagespeed/kernel/base/message_handler.h"
#include "pagespeed/kernel/base/message_handler_test_base.h"
#include "pagespeed/kernel/base/null_mutex.h"
#include "pagespeed/kernel/util/simple_random.h"
#include "pagespeed/kernel/base/stack_buffer.h"
#include "pagespeed/kernel/base/string.h"
#include "pagespeed/kernel/base/string_util.h"
#include "pagespeed/kernel/base/string_writer.h"

namespace net_instaweb {

namespace {

// Generated with command line tool "bro".
static const char kHello[] = "hello\n";
static const char kHelloBrotli[] = "\x8b\x02\x80\x68\x65\x6c\x6c\x6f\x0a\x03";
// Use the highest quality by default (11).
static const int kCompressionLevel = 11;

// Writer that returns false on Write().
class StringWriterReturningFalse : public StringWriter {
 public:
  explicit StringWriterReturningFalse(GoogleString* str) : StringWriter(str) {}
  bool Write(const StringPiece& str,
             net_instaweb::MessageHandler* message_handler) {
    StringWriter::Write(str, message_handler);
    return false;
  }
};

TEST(BrotliInflater, TestBrotliDecompress) {
  // Compress and decompress a simple string.
  GoogleString decompressed;
  TestMessageHandler handler;
  StringWriter decompress_writer(&decompressed);
  StringPiece compressed(kHelloBrotli, sizeof(kHelloBrotli));
  EXPECT_TRUE(
      BrotliInflater::Decompress(compressed, &handler, &decompress_writer));
  EXPECT_STREQ(kHello, decompressed);
  EXPECT_EQ(0, handler.messages().size());
}

TEST(BrotliInflater, TestFailedWriteBrotliDecompress) {
  // Use a writer that returns failure on write.
  GoogleString decompressed;
  TestMessageHandler handler;
  StringWriterReturningFalse decompress_writer(&decompressed);
  StringPiece compressed(kHelloBrotli, sizeof(kHelloBrotli));
  EXPECT_FALSE(
      BrotliInflater::Decompress(compressed, &handler, &decompress_writer));
  EXPECT_EQ(0, handler.messages().size());
}

TEST(BrotliInflater, TestCorruptInputBrotliDecompress) {
  // Take "hello\n" but replace the first 2 bytes with "AB", so it will not be
  // valid brotli.
  const char kHelloBrotliCorrupt[] = "AB\x80\x68\x65\x6c\x6c\x6f\x0a\x03";
  GoogleString decompressed;
  TestMessageHandler handler;
  StringWriterReturningFalse decompress_writer(&decompressed);
  StringPiece compressed(kHelloBrotliCorrupt, sizeof(kHelloBrotliCorrupt));
  EXPECT_FALSE(
      BrotliInflater::Decompress(compressed, &handler, &decompress_writer));
  ASSERT_GE(handler.messages().size(), 1);
  const GoogleString& message = handler.messages()[0];
  EXPECT_TRUE(message.find("PADDING_1") != GoogleString::npos ||
              message == "Error: BROTLI_DECODER_RESULT_ERROR")
      << message;
}

TEST(BrotliInflater, TestTruncatedInputBrotliDecompress) {
  // Take "hello\n" but truncate the string, so it will not be valid brotli.
  const char kHelloBrotliCorrupt[] = "\x8b\x02\x80\x68\x65\x6c\x6c\x6f";
  GoogleString decompressed;
  TestMessageHandler handler;
  StringWriterReturningFalse decompress_writer(&decompressed);
  StringPiece compressed(kHelloBrotliCorrupt, sizeof(kHelloBrotliCorrupt));
  EXPECT_FALSE(
      BrotliInflater::Decompress(compressed, &handler, &decompress_writer));
  EXPECT_STREQ("Warning: BROTLI_DECODER_RESULT_NEEDS_MORE_INPUT",
               handler.messages()[0]);
}

TEST(BrotliInflater, TestCompressDecompressSmallString) {
  // Compress and decompress a simple string, ensure that it remains unchanged.
  StringPiece payload(kHello);
  TestMessageHandler handler;
  GoogleString compressed, decompressed;
  StringWriter compressed_writer(&compressed);
  EXPECT_TRUE(BrotliInflater::Compress(payload, kCompressionLevel, &handler,
                                       &compressed_writer));
  StringWriter decompressed_writer(&decompressed);
  EXPECT_TRUE(
      BrotliInflater::Decompress(compressed, &handler, &decompressed_writer));
  EXPECT_STREQ(payload, decompressed);
  EXPECT_EQ(0, handler.messages().size());
}

TEST(BrotliInflater, TestCompressDecompressLargeString) {
  // Compress and decompress a long string of repeated characters that will
  // exceed the buffer size.
  TestMessageHandler handler;
  GoogleString value(5 * kStackBufferSize, 'A');
  StringPiece payload(value);
  GoogleString compressed, decompressed;
  StringWriter compressed_writer(&compressed);
  EXPECT_TRUE(BrotliInflater::Compress(payload, kCompressionLevel, &handler,
                                       &compressed_writer));
  StringWriter decompressed_writer(&decompressed);
  EXPECT_TRUE(
      BrotliInflater::Decompress(compressed, &handler, &decompressed_writer));
  EXPECT_STREQ(payload, decompressed);
  EXPECT_EQ(0, handler.messages().size());
}

TEST(BrotliInflater, TestCompressDecompressLargeStringWithPoorCompression) {
  // Compress and decompress a long string of random characters.
  TestMessageHandler handler;
  SimpleRandom random(new NullMutex);
  GoogleString value = random.GenerateHighEntropyString(5 * kStackBufferSize);
  StringPiece payload(value);
  GoogleString compressed, decompressed;
  StringWriter compressed_writer(&compressed);
  EXPECT_TRUE(BrotliInflater::Compress(payload, kCompressionLevel, &handler,
                                       &compressed_writer));
  StringWriter decompressed_writer(&decompressed);
  EXPECT_TRUE(
      BrotliInflater::Decompress(compressed, &handler, &decompressed_writer));
  EXPECT_STREQ(payload, decompressed);
  EXPECT_EQ(0, handler.messages().size());
}

}  // namespace

}  // namespace net_instaweb


text:
var class2type = {
    'Boolean': 1,
    'Number': 1,
    'String': 1,
    'Function': 1,
    'Array': 1,
    'Date': 1,
    'RegExp': 1,
    'Object': 1,
    'Error': 1
};
var toString = Object.prototype.toString;

/**
 * Get the type of input.
 *
 * @param {Object} object .
 * @return {string} type .
 */
var type = function (object) {
    if (object == null) {
        return String(object);
    }

    // Support: Safari <= 5.1 (functionish RegExp)
    var t = typeof object;
    var objType = 'object';
    if (t === objType || t === 'function') {
        t = toString.call(object).slice(8, -1);
        return class2type[t] ? t.toLowerCase() : objType;
    }

    return typeof object;
};

export default type;


text:
using org.xmlvm;
namespace java.util {
public class Collections_2EmptyMap: global::java.util.AbstractMap,global::java.io.Serializable {

new private void @this(){
//XMLVM_BEGIN_WRAPPER[java.util.Collections$EmptyMap: void <init>()]
    global::System.Object _r0_o = null;
    _r0_o = this;
    ((global::java.util.AbstractMap) _r0_o).@this();
    return;
//XMLVM_END_WRAPPER[java.util.Collections$EmptyMap: void <init>()]
}

public override bool containsKey(global::java.lang.Object n1){
//XMLVM_BEGIN_WRAPPER[java.util.Collections$EmptyMap: boolean containsKey(java.lang.Object)]
    global::org.xmlvm._nElement _r0;
    global::System.Object _r1_o = null;
    global::System.Object _r2_o = null;
    _r1_o = this;
    _r2_o = n1;
    _r0.i = 0;
    return _r0.i!=0;
//XMLVM_END_WRAPPER[java.util.Collections$EmptyMap: boolean containsKey(java.lang.Object)]
}

public override bool containsValue(global::java.lang.Object n1){
//XMLVM_BEGIN_WRAPPER[java.util.Collections$EmptyMap: boolean containsValue(java.lang.Object)]
    global::org.xmlvm._nElement _r0;
    global::System.Object _r1_o = null;
    global::System.Object _r2_o = null;
    _r1_o = this;
    _r2_o = n1;
    _r0.i = 0;
    return _r0.i!=0;
//XMLVM_END_WRAPPER[java.util.Collections$EmptyMap: boolean containsValue(java.lang.Object)]
}

public override global::System.Object entrySet(){
//XMLVM_BEGIN_WRAPPER[java.util.Collections$EmptyMap: java.util.Set entrySet()]
    global::System.Object _r0_o = null;
    global::System.Object _r1_o = null;
    _r1_o = this;
    _r0_o = global::java.util.Collections._fEMPTY_1SET;
    return (global::java.util.Set) _r0_o;
//XMLVM_END_WRAPPER[java.util.Collections$EmptyMap: java.util.Set entrySet()]
}

public override global::System.Object get(global::java.lang.Object n1){
//XMLVM_BEGIN_WRAPPER[java.util.Collections$EmptyMap: java.lang.Object get(java.lang.Object)]
    global::System.Object _r0_o = null;
    global::System.Object _r1_o = null;
    global::System.Object _r2_o = null;
    _r1_o = this;
    _r2_o = n1;
    _r0_o = null;
    return (global::java.lang.Object) _r0_o;
//XMLVM_END_WRAPPER[java.util.Collections$EmptyMap: java.lang.Object get(java.lang.Object)]
}

public override global::System.Object keySet(){
//XMLVM_BEGIN_WRAPPER[java.util.Collections$EmptyMap: java.util.Set keySet()]
    global::System.Object _r0_o = null;
    global::System.Object _r1_o = null;
    _r1_o = this;
    _r0_o = global::java.util.Collections._fEMPTY_1SET;
    return (global::java.util.Set) _r0_o;
//XMLVM_END_WRAPPER[java.util.Collections$EmptyMap: java.util.Set keySet()]
}

public override global::System.Object values(){
//XMLVM_BEGIN_WRAPPER[java.util.Collections$EmptyMap: java.util.Collection values()]
    global::System.Object _r0_o = null;
    global::System.Object _r1_o = null;
    _r1_o = this;
    _r0_o = global::java.util.Collections._fEMPTY_1LIST;
    return (global::java.util.Collection) _r0_o;
//XMLVM_END_WRAPPER[java.util.Collections$EmptyMap: java.util.Collection values()]
}

private global::System.Object readResolve(){
//XMLVM_BEGIN_WRAPPER[java.util.Collections$EmptyMap: java.lang.Object readResolve()]
    global::System.Object _r0_o = null;
    global::System.Object _r1_o = null;
    _r1_o = this;
    _r0_o = global::java.util.Collections._fEMPTY_1MAP;
    return (global::java.lang.Object) _r0_o;
//XMLVM_END_WRAPPER[java.util.Collections$EmptyMap: java.lang.Object readResolve()]
}

public void @this(global::java.util.Collections_2EmptyMap n1){
//XMLVM_BEGIN_WRAPPER[java.util.Collections$EmptyMap: void <init>(java.util.Collections$EmptyMap)]
    global::System.Object _r0_o = null;
    global::System.Object _r1_o = null;
    _r0_o = this;
    _r1_o = n1;
    ((global::java.util.Collections_2EmptyMap) _r0_o).@this();
    return;
//XMLVM_END_WRAPPER[java.util.Collections$EmptyMap: void <init>(java.util.Collections$EmptyMap)]
}

//XMLVM_BEGIN_WRAPPER[java.util.Collections$EmptyMap]
//XMLVM_END_WRAPPER[java.util.Collections$EmptyMap]

} // end of class: Collections_2EmptyMap

} // end of namespace: java.util


text:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:orientation="vertical" android:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:padding="8dp"
    android:layout_gravity="center">

    <TextView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:textAppearance="?android:attr/textAppearanceSmall"
        android:text="2A"
        android:id="@+id/hex"
        android:typeface="monospace" />

    <TextView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:textAppearance="?android:attr/textAppearanceLarge"
        android:text="42"
        android:id="@+id/dec" />

    <TextView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:textAppearance="?android:attr/textAppearanceSmall"
        android:text="0010 1010"
        android:id="@+id/bin"
        android:typeface="monospace" />

</LinearLayout>


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

    <title>Keith Hamilton - Keith's Blog of Reasonable Certainty</title>
    <meta name="description" content="">

    <meta name="HandheldFriendly" content="True">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">

    <link rel="shortcut icon" href="../../favicon.ico">

    <link rel="stylesheet" type="text/css" href="../../assets/css/screen.css?v=680378e20a">
    <link rel="stylesheet" type="text/css" href="http://fonts.googleapis.com/css?family=Merriweather:300,700,700italic,300italic%7COpen+Sans:700,400">

    <link rel="canonical" href="http://blog.tcpkeith.com/author/keith/">
    <link rel="next" href="http://blog.tcpkeith.com/author/keith/page/2/">
    <meta name="generator" content="Ghost 0.5">
    <link rel="alternate" type="application/rss+xml" title="Keith's Blog of Reasonable Certainty" href="http://blog.tcpkeith.com/rss/">

Menu

        Close

Blog Home

tcpkeith.com

kdo2g (Twitter)

keithstagr_am (Instagram)

    Subscribe

                ☰Menu

Keith Hamilton's Picture

Keith Hamilton

            Portland, OR
            http://tcpkeith.com
             6 posts

        Page 1 of 2
            Older Posts →

Cats.

I live in urban Portland, and I want to talk briefly about a really shitty part about living in an urban environment.  My wife and I »

            Keith Hamilton
             on rant, urban-life, portland, cats
            <time class="post-date" datetime="2015-04-14">14 April 2015</time>

Fewer vs. Less

I have less apples than I did yesterday. I've been reading a lot of essays on the "correctness" of Standard English lately, and I've been waffling »

            Keith Hamilton

            <time class="post-date" datetime="2015-04-13">13 April 2015</time>

Facebook Peeve #1: The Hijack

I see it over and over again. Typically from the same people, and typically interjected into a post from the same few of my friends.  I'm »

            Keith Hamilton
             on facebook, etiquette, social media
            <time class="post-date" datetime="2015-04-11">11 April 2015</time>

Hosting a Ghost Blog on Github Pages

I recently set up my website, with custom domain, on Github Pages. After I did that, I wanted to set up a blog as well, but »

            Keith Hamilton
             on blog, github, hosting, ghost
            <time class="post-date" datetime="2015-04-10">10 April 2015</time>

Spinach for breakfast

Mmm.   Is there any better breakfast food than buttery, garlicky, tangy spinach, topped with a poached egg? You could definitely make an argument for bacon, and »

            Keith Hamilton
             on food, breakfast
            <time class="post-date" datetime="2015-04-10">10 April 2015</time>

        Page 1 of 2
            Older Posts →

Keith's Blog of Reasonable Certainty © 2015

Proudly published with Ghost


text:
// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "base/message_pump_libevent.h"

#include <unistd.h>

#include "base/message_loop.h"
#include "base/threading/thread.h"
#include "testing/gtest/include/gtest/gtest.h"

#if defined(USE_SYSTEM_LIBEVENT)
#include <event.h>
#else
#include "third_party/libevent/event.h"
#endif

namespace base {

class MessagePumpLibeventTest : public testing::Test {
 protected:
  MessagePumpLibeventTest()
      : ui_loop_(MessageLoop::TYPE_UI),
        io_thread_("MessagePumpLibeventTestIOThread") {}
  virtual ~MessagePumpLibeventTest() {}

  virtual void SetUp() {
    Thread::Options options(MessageLoop::TYPE_IO, 0);
    ASSERT_TRUE(io_thread_.StartWithOptions(options));
    ASSERT_EQ(MessageLoop::TYPE_IO, io_thread_.message_loop()->type());
  }

  MessageLoop* ui_loop() { return &ui_loop_; }
  MessageLoopForIO* io_loop() const {
    return static_cast<MessageLoopForIO*>(io_thread_.message_loop());
  }

  void OnLibeventNotification(
      MessagePumpLibevent* pump,
      MessagePumpLibevent::FileDescriptorWatcher* controller) {
    pump->OnLibeventNotification(0, EV_WRITE | EV_READ, controller);
  }

  MessageLoop ui_loop_;
  Thread io_thread_;
};

namespace {

// Concrete implementation of MessagePumpLibevent::Watcher that does
// nothing useful.
class StupidWatcher : public MessagePumpLibevent::Watcher {
 public:
  virtual ~StupidWatcher() {}

  // base:MessagePumpLibevent::Watcher interface
  virtual void OnFileCanReadWithoutBlocking(int fd) {}
  virtual void OnFileCanWriteWithoutBlocking(int fd) {}
};

#if GTEST_HAS_DEATH_TEST && !defined(NDEBUG)

// Test to make sure that we catch calling WatchFileDescriptor off of the
// wrong thread.
TEST_F(MessagePumpLibeventTest, TestWatchingFromBadThread) {
  MessagePumpLibevent::FileDescriptorWatcher watcher;
  StupidWatcher delegate;

  ASSERT_DEATH(io_loop()->WatchFileDescriptor(
      STDOUT_FILENO, false, MessageLoopForIO::WATCH_READ, &watcher, &delegate),
      "Check failed: "
      "watch_file_descriptor_caller_checker_.CalledOnValidThread()");
}

#endif  // GTEST_HAS_DEATH_TEST && !defined(NDEBUG)

class DeleteWatcher : public MessagePumpLibevent::Watcher {
 public:
  explicit DeleteWatcher(
      MessagePumpLibevent::FileDescriptorWatcher* controller)
      : controller_(controller) {
    DCHECK(controller_);
  }
  virtual ~DeleteWatcher() {}

  // base:MessagePumpLibevent::Watcher interface
  virtual void OnFileCanReadWithoutBlocking(int /* fd */) {
    NOTREACHED();
  }
  virtual void OnFileCanWriteWithoutBlocking(int /* fd */) {
    delete controller_;
  }

 private:
  MessagePumpLibevent::FileDescriptorWatcher* const controller_;
};

TEST_F(MessagePumpLibeventTest, DeleteWatcher) {
  scoped_refptr<MessagePumpLibevent> pump(new MessagePumpLibevent);
  MessagePumpLibevent::FileDescriptorWatcher* watcher =
      new MessagePumpLibevent::FileDescriptorWatcher;
  DeleteWatcher delegate(watcher);
  pump->WatchFileDescriptor(
      0, false, MessagePumpLibevent::WATCH_READ_WRITE, watcher, &delegate);

  // Spoof a libevent notification.
  OnLibeventNotification(pump, watcher);
}

class StopWatcher : public MessagePumpLibevent::Watcher {
 public:
  explicit StopWatcher(
      MessagePumpLibevent::FileDescriptorWatcher* controller)
      : controller_(controller) {
    DCHECK(controller_);
  }
  virtual ~StopWatcher() {}

  // base:MessagePumpLibevent::Watcher interface
  virtual void OnFileCanReadWithoutBlocking(int /* fd */) {
    NOTREACHED();
  }
  virtual void OnFileCanWriteWithoutBlocking(int /* fd */) {
    controller_->StopWatchingFileDescriptor();
  }

 private:
  MessagePumpLibevent::FileDescriptorWatcher* const controller_;
};

TEST_F(MessagePumpLibeventTest, StopWatcher) {
  scoped_refptr<MessagePumpLibevent> pump(new MessagePumpLibevent);
  MessagePumpLibevent::FileDescriptorWatcher watcher;
  StopWatcher delegate(&watcher);
  pump->WatchFileDescriptor(
      0, false, MessagePumpLibevent::WATCH_READ_WRITE, &watcher, &delegate);

  // Spoof a libevent notification.
  OnLibeventNotification(pump, &watcher);
}

}  // namespace

}  // namespace base


text:
package observability

import (
	"context"
	"log"
	"sync"

	"google.golang.org/protobuf/encoding/protojson"
	"knative.dev/pkg/injection"

	"knative.dev/eventing-kafka-broker/control-plane/pkg/contract"

	"github.com/google/go-cmp/cmp"
	"go.uber.org/zap"
	corev1 "k8s.io/api/core/v1"
	"k8s.io/apimachinery/pkg/types"
	"knative.dev/pkg/configmap"
	"knative.dev/pkg/controller"
	"knative.dev/pkg/injection/sharedmain"
	"knative.dev/pkg/logging"
	"knative.dev/pkg/signals"

	"knative.dev/eventing-kafka-broker/control-plane/pkg/reconciler/base"
)

const (
	component = "kafka-broker-cm-watcher"
)

// WatchDataPlaneConfigMap watches our data plane config map, and it logs out all differences at every change.
//
// This function is used for troubleshooting failed test runs.
func WatchDataPlaneConfigMap(cm types.NamespacedName, format string) {

	ctx := signals.NewContext()
	ctx = sharedmain.WithHADisabled(ctx)

	cfg := injection.ParseAndGetRESTConfigOrDie()

	sharedmain.MainWithConfig(ctx, component, cfg, func(ctx context.Context, watcher configmap.Watcher) *controller.Impl {

		logger := logging.FromContext(ctx).Desugar()

		diffLogger := diffLogger{
			logger: logger,
			format: format,
		}

		watcher.Watch(cm.Name, diffLogger.logDiff)

		return controller.NewContext(ctx,
			ReconcileFunc(func(ctx context.Context, key string) error { return nil }),
			controller.ControllerOptions{WorkQueueName: component, Logger: logger.Sugar()},
		)
	})
}

type diffLogger struct {
	m      sync.Mutex
	logger *zap.Logger
	format string
	prev   *contract.Contract
}

func (d *diffLogger) logDiff(cm *corev1.ConfigMap) {

	ct, err := base.GetDataPlaneConfigMapData(d.logger, cm, d.format)
	if err != nil {
		d.logger.Error(
			"failed to get data plane config map data",
			zap.Error(err),
			zap.String("version", cm.ResourceVersion),
		)
		return
	}

	d.m.Lock()
	defer d.m.Unlock()

	sJNow := protojson.Format(ct)
	sJPrev := protojson.Format(d.prev)

	log.Println(cmp.Diff(sJPrev, sJNow))

	d.prev = ct
}

type reconciler struct {
	f func(ctx context.Context, key string) error
}

func (r reconciler) Reconcile(ctx context.Context, key string) error {
	return r.f(ctx, key)
}

func ReconcileFunc(f func(ctx context.Context, key string) error) controller.Reconciler {
	return reconciler{f: f}
}


text:
import { Injectable } from '@angular/core';
import { Observable } from 'rxjs';
import * as socketIo from 'socket.io-client';

@Injectable()
export class SocketService {
    protected socket;

    constructor() {
        this.socket = socketIo('/');
    }

    public send(event: string, data: any): void {
        this.socket.emit(event, data);
    }

    public onData(event: string): Observable<any> {
        return new Observable<any>(observer => {
            this.socket.on(event, (data: any) => observer.next(data));
        });
    }
}


text:
Backbone browserify generator for Yeoman
=======

This Yeoman generator provides some shortcuts to work with Backbone project based on Browserify and Handlebars.

# Install with

    $ npm install -g generator-backbone-browserify

# Scaffold a new project

    $ mkdir new_dir && cd new_dir
    $ yo backbone-browserify

# Scaffold components

    $ yo backbone-browserify:view NAME
    $ yo backbone-browserify:model NAME
    $ yo backbone-browserify:collection NAME

# Build

Build project with:   `

    $ make

# License

MIT, 2014, Patrick Mulder


text:
package dvdrental;
// Generated Feb 4, 2017 8:25:50 PM by Hibernate Tools 4.3.1

/**
 * FilmCategoryId generated by hbm2java
 */
public class FilmCategoryId  implements java.io.Serializable {

     private short filmId;
     private byte categoryId;

    public FilmCategoryId() {
    }

    public FilmCategoryId(short filmId, byte categoryId) {
       this.filmId = filmId;
       this.categoryId = categoryId;
    }

    public short getFilmId() {
        return this.filmId;
    }

    public void setFilmId(short filmId) {
        this.filmId = filmId;
    }
    public byte getCategoryId() {
        return this.categoryId;
    }

    public void setCategoryId(byte categoryId) {
        this.categoryId = categoryId;
    }

   public boolean equals(Object other) {
         if ( (this == other ) ) return true;
		 if ( (other == null ) ) return false;
		 if ( !(other instanceof FilmCategoryId) ) return false;
		 FilmCategoryId castOther = ( FilmCategoryId ) other;

		 return (this.getFilmId()==castOther.getFilmId())
 && (this.getCategoryId()==castOther.getCategoryId());
   }

   public int hashCode() {
         int result = 17;

         result = 37 * result + this.getFilmId();
         result = 37 * result + this.getCategoryId();
         return result;
   }

}


text:
package ee.tkasekamp.ltlminer.rulecreator;

import java.util.ArrayList;

/**
 * Creates combinations of String elements. Not very generic
 *
 * @author Tonis
 *
 */
public class CombineUtil {
	/**
	 * Generates all possible combinations from arr with lenght k. Allows
	 * repetiton in the finshed arrays.
	 * http://exceptional-code.blogspot.com/2012/09/generating-all-permutations.html
	 *
	 * @param arr
	 *            Where to take arguments from
	 * @param k
	 *            How deep to go
	 * @param branch
	 *            Current working array
	 * @param numElem
	 *            Current depth
	 * @param combos
	 *            Holds finished arrays
	 */
	public static void combine(String[] arr, int k, String[] branch,
			int numElem, ArrayList<String[]> combos) {
		if (numElem == k) {
			combos.add(createCopy(branch));
			return;
		}

		for (int i = 0; i < arr.length; ++i) {
			branch[numElem++] = arr[i];
			combine(arr, k, branch, numElem, combos);
			--numElem;
		}
	}

	/**
	 * Generates all possible combinations from arr with lenght k. Does not
	 * allow repetiton in the finshed arrays.
	 * http://exceptional-code.blogspot.com/2012/09/generating-all-permutations.html
	 *
	 * @param arr
	 *            Where to take arguments from
	 * @param k
	 *            How deep to go
	 * @param branch
	 *            Current working array
	 * @param numElem
	 *            Current depth
	 * @param combos
	 *            Holds finished arrays
	 */
	public static void combineNoRepetitions(String[] arr, int k,
			String[] branch, int numElem, ArrayList<String[]> combos) {
		if (numElem == k) {
			combos.add(createCopy(branch));
			return;
		}

		for (int i = 0; i < arr.length; ++i) {
			if (!arrayIncludesElement(branch, arr[i])) {
				branch[numElem++] = arr[i];
				combineNoRepetitions(arr, k, branch, numElem, combos);
				--numElem;
			}
		}
	}

	/**
	 * Creates a deep copy of a String array.
	 *
	 * @param original
	 *            String []
	 * @return Copy of the original
	 */
	private static String[] createCopy(String[] original) {
		String[] copy = new String[original.length];
		for (int i = 0; i < original.length; i++) {
			copy[i] = original[i];
		}

		return copy;
	}

	/**
	 * Checks if the branch includes the element. Returns false if the first
	 * element is null. Otherwise checks if first element equals to input
	 * element.
	 *
	 * @param branch
	 * @param element
	 * @return
	 */
	private static boolean arrayIncludesElement(String[] branch, String element) {
		if (branch[0] == null)
			return false;
		return branch[0].equals(element);
	}
}


text:
'use strict';

const chalk = require('chalk');
const isStream = require('isstream');
const isBuffer = require('is-buffer');

const getOptions = require('./options');

function prepare(file, options, startTime) {

  return new Promise((resolve, reject) => {

    let buffer;
    let stream;
    let errString;
    let fileData = options;

    // prepare most options
    fileData = getOptions.start(file, fileData, startTime);

    file = fileData.file;

    // vinyl
    if (file.contents && (isBuffer(file.contents) || isStream(file.contents))) {
      fileData.file = file = file.contents;
    }

    if (typeof file === 'string') {

      // fileData.isFilePath = true;
      resolve(fileData);

    } else if (isBuffer(file)) {

      // fileData.isBuffer = true;
      resolve(fileData);

    } else if (isStream(file)) {

      // fileData.isStream = true;
      stream = file;
      buffer = [];
      stream.on('data', function (chunk) {
        buffer.push(chunk);
      });
      stream.on('end', function () {
        fileData.file = Buffer.concat(buffer);
        resolve(fileData);
      });

    } else {

      // Justin Case
      errString = 'unsupported - must be file path, buffer or stream';
      if (fileData.showErrorMessages) fileData.log(chalk.red(errString));
      reject(errString);

    }

  });

}

module.exports = prepare;


text:
using System;
using System.Collections.Generic;
using System.Drawing;
using System.Media;
using System.Text;
using System.Threading;
using System.Windows.Forms;
using MetroFramework.Forms;
using MetroFramework.Interfaces;

namespace MetroFramework
{
    /// <summary>
    /// Metro-styled message notification.
    /// </summary>
    public static class MetroMessageBox
    {
        private const int defaultHeight = 211;

        /// <summary>
        /// Shows a metro-styles message notification into the specified owner window.
        /// </summary>
        /// <param name="owner"></param>
        /// <param name="message"></param>
        /// <param name="height" optional=211></param>
        /// <returns></returns>
        public static DialogResult Show(IWin32Window owner, String message, int height = defaultHeight)
        { return Show(owner, message, "Notification", height); }

        /// <summary>
        /// Shows a metro-styles message notification into the specified owner window.
        /// </summary>
        /// <param name="owner"></param>
        /// <param name="message"></param>
        /// <param name="title"></param>
        /// <param name="height" optional=211></param>
        /// <returns></returns>
        public static DialogResult Show(IWin32Window owner, String message, String title, int height = defaultHeight)
        { return Show(owner, message, title, MessageBoxButtons.OK, height); }

        /// <summary>
        /// Shows a metro-styles message notification into the specified owner window.
        /// </summary>
        /// <param name="owner"></param>
        /// <param name="message"></param>
        /// <param name="title"></param>
        /// <param name="buttons"></param>
        /// <param name="height" optional=211></param>
        /// <returns></returns>
        public static DialogResult Show(IWin32Window owner, String message, String title, MessageBoxButtons buttons, int height = defaultHeight)
        { return Show(owner, message, title, buttons, MessageBoxIcon.None, height); }

        /// <summary>
        /// Shows a metro-styles message notification into the specified owner window.
        /// </summary>
        /// <param name="owner"></param>
        /// <param name="message"></param>
        /// <param name="title"></param>
        /// <param name="buttons"></param>
        /// <param name="icon"></param>
        /// <param name="height" optional=211></param>
        /// <returns></returns>
        public static DialogResult Show(IWin32Window owner, String message, String title, MessageBoxButtons buttons, MessageBoxIcon icon, int height = defaultHeight)
        {
            string refstring= "";
            return Show(owner, message, title, buttons, icon, MessageBoxDefaultButton.Button1, ref refstring, height);
        }

        /// <summary>
        /// Shows a metro-styles message notification into the specified owner window.
        /// </summary>
        /// <param name="owner"></param>
        /// <param name="message"></param>
        /// <param name="title"></param>
        /// <param name="buttons"></param>
        /// <param name="icon"></param>
        /// <param name="height" optional=211></param>
        /// <returns></returns>
        public static DialogResult Show(IWin32Window owner, String message, String title, MessageBoxButtons buttons, MessageBoxIcon icon, ref string inputValue, bool ShowInputBox, int height = defaultHeight)
        { return Show(owner, message, title, buttons, icon, MessageBoxDefaultButton.Button1, ref inputValue, height, ShowInputBox); }

        /// <summary>
        /// Shows a metro-styles message notification into the specified owner window.
        /// </summary>
        /// <param name="owner"></param>
        /// <param name="message"></param>
        /// <param name="title"></param>
        /// <param name="buttons"></param>
        /// <param name="icon"></param>
        /// <param name="defaultbutton"></param>
        /// <param name="height" optional=211></param>
        /// <returns></returns>
        public static DialogResult Show(IWin32Window owner, String message, String title, MessageBoxButtons buttons, MessageBoxIcon icon, MessageBoxDefaultButton defaultbutton, ref string inputValue, int height = defaultHeight, bool ShowInputBox = false)
        {
            DialogResult _result = DialogResult.None;

            if (owner != null)
            {
                Form _owner = (owner as Form == null) ? ((UserControl)owner).ParentForm : (Form)owner;

                //int _minWidth = 500;
                //int _minHeight = 350;

                //if (_owner.Size.Width < _minWidth ||
                //    _owner.Size.Height < _minHeight)
                //{
                //    if (_owner.Size.Width < _minWidth && _owner.Size.Height < _minHeight) {
                //            _owner.Size = new Size(_minWidth, _minHeight);
                //    }
                //    else
                //    {
                //        if (_owner.Size.Width < _minWidth) _owner.Size = new Size(_minWidth, _owner.Size.Height);
                //        else _owner.Size = new Size(_owner.Size.Width, _minHeight);
                //    }

                //    int x = Convert.ToInt32(Math.Ceiling((decimal)(Screen.PrimaryScreen.WorkingArea.Size.Width / 2) - (_owner.Size.Width / 2)));
                //    int y = Convert.ToInt32(Math.Ceiling((decimal)(Screen.PrimaryScreen.WorkingArea.Size.Height / 2) - (_owner.Size.Height / 2)));
                //    _owner.Location = new Point(x, y);
                //}

                switch (icon)
                {
                    case MessageBoxIcon.Error:
                        SystemSounds.Hand.Play(); break;
                    case MessageBoxIcon.Exclamation:
                        SystemSounds.Exclamation.Play(); break;
                    case MessageBoxIcon.Question:
                        SystemSounds.Beep.Play(); break;
                    default:
                        SystemSounds.Asterisk.Play(); break;
                }

                MetroMessageBoxControl _control = new MetroMessageBoxControl();
                _control.BackColor = _owner.BackColor;
                _control.Properties.Buttons = buttons;
                _control.Properties.DefaultButton = defaultbutton;
                _control.Properties.Icon = icon;
                _control.Properties.Message = message;
                _control.Properties.Title = title;
                _control.Padding = new Padding(0, 0, 0, 0);
                _control.ControlBox = false;
                _control.ShowInTaskbar = false;
                //_owner.Controls.Add(_control);
                //if (_owner is IMetroForm)
                //{
                //    //if (((MetroForm)_owner).DisplayHeader)
                //    //{
                //    //    _offset += 30;
                //    //}
                //    _control.Theme = ((MetroForm)_owner).Theme;
                //    _control.Style = ((MetroForm)_owner).Style;
                //}

                _control.Properties.InputBox = ShowInputBox;

                _control.Size = new Size(_owner.Size.Width, height);
                _control.Location = new Point(_owner.Location.X, _owner.Location.Y + (_owner.Height - _control.Height) / 2);
                _control.ArrangeApperance();
                //int _overlaySizes = Convert.ToInt32(Math.Floor(_control.Size.Height * 0.28));
                //_control.OverlayPanelTop.Size = new Size(_control.Size.Width, _overlaySizes - 30);
                //_control.OverlayPanelBottom.Size = new Size(_control.Size.Width, _overlaySizes);

                _control.ShowDialog();
                //_control.BringToFront();
                //_control.SetFocus();

                Action<MetroMessageBoxControl> _delegate = new Action<MetroMessageBoxControl>(ModalState);
                IAsyncResult _asyncresult = _delegate.BeginInvoke(_control, null, _delegate);
                bool _cancelled = false;

                try
                {
                    while (!_asyncresult.IsCompleted)
                    { Thread.Sleep(1); Application.DoEvents(); }
                }
                catch
                {
                    _cancelled = true;

                    if (!_asyncresult.IsCompleted)
                    {
                        try { _asyncresult = null; }
                        catch { }
                    }

                    _delegate = null;
                }

                if (!_cancelled)
                {
                    _result = _control.Result;
                    inputValue = _control.InputBoxText;
                    //_owner.Controls.Remove(_control);
                    _control.Dispose(); _control = null;
                }

            }

            return _result;
        }

        private static void ModalState(MetroMessageBoxControl control)
        {
            while (control.Visible)
            { }
        }

    }
}


text:
// --------------------------------------------------------------------------------------------------------------------
// <copyright file="PlayerView.xaml.cs" company="Developing Enterprises">
//   Josh Charles
// </copyright>
// <summary>
//   Interaction logic for PlayerView.xaml
// </summary>
// --------------------------------------------------------------------------------------------------------------------

namespace Grease.Views
{
	using Grease.ViewModels;

	using ReactiveUI;

	/// <summary>
	/// Interaction logic for PlayerView.xaml
	/// </summary>
	public partial class PlayerView : IPlayerView
	{
		/// <summary>
		/// Initializes a new instance of the <see cref="PlayerView"/> class.
		/// </summary>
		public PlayerView()
		{
			InitializeComponent();
		}

		/// <summary>
		/// Gets or sets the view model.
		/// </summary>
		public IPlayerViewModel ViewModel
		{
			get
			{
				return (IPlayerViewModel)this.DataContext;
			}

			set
			{
				this.DataContext = value;
			}
		}

		/// <summary>
		/// Gets or sets the view model.
		/// </summary>
		object IViewFor.ViewModel
		{
			get
			{
				return this.ViewModel;
			}

			set
			{
				this.ViewModel = (IPlayerViewModel)value;
			}
		}
	}
}


text:
require 'walrat'
require 'singleton'

module Walrat
  # The MemoizingCache class memoizes the outcomes of parse operations. The
  # functionality is implemented as a separate class so as to minimize the
  # amount of "contamination" of other classes by memoizing code, and to allow
  # memoizing to be cleanly turned on or off at will. If a MemoizingCache is
  # passed to a Parslet, ParsletCombination or Predicate as a value for the
  # :memoizer key in the options hash passed to a parse method, the class
  # implementing that method will call the parse method on the cache rather
  # than proceeding normally. The cache will either propagate the previously
  # memoized result, or will defer back to the original class to obtain the
  # result. A circular dependency is avoided by setting the :skip_memoizer flag
  # in the options dictionary. If no MemoizingCache is passed then normal
  # program flow takes place.
  class MemoizingCache
    # Singleton class that serves as a default value for unset keys in a Hash.
    class NoValueForKey
      include Singleton
    end

    def initialize
      # The results of parse operations are stored (memoized) in a cache, keyed
      # on a unique identifier comprising the Parslet, ParsletCombination or
      # Predicate used in the parse operation, the location of the operation
      # (the line_start and column_start), and the skipping override (if any).
      # The values may be:
      #
      #   - ParseErrors raised during parsing
      #   - SkippedSubstringExceptions raised during parsing
      #   - :ZeroWidthParseSuccess symbols thrown during parsing
      #   - :AndPredicateSuccess symbols thrown during parsing
      #   - :NotPredicateSuccess symbols thrown during parsing
      #   - String instances returned as parse results
      #   - MatchDataWrapper instance returned as parse results
      #   - Array instances containing ordered collections of parse results
      #   - Node subclass instances containing AST productions
      @cache = Hash.new NoValueForKey.instance
    end

    # The receiver checks whether there is already a stored result
    # corresponding to that a unique identifier that specifies the
    # "coordinates" of a parsing operation (location, parseable, skipping
    # override). If found propogates the result directly to the caller rather
    # than performing the parse method all over again. Here "propagation" means
    # re-raising parse errors, re-throwing symbols, and returning object
    # references. If not found, performs the parsing operation and stores the
    # result in the cache before propagating it.
    def parse string, options = {}
      raise ArgumentError if string.nil?

      # construct a unique identifier
      identifier = [options[:parseable], options[:line_start], options[:column_start]]
      identifier << options[:skipping_override] if options.has_key? :skipping_override

      if (result = @cache[identifier]) != NoValueForKey.instance
        if result.kind_of? Symbol
          throw result
        elsif result.kind_of? Exception
          raise result
        else
          return result
        end
      else
        # first time for this parseable/location/skipping_override (etc)
        # combination; capture result and propagate
        catch :NotPredicateSuccess do
          catch :AndPredicateSuccess do
            catch :ZeroWidthParseSuccess do
              begin
                options[:ignore_memoizer] = true

                # short-circuit left recursion here rather than infinite
                # looping
                if options[:parseable].kind_of? SymbolParslet
                  check_left_recursion(options[:parseable], options)
                  @last_seen_symbol_parslet             = options[:parseable]
                  @last_seen_symbol_parslet_location    = [options[:line_start], options[:column_start]]
                end

                return @cache[identifier] = options[:parseable].memoizing_parse(string, options)  # store and return
              rescue Exception => e
                raise @cache[identifier] = e                  # store and re-raise
              end
            end
            throw @cache[identifier] = :ZeroWidthParseSuccess # store and re-throw
          end
          throw @cache[identifier] = :AndPredicateSuccess     # store and re-throw
        end
        throw @cache[identifier] = :NotPredicateSuccess       # store and re-throw
      end
    end

    def check_left_recursion parseable, options = {}
      if parseable.kind_of? SymbolParslet and
         @last_seen_symbol_parslet == parseable and
         @last_seen_symbol_parslet_location == [options[:line_start], options[:column_start]]
        raise LeftRecursionException
      end
    end
  end # class MemoizingCache
end # module Walrat


text:
namespace Barcode
{
    partial class BarcodeConfigDialog
    {
        /// <summary>
        /// Required designer variable.
        /// </summary>
        private System.ComponentModel.IContainer components = null;

        /// <summary>
        /// Clean up any resources being used.
        /// </summary>
        /// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
        protected override void Dispose(bool disposing)
        {
            if (disposing && (components != null))
            {
                components.Dispose();
            }
            base.Dispose(disposing);
        }

        #region Windows Form Designer generated code

        /// <summary>
        /// Required method for Designer support - do not modify
        /// the contents of this method with the code editor.
        /// </summary>
        private void InitializeComponent()
        {
            this.buttonCancel = new System.Windows.Forms.Button();
            this.buttonOK = new System.Windows.Forms.Button();
            this.textBoxText = new System.Windows.Forms.TextBox();
            this.comboEncoding = new System.Windows.Forms.ComboBox();
            this.checkBoxBW = new System.Windows.Forms.CheckBox();
            this.labelText = new System.Windows.Forms.Label();
            this.labelMethod = new System.Windows.Forms.Label();
            this.panelDivider = new System.Windows.Forms.Panel();
            this.panelTextLine = new System.Windows.Forms.Panel();
            this.panelMethodLine = new System.Windows.Forms.Panel();
            this.SuspendLayout();
            //
            // buttonCancel
            //
            this.buttonCancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
            this.buttonCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel;
            this.buttonCancel.FlatStyle = System.Windows.Forms.FlatStyle.System;
            this.buttonCancel.Location = new System.Drawing.Point(254, 141);
            this.buttonCancel.Name = "buttonCancel";
            this.buttonCancel.Size = new System.Drawing.Size(83, 23);
            this.buttonCancel.TabIndex = 5;
            this.buttonCancel.Text = "Cancel";
            this.buttonCancel.UseVisualStyleBackColor = true;
            //
            // buttonOK
            //
            this.buttonOK.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
            this.buttonOK.DialogResult = System.Windows.Forms.DialogResult.OK;
            this.buttonOK.FlatStyle = System.Windows.Forms.FlatStyle.System;
            this.buttonOK.Location = new System.Drawing.Point(162, 141);
            this.buttonOK.Name = "buttonOK";
            this.buttonOK.Size = new System.Drawing.Size(83, 23);
            this.buttonOK.TabIndex = 4;
            this.buttonOK.Text = "OK";
            this.buttonOK.UseVisualStyleBackColor = true;
            //
            // textBoxText
            //
            this.textBoxText.BackColor = System.Drawing.SystemColors.Window;
            this.textBoxText.Location = new System.Drawing.Point(7, 27);
            this.textBoxText.Name = "textBoxText";
            this.textBoxText.Size = new System.Drawing.Size(331, 23);
            this.textBoxText.TabIndex = 0;
            this.textBoxText.TextChanged += new System.EventHandler(this.BarcodeInputValidation);
            //
            // comboEncoding
            //
            this.comboEncoding.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
            this.comboEncoding.FormattingEnabled = true;
            this.comboEncoding.Items.AddRange(new object[] {
            "Code 39",
            "Code 39 mod 43",
            "Full ASCII Code 39",
            "POSTNET",
            "UPC-A"});
            this.comboEncoding.Location = new System.Drawing.Point(7, 76);
            this.comboEncoding.Name = "comboEncoding";
            this.comboEncoding.Size = new System.Drawing.Size(127, 23);
            this.comboEncoding.TabIndex = 1;
            this.comboEncoding.SelectedIndexChanged += new System.EventHandler(this.BarcodeInputValidation);
            //
            // checkBoxBW
            //
            this.checkBoxBW.AutoSize = true;
            this.checkBoxBW.Location = new System.Drawing.Point(7, 109);
            this.checkBoxBW.Name = "checkBoxBW";
            this.checkBoxBW.Size = new System.Drawing.Size(111, 19);
            this.checkBoxBW.TabIndex = 3;
            this.checkBoxBW.Text = "Black and White";
            this.checkBoxBW.UseVisualStyleBackColor = true;
            this.checkBoxBW.CheckedChanged += new System.EventHandler(this.checkBoxBW_CheckedStateChanged);
            //
            // labelText
            //
            this.labelText.AutoSize = true;
            this.labelText.Location = new System.Drawing.Point(6, 8);
            this.labelText.Name = "labelText";
            this.labelText.Size = new System.Drawing.Size(85, 15);
            this.labelText.TabIndex = 0;
            this.labelText.Text = "Text To Encode";
            //
            // labelMethod
            //
            this.labelMethod.AutoSize = true;
            this.labelMethod.Location = new System.Drawing.Point(6, 57);
            this.labelMethod.Name = "labelMethod";
            this.labelMethod.Size = new System.Drawing.Size(102, 15);
            this.labelMethod.TabIndex = 0;
            this.labelMethod.Text = "Encoding Method";
            //
            // panelDivider
            //
            this.panelDivider.BackColor = System.Drawing.SystemColors.ControlLight;
            this.panelDivider.Location = new System.Drawing.Point(7, 133);
            this.panelDivider.Name = "panelDivider";
            this.panelDivider.Size = new System.Drawing.Size(332, 1);
            this.panelDivider.TabIndex = 6;
            //
            // panelTextLine
            //
            this.panelTextLine.BackColor = System.Drawing.SystemColors.ControlLight;
            this.panelTextLine.Location = new System.Drawing.Point(7, 14);
            this.panelTextLine.Name = "panelTextLine";
            this.panelTextLine.Size = new System.Drawing.Size(332, 1);
            this.panelTextLine.TabIndex = 7;
            //
            // panelMethodLine
            //
            this.panelMethodLine.BackColor = System.Drawing.SystemColors.ControlLight;
            this.panelMethodLine.Location = new System.Drawing.Point(7, 63);
            this.panelMethodLine.Name = "panelMethodLine";
            this.panelMethodLine.Size = new System.Drawing.Size(332, 1);
            this.panelMethodLine.TabIndex = 8;
            //
            // BarcodeConfigDialog
            //
            this.AcceptButton = this.buttonOK;
            this.AutoScaleDimensions = new System.Drawing.SizeF(96F, 96F);
            this.CancelButton = this.buttonCancel;
            this.ClientSize = new System.Drawing.Size(345, 174);
            this.Controls.Add(this.panelDivider);
            this.Controls.Add(this.checkBoxBW);
            this.Controls.Add(this.buttonOK);
            this.Controls.Add(this.buttonCancel);
            this.Controls.Add(this.comboEncoding);
            this.Controls.Add(this.textBoxText);
            this.Controls.Add(this.labelText);
            this.Controls.Add(this.labelMethod);
            this.Controls.Add(this.panelTextLine);
            this.Controls.Add(this.panelMethodLine);
            this.Location = new System.Drawing.Point(0, 0);
            this.Name = "BarcodeConfigDialog";
            this.Text = "Barcode";
            this.ResumeLayout(false);
            this.PerformLayout();

        }

        #endregion

        private System.Windows.Forms.Button buttonOK;
        private System.Windows.Forms.TextBox textBoxText;
        private System.Windows.Forms.ComboBox comboEncoding;
        private System.Windows.Forms.Button buttonCancel;
        private System.Windows.Forms.CheckBox checkBoxBW;
        private System.Windows.Forms.Label labelText;
        private System.Windows.Forms.Label labelMethod;
        private System.Windows.Forms.Panel panelTextLine;
        private System.Windows.Forms.Panel panelMethodLine;
        private System.Windows.Forms.Panel panelDivider;
    }
}