+ All Categories

OOoCon

Date post: 03-Apr-2018
Category:
Upload: scribdmatti
View: 221 times
Download: 0 times
Share this document with a friend

of 25

Transcript
  • 7/28/2019 OOoCon

    1/25

    Mathias Bauer - OpenOffice.org Application Framework- Slide 1

    OOoCon 2004 - Berlin

    OpenOffice.org as a platform fordevelopers

    [email protected]

  • 7/28/2019 OOoCon

    2/25

    Mathias Bauer - OpenOffice.org Application Framework- Slide 2

    Agenda

    Speaker introductions

    Features for developmentOpenOffice.org API architecture

    OpenOffice.org as a service provider

    Extending OpenOffice.org

    User Interface programmabilityAddOns

    OpenOffice.org AddOns (Demo)

    Q & A

  • 7/28/2019 OOoCon

    3/25

    Mathias Bauer - OpenOffice.org Application Framework- Slide 3

    Speaker introductions

    At Sun Microsystems:Working on StarOffice/OpenOffice.org since 1995Application Framework, 3rd party integrationManager Software Engineering

    Application FrameworkUNO

    SDKUCB

    For OpenOffice.org:Working on the project since its foundation

    Application Framework Project LeadMember of Engineering Steering Committee

  • 7/28/2019 OOoCon

    4/25Mathias Bauer - OpenOffice.org Application Framework- Slide 4

    Features for developers

    Support for many platforms and languages11 languages available for standard buildsMore languages provided by the communityOOo 2.0: New tool support for localizing help content

    Stable language independent API based on UNOUsable from Java, C++, OpenOfficeBASIC, PythonSupport for OLE automation on Windows (f.e. VB, Delphi)OOo 2.0: Language binding for CLI (.NET runtime)More programming and scripting languages through a

    language agnostic scripting framework (f.e. JavaScript)Implement own UNO services in C++, Java, PythonOOo 2.0: Much simpler use of UNO services

  • 7/28/2019 OOoCon

    5/25Mathias Bauer - OpenOffice.org Application Framework- Slide 5

    Features for developers (continued)

    UNO Component and type registry

    Extend the OOo API by creating own typesRegister own UNO components

    XML based expandable configuration

    Read and write OOo configuration settingsCreate own configuration templates and settingsAccess through OpenOffice.org API

    Open, XML based file formatAdd arbitrary content streams to packagesOOo 2.0: Store and read document variables

  • 7/28/2019 OOoCon

    6/25Mathias Bauer - OpenOffice.org Application Framework- Slide 6

    Features for developers (continued)

    Easy deployment of 3rd party components

    Based on ZIP packagesDeployable on user or installation baseOOo 2.0: New Package Manager

    Live DeploymentPackage Manager GUI

    Deployable content:Code: jar files, Basic modules, scripts, libraries (formultiple platforms in one file)Configuration files (schema and data)UNO types and servicesUI elements (Popup menus, toolbars, images)Document templates

  • 7/28/2019 OOoCon

    7/25Mathias Bauer - OpenOffice.org Application Framework- Slide 7

    OpenOffice.org API architecture

    Writer

    Application Framework

    Calc Draw Impress

    API

    SPI (Service Provider Interface)

    ContentFilter

    CalcAdd-in

    DataConnector ...

    Macro-Script.

    Server-Apps

    GUI-Apps

    JavaBean

    ...

  • 7/28/2019 OOoCon

    8/25Mathias Bauer - OpenOffice.org Application Framework- Slide 8

    OpenOffice.org as a service provider

    Connect through UNO

    Use any programming language supporting UNO callsConnect from Python ScriptsConnect from Java Applets, Servlets, Java GUI AppsConnect from Native ApplicationsOn Windows: Connect via COM

    OOo 2.0: On Windows: Connect via .NET

    Use existing GUI embedding technologiesActiveXOLE documents

    Java AppletJava (AWTContainers)OOo 2.0: Netscape PluginOOo 2.0: Java Beans

  • 7/28/2019 OOoCon

    9/25Mathias Bauer - OpenOffice.org Application Framework- Slide 9

    Development Opportunities

    OpenOffice.org as content format gateway

    Provide 1 format, publish to NServer based document conversions

    OpenOffice.org as a point of service integrationRelational Databases

    Address books, LDAP directoryWeb servicesFile/Content management systems

    OOo 2.o: Workflow managementXForms supportDocument variablesDigital signing of documents

  • 7/28/2019 OOoCon

    10/25Mathias Bauer - OpenOffice.org Application Framework- Slide 10

    Service Integration

    DynamicDocument

    Model

    OO.org

    EnterpriseDatabase

    LDAPDirectory

    IntranetWeb

    Service

    PublicWeb

    Service

  • 7/28/2019 OOoCon

    11/25Mathias Bauer - OpenOffice.org Application Framework- Slide 11

    Service Integration

    OO.org

    EnterpriseDatabase

    LDAPDirectory

    IntranetWeb

    Service

    PublicWeb

    Service Response

    Cont

    ent

    Content

    Data

    Fields

    Contacts

    Data Data GUI(JDBC, JNDI)

    SDBC

    JAXM /XMLRPC

    client

    insert aparagraph

    Mr. Mathias BauerSun Microsystems...

    R

    esponse

    C G

  • 7/28/2019 OOoCon

    12/25Mathias Bauer - OpenOffice.org Application Framework- Slide 12

    Content Format Gateway

    OpenOffice.orgXML format

    Flash

    PDF

    SVG

    Closed ProprietaryFormats(e.g. MS Office)

    HTML

    RTF

    OpenOffice.org

    *XML

    OASIS OpenOffice XMLformat

  • 7/28/2019 OOoCon

    13/25

    E t di O Offi

  • 7/28/2019 OOoCon

    14/25

    Mathias Bauer - OpenOffice.org Application Framework- Slide 14

    Extending OpenOffice.org

    Adding external components to OpenOffice.org

    Provide UNO components (see Developers Guide)Bridge to other technologies (COM, Java etc.)

    Provide UNO wrappers for existing componentsCall non-UNO based components

    Build your components with the OpenOffice.org SDK

    Currently possible languages: C++, Java, PythonDevelop platform independent componentsUse JavaProvide libraries for several platforms in one packageUse SDK libraries for platform support

    Replace existing components or add new ones

    O Offi API hit t

  • 7/28/2019 OOoCon

    15/25

    Mathias Bauer - OpenOffice.org Application Framework- Slide 15

    OpenOffice.org API architecture

    Writer

    Application Framework

    Calc Draw Impress

    API

    SPI (Service Provider Interface)

    ContentFilter

    CalcAdd-in

    DataConnector ...

    Macro-Script.

    Server-Apps

    GUI-Apps

    JavaBean

    ...

    I t ti t l t

  • 7/28/2019 OOoCon

    16/25

    Mathias Bauer - OpenOffice.org Application Framework- Slide 16

    Integrating external components

    Registration of new Service Providers

    Data Connectors: new data connectionsCalc Add-ins: new functions in Calc formulasContent Providers: new file sourcesDocument import/export filtersOOo 2.0: Impress Shapes

    Call external components from the GUIAdd new GUI elementsRedirect calls from existing GUI elements

    Exchange current implementationsExample: FilePicker and FolderPicker serviceSpell CheckerReplace existing Service Providers

    Content Access: UCB

  • 7/28/2019 OOoCon

    17/25

    Mathias Bauer - OpenOffice.org Application Framework- Slide 17

    Content Access: UCB

    Makes content hierarchies accessible throughURLs (http, ftp, file, webdav)

    Extend it by defining new protocol schemesImplement access to folders and filesfollowing the UCP API

    IMAP UCP

    UCB

    Folder Content

    FILE UCP HTTP UCP

    File ContentFolder Content File Content Folder Content File ContentAccount Content Message Content

    Folder ContentFolder ContentDocument

    Broker

    Providers

    Contents

    Special: Hierarchy UCP

  • 7/28/2019 OOoCon

    18/25

    Mathias Bauer - OpenOffice.org Application Framework- Slide 18

    Special: Hierarchy UCP

    Implements a UCP on a registry backend

    Default registry backend available working onthe OOo configurationCan map arbitrary hierarchies

    Fixed hierarchies: provide configuration file

    Moderately changing hierarchy: same as above, butprovide service that updates configuration on demandDynamic hierarchy: provide your own backend

    Integration with CMS

  • 7/28/2019 OOoCon

    19/25

    Mathias Bauer - OpenOffice.org Application Framework- Slide 19

    Integration with CMS

    CMS

    OO.org

    Own dialog as

    OpenOffice.orgAdd-On

    Implement

    Content ProviderService

    Provide

    WebDAVaccess

    User Interface: Programmability

  • 7/28/2019 OOoCon

    20/25

    Mathias Bauer - OpenOffice.org Application Framework- Slide 20

    User Interface: Programmability

    Generic OpenOffice.org UI is XML based

    MenubarToolboxesKeyboard shortcutsEvent bindings

    Modification of UI elementsModify the XML files directlyAdd toolbars as many as you like with new XML filesAdd toolbars and menubar popups through AddOn

    configuration filesOOo 2.0: API for accessing UI elements at runtimeOOo 2.0: Replace menu entries by registered popups

    User Interface: Dispatching

  • 7/28/2019 OOoCon

    21/25

    Mathias Bauer - OpenOffice.org Application Framework- Slide 21

    User Interface: Dispatching

    Modify or extend the UI through Dispatch Objects

    Disabling of selected commands: Configuration meansRedirecting of internal commands: Dispatch InterceptionIntroducing new commands: Protocol Handlers

    Functionality is described by commandsCommands are strings with URL like syntaxOpenOffice.org searches for command handlersimplementing the DispatchProvider serviceDispatch Providers create Dispatch objects that are

    bound to the User Interface elementDispatch objects send status informationDispatch objects execute commandsDispatch objects are very lightweight objects

    Default Dispatching process

  • 7/28/2019 OOoCon

    22/25

    Mathias Bauer - OpenOffice.org Application Framework- Slide 22

    Default Dispatching process

    UI

    Document dispatchprovider

    Framework dispatch

    providerBoundcommand

    Frame

    Intercepted dispatching process

  • 7/28/2019 OOoCon

    23/25

    Mathias Bauer - OpenOffice.org Application Framework- Slide 23

    Intercepted dispatching process

    Document dispatchprovider

    Framework dispatch

    provider

    Dispatch Interceptor

    UI

    Bound

    commandFrame

    Complete dispatching process

  • 7/28/2019 OOoCon

    24/25

    Mathias Bauer - OpenOffice.org Application Framework- Slide 24

    Complete dispatching process

    Document dispatchprovider

    Framework dispatch

    provider

    UI

    Bound

    command

    Protocol Handler

    Unknown protocol

    Frame

    Dispatch Interceptor

    OpenOffice.org AddOn concept

  • 7/28/2019 OOoCon

    25/25

    Mathias Bauer - OpenOffice.org Application Framework- Slide 25

    OpenOffice.org AddOn concept

    Chapter 4.7.3 in the OOo 1.1 Developers Guide

    Sample code for Demo Addon in OOo 2.0 SDKJavaC++

    Basic elements:GUI configuration files for menu, toolbarsImages for toolbar and menu entriesProtocol HandlerDispatch Interceptor, Context Menu interceptorEvent ListenersJobsPack up everything into a zip file


Recommended