diff options
author | Ursache Vladimir <ursache@collabora.co.uk> | 2015-02-19 01:17:31 +0200 |
---|---|---|
committer | Jan Holesovsky <kendy@collabora.com> | 2015-02-20 10:19:10 +0100 |
commit | 17984250e94a04f7989dbe42a5cf5353e3e2b076 (patch) | |
tree | bd8fb5c5bbf521037ed86a806ec751a79f057bc7 /stoc | |
parent | 8f5eff2210dc96fa9da8775db5c4d117b63c1f78 (diff) |
stocservices.component partly refactored to use the "constructor" feature.
Change-Id: I4c1c5e62de608738a91be4a234d9c160a18cbf8f
Diffstat (limited to 'stoc')
-rw-r--r-- | stoc/source/stocservices/stocservices.cxx | 19 | ||||
-rw-r--r-- | stoc/source/uriproc/ExternalUriReferenceTranslator.cxx | 7 | ||||
-rw-r--r-- | stoc/source/uriproc/UriReferenceFactory.cxx | 7 | ||||
-rw-r--r-- | stoc/source/uriproc/VndSunStarPkgUrlReferenceFactory.cxx | 7 | ||||
-rw-r--r-- | stoc/util/stocservices.component | 9 |
5 files changed, 27 insertions, 22 deletions
diff --git a/stoc/source/stocservices/stocservices.cxx b/stoc/source/stocservices/stocservices.cxx index c8aa9d954226..347580cfa6cb 100644 --- a/stoc/source/stocservices/stocservices.cxx +++ b/stoc/source/stocservices/stocservices.cxx @@ -39,19 +39,6 @@ static const struct ImplementationEntry g_entries[] = tcv_getSupportedServiceNames, createSingleComponentFactory, 0, 0 }, - // uriproc - { - ExternalUriReferenceTranslator::create, - ExternalUriReferenceTranslator::getImplementationName, - ExternalUriReferenceTranslator::getSupportedServiceNames, - createSingleComponentFactory, 0, 0 - }, - { - UriReferenceFactory::create, - UriReferenceFactory::getImplementationName, - UriReferenceFactory::getSupportedServiceNames, - createSingleComponentFactory, 0, 0 - }, { UriSchemeParser_vndDOTsunDOTstarDOTexpand::create, UriSchemeParser_vndDOTsunDOTstarDOTexpand::getImplementationName, @@ -64,12 +51,6 @@ static const struct ImplementationEntry g_entries[] = UriSchemeParser_vndDOTsunDOTstarDOTscript::getSupportedServiceNames, createSingleComponentFactory, 0, 0 }, - { - VndSunStarPkgUrlReferenceFactory::create, - VndSunStarPkgUrlReferenceFactory::getImplementationName, - VndSunStarPkgUrlReferenceFactory::getSupportedServiceNames, - createSingleComponentFactory, 0, 0 - }, { 0, 0, 0, 0, 0, 0 } }; diff --git a/stoc/source/uriproc/ExternalUriReferenceTranslator.cxx b/stoc/source/uriproc/ExternalUriReferenceTranslator.cxx index 136eb158727a..fba94d29ece8 100644 --- a/stoc/source/uriproc/ExternalUriReferenceTranslator.cxx +++ b/stoc/source/uriproc/ExternalUriReferenceTranslator.cxx @@ -213,4 +213,11 @@ css::uno::Sequence< OUString > getSupportedServiceNames() { } } +extern "C" SAL_DLLPUBLIC_EXPORT ::com::sun::star::uno::XInterface* SAL_CALL +com_sun_star_comp_uri_ExternalUriReferenceTranslator_get_implementation(::com::sun::star::uno::XComponentContext* rxContext, + ::com::sun::star::uno::Sequence<css::uno::Any> const &) +{ + return ::cppu::acquire(new Translator(rxContext)); +} + /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/stoc/source/uriproc/UriReferenceFactory.cxx b/stoc/source/uriproc/UriReferenceFactory.cxx index 393aa1ae729a..08b967c484f8 100644 --- a/stoc/source/uriproc/UriReferenceFactory.cxx +++ b/stoc/source/uriproc/UriReferenceFactory.cxx @@ -652,4 +652,11 @@ css::uno::Sequence< OUString > getSupportedServiceNames() { } } +extern "C" SAL_DLLPUBLIC_EXPORT ::com::sun::star::uno::XInterface* SAL_CALL +com_sun_star_comp_uri_UriReferenceFactory_get_implementation(::com::sun::star::uno::XComponentContext* rxContext, + ::com::sun::star::uno::Sequence<css::uno::Any> const &) +{ + return ::cppu::acquire(new Factory(rxContext)); +} + /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/stoc/source/uriproc/VndSunStarPkgUrlReferenceFactory.cxx b/stoc/source/uriproc/VndSunStarPkgUrlReferenceFactory.cxx index 272c4a8377ee..0276942cf2cc 100644 --- a/stoc/source/uriproc/VndSunStarPkgUrlReferenceFactory.cxx +++ b/stoc/source/uriproc/VndSunStarPkgUrlReferenceFactory.cxx @@ -143,4 +143,11 @@ css::uno::Sequence< OUString > getSupportedServiceNames() { } } +extern "C" SAL_DLLPUBLIC_EXPORT ::com::sun::star::uno::XInterface* SAL_CALL +com_sun_star_comp_uri_VndSunStarPkgUrlReferenceFactory_get_implementation(::com::sun::star::uno::XComponentContext* rxContext, + ::com::sun::star::uno::Sequence<css::uno::Any> const &) +{ + return ::cppu::acquire(new Factory(rxContext)); +} + /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/stoc/util/stocservices.component b/stoc/util/stocservices.component index d94f0acf6f51..982556e13f0f 100644 --- a/stoc/util/stocservices.component +++ b/stoc/util/stocservices.component @@ -22,10 +22,12 @@ <implementation name="com.sun.star.comp.stoc.TypeConverter"> <service name="com.sun.star.script.Converter"/> </implementation> - <implementation name="com.sun.star.comp.uri.ExternalUriReferenceTranslator"> + <implementation name="com.sun.star.comp.uri.ExternalUriReferenceTranslator" + constructor="com_sun_star_comp_uri_ExternalUriReferenceTranslator_get_implementation"> <service name="com.sun.star.uri.ExternalUriReferenceTranslator"/> </implementation> - <implementation name="com.sun.star.comp.uri.UriReferenceFactory"> + <implementation name="com.sun.star.comp.uri.UriReferenceFactory" + constructor="com_sun_star_comp_uri_UriReferenceFactory_get_implementation"> <service name="com.sun.star.uri.UriReferenceFactory"/> </implementation> <implementation @@ -36,7 +38,8 @@ name="com.sun.star.comp.uri.UriSchemeParser_vndDOTsunDOTstarDOTscript"> <service name="com.sun.star.uri.UriSchemeParser_vndDOTsunDOTstarDOTscript"/> </implementation> - <implementation name="com.sun.star.comp.uri.VndSunStarPkgUrlReferenceFactory"> + <implementation name="com.sun.star.comp.uri.VndSunStarPkgUrlReferenceFactory" + constructor="com_sun_star_comp_uri_VndSunStarPkgUrlReferenceFactory_get_implementation"> <service name="com.sun.star.uri.VndSunStarPkgUrlReferenceFactory"/> </implementation> </component> |