merge the formfield patch from ooo-build
[ooovba.git] / autodoc / source / ary / idl / i_sisingleton.cxx
blob8885458b6eb9ac80bc1c341f6aaf4da884c233c6
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: i_sisingleton.cxx,v $
10 * $Revision: 1.7 $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
31 #include <precomp.h>
32 #include <ary/idl/i_sisingleton.hxx>
35 // NOT FULLY DECLARED SERVICES
36 #include <cosv/tpl/processor.hxx>
37 #include <ary/idl/ik_sisingleton.hxx>
41 namespace ary
43 namespace idl
46 SglIfcSingleton::SglIfcSingleton( const String & i_sName,
47 Ce_id i_nOwner,
48 Type_id i_nBaseInterface )
49 : sName(i_sName),
50 nOwner(i_nOwner),
51 nBaseInterface(i_nBaseInterface)
55 SglIfcSingleton::~SglIfcSingleton()
59 void
60 SglIfcSingleton::do_Accept( csv::ProcessorIfc & io_processor ) const
62 csv::CheckedCall(io_processor, *this);
65 ClassId
66 SglIfcSingleton::get_AryClass() const
68 return class_id;
71 const String &
72 SglIfcSingleton::inq_LocalName() const
74 return sName;
77 Ce_id
78 SglIfcSingleton::inq_NameRoom() const
80 return nOwner;
83 Ce_id
84 SglIfcSingleton::inq_Owner() const
86 return nOwner;
89 E_SightLevel
90 SglIfcSingleton::inq_SightLevel() const
92 return sl_File;
95 namespace ifc_sglifcsingleton
98 inline const SglIfcSingleton &
99 sglifcsingleton_cast( const CodeEntity & i_ce )
101 csv_assert( i_ce.AryClass() == SglIfcSingleton::class_id );
102 return static_cast< const SglIfcSingleton& >(i_ce);
105 Type_id
106 attr::BaseInterface( const CodeEntity & i_ce )
108 return sglifcsingleton_cast(i_ce).nBaseInterface;
112 } // namespace ifc_sglifcsingleton
115 } // namespace idl
116 } // namespace ary