text:
package com.amazonaws.services.elasticbeanstalk.model;

import java.io.Serializable;
import javax.annotation.Generated;

/**
 *

 * Provides a list of validation messages.
 *

 *
 * @see AWS API Documentation
 */
@Generated("com.amazonaws:aws-java-sdk-code-generator")
public class ValidateConfigurationSettingsResult extends com.amazonaws.AmazonWebServiceResult<com.amazonaws.ResponseMetadata> implements Serializable,
        Cloneable {

    /**
     *

     * A list of ValidationMessage.
     *

     */
    private com.amazonaws.internal.SdkInternalList<ValidationMessage> messages;

    /**
     *

     * A list of ValidationMessage.
     *

     *
     * @return A list of ValidationMessage.
     */

    public java.util.List<ValidationMessage> getMessages() {
        if (messages == null) {
            messages = new com.amazonaws.internal.SdkInternalList<ValidationMessage>();
        }
        return messages;
    }

    /**
     *

     * A list of ValidationMessage.
     *

     *
     * @param messages
     *        A list of ValidationMessage.
     */

    public void setMessages(java.util.Collection<ValidationMessage> messages) {
        if (messages == null) {
            this.messages = null;
            return;
        }

        this.messages = new com.amazonaws.internal.SdkInternalList<ValidationMessage>(messages);
    }

    /**
     *

     * A list of ValidationMessage.
     *

     *

     * NOTE: This method appends the values to the existing list (if any). Use
     * {@link #setMessages(java.util.Collection)} or {@link #withMessages(java.util.Collection)} if you want to override
     * the existing values.
     *

     *
     * @param messages
     *        A list of ValidationMessage.
     * @return Returns a reference to this object so that method calls can be chained together.
     */

    public ValidateConfigurationSettingsResult withMessages(ValidationMessage... messages) {
        if (this.messages == null) {
            setMessages(new com.amazonaws.internal.SdkInternalList<ValidationMessage>(messages.length));
        }
        for (ValidationMessage ele : messages) {
            this.messages.add(ele);
        }
        return this;
    }

    /**
     *

     * A list of ValidationMessage.
     *

     *
     * @param messages
     *        A list of ValidationMessage.
     * @return Returns a reference to this object so that method calls can be chained together.
     */

    public ValidateConfigurationSettingsResult withMessages(java.util.Collection<ValidationMessage> messages) {
        setMessages(messages);
        return this;
    }

    /**
     * Returns a string representation of this object; useful for testing and debugging.
     *
     * @return A string representation of this object.
     *
     * @see java.lang.Object#toString()
     */
    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append("{");
        if (getMessages() != null)
            sb.append("Messages: ").append(getMessages());
        sb.append("}");
        return sb.toString();
    }

    @Override
    public boolean equals(Object obj) {
        if (this == obj)
            return true;
        if (obj == null)
            return false;

        if (obj instanceof ValidateConfigurationSettingsResult == false)
            return false;
        ValidateConfigurationSettingsResult other = (ValidateConfigurationSettingsResult) obj;
        if (other.getMessages() == null ^ this.getMessages() == null)
            return false;
        if (other.getMessages() != null && other.getMessages().equals(this.getMessages()) == false)
            return false;
        return true;
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int hashCode = 1;

        hashCode = prime * hashCode + ((getMessages() == null) ? 0 : getMessages().hashCode());
        return hashCode;
    }

    @Override
    public ValidateConfigurationSettingsResult clone() {
        try {
            return (ValidateConfigurationSettingsResult) super.clone();
        } catch (CloneNotSupportedException e) {
            throw new IllegalStateException("Got a CloneNotSupportedException from Object.clone() " + "even though we're Cloneable!", e);
        }
    }

}


text:
from google.protobuf import descriptor as _descriptor
from google.protobuf import message as _message
from google.protobuf import reflection as _reflection
from google.protobuf import symbol_database as _symbol_database

# @@protoc_insertion_point(imports)

_sym_db = _symbol_database.Default()

DESCRIPTOR = _descriptor.FileDescriptor(
    name="google/api/context.proto",
    package="google.api",
    syntax="proto3",
    serialized_options=b"\n\016com.google.apiB\014ContextProtoP\001ZEgoogle.golang.org/genproto/googleapis/api/serviceconfig;serviceconfig\242\002\004GAPI",
    serialized_pb=b'\n\x18google/api/context.proto\x12\ngoogle.api"1\n\x07\x43ontext\x12&\n\x05rules\x18\x01 \x03(\x0b\x32\x17.google.api.ContextRule"D\n\x0b\x43ontextRule\x12\x10\n\x08selector\x18\x01 \x01(\t\x12\x11\n\trequested\x18\x02 \x03(\t\x12\x10\n\x08provided\x18\x03 \x03(\tBn\n\x0e\x63om.google.apiB\x0c\x43ontextProtoP\x01ZEgoogle.golang.org/genproto/googleapis/api/serviceconfig;serviceconfig\xa2\x02\x04GAPIb\x06proto3',
)

_CONTEXT = _descriptor.Descriptor(
    name="Context",
    full_name="google.api.Context",
    filename=None,
    file=DESCRIPTOR,
    containing_type=None,
    fields=[
        _descriptor.FieldDescriptor(
            name="rules",
            full_name="google.api.Context.rules",
            index=0,
            number=1,
            type=11,
            cpp_type=10,
            label=3,
            has_default_value=False,
            default_value=[],
            message_type=None,
            enum_type=None,
            containing_type=None,
            is_extension=False,
            extension_scope=None,
            serialized_options=None,
            file=DESCRIPTOR,
        )
    ],
    extensions=[],
    nested_types=[],
    enum_types=[],
    serialized_options=None,
    is_extendable=False,
    syntax="proto3",
    extension_ranges=[],
    oneofs=[],
    serialized_start=40,
    serialized_end=89,
)

_CONTEXTRULE = _descriptor.Descriptor(
    name="ContextRule",
    full_name="google.api.ContextRule",
    filename=None,
    file=DESCRIPTOR,
    containing_type=None,
    fields=[
        _descriptor.FieldDescriptor(
            name="selector",
            full_name="google.api.ContextRule.selector",
            index=0,
            number=1,
            type=9,
            cpp_type=9,
            label=1,
            has_default_value=False,
            default_value=b"".decode("utf-8"),
            message_type=None,
            enum_type=None,
            containing_type=None,
            is_extension=False,
            extension_scope=None,
            serialized_options=None,
            file=DESCRIPTOR,
        ),
        _descriptor.FieldDescriptor(
            name="requested",
            full_name="google.api.ContextRule.requested",
            index=1,
            number=2,
            type=9,
            cpp_type=9,
            label=3,
            has_default_value=False,
            default_value=[],
            message_type=None,
            enum_type=None,
            containing_type=None,
            is_extension=False,
            extension_scope=None,
            serialized_options=None,
            file=DESCRIPTOR,
        ),
        _descriptor.FieldDescriptor(
            name="provided",
            full_name="google.api.ContextRule.provided",
            index=2,
            number=3,
            type=9,
            cpp_type=9,
            label=3,
            has_default_value=False,
            default_value=[],
            message_type=None,
            enum_type=None,
            containing_type=None,
            is_extension=False,
            extension_scope=None,
            serialized_options=None,
            file=DESCRIPTOR,
        ),
    ],
    extensions=[],
    nested_types=[],
    enum_types=[],
    serialized_options=None,
    is_extendable=False,
    syntax="proto3",
    extension_ranges=[],
    oneofs=[],
    serialized_start=91,
    serialized_end=159,
)

_CONTEXT.fields_by_name["rules"].message_type = _CONTEXTRULE
DESCRIPTOR.message_types_by_name["Context"] = _CONTEXT
DESCRIPTOR.message_types_by_name["ContextRule"] = _CONTEXTRULE
_sym_db.RegisterFileDescriptor(DESCRIPTOR)

Context = _reflection.GeneratedProtocolMessageType(
    "Context",
    (_message.Message,),
    {
        "DESCRIPTOR": _CONTEXT,
        "__module__": "google.api.context_pb2"
        # @@protoc_insertion_point(class_scope:google.api.Context)
    },
)
_sym_db.RegisterMessage(Context)

