|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.awt.Component java.awt.Canvas com.jniwrapper.win32.automation.OleContainer com.jniwrapper.win32.automation.OfficeContainer
This class enables to embed OLE/ActiveX MS Office controls into java application.
Nested Class Summary |
Nested classes inherited from class com.jniwrapper.win32.automation.OleContainer |
OleContainer.AutoActivateMode, OleContainer.SizeMode |
Nested classes inherited from class java.awt.Canvas |
java.awt.Canvas.AccessibleAWTCanvas |
Nested classes inherited from class java.awt.Component |
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy |
Field Summary |
Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
OfficeContainer()
Creates OLE container for MS Office components. |
|
OfficeContainer(OleMessageLoop messageLoop)
Creates OLE container for MS Office components. |
Method Summary | |
void |
activate()
Activates embedded document. |
void |
createObject(CLSID clsid)
Creates an object in the container by CLSID. |
void |
createObject(java.io.File file)
Creates an object in the container by association specified by the file name. |
void |
createObject(java.lang.String oleClassName)
Creates an object in the container by class name. |
void |
deactivate()
Deactivates embedded document. |
void |
destroyObject()
Destroys the previously created OleObject. |
protected void |
drawScreenshot(java.awt.Graphics g)
Default method for drawing an embedded component which is in inactive state. |
protected boolean |
gainedFocus()
|
CLSID |
getContainedObjectCLSID()
Retrieves CLSID of the object embedded into OLE container |
protected int |
getProcessID()
|
protected boolean |
gotSameRoots(Wnd wnd1,
Wnd wnd2)
|
protected boolean |
isActive()
Returns UI state |
boolean |
isStaticMode()
Returns true if the embedded object is displayed in a static mode and false in a UI active mode. |
protected void |
makeContainerWindowFocused()
|
void |
paint(java.awt.Graphics g)
|
protected void |
resizeWindow()
|
HResult |
save(java.io.File file)
Saves an OLE object to file. |
protected void |
setActivatedWindow(Wnd activatedWindow)
|
protected void |
setActive(boolean active)
|
protected void |
setProcessID(int processID)
|
void |
setStaticMode(boolean value)
Changes the embedded workbook displaying mode. |
Methods inherited from class java.awt.Canvas |
addNotify, createBufferStrategy, createBufferStrategy, getAccessibleContext, getBufferStrategy, update |
Methods inherited from class java.awt.Component |
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, deliverEvent, disable, disableEvents, dispatchEvent, doLayout, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, getAlignmentX, getAlignmentY, getBackground, getBounds, getBounds, getColorModel, getComponentAt, getComponentAt, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeys, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphics, getGraphicsConfiguration, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getListeners, getLocale, getLocation, getLocation, getLocationOnScreen, getMaximumSize, getMinimumSize, getMouseListeners, getMouseMotionListeners, getMouseWheelListeners, getName, getParent, getPeer, getPreferredSize, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getToolkit, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, invalidate, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusCycleRoot, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isOpaque, isShowing, isValid, isVisible, keyDown, keyUp, layout, list, list, list, list, list, locate, location, lostFocus, minimumSize, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, paramString, postEvent, preferredSize, prepareImage, prepareImage, print, printAll, processComponentEvent, processEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, reshape, resize, resize, setBackground, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeys, setFocusTraversalKeysEnabled, setFont, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, setVisible, show, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle, validate |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public OfficeContainer()
public OfficeContainer(OleMessageLoop messageLoop)
messageLoop
- - Ole Message Loop specific for this container.
Shall be started before creating an object.Method Detail |
protected void setActivatedWindow(Wnd activatedWindow)
setActivatedWindow
in class OleContainer
public void createObject(CLSID clsid) throws ComException
createObject
in class OleContainer
clsid
- - CLSID of the object to be created
ComException
public void createObject(java.io.File file) throws ComException
createObject
in class OleContainer
file
- - source(storage) file of the object to be created
ComException
public void createObject(java.lang.String oleClassName) throws ComException
createObject
in class OleContainer
oleClassName
- - class name of the object to be created
ComException
protected void resizeWindow()
resizeWindow
in class OleContainer
public HResult save(java.io.File file)
OleContainer
save
in class OleContainer
file
- for saving
HResult.S_OK
,
HResult.S_FALSE
public void activate()
activate
in class OleContainer
public void deactivate()
protected void drawScreenshot(java.awt.Graphics g)
public void destroyObject()
destroyObject
in class OleContainer
public void paint(java.awt.Graphics g)
paint
in class OleContainer
protected boolean isActive()
true
- UI activated; false
- UI deactivatedprotected void setActive(boolean active)
active
- - true
- UI activated, other components addressing the same server may
loose the UI controls; false
- UI deactivated, UI controls free for
usage in other components.protected boolean gainedFocus()
gainedFocus
in class OleContainer
public void setStaticMode(boolean value)
value
- if true
the workbook is displayed in a static mode, otherwise in a UI active mode.public boolean isStaticMode()
true
if the embedded object is displayed in a static mode and false
in a UI active mode.
true
if the embedded object is displayed in a static mode and false
in a UI active mode.public CLSID getContainedObjectCLSID()
protected boolean gotSameRoots(Wnd wnd1, Wnd wnd2)
gotSameRoots
in class OleContainer
protected int getProcessID()
protected void setProcessID(int processID)
protected void makeContainerWindowFocused()
makeContainerWindowFocused
in class OleContainer
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |