masterfix DEV300: #i10000# build fix
[LibreOffice.git] / extensions / source / propctrlr / xsdvalidationpropertyhandler.hxx
blobe78a33096b32024ee319a679c66fa92610c03576
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * Copyright 2000, 2010 Oracle and/or its affiliates.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * This file is part of OpenOffice.org.
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.
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).
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.
26 ************************************************************************/
28 #ifndef EXTENSIONS_SOURCE_PROPCTRLR_XSDVALIDATIONPROPERTYHANDLER_HXX
29 #define EXTENSIONS_SOURCE_PROPCTRLR_XSDVALIDATIONPROPERTYHANDLER_HXX
31 #include "propertyhandler.hxx"
33 /** === begin UNO includes === **/
34 /** === end UNO includes === **/
36 #include <memory>
38 //........................................................................
39 namespace pcr
41 //........................................................................
43 class XSDValidationHelper;
44 //====================================================================
45 //= XSDValidationPropertyHandler
46 //====================================================================
47 class XSDValidationPropertyHandler;
48 typedef HandlerComponentBase< XSDValidationPropertyHandler > XSDValidationPropertyHandler_Base;
49 class XSDValidationPropertyHandler : public XSDValidationPropertyHandler_Base
51 private:
52 ::std::auto_ptr< XSDValidationHelper > m_pHelper;
54 public:
55 XSDValidationPropertyHandler(
56 const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& _rxContext
59 static ::rtl::OUString SAL_CALL getImplementationName_static( ) throw (::com::sun::star::uno::RuntimeException);
60 static ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames_static( ) throw (::com::sun::star::uno::RuntimeException);
62 protected:
63 ~XSDValidationPropertyHandler();
65 protected:
66 // XPropertyHandler overriables
67 virtual ::com::sun::star::uno::Any SAL_CALL getPropertyValue( const ::rtl::OUString& _rPropertyName ) throw (::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::uno::RuntimeException);
68 virtual void SAL_CALL setPropertyValue( const ::rtl::OUString& _rPropertyName, const ::com::sun::star::uno::Any& _rValue ) throw (::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::uno::RuntimeException);
69 virtual ::com::sun::star::uno::Sequence< ::rtl::OUString >
70 SAL_CALL getSupersededProperties( ) throw (::com::sun::star::uno::RuntimeException);
71 virtual ::com::sun::star::uno::Sequence< ::rtl::OUString >
72 SAL_CALL getActuatingProperties( ) throw (::com::sun::star::uno::RuntimeException);
73 virtual ::com::sun::star::inspection::LineDescriptor
74 SAL_CALL describePropertyLine( const ::rtl::OUString& _rPropertyName, const ::com::sun::star::uno::Reference< ::com::sun::star::inspection::XPropertyControlFactory >& _rxControlFactory ) throw (::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::NullPointerException, ::com::sun::star::uno::RuntimeException);
75 virtual ::com::sun::star::inspection::InteractiveSelectionResult
76 SAL_CALL onInteractivePropertySelection( const ::rtl::OUString& _rPropertyName, sal_Bool _bPrimary, ::com::sun::star::uno::Any& _rData, const ::com::sun::star::uno::Reference< ::com::sun::star::inspection::XObjectInspectorUI >& _rxInspectorUI ) throw (::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::NullPointerException, ::com::sun::star::uno::RuntimeException);
77 virtual void SAL_CALL actuatingPropertyChanged( const ::rtl::OUString& _rActuatingPropertyName, const ::com::sun::star::uno::Any& _rNewValue, const ::com::sun::star::uno::Any& _rOldValue, const ::com::sun::star::uno::Reference< ::com::sun::star::inspection::XObjectInspectorUI >& _rxInspectorUI, sal_Bool ) throw (::com::sun::star::lang::NullPointerException, ::com::sun::star::uno::RuntimeException);
78 virtual void SAL_CALL addPropertyChangeListener( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertyChangeListener >& _rxListener ) throw (::com::sun::star::uno::RuntimeException);
79 virtual void SAL_CALL removePropertyChangeListener( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertyChangeListener >& _rxListener ) throw (::com::sun::star::uno::RuntimeException);
81 // PropertyHandler overridables
82 virtual ::com::sun::star::uno::Sequence< ::com::sun::star::beans::Property >
83 SAL_CALL doDescribeSupportedProperties() const;
84 virtual void onNewComponent();
86 private:
87 bool implPrepareRemoveCurrentDataType() SAL_THROW(());
88 bool implDoRemoveCurrentDataType() SAL_THROW(());
90 bool implPrepareCloneDataCurrentType( ::rtl::OUString& _rNewName ) SAL_THROW(());
91 bool implDoCloneCurrentDataType( const ::rtl::OUString& _rNewName ) SAL_THROW(());
93 /** retrieves the names of the data types which our introspectee can be validated against
95 void implGetAvailableDataTypeNames( ::std::vector< ::rtl::OUString >& /* [out] */ _rNames ) const SAL_THROW(());
98 //........................................................................
99 } // namespace pcr
100 //........................................................................
102 #endif // EXTENSIONS_SOURCE_PROPCTRLR_XSDVALIDATIONPROPERTYHANDLER_HXX