Kaydet (Commit) 3aa70e21 authored tarafından Stephan Bergmann's avatar Stephan Bergmann

[API CHANGE] OfficeBean: remove deprecated com.sun.star.beans classes

<https://wiki.openoffice.org/wiki/Documentation/DevGuide/JavaBean/The_Internal_Office_Bean_API>:
"Prior to OpenOffice.org 2.0 all Office Bean classes were in the
com.sun.star.bean package.  As of OpenOffice.org 2.0 the classes are contained
in the com.sun.star.comp.bean package.  The classes of the com.sun.star.bean
package are still contained in the officebean.jar but they are deprecated.
Further development and bug fixing will occur only in the com.sun.star.comp.bean
package."

Change-Id: I9421bfba941d9801a5cf8886ca971275740d178a
üst 1c70f59c
...@@ -20,14 +20,6 @@ $(eval $(call gb_Jar_use_jars,officebean,\ ...@@ -20,14 +20,6 @@ $(eval $(call gb_Jar_use_jars,officebean,\
$(eval $(call gb_Jar_set_packageroot,officebean,com)) $(eval $(call gb_Jar_set_packageroot,officebean,com))
$(eval $(call gb_Jar_add_sourcefiles,officebean,\ $(eval $(call gb_Jar_add_sourcefiles,officebean,\
bean/com/sun/star/beans/ContainerFactory \
bean/com/sun/star/beans/JavaWindowPeerFake \
bean/com/sun/star/beans/LocalOfficeConnection \
bean/com/sun/star/beans/LocalOfficeWindow \
bean/com/sun/star/beans/NativeConnection \
bean/com/sun/star/beans/NativeService \
bean/com/sun/star/beans/OfficeConnection \
bean/com/sun/star/beans/OfficeWindow \
bean/com/sun/star/comp/beans/ContainerFactory \ bean/com/sun/star/comp/beans/ContainerFactory \
bean/com/sun/star/comp/beans/Controller \ bean/com/sun/star/comp/beans/Controller \
bean/com/sun/star/comp/beans/Frame \ bean/com/sun/star/comp/beans/Frame \
......
/*
* This file is part of the LibreOffice project.
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*
* This file incorporates work covered by the following license notice:
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed
* with this work for additional information regarding copyright
* ownership. The ASF licenses this file to you under the Apache
* License, Version 2.0 (the "License"); you may not use this file
* except in compliance with the License. You may obtain a copy of
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
package com.sun.star.beans;
import java.awt.Container;
/**
* This interface reprecents an AWT container factory.
*
* @see OfficeBean
* @deprecated
*/
public interface ContainerFactory
{
/**
* Creates an AWT container.
*
* @return An AWT container.
*/
Container createContainer();
}
/*
* This file is part of the LibreOffice project.
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*
* This file incorporates work covered by the following license notice:
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed
* with this work for additional information regarding copyright
* ownership. The ASF licenses this file to you under the Apache
* License, Version 2.0 (the "License"); you may not use this file
* except in compliance with the License. You may obtain a copy of
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
package com.sun.star.beans;
import com.sun.star.awt.*;
/** <p>Class to pass the system window handle to the OpenOffice.org toolkit.</p>
* @deprecated
*/
/* package */ class JavaWindowPeerFake
implements XSystemDependentWindowPeer, XWindowPeer
{
private long hWindow;
private int localSystemType;
/** Create the faked window peer.
* @param _hWindow the system handle to the window.
* @param _systemType specifies the system type.
*/
public JavaWindowPeerFake(long _hWindow, int _systemType)
{
hWindow = _hWindow;
localSystemType = _systemType;
}
/** <p>Implementation of XSystemDependentWindowPeer (that's all we really need)</p>
* This method is called back from the OpenOffice.org toolkit to retrieve the system data.
*/
public Object getWindowHandle(/*IN*/byte[] ProcessId, /*IN*/short SystemType)
throws com.sun.star.uno.RuntimeException
{
if (SystemType == localSystemType) {
return Integer.valueOf((int)hWindow);
}
else return null;
}
/** not really neaded.
*/
public XToolkit getToolkit()
throws com.sun.star.uno.RuntimeException
{
return null;
}
/** not really neaded.
*/
public void setPointer(/*IN*/XPointer Pointer)
throws com.sun.star.uno.RuntimeException
{
}
/** not really neaded.
*/
public void setBackground(/*IN*/int Color)
throws com.sun.star.uno.RuntimeException
{
}
/** not really neaded.
*/
public void invalidate(/*IN*/short Flags)
throws com.sun.star.uno.RuntimeException
{
}
/** not really neaded.
*/
public void invalidateRect(/*IN*/com.sun.star.awt.Rectangle Rect, /*IN*/short Flags)
throws com.sun.star.uno.RuntimeException
{
}
/** not really neaded.
*/
public void dispose()
throws com.sun.star.uno.RuntimeException
{
}
/** not really neaded.
*/
public void addEventListener(/*IN*/com.sun.star.lang.XEventListener xListener)
throws com.sun.star.uno.RuntimeException
{
}
/** not really neaded.
*/
public void removeEventListener(/*IN*/com.sun.star.lang.XEventListener aListener)
throws com.sun.star.uno.RuntimeException
{
}
}
/*
* This file is part of the LibreOffice project.
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*
* This file incorporates work covered by the following license notice:
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed
* with this work for additional information regarding copyright
* ownership. The ASF licenses this file to you under the Apache
* License, Version 2.0 (the "License"); you may not use this file
* except in compliance with the License. You may obtain a copy of
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
package com.sun.star.beans;
import com.sun.star.connection.XConnection;
/* @deprecated
*/
/* package */ class NativeConnection
implements XConnection
{
public native void connect(NativeService aNativeService)
throws com.sun.star.io.IOException;
public native int read(/*OUT*/byte[][] aReadBytes, /*IN*/int nBytesToRead)
throws com.sun.star.io.IOException, com.sun.star.uno.RuntimeException;
public native void write(/*IN*/byte[] aData)
throws com.sun.star.io.IOException, com.sun.star.uno.RuntimeException;
public native void flush()
throws com.sun.star.io.IOException, com.sun.star.uno.RuntimeException;
public native void close()
throws com.sun.star.io.IOException, com.sun.star.uno.RuntimeException;
public synchronized String getDescription()
throws com.sun.star.uno.RuntimeException
{
return Description;
}
private long NativeHandle;
private String Description;
}
/*
* This file is part of the LibreOffice project.
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*
* This file incorporates work covered by the following license notice:
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed
* with this work for additional information regarding copyright
* ownership. The ASF licenses this file to you under the Apache
* License, Version 2.0 (the "License"); you may not use this file
* except in compliance with the License. You may obtain a copy of
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
package com.sun.star.beans;
/* @deprecated
*/
/* package */ interface NativeService {
String getIdentifier();
void startupService() throws java.io.IOException;
int getStartupTime();
}
/*
* This file is part of the LibreOffice project.
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*
* This file incorporates work covered by the following license notice:
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed
* with this work for additional information regarding copyright
* ownership. The ASF licenses this file to you under the Apache
* License, Version 2.0 (the "License"); you may not use this file
* except in compliance with the License. You may obtain a copy of
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
package com.sun.star.beans;
import com.sun.star.lang.XComponent;
import com.sun.star.uno.XComponentContext;
import java.awt.Container;
/**
* This abstract class reprecents a connection to the office
* application.
* @deprecated
*/
public interface OfficeConnection
extends XComponent
{
/**
* Sets a connection URL.
*
* @param url This is UNO URL which describes the type of a connection.
*/
void setUnoUrl(String url)
throws java.net.MalformedURLException;
/**
* Sets an AWT container catory.
*
* @param containerFactory This is a application provided AWT container
* factory.
*/
void setContainerFactory(ContainerFactory containerFactory);
/**
* Retrieves the UNO component context.
* Establishes a connection if necessary and initialises the
* UNO service manager if it has not already been initialised.
*
* @return The office UNO component context.
*/
XComponentContext getComponentContext();
/**
* Creates an office window.
* The window is either a sub-class of java.awt.Canvas (local) or
* java.awt.Container (RVP).
*
* This method does not add add the office window to its container.
*
* @param container This is an AWT container.
* @return The office window instance.
*/
OfficeWindow createOfficeWindow(Container container);
}
/*
* This file is part of the LibreOffice project.
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*
* This file incorporates work covered by the following license notice:
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed
* with this work for additional information regarding copyright
* ownership. The ASF licenses this file to you under the Apache
* License, Version 2.0 (the "License"); you may not use this file
* except in compliance with the License. You may obtain a copy of
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
package com.sun.star.beans;
import java.awt.Component;
import com.sun.star.awt.XWindowPeer;
/**
* The concreate implementation of the OfficeWindow extends an
* approperate type of visual component (java.awt.Canvas for local
* and java.awt.Container for remote).
* @deprecated
*/
public interface OfficeWindow
{
/**
* Retrieves an AWT component object associated with the OfficeWindow.
*
* @return The AWT component object associated with the OfficeWindow.
*/
Component getAWTComponent();
/**
* Retrieves an UNO XWindowPeer object associated with the OfficeWindow.
*
* @return The UNO XWindowPeer object associated with the OfficeWindow.
*/
XWindowPeer getUNOWindowPeer();
}
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