Kaydet (Commit) 93ca2247 authored tarafından Noel Grandin's avatar Noel Grandin Kaydeden (comit) Noel Grandin

com::sun::star->css in xmlscript/

Change-Id: I8ead2862ef429a0ac3fc16fe6ca5dfc9e5f549bc
Reviewed-on: https://gerrit.libreoffice.org/20193Reviewed-by: 's avatarNoel Grandin <noelgrandin@gmail.com>
Tested-by: 's avatarNoel Grandin <noelgrandin@gmail.com>
üst fa17cfd7
...@@ -26,19 +26,19 @@ namespace xmlscript ...@@ -26,19 +26,19 @@ namespace xmlscript
{ {
template< typename T > template< typename T >
inline void extract_throw( T * p, ::com::sun::star::uno::Any const & a ) inline void extract_throw( T * p, css::uno::Any const & a )
{ {
if (! (a >>= *p)) if (! (a >>= *p))
{ {
throw ::com::sun::star::uno::RuntimeException( throw css::uno::RuntimeException(
"expected " + cppu::UnoType<T>::get().getTypeName(), "expected " + cppu::UnoType<T>::get().getTypeName(),
::com::sun::star::uno::Reference< css::uno::Reference<
::com::sun::star::uno::XInterface>() ); css::uno::XInterface>() );
} }
} }
template< typename T > template< typename T >
inline T extract_throw( ::com::sun::star::uno::Any const & a ) inline T extract_throw( css::uno::Any const & a )
{ {
T v = T(); T v = T();
extract_throw<T>( &v, a ); extract_throw<T>( &v, a );
......
...@@ -48,10 +48,10 @@ namespace xmlscript ...@@ -48,10 +48,10 @@ namespace xmlscript
@return @return
document handler for parser document handler for parser
*/ */
::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XDocumentHandler > css::uno::Reference< css::xml::sax::XDocumentHandler >
SAL_CALL createDocumentHandler( SAL_CALL createDocumentHandler(
::com::sun::star::uno::Reference< css::uno::Reference<
::com::sun::star::xml::input::XRoot > const & xRoot, css::xml::input::XRoot > const & xRoot,
bool bSingleThreadedUse = true ); bool bSingleThreadedUse = true );
} }
......
...@@ -93,7 +93,7 @@ class DocumentHandlerImpl : ...@@ -93,7 +93,7 @@ class DocumentHandlerImpl :
public ::cppu::WeakImplHelper< xml::sax::XDocumentHandler, public ::cppu::WeakImplHelper< xml::sax::XDocumentHandler,
xml::input::XNamespaceMapping, xml::input::XNamespaceMapping,
lang::XInitialization, lang::XInitialization,
com::sun::star::lang::XServiceInfo > css::lang::XServiceInfo >
{ {
friend class ExtendedAttributes; friend class ExtendedAttributes;
......
...@@ -35,41 +35,41 @@ namespace xmlscript ...@@ -35,41 +35,41 @@ namespace xmlscript
// class XMLBasicExporterBase // class XMLBasicExporterBase
typedef ::cppu::WeakImplHelper< typedef ::cppu::WeakImplHelper<
::com::sun::star::lang::XServiceInfo, css::lang::XServiceInfo,
::com::sun::star::lang::XInitialization, css::lang::XInitialization,
::com::sun::star::document::XXMLBasicExporter > XMLBasicExporterBase_BASE; css::document::XXMLBasicExporter > XMLBasicExporterBase_BASE;
class XMLBasicExporterBase : public XMLBasicExporterBase_BASE class XMLBasicExporterBase : public XMLBasicExporterBase_BASE
{ {
private: private:
::osl::Mutex m_aMutex; ::osl::Mutex m_aMutex;
::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext > m_xContext; css::uno::Reference< css::uno::XComponentContext > m_xContext;
::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XDocumentHandler > m_xHandler; css::uno::Reference< css::xml::sax::XDocumentHandler > m_xHandler;
::com::sun::star::uno::Reference< ::com::sun::star::frame::XModel > m_xModel; css::uno::Reference< css::frame::XModel > m_xModel;
bool m_bOasis; bool m_bOasis;
public: public:
XMLBasicExporterBase( XMLBasicExporterBase(
const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext, bool bOasis ); const css::uno::Reference< css::uno::XComponentContext >& rxContext, bool bOasis );
virtual ~XMLBasicExporterBase(); virtual ~XMLBasicExporterBase();
// XServiceInfo // XServiceInfo
virtual sal_Bool SAL_CALL supportsService( const OUString& ServiceName ) virtual sal_Bool SAL_CALL supportsService( const OUString& ServiceName )
throw (::com::sun::star::uno::RuntimeException, std::exception) override; throw (css::uno::RuntimeException, std::exception) override;
// XInitialization // XInitialization
virtual void SAL_CALL initialize( const ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any >& aArguments ) virtual void SAL_CALL initialize( const css::uno::Sequence< css::uno::Any >& aArguments )
throw (::com::sun::star::uno::Exception, ::com::sun::star::uno::RuntimeException, std::exception) override; throw (css::uno::Exception, css::uno::RuntimeException, std::exception) override;
// XExporter // XExporter
virtual void SAL_CALL setSourceDocument( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XComponent >& rxDoc ) virtual void SAL_CALL setSourceDocument( const css::uno::Reference< css::lang::XComponent >& rxDoc )
throw (::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::RuntimeException, std::exception) override; throw (css::lang::IllegalArgumentException, css::uno::RuntimeException, std::exception) override;
// XFilter // XFilter
virtual sal_Bool SAL_CALL filter( const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >& aDescriptor ) virtual sal_Bool SAL_CALL filter( const css::uno::Sequence< css::beans::PropertyValue >& aDescriptor )
throw (::com::sun::star::uno::RuntimeException, std::exception) override; throw (css::uno::RuntimeException, std::exception) override;
virtual void SAL_CALL cancel() virtual void SAL_CALL cancel()
throw (::com::sun::star::uno::RuntimeException, std::exception) override; throw (css::uno::RuntimeException, std::exception) override;
}; };
// class XMLBasicExporter // class XMLBasicExporter
...@@ -78,14 +78,14 @@ namespace xmlscript ...@@ -78,14 +78,14 @@ namespace xmlscript
{ {
public: public:
explicit XMLBasicExporter( explicit XMLBasicExporter(
const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext ); const css::uno::Reference< css::uno::XComponentContext >& rxContext );
virtual ~XMLBasicExporter(); virtual ~XMLBasicExporter();
// XServiceInfo // XServiceInfo
virtual OUString SAL_CALL getImplementationName( ) virtual OUString SAL_CALL getImplementationName( )
throw (::com::sun::star::uno::RuntimeException, std::exception) override; throw (css::uno::RuntimeException, std::exception) override;
virtual ::com::sun::star::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames( ) virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames( )
throw (::com::sun::star::uno::RuntimeException, std::exception) override; throw (css::uno::RuntimeException, std::exception) override;
}; };
// class XMLOasisBasicExporter // class XMLOasisBasicExporter
...@@ -94,14 +94,14 @@ namespace xmlscript ...@@ -94,14 +94,14 @@ namespace xmlscript
{ {
public: public:
explicit XMLOasisBasicExporter( explicit XMLOasisBasicExporter(
const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext ); const css::uno::Reference< css::uno::XComponentContext >& rxContext );
virtual ~XMLOasisBasicExporter(); virtual ~XMLOasisBasicExporter();
// XServiceInfo // XServiceInfo
virtual OUString SAL_CALL getImplementationName( ) virtual OUString SAL_CALL getImplementationName( )
throw (::com::sun::star::uno::RuntimeException, std::exception) override; throw (css::uno::RuntimeException, std::exception) override;
virtual ::com::sun::star::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames( ) virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames( )
throw (::com::sun::star::uno::RuntimeException, std::exception) override; throw (css::uno::RuntimeException, std::exception) override;
}; };
} // namespace xmlscript } // namespace xmlscript
......
...@@ -63,7 +63,7 @@ namespace xmlscript ...@@ -63,7 +63,7 @@ namespace xmlscript
} }
bool BasicElementBase::getBoolAttr( sal_Bool* pRet, const OUString& rAttrName, bool BasicElementBase::getBoolAttr( sal_Bool* pRet, const OUString& rAttrName,
const ::com::sun::star::uno::Reference< ::com::sun::star::xml::input::XAttributes >& xAttributes, const css::uno::Reference< css::xml::input::XAttributes >& xAttributes,
sal_Int32 nUid ) sal_Int32 nUid )
{ {
if ( xAttributes.is() ) if ( xAttributes.is() )
......
...@@ -89,7 +89,7 @@ SAL_CALL exportLibraryContainer( ...@@ -89,7 +89,7 @@ SAL_CALL exportLibraryContainer(
void void
SAL_CALL exportLibrary( SAL_CALL exportLibrary(
::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XWriter > const & xOut, css::uno::Reference< css::xml::sax::XWriter > const & xOut,
const LibDescriptor& rLib ) const LibDescriptor& rLib )
{ {
xOut->startDocument(); xOut->startDocument();
......
...@@ -265,14 +265,14 @@ void LibraryElement::endElement() ...@@ -265,14 +265,14 @@ void LibraryElement::endElement()
pLib->aElementNames = aElementNames; pLib->aElementNames = aElementNames;
} }
Reference< ::com::sun::star::xml::sax::XDocumentHandler > Reference< css::xml::sax::XDocumentHandler >
SAL_CALL importLibraryContainer( LibDescriptorArray* pLibArray ) SAL_CALL importLibraryContainer( LibDescriptorArray* pLibArray )
{ {
return ::xmlscript::createDocumentHandler( return ::xmlscript::createDocumentHandler(
static_cast< xml::input::XRoot * >( new LibraryImport( pLibArray ) ) ); static_cast< xml::input::XRoot * >( new LibraryImport( pLibArray ) ) );
} }
::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XDocumentHandler > css::uno::Reference< css::xml::sax::XDocumentHandler >
SAL_CALL importLibrary( LibDescriptor& rLib ) SAL_CALL importLibrary( LibDescriptor& rLib )
{ {
return ::xmlscript::createDocumentHandler( return ::xmlscript::createDocumentHandler(
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment