446N/A/*
4744N/A * Copyright (c) 2009, Oracle and/or its affiliates. All rights reserved.
446N/A * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
446N/A *
446N/A * This code is free software; you can redistribute it and/or modify it
446N/A * under the terms of the GNU General Public License version 2 only, as
446N/A * published by the Free Software Foundation.
446N/A *
446N/A * This code is distributed in the hope that it will be useful, but WITHOUT
446N/A * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
6982N/A * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
6982N/A * version 2 for more details (a copy is included in the LICENSE file that
446N/A * accompanied this code).
446N/A *
446N/A * You should have received a copy of the GNU General Public License version
446N/A * 2 along with this work; if not, write to the Free Software Foundation,
6982N/A * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
6982N/A *
6982N/A * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
6982N/A * or visit www.oracle.com if you need additional information or have any
446N/A * questions.
446N/A */
446N/A
446N/A/*
5073N/A * @test
5508N/A * @bug 6777487
446N/A * @summary Tests private field access for CheckedCollection
446N/A * @author Sergey Malenkov
446N/A */
4744N/A
4744N/Aimport java.util.ArrayList;
4744N/Aimport java.util.Collections;
4744N/Aimport java.util.List;
4744N/A
4744N/Apublic final class TestCheckedCollection {
4744N/A private static final Object OBJECT = new Object();
4744N/A
4744N/A public static void main(String[] args) {
4744N/A List<String> list = Collections.emptyList();
4744N/A TestEncoder.test(
4744N/A Collections.checkedCollection(list, String.class),
4744N/A new ArrayList() {
4744N/A private final Object type = OBJECT;
4744N/A },
4744N/A OBJECT
4744N/A );
4744N/A }
4744N/A}
4744N/A