ContextRule = _reflection.GeneratedProtocolMessageType(
    "ContextRule",
    (_message.Message,),
    {
        "DESCRIPTOR": _CONTEXTRULE,
        "__module__": "google.api.context_pb2"
        # @@protoc_insertion_point(class_scope:google.api.ContextRule)
    },
)
_sym_db.RegisterMessage(ContextRule)

DESCRIPTOR._options = None
# @@protoc_insertion_point(module_scope)

redpajama_set_name: RedPajamaGithub


text:
class JarvisCliConfigError(RuntimeError):
    pass

class JarvisPromptError(RuntimeError):
    pass


text:
/**
 * Created by Kamaron on 6/8/2015.
 */

var competition_layer = require('./index');
var CompetitionRules = require('../../models/CompetitionRules');

exports.get = function (req, res) {
    competition_layer.fill_data(req, {
        title: req.comp_data.name,
        subtitle: 'Version 0.3.1 - Zora',
        redirect_url: '/competition/' + req.comp_data.id + '/rules'
    }, function (new_data) {
        // I'm putting this here, because it only applies to the index page.
        new_data.comp_desc = new CompetitionRules(new_data.comp_data);

        res.render('./competition/rules/' + req.comp_data.id + '.jade', new_data);
    });
};


text:
function Get-PSVersion
{

    <#
.SYNOPSIS
    Maps information from $PSVersionTable to a mapping table to retrieve friendly names for Windows PowerShell build numbers

.DESCRIPTION
    Get-PSVersion is a function to map information from $PSVersionTable to a mapping table in order to retrieve friendly names for Windows PowerShell build numbers.
    For example, if the build number is 5.0.10586.117, the returned friendly name will be 'Windows PowerShell 5 RTM 1512'.
    For remote computers, the function relies on PowerShell remoting.
    By default a mapping table bundled with the module is used a data source. The switch parameter -UpdatePSVersionData can be used to download the latest version.

A useful tip is to use a scheduled job to automatically update both the PSVersion module and the PSVersionData:
$ScheduledJobOption = New-ScheduledJobOption -RunElevated
$Trigger = New-JobTrigger -At 03:00:00 -Daily

Register-ScheduledJob -Name Update-PSVersion -ScriptBlock {

Update-Module -Name PSVersion -Force
Import-Module -Name PSVersion
Update-PSVersionData

} -Trigger $Trigger -ScheduledJobOption $ScheduledJobOption -RunNow

.PARAMETER ComputerName
    The remote computer(s) to retrieve PowerShell version information from.

.PARAMETER Credential
    Specifies a user account that has permission to perform this action. The default
    is the current user.

.PARAMETER UpdatePSVersionData
    Triggers the Update-PSVersionData function which will update the PowerShell version mapping table

.EXAMPLE
     Get-PSVersion

.EXAMPLE
     Get-PSVersion -UpdatePSVersionData

.EXAMPLE
     Get-PSVersion -ComputerName 'ComputerA','ComputerB'

.EXAMPLE
     'ComputerA','ComputerB | Get-PSVersion

.EXAMPLE
     Get-PSVersion -ComputerName 'ComputerA','ComputerB -Credential (Get-Credential)

.EXAMPLE
     Get-ADComputer -Filter 'operatingsystem -like "*Server*"' | Select-Object -ExpandProperty Name | Sort-Object -Property Name | Get-PSVersion

.INPUTS
    String

.OUTPUTS
    Selected.System.Collections.Hashtable
    System.Management.Automation.PSCustomObject

.NOTES
    Author:  Jan Egil Ring
    Twitter: @JanEgilRing
#>

    [CmdletBinding()]
    param (
        [Parameter(Mandatory = $false,
            ValueFromPipeline = $true,
            ValueFromPipelineByPropertyName = $true
        )]
        [string[]]$ComputerName = $env:computername,
        [System.Management.Automation.Credential()]$Credential = [System.Management.Automation.PSCredential]::Empty,
        [switch]$UpdatePSVersionData,
        [parameter(ParameterSetName = "ListVersion")]
        [switch]$ListVersion
    )

    BEGIN
    {
        $Params = @{}

        If ($PSBoundParameters['Credential'])
        {
            $Params.Credential = $Credential
        }

        If ($PSBoundParameters['UpdatePSVersionData'])
        {
            Update-PSVersionData -ErrorAction SilentlyContinue
        }

        $functionpath = Split-Path -Path ${function:Get-PSVersion}.File
        $modulepath = Split-Path -Path $functionpath
        $mappingtablemodulepath = Join-Path -Path $modulepath -ChildPath 'PSVersionMappingTable.json'

        if ($IsLinux)
        {
            $mappingtableappdatapath = Join-Path -Path "$($home)/.config" -ChildPath 'PSVersionMappingTable.json'
        }
        else
        {
            $mappingtableappdatapath = Join-Path -Path $env:LOCALAPPDATA\Microsoft\Windows\PowerShell -ChildPath 'PSVersionMappingTable.json'
        }

        if (Test-Path -Path $mappingtableappdatapath)
        {

            Write-Verbose -Message "Found $mappingtableappdatapath, using this version..."
            $mappingtablepath = $mappingtableappdatapath

        }
        else
        {

            Write-Verbose -Message "$mappingtableappdatapath not found, using the mapping table which is bundled with the module..."
            $mappingtablepath = $mappingtablemodulepath

        }

        $mappingtable = Get-Content -Path $mappingtablepath -Raw | ConvertFrom-Json

        If ($PSBoundParameters['ListVersion'])
        {

            Write-Verbose -Message "Parameter Set: ListVersion"
            Write-Verbose -Message "mappingtablepath: $mappingtablepath"

            $mappingtable | Add-ObjectDetail -TypeName 'PSVersionInfoList'

            break

        }

        $ComputerNames = @()

    }

    PROCESS
    {

        $ComputerNames += $ComputerName

    }
    END
    {

        If (-not ($PSBoundParameters['ComputerName']) -or $ComputerName -eq $env:computername -or $ComputerName -eq '127.0.0.1' -or $ComputerName -eq 'localhost' -or $ComputerName -eq '.')
        {

            Write-Verbose -Message 'Parameter -ComputerName not specified, skipping PS Remoting and retrieving information from localhost directly from $PSVersionTable'

            $PSVersion = $PSVersionTable.PSVersion.ToString()
            $FriendlyName = ($mappingtable | Where-Object {$_.Name -eq $PSVersion}).FriendlyName

            if (-not ($FriendlyName))
            {

                Write-Verbose -Message 'FriendlyName not found in mappingtable, trying to update the local mapping table using Update-PSVersionData...'

                Update-PSVersionData -ErrorAction SilentlyContinue

                $mappingtable = Get-Content -Path $mappingtablepath -Raw | ConvertFrom-Json
                $FriendlyName = ($mappingtable | Where-Object {$_.Name -eq $PSVersion}).FriendlyName

                if (-not ($FriendlyName))
                {

                    Write-Verbose -Message 'FriendlyName still not found in mappingtable, setting value to Unknown'

                    $FriendlyName = "Unknown $($_.PSVersion)"

                }
                else
                {

                    Write-Verbose -Message 'FriendlyName found after calling Update-PSVersionData'

                }
            }

            $output = [pscustomobject]@{
                PSComputerName        = hostname
                PSVersion             = $PSVersionTable.PSVersion.ToString()
                PSVersionFriendlyName = $FriendlyName
            }

            $output | Foreach-Object {Add-ObjectDetail -InputObject $_ -TypeName 'PSVersionInfo'}

        }

        $LocalHost = @($env:computername,'127.0.0.1','localhost','.')
        $ComputerNames = $ComputerNames | Where-Object {$PSItem -notin  $LocalHost}

        if ($ComputerNames) {

        $Params.ComputerName = $ComputerNames

        Invoke-Command @Params {

            $PSVersionTable

        } -ErrorAction SilentlyContinue -ErrorVariable failed | Select-Object @{Name = 'PSComputerName'; e = {$_.PSComputerName}}, @{Name = 'PSVersion'; e = {$_.PSVersion.ToString()}}, @{Name = 'PSVersionFriendlyName'; e = {

                $PSVersion = $_.PSVersion.ToString()
                $FriendlyName = ($mappingtable | Where-Object {$_.Name -eq $PSVersion}).FriendlyName

                if ($FriendlyName)
                {

                    $FriendlyName

                }
                else
                {

                    "Unknown $($_.PSVersion)"

                }

            }
        } | Add-ObjectDetail -TypeName 'PSVersionInfo'

    }

        if ($failed)
        {

            foreach ($item in $failed)
            {

                [pscustomobject]@{
                    PSComputerName        = $item.TargetObject
                    PSVersion             = $null
                    PSVersionFriendlyName = 'N/A - PS Remoting failed'
                } | Add-ObjectDetail -TypeName 'PSVersionInfo'
            }

        }

    }

}


