Comment:

    DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.

    Copyright (c) 1997-2013 Oracle and/or its affiliates. All rights reserved.

    The contents of this file are subject to the terms of either the GNU
    General Public License Version 2 only ("GPL") or the Common Development
    and Distribution License("CDDL") (collectively, the "License").  You
    may not use this file except in compliance with the License.  You can
    obtain a copy of the License at
    https://glassfish.dev.java.net/public/CDDL+GPL_1_1.html
    or packager/legal/LICENSE.txt.  See the License for the specific
    language governing permissions and limitations under the License.

    When distributing the software, include this License Header Notice in each
    file and include the License file at packager/legal/LICENSE.txt.

    GPL Classpath Exception:
    Oracle designates this particular file as subject to the "Classpath"
    exception as provided by Oracle in the GPL Version 2 section of the License
    file that accompanied this code.

    Modifications:
    If applicable, add the following below the License Header, with the fields
    enclosed by brackets [] replaced by your own identifying information:
    "Portions Copyright [year] [name of copyright owner]"

    Contributor(s):
    If you wish your version of this file to be governed by only the CDDL or
    only the GPL Version 2, indicate your decision by adding "[Contributor]
    elects to include this software in this distribution under the [CDDL or GPL
    Version 2] license."  If you don't indicate a single choice of license, a
    recipient has the option to distribute your version of this file under
    either the CDDL, the GPL Version 2 or to extend the choice of license to
    its licensees as provided above.  However, if you add GPL Version 2 code
    and therefore, elected the GPL Version 2 license, then the option applies
    only if the new code is made subject to such option by the copyright
    holder.

Comment:

        A set of test headers to test parameter list parsing and
	especially RFC 2231 decoding.
        Use with "paramtest -p <paramdata".

	All tests assume "mail.mime.decodeparameters" is set to "true",
	which is done at the start of paramtest.

        CAREFUL: a blank line in this file causes everything following it
                 to be ignored until a line starting with "From " (so that
                 paramtest -p can be pointed at a real mailbox).

From start here
Comment:
	This set of headers are all good and test RFC 2231 decoding.
Content-Type: application/x-stuff;
	title*0*=us-ascii'en'This%20is%20even%20more%20;
	title*1*=%2A%2A%2Afun%2A%2A%2A%20;
	title*2="isn't it!"
Expect: 1
	title=This is even more ***fun*** isn't it!
Content-Type: application/x-stuff;
	title*0*=''This%20is%20even%20more%20;
	title*1*=%2A%2A%2Afun%2A%2A%2A%20;
	title*2="isn't it!"
Expect: 1
	title=This is even more ***fun*** isn't it!
Content-Type: application/x-stuff;
	title*2="isn't it!";
	title*1*=%2A%2A%2Afun%2A%2A%2A%20;
	title*0*=us-ascii'en'This%20is%20even%20more%20
Expect: 1
	title=This is even more ***fun*** isn't it!
Content-Type: application/x-stuff;
	title*2="isn't it!";
	title*1*=%2A%2A%2Afun%2A%2A%2A%20;
	title*0*=us-ascii'en'This%20is%20even%20more%20;
	name*0="one ";
	name*1="two ";
	name*2="three";
	p*=us-ascii'en'This%20is%20fun;
Expect: 3
	title=This is even more ***fun*** isn't it!
	name=one two three
	p=This is fun
Content-Type: application/x-stuff;
	title*2="isn't it!";
	title*1*=%2A%2A%2Afun%2A%2A%2A%20;
	title*0*=us-ascii'en'This%20is%20even%20more%20;
	name*0="one ";
	name*1="two ";
	name*2="three";
	p*=us-ascii'en'This%20is%20fun
Expect: 3
	title=This is even more ***fun*** isn't it!
	name=one two three
	p=This is fun
Content-Type: application/x-stuff;
	title*2="isn't it!";
	name*1="two ";
	title*1*=%2A%2A%2Afun%2A%2A%2A%20;
	name*0="one ";
	title*0*=us-ascii'en'This%20is%20even%20more%20;
	name*2="three";
	p*=us-ascii'en'This%20is%20fun
Expect: 3
	title=This is even more ***fun*** isn't it!
	name=one two three
	p=This is fun
Comment:
	These headers test error cases that don't generate parse exceptions.
	.
Content-Type: application/x-stuff;
	title*0*=us-ascii'en'This%20is%20even%20more%20;
	title*1*=%2A%2A%2Afun%2A%2A%2A;
	title*3="isn't it!"
Expect: 2
	title=This is even more ***fun***
	title*3=isn't it!
Content-Type: application/x-stuff;
	title*0*=us-ascii'en'This%20is%20even%20more%20;
	title*1*=%2A%2A%2Afun%2A%2A%2A;
	title*3*="isn't it!"
Expect: 2
	title=This is even more ***fun***
	title*3=isn't it!
Comment:
	This is an error case with no right answer.
	Should we assume earlier segments are missing and just decode
	this segment?  Or should we assume that the "*3" is part of
	the parameter name and this is a single segment encoded parameter?
	Currently we do the former.
Content-Type: application/x-stuff; title*3*=us-ascii'en'isn't%20it!
Expect: 1
	title*3=us-ascii'en'isn't it!
Content-Type: application/x-stuff; title*3*=unknown'en'isn't%20it!
Expect: 1
	title*3=unknown'en'isn't it!
Content-Type: application/x-stuff;
	title*0*=us-ascii'en'This%20is%20even%20more%20;
	title*1*=%XX%2A%2Afun%2A%2A%2A%20;
	title*2="isn't it!"
Expect: 1
	title=This is even more %XX**fun*** isn't it!
Content-Type: application/x-stuff;
	title*0*=us-ascii'en'This%20is%20even%20more%20;
	title*1="***fun***";
	title*2*=%20isn't%20it!
Expect: 1
	title=This is even more ***fun*** isn't it!
Content-Type: image/png;
	name*0*=ISO-2022-JP''%1B%24B%24%22%24%24%24%26%24%28%24*%24%22%24%24%24%26;
	name*1*=%24%28%24*%24%22%24%24%24%26%24%28%24*%24%22%24%24%24%26%24%28;
	name*2*=%24*%1B%28B.png
Expect: 1
	name=\u3042\u3044\u3046\u3048\u304a\u3042\u3044\u3046\u3048\u304a\u3042\u3044\u3046\u3048\u304a\u3042\u3044\u3046\u3048\u304a.png
Content-Type: image/png;
	filename*0*=ISO-2022-JP''%1B%24B%24%22%24%24%24%26%24%28%24*%24%22%24%24;
	filename*1*=%24%26%24%28%24*%24%22%24%24%24%26%24%28%24*%24%22%24%24%24;
	filename*2*=%26%24%28%24*%1B%28B.png
Expect: 1
	filename=\u3042\u3044\u3046\u3048\u304a\u3042\u3044\u3046\u3048\u304a\u3042\u3044\u3046\u3048\u304a\u3042\u3044\u3046\u3048\u304a.png
