1 /************************************************************************* 2 * 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * Copyright 2000, 2010 Oracle and/or its affiliates. 6 * 7 * OpenOffice.org - a multi-platform office productivity suite 8 * 9 * This file is part of OpenOffice.org. 10 * 11 * OpenOffice.org is free software: you can redistribute it and/or modify 12 * it under the terms of the GNU Lesser General Public License version 3 13 * only, as published by the Free Software Foundation. 14 * 15 * OpenOffice.org is distributed in the hope that it will be useful, 16 * but WITHOUT ANY WARRANTY; without even the implied warranty of 17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18 * GNU Lesser General Public License version 3 for more details 19 * (a copy is included in the LICENSE file that accompanied this code). 20 * 21 * You should have received a copy of the GNU Lesser General Public License 22 * version 3 along with OpenOffice.org. If not, see 23 * <http://www.openoffice.org/license.html> 24 * for a copy of the LGPLv3 License. 25 * 26 ************************************************************************/ 27 28 #ifndef _FIXEDVALUEBACKEND_HXX_ 29 #define _FIXEDVALUEBACKEND_HXX_ 30 31 #include <com/sun/star/beans/Optional.hpp> 32 #include <com/sun/star/beans/XPropertySet.hpp> 33 #include <com/sun/star/lang/XServiceInfo.hpp> 34 #include <cppuhelper/implbase2.hxx> 35 #include <rtl/string.hxx> 36 37 namespace css = com::sun::star ; 38 namespace uno = css::uno ; 39 namespace lang = css::lang ; 40 41 class WinInetBackend : public ::cppu::WeakImplHelper2 < 42 css::beans::XPropertySet, 43 lang::XServiceInfo > { 44 45 public : 46 47 static WinInetBackend* createInstance(); 48 49 // XServiceInfo 50 virtual rtl::OUString SAL_CALL 51 getImplementationName( ) 52 throw (uno::RuntimeException) ; 53 54 virtual sal_Bool SAL_CALL 55 supportsService( const rtl::OUString& aServiceName ) 56 throw (uno::RuntimeException) ; 57 58 virtual uno::Sequence<rtl::OUString> SAL_CALL 59 getSupportedServiceNames( ) 60 throw (uno::RuntimeException) ; 61 62 /** 63 Provides the implementation name. 64 65 @return implementation name 66 */ 67 static rtl::OUString SAL_CALL getBackendName(void) ; 68 /** 69 Provides the supported services names 70 71 @return service names 72 */ 73 static uno::Sequence<rtl::OUString> SAL_CALL getBackendServiceNames(void) ; 74 75 // XPropertySet 76 virtual css::uno::Reference< css::beans::XPropertySetInfo > SAL_CALL 77 getPropertySetInfo() throw (css::uno::RuntimeException) 78 { return css::uno::Reference< css::beans::XPropertySetInfo >(); } 79 80 virtual void SAL_CALL setPropertyValue( 81 rtl::OUString const &, css::uno::Any const &) 82 throw ( 83 css::beans::UnknownPropertyException, 84 css::beans::PropertyVetoException, 85 css::lang::IllegalArgumentException, 86 css::lang::WrappedTargetException, css::uno::RuntimeException); 87 88 virtual css::uno::Any SAL_CALL getPropertyValue( 89 rtl::OUString const & PropertyName) 90 throw ( 91 css::beans::UnknownPropertyException, 92 css::lang::WrappedTargetException, css::uno::RuntimeException); 93 94 virtual void SAL_CALL addPropertyChangeListener( 95 rtl::OUString const &, 96 css::uno::Reference< css::beans::XPropertyChangeListener > const &) 97 throw ( 98 css::beans::UnknownPropertyException, 99 css::lang::WrappedTargetException, css::uno::RuntimeException) 100 {} 101 102 virtual void SAL_CALL removePropertyChangeListener( 103 rtl::OUString const &, 104 css::uno::Reference< css::beans::XPropertyChangeListener > const &) 105 throw ( 106 css::beans::UnknownPropertyException, 107 css::lang::WrappedTargetException, css::uno::RuntimeException) 108 {} 109 110 virtual void SAL_CALL addVetoableChangeListener( 111 rtl::OUString const &, 112 css::uno::Reference< css::beans::XVetoableChangeListener > const &) 113 throw ( 114 css::beans::UnknownPropertyException, 115 css::lang::WrappedTargetException, css::uno::RuntimeException) 116 {} 117 118 virtual void SAL_CALL removeVetoableChangeListener( 119 rtl::OUString const &, 120 css::uno::Reference< css::beans::XVetoableChangeListener > const &) 121 throw ( 122 css::beans::UnknownPropertyException, 123 css::lang::WrappedTargetException, css::uno::RuntimeException) 124 {} 125 126 protected: 127 /** 128 Service constructor from a service factory. 129 130 @param xContext component context 131 */ 132 WinInetBackend(); 133 134 /** Destructor */ 135 ~WinInetBackend(void) ; 136 137 private: 138 com::sun::star::beans::Optional< com::sun::star::uno::Any > 139 valueProxyType_; 140 com::sun::star::beans::Optional< com::sun::star::uno::Any > 141 valueNoProxy_; 142 com::sun::star::beans::Optional< com::sun::star::uno::Any > 143 valueHttpProxyName_; 144 com::sun::star::beans::Optional< com::sun::star::uno::Any > 145 valueHttpProxyPort_; 146 com::sun::star::beans::Optional< com::sun::star::uno::Any > 147 valueHttpsProxyName_; 148 com::sun::star::beans::Optional< com::sun::star::uno::Any > 149 valueHttpsProxyPort_; 150 com::sun::star::beans::Optional< com::sun::star::uno::Any > 151 valueFtpProxyName_; 152 com::sun::star::beans::Optional< com::sun::star::uno::Any > 153 valueFtpProxyPort_; 154 } ; 155 156 157 #endif // _FIXEDVALUEBACKEND_HXX_ 158