diff options
Diffstat (limited to 'scripting/source/provider/MasterScriptProvider.cxx')
-rw-r--r-- | scripting/source/provider/MasterScriptProvider.cxx | 47 |
1 files changed, 10 insertions, 37 deletions
diff --git a/scripting/source/provider/MasterScriptProvider.cxx b/scripting/source/provider/MasterScriptProvider.cxx index 56faea32c6d2..0b4baeddd981 100644 --- a/scripting/source/provider/MasterScriptProvider.cxx +++ b/scripting/source/provider/MasterScriptProvider.cxx @@ -55,16 +55,11 @@ using namespace ::sf_misc; namespace func_provider { -bool endsWith( const OUString& target, - const OUString& item ) +bool endsWith( const OUString& target, const OUString& item ) { - sal_Int32 index = 0; - if ( ( index = target.indexOf( item ) ) != -1 && - ( index == ( target.getLength() - item.getLength() ) ) ) - { - return true; - } - return false; + sal_Int32 index = target.indexOf( item ); + return index != -1 && + index == ( target.getLength() - item.getLength() ); } /* should be available in some central location. */ @@ -607,30 +602,17 @@ MasterScriptProvider::removeByName( const OUString& Name ) void SAL_CALL -MasterScriptProvider::replaceByName( const OUString& aName, const Any& aElement ) +MasterScriptProvider::replaceByName( const OUString& /*aName*/, const Any& /*aElement*/ ) { - (void)aName; - (void)aElement; - // TODO needs implementing - if ( true ) - { - throw RuntimeException( "replaceByName not implemented!!!!" ); - } + throw RuntimeException( "replaceByName not implemented!!!!" ); } Any SAL_CALL -MasterScriptProvider::getByName( const OUString& aName ) +MasterScriptProvider::getByName( const OUString& /*aName*/ ) { - (void)aName; - // TODO needs to be implemented - Any result; - if ( true ) - { - throw RuntimeException( "getByName not implemented!!!!" ); - } - return result; + throw RuntimeException( "getByName not implemented!!!!" ); } sal_Bool SAL_CALL @@ -701,12 +683,7 @@ Sequence< OUString > SAL_CALL MasterScriptProvider::getElementNames( ) { // TODO needs implementing - Sequence< OUString > names; - if ( true ) - { - throw RuntimeException( "getElementNames not implemented!!!!" ); - } - return names; + throw RuntimeException( "getElementNames not implemented!!!!" ); } Type SAL_CALL @@ -720,11 +697,7 @@ MasterScriptProvider::getElementType( ) sal_Bool SAL_CALL MasterScriptProvider::hasElements( ) { // TODO needs implementing - if ( true ) - { - throw RuntimeException( "hasElements not implemented!!!!" ); - } - return false; + throw RuntimeException( "hasElements not implemented!!!!" ); } |