text:
..
    Copyright 2014 Mirantis, Inc.

    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.

=============
Windows image
=============

Murano requires a Windows image in QCOW2 format to be built and uploaded into glance.

The easiest way to build a Windows image for murano is to build it on the host where your OpenStack is installed.

Prepare image builder host
==========================

Install KVM
-----------

.. note::

  This guide was tested on Ubuntu Server 12.04 x64.
..

KVM is a default hypervisor in OpenStack, so our build scripts are targeted to this hypervisor only. It may change in the future, though.

Install KVM and some additional packages that are required by our scripts

.. code-block:: console

  # apt-get install qemu-kvm virtinst virt-manager
..

Check that your hardware supports hardware virtualization.

.. code-block:: console

  $ kvm-ok
  INFO: /dev/kvm exists
  KVM acceleration can be used
..

If your output differs, check that hardware virtualization is enabled in your BIOS settings. You also could try import KVM kernel module

.. code-block:: console

  $ sudo modprobe kvm-intel
..

or

.. code-block:: cosole

  $ sudo modprobe kvm-amd
..

It might be helpful to add an appropriate module name into **/etc/modules** file to auto-load it during system boot. Sometimes it is required on Ubuntu systems.

Configure shared resource
=========================

The murano image builder uses a shared folder located on the host system as an installation source for components.
Makefile from the image builder will copy the required files to their locations, but you have to manually configure samba share.
To do this, use the steps below.

* Install samba

  .. code-block:: console

    # apt-get install samba
  ..

* Create folder that will be shared

  .. code-block:: console

    # mkdir -p /opt/samba/share
    # chown -R nobody:nogroup /opt/samba/share
  ..

* Configure samba server (/etc/samba/smb.conf)

  .. code-block:: text
    :linenos:

    ...
    [global]
       ...
      security = share
      ...
    [image-builder-share]
        comment = Image Builder Share
        browsable = yes
        path = /opt/image-builder/share
        guest ok = yes
        guest user = nobody
        read only = no
        create mask = 0755
    ...
  ..

* Restart samba services

  .. code-block:: console

      # service smbd restart
      # service nmbd restart
  ..

Download prerequisites
======================

.. _windows_installation_iso:

Windows server installation ISO
-------------------------------

.. list-table::
    :header-rows: 1
    :widths: 30, 15, 55

    * - Windows Version
      - Version String
      - Save to

    * - Windows Server 2008 R2 [#win2k8r2_link]_
      - 6.1.7601
      - /opt/image-builder/share/libvirt/images/ws-2008-eval.iso

    * - Windows Server 2012 [#win2k12_link]_
      - 6.3.9200
      - /opt/image-builder/share/libvirt/images/ws-2012-eval.iso
..

.. warning::

  Windows Server 2008 R2 must include Service Pack 1 updates. This is required to install PowerShell V3 which is required by the murano Agent.
..

|
.. [#win2k8r2_link] http://www.microsoft.com/en-us/download/details.aspx?id=11093
.. [#win2k12_link] http://technet.microsoft.com/en-US/evalcenter/hh670538.aspx?ocid=&wt.mc_id=TEC_108_1_33

.. _required_prerequisites:

Required Components
-------------------

.. list-table::
  :header-rows: 1
  :widths: 30, 70

  * - Component
    - Save to

  * - VirtIO drivers for Windows [#virtio_iso_link]_
    - /opt/image-builder/share/libvirt/images/virtio-win-0.1-74.iso

  * - CloudBase-Init for Windows [#cloudbase_init_link]_
    - /opt/image-builder/share/files/CloudbaseInitSetup_Beta.msi

  * - .NET 4.0 [#dot_net_40_link]_
    - /opt/image-builder/share/files/dotNetFx40_Full_x86_x64.exe

  * - PowerShell v3 [#powershell_v3_link]_
    - /opt/image-builder/share/files/Windows6.1-KB2506143-x64.msu

  * - Murano Agent [#murano_agent_link]_
    - /opt/image-builder/share/files/MuranoAgent.zip

  * - Git client [#msysgit_link]_
    - /opt/image-builder/share/files/Git-1.8.1.2-preview20130601.exe
..

.. warning::

  PowerShell V3 is a **mandatory** prerequisite. It is required by the murano Agent. To check your PowerShell version use PowerShell command *Get-Host*.
..

.. warning::

  When downloading VirtIO drivers choose only stable versions.
  Unstable versions might lead to errors during guest unattended installation.
  You can check the latest version available here: http://alt.fedoraproject.org/pub/alt/virtio-win/stable
..

|
.. [#ws2012iso_link] http://technet.microsoft.com/en-us/evalcenter/hh670538.aspx
.. [#virtio_iso_link] http://alt.fedoraproject.org/pub/alt/virtio-win/stable/virtio-win-0.1-74.iso
.. [#cloudbase_init_link] https://www.cloudbase.it/downloads/CloudbaseInitSetup_Beta.msi
.. [#dot_net_40_link] http://www.microsoft.com/en-us/download/details.aspx?id=17718
.. [#powershell_v3_link] http://www.microsoft.com/en-us/download/details.aspx?id=34595
.. [#murano_agent_link] https://www.dropbox.com/sh/zthldcxnp6r4flm/AADh6LkVkcw2j8nKZevqedHja/MuranoAgent.zip
.. [#msysgit_link] https://msysgit.googlecode.com/files/Git-1.8.3-preview20130601.exe

.. _optional_prerequisites:

Optional Components
-------------------

These components are not mandatory for the murano agent to function properly.
However, they may help you work with the image after deployment.

.. list-table::
  :header-rows: 1
  :widths: 30, 70

  * - Component
    - Save to

  * - Far Manager [#far_manager_link]_
    - /opt/image-builder/share/files/Far30b3367.x64.20130717.msi

  * - Sysinternals Suite [#sysinternals_link]_
    - /opt/image-builder/share/files/SysinternalsSuite.zip

  * - unzip.exe [#unzip_link]_
    - /opt/image-builder/share/files/unzip.exe

  * - .NET 4.5 [#dot_net_45_link]_
    - /opt/image-builder/share/files/dotNetFx45_Full_setup.exe
..

|
.. [#far_manager_link] http://www.farmanager.com/files/Far30b3525.x64.20130717.msi
.. [#sysinternals_link] http://download.sysinternals.com/files/SysinternalsSuite.zip
.. [#unzip_link] https://www.dropbox.com/sh/zthldcxnp6r4flm/AACwiyfcrlGDt3ygCFHrbwMra/unzip.exe
.. [#dot_net_45_link] http://www.microsoft.com/en-us/download/details.aspx?id=30653

Additional tools
================

Tools from this section are not necessary to build an image.
However, they may be helpful if you want to create an image with a different configuration.

Windows assessment and deployment kit (ADK)
-------------------------------------------

*Windows ADK* is required if you want to build your own answer files for auto unattended Windows installation.

Download it from http://www.microsoft.com/en-us/download/details.aspx?id=30652

Floppy image with unattended file
---------------------------------

Floppy image with answer file for unattended installation is needed to automate Windows installation process.

* Create empty floppy image in your home folder

  .. code-block:: console

    $ mkdir ~/flp/files
    $ mkdir ~/flp/mnt
  ..

  .. code-block:: console

    $ dd bs=512 count=2880 if=/dev/zero of=~/flp/floppy.img
    $ mkfs.msdos ~/flp/floppy.img
  ..

* Mount the image

  .. code-block:: console

      $ mkdir ~/flp/mnt
      $ sudo mount -o loop ~/floppy.img ~/flp/mnt
  ..

* Download **autounattend.xml.template** file from https://github.com/openstack/murano-deployment/tree/master/contrib/windows/image-builder/share/files

  This folder contains unattended files for several Windows versions, choose one that matches your Windows version.

* Copy that file to mounted floppy image

  .. code-block:: console

      $ cp ~/autounattend.xml.template ~/flp/mnt/autounattend.xml
  ..

* Replace string **%_IMAGE_BUILDER_IP_%** in that file with **192.168.122.1**

* Unmount the image

  .. code-block:: console

      $ sudo umount ~/flp/mnt
  ..

Build Windows image with murano
===============================

.. _build_image_using_image_builder_scripts:

Build Windows image using image builder script
----------------------------------------------

* Clone **murano-deployment** repository

  .. code-block:: console

    $ git clone git://git.openstack.org/cgit/openstack/murano-deployment.git
  ..

* Change directory to image-builder folder

  .. code-block:: console

    $ cd murano-deployment/contrib/windows/image-builder
  ..

* Create folder structure for image builder

  .. code-block:: console

    $ sudo make build-root
  ..

* Download build prerequisites, and copy them to correct folders

  * :ref:`windows_installation_iso`
  * :ref:`required_prerequisites`
  * :ref:`optional_prerequisites` (Optional)

* Test that all required files are in place

  .. code-block:: console

    $ sudo make test-build-files
  ..

* Get list of available images

  .. code-block:: console

    $ make
  ..

* Run image build process (e.g. to build Windows Server 2012)

  .. code-block:: console

    $ sudo make ws-2012-std
  ..

* Wait until process finishes

* The image file **ws-2012-std.qcow2** should be stored inside **/opt/image-builder/share/images** folder.

Build windows image manually
----------------------------

.. note::

  Please note that the preferred way to build images is to use Image Builder scripts, see :ref:`build_image_using_image_builder_scripts`
..

Get post-install scripts
------------------------

There are a few scripts which perform all the required post-installation tasks.

They all are located in http://git.openstack.org/cgit/openstack/murano-deployment/tree/contrib/windows/image-builder/share/scripts

.. note::

  There are subfolders for each supported Windows version.
  Choose one that matches Windows version you are building.
..

This folder contains several scripts

.. list-table::
  :header-rows: 1
  :widths: 20, 80

  * - Script Name
    - Description

  * - wpi.ps1
    - Handles component installation and system configuration tasks

  * - Start-Sysprep.ps1
    - Prepares system to be syspreped (cleans log files, stops some services and so on), and starts sysprep

  * - Start-AtFirstBoot.ps1
    - Performs basic after-installation tasks
..

Download these scripts and save them into /opt/image-builder/share/scripts

Create a VM
-----------

Now you need a virtual machine instance. There are two possible ways to create it - using CLI or GUI tools. We describe both in this section.

Using CLI Tools
^^^^^^^^^^^^^^^

1. Preallocate disk image

  .. code-block:: console

    $ qemu-img create -f raw /var/lib/libvirt/images/ws-2012.img 40G
  ..

2. Start the VM

  .. code-block:: console

    # virt-install --connect qemu:///system --hvm --name WinServ \
    > --ram 2048 --vcpus 2 --cdrom /opt/samba/share/9200.16384.WIN8_RTM\
    >.120725-1247_X64FRE_SERVER_EVAL_EN-US-HRM_SSS_X64FREE_EN-US_DV5.ISO \
    > --disk path=/opt/samba/share/virtio-win-0.1-52.iso,device=cdrom \
    > --disk path=/opt/samba/share/floppy.img,device=floppy \
    > --disk path=/var/lib/libvirt/images/ws-2012.qcow2\
    >,format=qcow2,bus=virtio,cache=none \
    > --network network=default,model=virtio \
    > --memballoon model=virtio --vnc --os-type=windows \
    > --os-variant=win2k8 --noautoconsole \
    > --accelerate --noapic --keymap=en-us --video=cirrus --force
  ..

Using virt-manager UI
^^^^^^^^^^^^^^^^^^^^^

1. Launch *virt-manager* from shell as root

2. Set a name for VM and select Local install media

3. Add one cdrom and attach Windows Server ISO image to it

4. Select OS type **Windows**

5. Set CPU and RAM amount

6. Deselect option **Enable storage for this virtual machine**

7. Add second cdrom for ISO image with virtio drivers

8. Add a floppy drive and attach our floppy image to it

9. Add (or create new) HDD image with Disk bus **VirtIO** and storage format **RAW**

10. Set network device model **VirtIO**

11. Start installation process and open guest vm screen through **Console** button

Install OS
----------

Launch your virtual machine, connect to its virtual console and complete OS installation. At the end of this step you should have Windows Server system that you are able to log into.

Install prerequisites and murano
--------------------------------

* Create folders where murano components will be installed

  .. list-table::
    :header-rows: 1
    :widths: 20, 80

    * - Path
      - Description

    * - C:\\Murano
      - Root directory for Murano

    * - C:\\Murano\\Agent
      - Murano Agent installation directory

    * - C:\\Murano\\Modules
      - PowerShell modules required by Murano

    * - C:\\Murano\\Scripts
      - PowerShell scripts and other files required by murano
  ..

* Open **Explorer** and navigate to **\\192.168.122.1\share** **192.168.122.1** is an IP address of KVM hypervisor assigned by default.

* Copy the murano agent files into C:\Murano\Agent

* Copy CoreFunctions directory (entire directory!) into C:\Murano\Modules

* Install .NET 4.0

* Register the murano agent

  .. code-block:: cmd

    > cd C:\Murano\Agent
    > .\WindowsMuranoAgent.exe /install
  ..

* Change PowerShell execution policy to less restricted

  .. code-block:: powershell

    Set-ExecutionPolicy RemoteSigned
  ..

* Register CoreFunctions modules

  .. code-block:: powershell

    Import-Module C:\Murano\Modules\CoreFunctions\CoreFunctions.psm1 -ArgumentList register
  ..

* Install CloudInit

* Run Sysprep

  .. code-block:: powershell

    C:\Murano\Scripts\Start-Sysprep.ps1 -BatchExecution
  ..

* Wait until sysprep phase finishes and system powers off.

Convert the image from RAW to QCOW2 format
------------------------------------------

The image must be converted from RAW format to QCOW2 before being imported into glance.

.. code-block:: console

    # qemu-img convert -O qcow2 /var/lib/libvirt/images/ws-2012.raw \
    > /var/lib/libvirt/images/ws-2012-ref.qcow2
..


text:
@interface UIViewController (KMNavigationBarTransition)

@end

redpajama_set_name: RedPajamaGithub


text:
require 'rails_helper'

describe HomeController, :type => :controller do

end


text:
exec sp_rename 'SEC_USER_SETTING.VALUE',  'VALUE_', 'COLUMN';

exec sp_rename 'SYS_CONFIG.VALUE', 'VALUE_', 'COLUMN';

exec sp_rename 'SEC_PERMISSION.VALUE', 'VALUE_', 'COLUMN';


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

	<textarea id="xooki-source">
As the Ivy's ant target to manage classpath, the IvyDE classpath container will help you manage the classpath of your Eclipse project, based on the dependencies declared in the Ivy files.

So you probably want to:

Create a container

Edit its setup

Launch the resolve of the dependencies

Retrieve the dependencies in your project

Resolve dependencies within the Eclipse workspace

Use IvyDE with maven pom.xml

Use IvyDE in concert with WTP

</textarea>


text:
package com.lakra.word.dao;

public abstract class WordDaoImpl implements WordDao {

}


text:
cd /tmp
wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
sudo sh -c "dpkg -i google-chrome-stable_current_amd64.deb && rm -f google-chrome-stable_current_amd64.deb"
sudo apt -yf install


text:
<?php
/* vim: set expandtab sw=4 ts=4 sts=4: */
/**
 * Tests for server_user_groups.lib.php
 *
 * @package PhpMyAdmin-test
 */

require_once 'libraries/php-gettext/gettext.inc';
require_once 'libraries/Util.class.php';
require_once 'libraries/Theme.class.php';
require_once 'libraries/relation.lib.php';
require_once 'libraries/database_interface.inc.php';
require_once 'libraries/url_generating.lib.php';
/*
 * Include to test.
 */
require_once 'libraries/server_user_groups.lib.php';

/**
 * Tests for server_user_groups.lib.php
 *
 * @package PhpMyAdmin-test
 */
class PMA_ServerUserGroupsTest extends PHPUnit_Framework_TestCase
{
    /**
     * Prepares environment for the test.
     *
     * @return void
     */
    public function setUp()
    {
        $GLOBALS['cfg']['ServerDefault'] = 1;
        $GLOBALS['cfg']['ActionLinksMode'] = 'both';

        $GLOBALS['server'] = 1;
        $_SESSION['relation'][$GLOBALS['server']] = array(
            'db' => 'pmadb',
            'users' => 'users',
            'usergroups' => 'usergroups'
        );

        $GLOBALS['pmaThemeImage'] = 'image';
        $_SESSION['PMA_Theme'] = PMA_Theme::load('./themes/pmahomme');
        $_SESSION['PMA_Theme'] = new PMA_Theme();
    }

    /**
     * Tests PMA_getHtmlForUserGroupsTable() function when there are no user groups
     *
     * @return void
     * @group medium
     */
    public function testGetHtmlForUserGroupsTableWithNoUserGroups()
    {
        $expectedQuery = "SELECT * FROM `pmadb`.`usergroups`"
            . " ORDER BY `usergroup` ASC";

        $dbi = $this->getMockBuilder('PMA_DatabaseInterface')
            ->disableOriginalConstructor()
            ->getMock();
        $dbi->expects($this->once())
            ->method('tryQuery')
            ->with($expectedQuery)
            ->will($this->returnValue(true));
        $dbi->expects($this->once())
            ->method('numRows')
            ->withAnyParameters()
            ->will($this->returnValue(0));
        $dbi->expects($this->once())
            ->method('freeResult');
        $GLOBALS['dbi'] = $dbi;

        $html = PMA_getHtmlForUserGroupsTable();
        $this->assertNotContains(
            '
',
            $html
        );
        $url_tag = ' 1));
        $this->assertContains(
            $url_tag,
            $html
        );
    }

    /**
     * Tests PMA_getHtmlForUserGroupsTable() function when there are user groups
     *
     * @return void
     */
    public function testGetHtmlForUserGroupsTableWithUserGroups()
    {
        $expectedQuery = "SELECT * FROM `pmadb`.`usergroups`"
            . " ORDER BY `usergroup` ASC";

        $dbi = $this->getMockBuilder('PMA_DatabaseInterface')
            ->disableOriginalConstructor()
            ->getMock();
        $dbi->expects($this->once())
            ->method('tryQuery')
            ->with($expectedQuery)
            ->will($this->returnValue(true));
        $dbi->expects($this->once())
            ->method('numRows')
            ->withAnyParameters()
            ->will($this->returnValue(1));
        $dbi->expects($this->at(2))
            ->method('fetchAssoc')
            ->withAnyParameters()
            ->will(
                $this->returnValue(
                    array(
                        'usergroup' => 'usergroup',
                        'tab' => 'server_sql',
                        'allowed' => 'Y'
                    )
                )
            );
        $dbi->expects($this->at(3))
            ->method('fetchAssoc')
            ->withAnyParameters()
            ->will($this->returnValue(false));
        $dbi->expects($this->once())
            ->method('freeResult');
        $GLOBALS['dbi'] = $dbi;

        $html = PMA_getHtmlForUserGroupsTable();
        $this->assertContains(
            'usergroup	',
            $html
        );
        $url_tag = '1, 'userGroup'=>htmlspecialchars('usergroup')
                )
            );
        $this->assertContains(
            $url_tag,
            $html
        );
        $url_tag = '1,
                    'userGroup'=>htmlspecialchars('usergroup')
                )
            );
        $this->assertContains(
            $url_tag,
            $html
        );
        $url_tag = ' 1,
                    'userGroup'=>htmlspecialchars('usergroup')
                )
            );
        $this->assertContains(
            $url_tag,
            $html
        );
    }

    /**
     * Tests PMA_deleteUserGroup() function
     *
     * @return void
     */
    public function testDeleteUserGroup()
    {
        $userDelQuery = "DELETE FROM `pmadb`.`users`"
            . " WHERE `usergroup`='ug'";
        $userGrpDelQuery = "DELETE FROM `pmadb`.`usergroups`"
            . " WHERE `usergroup`='ug'";

        $dbi = $this->getMockBuilder('PMA_DatabaseInterface')
            ->disableOriginalConstructor()
            ->getMock();
        $dbi->expects($this->at(0))
            ->method('query')
            ->with($userDelQuery);
        $dbi->expects($this->at(1))
            ->method('query')
            ->with($userGrpDelQuery);
        $GLOBALS['dbi'] = $dbi;

        PMA_deleteUserGroup('ug');
    }

    /**
     * Tests PMA_getHtmlToEditUserGroup() function
     *
     * @return void
     */
    public function testGetHtmlToEditUserGroup()
    {
        // adding a user group
        $html = PMA_getHtmlToEditUserGroup();
        $this->assertContains(
            '<input type="hidden" name="addUserGroupSubmit" value="1"',
            $html
        );
        $this->assertContains(
            '<input type="text" name="userGroup"',
            $html
        );

        $expectedQuery = "SELECT * FROM `pmadb`.`usergroups`"
            . " WHERE `usergroup`='ug'";
        $dbi = $this->getMockBuilder('PMA_DatabaseInterface')
            ->disableOriginalConstructor()
            ->getMock();
        $dbi->expects($this->once())
            ->method('tryQuery')
            ->with($expectedQuery)
            ->will($this->returnValue(true));
        $dbi->expects($this->at(1))
            ->method('fetchAssoc')
            ->withAnyParameters()
            ->will(
                $this->returnValue(
                    array(
                        'usergroup' => 'ug',
                        'tab' => 'server_sql',
                        'allowed' => 'Y'
                    )
                )
            );
        $dbi->expects($this->at(2))
            ->method('fetchAssoc')
            ->withAnyParameters()
            ->will($this->returnValue(false));
        $dbi->expects($this->once())
            ->method('freeResult');
        $GLOBALS['dbi'] = $dbi;

        // editing a user group
        $html = PMA_getHtmlToEditUserGroup('ug');
        $this->assertContains(
            '<input type="hidden" name="userGroup" value="ug"',
            $html
        );
        $this->assertContains(
            '<input type="hidden" name="editUserGroupSubmit" value="1"',
            $html
        );
        $this->assertContains(
            '<input type="hidden" name="editUserGroupSubmit" value="1"',
            $html
        );
        $this->assertContains(
            '<input type="checkbox" class="checkall" checked="checked"'
            . ' name="server_sql" value="Y" />',
            $html
        );
        $this->assertContains(
            '<input type="checkbox" class="checkall"'
            . ' name="server_databases" value="Y" />',
            $html
        );
    }
}
?>


text:
using Microsoft.AspNetCore.Html;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace DotNet.HighStock
{
    public class Container : HtmlString
    {
        private readonly List<HighStock> _Highstock;

        public Container(IEnumerable<HighStock> highstock)
            : base("")
        {
            _Highstock = new List<HighStock>();
            _Highstock.AddRange(highstock);
        }

        #region IHtmlString Members

        public string ToHtmlString()
        {
            StringBuilder scripts = new StringBuilder();
            _Highstock.ForEach(x => scripts.AppendLine("

".FormatWith(x.ContainerName)));

            List<HighStock> startupCharts = _Highstock.Where(x => String.IsNullOrEmpty(x.FunctionName)).ToList();
            scripts.AppendLine("");

            return scripts.ToString();
        }

        #endregion IHtmlString Members
    }
}


text:
<!DOCTYPE html>

    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <title>Class UrlBuilder
   </title>
    <meta name="viewport" content="width=device-width">
    <meta name="title" content="Class UrlBuilder
   ">
    <meta name="generator" content="docfx 2.40.8.0">

    <link rel="shortcut icon" href="../favicon.ico">
    <link rel="stylesheet" href="../styles/docfx.vendor.css">
    <link rel="stylesheet" href="../styles/docfx.css">
    <link rel="stylesheet" href="../styles/main.css">
    <meta property="docfx:navrel" content="../toc.html">
    <meta property="docfx:tocrel" content="toc.html">

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

              </button>

              <form class="navbar-form navbar-right" role="search" id="search">

                  <input type="text" class="form-control" id="search-query" placeholder="Search" autocomplete="off">

              </form>

          Show / Hide Table of Contents

Class UrlBuilder

Inheritance

System.Object

UrlBuilder

Inherited Members

      System.Object.Equals(System.Object)

      System.Object.Equals(System.Object, System.Object)

      System.Object.ReferenceEquals(System.Object, System.Object)

      System.Object.GetHashCode()

      System.Object.GetType()

      System.Object.MemberwiseClone()

Namespace: FFLib

Assembly: cs.temp.dll.dll

Syntax

public class UrlBuilder

Constructors

UrlBuilder()

Declaration

public UrlBuilder()

UrlBuilder(String)

Declaration

public UrlBuilder(string urlString)

Parameters

        Type
        Name
        Description

        System.String
        urlString

Properties

Fragment

Declaration

public string Fragment { get; set; }

Property Value

        Type
        Description

        System.String

Host

Declaration

public string Host { get; set; }

Property Value

        Type
        Description

        System.String

Path

Declaration

public string Path { get; set; }

Property Value

        Type
        Description

        System.String

Query

Get/Set URL encoded Query string

Declaration

public string Query { get; set; }

Property Value

        Type
        Description

        System.String

Scheme

Declaration

public string Scheme { get; set; }

Property Value

        Type
        Description

        System.String

Methods

GetQueryParam(String)

Get Url Decoded Query Parmeter Value by Key.

Declaration

public string GetQueryParam(string key)

Parameters

        Type
        Name
        Description

        System.String
        key

Returns

        Type
        Description

        System.String

Parse(String)

Declaration

public void Parse(string url)

Parameters

        Type
        Name
        Description

        System.String
        url

SetQueryParam(String, String)

Set Query Parameter by Key. Value will be encoded automaticly.

Declaration

public void SetQueryParam(string key, string value)

Parameters

        Type
        Name
        Description

        System.String
        key

        System.String
        value

ToString()

Declaration

public override string ToString()

Returns

        Type
        Description

        System.String

Overrides

System.Object.ToString()

              Back to top

            Generated by DocFX


text:
package org.elasticsearch.test.rest.test;

import org.elasticsearch.common.xcontent.yaml.YamlXContent;
import org.elasticsearch.test.rest.parser.RestTestParseException;
import org.elasticsearch.test.rest.parser.RestTestSuiteParseContext;
import org.elasticsearch.test.rest.parser.SkipSectionParser;
import org.elasticsearch.test.rest.section.SkipSection;
import org.junit.Test;

import static org.hamcrest.Matchers.*;

public class SkipSectionParserTests extends AbstractParserTests {

    @Test
    public void testParseSkipSectionVersionNoFeature() throws Exception {
        parser = YamlXContent.yamlXContent.createParser(
                "version:     \"0 - 0.90.2\"\n" +
                "reason:      Delete ignores the parent param"
        );

        SkipSectionParser skipSectionParser = new SkipSectionParser();

        SkipSection skipSection = skipSectionParser.parse(new RestTestSuiteParseContext("api", "suite", parser, "0.90.7"));

        assertThat(skipSection, notNullValue());
        assertThat(skipSection.getVersion(), equalTo("0 - 0.90.2"));
        assertThat(skipSection.getFeatures().size(), equalTo(0));
        assertThat(skipSection.getReason(), equalTo("Delete ignores the parent param"));
    }

    @Test
    public void testParseSkipSectionFeatureNoVersion() throws Exception {
        parser = YamlXContent.yamlXContent.createParser(
                "features:     regex"
        );

        SkipSectionParser skipSectionParser = new SkipSectionParser();

        SkipSection skipSection = skipSectionParser.parse(new RestTestSuiteParseContext("api", "suite", parser, "0.90.7"));

        assertThat(skipSection, notNullValue());
        assertThat(skipSection.getVersion(), nullValue());
        assertThat(skipSection.getFeatures().size(), equalTo(1));
        assertThat(skipSection.getFeatures().get(0), equalTo("regex"));
        assertThat(skipSection.getReason(), nullValue());
    }

    @Test
    public void testParseSkipSectionFeaturesNoVersion() throws Exception {
        parser = YamlXContent.yamlXContent.createParser(
                "features:     [regex1,regex2,regex3]"
        );

        SkipSectionParser skipSectionParser = new SkipSectionParser();

        SkipSection skipSection = skipSectionParser.parse(new RestTestSuiteParseContext("api", "suite", parser, "0.90.7"));

        assertThat(skipSection, notNullValue());
        assertThat(skipSection.getVersion(), nullValue());
        assertThat(skipSection.getFeatures().size(), equalTo(3));
        assertThat(skipSection.getFeatures().get(0), equalTo("regex1"));
        assertThat(skipSection.getFeatures().get(1), equalTo("regex2"));
        assertThat(skipSection.getFeatures().get(2), equalTo("regex3"));
        assertThat(skipSection.getReason(), nullValue());
    }

    @Test(expected = RestTestParseException.class)
    public void testParseSkipSectionBothFeatureAndVersion() throws Exception {
        parser = YamlXContent.yamlXContent.createParser(
                "version:     \"0 - 0.90.2\"\n" +
                "features:     regex\n" +
                "reason:      Delete ignores the parent param"
        );

        SkipSectionParser skipSectionParser = new SkipSectionParser();

        skipSectionParser.parse(new RestTestSuiteParseContext("api", "suite", parser, "0.90.7"));
    }

    @Test(expected = RestTestParseException.class)
    public void testParseSkipSectionNoReason() throws Exception {
        parser = YamlXContent.yamlXContent.createParser(
                "version:     \"0 - 0.90.2\"\n"
        );

        SkipSectionParser skipSectionParser = new SkipSectionParser();
        skipSectionParser.parse(new RestTestSuiteParseContext("api", "suite", parser, "0.90.7"));
    }

    @Test(expected = RestTestParseException.class)
    public void testParseSkipSectionNoVersionNorFeature() throws Exception {
        parser = YamlXContent.yamlXContent.createParser(
                "reason:      Delete ignores the parent param\n"
        );

        SkipSectionParser skipSectionParser = new SkipSectionParser();
        skipSectionParser.parse(new RestTestSuiteParseContext("api", "suite", parser, "0.90.7"));
    }
}


text:
package org.ppwcode.vernacular.persistence_III.jpa;

import static org.ppwcode.vernacular.exception_II.ProgrammingErrorHelpers.preArgumentNotNull;

import javax.persistence.PrePersist;
import javax.persistence.PreUpdate;

import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.ppwcode.vernacular.exception_II.InternalTransportException;
import org.ppwcode.vernacular.persistence_III.dao.jpa.JpaStatelessCrudDao;
import org.ppwcode.vernacular.semantics_VI.bean.RousseauBean;
import org.ppwcode.vernacular.semantics_VI.exception.CompoundPropertyException;
import org.toryt.annotations_I.Expression;
import org.toryt.annotations_I.MethodContract;
import org.toryt.annotations_I.Throw;

/**
 *
This is a JPA entity listener that normalizes and validates {@link RousseauBean} instances immediately
 *   prior to database insertion and update, using {@link RousseauBean#normalize()} and
 *   {@link RousseauBean#wildExceptions()}.

 *
Although this a persistence-related issue, this class only depends of the entities implementing
 *   {@link RousseauBean}, and thus can be used in circumstances where you do not wish to apply the
 *   {@code PersistentBean} interface. The listener methods do nothing for entities that not have type
 *   {@link RousseauBean}, so it is no problem to define the listener as the default entity listener for all inserts
 *   and updates. This can be done in the persistency unit definition as follows:

 *

 *   <entity-mappings>
 *     <entity-listeners>
 *       < entity-listeners class="org.ppwcode.vernacular.persistence_III.jpa.JpaRousseauBeanValidator">
 *     </entity-listeners>
 *   </entity-mappings>
 *

 *
If you use entities that extend {@code AbstractIntegerIdVersionedPersistentBean}, this is not necessary, since that
 *   class defines the listener for itself and all subtypes.

 *
In case validation fails ({@code ! }{@link CompoundPropertyException#isEmpty()}), the exception that expresses
 *   the validation problem is packaged into a {@link InternalTransportException}, because JPA entity listener methods
 *   are only allowed to throw {@link RuntimeException RuntimeExceptions}. When a listener does throw an exception,
 *   the current transaction is rolled-back, and all instances of session beans implicated in the current
 *   thread are discarded.

 *
The problem with this approach is that, with multiple updates and inserts in 1 transaction, only the
 *   first validation that fails has the opportunity to express its woes. This validator is to be used as a last resort.
 *   If you use the {@link JpaStatelessCrudDao} and a persistence strategy (cascade, loading strategy) according to the
 *   ppwcode vernacular for relations, normally all relevant beans are validated before insertion or update. This
 *   validator thus does the same work again. Its functionality is less than optimal in reporting all problems in one
 *   go, but it makes the system completely safe at the cost of extra processing time. This is not a good idea in
 *   systems with an extreme load, but gives us a buffer against programming errors in normal systems, protecting data
 *   integrity. For {@link JpaStatelessCrudDao}, it thus has to make sure that the persistence manager will not try to
 *   persist in cases of problems, since then one problem will be noted twice. Thus {@link JpaStatelessCrudDao} will
 *   have to abort the transaction before commit is attempted. It does.

 */
public class JpaRousseauBeanValidator {

  private final static Log _LOG = LogFactory.getLog(JpaRousseauBeanValidator.class);

  @PrePersist
  @PreUpdate
  @MethodContract(
    pre  = @Expression("entity != null"),
    post = {
      @Expression("entity.normalize()"),
      @Expression(value = "entity'civilized",
                  description = "if this bean is not civilized before the call, " +
                      "nothing can make this postcondition true, and thus an " +
                      "exception must be thrown")
    },
    exc = @Throw(type = InternalTransportException.class,
                 cond = {
                   @Expression("! entity'civilized"),
                   @Expression("thrown.cause != null"),
                   @Expression("thrown.cause instanceof CompoundPropertyException"),
                   @Expression("thrown.cause.like(wildExceptions)"),
                   @Expression("thrown.cause.closed")
                 })
  )
  public void validate(Object entity) throws InternalTransportException {
    _LOG.debug("pre-insert or -update called for " + entity);
    assert preArgumentNotNull(entity, "entity");
    try {
      RousseauBean rb = (RousseauBean)entity; // ClassCastException
      _LOG.trace("entity is a RousseauBean; we will normalize and then check civility");
      rb.normalize();
      rb.checkCivility(); // CompoundPropertyException
      _LOG.trace("entity is normalized and is civil; database change may proceed");
    }
    catch (ClassCastException ccExc) {
      // NOP don't touch non-rousseau bean entities
      _LOG.trace("entity is not a RousseauBean; no normalization or validation done");
    }
    catch (CompoundPropertyException wildExc) {
      _LOG.debug("entity is normalized, and found wild; the exception will be thrown, " +
                 "packaged in a InternalTransportException", wildExc);
      throw new InternalTransportException(wildExc);
    }
    finally {
      _LOG.debug("pre-insert or -update done for " + entity);
    }
  }

}


text:
package subprocess

import (
	"bytes"
	"io"
	"os/exec"
	"strings"
	"time"
)

const (
	SUCCESS = 0
	FAILED  = 1
	TIMEOUT = 2
)

type SubProcess struct {
	commands []*Command

	env     []string
	dir     string
	stdin   io.Reader
	timeout time.Duration
}

type Command struct {
	name string
	args []string
}

func Cmd(name string, arg ...string) *SubProcess {
	sp := SubProcess{}
	sp.commands = append(sp.commands, &Command{
		name: name,
		args: arg,
	})
	return &sp
}

func (sp *SubProcess) Pipe(name string, arg ...string) *SubProcess {
	sp.commands = append(sp.commands, &Command{
		name: name,
		args: arg,
	})
	return sp
}

func (sp *SubProcess) SetEnv(key, value string) *SubProcess {
	sp.env = append(sp.env, key+"="+value)
	return sp
}

func (sp *SubProcess) WithDir(dir string) *SubProcess {
	sp.dir = dir
	return sp
}

func (sp *SubProcess) WithTimeout(to time.Duration) *SubProcess {
	sp.timeout = to
	return sp
}

func (sp *SubProcess) SetStdin(ir io.Reader) *SubProcess {
	sp.stdin = ir
	return sp
}

type Result struct {
	Stdout     io.Reader
	Stderr     io.Reader
	StatusCode int
}

func (sp *SubProcess) Connect() chan *Result {
	ch := make(chan *Result)
	go func() {
		var ret *Result
		if sp.timeout == time.Duration(0) {
			ret = <-sp.connect()
		} else {
			select {
			case ret = <-sp.connect():
			case <-time.After(sp.timeout):
				ret = createTimeoutResult()
			}
		}
		ch <- ret
	}()
	return ch
}

func (sp *SubProcess) connect() chan *Result {
	ch := make(chan *Result)
	go func() {
		ch <- sp.execCommand()
	}()
	return ch
}

func (sp *SubProcess) execCommand() *Result {
	var out bytes.Buffer
	var ec *exec.Cmd
	var stdout io.ReadCloser
	var isHead bool = true
	var err error
	var ecs []*exec.Cmd
	var length = len(sp.commands)

	for _, cmd := range sp.commands {
		ec = exec.Command(cmd.name, cmd.args...)
		if isHead {
			ec.Stdin = sp.stdin
			isHead = false
		} else {
			ec.Stdin = stdout
		}
		ec.Env = sp.env
		ec.Dir = sp.dir

		stdout, err = ec.StdoutPipe()
		if err != nil {
			return &Result{
				Stderr:     strings.NewReader(err.Error()),
				StatusCode: FAILED,
			}
		}
		ecs = append(ecs, ec)
	}

	for i := length; i > 0; i-- {
		ec = ecs[i-1]
		if i == length {
			ec.Stdout = &out
		}
		ec.Start()
	}
	for i := 0; i < length; i++ {
		ecs[i].Wait()
	}

	return &Result{
		Stdout:     &out,
		StatusCode: SUCCESS,
	}
}

func createTimeoutResult() *Result {
	return &Result{
		Stderr:     strings.NewReader("Connection timeout error"),
		StatusCode: TIMEOUT,
	}
}


text:
id: apis/Settings
title: Settings
wip: true
---

```reason
[@bs.module "react-native"] [@bs.scope "Settings"]
external get: string => string = "";

[@bs.module "react-native"] [@bs.scope "Settings"]
external set: Js.Dict.t(string) => unit = "";

type watchToken;

[@bs.module "react-native"] [@bs.scope "Settings"]
external watchKeys: (list(string), unit => unit) => watchToken = "";

[@bs.module "react-native"] [@bs.scope "Settings"]
external clearWatch: watchToken => unit = "";

```


text:
ACCEPTED

#### According to
Index Fungorum

#### Published in
Sydowia 11: 114 (1958)

#### Original name
Meliola thaliformis var. naucleae Deighton

### Remarks
null


text:
layout: post
title: Using MTA Turnstile Data to Create a Smart Canvasseering Plan
---

I ride the subway everyday, along with millions of others. Each time someone swipes their card and plows
through the turnstile, the MTA captures that bit of data at that points in time (actually during that
specific four hour increment, to be precise).

For our first project at Metis, we were challenged with the task of downloading, cleaning, organizing,
scrubbing, and analyzing this data to help an organization with the task of deploying a street team
to canvas for their gala at the beginning of the summer. The task was loosely defined: we knew that the
gala appealed to women in tech and that the organizations goals were firstly, to gather as many email
addresses as possible and secondly, to increase gala attendance and potential contributions. The rest was up
to us to determine.

Thus, my team and I started out by creating our own assumptions for the gala. We decided that the gala would
be held during the first week of June in Manhattan. Thus, we collected data from the 5 weeks leading up to
June in 2015, assuming this is an accurate proxy for subway traffic in May in 2016.

Before looking at the data we brainstormed potential factors that could influence our decisions of where
to place canvaseers. Below is a snapshot of our list:

Factors that influence number of email addresses:
- number of entries and exits
- time of day
- day of week
- seasonality / holidays
- proximity to tech companies
- number of canvassers

Factors that influence gala attendance and contribution:
- resident vs. tourist
- disposable income
- occupation
- distance from gala
- gender
- age

Ideally, we could gather all of the above data and overlay this insight with information gathered from our
analysis of the MTA data. Given timing and ability constraints, we chose to focus on the following factors:
number of entries and exits, day of week, seasonality / holidays, proximity to tech companies

We used dictionaries and pandas DataFrames in Python to store and clean the MTA data. Once that was finished,
we took some high level snapshots of the data. Below you can see some of the output generated:

![Top 10 Stations](https://raw.githubusercontent.com/applebym/applebym.github.io/master/images/post1/top_20.png)

![Total Traffic by Day of Week](https://raw.githubusercontent.com/applebym/applebym.github.io/master/images/post1/day_of_week.png)
![Top 15 Stations Heatmap](https://raw.githubusercontent.com/applebym/applebym.github.io/master/images/post1/heat2.png)

![Tech Heavy Zip Codes](https://raw.githubusercontent.com/applebym/applebym.github.io/master/images/post1/Est%20by%20zip.jpg)

From this, we recommended sending the street teams to the _top 10 stations_ within _tech heavy zipcodes_ on _Mon-Fri_ in _May_, _excluding Memorial Day_.

Given more time, some interesting next steps would be to overlay additional data sources, such as tourist density information, income distributions within Manhattan, donation density by location, and other demographic data (gender,
age, etc). We also thought it might be prudent to focus on different data depending on the time of day and whether the
target was entering or exiting a station. For example, in the morning, we would focus on demographic data when considering
the number of entries and industry data when considering the number of exits, given that the moring is commuter heavy.

Thanks for reading!


text:
/**
 * BatchSvcLocator.java
 *
 * This file was auto-generated from WSDL
 * by the Apache Axis 1.2.1 Jun 14, 2005 (09:15:57 EDT) WSDL2Java emitter.
 */

package com.avalara.avatax.services.batch;

import java.net.MalformedURLException;
import java.net.URL;

public class BatchSvcLocator extends org.apache.axis.client.Service implements BatchSvc {

    public BatchSvcLocator() {
    }

    public BatchSvcLocator(org.apache.axis.EngineConfiguration config) {
        super(config);
    }

    public BatchSvcLocator(String wsdlLoc, javax.xml.namespace.QName sName) throws javax.xml.rpc.ServiceException {
        super(wsdlLoc, sName);
    }

    // Use to get a proxy class for BatchSvcSoap
    private String BatchSvcSoap_address = "http://localhost/avatax.services/Batch/BatchSvc.asmx";

    public String getBatchSvcSoapAddress() {
        return BatchSvcSoap_address;
    }

    // The WSDD service name defaults to the port name.
    private String BatchSvcSoapWSDDServiceName = "BatchSvcSoap";

    public String getBatchSvcSoapWSDDServiceName() {
        return BatchSvcSoapWSDDServiceName;
    }

    public void setBatchSvcSoapWSDDServiceName(String name) {
        BatchSvcSoapWSDDServiceName = name;
    }

    public com.avalara.avatax.services.batch.BatchSvcSoap getBatchSvcSoap() throws javax.xml.rpc.ServiceException {
       java.net.URL endpoint;
        try {
            endpoint = new java.net.URL(BatchSvcSoap_address);
        }
        catch (java.net.MalformedURLException e) {
            throw new javax.xml.rpc.ServiceException(e);
        }
        return getBatchSvcSoap(endpoint);
    }

    public com.avalara.avatax.services.batch.BatchSvcSoap getBatchSvcSoap(java.net.URL portAddress) throws javax.xml.rpc.ServiceException {
        try {
             // BEGIN CUSTOM
            String path = portAddress.toString();
            if (!path.endsWith(".asmx"))
            {
                if (!path.endsWith("/"))
                {
                    path += "/";
                }
                path += "batch/batchsvc.asmx";
                portAddress = new URL(path);
            }
            // END CUSTOM
            com.avalara.avatax.services.batch.BatchSvcSoapStub _stub = new com.avalara.avatax.services.batch.BatchSvcSoapStub(portAddress, this);
            _stub.setPortName(getBatchSvcSoapWSDDServiceName());
            return _stub;
        }
        catch (org.apache.axis.AxisFault e) {
            return null;
        }
         // BEGIN CUSTOM
        catch (MalformedURLException e)
        {
            return null;
        }
        // END CUSTOM
    }

    public void setBatchSvcSoapEndpointAddress(String address) {
        BatchSvcSoap_address = address;
    }

    // Use to get a proxy class for BatchSvcSoap12
    private String BatchSvcSoap12_address = "http://localhost/avatax.services/Batch/BatchSvc.asmx";

    public String getBatchSvcSoap12Address() {
        return BatchSvcSoap12_address;
    }

    // The WSDD service name defaults to the port name.
    private String BatchSvcSoap12WSDDServiceName = "BatchSvcSoap12";

    public String getBatchSvcSoap12WSDDServiceName() {
        return BatchSvcSoap12WSDDServiceName;
    }

    public void setBatchSvcSoap12WSDDServiceName(String name) {
        BatchSvcSoap12WSDDServiceName = name;
    }

    public com.avalara.avatax.services.batch.BatchSvcSoap getBatchSvcSoap12() throws javax.xml.rpc.ServiceException {
       java.net.URL endpoint;
        try {
            endpoint = new java.net.URL(BatchSvcSoap12_address);
        }
        catch (java.net.MalformedURLException e) {
            throw new javax.xml.rpc.ServiceException(e);
        }
        return getBatchSvcSoap12(endpoint);
    }

    public com.avalara.avatax.services.batch.BatchSvcSoap getBatchSvcSoap12(java.net.URL portAddress) throws javax.xml.rpc.ServiceException {
        try {
            com.avalara.avatax.services.batch.BatchSvcSoap12Stub _stub = new com.avalara.avatax.services.batch.BatchSvcSoap12Stub(portAddress, this);
            _stub.setPortName(getBatchSvcSoap12WSDDServiceName());
            return _stub;
        }
        catch (org.apache.axis.AxisFault e) {
            return null;
        }
    }

    public void setBatchSvcSoap12EndpointAddress(String address) {
        BatchSvcSoap12_address = address;
    }

    /**
     * For the given interface, get the stub implementation.
     * If this service has no port for the given interface,
     * then ServiceException is thrown.
     * This service has multiple ports for a given interface;
     * the proxy implementation returned may be indeterminate.
     */
    public java.rmi.Remote getPort(Class serviceEndpointInterface) throws javax.xml.rpc.ServiceException {
        try {
            if (com.avalara.avatax.services.batch.BatchSvcSoap.class.isAssignableFrom(serviceEndpointInterface)) {
                com.avalara.avatax.services.batch.BatchSvcSoapStub _stub = new com.avalara.avatax.services.batch.BatchSvcSoapStub(new java.net.URL(BatchSvcSoap_address), this);
                _stub.setPortName(getBatchSvcSoapWSDDServiceName());
                return _stub;
            }
            if (com.avalara.avatax.services.batch.BatchSvcSoap.class.isAssignableFrom(serviceEndpointInterface)) {
                com.avalara.avatax.services.batch.BatchSvcSoap12Stub _stub = new com.avalara.avatax.services.batch.BatchSvcSoap12Stub(new java.net.URL(BatchSvcSoap12_address), this);
                _stub.setPortName(getBatchSvcSoap12WSDDServiceName());
                return _stub;
            }
        }
        catch (Throwable t) {
            throw new javax.xml.rpc.ServiceException(t);
        }
        throw new javax.xml.rpc.ServiceException("There is no stub implementation for the interface:  " + (serviceEndpointInterface == null ? "null" : serviceEndpointInterface.getName()));
    }

    /**
     * For the given interface, get the stub implementation.
     * If this service has no port for the given interface,
     * then ServiceException is thrown.
     */
    public java.rmi.Remote getPort(javax.xml.namespace.QName portName, Class serviceEndpointInterface) throws javax.xml.rpc.ServiceException {
        if (portName == null) {
            return getPort(serviceEndpointInterface);
        }
        String inputPortName = portName.getLocalPart();
        if ("BatchSvcSoap".equals(inputPortName)) {
            return getBatchSvcSoap();
        }
        else if ("BatchSvcSoap12".equals(inputPortName)) {
            return getBatchSvcSoap12();
        }
        else  {
            java.rmi.Remote _stub = getPort(serviceEndpointInterface);
            ((org.apache.axis.client.Stub) _stub).setPortName(portName);
            return _stub;
        }
    }

    public javax.xml.namespace.QName getServiceName() {
        return new javax.xml.namespace.QName("http://avatax.avalara.com/services", "BatchSvc");
    }

    private java.util.HashSet ports = null;

    public java.util.Iterator getPorts() {
        if (ports == null) {
            ports = new java.util.HashSet();
            ports.add(new javax.xml.namespace.QName("http://avatax.avalara.com/services", "BatchSvcSoap"));
            ports.add(new javax.xml.namespace.QName("http://avatax.avalara.com/services", "BatchSvcSoap12"));
        }
        return ports.iterator();
    }

    /**
    * Set the endpoint address for the specified port name.
    */
    public void setEndpointAddress(String portName, String address) throws javax.xml.rpc.ServiceException {

if ("BatchSvcSoap".equals(portName)) {
            setBatchSvcSoapEndpointAddress(address);
        }
        else
if ("BatchSvcSoap12".equals(portName)) {
            setBatchSvcSoap12EndpointAddress(address);
        }
        else
{ // Unknown Port Name
            throw new javax.xml.rpc.ServiceException(" Cannot set Endpoint Address for Unknown Port" + portName);
        }
    }

    /**
    * Set the endpoint address for the specified port name.
    */
    public void setEndpointAddress(javax.xml.namespace.QName portName, String address) throws javax.xml.rpc.ServiceException {
        setEndpointAddress(portName.getLocalPart(), address);
    }

}


text:
ACCEPTED

#### According to
Integrated Taxonomic Information System

#### Published in
Bol. Soc. Argent. Bot. 9:382. 1961

#### Original name
null

### Remarks
null


text:
package com.experimentmob.pojos;

import java.util.List;

public class ExperimentPojo {
	private String id;
	private String name;
	private String desc;
	private List<FieldsPojo> fields;
	private String createDate;
	private String finishedDate;
	private String expression;

	public ExperimentPojo(String id, String name, String desc, List<FieldsPojo> fields, String createDate, String finishedDate, String expression) {
		super();
		this.id = id;
		this.name = name;
		this.desc = desc;
		this.fields = fields;
		this.createDate = createDate;
		this.finishedDate = finishedDate;
		this.expression = expression;
	}

	public String getCreateDate() {
		return createDate;
	}

	public String getFinishedDate() {
		return finishedDate;
	}

	public String getId() {
		return id;
	}

	public String getName() {
		return name;
	}

	public String getDesc() {
		return desc;
	}

	public List<FieldsPojo> getFields() {
		return fields;
	}

	public String getExpression() {
		return expression;
	}

	public void setCreateDate(String createDate) {
		this.createDate = createDate;
	}

	public void setFinishedDate(String finishedDate) {
		this.finishedDate = finishedDate;
	}
}


text:
package scalapb.grpc
import io.grpc.stub.StreamObserver
import io.grpc.{CallOptions, Channel, MethodDescriptor}

import scala.collection.JavaConverters._
import scala.concurrent.Future

object ClientCalls {
  def blockingUnaryCall[ReqT, RespT](
      channel: Channel,
      method: MethodDescriptor[ReqT, RespT],
      options: CallOptions,
      request: ReqT
  ): RespT = {
    io.grpc.stub.ClientCalls.blockingUnaryCall(channel.newCall(method, options), request)
  }

  def asyncUnaryCall[ReqT, RespT](
      channel: Channel,
      method: MethodDescriptor[ReqT, RespT],
      options: CallOptions,
      request: ReqT
  ): Future[RespT] = {
    Grpc.guavaFuture2ScalaFuture(
      io.grpc.stub.ClientCalls.futureUnaryCall(channel.newCall(method, options), request)
    )
  }

  def blockingServerStreamingCall[ReqT, RespT](
      channel: Channel,
      method: MethodDescriptor[ReqT, RespT],
      options: CallOptions,
      request: ReqT
  ): Iterator[RespT] = {
    io.grpc.stub.ClientCalls
      .blockingServerStreamingCall(channel.newCall(method, options), request)
      .asScala
  }

  def asyncServerStreamingCall[ReqT, RespT](
      channel: Channel,
      method: MethodDescriptor[ReqT, RespT],
      options: CallOptions,
      request: ReqT,
      responseObserver: StreamObserver[RespT]
  ): Unit = {
    io.grpc.stub.ClientCalls
      .asyncServerStreamingCall(channel.newCall(method, options), request, responseObserver)
  }

  def asyncClientStreamingCall[ReqT, RespT](
      channel: Channel,
      method: MethodDescriptor[ReqT, RespT],
      options: CallOptions,
      responseObserver: StreamObserver[RespT]
  ): StreamObserver[ReqT] = {
    io.grpc.stub.ClientCalls
      .asyncClientStreamingCall(channel.newCall(method, options), responseObserver)
  }

  def asyncBidiStreamingCall[ReqT, RespT](
      channel: Channel,
      method: MethodDescriptor[ReqT, RespT],
      options: CallOptions,
      responseObserver: StreamObserver[RespT]
  ): StreamObserver[ReqT] = {
    io.grpc.stub.ClientCalls
      .asyncBidiStreamingCall(channel.newCall(method, options), responseObserver)
  }
}


text:
<?php

namespace Github\Api\Issue;

use Github\Api\AbstractApi;
use Github\Api\AcceptHeaderTrait;

class Timeline extends AbstractApi
{
    use AcceptHeaderTrait;

    public function configure()
    {
        $this->acceptHeaderValue = 'application/vnd.github.mockingbird-preview';

        return $this;
    }

    /**
     * Get all events for a specific issue.
     *
     * @link https://developer.github.com/v3/issues/timeline/#list-events-for-an-issue
     *
     * @param string $username
     * @param string $repository
     * @param int    $issue
     *
     * @return array
     */
    public function all($username, $repository, $issue)
    {
        return $this->get('/repos/'.rawurlencode($username).'/'.rawurlencode($repository).'/issues/'.$issue.'/timeline');
    }
}


text:
#ifndef SQLStatementSync_h
#define SQLStatementSync_h

#if ENABLE(DATABASE)

#include "ExceptionCode.h"
#include "PlatformString.h"
#include "SQLValue.h"
#include <wtf/Forward.h>
#include <wtf/Vector.h>

namespace WebCore {

class DatabaseSync;
class SQLResultSet;

class SQLStatementSync {
public:
    SQLStatementSync(const String& statement, const Vector<SQLValue>& arguments, int permissions);

    PassRefPtr<SQLResultSet> execute(DatabaseSync*, ExceptionCode&);

private:
    String m_statement;
    Vector<SQLValue> m_arguments;
    int m_permissions;
};

} // namespace WebCore

#endif // ENABLE(DATABASE)

#endif // SQLStatementSync_h


text:
![unmaintained](http://img.shields.io/badge/status-unmaintained-lightgrey.svg)

Manually downloading songs from The Hype Machine too difficult? Wish you could
download that song from Soundcloud? Since the browser stores songs in its cache
in order to play them, simply start `hypembot` and it will monitor the cache,
copying mp3's into your Music directory.

## How does it work?

The program monitors your browser cache using `kqueue` and once a 'quality' mp3
file has been stable in the cache for 5 minutes, `hypembot` copies out of the
cache for you.

## Install

    $ [sudo] gem install hypembot
    $ hypembot # make sure to set ulimit -n 4096 or something similarily high

Use `-s` or `--source` to specify the path to where the music is cached, and
`-d` or `--directory` to specify where you want the files copied to.

Works on Mac OSX Lion. Uses kqueue by default.

## Copyright

`hypembot` is Copyright (c) 2012 [Kirk Scheibelhut](http://scheibo.com/about) and distributed under the MIT license.<br />
See the `LICENSE` file for further details regarding licensing and distribution.


text:
"""Auto-generated file, do not edit by hand. MQ metadata"""
from ..phonemetadata import NumberFormat, PhoneNumberDesc, PhoneMetadata

PHONE_METADATA_MQ = PhoneMetadata(id='MQ', country_code=596, international_prefix='00',
    general_desc=PhoneNumberDesc(national_number_pattern='[56]\\d{8}', possible_number_pattern='\\d{9}'),
    fixed_line=PhoneNumberDesc(national_number_pattern='596(?:0[2-5]|[12]0|3[05-9]|4[024-8]|[5-7]\\d|89|9[4-8])\\d{4}', possible_number_pattern='\\d{9}', example_number='596301234'),
    mobile=PhoneNumberDesc(national_number_pattern='696(?:[0-479]\\d|5[01]|8[0-689])\\d{4}', possible_number_pattern='\\d{9}', example_number='696201234'),
    toll_free=PhoneNumberDesc(national_number_pattern='NA', possible_number_pattern='NA'),
    premium_rate=PhoneNumberDesc(national_number_pattern='NA', possible_number_pattern='NA'),
    shared_cost=PhoneNumberDesc(national_number_pattern='NA', possible_number_pattern='NA'),
    personal_number=PhoneNumberDesc(national_number_pattern='NA', possible_number_pattern='NA'),
    voip=PhoneNumberDesc(national_number_pattern='NA', possible_number_pattern='NA'),
    pager=PhoneNumberDesc(national_number_pattern='NA', possible_number_pattern='NA'),
    uan=PhoneNumberDesc(national_number_pattern='NA', possible_number_pattern='NA'),
    emergency=PhoneNumberDesc(national_number_pattern='1(?:12|[578])', possible_number_pattern='\\d{2,3}', example_number='15'),
    voicemail=PhoneNumberDesc(national_number_pattern='NA', possible_number_pattern='NA'),
    short_code=PhoneNumberDesc(national_number_pattern='NA', possible_number_pattern='NA'),
    standard_rate=PhoneNumberDesc(national_number_pattern='NA', possible_number_pattern='NA'),
    no_international_dialling=PhoneNumberDesc(national_number_pattern='NA', possible_number_pattern='NA'),
    national_prefix='0',
    national_prefix_for_parsing='0',
    number_format=[NumberFormat(pattern='(\\d{3})(\\d{2})(\\d{2})(\\d{2})', format='\\1 \\2 \\3 \\4', national_prefix_formatting_rule='0\\1')])


text:
package com.horowitz.mickey.common;

import java.awt.image.RenderedImage;
import java.io.File;
import java.io.IOException;
import java.util.Iterator;

import javax.imageio.IIOException;
import javax.imageio.ImageIO;
import javax.imageio.ImageTypeSpecifier;
import javax.imageio.ImageWriter;
import javax.imageio.stream.ImageOutputStream;

public class MyImageIO {

  private MyImageIO() {
  }

  private static ImageWriter getWriter(RenderedImage im, String formatName) {
    ImageTypeSpecifier type = ImageTypeSpecifier.createFromRenderedImage(im);
    Iterator<ImageWriter> iter = ImageIO.getImageWriters(type, formatName);

    if (iter.hasNext()) {
      return iter.next();
    } else {
      return null;
    }
  }

  public static boolean write(RenderedImage im, String formatName, File output) throws IOException {
    if (output == null) {
      throw new IllegalArgumentException("output == null!");
    }
    ImageOutputStream stream = null;

    ImageWriter writer = getWriter(im, formatName);
    if (writer == null) {
      /*
       * Do not make changes in the file system if we have no appropriate writer.
       */
      return false;
    }

    try {
      // output.delete();
      stream = ImageIO.createImageOutputStream(output);
    } catch (IOException e) {
      throw new IIOException("Can't create output stream!", e);
    }

    try {
      return doWrite(im, writer, stream);
    } finally {
      stream.close();
    }
  }

  private static boolean doWrite(RenderedImage im, ImageWriter writer, ImageOutputStream output) throws IOException {
    if (writer == null) {
      return false;
    }
    writer.setOutput(output);
    try {
      writer.write(im);
    } finally {
      writer.dispose();
      output.flush();
    }
    return true;
  }
}


text:
package mobilegateway

import (
	"context"

	"github.com/sacloud/libsacloud/v2/sacloud"
)

func (s *Service) DeleteSIMRoute(req *DeleteSIMRouteRequest) error {
	return s.DeleteSIMRouteWithContext(context.Background(), req)
}

func (s *Service) DeleteSIMRouteWithContext(ctx context.Context, req *DeleteSIMRouteRequest) error {
	if err := req.Validate(); err != nil {
		return err
	}

	client := sacloud.NewMobileGatewayOp(s.caller)
	routes, err := client.GetSIMRoutes(ctx, req.Zone, req.ID)
	if err != nil {
		return err
	}
	if err := routes.Delete(req.SIMID); err != nil {
		return err
	}

	return client.SetSIMRoutes(ctx, req.Zone, req.ID, routes.ToRequestParameter())
}


text:
Thymeleaf is released under the Apache 2.0 license. If you would like to
contribute something, or want to hack on the code this document should help you
get started.

## Code of Conduct

This project adheres to the Contributor Covenant
[code of conduct][code-of-coduct].
By participating, you are expected to uphold this code. Please report
unacceptable behavior to [the project leads][thymeleaf-team].

## Using GitHub Issues

We use GitHub issues to track bugs and enhancements.
If you have a general usage question please ask on
[Stack Overflow][stackoverflow].
The Thymeleaf team and the broader community monitor the
[`thymeleaf`][stackoverflow-thymeleaf] tag.

If you are reporting a bug, please help to speed up problem diagnosis by
providing as much information as possible.
Ideally, that would include a small sample project that reproduces the problem.

## Before submitting a Contribution

Before submitting a contribution that is not an obvious or trivial fix,
get in contact with the [the project leads][thymeleaf-team] about your
ideas (an email should do). Let us discuss the possibilities with you so that
we make sure your contribution goes in the right direction and aligns with the
project's standards, intentions and roadmap.

Please understand that *not all contributions will be accepted and merged into
the project's repositories*. Talking about your planned contributions with the
project maintainers before creating pull requests can maximize the possibility
of your contributions being accepted.

## Signing the Contributor License Agreement

Before we accept a non-trivial patch or pull request we will need you to
sign a **Contributor License Agreement**.

There are two versions of the CLA:

   * **Individual CLA**: For individuals acting on their own behalf, i.e. not
     being backed by any company or government, and not making their
     contributions potentially under the effect of any contracts, agreements or
     laws that could cause their employeer (or any other entities) claim
     any rights on their contribution.
   * **Corporate CLA**: For corporate entities allowing some of their employees
     to contribute to Thymeleaf on the entity's behalf.

For more information on the CLA and the (very easy) process involving this
step, please have a look at the [Thymeleaf CLA repository][cla].

## Conventions and Housekeeping

### General Guidelines:

  - Obviously, **your code must both compile and work correctly**.
  - All your code should be easy to read and understand by a human. The same
    requirement applies to documentation.
  - Unless for specific artifacts such as documentation translations, all
    code, comments, documentation, names of classes and variables,
    log messages, etc. must be **in English**.
  - All contribured files must include the standard Thymeleaf copyright header.
  - Maximum recommended line length is 120 characters. This is not strictly
    enforced.
  - Indentation should be made with 4 spaces, not tabs. Line feeds should be
    UNIX-like (`\n`).
  - All source files should be pure ASCII, except `.properties` files which
    should be ISO-8859-1.
  - You shall add yourself as _author_ (e.g. Javadoc `@author`) to any files
    that you create or modify substantially (more than cosmetic changes).

### Specific Java Code Gudelines:

  - All your code should compile and run in the current minimum Java version
    of the project.
  - All your code should follow the Java Code Conventions regarding
    variable/method/class naming.
  - Number autoboxing and/or autounboxing is forbidden.
  - Every class should define a constructor, even if it is the no-argument
    constructor, and include a call to `super()`.
  - All method parameters should be declared as `final` so that they cannot be
    changed or reassigned in the method.
  - All non-nullable parameters in public methods should be first validated for
    non-nullity inside the code.
  - Existing Javadoc must be maintained along with performed changes. Addition
    of new Javadoc for public methods or code comments for any non-trivial
    algorithms is always welcome.
  - Writing unit tests for new, existing and modified code is always welcome
    too. For any new algorithms or functionality contributed, or substantial
    modifications made to existing ones, the team might consider these a
    requirement.

[cla]: https://github.com/thymeleaf/thymeleaf-org/blob/CLA_CURRENT/CLA/
[code-of-coduct]: https://github.com/thymeleaf/thymeleaf-org/blob/CoC_CURRENT/CoC/THYMELEAF_CODE_OF_CONDUCT.markdown
[thymeleaf-team]: https://www.thymeleaf.org/team.html
[stackoverflow]: https://stackoverflow.com
[stackoverflow-thymeleaf]: https://stackoverflow.com/tags/thymeleaf


text:
using System;
using Microsoft.Xrm.Sdk;
using Microsoft.Xrm.Sdk.Query;

namespace PowerShellLibrary.Crm.CmdletProviders.Tests {
  public class TestOrganizationService : IOrganizationService {

    public Guid Create(Entity entity) {
      throw new NotImplementedException();
    }

    public Entity Retrieve(string entityName, Guid id, ColumnSet columnSet) {
      throw new NotImplementedException();
    }

    public void Update(Entity entity) {
      throw new NotImplementedException();
    }

    public void Delete(string entityName, Guid id) {
      throw new NotImplementedException();
    }

    public OrganizationResponse Execute(OrganizationRequest request) {
      throw new NotImplementedException();
    }

    public void Associate(string entityName, Guid entityId, Relationship relationship, EntityReferenceCollection relatedEntities) {
      throw new NotImplementedException();
    }

    public void Disassociate(string entityName, Guid entityId, Relationship relationship, EntityReferenceCollection relatedEntities) {
      throw new NotImplementedException();
    }

    public EntityCollection RetrieveMultiple(QueryBase query) {
      throw new NotImplementedException();
    }
  }
}


text:
/**
 * @flow
 */

import React from 'react';
import { StyleSheet, css } from 'aphrodite/no-important';
import SharedStyles from 'xde/ui/Styles';

type Event = {
  target: {
    value: string,
  },
};

type Props = {
  styles?: any,
  value?: ?string,
  valueTransformer?: (val: string) => string,
  autoFocus?: boolean,
};

type State = {
  value: string,
};

export default class TextInput extends React.Component {
  props: Props;
  state: State;

  constructor(props: Props) {
    super();
    this.state = {
      value: props.value || '',
    };
  }

  getValue() {
    return this.state.value.trim();
  }

  render() {
    const { styles: extraStyles, valueTransformer, ...inputProps } = this.props;

    return (
      <input
        className={css(styles.input, extraStyles)}
        {...inputProps}
        onChange={this._onValueChange}
        value={this.state.value}
      />
    );
  }

  _onValueChange = (e: Event) => {
    let value = e.target.value;
    if (this.props.valueTransformer) {
      value = this.props.valueTransformer(value);
    }
    this.setState({
      value,
    });
  };
}

const styles = StyleSheet.create({
  input: {
    ...SharedStyles.input,
    display: 'block',
  },
});


text:
package present

import (
	"errors"
	"html/template"
	"path/filepath"
	"strings"
)

func init() {
	Register("html", parseHTML)
}

type HTML struct {
	template.HTML
}

func (s *HTML) TemplateName() string { return "html" }

func parseHTML(ctx *Context, fileName string, lineno int, text string) (Elem, error) {
	p := strings.Fields(text)
	if len(p) != 2 {
		return nil, errors.New("invalid .html args")
	}
	name := filepath.Join(filepath.Dir(fileName), p[1])
	b, err := ctx.ReadFile(name)
	if err != nil {
		return nil, err
	}
	return &HTML{template.HTML(b)}, nil
}

func init() {
	RegisterUnmarshaler("html", unmarshalHTML)
}

func unmarshalHTML(data []byte, worker UnmarshalWork) (Elem, error) {
	var ep struct {
		Inner *HTML
		Type  string
	}
	err := worker(data, &ep)
	if err != nil {
		return nil, err
	}
	return ep.Inner, nil
}


text:
package com.magicalboy.artchecker;

import android.app.Activity;
import android.app.AlertDialog;
import android.os.Build;
import android.os.Bundle;
import android.view.Menu;
import android.view.MenuItem;
import android.view.View;
import android.widget.TextView;

import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;

public class MainActivity extends Activity {
    private static final String SELECT_RUNTIME_PROPERTY = "persist.sys.dalvik.vm.lib";
    private static final String LIB_DALVIK = "libdvm.so";
    private static final String LIB_ART = "libart.so";
    private static final String LIB_ART_D = "libartd.so";

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);

        TextView tv = (TextView)findViewById(R.id.current_runtime_value);

        int currentAPIVersion = android.os.Build.VERSION.SDK_INT;
        String myVersion = android.os.Build.VERSION.RELEASE;

        String resultText;

        if (currentAPIVersion > Build.VERSION_CODES.KITKAT) {
            // Lollipop and above versions
            resultText = "Your device currently running ART.";
        } else{
            // do something for phones running an SDK before lollipop
            resultText = "Your device currently running " + getCurrentRuntimeValue() + ".";
        }

        resultText += "\n\nAndroid " + myVersion + "\nAPI level is " + currentAPIVersion +
        "\nVM version is " + getVMVersion() + ".";

        tv.setText(resultText);
    }

    /**
     * http://stackoverflow.com/a/19831208
     * @return
     */
    private CharSequence getCurrentRuntimeValue() {
        try {
            Class<?> systemProperties = Class.forName("android.os.SystemProperties");
            try {
                Method get = systemProperties.getMethod("get",
                   String.class, String.class);
                if (get == null) {
                    return "WTF?!";
                }
                try {
                    final String value = (String)get.invoke(
                        systemProperties, SELECT_RUNTIME_PROPERTY,
                        /* Assuming default is */"Dalvik");
                    if (LIB_DALVIK.equals(value)) {
                        return "Dalvik";
                    } else if (LIB_ART.equals(value)) {
                        return "ART";
                    } else if (LIB_ART_D.equals(value)) {
                        return "ART debug build";
                    }

                    return value;
                } catch (IllegalAccessException e) {
                    return "IllegalAccessException";
                } catch (IllegalArgumentException e) {
                    return "IllegalArgumentException";
                } catch (InvocationTargetException e) {
                    return "InvocationTargetException";
                }
            } catch (NoSuchMethodException e) {
                return "SystemProperties.get(String key, String def) method is not found";
            }
        } catch (ClassNotFoundException e) {
            return "SystemProperties class is not found";
        }
    }

    /**
     * get VM version
     * @return
     */
    private final String getVMVersion() {
        final String vmVersion = System.getProperty("java.vm.version");
        return vmVersion;
    }

    protected void showAbout() {
        // Inflate the about message contents
        View messageView = getLayoutInflater().inflate(R.layout.about, null, false);

        // When linking text, force to always use default color. This works
        // around a pressed color state bug.
        TextView textView = (TextView) messageView.findViewById(R.id.about_credits);
        int defaultColor = textView.getTextColors().getDefaultColor();
        textView.setTextColor(defaultColor);

        AlertDialog.Builder builder = new AlertDialog.Builder(this);
        builder.setIcon(R.drawable.ic_launcher);
        builder.setTitle(getString(R.string.app_name) + " v1.1");
        builder.setView(messageView);
        builder.create();
        builder.show();
    }

    @Override
    public boolean onCreateOptionsMenu(Menu menu) {
        // Inflate the menu; this adds items to the action bar if it is present.
        getMenuInflater().inflate(R.menu.main, menu);
        return true;
    }

    @Override
    public boolean onOptionsItemSelected(MenuItem item) {
        // Handle action bar item clicks here. The action bar will
        // automatically handle clicks on the Home/Up button, so long
        // as you specify a parent activity in AndroidManifest.xml.
        int id = item.getItemId();

        //noinspection SimplifiableIfStatement
        if (id == R.id.action_about) {
            showAbout();
            return true;
        }

        return super.onOptionsItemSelected(item);
    }
}


text:
const webpack = require('webpack')
const merge = require('webpack-merge')
const HtmlWebpackPlugin = require('html-webpack-plugin')
const CopyWebpackPlugin = require('copy-webpack-plugin')

const { debug, dist, entry, resolve, template, test } = require('./config')

const options = {
    entry,
    output: {
        path: dist,
        publicPath: '/'
    },
    resolve: {
        modules: ['node_modules', 'src'],
        extensions: ['.js', '.jsx', '.styl'],
        alias: {
            service: resolve('src/js/service/'),
            libs: resolve('src/js/libs/'),
            apps: resolve('src/js/apps/'),
            components: resolve('src/js/components/'),
            stylus: resolve('src/stylus/')
        }
    },
    module: {
        rules: [{
            test: /\.jsx?$/,
            exclude: [/node_modules/, /dist/],
            use: ['react-hot-loader/webpack', 'babel-loader']
        }, {
            test: /\.styl$/,
            exclude: [/node_modules/, /dist/],
            use: ['style-loader', 'css-loader', 'stylus-loader']
        },{
            test   : /\.(ttf|eot|svg|woff(2)?)(\?[a-z0-9=&.]+)?$/,
            exclude: [/node_modules/, /dist/],
            use : ['file-loader']
        }]
    },
    plugins: [
        new webpack.DefinePlugin({
            'process.env': {
                NODE_ENV: JSON.stringify(process.env.NODE_ENV),
                GOOGLE_KEY: JSON.stringify(process.env.GOOGLE_KEY),
                GOOGLE_SENDER: JSON.stringify(process.env.GOOGLE_SENDER),
            },
        }),
        new HtmlWebpackPlugin({
            template,
            filename: 'index.html',
            inject: 'body'
        }),
        new CopyWebpackPlugin([{
            from: resolve('src/assets'),
            to: './'
        }])
    ]
}

module.exports = test ?
    merge(options, require('./webpack.test')) : debug ?
        merge(options, require('./webpack.dev')) :
        merge(options, require('./webpack.dist'))


text: * changed background & basic text colors


text:
using Newtonsoft.Json;
namespace Qiniu.Storage
{
    /// <summary>
    /// 批量处理返回的信息
    /// </summary>
    public class BatchInfo
    {
        /// <summary>
        /// 状态码
        /// </summary>
        [JsonProperty("code",NullValueHandling=NullValueHandling.Ignore)]
        public int Code { get; set; }

        /// <summary>
        /// 消息
        /// </summary>
        [JsonProperty("data",NullValueHandling=NullValueHandling.Ignore)]
        public BatchData Data { get; set; }
    }

    /// <summary>
    /// 批量处理的结果内容
    /// </summary>
    public class BatchData
    {
        /// <summary>
        /// 处理遇到的错误信息
        /// </summary>
        [JsonProperty("error", NullValueHandling = NullValueHandling.Ignore)]
        public string Error { get; set; }

        /// <summary>
        /// 文件hash(ETAG)
        /// </summary>
        [JsonProperty("hash", NullValueHandling = NullValueHandling.Ignore)]
        public string Hash { get; set; }

        /// <summary>
        /// 文件大小(字节)
        /// </summary>
        [JsonProperty("fsize", NullValueHandling = NullValueHandling.Ignore)]
        public long Fsize { get; set; }

        /// <summary>
        /// 文件MIME类型
        /// </summary>
        [JsonProperty("mimeType", NullValueHandling = NullValueHandling.Ignore)]
        public string MimeType { get; set; }

        /// <summary>
        /// 上传时间
        /// </summary>
        [JsonProperty("putTime", NullValueHandling = NullValueHandling.Ignore)]
        public long PutTime { get; set; }

        /// <summary>
        /// 文件存储类型
        /// </summary>
        [JsonProperty("type", NullValueHandling = NullValueHandling.Ignore)]
        public int FileType { get; set; }
    }
}