text:
package com.anypresence.masterpass_android_library.util;

import android.os.Looper;

import com.anypresence.masterpass_android_library.interfaces.FutureCallback;

import org.apache.http.HttpResponse;
import org.apache.http.StatusLine;
import org.apache.http.client.HttpClient;
import org.apache.http.client.methods.HttpGet;
import org.apache.http.client.methods.HttpPost;
import org.apache.http.client.methods.HttpUriRequest;
import org.apache.http.entity.StringEntity;
import org.apache.http.impl.client.DefaultHttpClient;
import org.apache.http.params.HttpConnectionParams;
import org.json.JSONObject;

import java.io.BufferedReader;
import java.io.InputStream;
import java.io.InputStreamReader;

/**
 * Created by diego.rotondale on 02/02/2015.
 */
public class ConnectionUtil {
    private static final String LOG_TAG = ConnectionUtil.class.getSimpleName();
    private static final Integer TIMEOUT = 10000;

    public static void call(final Boolean post, final String url, final String xSessionId, final JSONObject json, final FutureCallback<JSONObject> listener) {
        Thread t = new Thread() {
            public void run() {
                Looper.prepare();
                HttpClient client = new DefaultHttpClient();
                HttpConnectionParams.setConnectionTimeout(client.getParams(), TIMEOUT);
                HttpResponse response;
                try {
                    HttpUriRequest request = null;
                    if (post) {
                        request = new HttpPost(url);
                        request.setHeader("Accept", "application/json");
                        request.setHeader("Content-type", "application/json");
                        if (json != null) {
                            StringEntity se = new StringEntity(json.toString());
                            se.setContentType("application/json");
                            ((HttpPost) request).setEntity(se);
                        }
                    } else {
                        request = new HttpGet(url);
                    }
                    request.setHeader("Cookie", "_session_id=" + xSessionId);
                    response = client.execute(request);
                    if (response != null) {
                        StatusLine statusLine = response.getStatusLine();
                        int statusCode = statusLine.getStatusCode();

                        InputStream in = response.getEntity().getContent();
                        BufferedReader streamReader = new BufferedReader(new InputStreamReader(in, "UTF-8"));
                        StringBuilder responseStrBuilder = new StringBuilder();

                        String inputStr;
                        while ((inputStr = streamReader.readLine()) != null)
                            responseStrBuilder.append(inputStr);
                        if (statusCode == 200) {
                            listener.onSuccess(new JSONObject(responseStrBuilder.toString()));
                        } else {
                            listener.onFailure(new Throwable(responseStrBuilder.toString()));
                        }
                    }
                } catch (Exception e) {
                    listener.onFailure(e);
                }
                Looper.loop();
            }
        };
        t.start();
    }
}


text:
use Search::Kino03::KinoSearch;

1;

__END__

__AUTO_XS__

my $synopsis = <<'END_SYNOPSIS';
    my $postings_reader
        = $seg_reader->obtain("Search::Kino03::KinoSearch::Index::PostingsReader");
    my $posting_list = $postings_reader->posting_list(
        field => 'content',
        term  => 'foo',
    );
    while ( my $doc_id = $posting_list->next ) {
        say "Matching doc id: $doc_id";
    }
END_SYNOPSIS

{   "Search::Kino03::KinoSearch::Index::PostingList" => {
        bind_methods => [
            qw(
                Seek
                Get_Posting
                Get_Doc_Freq
                Make_Matcher
                )
        ],
        make_constructors => ["new"],
        make_pod          => {
            synopsis => $synopsis,
            methods  => [
                qw(
                    next
                    advance
                    get_doc_id
                    get_doc_freq
                    seek
                    )
            ],
        },
    }
}

__COPYRIGHT__

Copyright 2005-2009 Marvin Humphrey

This program is free software; you can redistribute it and/or modify
under the same terms as Perl itself.


text:
/* flac - Command-line FLAC encoder/decoder
 */

#if HAVE_CONFIG_H
#  include <config.h>
#endif

#include <string.h>

#include "utils.h"
#include "local_string_utils.h"

/*	$OpenBSD: strlcpy.c,v 1.8 2003/06/17 21:56:24 millert Exp $
 *
 * Copyright (c) 1998 Todd C. Miller <Todd.Miller@courtesan.com>
 *
 * Permission to use, copy, modify, and distribute this software for any
 * purpose with or without fee is hereby granted, provided that the above
 * copyright notice and this permission notice appear in all copies.
 *
 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
 * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
 * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
 *
 *
 * Copy src to string dst of size siz.  At most siz-1 characters
 * will be copied.  Always NUL terminates (unless siz == 0).
 * Returns strlen(src); if retval >= siz, truncation occurred.
 */
size_t
flac__strlcpy(char *dst, const char *src, size_t siz)
{
	register char *d = dst;
	register const char *s = src;
	register size_t n = siz;

	/* Copy as many bytes as will fit */
	if (n != 0 && --n != 0) {
		do {
			if ((*d++ = *s++) == 0)
				break;
		} while (--n != 0);
	}

	/* Not enough room in dst, add NUL and traverse rest of src */
	if (n == 0) {
		if (siz != 0)
			*d = '\0';		/* NUL-terminate dst */
		while (*s++)
			;
	}

	return(s - src - 1);	/* count does not include NUL */
}

/*	$OpenBSD: strlcat.c,v 1.11 2003/06/17 21:56:24 millert Exp $
 *
 * Copyright (c) 1998 Todd C. Miller <Todd.Miller@courtesan.com>
 *
 * Permission to use, copy, modify, and distribute this software for any
 * purpose with or without fee is hereby granted, provided that the above
 * copyright notice and this permission notice appear in all copies.
 *
 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
 * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
 * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
 *
 *
 * Appends src to string dst of size siz (unlike strncat, siz is the
 * full size of dst, not space left).  At most siz-1 characters
 * will be copied.  Always NUL terminates (unless siz <= strlen(dst)).
 * Returns strlen(src) + MIN(siz, strlen(initial dst)).
 * If retval >= siz, truncation occurred.
 */
size_t
flac__strlcat(char *dst, const char *src, size_t siz)
{
	register char *d = dst;
	register const char *s = src;
	register size_t n = siz;
	size_t dlen;

	/* Find the end of dst and adjust bytes left but don't go past end */
	while (n-- != 0 && *d != '\0')
		d++;
	dlen = d - dst;
	n = siz - dlen;

	if (n == 0)
		return(dlen + strlen(s));
	while (*s != '\0') {
		if (n != 1) {
			*d++ = *s;
			n--;
		}
		s++;
	}
	*d = '\0';

	return(dlen + (s - src));	/* count does not include NUL */
}


text:
<?php

/**
 * Represents a Distinguished Encoding Rule UniversalString
 *
 * No unicode ucs-2 -> utf-8 is attempted, you're on your own
 *
 * @category  PEAR2
 * @package   PEAR2_Pyrus
 * @author    Greg Beaver <cellog@php.net>
 * @copyright 2010 The PEAR Group
 * @license   http://www.opensource.org/licenses/bsd-license.php New BSD License
 * @link      http://svn.php.net/viewvc/pear2/Pyrus/
 */
namespace PEAR2\Pyrus\DER;
class UniversalString extends String
{
    const TAG = 0x1C;

    function setValue($string)
    {
        $this->value = $string;
    }
}


text:
@class IgzTextureObject;

@interface IgzComponentTexture : IgzComponentBase

@property (readwrite) IgzTextureObject *texture;

@end


text:
using ATZ.CollectionObservers;
using ATZ.DependencyInjection;
using JetBrains.Annotations;
using System;
using System.Collections.ObjectModel;
using System.ComponentModel;
using System.Linq;

namespace ATZ.MVVM.ViewModels.Utility.Connectors
{
    /// <summary>
    /// Connector between a collection of ViewModels and Models.
    /// </summary>
    /// <typeparam name="TModel">The type of the Model.</typeparam>
    // ReSharper disable once ClassWithVirtualMembersNeverInherited.Global => Part of public API.
    public class CollectionViewModelToModelConnector<TModel> : CollectionObserver<TModel, IViewModel<TModel>>, IVerifiable, INotifyPropertyChanged
        where TModel : class
    {
        /// <summary>
        /// Delegate function to bind a ViewModel.
        /// </summary>
        /// <param name="vm">The ViewModel to bind.</param>
        public delegate void ViewModelBinder(IViewModel<TModel> vm);

        private bool _isValid;

        /// <summary>
        /// Delegate to bind the ViewModel.
        /// </summary>
        // ReSharper disable once MemberCanBePrivate.Global => Part of public API.
        public ViewModelBinder BindViewModel { get; set; }

        /// <summary>
        /// Delegate to unbind the ViewModel.
        /// </summary>
        // ReSharper disable once MemberCanBePrivate.Global => Part of public API.
        public ViewModelBinder UnbindViewModel { get; set; }

        /// <summary>
        /// The validity of the object.
        /// </summary>
        public bool IsValid
        {
            get => _isValid;
            set
            {
                if (_isValid == value)
                {
                    return;
                }

                _isValid = value;
                OnIsValidChanged();
            }
        }

        /// <summary>
        /// The validity of the object has changed.
        /// </summary>
        public event EventHandler IsValidChanged;

        /// <summary>
        /// The collection of the Model objects.
        /// </summary>
        public ObservableCollection<TModel> ModelCollection
        {
            get => SourceCollection;
            set => SourceCollection = value;
        }

        /// <summary>
        /// PropertyChanged event for implementing the INotifyPropertyChanged interface.
        /// </summary>
        public event PropertyChangedEventHandler PropertyChanged;

        /// <summary>
        /// The collection of the ViewModel objects.
        /// </summary>
        public ObservableCollection<IViewModel<TModel>> ViewModelCollection
        {
            get => TargetCollection;
            set => TargetCollection = value;
        }

        private void ClearViewModelCollection()
        {
            ClearAllViewModelBindings();
            TargetCollection?.Clear();
        }

        private void DetachViewModel(IViewModel<TModel> viewModel)
        {
            if (viewModel == null)
            {
                return;
            }

            viewModel.IsValidChanged -= UpdateValidity;
            UnbindViewModel?.Invoke(viewModel);
        }

        private static void SortCollection([NotNull] ObservableCollection<TModel> collection, [NotNull] Comparison<TModel> comparison)
        {
            bool swapped;
            do
            {
                swapped = false;
                for (var index = 0; index < collection.Count - 1; ++index)
                {
                    if (comparison(collection[index], collection[index + 1]) <= 0)
                    {
                        continue;
                    }

                    collection.Move(index + 1, index);
                    swapped = true;
                }
            } while (swapped);
        }

        private void UpdateValidity()
        {
            var items = TargetCollection?.ToList();
            if (items == null)
            {
                IsValid = true;
                return;
            }

            IsValid = items.TrueForAll(ViewModelIsNullOrValid);
        }

        private static bool ViewModelIsNullOrValid(IViewModel<TModel> vm)
        {
            return vm == null || vm.IsValid;
        }

        /// <summary>
        /// Fire IsValidChanged event and property change notification for IsValid property.
        /// </summary>
        protected virtual void OnIsValidChanged()
        {
            IsValidChanged?.Invoke(this, EventArgs.Empty);
            PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(nameof(IsValid)));
        }

        /// <summary>
        /// Add the ViewModel to the ViewModel collection and at the same time add the ViewModel's Model to the Model collection.
        /// </summary>
        /// <param name="viewModel">The ViewModel to add to the ViewModel collection.</param>
        /// <exception cref="ArgumentNullException">viewModel is null.</exception>
        public void Add(IViewModel<TModel> viewModel)
        {
            if (viewModel == null)
            {
                throw new ArgumentNullException(nameof(viewModel));
            }

            Add(viewModel.GetModel(), viewModel);
        }

        /// <summary>
        /// Detach all ViewModels in the mirror collection.
        /// </summary>
        public void ClearAllViewModelBindings()
        {
            // ReSharper disable once PossibleNullReferenceException => ToList() does not return null.
            foreach (var viewModel in TargetCollection.ToList())
            {
                DetachViewModel(viewModel);
            }
        }

        /// <summary>
        /// Sort the Model collection with the given comparison method.
        /// </summary>
        /// <param name="comparison">The comparison method to compare the Model objects.</param>
        /// <exception cref="ArgumentNullException">comparison is null.</exception>
        public void Sort(Comparison<TModel> comparison)
        {
            if (comparison == null)
            {
                throw new ArgumentNullException(nameof(comparison));
            }

            var collectionSorted = SourceCollection;
            if (collectionSorted == null)
            {
                return;
            }

            SortCollection(collectionSorted, comparison);
        }

        /// <summary>
        /// Reevaluation of the object validity requested.
        /// </summary>
        /// <param name="sender">The sender of the event.</param>
        /// <param name="e">The arguments of the event.</param>
        public void UpdateValidity(object sender, EventArgs e)
        {
            UpdateValidity();
        }

        /// <see cref="ICollectionChangedEventSource{TSourceItem,TCollectionItem}.ClearCollection"/>
        public override void ClearCollection() => ClearViewModelCollection();

        /// <see cref="ICollectionChangedEventSource{TSourceItem,TCollectionItem}.CreateItem"/>
        public override IViewModel<TModel> CreateItem(TModel sourceItem)
        {
            if (sourceItem == null)
            {
                return null;
            }

            var viewModel = DependencyResolver.Instance.GetInterface<IViewModel<TModel>>(
                typeof(IViewModel<>), sourceItem.GetType());
            if (viewModel == null)
            {
                return null;
            }

            viewModel.SetModel(sourceItem);

            BindViewModel?.Invoke(viewModel);

            viewModel.IsValidChanged += UpdateValidity;
            return viewModel;
        }

        /// <see cref="ICollectionChangedEventSource{TSourceItem,TCollectionItem}.RemoveItem"/>
        public override void RemoveItem(int index)
        {
            var collection = TargetCollection;
            if (collection == null)
            {
                return;
            }

            var viewModel = collection[index];

            DetachViewModel(viewModel);
            collection.RemoveAt(index);
        }

        /// <see cref="ICollectionChangedEventSource{TSourceItem,TCollectionItem}.ReplaceItem"/>
        public override void ReplaceItem(int index, IViewModel<TModel> newItem)
        {
            var collection = TargetCollection;
            if (collection == null)
            {
                return;
            }

            var viewModel = collection[index];

            DetachViewModel(viewModel);
            collection[index] = newItem;
        }
    }
}


text:
    <title>Vimium Options</title>

Vimium - Options

        Scroll step size

          <input id="scrollStepSize" type="text" style="width:50px" />px

            Excluded URLs

                e.g. http*://mail.google.com/*

                This will disable Vimium on Gmail.

                Enter one URL per line.

            <textarea id="excludedUrls"></textarea>

          Advanced options »

        Custom key
mappings

              Enter commands to remap your keys. Available commands:

                map j scrollDown

                unmap j

                unmapAll

                " this is a comment

                # this is also a comment

              Show available commands.

          <textarea id="keyMappings" type="text"></textarea>

        Characters used
 for link hints

                The characters placed next to each link after typing "F" to enter link hinting mode.

            <input id="linkHintCharacters" type="text" style="width:150px" />

        CSS for link hints

              The CSS used to style the characters next to each link hint.

              Note: these styles are used in addition to and take precedence over Vimium's
              default styles.

          <textarea id="userDefinedLinkHintCss" type="text"></textarea>

              After typing "F" to enter link hinting mode, this option lets you type the text of a link
              to select it.

            <input id="filterLinkHints" type="checkbox"/>
            Use the link's name and numbers for link hint filtering

      <button id="restoreSettings" onclick="restoreToDefaults()">Restore to Defaults</button>
      <button id="saveOptions" disabled="true" onclick="saveOptions()">Save Options</button>

      To view all available shortcuts, type ? to show the Vimium help dialog.


