jdk/test/javax/sql/testng/util/StubRowSetFactory.java
author sundar
Mon, 16 May 2016 14:50:43 +0530
changeset 37951 ce2744a0f1a7
parent 26959 c8b54474e672
permissions -rw-r--r--
8156914: jlink API minor cleanups Reviewed-by: mchung
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
26959
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
     1
/*
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
     2
 * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved.
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
     3
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
     4
 *
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
     5
 * This code is free software; you can redistribute it and/or modify it
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
     6
 * under the terms of the GNU General Public License version 2 only, as
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
     7
 * published by the Free Software Foundation.
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
     8
 *
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
     9
 * This code is distributed in the hope that it will be useful, but WITHOUT
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    10
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    11
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    12
 * version 2 for more details (a copy is included in the LICENSE file that
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    13
 * accompanied this code).
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    14
 *
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    15
 * You should have received a copy of the GNU General Public License version
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    16
 * 2 along with this work; if not, write to the Free Software Foundation,
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    17
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    18
 *
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    19
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    20
 * or visit www.oracle.com if you need additional information or have any
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    21
 * questions.
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    22
 */
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    23
package util;
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    24
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    25
import java.sql.SQLException;
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    26
import javax.sql.rowset.CachedRowSet;
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    27
import javax.sql.rowset.FilteredRowSet;
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    28
import javax.sql.rowset.JdbcRowSet;
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    29
import javax.sql.rowset.JoinRowSet;
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    30
import javax.sql.rowset.RowSetFactory;
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    31
import javax.sql.rowset.WebRowSet;
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    32
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    33
public class StubRowSetFactory implements RowSetFactory {
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    34
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    35
    @Override
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    36
    public CachedRowSet createCachedRowSet() throws SQLException {
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    37
        return new StubCachedRowSetImpl();
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    38
    }
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    39
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    40
    @Override
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    41
    public FilteredRowSet createFilteredRowSet() throws SQLException {
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    42
        return new StubFilteredRowSetImpl();
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    43
    }
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    44
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    45
    @Override
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    46
    public JdbcRowSet createJdbcRowSet() throws SQLException {
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    47
        return new StubJdbcRowSetImpl();
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    48
    }
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    49
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    50
    @Override
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    51
    public JoinRowSet createJoinRowSet() throws SQLException {
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    52
        return new StubJoinRowSetImpl();
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    53
    }
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    54
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    55
    @Override
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    56
    public WebRowSet createWebRowSet() throws SQLException {
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    57
        return new StubWebRowSetImpl();
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    58
    }
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    59
c8b54474e672 8059570: Addition of tests for RowSetFactory and RowSetProvider
lancea
parents:
diff changeset
    60
}