diff options
Diffstat (limited to 'bean/com/sun/star/beans/LocalOfficeConnection.java')
-rw-r--r-- | bean/com/sun/star/beans/LocalOfficeConnection.java | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/bean/com/sun/star/beans/LocalOfficeConnection.java b/bean/com/sun/star/beans/LocalOfficeConnection.java index 15f025ac6738..b742fb3a7027 100644 --- a/bean/com/sun/star/beans/LocalOfficeConnection.java +++ b/bean/com/sun/star/beans/LocalOfficeConnection.java @@ -110,8 +110,8 @@ public class LocalOfficeConnection UnoUrl aURL = UnoUrl.parseUnoUrl( url ); mProgramPath = null; mConnType = aURL.getConnection(); - mPipe = (String) aURL.getConnectionParameters().get( "pipe" ); - mPort = (String) aURL.getConnectionParameters().get( "port" ); + mPipe = aURL.getConnectionParameters().get( "pipe" ); + mPort = aURL.getConnectionParameters().get( "port" ); mProtocol = aURL.getProtocol(); mInitialObject = aURL.getRootOid(); } @@ -221,7 +221,7 @@ public class LocalOfficeConnection // query for the XUnoUrlResolver interface XUnoUrlResolver xUrlResolver = - (XUnoUrlResolver) UnoRuntime.queryInterface( XUnoUrlResolver.class, urlResolver ); + UnoRuntime.queryInterface( XUnoUrlResolver.class, urlResolver ); // try to connect to soffice Object aInitialObject = null; @@ -261,10 +261,9 @@ public class LocalOfficeConnection // XComponentContext if( null != aInitialObject ) { - XPropertySet xPropertySet = (XPropertySet) - UnoRuntime.queryInterface( XPropertySet.class, aInitialObject); + XPropertySet xPropertySet = UnoRuntime.queryInterface( XPropertySet.class, aInitialObject); Object xContext = xPropertySet.getPropertyValue("DefaultContext"); - XComponentContext xComponentContext = (XComponentContext) UnoRuntime.queryInterface( + XComponentContext xComponentContext = UnoRuntime.queryInterface( XComponentContext.class, xContext); return xComponentContext; } |