text:
using System.Linq;
using System.Reflection;

namespace IglooCastle.Core.Elements
{
    /// <summary>
    /// A code element that is a member of a type.
    /// </summary>
    public abstract class TypeMemberElement<T> : ReflectedElement<T>
        where T: MemberInfo
    {
        /// <summary>
        /// Creates an instance of this class.
        /// </summary>
        protected TypeMemberElement(Documentation documentation, TypeElement ownerType, T member) : base(documentation, member)
        {
            OwnerType = ownerType;
        }

        /// <summary>
        /// Gets the owner type.
        /// </summary>
        public TypeElement OwnerType { get; private set; }

        /// <summary>
        /// Gets the reflected type.
        /// </summary>
        public TypeElement ReflectedType { get { return Documentation.Find(Member.ReflectedType); } }

        /// <summary>
        /// Gets the declaring type.
        /// </summary>
        public TypeElement DeclaringType { get { return Documentation.Find(Member.DeclaringType); } }

        /// <summary>
        /// Gets the namespace element.
        /// </summary>
        public override NamespaceElement NamespaceElement
        {
            get { return Documentation.Namespaces.Single(n => n.Namespace == OwnerType.Member.Namespace); }
        }

        /// <summary>
        /// Gets a value indicating whether the element is inherited or not.
        /// </summary>
        public bool IsInherited
        {
            get
            {
                return Member.DeclaringType != OwnerType.Type;
            }
        }

        /// <summary>
        /// Gets the access related attributes of this element.
        /// </summary>
        public abstract MethodAttributes AccessAttributes { get; }
    }
}


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

<TITLE>
SchemaAnnotation.Attribute (XMLBeans 2.6.0 Documentation)
</TITLE>

<META NAME="date" CONTENT="2012-07-23">

<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">

      Overview
      Package
    Class
      Tree
      Deprecated
      Index
      Help

 PREV CLASS
 NEXT CLASS

  FRAMES
 NO FRAMES

  All Classes

  SUMMARY: NESTED | FIELD | CONSTR | METHOD

DETAIL: FIELD | CONSTR | METHOD

org.apache.xmlbeans

Interface SchemaAnnotation.Attribute

Enclosing interface:
SchemaAnnotation

public static interface SchemaAnnotation.Attribute

Represents an attribute instance

Method Summary

 QName
getName()

          Returns the name of the attribute

 String
getValue()

          Returns the value of the attribute

 String
getValueUri()

          In case the value of this attribute is a QName,
 returns the URI to which the prefix in the value is bound

Method Detail

getName

QName getName()

Returns the name of the attribute

getValue

String getValue()

Returns the value of the attribute

getValueUri

String getValueUri()

In case the value of this attribute is a QName,
 returns the URI to which the prefix in the value is bound

      Overview
      Package
    Class
      Tree
      Deprecated
      Index
      Help

 PREV CLASS
 NEXT CLASS

  FRAMES
 NO FRAMES

  All Classes

  SUMMARY: NESTED | FIELD | CONSTR | METHOD

DETAIL: FIELD | CONSTR | METHOD


text:
package com.alibaba.dubbo.validation;

/**
 * Validator
 *
 * @author william.liangf
 */
public interface Validator {

    void validate(String methodName, Class<?>[] parameterTypes, Object[] arguments) throws Exception;

}


text:
var RxOld = require('rx');
var RxNew = require('../../../../index');

module.exports = function (suite) {
  var oldSkipLastWithImmediateScheduler = RxOld.Observable.range(0, 500, RxOld.Scheduler.immediate).skipLast(50);
  var newSkipLastWithImmediateScheduler = RxNew.Observable.range(0, 500).skipLast(50);

  function _next(x) { }
  function _error(e) { }
  function _complete() { }
  return suite
    .add('old skipLast with immediate scheduler', function () {
      oldSkipLastWithImmediateScheduler.subscribe(_next, _error, _complete);
    })
    .add('new skipLast with immediate scheduler', function () {
      newSkipLastWithImmediateScheduler.subscribe(_next, _error, _complete);
    });
};


text:
set(CPACK_PACKAGE_NAME "${PROJECT_NAME}")
set(CPACK_PACKAGE_VERSION "${PACKAGE_VERSION}")
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "Apache Thrift")
set(CPACK_PACKAGE_DESCRIPTION_FILE "${CMAKE_SOURCE_DIR}/README.md")
set(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_SOURCE_DIR}/LICENSE")
set(CPACK_PACKAGE_VENDOR "Apache Software Foundation")
set(CPACK_PACKAGE_CONTACT "dev@thrift.apache.org")
set(CPACK_PACKAGE_INSTALL_DIRECTORY "${CPACK_PACKAGE_NAME}")
set(CPACK_SYSTEM_NAME "${CMAKE_SYSTEM_NAME}")

### versions
set(CPACK_PACKAGE_VERSION_MAJOR ${thrift_VERSION_MAJOR})
set(CPACK_PACKAGE_VERSION_MINOR ${thrift_VERSION_MINOR})
set(CPACK_PACKAGE_VERSION_PATCH ${thrift_VERSION_PATCH})

### source generator
set(CPACK_SOURCE_GENERATOR "TGZ")
set(CPACK_SOURCE_IGNORE_FILES "~$;[.]swp$;/[.]svn/;/[.]git/;.gitignore;/build/;tags;cscope.*")
set(CPACK_SOURCE_PACKAGE_FILE_NAME "${CPACK_PACKAGE_NAME}-${CPACK_PACKAGE_VERSION}")

### zip generator
set(CPACK_GENERATOR "ZIP")
set(CPACK_PACKAGE_INSTALL_DIRECTORY "thrift")

if(CMAKE_SYSTEM_NAME STREQUAL "Windows")
    set(CPACK_GENERATOR "NSIS")
    set(CPACK_NSIS_HELP_LINK "http://thrift.apache.org")
    set(CPACK_NSIS_MENU_LINKS
        "http://thrift.apache.org" "Apache Thrift - Web Site"
        "https://issues.apache.org/jira/browse/THRIFT" "Apache Thrift - Issues")
    set(CPACK_NSIS_CONTACT ${CPACK_PACKAGE_CONTACT})
    set(CPACK_NSIS_MODIFY_PATH "ON")
    set(CPACK_PACKAGE_INSTALL_DIRECTORY ${CPACK_PACKAGE_NAME})
else()
    set(CPACK_GENERATOR "DEB" )
    set(CPACK_DEBIAN_PACKAGE_MAINTAINER ${CPACK_PACKAGE_CONTACT})
endif()

include(CPack)


