xref: /aoo41x/main/ucb/source/ucp/gio/gio_resultset.cxx (revision 2f86921c)
1*2f86921cSAndrew Rist /**************************************************************
2cdf0e10cSrcweir  *
3*2f86921cSAndrew Rist  * Licensed to the Apache Software Foundation (ASF) under one
4*2f86921cSAndrew Rist  * or more contributor license agreements.  See the NOTICE file
5*2f86921cSAndrew Rist  * distributed with this work for additional information
6*2f86921cSAndrew Rist  * regarding copyright ownership.  The ASF licenses this file
7*2f86921cSAndrew Rist  * to you under the Apache License, Version 2.0 (the
8*2f86921cSAndrew Rist  * "License"); you may not use this file except in compliance
9*2f86921cSAndrew Rist  * with the License.  You may obtain a copy of the License at
10*2f86921cSAndrew Rist  *
11*2f86921cSAndrew Rist  *   http://www.apache.org/licenses/LICENSE-2.0
12*2f86921cSAndrew Rist  *
13*2f86921cSAndrew Rist  * Unless required by applicable law or agreed to in writing,
14*2f86921cSAndrew Rist  * software distributed under the License is distributed on an
15*2f86921cSAndrew Rist  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16*2f86921cSAndrew Rist  * KIND, either express or implied.  See the License for the
17*2f86921cSAndrew Rist  * specific language governing permissions and limitations
18*2f86921cSAndrew Rist  * under the License.
19*2f86921cSAndrew Rist  *
20*2f86921cSAndrew Rist  *************************************************************/
21*2f86921cSAndrew Rist 
22*2f86921cSAndrew Rist 
23cdf0e10cSrcweir 
24cdf0e10cSrcweir #include "gio_datasupplier.hxx"
25cdf0e10cSrcweir #include "gio_resultset.hxx"
26cdf0e10cSrcweir 
27cdf0e10cSrcweir using namespace com::sun::star::lang;
28cdf0e10cSrcweir using namespace com::sun::star::ucb;
29cdf0e10cSrcweir using namespace com::sun::star::uno;
30cdf0e10cSrcweir 
31cdf0e10cSrcweir using namespace gio;
32cdf0e10cSrcweir 
DynamicResultSet(const Reference<XMultiServiceFactory> & rxSMgr,const Reference<Content> & rxContent,const OpenCommandArgument2 & rCommand,const Reference<XCommandEnvironment> & rxEnv)33cdf0e10cSrcweir DynamicResultSet::DynamicResultSet(
34cdf0e10cSrcweir     const Reference< XMultiServiceFactory >& rxSMgr,
35cdf0e10cSrcweir     const Reference< Content >& rxContent,
36cdf0e10cSrcweir     const OpenCommandArgument2& rCommand,
37cdf0e10cSrcweir     const Reference< XCommandEnvironment >& rxEnv )
38cdf0e10cSrcweir     : ResultSetImplHelper( rxSMgr, rCommand ),
39cdf0e10cSrcweir       m_xContent( rxContent ),
40cdf0e10cSrcweir       m_xEnv( rxEnv )
41cdf0e10cSrcweir {
42cdf0e10cSrcweir }
43cdf0e10cSrcweir 
initStatic()44cdf0e10cSrcweir void DynamicResultSet::initStatic()
45cdf0e10cSrcweir {
46cdf0e10cSrcweir     m_xResultSet1 = new ::ucbhelper::ResultSet(
47cdf0e10cSrcweir         m_xSMgr, m_aCommand.Properties,
48cdf0e10cSrcweir         new DataSupplier( m_xSMgr, m_xContent, m_aCommand.Mode ), m_xEnv );
49cdf0e10cSrcweir }
50cdf0e10cSrcweir 
initDynamic()51cdf0e10cSrcweir void DynamicResultSet::initDynamic()
52cdf0e10cSrcweir {
53cdf0e10cSrcweir     initStatic();
54cdf0e10cSrcweir     m_xResultSet2 = m_xResultSet1;
55cdf0e10cSrcweir }
56