text:
<?php
/*
	file: inline_renderer.php

	This file is a modified renderer for the Text_Diff PEAR package.

	The inline_diff code was written by Ciprian Popovici in 2004,
	as a hack building upon the Text_Diff PEAR package.
	It is released under the GPL.

	There are 3 files in this package: inline_example.php, inline_function.php, inline_renderer.php
*/

	include_once 'Text/Diff/Renderer.php';
	class Text_Diff_Renderer_inline extends Text_Diff_Renderer {

	var $ins_prefix = '
';
	var $ins_suffix = '
';
	var $del_prefix = '
';
	var $del_suffix = '
';

	function Text_Diff_Renderer_inline($context_lines = 10000, $ins_prefix = '
', $ins_suffix = '
', $del_prefix = '
', $del_suffix = '
')
    {
		$this->$ins_prefix = $ins_prefix;
		$this->$ins_suffix = $ins_suffix;
		$this->$del_prefix = $del_prefix;
		$this->$del_suffix = $del_suffix;

        $this->_leading_context_lines = $context_lines;
        $this->_trailing_context_lines = $context_lines;
    }

    function _lines($lines)
    {
        $value="";
        foreach ($lines as $line) {
            $value.="$line ";
            // FIXME: don't output space if it's the last line.
        }
        return "<xmp>".$value."</xmp>";
    }

    function _blockHeader($xbeg, $xlen, $ybeg, $ylen)
    {
		return '';
    }

    function _startBlock($header)
    {
        return $header;
    }

    function _context($lines)
    {
          return $this->_lines($lines, '  ');
    }
    function _added($lines)
    {
        return  $this->ins_prefix.$this->_lines($lines).$this->ins_suffix;
    }

    function _deleted($lines)
    {
        return  $this->del_prefix.$this->_lines($lines).$this->del_suffix;
    }

    function _changed($orig, $final)
    {
        return "
".$this->_deleted($orig) ."

". $this->_added($final)."
";
    }

}


text:
require 'podrick/version'
require 'podrick/podcast'
require 'podrick/episode'

redpajama_set_name: RedPajamaGithub


text:
#ifndef SQUIM_IMAGE_IMAGE_DECODER_H_
#define SQUIM_IMAGE_IMAGE_DECODER_H_

#include "squim/image/image_constants.h"
#include "squim/image/result.h"

namespace image {

class ImageFrame;
struct ImageInfo;
class ImageMetadata;

// Decoder interface.
class ImageDecoder {
 public:
  // Should return true if image header (containing width, height, and stuff)
  // has been parsed and client can call any of the methods above.
  virtual bool IsImageInfoComplete() const = 0;

  // Returns ImageInfo info for image being decoded. returned structure is valid
  // iff IsImageInfoComplete() return true.
  virtual const ImageInfo& GetImageInfo() const = 0;

  // Should return true iff frame header at |index| has been successfully
  // parsed.
  virtual bool IsFrameHeaderCompleteAtIndex(size_t index) const = 0;

  // Should return true iff frame at |index| has been successfully decoded
  // so far.
  virtual bool IsFrameCompleteAtIndex(size_t index) const = 0;

  // Should return non-owned pointer to the decoded image frame. Implementations
  // may assume that |index| refers to a decoded frame - it's up to the client
  // to ensure it using IsFrameCompleteAtIndex().
  virtual ImageFrame* GetFrameAtIndex(size_t index) = 0;

  // Returns number of frames *decoded so far*. 1 does not generally mean that
  // image is single frame, other may not be decoded yet
  virtual size_t GetFrameCount() const = 0;

  // Returns image metadata.
  virtual ImageMetadata* GetMetadata() = 0;

  // Should return true if all metadata has been parsed.
  virtual bool IsAllMetadataComplete() const = 0;

  // Should return true if all frames has been decoded.
  virtual bool IsAllFramesComplete() const = 0;

  // Should return true if the whole image is ready.
  virtual bool IsImageComplete() const = 0;

  // Should decode more if data available.
  virtual Result Decode() = 0;

  // Should try to decode only basic image info (usually from image header).
  virtual Result DecodeImageInfo() = 0;

  // True if the error occurred. Decoding cannot progress after that.
  virtual bool HasError() const = 0;

  virtual ~ImageDecoder() {}
};

}  // namespace image

#endif  // SQUIM_IMAGE_IMAGE_DECODER_H_


text:
<?php

// AcmeProductBundle:Default:layout1.html.twig
return array (
);


text:
<!--
id: 48358110046
link: http://tumblr.atmos.org/post/48358110046/joshpeek-on-content-security-policy
slug: joshpeek-on-content-security-policy
date: Fri Apr 19 2013 07:53:11 GMT-0700 (PDT)
publish: 2013-04-019
tags:
title: @joshpeek on Content Security Policy
-->

@joshpeek on Content Security Policy
====================================

[https://github.com/blog/1477-content-security-policy](https://github.com/blog/1477-content-security-policy)


text:
<?php
namespace ReduxCore\ReduxFramework;
/**
 * Redux Framework is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 2 of the License, or
 * any later version.
 * Redux Framework is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
 * GNU General Public License for more details.
 * You should have received a copy of the GNU General Public License
 * along with Redux Framework. If not, see <http://www.gnu.org/licenses/>.
 *
 * @package     ReduxFramework
 * @subpackage  Field_Multi_Text
 * @author      Daniel J Griffiths (Ghost1227)
 * @author      Dovy Paukstys
 * @version     3.0.0
 */

// Exit if accessed directly
if ( ! defined( 'ABSPATH' ) ) {
    exit;
}

// Don't duplicate me!
if ( ! class_exists( 'ReduxFramework_multi_text' ) ) {

    /**
     * Main ReduxFramework_multi_text class
     *
     * @since       1.0.0
     */
    class ReduxFramework_multi_text {

        /**
         * Field Constructor.
         * Required - must call the parent constructor, then assign field and value to vars, and obviously call the render field function
         *
         * @since       1.0.0
         * @access      public
         * @return      void
         */
        function __construct( $field = array(), $value = '', $parent = ' ' ) {
            $this->parent = $parent;
            $this->field  = $field;
            $this->value  = $value;
        }

        /**
         * Field Render Function.
         * Takes the vars and outputs the HTML for the field in the settings
         *
         * @since       1.0.0
         * @access      public
         * @return      void
         */
        public function render() {

            $this->add_text   = ( isset( $this->field['add_text'] ) ) ? $this->field['add_text'] : __( 'Add More', 'accelerated-mobile-pages' );
            $this->show_empty = ( isset( $this->field['show_empty'] ) ) ? $this->field['show_empty'] : true;

            echo '
field['id'] . '-ul" class="redux-multi-text">';

            if ( isset( $this->value ) && is_array( $this->value ) ) {
                foreach ( $this->value as $k => $value ) {
                    if ( $value != '' ) {
                        echo '
<input type="text" id="' . $this->field['id'] . '-' . $k . '" name="' . $this->field['name'] . $this->field['name_suffix'] . '[]' . '" value="' . esc_attr( $value ) . '" class="regular-text ' . $this->field['class'] . '" /> ' . __( 'Remove', 'accelerated-mobile-pages' ) . '
';
                    }
                }
            } elseif ( $this->show_empty == true ) {
                echo '
<input type="text" id="' . $this->field['id'] . '" name="' . $this->field['name'] . $this->field['name_suffix'] . '[]' . '" value="" class="regular-text ' . $this->field['class'] . '" /> ' . __( 'Remove', 'accelerated-mobile-pages' ) . '
';
            }

            echo '
<input type="text" id="' . $this->field['id'] . '" name="" value="" class="regular-text" /> ' . __( 'Remove', 'accelerated-mobile-pages' ) . '
';

            echo '
';
            echo '';
            $this->field['add_number'] = ( isset( $this->field['add_number'] ) && is_numeric( $this->field['add_number'] ) ) ? $this->field['add_number'] : 1;
            echo 'field['add_number'] . '" data-id="' . $this->field['id'] . '-ul" data-name="' . $this->field['name'] . $this->field['name_suffix'] . '[]">' . $this->add_text . '
';
        }

        /**
         * Enqueue Function.
         * If this field requires any scripts, or css define this function and register/enqueue the scripts/css
         *
         * @since       1.0.0
         * @access      public
         * @return      void
         */
        public function enqueue() {

            wp_enqueue_script(
                'redux-field-multi-text-js',
                ReduxFramework::$_url . 'inc/fields/multi_text/field_multi_text' . Redux_Functions::isMin() . '.js',
                array( 'jquery', 'redux-js' ),
                time(),
                true
            );

            if ($this->parent->args['dev_mode']) {
                wp_enqueue_style(
                    'redux-field-multi-text-css',
                    ReduxFramework::$_url . 'inc/fields/multi_text/field_multi_text.css',
                    array(),
                    time(),
                    'all'
                );
            }
        }
    }
}


text:
package base.socket.message.user

import base.socket.message.{ CommandObject, UserServerCommand }

object UserServerCommands extends CommandObject {

  val cmds = init(this, Login, BadApiVersion, Busy, BadInput)

  case object Login extends UserServerCommand[LoginUserServerMessage]("loginOK")
  case object BadApiVersion extends UserServerCommand[BadApiUserServerMessage]("loginOK")
  case object Busy extends UserServerCommand[BusyUserServerMessage]("serverBusy")
  case object BadInput extends UserServerCommand[BadInputUserServerMessage]("badInput")

}


text:
/*
 * Licensed to the Apache Software Foundation (ASF) under one or more
 * contributor license agreements.  The ASF licenses this file to You
 * 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 org.apache.jackrabbit.webdav.client.methods;

import org.apache.log4j.Logger;
import org.apache.jackrabbit.webdav.DavConstants;
import org.apache.jackrabbit.webdav.DavMethods;
import org.apache.jackrabbit.webdav.header.Header;
import org.apache.jackrabbit.webdav.header.CodedUrlHeader;

/**
 * UnLockMethod...
 */
public class UnLockMethod extends DavMethodBase {

    private static Logger log = Logger.getLogger(UnLockMethod.class);

    public UnLockMethod(String uri, String lockToken) {
        super(uri);
        Header lth = new CodedUrlHeader(DavConstants.HEADER_LOCK_TOKEN, lockToken);
        setRequestHeader(lth);
    }

    /**
     * @see org.apache.commons.httpclient.HttpMethod#getName()
     */
    public String getName() {
        return DavMethods.METHOD_UNLOCK;
    }
}


text:
package com.intellij.xdebugger.memory.utils;

import java.awt.event.KeyEvent;

public class KeyboardUtils {
  public static boolean isEnterKey(int keyCode) {
    return keyCode == KeyEvent.VK_ENTER;
  }

  public static boolean isUpDownKey(int keyCode) {
    return keyCode == KeyEvent.VK_UP || keyCode == KeyEvent.VK_DOWN;
  }

  public static boolean isBackSpace(int keyCode) {
    return keyCode == KeyEvent.VK_BACK_SPACE;
  }

  public static boolean isPartOfJavaClassName(char ch) {
    return Character.isLetterOrDigit(ch) || ch == '.' || ch == '$' || ch == '[' || ch == ']';
  }
}


text:
package org.swiften.javautilities.functional;

/**
 * Created by haipham on 7/12/17.
 */

import io.reactivex.functions.BiFunction;
import io.reactivex.functions.Function;
import org.jetbrains.annotations.NotNull;

/**
 * Option monad interface.
 * @param <Val> Generics parameter.
 */
public interface OptionType<Val> extends OptionConvertibleType<Val>, TryConvertibleType<Val>, MaybeType<Val> {
    /**
     * Check if there is some {@link Val} value available.
     * @return {@link Boolean} value.
     */
    boolean isPresent();

    /**
     * Check if there is nothing available.
     * @return {@link Boolean} value.
     */
    boolean isNothing();

    /**
     * Functor.
     * @param transform Transform {@link Function} from {@link Val} to {@link Val1}.
     * @param <Val1> Generics parameter.
     * @return {@link Option} instance.
     */
    @NotNull <Val1> Option<Val1> map(@NotNull Function<? super Val, ? extends Val1> transform);

    /**
     * Applicative.
     * @param transform {@link OptionConvertibleType} of transform {@link Function}.
     * @param <Val1> Generics parameter.
     * @return {@link Option}
     */
    @NotNull <Val1> Option<Val1> apply(@NotNull OptionConvertibleType<Function<? super Val, ? extends Val1>> transform);

    /**
     * Monad.
     * @param transform Transform {@link Function} from {@link Val} to {@link Option}.
     * @param <Val1> Generics parameter.
     * @return {@link Option} instance.
     */
    @NotNull <Val1> Option<Val1> flatMap(@NotNull Function<? super Val, ? extends OptionConvertibleType<Val1>> transform);

    /**
     * Zip with another {@link OptionConvertibleType} and a {@link BiFunction}
     * to create a {@link Option}.
     * @param option2 {@link OptionConvertibleType} instance.
     * @param transform Transform {@link BiFunction} from {@link Val} and
     * {@link Val2} to {@link Val3}.
     * @param <Val2> Generics parameter.
     * @param <Val3> Generics parameter.
     * @return {@link Option} instance.
     */
    @NotNull <Val2,Val3> Option<Val3> zipWith(
        @NotNull OptionConvertibleType<Val2> option2,
        @NotNull BiFunction<? super Val,? super Val2,? extends Val3> transform);
}


text:
var dao = require('../Data/DAO');

/*

*/
var CreatePlayer = function(playerInfo) {
    return dao.methods.playerMethods.main.createPlayer(playerInfo);
};

module.exports = {
    CreatePlayer: CreatePlayer
};


text:
package uk.org.opentrv.comms.http;

import java.text.DateFormat;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import java.util.Map;
import java.util.TimeZone;

import org.json.simple.JSONArray;
import org.json.simple.JSONAware;
import org.json.simple.JSONObject;

import uk.org.opentrv.comms.util.CommonSensorLabels;
import uk.org.opentrv.comms.util.ParsedRemoteBinaryStatsRecord;

/**
 * Lightweight object that represents a RKDAP payload.
 * @author Bruno Girin
 *
 */
public class RkdapPayload implements JSONAware {

	/*
	 * Constants used to construct the JSON payload
	 */
	public static final String METHOD_KEY = "method";
	public static final String METHOD_VALUE = "dad_data";
	public static final String VERSION_KEY = "ver";
	public static final String VERSION_VALUE = "1.1";
	public static final String DAD_ID_KEY = "dad_id";
	public static final String DATA_KEY = "data";
	public static final String DATA_ID_KEY = "id";
	public static final String DATA_PERIOD_KEY = "period";
	public static final String DATA_VALUE_KEY = "value";

	public static final DateFormat PERIOD_DATE_FORMAT = new SimpleDateFormat(
			"yyyy-MM-dd'T'HH:mm:ss");
    { PERIOD_DATE_FORMAT.setTimeZone(TimeZone.getTimeZone("UTC")); }

	private final String dadId;
	private final long timestamp;
	private final List<DataItem> dataItems;

    /**
     * Create a RKDAP payload given a parsed binary record.
     */
	public RkdapPayload(final String dadId, final ParsedRemoteBinaryStatsRecord record) {
		this.dadId = dadId;
		this.timestamp = record.constructionTime;
		this.dataItems = new ArrayList<DataItem>();
		for(final Map.Entry<Character, String> entry :
			record.sectionsByKey.entrySet()) {
			final String entryKey = entry.getKey().toString();
			// Ignore the @ entry as it's part of the key anyway
			if(!"@".equals(entryKey)) {
			    Number value = null;
			    if(CommonSensorLabels.TEMPERATURE.getLabel() == entry.getKey().charValue()) {
				    value = ParsedRemoteBinaryStatsRecord.parseTemperatureFromDDCH(entry.getValue());
			    } else {
				    try {
					    value = Integer.parseInt(entry.getValue());
				    } catch(final NumberFormatException nfe1) {
					    try {
						    value = Double.parseDouble(entry.getValue());
					    } catch(final NumberFormatException nfe2) {
						    continue;
					    }
				    }
			    }
			    dataItems.add(new DataItem(
					    record.ID,
					    entryKey,
					    this.timestamp,
					    value
			    ));
		    }
		}
	}

    /**
     * Create a RKDAP payload given a JSON record.
     */
	public RkdapPayload(final String dadId, final long constructionTime, final JSONObject record) {
		this.dadId = dadId;
		this.timestamp = constructionTime;
		this.dataItems = new ArrayList<DataItem>();
		final Object deviceIDObj = record.get("@");
		if(deviceIDObj != null) {
		    final String deviceID = deviceIDObj.toString().toUpperCase();
    		for(final Object entryKeyObj : record.keySet()) {
    		    final String entryKey = entryKeyObj.toString();
    		    if(!"@".equals(entryKey)) {
    		        final int pipePos = entryKey.indexOf('|');
    		        final String sensorID;
    		        final String sensorUnit;
    		        if(pipePos > 0) {
    		            sensorID = entryKey.substring(0, pipePos);
    		            sensorUnit = entryKey.substring(pipePos + 1);
		            } else {
        		        sensorID = entryKey;
        		        sensorUnit = "";
		            }
    		        final String entryValue = record.get(entryKey).toString();
    		        Number value = null;
    		        if("C16".equals(sensorUnit)) {
    		            try {
        		            value = Integer.parseInt(entryValue)/16.0;
    		            } catch(final NumberFormatException nfe) {
    		                continue;
		                }
    		        } else {
				        try {
					        value = Integer.parseInt(entryValue);
				        } catch(final NumberFormatException nfe1) {
					        try {
						        value = Double.parseDouble(entryValue);
					        } catch(final NumberFormatException nfe2) {
						        continue;
					        }
				        }
			        }
    		        dataItems.add(new DataItem(
    		            deviceID,
    		            sensorID,
    		            this.timestamp,
    		            value
		            ));
	            }
    		}
		}
	}

    @Override
    public String toJSONString() {
        return toJSONObject().toString();
    }

    public JSONObject toJSONObject() {
        final JSONObject payload = new JSONObject();
        payload.put(METHOD_KEY, METHOD_VALUE);
        payload.put(VERSION_KEY, VERSION_VALUE);
        payload.put(DAD_ID_KEY, this.dadId);
        final JSONArray dataArray = new JSONArray();
        for(final DataItem item: this.dataItems) {
            dataArray.add(item.toJSONObject());
        }
        payload.put(DATA_KEY, dataArray);
        return payload;
    }

	public static class DataItem {
		private final String deviceID;
		private final String sensorID;
		private final long timestamp;
		private final Number value;

		public DataItem(final String deviceID, final String sensorID, final long timestamp, final Number value) {
			this.deviceID = deviceID;
			this.sensorID = sensorID;
			this.timestamp = timestamp;
			this.value = value;
		}

		public JSONObject toJSONObject() {
		    final JSONObject item = new JSONObject();
		    item.put(DATA_ID_KEY, this.deviceID+"_"+this.sensorID);
		    item.put(DATA_PERIOD_KEY, PERIOD_DATE_FORMAT.format(new Date(this.timestamp)));
		    item.put(DATA_VALUE_KEY, this.value);
		    return item;
	    }
	}
}


text:
// Copyright 2016 Chase Willden and The CondorLang Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

/**
 * The end user will not interact with this library.
 * This file is used to tokenize the code string
 *
 * Use:
 * 	Syntax Analysis Only
 *
 * Usage:
 * 	char* code = "var a = 10;";
 * 	Lexer* lexer = InitLexer(code);
 * 	Token token = GetNextToken(lexer);
 */

#ifndef LEXER_H_
#define LEXER_H_

#include <string.h>
#include <ctype.h>
#include <stdbool.h>
#include "../mem/allocate.h"
#include "../token/token.h"

typedef struct LexerTracker{
	int tokenStart; // substr
	int tokenEnd; // substr
	int currentTokenPosition; // If -1, is EOF
	int row;
	int col;
} LexerTracker;

typedef struct Lexer{
	LexerTracker tracker;
	LexerTracker previousTrackers[5];
	int previousTrackerSpot;
	int totalTrackers;

	char* rawSourceCode;
	int length;
	char* currentTokenString;
} Lexer;

/**
 * Public Functions
 */
void InitLexer(Lexer* lexer, char* rawSourceCode);
void DestroyLexer(Lexer* lexer);
Token GetNextToken(Lexer* lexer);
char* GetCurrentTokenString(Lexer* lexer);
int CountTotalASTTokens(Lexer* lexer);
int CountTotalScopes(Lexer* lexer);
int CountTotalFuncs(Lexer* lexer);
int CountTotalFuncCalls(Lexer* lexer);
int CountTotalParamItems(Lexer* lexer);
void ResetLexer(Lexer* lexer);
void PeekNextToken(Lexer* lexer, PeekedToken* peeked);
Token GetCurrentToken(Lexer* lexer);
void BackOneToken(Lexer* lexer);

/**
 * Private Functions
 */
void SetNextTokenRange(Lexer* lexer);
char GetCurrentCharacter(Lexer* lexer);
char GetNextCharacter(Lexer* lexer);
char PeekNextCharacter(Lexer* lexer);
bool IsCharacter(char character, char charactersToCheck[]);
char* GetTokenString(Lexer* lexer);
bool CrawlIdentifierCharacters(Lexer* lexer);
bool CrawlSpaces(Lexer* lexer);
bool CrawlOperators(Lexer* lexer);
bool CrawlNumbers(Lexer* lexer);
bool CrawlString(Lexer* lexer);

void SetTokenStart(Lexer* lexer);
void SetTokenEnd(Lexer* lexer);

void SetPreviousTracker(Lexer* lexer);

#endif // LEXER_H_


text:
from msrest.serialization import Model

class ConnectionResetSharedKey(Model):
    """ConnectionResetSharedKey.

    :param key_length: The virtual network connection reset shared key length
    :type key_length: long
    """

    _attribute_map = {
        'key_length': {'key': 'keyLength', 'type': 'long'},
    }

    def __init__(self, *, key_length: int=None, **kwargs) -> None:
        super(ConnectionResetSharedKey, self).__init__(**kwargs)
        self.key_length = key_length


text:
mkdir -p "$PREFIX/bin"
if [ "$(uname)" == "Darwin" ]; then
    cp paraNodeStart "$PREFIX/bin"
else
    export MACHTYPE=x86_64
    export BINDIR=$(pwd)/bin
    mkdir -p "$BINDIR"
    (cd kent/src/lib && make)
    (cd kent/src/htslib && make)
    (cd kent/src/jkOwnLib && make)
    (cd kent/src/hg/lib && make)
    (cd kent/src/parasol && make)
    cp kent/src/parasol/bin/paraNodeStart "$PREFIX/bin"
fi
chmod +x "$PREFIX/bin/paraNodeStart"


text:
module Torkify::Event
  module Message
    def message
      "on_#{type}".to_sym
    end
  end
end


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

public class LeftWallScript : MonoBehaviour {
    public GameObject nms;
    private MenuManagerScript endGame;

	// Use this for initialization
	void Start () {
        endGame = nms.GetComponent<MenuManagerScript>();
	}

	// Update is called once per frame
	void Update () {

	}

    void OnTriggerEnter(Collider col)
    {
        if(col.gameObject.tag == "Note")
        {
            endGame.changeScene("game_over");
        }
    }
}


text:
namespace jd { class Tilemap; }
typedef sf::Vector3<unsigned> Vector3u;

class TilePositionComponent: public Component {
    JD_COMPONENT

    SSIG_DEFINE_MEMBERSIGNAL(tilePositionChanged,
        void(Vector3u oldPos, Vector3u newPos))
public:
    explicit TilePositionComponent(jd::Tilemap const& tilemap, unsigned layer = 0);
    TilePositionComponent(
        Entity& parent, jd::Tilemap const& tilemap, unsigned layer = 0);

    virtual void initComponent();
    virtual void cleanupComponent();

    Vector3u tilePosition() const { return m_tilePosition; }

private:
    void on_positionChanged(
        sf::FloatRect const& oldRect, sf::FloatRect const& newRect);

    ssig::ScopedConnection<void(sf::FloatRect const&, sf::FloatRect const&)>
        m_con_positionChanged;
    Vector3u m_tilePosition;
    jd::Tilemap const& m_tilemap;

};

#endif


text:
require 'pry'
require 'nokogiri'
require 'open-uri'
require 'colorize'
require 'mechanize'
require 'scraper'
require 'book'
require 'cli'
require 'genre'

module NYTBestsellers
end


text:
SYNONYM

#### According to
The Catalogue of Life, 3rd January 2011

#### Published in
Prodr. 3:233. 1829

#### Original name
null

### Remarks
null


text:
namespace ApkExtractor
{
    partial class SettingsForm
    {
        /// <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()
        {
            System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(SettingsForm));
            this.AdbLocationTextBox = new System.Windows.Forms.TextBox();
            this.SelectFileButton = new System.Windows.Forms.Button();
            this.ConfirmSelectionButton = new System.Windows.Forms.Button();
            this.SuspendLayout();
            //
            // AdbLocationTextBox
            //
            this.AdbLocationTextBox.Location = new System.Drawing.Point(12, 12);
            this.AdbLocationTextBox.Name = "AdbLocationTextBox";
            this.AdbLocationTextBox.Size = new System.Drawing.Size(369, 20);
            this.AdbLocationTextBox.TabIndex = 0;
            this.AdbLocationTextBox.Text = "No File Selected";
            //
            // SelectFileButton
            //
            this.SelectFileButton.Location = new System.Drawing.Point(387, 10);
            this.SelectFileButton.Name = "SelectFileButton";
            this.SelectFileButton.Size = new System.Drawing.Size(75, 23);
            this.SelectFileButton.TabIndex = 1;
            this.SelectFileButton.Text = "Browse...";
            this.SelectFileButton.UseVisualStyleBackColor = true;
            this.SelectFileButton.Click += new System.EventHandler(this.SelectFileButton_Click);
            //
            // ConfirmSelectionButton
            //
            this.ConfirmSelectionButton.Location = new System.Drawing.Point(468, 10);
            this.ConfirmSelectionButton.Name = "ConfirmSelectionButton";
            this.ConfirmSelectionButton.Size = new System.Drawing.Size(75, 23);
            this.ConfirmSelectionButton.TabIndex = 2;
            this.ConfirmSelectionButton.Text = "Confirm";
            this.ConfirmSelectionButton.UseVisualStyleBackColor = true;
            this.ConfirmSelectionButton.Click += new System.EventHandler(this.ConfirmSelectionButton_Click);
            //
            // SettingsForm
            //
            this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
            this.ClientSize = new System.Drawing.Size(550, 45);
            this.Controls.Add(this.ConfirmSelectionButton);
            this.Controls.Add(this.SelectFileButton);
            this.Controls.Add(this.AdbLocationTextBox);
            this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
            this.MaximizeBox = false;
            this.MinimizeBox = false;
            this.Name = "SettingsForm";
            this.Text = "Settings";
            this.ResumeLayout(false);
            this.PerformLayout();

        }

        #endregion

        private System.Windows.Forms.TextBox AdbLocationTextBox;
        private System.Windows.Forms.Button SelectFileButton;
        private System.Windows.Forms.Button ConfirmSelectionButton;
    }
}


text:
import sys
from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, TypeVar, Union, overload
import urllib.parse

from azure.core.async_paging import AsyncItemPaged, AsyncList
from azure.core.exceptions import (
    ClientAuthenticationError,
    HttpResponseError,
    ResourceExistsError,
    ResourceNotFoundError,
    ResourceNotModifiedError,
    map_error,
)
from azure.core.pipeline import PipelineResponse
from azure.core.pipeline.transport import AsyncHttpResponse
from azure.core.rest import HttpRequest
from azure.core.tracing.decorator import distributed_trace
from azure.core.tracing.decorator_async import distributed_trace_async
from azure.core.utils import case_insensitive_dict
from azure.mgmt.core.exceptions import ARMErrorFormat

from ... import models as _models
from ..._vendor import _convert_request
from ...operations._product_operations import (
    build_create_or_update_request,
    build_delete_request,
    build_get_entity_tag_request,
    build_get_request,
    build_list_by_service_request,
    build_list_by_tags_request,
    build_update_request,
)
from .._vendor import ApiManagementClientMixinABC

if sys.version_info >= (3, 8):
    from typing import Literal  # pylint: disable=no-name-in-module, ungrouped-imports
else:
    from typing_extensions import Literal  # type: ignore  # pylint: disable=ungrouped-imports
T = TypeVar("T")
ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]]