text:
/*
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package io.trino.sql.planner.iterative.rule;

import com.google.common.collect.ImmutableMap;
import io.trino.Session;
import io.trino.plugin.tpch.TpchConnectorFactory;
import io.trino.testing.LocalQueryRunner;
import io.trino.testing.MaterializedResult;
import io.trino.testing.QueryRunner;
import org.openjdk.jmh.annotations.Benchmark;
import org.openjdk.jmh.annotations.BenchmarkMode;
import org.openjdk.jmh.annotations.Fork;
import org.openjdk.jmh.annotations.Measurement;
import org.openjdk.jmh.annotations.OutputTimeUnit;
import org.openjdk.jmh.annotations.Param;
import org.openjdk.jmh.annotations.Setup;
import org.openjdk.jmh.annotations.State;
import org.openjdk.jmh.annotations.TearDown;
import org.openjdk.jmh.annotations.Warmup;
import org.openjdk.jmh.runner.RunnerException;

import static io.trino.jmh.Benchmarks.benchmark;
import static io.trino.testing.TestingSession.testSessionBuilder;
import static java.util.concurrent.TimeUnit.MILLISECONDS;
import static org.openjdk.jmh.annotations.Mode.AverageTime;
import static org.openjdk.jmh.annotations.Scope.Thread;

@State(Thread)
@OutputTimeUnit(MILLISECONDS)
@BenchmarkMode(AverageTime)
@Fork(3)
@Warmup(iterations = 10)
@Measurement(iterations = 10)
public class BenchmarkReorderChainedJoins
{
    @Benchmark
    public MaterializedResult benchmarkReorderJoins(BenchmarkInfo benchmarkInfo)
    {
        return benchmarkInfo.getQueryRunner().execute(
                "EXPLAIN SELECT * FROM " +
                        "nation n1 JOIN nation n2 ON n1.nationkey = n2.nationkey " +
                        "JOIN nation n3 ON n2.comment = n3.comment " +
                        "JOIN nation n4 ON n3.name = n4.name " +
                        "JOIN region r1 ON n4.regionkey = r1.regionkey " +
                        "JOIN region r2 ON r1.name = r2.name " +
                        "JOIN region r3 ON r3.comment = r2.comment " +
                        "JOIN region r4 ON r4.regionkey = r3.regionkey");
    }

    @State(Thread)
    public static class BenchmarkInfo
    {
        @Param({"ELIMINATE_CROSS_JOINS", "AUTOMATIC"})
        private String joinReorderingStrategy;

        private LocalQueryRunner queryRunner;

        @Setup
        public void setup()
        {
            Session session = testSessionBuilder()
                    .setSystemProperty("join_reordering_strategy", joinReorderingStrategy)
                    .setSystemProperty("join_distribution_type", "AUTOMATIC")
                    .setCatalog("tpch")
                    .setSchema("tiny")
                    .build();
            queryRunner = LocalQueryRunner.create(session);
            queryRunner.createCatalog("tpch", new TpchConnectorFactory(1), ImmutableMap.of());
        }

        public QueryRunner getQueryRunner()
        {
            return queryRunner;
        }

        @TearDown
        public void tearDown()
        {
            queryRunner.close();
        }
    }

    public static void main(String[] args)
            throws RunnerException
    {
        benchmark(BenchmarkReorderChainedJoins.class).run();
    }
}


text:
package ch10.inheritance1;

/**
 * Dumps out the command-line information about a Person object.
 */
public class PersonViewer
{
    /**
     * View the person
     */
    public void view(Person person)
    {
        System.out.println("Person.." + person.getClass().getSimpleName());
        System.out.println("Name: " + person.getName());
        System.out.println("Email: " + person.getEmail());
        System.out.println("Description: " + person.getDescription());
        System.out.println("\n");
    }

}


text:
// ----------------------------------------------------------------------------------
//
// Copyright Microsoft Corporation
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
// http://www.apache.org/licenses/LICENSE-2.0
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
// ----------------------------------------------------------------------------------

using System.Collections.Generic;
using System.Linq;
using System.Management.Automation;
using Microsoft.Azure.Management.DataMigration.Models;

namespace Microsoft.Azure.Commands.DataMigration.Cmdlets
{
    public class ValidateSqlServerSqlDbSyncTaskCmdlet : TaskCmdlet
    {
        private readonly string SelectedDatabase = "SelectedDatabase";

        public ValidateSqlServerSqlDbSyncTaskCmdlet(InvocationInfo myInvocation) : base(myInvocation)
        {
        }

        public override void CustomInit()
        {
            this.SourceConnectionInfoParam(true);
            this.TargetConnectionInfoParam(true);
            this.SimpleParam(SelectedDatabase, typeof(MigrateSqlServerSqlDbSyncDatabaseInput[]), "Selected database to migrate", true);
        }

        public override ProjectTaskProperties ProcessTaskCmdlet()
        {
            SqlConnectionInfo sourceConnectionInfo = null;
            SqlConnectionInfo targetConnectionInfo = null;
            List<MigrateSqlServerSqlDbSyncDatabaseInput> selectedDatabases = null;

            if (MyInvocation.BoundParameters.ContainsKey(SourceConnection))
            {
                sourceConnectionInfo = (SqlConnectionInfo)MyInvocation.BoundParameters[SourceConnection];
                PSCredential cred = (PSCredential)MyInvocation.BoundParameters[SourceCred];
                sourceConnectionInfo.UserName = cred.UserName;
                sourceConnectionInfo.Password = Decrypt(cred.Password);
            }

            if (MyInvocation.BoundParameters.ContainsKey(TargetConnection))
            {
                targetConnectionInfo = (SqlConnectionInfo)MyInvocation.BoundParameters[TargetConnection];
                PSCredential cred = (PSCredential)MyInvocation.BoundParameters[TargetCred];
                targetConnectionInfo.UserName = cred.UserName;
                targetConnectionInfo.Password = Decrypt(cred.Password);
            }

            if (MyInvocation.BoundParameters.ContainsKey(SelectedDatabase))
            {
                selectedDatabases
                    = ((MigrateSqlServerSqlDbSyncDatabaseInput[])MyInvocation.BoundParameters[SelectedDatabase]).ToList();
            }

            var properties = new ValidateMigrationInputSqlServerSqlDbSyncTaskProperties
            {
                Input = new ValidateSyncMigrationInputSqlServerTaskInput
                {
                    SourceConnectionInfo = sourceConnectionInfo,
                    TargetConnectionInfo = targetConnectionInfo,
                    SelectedDatabases = selectedDatabases,
                }
            };

            return properties;
        }
    }
}


text:
namespace elang {
namespace hir {

#define V(Name, ...)                                                     \
  void InstructionVisitor::Visit##Name(Name##Instruction* instruction) { \
    DoDefaultVisit(instruction);                                         \
  }
FOR_EACH_HIR_INSTRUCTION(V)
#undef V

#define V(Name, ...)                                            \
  void Name##Instruction::Accept(InstructionVisitor* visitor) { \
    visitor->Visit##Name(this);                                 \
  }
FOR_EACH_HIR_INSTRUCTION(V)
#undef V

void InstructionVisitor::DoDefaultVisit(Instruction* instruction) {
  DCHECK(instruction);
}

InstructionFactory::InstructionFactory(Factory* factory,
                                       const FactoryConfig& config)
    : TypeFactoryUser(new TypeFactory(config)),
      factory_(factory),
      type_factory_(types()) {
}

InstructionFactory::~InstructionFactory() {
}

#define V(Name, ...)                                                 \
  Instruction* InstructionFactory::New##Name##Instruction(           \
      Type* output_type, Value* left, Value* right) {                \
    DCHECK(output_type->is_numeric()) << *output_type;               \
    DCHECK_EQ(output_type, left->type()) << *left << " " << *right;  \
    DCHECK_EQ(output_type, right->type()) << *left << " " << *right; \
    auto const instr = new (zone()) Name##Instruction(output_type);  \
    instr->InitInputAt(0, left);                                     \
    instr->InitInputAt(1, right);                                    \
    return instr;                                                    \
  }
FOR_EACH_ARITHMETIC_BINARY_OPERATION(V)
#undef V

#define V(Name, ...)                                                 \
  Instruction* InstructionFactory::New##Name##Instruction(           \
      Type* output_type, Value* left, Value* right) {                \
    DCHECK(output_type->is_integer()) << *output_type;               \
    DCHECK_EQ(output_type, left->type()) << *left << " " << *right;  \
    DCHECK_EQ(output_type, right->type()) << *left << " " << *right; \
    auto const instr = new (zone()) Name##Instruction(output_type);  \
    instr->InitInputAt(0, left);                                     \
    instr->InitInputAt(1, right);                                    \
    return instr;                                                    \
  }
FOR_EACH_BITWISE_BINARY_OPERATION(V)
#undef V

#define V(Name, ...)                                                \
  Instruction* InstructionFactory::New##Name##Instruction(          \
      Type* output_type, Value* left, Value* right) {               \
    DCHECK(output_type->is_integer()) << *output_type;              \
    DCHECK(left->type()->is_integer()) << *left << " " << *right;   \
    DCHECK_EQ(int32_type(), right->type()) << *right;               \
    auto const instr = new (zone()) Name##Instruction(output_type); \
    instr->InitInputAt(0, left);                                    \
    instr->InitInputAt(1, right);                                   \
    return instr;                                                   \
  }
FOR_EACH_BITWISE_SHIFT_OPERATION(V)
#undef V

