Kaydet (Commit) 610cfb37 authored tarafından Noel Grandin's avatar Noel Grandin

java: fix reportbuilder and wizard

which I broke in commits
70f56bc2 "java: reduce scope, make member classes private"
and
34bcf9b4 "java: remove dead methods"

Change-Id: Id21482782bbc102e60f346a2bf51096af2fcbe22
üst 7da6716e
......@@ -329,7 +329,7 @@ public final class SOFormulaParser extends ComponentBase
* This method is a simple helper function to used in the static component initialisation functions as well as
* in getSupportedServiceNames.
*/
private static String[] getServiceNames()
public static String[] getServiceNames()
{
return new String[]
{
......
......@@ -30,6 +30,8 @@ import com.sun.star.lang.IllegalArgumentException;
import com.sun.star.lang.WrappedTargetException;
import com.sun.star.lang.XInitialization;
import com.sun.star.lang.XServiceInfo;
import com.sun.star.lang.XSingleComponentFactory;
import com.sun.star.lib.uno.helper.Factory;
import com.sun.star.lib.uno.helper.PropertySetMixin;
import com.sun.star.lib.uno.helper.WeakBase;
import com.sun.star.registry.InvalidRegistryException;
......@@ -74,7 +76,7 @@ public class SOReportJobFactory
{
}
private static class _SOReportJobFactory extends WeakBase implements XInitialization, XServiceInfo, XJob, XPropertySet, ReportJobFactory
public static class _SOReportJobFactory extends WeakBase implements XInitialization, XServiceInfo, XJob, XPropertySet, ReportJobFactory
{
private static final Log LOGGER = LogFactory.getLog(_SOReportJobFactory.class);
......@@ -381,5 +383,38 @@ public class SOReportJobFactory
}
}
/**
* Gives a factory for creating the service. This method is called by the <code>JavaLoader</code>
* <p/>
*
* @param sImplName the name of the implementation for which a service is desired
* @return returns a <code>XSingleComponentFactory</code> for creating the component
* @see com.sun.star.comp.loader.JavaLoader
*/
public static XSingleComponentFactory __getComponentFactory(final String sImplName)
{
XSingleComponentFactory xFactory = null;
try
{
if (sImplName.equals(_SOReportJobFactory.class.getName()))
{
xFactory = Factory.createComponentFactory(_SOReportJobFactory.class, _SOReportJobFactory.getServiceNames());
}
else if (sImplName.equals(SOFunctionManager.class.getName()))
{
xFactory = Factory.createComponentFactory(SOFunctionManager.class, SOFunctionManager.getServiceNames());
}
else if (sImplName.equals(SOFormulaParser.class.getName()))
{
xFactory = Factory.createComponentFactory(SOFormulaParser.class, SOFormulaParser.getServiceNames());
}
}
catch (java.lang.IncompatibleClassChangeError e2)
{
}
return xFactory;
}
}
......@@ -51,7 +51,7 @@ public class CallFormWizard
/** This class implements the component. At least the interfaces XServiceInfo,
* XTypeProvider, and XInitialization should be provided by the service.
*/
private static class FormWizardImplementation extends com.sun.star.lib.uno.helper.PropertySet implements com.sun.star.lang.XInitialization, com.sun.star.lang.XServiceInfo, com.sun.star.task.XJobExecutor
public static class FormWizardImplementation extends com.sun.star.lib.uno.helper.PropertySet implements com.sun.star.lang.XInitialization, com.sun.star.lang.XServiceInfo, com.sun.star.task.XJobExecutor
{
private PropertyValue[] m_wizardContext;
......
......@@ -53,7 +53,7 @@ public class CallQueryWizard
/** This class implements the component. At least the interfaces XServiceInfo,
* XTypeProvider, and XInitialization should be provided by the service.
*/
private static class QueryWizardImplementation extends com.sun.star.lib.uno.helper.PropertySet implements com.sun.star.lang.XInitialization, com.sun.star.lang.XServiceInfo, com.sun.star.task.XJobExecutor
public static class QueryWizardImplementation extends com.sun.star.lib.uno.helper.PropertySet implements com.sun.star.lang.XInitialization, com.sun.star.lang.XServiceInfo, com.sun.star.task.XJobExecutor
{
private PropertyValue[] m_wizardContext;
......
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