class ProductOperations:
    """
    .. warning::
        **DO NOT** instantiate this class directly.

        Instead, you should access the following operations through
        :class:`~azure.mgmt.apimanagement.aio.ApiManagementClient`'s
        :attr:`product` attribute.
    """

    models = _models

    def __init__(self, *args, **kwargs) -> None:
        input_args = list(args)
        self._client = input_args.pop(0) if input_args else kwargs.pop("client")
        self._config = input_args.pop(0) if input_args else kwargs.pop("config")
        self._serialize = input_args.pop(0) if input_args else kwargs.pop("serializer")
        self._deserialize = input_args.pop(0) if input_args else kwargs.pop("deserializer")

    @distributed_trace
    def list_by_service(
        self,
        resource_group_name: str,
        service_name: str,
        filter: Optional[str] = None,
        top: Optional[int] = None,
        skip: Optional[int] = None,
        expand_groups: Optional[bool] = None,
        tags: Optional[str] = None,
        **kwargs: Any
    ) -> AsyncIterable["_models.ProductContract"]:
        """Lists a collection of products in the specified service instance.

        :param resource_group_name: The name of the resource group. Required.
        :type resource_group_name: str
        :param service_name: The name of the API Management service. Required.
        :type service_name: str
        :param filter: |     Field     |     Usage     |     Supported operators     |     Supported
         functions     |
|-------------|-------------|-------------|-------------|
| name |
         filter | ge, le, eq, ne, gt, lt | substringof, contains, startswith, endswith |
|
         displayName | filter | ge, le, eq, ne, gt, lt | substringof, contains, startswith, endswith
         |
| description | filter | ge, le, eq, ne, gt, lt | substringof, contains, startswith,
         endswith |
| terms | filter | ge, le, eq, ne, gt, lt | substringof, contains, startswith,
         endswith |
| state | filter | eq |     |
| groups | expand |     |     |
. Default
         value is None.
        :type filter: str
        :param top: Number of records to return. Default value is None.
        :type top: int
        :param skip: Number of records to skip. Default value is None.
        :type skip: int
        :param expand_groups: When set to true, the response contains an array of groups that have
         visibility to the product. The default is false. Default value is None.
        :type expand_groups: bool
        :param tags: Products which are part of a specific tag. Default value is None.
        :type tags: str
        :keyword callable cls: A custom type or function that will be passed the direct response
        :return: An iterator like instance of either ProductContract or the result of cls(response)
        :rtype:
         ~azure.core.async_paging.AsyncItemPaged[~azure.mgmt.apimanagement.models.ProductContract]
        :raises ~azure.core.exceptions.HttpResponseError:
        """
        _headers = kwargs.pop("headers", {}) or {}
        _params = case_insensitive_dict(kwargs.pop("params", {}) or {})

        api_version = kwargs.pop(
            "api_version", _params.pop("api-version", self._config.api_version)
        )  # type: Literal["2021-08-01"]
        cls = kwargs.pop("cls", None)  # type: ClsType[_models.ProductCollection]

        error_map = {
            401: ClientAuthenticationError,
            404: ResourceNotFoundError,
            409: ResourceExistsError,
            304: ResourceNotModifiedError,
        }
        error_map.update(kwargs.pop("error_map", {}) or {})

        def prepare_request(next_link=None):
            if not next_link:

                request = build_list_by_service_request(
                    resource_group_name=resource_group_name,
                    service_name=service_name,
                    subscription_id=self._config.subscription_id,
                    filter=filter,
                    top=top,
                    skip=skip,
                    expand_groups=expand_groups,
                    tags=tags,
                    api_version=api_version,
                    template_url=self.list_by_service.metadata["url"],
                    headers=_headers,
                    params=_params,
                )
                request = _convert_request(request)
                request.url = self._client.format_url(request.url)  # type: ignore

            else:
                # make call to next link with the client's api-version
                _parsed_next_link = urllib.parse.urlparse(next_link)
                _next_request_params = case_insensitive_dict(
                    {
                        key: [urllib.parse.quote(v) for v in value]
                        for key, value in urllib.parse.parse_qs(_parsed_next_link.query).items()
                    }
                )
                _next_request_params["api-version"] = self._config.api_version
                request = HttpRequest(
                    "GET", urllib.parse.urljoin(next_link, _parsed_next_link.path), params=_next_request_params
                )
                request = _convert_request(request)
                request.url = self._client.format_url(request.url)  # type: ignore
                request.method = "GET"
            return request

        async def extract_data(pipeline_response):
            deserialized = self._deserialize("ProductCollection", pipeline_response)
            list_of_elem = deserialized.value
            if cls:
                list_of_elem = cls(list_of_elem)
            return deserialized.next_link or None, AsyncList(list_of_elem)

        async def get_next(next_link=None):
            request = prepare_request(next_link)

            pipeline_response = await self._client._pipeline.run(  # type: ignore # pylint: disable=protected-access
                request, stream=False, **kwargs
            )
            response = pipeline_response.http_response

            if response.status_code not in [200]:
                map_error(status_code=response.status_code, response=response, error_map=error_map)
                error = self._deserialize.failsafe_deserialize(_models.ErrorResponse, pipeline_response)
                raise HttpResponseError(response=response, model=error, error_format=ARMErrorFormat)

            return pipeline_response

        return AsyncItemPaged(get_next, extract_data)

    list_by_service.metadata = {"url": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/products"}  # type: ignore

    @distributed_trace_async
    async def get_entity_tag(self, resource_group_name: str, service_name: str, product_id: str, **kwargs: Any) -> bool:
        """Gets the entity state (Etag) version of the product specified by its identifier.

        :param resource_group_name: The name of the resource group. Required.
        :type resource_group_name: str
        :param service_name: The name of the API Management service. Required.
        :type service_name: str
        :param product_id: Product identifier. Must be unique in the current API Management service
         instance. Required.
        :type product_id: str
        :keyword callable cls: A custom type or function that will be passed the direct response
        :return: bool or the result of cls(response)
        :rtype: bool
        :raises ~azure.core.exceptions.HttpResponseError:
        """
        error_map = {
            401: ClientAuthenticationError,
            404: ResourceNotFoundError,
            409: ResourceExistsError,
            304: ResourceNotModifiedError,
        }
        error_map.update(kwargs.pop("error_map", {}) or {})

        _headers = kwargs.pop("headers", {}) or {}
        _params = case_insensitive_dict(kwargs.pop("params", {}) or {})

        api_version = kwargs.pop(
            "api_version", _params.pop("api-version", self._config.api_version)
        )  # type: Literal["2021-08-01"]
        cls = kwargs.pop("cls", None)  # type: ClsType[None]

        request = build_get_entity_tag_request(
            resource_group_name=resource_group_name,
            service_name=service_name,
            product_id=product_id,
            subscription_id=self._config.subscription_id,
            api_version=api_version,
            template_url=self.get_entity_tag.metadata["url"],
            headers=_headers,
            params=_params,
        )
        request = _convert_request(request)
        request.url = self._client.format_url(request.url)  # type: ignore

        pipeline_response = await self._client._pipeline.run(  # type: ignore # pylint: disable=protected-access
            request, stream=False, **kwargs
        )

        response = pipeline_response.http_response

        if response.status_code not in [200]:
            map_error(status_code=response.status_code, response=response, error_map=error_map)
            error = self._deserialize.failsafe_deserialize(_models.ErrorResponse, pipeline_response)
            raise HttpResponseError(response=response, model=error, error_format=ARMErrorFormat)

        response_headers = {}
        response_headers["ETag"] = self._deserialize("str", response.headers.get("ETag"))

        if cls:
            return cls(pipeline_response, None, response_headers)
        return 200 <= response.status_code <= 299

    get_entity_tag.metadata = {"url": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/products/{productId}"}  # type: ignore

    @distributed_trace_async
    async def get(
        self, resource_group_name: str, service_name: str, product_id: str, **kwargs: Any
    ) -> _models.ProductContract:
        """Gets the details of the product specified by its identifier.

        :param resource_group_name: The name of the resource group. Required.
        :type resource_group_name: str
        :param service_name: The name of the API Management service. Required.
        :type service_name: str
        :param product_id: Product identifier. Must be unique in the current API Management service
         instance. Required.
        :type product_id: str
        :keyword callable cls: A custom type or function that will be passed the direct response
        :return: ProductContract or the result of cls(response)
        :rtype: ~azure.mgmt.apimanagement.models.ProductContract
        :raises ~azure.core.exceptions.HttpResponseError:
        """
        error_map = {
            401: ClientAuthenticationError,
            404: ResourceNotFoundError,
            409: ResourceExistsError,
            304: ResourceNotModifiedError,
        }
        error_map.update(kwargs.pop("error_map", {}) or {})

        _headers = kwargs.pop("headers", {}) or {}
        _params = case_insensitive_dict(kwargs.pop("params", {}) or {})

        api_version = kwargs.pop(
            "api_version", _params.pop("api-version", self._config.api_version)
        )  # type: Literal["2021-08-01"]
        cls = kwargs.pop("cls", None)  # type: ClsType[_models.ProductContract]

        request = build_get_request(
            resource_group_name=resource_group_name,
            service_name=service_name,
            product_id=product_id,
            subscription_id=self._config.subscription_id,
            api_version=api_version,
            template_url=self.get.metadata["url"],
            headers=_headers,
            params=_params,
        )
        request = _convert_request(request)
        request.url = self._client.format_url(request.url)  # type: ignore

        pipeline_response = await self._client._pipeline.run(  # type: ignore # pylint: disable=protected-access
            request, stream=False, **kwargs
        )

        response = pipeline_response.http_response

        if response.status_code not in [200]:
            map_error(status_code=response.status_code, response=response, error_map=error_map)
            error = self._deserialize.failsafe_deserialize(_models.ErrorResponse, pipeline_response)
            raise HttpResponseError(response=response, model=error, error_format=ARMErrorFormat)

        response_headers = {}
        response_headers["ETag"] = self._deserialize("str", response.headers.get("ETag"))

        deserialized = self._deserialize("ProductContract", pipeline_response)

        if cls:
            return cls(pipeline_response, deserialized, response_headers)

        return deserialized

    get.metadata = {"url": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/products/{productId}"}  # type: ignore

    @overload
    async def create_or_update(
        self,
        resource_group_name: str,
        service_name: str,
        product_id: str,
        parameters: _models.ProductContract,
        if_match: Optional[str] = None,
        *,
        content_type: str = "application/json",
        **kwargs: Any
    ) -> _models.ProductContract:
        """Creates or Updates a product.

        :param resource_group_name: The name of the resource group. Required.
        :type resource_group_name: str
        :param service_name: The name of the API Management service. Required.
        :type service_name: str
        :param product_id: Product identifier. Must be unique in the current API Management service
         instance. Required.
        :type product_id: str
        :param parameters: Create or update parameters. Required.
        :type parameters: ~azure.mgmt.apimanagement.models.ProductContract
        :param if_match: ETag of the Entity. Not required when creating an entity, but required when
         updating an entity. Default value is None.
        :type if_match: str
        :keyword content_type: Body Parameter content-type. Content type parameter for JSON body.
         Default value is "application/json".
        :paramtype content_type: str
        :keyword callable cls: A custom type or function that will be passed the direct response
        :return: ProductContract or the result of cls(response)
        :rtype: ~azure.mgmt.apimanagement.models.ProductContract
        :raises ~azure.core.exceptions.HttpResponseError:
        """

    @overload
    async def create_or_update(
        self,
        resource_group_name: str,
        service_name: str,
        product_id: str,
        parameters: IO,
        if_match: Optional[str] = None,
        *,
        content_type: str = "application/json",
        **kwargs: Any
    ) -> _models.ProductContract:
        """Creates or Updates a product.

        :param resource_group_name: The name of the resource group. Required.
        :type resource_group_name: str
        :param service_name: The name of the API Management service. Required.
        :type service_name: str
        :param product_id: Product identifier. Must be unique in the current API Management service
         instance. Required.
        :type product_id: str
        :param parameters: Create or update parameters. Required.
        :type parameters: IO
        :param if_match: ETag of the Entity. Not required when creating an entity, but required when
         updating an entity. Default value is None.
        :type if_match: str
        :keyword content_type: Body Parameter content-type. Content type parameter for binary body.
         Default value is "application/json".
        :paramtype content_type: str
        :keyword callable cls: A custom type or function that will be passed the direct response
        :return: ProductContract or the result of cls(response)
        :rtype: ~azure.mgmt.apimanagement.models.ProductContract
        :raises ~azure.core.exceptions.HttpResponseError:
        """

    @distributed_trace_async
    async def create_or_update(
        self,
        resource_group_name: str,
        service_name: str,
        product_id: str,
        parameters: Union[_models.ProductContract, IO],
        if_match: Optional[str] = None,
        **kwargs: Any
    ) -> _models.ProductContract:
        """Creates or Updates a product.

        :param resource_group_name: The name of the resource group. Required.
        :type resource_group_name: str
        :param service_name: The name of the API Management service. Required.
        :type service_name: str
        :param product_id: Product identifier. Must be unique in the current API Management service
         instance. Required.
        :type product_id: str
        :param parameters: Create or update parameters. Is either a model type or a IO type. Required.
        :type parameters: ~azure.mgmt.apimanagement.models.ProductContract or IO
        :param if_match: ETag of the Entity. Not required when creating an entity, but required when
         updating an entity. Default value is None.
        :type if_match: str
        :keyword content_type: Body Parameter content-type. Known values are: 'application/json'.
         Default value is None.
        :paramtype content_type: str
        :keyword callable cls: A custom type or function that will be passed the direct response
        :return: ProductContract or the result of cls(response)
        :rtype: ~azure.mgmt.apimanagement.models.ProductContract
        :raises ~azure.core.exceptions.HttpResponseError:
        """
        error_map = {
            401: ClientAuthenticationError,
            404: ResourceNotFoundError,
            409: ResourceExistsError,
            304: ResourceNotModifiedError,
        }
        error_map.update(kwargs.pop("error_map", {}) or {})

        _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {})
        _params = case_insensitive_dict(kwargs.pop("params", {}) or {})

        api_version = kwargs.pop(
            "api_version", _params.pop("api-version", self._config.api_version)
        )  # type: Literal["2021-08-01"]
        content_type = kwargs.pop("content_type", _headers.pop("Content-Type", None))  # type: Optional[str]
        cls = kwargs.pop("cls", None)  # type: ClsType[_models.ProductContract]

        content_type = content_type or "application/json"
        _json = None
        _content = None
        if isinstance(parameters, (IO, bytes)):
            _content = parameters
        else:
            _json = self._serialize.body(parameters, "ProductContract", is_xml=True)

        request = build_create_or_update_request(
            resource_group_name=resource_group_name,
            service_name=service_name,
            product_id=product_id,
            subscription_id=self._config.subscription_id,
            if_match=if_match,
            api_version=api_version,
            content_type=content_type,
            json=_json,
            content=_content,
            template_url=self.create_or_update.metadata["url"],
            headers=_headers,
            params=_params,
        )
        request = _convert_request(request)
        request.url = self._client.format_url(request.url)  # type: ignore

        pipeline_response = await self._client._pipeline.run(  # type: ignore # pylint: disable=protected-access
            request, stream=False, **kwargs
        )

        response = pipeline_response.http_response

        if response.status_code not in [200, 201]:
            map_error(status_code=response.status_code, response=response, error_map=error_map)
            error = self._deserialize.failsafe_deserialize(_models.ErrorResponse, pipeline_response)
            raise HttpResponseError(response=response, model=error, error_format=ARMErrorFormat)

        response_headers = {}
        if response.status_code == 200:
            response_headers["ETag"] = self._deserialize("str", response.headers.get("ETag"))

            deserialized = self._deserialize("ProductContract", pipeline_response)

        if response.status_code == 201:
            response_headers["ETag"] = self._deserialize("str", response.headers.get("ETag"))

            deserialized = self._deserialize("ProductContract", pipeline_response)

        if cls:
            return cls(pipeline_response, deserialized, response_headers)

        return deserialized

    create_or_update.metadata = {"url": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/products/{productId}"}  # type: ignore

    @overload
    async def update(
        self,
        resource_group_name: str,
        service_name: str,
        product_id: str,
        if_match: str,
        parameters: _models.ProductUpdateParameters,
        *,
        content_type: str = "application/json",
        **kwargs: Any
    ) -> _models.ProductContract:
        """Update existing product details.

        :param resource_group_name: The name of the resource group. Required.
        :type resource_group_name: str
        :param service_name: The name of the API Management service. Required.
        :type service_name: str
        :param product_id: Product identifier. Must be unique in the current API Management service
         instance. Required.
        :type product_id: str
        :param if_match: ETag of the Entity. ETag should match the current entity state from the header
         response of the GET request or it should be * for unconditional update. Required.
        :type if_match: str
        :param parameters: Update parameters. Required.
        :type parameters: ~azure.mgmt.apimanagement.models.ProductUpdateParameters
        :keyword content_type: Body Parameter content-type. Content type parameter for JSON body.
         Default value is "application/json".
        :paramtype content_type: str
        :keyword callable cls: A custom type or function that will be passed the direct response
        :return: ProductContract or the result of cls(response)
        :rtype: ~azure.mgmt.apimanagement.models.ProductContract
        :raises ~azure.core.exceptions.HttpResponseError:
        """

    @overload
    async def update(
        self,
        resource_group_name: str,
        service_name: str,
        product_id: str,
        if_match: str,
        parameters: IO,
        *,
        content_type: str = "application/json",
        **kwargs: Any
    ) -> _models.ProductContract:
        """Update existing product details.

        :param resource_group_name: The name of the resource group. Required.
        :type resource_group_name: str
        :param service_name: The name of the API Management service. Required.
        :type service_name: str
        :param product_id: Product identifier. Must be unique in the current API Management service
         instance. Required.
        :type product_id: str
        :param if_match: ETag of the Entity. ETag should match the current entity state from the header
         response of the GET request or it should be * for unconditional update. Required.
        :type if_match: str
        :param parameters: Update parameters. Required.
        :type parameters: IO
        :keyword content_type: Body Parameter content-type. Content type parameter for binary body.
         Default value is "application/json".
        :paramtype content_type: str
        :keyword callable cls: A custom type or function that will be passed the direct response
        :return: ProductContract or the result of cls(response)
        :rtype: ~azure.mgmt.apimanagement.models.ProductContract
        :raises ~azure.core.exceptions.HttpResponseError:
        """

    @distributed_trace_async
    async def update(
        self,
        resource_group_name: str,
        service_name: str,
        product_id: str,
        if_match: str,
        parameters: Union[_models.ProductUpdateParameters, IO],
        **kwargs: Any
    ) -> _models.ProductContract:
        """Update existing product details.

        :param resource_group_name: The name of the resource group. Required.
        :type resource_group_name: str
        :param service_name: The name of the API Management service. Required.
        :type service_name: str
        :param product_id: Product identifier. Must be unique in the current API Management service
         instance. Required.
        :type product_id: str
        :param if_match: ETag of the Entity. ETag should match the current entity state from the header
         response of the GET request or it should be * for unconditional update. Required.
        :type if_match: str
        :param parameters: Update parameters. Is either a model type or a IO type. Required.
        :type parameters: ~azure.mgmt.apimanagement.models.ProductUpdateParameters or IO
        :keyword content_type: Body Parameter content-type. Known values are: 'application/json'.
         Default value is None.
        :paramtype content_type: str
        :keyword callable cls: A custom type or function that will be passed the direct response
        :return: ProductContract or the result of cls(response)
        :rtype: ~azure.mgmt.apimanagement.models.ProductContract
        :raises ~azure.core.exceptions.HttpResponseError:
        """
        error_map = {
            401: ClientAuthenticationError,
            404: ResourceNotFoundError,
            409: ResourceExistsError,
            304: ResourceNotModifiedError,
        }
        error_map.update(kwargs.pop("error_map", {}) or {})

        _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {})
        _params = case_insensitive_dict(kwargs.pop("params", {}) or {})

        api_version = kwargs.pop(
            "api_version", _params.pop("api-version", self._config.api_version)
        )  # type: Literal["2021-08-01"]
        content_type = kwargs.pop("content_type", _headers.pop("Content-Type", None))  # type: Optional[str]
        cls = kwargs.pop("cls", None)  # type: ClsType[_models.ProductContract]

        content_type = content_type or "application/json"
        _json = None
        _content = None
        if isinstance(parameters, (IO, bytes)):
            _content = parameters
        else:
            _json = self._serialize.body(parameters, "ProductUpdateParameters")

        request = build_update_request(
            resource_group_name=resource_group_name,
            service_name=service_name,
            product_id=product_id,
            subscription_id=self._config.subscription_id,
            if_match=if_match,
            api_version=api_version,
            content_type=content_type,
            json=_json,
            content=_content,
            template_url=self.update.metadata["url"],
            headers=_headers,
            params=_params,
        )
        request = _convert_request(request)
        request.url = self._client.format_url(request.url)  # type: ignore

        pipeline_response = await self._client._pipeline.run(  # type: ignore # pylint: disable=protected-access
            request, stream=False, **kwargs
        )

        response = pipeline_response.http_response

        if response.status_code not in [200]:
            map_error(status_code=response.status_code, response=response, error_map=error_map)
            error = self._deserialize.failsafe_deserialize(_models.ErrorResponse, pipeline_response)
            raise HttpResponseError(response=response, model=error, error_format=ARMErrorFormat)

        response_headers = {}
        response_headers["ETag"] = self._deserialize("str", response.headers.get("ETag"))

        deserialized = self._deserialize("ProductContract", pipeline_response)

        if cls:
            return cls(pipeline_response, deserialized, response_headers)

        return deserialized

    update.metadata = {"url": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/products/{productId}"}  # type: ignore

    @distributed_trace_async
    async def delete(  # pylint: disable=inconsistent-return-statements
        self,
        resource_group_name: str,
        service_name: str,
        product_id: str,
        if_match: str,
        delete_subscriptions: Optional[bool] = None,
        **kwargs: Any
    ) -> None:
        """Delete product.

        :param resource_group_name: The name of the resource group. Required.
        :type resource_group_name: str
        :param service_name: The name of the API Management service. Required.
        :type service_name: str
        :param product_id: Product identifier. Must be unique in the current API Management service
         instance. Required.
        :type product_id: str
        :param if_match: ETag of the Entity. ETag should match the current entity state from the header
         response of the GET request or it should be * for unconditional update. Required.
        :type if_match: str
        :param delete_subscriptions: Delete existing subscriptions associated with the product or not.
         Default value is None.
        :type delete_subscriptions: bool
        :keyword callable cls: A custom type or function that will be passed the direct response
        :return: None or the result of cls(response)
        :rtype: None
        :raises ~azure.core.exceptions.HttpResponseError:
        """
        error_map = {
            401: ClientAuthenticationError,
            404: ResourceNotFoundError,
            409: ResourceExistsError,
            304: ResourceNotModifiedError,
        }
        error_map.update(kwargs.pop("error_map", {}) or {})

        _headers = kwargs.pop("headers", {}) or {}
        _params = case_insensitive_dict(kwargs.pop("params", {}) or {})

        api_version = kwargs.pop(
            "api_version", _params.pop("api-version", self._config.api_version)
        )  # type: Literal["2021-08-01"]
        cls = kwargs.pop("cls", None)  # type: ClsType[None]

        request = build_delete_request(
            resource_group_name=resource_group_name,
            service_name=service_name,
            product_id=product_id,
            subscription_id=self._config.subscription_id,
            if_match=if_match,
            delete_subscriptions=delete_subscriptions,
            api_version=api_version,
            template_url=self.delete.metadata["url"],
            headers=_headers,
            params=_params,
        )
        request = _convert_request(request)
        request.url = self._client.format_url(request.url)  # type: ignore

        pipeline_response = await self._client._pipeline.run(  # type: ignore # pylint: disable=protected-access
            request, stream=False, **kwargs
        )

        response = pipeline_response.http_response

        if response.status_code not in [200, 204]:
            map_error(status_code=response.status_code, response=response, error_map=error_map)
            error = self._deserialize.failsafe_deserialize(_models.ErrorResponse, pipeline_response)
            raise HttpResponseError(response=response, model=error, error_format=ARMErrorFormat)

        if cls:
            return cls(pipeline_response, None, {})

    delete.metadata = {"url": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/products/{productId}"}  # type: ignore

    @distributed_trace
    def list_by_tags(
        self,
        resource_group_name: str,
        service_name: str,
        filter: Optional[str] = None,
        top: Optional[int] = None,
        skip: Optional[int] = None,
        include_not_tagged_products: Optional[bool] = None,
        **kwargs: Any
    ) -> AsyncIterable["_models.TagResourceContract"]:
        """Lists a collection of products associated with tags.

        :param resource_group_name: The name of the resource group. Required.
        :type resource_group_name: str
        :param service_name: The name of the API Management service. Required.
        :type service_name: str
        :param filter: |     Field     |     Usage     |     Supported operators     |     Supported
         functions     |
|-------------|-------------|-------------|-------------|
| name |
         filter | ge, le, eq, ne, gt, lt | substringof, contains, startswith, endswith |
|
         displayName | filter | ge, le, eq, ne, gt, lt | substringof, contains, startswith, endswith
         |
| description | filter | ge, le, eq, ne, gt, lt | substringof, contains, startswith,
         endswith |
| terms | filter | ge, le, eq, ne, gt, lt | substringof, contains, startswith,
         endswith |
| state | filter | eq | substringof, contains, startswith, endswith |
.
         Default value is None.
        :type filter: str
        :param top: Number of records to return. Default value is None.
        :type top: int
        :param skip: Number of records to skip. Default value is None.
        :type skip: int
        :param include_not_tagged_products: Include not tagged Products. Default value is None.
        :type include_not_tagged_products: bool
        :keyword callable cls: A custom type or function that will be passed the direct response
        :return: An iterator like instance of either TagResourceContract or the result of cls(response)
        :rtype:
         ~azure.core.async_paging.AsyncItemPaged[~azure.mgmt.apimanagement.models.TagResourceContract]
        :raises ~azure.core.exceptions.HttpResponseError:
        """
        _headers = kwargs.pop("headers", {}) or {}
        _params = case_insensitive_dict(kwargs.pop("params", {}) or {})

        api_version = kwargs.pop(
            "api_version", _params.pop("api-version", self._config.api_version)
        )  # type: Literal["2021-08-01"]
        cls = kwargs.pop("cls", None)  # type: ClsType[_models.TagResourceCollection]

        error_map = {
            401: ClientAuthenticationError,
            404: ResourceNotFoundError,
            409: ResourceExistsError,
            304: ResourceNotModifiedError,
        }
        error_map.update(kwargs.pop("error_map", {}) or {})

        def prepare_request(next_link=None):
            if not next_link:

                request = build_list_by_tags_request(
                    resource_group_name=resource_group_name,
                    service_name=service_name,
                    subscription_id=self._config.subscription_id,
                    filter=filter,
                    top=top,
                    skip=skip,
                    include_not_tagged_products=include_not_tagged_products,
                    api_version=api_version,
                    template_url=self.list_by_tags.metadata["url"],
                    headers=_headers,
                    params=_params,
                )
                request = _convert_request(request)
                request.url = self._client.format_url(request.url)  # type: ignore

            else:
                # make call to next link with the client's api-version
                _parsed_next_link = urllib.parse.urlparse(next_link)
                _next_request_params = case_insensitive_dict(
                    {
                        key: [urllib.parse.quote(v) for v in value]
                        for key, value in urllib.parse.parse_qs(_parsed_next_link.query).items()
                    }
                )
                _next_request_params["api-version"] = self._config.api_version
                request = HttpRequest(
                    "GET", urllib.parse.urljoin(next_link, _parsed_next_link.path), params=_next_request_params
                )
                request = _convert_request(request)
                request.url = self._client.format_url(request.url)  # type: ignore
                request.method = "GET"
            return request

        async def extract_data(pipeline_response):
            deserialized = self._deserialize("TagResourceCollection", pipeline_response)
            list_of_elem = deserialized.value
            if cls:
                list_of_elem = cls(list_of_elem)
            return deserialized.next_link or None, AsyncList(list_of_elem)

        async def get_next(next_link=None):
            request = prepare_request(next_link)

            pipeline_response = await self._client._pipeline.run(  # type: ignore # pylint: disable=protected-access
                request, stream=False, **kwargs
            )
            response = pipeline_response.http_response

            if response.status_code not in [200]:
                map_error(status_code=response.status_code, response=response, error_map=error_map)
                error = self._deserialize.failsafe_deserialize(_models.ErrorResponse, pipeline_response)
                raise HttpResponseError(response=response, model=error, error_format=ARMErrorFormat)

            return pipeline_response

        return AsyncItemPaged(get_next, extract_data)

    list_by_tags.metadata = {"url": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/productsByTags"}  # type: ignore


text:
#ifndef ALT1250_PPP_H_
#define ALT1250_PPP_H_

#ifdef TARGET_FF_ARDUINO
#ifndef MBED_CONF_ALT1250_PPP_TX
#define MBED_CONF_ALT1250_PPP_TX D1
#endif
#ifndef MBED_CONF_ALT1250_PPP_RX
#define MBED_CONF_ALT1250_PPP_RX D0
#endif
#endif /* TARGET_FF_ARDUINO */

#include "AT_CellularDevice.h"
#include "DigitalInOut.h"

namespace mbed {

class ALT1250_PPP : public AT_CellularDevice {
public:
    ALT1250_PPP(FileHandle *fh, PinName rst = NC, PinDirection pin_dir = PIN_OUTPUT, PinMode pin_mode = PullUp, bool value = 1);

protected: // AT_CellularDevice
    virtual AT_CellularContext *create_context_impl(ATHandler &at, const char *apn, bool cp_req = false, bool nonip_req = false);

    AT_CellularNetwork *open_network_impl(ATHandler &at);
    virtual nsapi_error_t soft_power_on();
    DigitalInOut _rst;
};

} // namespace mbed
#endif // ALT1250_PPP_H_


text:
'use strict';

import React, {Component} from "react";
import {
    Text,
    AppState
} from "react-native";
import FormatTime from "minutes-seconds-milliseconds";

class TimerView extends Component {
    constructor(props) {
        super(props);

        this.state = {
            timeElapsed: 0,
            isPaused: false,
            tickInterval: props.interval || 100
        }
    }

    componentDidMount() {
        AppState.addEventListener('change', this._handleAppStateChange.bind(this));

        this.startTime = new Date();
        this.lastSavedTime = 0;

        this.interval = setInterval(() => {
                if(AppState.currentState === 'active' && !this.state.isPaused) {
            this.setState({
                timeElapsed: new Date() - this.startTime + this.lastSavedTime
            });
        }
    }, this.state.tickInterval);
    }

    componentWillUnmount() {
        AppState.removeEventListener('change', this._handleAppStateChange.bind(this));
        clearInterval(this.interval);

        this.startTime = 0;
        this.lastSavedTime = 0;

        this.setState({
            timeElapsed: 0,
        });
    }

    _handleAppStateChange(currentAppState) {
        if(currentAppState === 'active') {
            this.setPauseState(false);
        } else {
            this.setPauseState(true);
        }
    }

    componentWillReceiveProps(nextProps) {
        if(typeof nextProps.isPaused === 'boolean') {
            this.setPauseState(nextProps.isPaused);
        }
    }

    setNativeProps(nativeProps) {
        if(typeof nativeProps.isPaused === 'boolean') {
            this.setPauseState(nativeProps.isPaused);
        }
    }

    setPauseState(pauseState) {
        this.setState({
            isPaused: pauseState,
        });

        if(pauseState) {
            this.lastSavedTime = this.state.timeElapsed;
        } else {
            this.startTime = new Date();
        }
    }

    render() {
        return (
            <Text {...this.props}>
        {FormatTime(this.state.timeElapsed)}
    </Text>
    );
    }
}

module.exports = TimerView;


text:
<?xml version='1.0' encoding='utf-8'?>
<TEI xmlns="http://www.tei-c.org/ns/1.0" xml:id="PrL-0614">
   <teiHeader>
      <fileDesc>
         <titleStmt>
            <title>Private Letter: 1885 November 12: to Wilkinson</title>
            <author>
               <name type="person" key="http://wtap.vuw.ac.nz/eats/entity/9614/">William Colenso</name>
            </author>
         </titleStmt>
         <publicationStmt>

         </publicationStmt>
         <sourceDesc>

Hocken MS-1014/005.

         </sourceDesc>
      </fileDesc>
      <profileDesc>
         <correspDesc>

               <correspAction type="received">
                  <name type="person" key="http://wtap.vuw.ac.nz/eats/entity/74479/">Wilkinson</name>
               </correspAction>
            </correspDesc>
         <creation xmlns:tei="http://www.tei-c.org/ns/1.0">
            <date when="1885-11-12">1885 November 12</date>
         </creation>
      </profileDesc>
   </teiHeader>
   <text>
      <front>

1885 November 12: to Wilkinson<note xml:id="ftn3-329" place="foot" n="329"> Hocken MS-1014/005.</note>

      </front>

Napier<lb/>Novr. 12<hi rend="sup ">th</hi>., 1885.

Dear Sir

I duly received your letter of 9<hi rend="sup ">th</hi>. Sept., and with it the book-packet (containing your N.Z. Dicty.,) you so kindly so liberally sent me: I also recognize the valued friendly-feeling tone in your letter,—and I heartily thank you for <hi rend="italic">all</hi>.—

I ought to have written to you long ago, if only to acknowledge receipt, and I should have done so had I earlier received copies of my Mao. Circular from the Govt. Printer: these are very recently to hand, and I am sending out copies in all directions; among others to all those Maoris whose names you so kindly forwarded to me. I hope some good

            <hi rend="italic">[Page(s) missing]</hi>

   </text>
</TEI>


text:
# grunt-humans-txt

> Generate a [humans.txt](http://humanstxt.org/) file for the website.

[![Build Status](https://travis-ci.org//roughcoder/grunt-humans-txt.png)](https://travis-ci.org/roughcoder/grunt-humans-txt)

## Getting Started
This plugin requires Grunt `~0.4.1`

If you haven't used [Grunt](http://gruntjs.com/) before, be sure to check out the [Getting Started](http://gruntjs.com/getting-started) guide, as it explains how to create a [Gruntfile](http://gruntjs.com/sample-gruntfile) as well as install and use Grunt plugins. Once you're familiar with that process, you may install this plugin with this command:

```shell
npm install grunt-humans-txt --save-dev
```

Once the plugin has been installed, it may be enabled inside your Gruntfile with this line of JavaScript:

```js
grunt.loadNpmTasks('grunt-humans-txt');
```

## The "humans_txt" task

### Overview
_Run this task with the `grunt humans_txt` command._

The task creates a humans.txt file using data from any JSON file, i.e package.json file or directly from your Gruntfile. A humans.txt is a TXT file that contains information about the different people who have contributed to building the website.

Task targets, files and options may be specified according to the grunt [Configuring tasks](http://gruntjs.com/configuring-tasks) guide.

### Options

#### intro
Type: `String`
Default value: `'The humans responsible & colophon'`

A string value that is used in the head of the file.

#### commentStyle
Choices: `'c'`, `'u'`, `'p'`
Default value: `'c'`

Style of comments with section titles. Use `'c'` for C style, `'u'` for unix
style, and `'p'` for PHP style.

```
/* C STYLE COMMENT */

# UNIX STYLE COMMENT

// PHP STYLE COMMENT
```

#### tab
Type: `String`
Default value: `'\t'`

A string value that is used to advance nested values.

#### includeUpdateIn
Type: `String` or `false`
Default value: `'site'`

Include current date as *Last update* in section with specified name. Set to `false` to disable.

### Usage Examples

#### Local Content
In this example, the `content` options includes the data to be used. Each root item
is a section.

```js
grunt.initConfig({
  pkg: grunt.file.readJSON('package.json'),
  humans_txt: {
    options: {
      commentStyle: 'u',
      content: {
        'team': [ {
          'Web developer': 'Neil Barton',
          'Site': 'http://www.roughcoder.com',
          'Twitter': '@roughcoder',
          'Location': 'London, UK'

          },
          {
            'Ruby guy': 'Sam Jones',
            'Site': 'http://www.samjones.com',
            'Twitter': '@samjones'
          }
        ],
        'thanks': [
          {
            'Name': 'David Jones',
            'Website': 'www.google.com'
          }
        ],
        'site': [ {
            'Version': '<%= pkg.version %>',
            'Site Url': '<%= pkg.homepage %>',
            'Keywords': '<%= pkg.keywords %>',
            'Language': 'English',
            'Technology': 'node.js, apache'
          }
        ]
      },
    },
    dest: 'humans.txt',
  },
})
```

#### External Content
In this example, the content is read from external file.

```js
grunt.initConfig({
  humans_txt: {
    options: {
      content: grunt.file.readJSON('humans.json')
    },
    dest: 'humans.txt',
  },
})
```

## Contributing
In lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint and test your code using [Grunt](http://gruntjs.com/).

## Release History
* 2013-09-09   v0.2.1   Test tweak to allow Travis
* 2013-08-20   v0.2.0   Extended variability, tests
* 2013-06-11   v0.1.0   Initial task.


text:
from __future__ import print_function
import errno, os, shutil, sys, tempfile
from subprocess import check_call, check_output, CalledProcessError, Popen, PIPE
from distutils.version import LooseVersion

def pip_install(package, commit=None, **kwargs):
  "Install package using pip."
  if commit:
    check_version = kwargs.get('check_version', '')
    #output = check_output(['pip', 'show', package.split('/')[1]])
    #if check_version in output:
    #  print('{} already installed'.format(package))
    #  return
    package = 'git+git://github.com/{0}.git@{1}'.format(package, commit)
  print('Installing {}'.format(package))
  check_call(['pip', 'install', '--upgrade', package])

def build_docs(version='dev'):
  # Create virtualenv.
  doc_dir = os.path.dirname(os.path.realpath(__file__))
  virtualenv_dir = 'virtualenv'
  check_call(['virtualenv', virtualenv_dir])
  import sysconfig
  scripts_dir = os.path.basename(sysconfig.get_path('scripts'))
  activate_this_file = os.path.join(virtualenv_dir, scripts_dir,
                                    'activate_this.py')
  with open(activate_this_file) as f:
    exec(f.read(), dict(__file__=activate_this_file))
  # Upgrade pip because installation of sphinx with pip 1.1 available on Travis
  # is broken (see #207) and it doesn't support the show command.
  from pkg_resources import get_distribution, DistributionNotFound
  pip_version = get_distribution('pip').version
  if LooseVersion(pip_version) < LooseVersion('1.5.4'):
    print("Updating pip")
    check_call(['pip', 'install', '--upgrade', 'pip'])
  # Upgrade distribute because installation of sphinx with distribute 0.6.24
  # available on Travis is broken (see #207).
  try:
    distribute_version = get_distribution('distribute').version
    if LooseVersion(distribute_version) <= LooseVersion('0.6.24'):
      print("Updating distribute")
      check_call(['pip', 'install', '--upgrade', 'distribute'])
  except DistributionNotFound:
    pass
  # Install Sphinx and Breathe.
  pip_install('cppformat/sphinx',
              '12dde8afdb0a7bb5576e2656692c3478c69d8cc3',
              check_version='1.4a0.dev-20151013')
  pip_install('michaeljones/breathe',
              '1c9d7f80378a92cffa755084823a78bb38ee4acc')
  # Build docs.
  cmd = ['doxygen', '-']
  p = Popen(cmd, stdin=PIPE)
  p.communicate(input=r'''
      PROJECT_NAME      = C++ Format
      GENERATE_LATEX    = NO
      GENERATE_MAN      = NO
      GENERATE_RTF      = NO
      CASE_SENSE_NAMES  = NO
      INPUT             = {0}/format.h
      QUIET             = YES
      JAVADOC_AUTOBRIEF = YES
      AUTOLINK_SUPPORT  = NO
      GENERATE_HTML     = NO
      GENERATE_XML      = YES
      XML_OUTPUT        = doxyxml
      ALIASES           = "rst=\verbatim embed:rst"
      ALIASES          += "endrst=\endverbatim"
      PREDEFINED        = _WIN32=1 \
                          FMT_USE_VARIADIC_TEMPLATES=1 \
                          FMT_USE_RVALUE_REFERENCES=1 \
                          FMT_USE_USER_DEFINED_LITERALS=1
      EXCLUDE_SYMBOLS   = fmt::internal::* StringValue write_str
    '''.format(os.path.dirname(doc_dir)).encode('UTF-8'))
  if p.returncode != 0:
    raise CalledProcessError(p.returncode, cmd)
  check_call(['sphinx-build',
              '-Dbreathe_projects.format=' + os.path.join(os.getcwd(), 'doxyxml'),
              '-Dversion=' + version, '-Drelease=' + version, '-Aversion=' + version,
              '-b', 'html', doc_dir, 'html'])
  try:
    check_call(['lessc', '--clean-css',
                '--include-path=' + os.path.join(doc_dir, 'bootstrap'),
                os.path.join(doc_dir, 'cppformat.less'),
                'html/_static/cppformat.css'])
  except OSError as e:
    if e.errno != errno.ENOENT:
      raise
    print('lessc not found; make sure that Less (http://lesscss.org/) is installed')
    sys.exit(1)
  return 'html'

if __name__ == '__main__':
  build_docs(sys.argv[1])


text:
dojo.provide("dojo.io.RhinoIO");

dojo.require("dojo.io.common");
dojo.require("dojo.lang.func");
dojo.require("dojo.lang.array");
dojo.require("dojo.string.extras");

dojo.io.RhinoHTTPTransport = new function(){
		this.canHandle = function(/*dojo.io.Request*/req){
			//summary: Tells dojo.io.bind() if this is a good transport to
			//use for the particular type of request. This type of transport can
			//only be used inside the Rhino JavaScript engine.

			// We have to limit to text types because Rhino doesnt support
			// a W3C dom implementation out of the box.  In the future we
			// should provide some kind of hook to inject your own, because
			// in all my projects I use XML for Script to provide a W3C DOM.
			if(dojo.lang.find(["text/plain", "text/html", "text/xml", "text/javascript", "text/json", "application/json"],
				(req.mimetype.toLowerCase() || "")) < 0){
				return false;
			}

			// We only handle http requests!  Unfortunately, because the method is
			// protected, I can't directly create a java.net.HttpURLConnection, so
			// this is the only way to test.
			if(req.url.substr(0, 7) != "http://"){
				return false;
			}

			return true;
		}

		function doLoad(req, conn){
			var ret;
			if (req.method.toLowerCase() == "head"){
				// TODO: return the headers
			}else{
				var stream = conn.getContent();
				var reader = new java.io.BufferedReader(new java.io.InputStreamReader(stream));

				// read line-by-line because why not?
				var text = "";
				var line = null;
				while((line = reader.readLine()) != null){
					text += line;
				}

				if(req.mimetype == "text/javascript"){
					try{
						ret = dj_eval(text);
					}catch(e){
						dojo.debug(e);
						dojo.debug(text);
						ret = null;
					}
				}else if(req.mimetype == "text/json" || req.mimetype == "application/json"){
					try{
						ret = dj_eval("("+text+")");
					}catch(e){
						dojo.debug(e);
						dojo.debug(text);
						ret = false;
					}
				}else{
					ret = text;
				}
			}

			req.load("load", ret, req);
		}

		function connect(req){
			var content = req.content || {};
			var query;

			if (req.sendTransport){
				content["dojo.transport"] = "rhinohttp";
			}

			if(req.postContent){
				query = req.postContent;
			}else{
				query = dojo.io.argsFromMap(content, req.encoding);
			}

			var url_text = req.url;
			if(req.method.toLowerCase() == "get" && query != ""){
				url_text = url_text + "?" + query;
			}

			var url  = new java.net.URL(url_text);
			var conn = url.openConnection();

			//
			// configure the connection
			//

			conn.setRequestMethod(req.method.toUpperCase());

			if(req.headers){
				for(var header in req.headers){
					if(header.toLowerCase() == "content-type" && !req.contentType){
						req.contentType = req.headers[header];
					}else{
						conn.setRequestProperty(header, req.headers[header]);
					}
				}
			}
			if(req.contentType){
				conn.setRequestProperty("Content-Type", req.contentType);
			}

			if(req.method.toLowerCase() == "post"){
				conn.setDoOutput(true);

				// write the post data
				var output_stream = conn.getOutputStream();
				var byte_array = (new java.lang.String(query)).getBytes();
				output_stream.write(byte_array, 0, byte_array.length);
			}

			// do it to it!
			conn.connect();

			// perform the load
			doLoad(req, conn);
		}

		this.bind = function(req){
			//summary: function that sends the request to the server.

			//The following are acceptable properties in kwArgs (in addition to the
			//normal dojo.io.Request object properties).
			//url: String: URL the server URL to use for the request.
			//method: String: the HTTP method to use (GET, POST, etc...).
			//mimetype: Specifies what format the result data should be given to the load/handle callback. Values of
			//		text/javascript, text/json, and application/json will cause the transport
			//		to evaluate the response as JavaScript/JSON. Any other mimetype will give back a text
			//		string.
			//transport: String: specify "RhinoHTTPTransport" to force the use of this transport.
			//sync: boolean: if true, then a synchronous XMLHttpRequest call is done,
			//		if false (the default), then an asynchronous call is used.
			//headers: Object: The object property names and values will be sent as HTTP request header
			//		names and values.
			//encoding: String: The type of encoding to use when dealing with the content kwArgs property.
			//content: Object: The content object is converted into a name=value&name=value string, by
			//		using dojo.io.argsFromMap(). The encoding kwArgs property is passed to dojo.io.argsFromMap()
			//		for use in encoding the names and values. The resulting string is added to the request.
			//postContent: String: Raw name=value&name=value string to be included as part of the request.

			var async = req["sync"] ? false : true;
			if (async){
				setTimeout(dojo.lang.hitch(this, function(){
					connect(req);
				}), 1);
			} else {
				connect(req);
			}
		}

		dojo.io.transports.addTransport("RhinoHTTPTransport");
}


text:
module DLSS
  require 'dlss/capistrano'
end