#define V(Name, ...)                                                      \
  Instruction* InstructionFactory::New##Name##Instruction(Value* left,    \
                                                          Value* right) { \
    DCHECK_EQ(left->type(), right->type()) << *left << " " << *right;     \
    auto const instr = new (zone()) Name##Instruction(bool_type());       \
    instr->InitInputAt(0, left);                                          \
    instr->InitInputAt(1, right);                                         \
    return instr;                                                         \
  }
FOR_EACH_EQUALITY_OPERATION(V)
#undef V

#define V(Name, ...)                                                      \
  Instruction* InstructionFactory::New##Name##Instruction(Value* left,    \
                                                          Value* right) { \
    DCHECK(left->type()->is_numeric()) << *left << " " << *right;         \
    DCHECK_EQ(left->type(), right->type()) << *left << " " << *right;     \
    auto const instr = new (zone()) Name##Instruction(bool_type());       \
    instr->InitInputAt(0, left);                                          \
    instr->InitInputAt(1, right);                                         \
    return instr;                                                         \
  }
FOR_EACH_RELATIONAL_OPERATION(V)
#undef V

#define V(Name, ...)                                                         \
  Instruction* InstructionFactory::New##Name##Instruction(Type* output_type, \
                                                          Value* input) {    \
    auto const instr = new (zone()) Name##Instruction(output_type);          \
    instr->InitInputAt(0, input);                                            \
    return instr;                                                            \
  }
FOR_EACH_TYPE_CAST_OPERATION(V)
#undef V

Instruction* InstructionFactory::NewBoundInstruction(Value* array,
                                                     Value* indexes) {
  auto const array_type =
      array->type()->as<PointerType>()->pointee()->as<ArrayType>();
  DCHECK(array_type);
  auto const instr = new (zone()) BoundInstruction(bool_type());
#ifndef NDEBUG
  if (array_type->rank() == 1) {
    DCHECK_EQ(int32_type(), indexes->type());
  } else if (auto const indexes_type = indexes->as<TupleType>()) {
    DCHECK_EQ(array_type->rank(), indexes_type->size());
    for (auto const type : indexes_type->members())
      DCHECK_EQ(int32_type(), type);
  }
#endif
  instr->InitInputAt(0, array);
  instr->InitInputAt(1, indexes);
  return instr;
}

Instruction* InstructionFactory::NewBranchInstruction(Value* condition,
                                                      BasicBlock* true_block,
                                                      BasicBlock* false_block) {
  DCHECK_EQ(bool_type(), condition->type());
  // Since, we use use-def list for representing predecessors of basic block,
  // basic block must be unique in inputs.
  DCHECK_NE(true_block, false_block);
  auto const instr = new (zone()) BranchInstruction(void_type());
  instr->InitInputAt(0, condition);
  instr->InitInputAt(1, true_block);
  instr->InitInputAt(2, false_block);
  return instr;
}

Instruction* InstructionFactory::NewBranchInstruction(
    BasicBlock* target_block) {
  auto const instr = new (zone()) JumpInstruction(void_type());
  instr->InitInputAt(0, target_block);
  return instr;
}

Instruction* InstructionFactory::NewCallInstruction(Value* callee,
                                                    Value* arguments) {
  auto const callee_type = callee->type()->as<FunctionType>();
  DCHECK(callee_type);
  auto const instr = new (zone()) CallInstruction(callee_type->return_type());
  instr->InitInputAt(0, callee);
  instr->InitInputAt(1, arguments);
  return instr;
}

Instruction* InstructionFactory::NewEntryInstruction(Type* output_type) {
  return new (zone()) EntryInstruction(output_type);
}

Instruction* InstructionFactory::NewElementInstruction(Value* array,
                                                       Value* indexes) {
  auto const array_type =
      array->type()->as<PointerType>()->pointee()->as<ArrayType>();
  DCHECK(array_type);
  auto const instr = new (zone())
      ElementInstruction(types()->NewPointerType(array_type->element_type()));
#ifndef NDEBUG
  if (array_type->rank() == 1) {
    DCHECK_EQ(int32_type(), indexes->type());
  } else if (auto const indexes_type = indexes->as<TupleType>()) {
    DCHECK_EQ(array_type->rank(), indexes_type->size());
    for (auto const type : indexes_type->members())
      DCHECK_EQ(int32_type(), type);
  }
#endif
  instr->InitInputAt(0, array);
  instr->InitInputAt(1, indexes);
  return instr;
}

Instruction* InstructionFactory::NewExitInstruction() {
  return new (zone()) ExitInstruction(void_type());
}

Instruction* InstructionFactory::NewGetInstruction(Value* value, int index) {
  auto const tuple_type = value->type()->as<TupleType>();
  DCHECK(tuple_type) << *value;
  auto const output_type = tuple_type->get(index);
  auto const instr = new (zone()) GetInstruction(output_type, index);
  instr->InitInputAt(0, value);
  return instr;
}

Instruction* InstructionFactory::NewIfInstruction(Type* output_type,
                                                  Value* condition,
                                                  Value* true_value,
                                                  Value* false_value) {
  DCHECK_EQ(bool_type(), condition->type());
  DCHECK_EQ(output_type, true_value->type());
  DCHECK_EQ(output_type, false_value->type());
  auto const instr = new (zone()) IfInstruction(output_type);
  instr->InitInputAt(0, condition);
  instr->InitInputAt(1, true_value);
  instr->InitInputAt(2, false_value);
  return instr;
}

Instruction* InstructionFactory::NewLengthInstruction(Value* array, int index) {
  auto const array_type =
      array->type()->as<PointerType>()->pointee()->as<ArrayType>();
  DCHECK(array_type);
  DCHECK_GE(index, 0);
  DCHECK_LT(index, array_type->rank());
  auto const instr = new (zone()) LengthInstruction(int32_type(), index);
  instr->InitInputAt(0, array);
  return instr;
}

Instruction* InstructionFactory::NewLoadInstruction(Value* base_pointer,
                                                    Value* pointer) {
  DCHECK(base_pointer->type()->is<PointerType>());
  auto const pointer_type = pointer->type()->as<PointerType>();
  DCHECK(pointer_type);
  auto const instr = new (zone()) LoadInstruction(pointer_type->pointee());
  instr->InitInputAt(0, base_pointer);
  instr->InitInputAt(1, pointer);
  return instr;
}

PhiInstruction* InstructionFactory::NewPhiInstruction(Type* output_type) {
  return new (zone()) PhiInstruction(output_type);
}

Instruction* InstructionFactory::NewRetInstruction(Value* value,
                                                   BasicBlock* exit_block) {
  auto const instr = new (zone()) RetInstruction(void_type());
  instr->InitInputAt(0, value);
  instr->InitInputAt(1, exit_block);
  return instr;
}

Instruction* InstructionFactory::NewThrowInstruction(Value* value,
                                                     BasicBlock* exit_block) {
  DCHECK(!value->is<VoidValue>());
  auto const instr = new (zone()) ThrowInstruction(void_type());
  instr->InitInputAt(0, value);
  instr->InitInputAt(1, exit_block);
  return instr;
}

Instruction* InstructionFactory::NewStackAllocInstruction(Type* type,
                                                          int count) {
  DCHECK(type->can_allocate_on_stack());
  DCHECK_GE(count, 1);
  return new (zone())
      StackAllocInstruction(types()->NewPointerType(type), count);
}

Instruction* InstructionFactory::NewStoreInstruction(Value* base_pointer,
                                                     Value* pointer,
                                                     Value* value) {
  DCHECK(base_pointer->type()->is<PointerType>());
  auto const pointer_type = pointer->type()->as<PointerType>();
  DCHECK(pointer_type);
  DCHECK_EQ(pointer_type->pointee(), value->type());
  auto const instr = new (zone()) StoreInstruction(void_type());
  instr->InitInputAt(0, base_pointer);
  instr->InitInputAt(1, pointer);
  instr->InitInputAt(2, value);
  return instr;
}

Instruction* InstructionFactory::NewTupleInstruction(
    Type* output_type,
    const std::vector<Value*>& inputs) {
  DCHECK(output_type->is<TupleType>());
  DCHECK(!inputs.empty());
  auto const instr = new (zone())
      TupleInstruction(zone(), output_type, static_cast<int>(inputs.size()));
  auto index = 0;
  for (auto const input : inputs) {
    instr->InitInputAt(index, input);
    ++index;
  }
  return instr;
}

Instruction* InstructionFactory::NewUnreachableInstruction(
    BasicBlock* exit_block) {
  auto const instr = new (zone()) UnreachableInstruction(void_type());
  instr->InitInputAt(0, exit_block);
  return instr;
}

}  // namespace hir
}  // namespace elang


text:
name             'setup-users'
maintainer       'Aiming Inc.'
maintainer_email 'info@aiming-inc.com'
license          'MIT'
description      'Installs/Configures setup-users'
long_description IO.read(File.join(File.dirname(__FILE__), 'README.md'))
version          '0.1.0'


text:
<!DOCTYPE html>

		<meta charset="utf-8">
		<meta name="HandheldFriendly" content="True">

		<title>Key.js - usage example</title>


text:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:orientation="horizontal" android:layout_width="match_parent"
    android:layout_height="40dp" android:gravity="center_vertical">

    <TextView
        android:id="@+id/type"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_marginRight="25dp"/>
    <TextView
        android:id="@+id/date"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_marginRight="25dp"/>
    <TextView
        android:id="@+id/comment"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"/>

</LinearLayout>


text:
@interface MTLTapa : MTLModel <MTLJSONSerializing, MTLManagedObjectSerializing>

@property (nonatomic, copy, readonly) NSNumber *identifier;
@property (nonatomic, copy, readonly) NSString *nombre;
@property (nonatomic, copy, readonly) NSString *desc;
@property (nonatomic, copy, readonly) NSDate *fechaCreacion;
@property (nonatomic, copy, readonly) NSURL *imagen;
@property (nonatomic, strong, readonly) MTLTipoTapa *tipoTapa;

@end


text:
package com.sandflow.smpte.mxf;

import com.sandflow.smpte.klv.Triplet;
import com.sandflow.smpte.klv.exceptions.KLVException;
import com.sandflow.smpte.util.UL;
import java.io.IOException;
import java.util.ArrayList;

/**
 * Represents a MXF Partition Pack Item (see SMPTE ST 377-1)
 */
public class RandomIndexPack {

    private static final UL KEY = UL.fromURN("urn:smpte:ul:060e2b34.02050101.0d010201.01110100");

    /**
     * Returns the Pack Key
     * @return Key
     */
    public static UL getKey() {
        return KEY;
    }

    /**
     * Creates a Random Index Pack (RIP) from a Triplet
     * @param triplet Triplet from which to create the RIP
     * @return Random Index Pack or null if the Triplet is not a Random Index Pack
     * @throws KLVException
     */
    public static RandomIndexPack fromTriplet(Triplet triplet) throws KLVException {
        RandomIndexPack pp = new RandomIndexPack();

        if (!KEY.equals(triplet.getKey())) {
            return null;
        }

        /* does the length make sense? */

        if ((triplet.getLength() - 4) % 12 != 0) {
            return null;
        }

        long count = (triplet.getLength() - 4)/12;

        try {
            MXFInputStream kis = new MXFInputStream(triplet.getValueAsStream());

            for(int i = 0; i < count; i++) {

                long bodySID = kis.readUnsignedInt();
                long offset = kis.readLong();

                PartitionOffset po = new PartitionOffset(bodySID, offset);

                pp.offsets.add(po);
            }

        } catch (IOException e) {
            throw new KLVException(e);
        }

        return pp;
    }

    /**
     * @return Ordered array containing the offsets stored in the RIP
     */
    public ArrayList<PartitionOffset> getOffsets() {
        return offsets;
    }

    private final ArrayList<PartitionOffset> offsets = new ArrayList<>();

    /**
     * Represents one partition offset entry stored in the RIP
     */
    static public class PartitionOffset {
       private final long bodySID;
       private final long offset;

        public PartitionOffset(long bodySID, long offset) {
            this.bodySID = bodySID;
            this.offset = offset;
        }

        /**
         *
         * @return Identifies the partition
         */
        public long getBodySID() {
            return bodySID;
        }

        /**
         *
         * @return Offset (in bytes) of the partition
         */
        public long getOffset() {
            return offset;
        }

   }
}


text:
/* bigBedFilter.h - Filter things from bigBeds */

/* Copyright (C) 2018 The Regents of the University of California
 * See README in this or parent directory for licensing information. */

#ifndef BIGBEDFILTER_H
#define BIGBEDFILTER_H

/* the values legal for *FilterType */
#define FILTERBY_SINGLE            "single"
#define FILTERBY_MULTIPLE          "multiple"
#define FILTERBY_SINGLE_LIST       "singleList"
#define FILTERBY_MULTIPLE_LIST_OR  "multipleListOr"
#define FILTERBY_MULTIPLE_LIST_AND "multipleListAnd"
#define FILTERTEXT_WILDCARD        "wildcard"
#define FILTERTEXT_REGEXP          "regexp"

/* cart and tdb variables */
#define FILTER_NUMBER_NAME    "Filter"
#define FILTER_TEXT_NAME      "FilterText"
#define FILTER_VALUES_NAME    "FilterValues"
#define FILTER_TYPE_NAME      "FilterType"
#define FILTER_NUMBER_WILDCARD    "*" FILTER_NUMBER_NAME
#define FILTER_TEXT_WILDCARD      "*" FILTER_TEXT_NAME
#define FILTER_VALUES_WILDCARD    "*" FILTER_VALUES_NAME
#define FILTER_TYPE_WILDCARD      "*" FILTER_TYPE_NAME

struct bigBedFilter
/* Filter on a field in a bigBed file. */
{
struct bigBedFilter *next;
int fieldNum;   // the field number
enum {COMPARE_LESS, COMPARE_MORE, COMPARE_BETWEEN, COMPARE_HASH, COMPARE_REGEXP, COMPARE_WILDCARD, COMPARE_HASH_LIST_AND, COMPARE_HASH_LIST_OR } comparisonType;  // the type of the comparison
double value1, value2;
struct hash *valueHash;
unsigned numValuesInHash;
regex_t regEx;
char *wildCardString;
};

struct bigBedFilter *bigBedMakeNumberFilter(struct cart *cart, struct bbiFile *bbi, struct trackDb *tdb, char *filter, char *defaultLimits,  char *field);
/* Add a bigBed filter using a trackDb filterBy statement. */

boolean bigBedFilterInterval(char **bedRow, struct bigBedFilter *filters);
/* Go through a row and filter based on filters.  Return TRUE if all filters are passed. */

struct bigBedFilter *bigBedBuildFilters(struct cart *cart, struct bbiFile *bbi, struct trackDb *tdb) ;
/* Build all the numeric and filterBy filters for a bigBed */

#endif /* BIGBEDFILTER_H */


text:
import * as calendar from "../../src/calendar.js";
import * as internal from "../../src/internal.js";
import CalendarDays from "../../define/CalendarDays.js";

describe("CalendarDays", () => {
  it("returns day elements inside the calendar's range", async () => {
    const fixture = new CalendarDays();
    fixture.startDate = new Date("1 January 2019");
    fixture.dayCount = 31;
    await fixture[internal.renderChanges]();
    assert.equal(31, fixture.days.length);
    const lastDay = fixture.days[30];
    assert(calendar.datesEqual(lastDay.date, new Date("31 Jan 2019")));
    const dateInRange = new Date("15 January 2019");
    const dayElementInRange = fixture.dayElementForDate(dateInRange);
    assert(fixture.days[14], dayElementInRange);
    const dateOutOfRange = new Date("1 Jan 2016");
    assert.isUndefined(fixture.dayElementForDate(dateOutOfRange));
  });

  it("positions days with respect to the locale's preferred week start day", async () => {
    const fixture = new CalendarDays();
    fixture.locale = "en-US"; // Weeks start on Sunday
    fixture.startDate = new Date("10 March 2015"); // A Tuesday
    await fixture[internal.renderChanges]();
    assert.equal(fixture.days[0].style.gridColumnStart, "3");
    fixture.locale = "en-GB"; // Weeks start on Monday
    await fixture[internal.renderChanges]();
    assert.equal(fixture.days[0].style.gridColumnStart, "2");
  });
});