1cdf0e10cSrcweir/************************************************************************* 2cdf0e10cSrcweir * 3cdf0e10cSrcweir * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4cdf0e10cSrcweir * 5cdf0e10cSrcweir * Copyright 2000, 2010 Oracle and/or its affiliates. 6cdf0e10cSrcweir * 7cdf0e10cSrcweir * OpenOffice.org - a multi-platform office productivity suite 8cdf0e10cSrcweir * 9cdf0e10cSrcweir * This file is part of OpenOffice.org. 10cdf0e10cSrcweir * 11cdf0e10cSrcweir * OpenOffice.org is free software: you can redistribute it and/or modify 12cdf0e10cSrcweir * it under the terms of the GNU Lesser General Public License version 3 13cdf0e10cSrcweir * only, as published by the Free Software Foundation. 14cdf0e10cSrcweir * 15cdf0e10cSrcweir * OpenOffice.org is distributed in the hope that it will be useful, 16cdf0e10cSrcweir * but WITHOUT ANY WARRANTY; without even the implied warranty of 17cdf0e10cSrcweir * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18cdf0e10cSrcweir * GNU Lesser General Public License version 3 for more details 19cdf0e10cSrcweir * (a copy is included in the LICENSE file that accompanied this code). 20cdf0e10cSrcweir * 21cdf0e10cSrcweir * You should have received a copy of the GNU Lesser General Public License 22cdf0e10cSrcweir * version 3 along with OpenOffice.org. If not, see 23cdf0e10cSrcweir * <http://www.openoffice.org/license.html> 24cdf0e10cSrcweir * for a copy of the LGPLv3 License. 25cdf0e10cSrcweir * 26cdf0e10cSrcweir ************************************************************************/ 27cdf0e10cSrcweir 28cdf0e10cSrcweir#ifndef __com_sun_star_ucb_Content_idl__ 29cdf0e10cSrcweir#define __com_sun_star_ucb_Content_idl__ 30cdf0e10cSrcweir 31cdf0e10cSrcweir#include <com/sun/star/ucb/XContent.idl> 32cdf0e10cSrcweir#include <com/sun/star/lang/XComponent.idl> 33cdf0e10cSrcweir#include <com/sun/star/ucb/XCommandProcessor.idl> 34cdf0e10cSrcweir#include <com/sun/star/ucb/XCommandProcessor2.idl> 35cdf0e10cSrcweir#include <com/sun/star/ucb/XCommandInfoChangeNotifier.idl> 36cdf0e10cSrcweir#include <com/sun/star/beans/XPropertyContainer.idl> 37cdf0e10cSrcweir#include <com/sun/star/beans/XPropertySetInfoChangeNotifier.idl> 38cdf0e10cSrcweir#include <com/sun/star/beans/XPropertiesChangeNotifier.idl> 39cdf0e10cSrcweir#include <com/sun/star/ucb/XContentCreator.idl> 40cdf0e10cSrcweir#include <com/sun/star/container/XChild.idl> 41cdf0e10cSrcweir 42cdf0e10cSrcweir//============================================================================= 43cdf0e10cSrcweir 44cdf0e10cSrcweirmodule com { module sun { module star { module ucb { 45cdf0e10cSrcweir 46cdf0e10cSrcweir//============================================================================= 47cdf0e10cSrcweir/** A <type>Content</type> is a service that provides access to data of a 48cdf0e10cSrcweir content provided by an implementation of the service 49cdf0e10cSrcweir <type>ContentProvider</type>. 50cdf0e10cSrcweir*/ 51cdf0e10cSrcweirpublished service Content 52cdf0e10cSrcweir{ 53cdf0e10cSrcweir //------------------------------------------------------------------------- 54cdf0e10cSrcweir /** provides access to the identitity and the type of the content and 55cdf0e10cSrcweir allows the registration of listeners for <type>ContentEvent</type>s. 56cdf0e10cSrcweir 57cdf0e10cSrcweir <p>This interface is required. 58cdf0e10cSrcweir */ 59cdf0e10cSrcweir interface com::sun::star::ucb::XContent; 60cdf0e10cSrcweir 61cdf0e10cSrcweir //------------------------------------------------------------------------- 62cdf0e10cSrcweir /** must be implemented to make it possible to resolve cyclic object 63cdf0e10cSrcweir references. 64cdf0e10cSrcweir 65cdf0e10cSrcweir <p>Those references i.e. may occure if there are listeners 66cdf0e10cSrcweir registered at the content ( the content holds the listeners ) and 67cdf0e10cSrcweir the implementation of the listener interface holds a reference on 68cdf0e10cSrcweir the content. If the content shall be released, 69cdf0e10cSrcweir <member scope="com::sun::star::lang">XComponent::dispose</member> must 70cdf0e10cSrcweir be called at the content. The implementation of this method must call 71cdf0e10cSrcweir <member scope="com::sun::star::lang">XEventListener::disposing</member> 72cdf0e10cSrcweir on the registered listeners and release the appropriate object 73cdf0e10cSrcweir references. At the other hand, the implementation of 74cdf0e10cSrcweir XEventListener::disposing must release its appropriate references. 75cdf0e10cSrcweir 76cdf0e10cSrcweir <p>This interface is required. 77cdf0e10cSrcweir */ 78cdf0e10cSrcweir interface com::sun::star::lang::XComponent; 79cdf0e10cSrcweir 80cdf0e10cSrcweir //------------------------------------------------------------------------- 81cdf0e10cSrcweir /** enables the caller to let the content execute commands. 82cdf0e10cSrcweir 83cdf0e10cSrcweir <p>It is strongly recommended that any implementation supports the 84cdf0e10cSrcweir improved <type>XCommandProcessor2</type> interface.</p> 85cdf0e10cSrcweir 86cdf0e10cSrcweir <p>Typical commands are "open", "delete", "getPropertyValues" and 87cdf0e10cSrcweir "setPropertyValues". Each content must support a set of standard 88cdf0e10cSrcweir commands and properties. Also there is a set of predefined optionally 89cdf0e10cSrcweir commands and properties. A content may define additional commands and 90cdf0e10cSrcweir properties. </p> 91cdf0e10cSrcweir 92cdf0e10cSrcweir <p>This interface is required. </p> 93cdf0e10cSrcweir 94cdf0e10cSrcweir <pre> 95cdf0e10cSrcweir ======================================================================= 96cdf0e10cSrcweir Commands: 97cdf0e10cSrcweir ======================================================================= 98cdf0e10cSrcweir 99cdf0e10cSrcweir [return type] 100cdf0e10cSrcweir [command name] 101cdf0e10cSrcweir [parameter type and name] 102cdf0e10cSrcweir 103cdf0e10cSrcweir ----------------------------------------------------------------------- 104cdf0e10cSrcweir Mandatory commands: 105cdf0e10cSrcweir ----------------------------------------------------------------------- 106cdf0e10cSrcweir 107cdf0e10cSrcweir // This command obtains an interface which allows to query 108cdf0e10cSrcweir // information on commands supported by a content. 109cdf0e10cSrcweir <type>XCommandInfo</type> 110cdf0e10cSrcweir getCommandInfo 111cdf0e10cSrcweir void 112cdf0e10cSrcweir 113cdf0e10cSrcweir // This command obtains an interface which allows to query 114cdf0e10cSrcweir // information on properties supported by a content. 115cdf0e10cSrcweir <type scope="com::sun::star::beans">XPropertySetInfo</type> 116cdf0e10cSrcweir getPropertySetInfo 117cdf0e10cSrcweir void 118cdf0e10cSrcweir 119cdf0e10cSrcweir // This command obtains property values from the content. 120cdf0e10cSrcweir // Note: The execution will not be aborted, if there are properties 121cdf0e10cSrcweir // requested, that are unknown to the content! The returned 122cdf0e10cSrcweir // row object must contain a NULL value in the corresponding 123cdf0e10cSrcweir // column instead. 124cdf0e10cSrcweir <type scope="com::sun::star::sdbc">XRow</type> 125cdf0e10cSrcweir getPropertyValues 126cdf0e10cSrcweir sequence< <type scope="com::sun::star::beans">Property</type> > aProps 127cdf0e10cSrcweir 128cdf0e10cSrcweir // This command sets property values of the content. 129cdf0e10cSrcweir // Note that setPropertyValues does not throw an exception in the case 130cdf0e10cSrcweir // that one or more of the requested property values cannot be set! The 131cdf0e10cSrcweir // implementation should set as much property values as possible. This 132cdf0e10cSrcweir // command returns a sequence< any > which has exactly the same number 133cdf0e10cSrcweir // of elements like the number of properties to set. Every sequence 134cdf0e10cSrcweir // element contains the status for a property. The first sequence 135cdf0e10cSrcweir // elements corresponds to the first element in the sequence of 136cdf0e10cSrcweir // <type scope="com::sun::star::beans">PropertyValue</type> passed as 137cdf0e10cSrcweir // command argument and so on. The exceptions will never be passed to 138cdf0e10cSrcweir // an Interaction Handler. 139cdf0e10cSrcweir // 140cdf0e10cSrcweir // An any containing: 141cdf0e10cSrcweir // 142cdf0e10cSrcweir // - No value indicates, that the property value was set successfully. 143cdf0e10cSrcweir // - <type scope="com::sun::star::beans">UnknownPropertyException</type> 144cdf0e10cSrcweir // indicates, that the property is not known to the content 145cdf0e10cSrcweir // implementation. 146cdf0e10cSrcweir // - <type scope="com::sun::star::beans">IllegalTypeException</type> 147cdf0e10cSrcweir // indicates, that the data type of the property value is not 148cdf0e10cSrcweir // acceptable. 149cdf0e10cSrcweir // - <type scope="com::sun::star::lang">IllegalAccessException</type> 150cdf0e10cSrcweir // indicates, that the property is constant 151cdf0e10cSrcweir // (<member scope="com::sun::star::beans">PropertyAttribute::READONLY</member> 152cdf0e10cSrcweir // is set). 153cdf0e10cSrcweir // - <type scope="com::sun::star::lang">IllegalArgumentException</type> 154cdf0e10cSrcweir // indicates, that the property value is not acceptable. For instance, 155cdf0e10cSrcweir // setting an empty title may be illegal. 156cdf0e10cSrcweir // - Any other execption derived from <type scope="com::sun::star::uno">Exception</type> 157cdf0e10cSrcweir // indicates, that the value was not set successfully. For example, 158cdf0e10cSrcweir // this can be a <type>InteractiveAugmentedIOException</type> 159cdf0e10cSrcweir // transporting the error code <member>IOErrorCode::ACCESS_DENIED</member>. 160cdf0e10cSrcweir // 161cdf0e10cSrcweir // If the value to set is equal to the current value, no exception must 162cdf0e10cSrcweir // be added to the returned sequence 163cdf0e10cSrcweir sequence< any > 164cdf0e10cSrcweir setPropertyValues 165cdf0e10cSrcweir sequence< <type scope="com::sun::star::beans">PropertyValue</type> > aValues 166cdf0e10cSrcweir 167cdf0e10cSrcweir ----------------------------------------------------------------------- 168cdf0e10cSrcweir Optional commands: 169cdf0e10cSrcweir ----------------------------------------------------------------------- 170cdf0e10cSrcweir 171cdf0e10cSrcweir // For folder objects, this command will return an implementation 172cdf0e10cSrcweir // of service <type>DynamicResultSet</type>. 173cdf0e10cSrcweir // 174cdf0e10cSrcweir // The <type>OpenCommandArgument2</type> members must be filled as follows: 175cdf0e10cSrcweir // 176cdf0e10cSrcweir // Mode : ALL or FOLDERS or DOCUMENTS. The implementation 177cdf0e10cSrcweir // of the open command MUST support all these modes! 178cdf0e10cSrcweir // Priority : can be set, but implementation may ignore the value 179cdf0e10cSrcweir // Sink : empty( ignored ) 180cdf0e10cSrcweir // Properties : The properties for that the result set shall 181cdf0e10cSrcweir // contain the property values. The order of the 182cdf0e10cSrcweir // sequence is the same as the order of result set 183cdf0e10cSrcweir // columns. First element of sequence will be row 184cdf0e10cSrcweir // number one, second will be row number two, ... 185cdf0e10cSrcweir // SortingInfo : contains sort criteria, if result set shall 186cdf0e10cSrcweir // be sorted, otherwise it can be left empty. 187cdf0e10cSrcweir // 188cdf0e10cSrcweir // The exceution must be aborted by the implementation of this command 189cdf0e10cSrcweir // (by throwing a <type>CommandAbortedException</type>), if an 190cdf0e10cSrcweir // unsupported mode is requested. 191cdf0e10cSrcweir <type>XDynamicResultSet</type> 192cdf0e10cSrcweir <B>open</B> 193cdf0e10cSrcweir <type>OpenCommandArgument2</type> aOpenCommandArg 194cdf0e10cSrcweir 195cdf0e10cSrcweir // For non-folder objects, the <type>OpenCommandArgument2</type> struct 196cdf0e10cSrcweir // will be prefilled with a data sink object, which will be filled 197cdf0e10cSrcweir // with the content data. 198cdf0e10cSrcweir // 199cdf0e10cSrcweir // The <type>OpenCommandArgument2</type> members must be filled as follows: 200cdf0e10cSrcweir // 201cdf0e10cSrcweir // Mode : DOCUMENT or DOCUMENT_SHARE_DENY_NONE or 202cdf0e10cSrcweir // DOCUMENT_SHARE_DENY_WRITE. Support for DOCUMENT 203cdf0e10cSrcweir // is mandatory, all others are optional. 204cdf0e10cSrcweir // Priority : can be set, but implementation may ignore the value 205cdf0e10cSrcweir // Sink : a sink, where the implementation can put the 206cdf0e10cSrcweir // document data into. 207cdf0e10cSrcweir // Properties : empty ( ignored ) 208cdf0e10cSrcweir // SortingInfo : empty ( ignored ) 209cdf0e10cSrcweir // 210cdf0e10cSrcweir // The exceution must be aborted by the implementation of this command 211cdf0e10cSrcweir // (by throwing a <type>CommandAbortedException</type>), if an 212cdf0e10cSrcweir // unsupported mode is requested. 213cdf0e10cSrcweir void 214cdf0e10cSrcweir <B>open</B> 215cdf0e10cSrcweir <type>OpenCommandArgument2</type> aOpenCommandArg 216cdf0e10cSrcweir 217cdf0e10cSrcweir // This command triggers an update operation on a content. For example, 218cdf0e10cSrcweir // when "updating" a POP3-Inbox, the content for that box will get 219cdf0e10cSrcweir // and store all new objects on the appropriate server. The inserted 220cdf0e10cSrcweir // contents will be notified by calling 221cdf0e10cSrcweir // <member>XContentEventListener::contentEvent</member>. 222cdf0e10cSrcweir void 223cdf0e10cSrcweir <B>update</B> 224cdf0e10cSrcweir <type>OpenCommandArgument2</type> aOpenCommandArg 225cdf0e10cSrcweir 226cdf0e10cSrcweir // This command triggers a synchronization operation between locally 227cdf0e10cSrcweir // cached data and remote server's data. For example, when 228cdf0e10cSrcweir // "synchronizing" a POP3-Inbox the content for that box will get and 229cdf0e10cSrcweir // store all new objects and destroy all cached data for objects no 230cdf0e10cSrcweir // longer existing on the server. The inserted/deleted contents will 231cdf0e10cSrcweir // be notified by calling 232cdf0e10cSrcweir // <member>XContent::contentEvent</member>. 233cdf0e10cSrcweir void 234cdf0e10cSrcweir <B>synchronize</B> 235cdf0e10cSrcweir <type>OpenCommandArgument2</type> aOpenCommandArg 236cdf0e10cSrcweir 237cdf0e10cSrcweir // This command closes an object. 238cdf0e10cSrcweir void 239cdf0e10cSrcweir <B>close</B> 240cdf0e10cSrcweir void 241cdf0e10cSrcweir 242cdf0e10cSrcweir // This command deletes an object. If <TRUE/> is passed as parameter, 243cdf0e10cSrcweir // the object will be destroyed physically. Otherwise it will be put 244cdf0e10cSrcweir // into trash can, if such a service is available and the object to 245cdf0e10cSrcweir // be deleted supports the command "undelete". 246cdf0e10cSrcweir // On successful completion of this command, the deleted content 247cdf0e10cSrcweir // must propagate its deletion by notifying a <type>ContentEvent</type> 248cdf0e10cSrcweir // - <member>ContentAction::DELETED</member>. Additionally, the contents 249cdf0e10cSrcweir // parent must notify a <type>ContentEvent</type> 250cdf0e10cSrcweir // - <member>ContentAction::REMOVED</member> 251cdf0e10cSrcweir void 252cdf0e10cSrcweir <B>delete</B> 253cdf0e10cSrcweir boolean bDeletePhysically 254cdf0e10cSrcweir 255cdf0e10cSrcweir // This command restores an object previously deleted into trash. It 256cdf0e10cSrcweir // must be supported by objects which claim to be undeletable, but 257cdf0e10cSrcweir // should never be called directly. 258cdf0e10cSrcweir void 259cdf0e10cSrcweir <B>undelete</B> 260cdf0e10cSrcweir void 261cdf0e10cSrcweir 262cdf0e10cSrcweir // (1) This command inserts a new content. It commits the process of 263cdf0e10cSrcweir // creating a new content via executing the command "createNewContent" 264cdf0e10cSrcweir // and initializing it via setting properties, afterwards. 265cdf0e10cSrcweir // The command is not called on the content which created the new 266cdf0e10cSrcweir // content, because the new object already knows where it is to be 267cdf0e10cSrcweir // inserted (i.e. Calling createNewContent with the content type for a 268cdf0e10cSrcweir // message on a News Group creates a content which internally belongs 269cdf0e10cSrcweir // to the Outbox. Calling "insert" on that message will result in 270cdf0e10cSrcweir // posting the article to the appropriate News Group). Not calling 271cdf0e10cSrcweir // "insert" for the new content, i.e. because the user cancels writing 272cdf0e10cSrcweir // a new message, simply discards the new object. No extra call to 273cdf0e10cSrcweir // "delete" is necessary. 274cdf0e10cSrcweir // On successful completion of this command, the parent of the inserted 275cdf0e10cSrcweir // content must propagate the change by notifying a 276cdf0e10cSrcweir // <type>ContentEvent</type> - <member>ContentAction::INSERTED</member>. 277cdf0e10cSrcweir // 278cdf0e10cSrcweir // (2) Additionally this command can be called at any time to overwrite 279cdf0e10cSrcweir // the data of an existing content. 280cdf0e10cSrcweir void 281cdf0e10cSrcweir <B>insert</B> 282cdf0e10cSrcweir <type>InsertCommandArgument</type> aInsertCommandArg 283cdf0e10cSrcweir 284cdf0e10cSrcweir // This command searches for subcontents of a content matching the 285cdf0e10cSrcweir // given search criteria. The command will return an implemenation 286cdf0e10cSrcweir // of service <type>DynamicResultSet</type>. 287cdf0e10cSrcweir <type>XDynamicResultSet</type> 288cdf0e10cSrcweir <B>search</B> 289cdf0e10cSrcweir <type>SearchCommandArgument</type> aSearchCommandArg 290cdf0e10cSrcweir 291cdf0e10cSrcweir // <b>Important note:</b> A client that wants to transfer data should 292cdf0e10cSrcweir // not execute this command, but it should execute the command 293cdf0e10cSrcweir // "globalTransfer" at the <type>UniversalContentBroker</type>. 294cdf0e10cSrcweir // This command is able to transfer all kind of content 295cdf0e10cSrcweir // supported by that UCB. 296cdf0e10cSrcweir // 297cdf0e10cSrcweir // This command transfers (copies/moves) an object from one location 298cdf0e10cSrcweir // to another. It must be executed at the folder content representing 299cdf0e10cSrcweir // the destination of the transfer operation. Note that the 300cdf0e10cSrcweir // implementation need not(!) be able to handle any type of contents. 301cdf0e10cSrcweir // Generally, there are good chances that a transfer of a content will 302cdf0e10cSrcweir // succeed, if source and target folder have the same URL scheme. 303cdf0e10cSrcweir // But there is no guaranty for that. For instance, moving a message 304cdf0e10cSrcweir // from a folder on IMAP server A to a folder on IMAP server B may 305cdf0e10cSrcweir // fail, because the transfer command can't be implemented efficiently 306cdf0e10cSrcweir // for this scenario, because it is not directly supported by the IMAP 307cdf0e10cSrcweir // protocol. On the other hand, moving a message from one folder to 308cdf0e10cSrcweir // another folder on the same IMAP server should work, because it can 309cdf0e10cSrcweir // be implemeted efficiently. If an implementation is not able to 310cdf0e10cSrcweir // handle a given source URL, it should indicate this by issuing a 311cdf0e10cSrcweir // <type>InteractiveBadTransferURLException</type> interaction request. 312cdf0e10cSrcweir // Source and target folder may be the same when doing a move operation. 313cdf0e10cSrcweir // 314cdf0e10cSrcweir // Transfers without the transfer command can be done as follows: 315cdf0e10cSrcweir // 316cdf0e10cSrcweir // 1) Create a new content at the target folder 317cdf0e10cSrcweir // --> targetContent = target.execute( "createNewContent", type ) 318cdf0e10cSrcweir // 2) Transfer data from source to target content 319cdf0e10cSrcweir // --> props = sourceContent.execute( "getPropertyValues", ... ) 320cdf0e10cSrcweir // --> dataStream = sourceContent.execute( "open", ... ) 321cdf0e10cSrcweir // --> targetContent.execute( "setPropertyValues", props ) 322cdf0e10cSrcweir // 3) Insert ( commit ) the new content 323cdf0e10cSrcweir // --> targetContent.execute( "insert", dataStream ) 324cdf0e10cSrcweir // 4) For move operations only: destroy the source content 325cdf0e10cSrcweir // sourceContent.execute( "delete", ... ) 326cdf0e10cSrcweir // 327cdf0e10cSrcweir // This mechanism should work for all transfer operations, but generally 328cdf0e10cSrcweir // it's less efficient than the transfer command. 329cdf0e10cSrcweir void 330cdf0e10cSrcweir <B>transfer</B> 331cdf0e10cSrcweir <type>TransferInfo</type> aTransferInfo 332cdf0e10cSrcweir 333cdf0e10cSrcweir // This command obtains an exlusive write lock for the resource. The 334cdf0e10cSrcweir // lock is active until command "unlock" is executed or the OOo 335cdf0e10cSrcweir // session that obtained the lock ends or until the lock is released by 336cdf0e10cSrcweir // a third party (e.g. a system administrator). 337cdf0e10cSrcweir void 338cdf0e10cSrcweir <B>lock</B> 339cdf0e10cSrcweir void 340cdf0e10cSrcweir Exceptions: <type>InteractiveLockingLockedException</type> 341cdf0e10cSrcweir <type>InteractiveLockingLockExpiredException</type> 342cdf0e10cSrcweir 343cdf0e10cSrcweir // This command removes a lock obtained by executing the command "lock" 344cdf0e10cSrcweir // from the resource. 345cdf0e10cSrcweir void 346cdf0e10cSrcweir <B>unlock</B> 347cdf0e10cSrcweir void 348cdf0e10cSrcweir Exceptions: <type>InteractiveLockingNotLockedException</type> 349cdf0e10cSrcweir <type>InteractiveLockingLockExpiredException</type> 350cdf0e10cSrcweir 351cdf0e10cSrcweir // Note that <type>InteractiveLockingLockExpiredException</type> might 352cdf0e10cSrcweir // be raised by any command that requires a previously obtained lock. 353cdf0e10cSrcweir 354cdf0e10cSrcweir // This command creates a new non-persistent content of a given type. 355cdf0e10cSrcweir // 356cdf0e10cSrcweir // <p>Creation of a new (persistent) content: 357cdf0e10cSrcweir // <ol> 358cdf0e10cSrcweir // <li>creatabletypes = obtain "CreatableContentsInfo" property<br> 359cdf0e10cSrcweir // from creator 360cdf0e10cSrcweir // <li>choose a suitable type from creatabletypes 361cdf0e10cSrcweir // <li>newObject = execute command "createNewContent(type)" at<br> 362cdf0e10cSrcweir // creator 363cdf0e10cSrcweir // <li>initialize the new object (i.e. newObject.Property1 = ...) 364cdf0e10cSrcweir // <li>execute command "insert" at new content. This command 365cdf0e10cSrcweir // commits the data and makes the new content persistent. 366cdf0e10cSrcweir // </ol> 367cdf0e10cSrcweir // 368cdf0e10cSrcweir // This command must be supported by every Content that supports the 369cdf0e10cSrcweir // property "CreatableContentsInfo" if the returned property value 370cdf0e10cSrcweir // contains a non-empty sequence of creatable types. 371cdf0e10cSrcweir // 372cdf0e10cSrcweir // Note: This command is part of the replacement for the deprecated 373cdf0e10cSrcweir // interface <type>XContentCreator</type>. 374cdf0e10cSrcweir <type>XContent</type> > 375cdf0e10cSrcweir <B>createNewContent</B> 376cdf0e10cSrcweir <type>ContentInfo<type> contentinfo 377cdf0e10cSrcweir 378cdf0e10cSrcweir ======================================================================= 379cdf0e10cSrcweir Properties: 380cdf0e10cSrcweir ======================================================================= 381cdf0e10cSrcweir 382cdf0e10cSrcweir ----------------------------------------------------------------------- 383cdf0e10cSrcweir Mandatory properties: 384cdf0e10cSrcweir ----------------------------------------------------------------------- 385cdf0e10cSrcweir 386cdf0e10cSrcweir // contains a unique(!) type string for the content ( i.e. 387cdf0e10cSrcweir // "application/vnd.sun.star.hierarchy-link" ). This property is always 388cdf0e10cSrcweir // read-only. It does not contain the media type ( MIME types ) of the 389cdf0e10cSrcweir // content. Media types may be provided through the optional property 390cdf0e10cSrcweir // "MediaType". 391cdf0e10cSrcweir // The value of this property should match the information on creatable 392cdf0e10cSrcweir // contents given by UCB contents that implement the property 393cdf0e10cSrcweir // "CreatableContentsInfo". 394cdf0e10cSrcweir string ContentType 395cdf0e10cSrcweir 396cdf0e10cSrcweir // indicates, whether a content can contain other contents. 397cdf0e10cSrcweir boolean IsFolder 398cdf0e10cSrcweir 399cdf0e10cSrcweir // indicates, whether a content is a document. This means, the 400cdf0e10cSrcweir // content can dump itself into a data sink. 401cdf0e10cSrcweir boolean IsDocument 402cdf0e10cSrcweir 403cdf0e10cSrcweir // contains the title of an object (e.g. the subject of a message). 404cdf0e10cSrcweir string Title; 405cdf0e10cSrcweir 406cdf0e10cSrcweir ----------------------------------------------------------------------- 407cdf0e10cSrcweir Optional properties: 408cdf0e10cSrcweir ----------------------------------------------------------------------- 409cdf0e10cSrcweir 410cdf0e10cSrcweir // contains the interval for automatic updates of an object. 411cdf0e10cSrcweir // It is specified in seconds. 412cdf0e10cSrcweir long AutoUpdateInterval 413cdf0e10cSrcweir 414cdf0e10cSrcweir // contains the maximum number of network connections 415cdf0e10cSrcweir // allowed for one (internet) protocol at a time. (e.g. The HTTP 416cdf0e10cSrcweir // cache can be configured to use a maximum for the number of 417cdf0e10cSrcweir // connections used for browsing.) 418cdf0e10cSrcweir short ConnectionLimit 419cdf0e10cSrcweir 420cdf0e10cSrcweir // contains the current connection mode for the object. 421cdf0e10cSrcweir // (see <type>ConnectionMode</type>) 422cdf0e10cSrcweir short ConnectionMode 423cdf0e10cSrcweir 424cdf0e10cSrcweir // contains the date and time the object was created. 425cdf0e10cSrcweir <type scope"com::sun::star::util">DateTime</type> DateCreated 426cdf0e10cSrcweir 427cdf0e10cSrcweir // contains the date and time the object was last modified. 428cdf0e10cSrcweir <type scope"com::sun::star::util">DateTime</type> DateModified 429cdf0e10cSrcweir 430cdf0e10cSrcweir // contains the count of documents of a folder. 431cdf0e10cSrcweir long DocumentCount; 432cdf0e10cSrcweir 433cdf0e10cSrcweir // contains the count of marked documents within a folder. 434cdf0e10cSrcweir long DocumentCountMarked 435cdf0e10cSrcweir 436cdf0e10cSrcweir // contains a sequence of documemt header fields (i.e. header 437cdf0e10cSrcweir // fields of a MIME-message, or the document info of an 438cdf0e10cSrcweir // office document ). For some standard header fields there 439cdf0e10cSrcweir // are predefined separate properties, like "MessageTo". 440cdf0e10cSrcweir sequence< <type>DocumentHeaderField</type> > DocumentHeader 441cdf0e10cSrcweir 442cdf0e10cSrcweir // contains information about the way a folder stores the 443cdf0e10cSrcweir // contents of (remote) documents. 444cdf0e10cSrcweir <type>DocumentStoreMode</type> DocumentStoreMode 445cdf0e10cSrcweir 446cdf0e10cSrcweir // contains the count of subfolders of a folder. 447cdf0e10cSrcweir long FolderCount 448cdf0e10cSrcweir 449cdf0e10cSrcweir // contains the free space left on a storage device. It is 450*7c6ca970SHerbert Dürr // specified in bytes. 451cdf0e10cSrcweir hyper FreeSpace 452cdf0e10cSrcweir 453cdf0e10cSrcweir // indicates whether a content has subcontents, which are documents. 454cdf0e10cSrcweir boolean HasDocuments 455cdf0e10cSrcweir 456cdf0e10cSrcweir // indicates whether a content has subcontents, which are folders. 457cdf0e10cSrcweir boolean HasFolders 458cdf0e10cSrcweir 459cdf0e10cSrcweir // indicates whether a content is "marked". 460cdf0e10cSrcweir boolean IsMarked 461cdf0e10cSrcweir 462cdf0e10cSrcweir // indicates whether a content has been "read". 463cdf0e10cSrcweir boolean IsRead; 464cdf0e10cSrcweir 465cdf0e10cSrcweir // indicates whether a content is read-only. 466cdf0e10cSrcweir boolean IsReadOnly 467cdf0e10cSrcweir 468cdf0e10cSrcweir // indicates whether a content is subscribed. 469cdf0e10cSrcweir boolean IsSubscribed 470cdf0e10cSrcweir 471cdf0e10cSrcweir // indicates whether the feature to store contents depending on 472cdf0e10cSrcweir // their age is active. 473cdf0e10cSrcweir boolean IsTimeLimitedStore; 474cdf0e10cSrcweir 475cdf0e10cSrcweir // indicates whether (sub)contents shall be automatically updated 476cdf0e10cSrcweir // everytime a (folder) content is opened. This property may be 477cdf0e10cSrcweir // used to control whether a folder content should read data only 478cdf0e10cSrcweir // from local cache when it is opened, or whether it should connect 479cdf0e10cSrcweir // to a server to obtain latest data. 480cdf0e10cSrcweir boolean UpdateOnOpen 481cdf0e10cSrcweir 482cdf0e10cSrcweir // contains the keywords of a document (e.g. the value 483cdf0e10cSrcweir // of the "keywords" header field of a news article). 484cdf0e10cSrcweir string Keywords 485cdf0e10cSrcweir 486cdf0e10cSrcweir // contains the media type ( MIME type ) of a content. It is highly 487cdf0e10cSrcweir // recommended to support this property if the content's implementation 488cdf0e10cSrcweir // can obtain the media type natively from its data source ( i.e. 489cdf0e10cSrcweir // HTTP servers provide media types for all their documents ). 490cdf0e10cSrcweir string MediaType 491cdf0e10cSrcweir 492cdf0e10cSrcweir // contains the BCC (blind carbon copy) receiver(s) of a message. 493cdf0e10cSrcweir string MessageBCC 494cdf0e10cSrcweir 495cdf0e10cSrcweir // contains the CC (carbon copy) receiver(s) of a message. 496cdf0e10cSrcweir string MessageCC 497cdf0e10cSrcweir 498cdf0e10cSrcweir // contains (the address of) the sender of a message. 499cdf0e10cSrcweir string MessageFrom 500cdf0e10cSrcweir 501cdf0e10cSrcweir // contains the ID of a message. 502cdf0e10cSrcweir string MessageId 503cdf0e10cSrcweir 504cdf0e10cSrcweir // contains the "In-Reply-To" field of a message. 505cdf0e10cSrcweir string MessageInReplyTo 506cdf0e10cSrcweir 507cdf0e10cSrcweir // contains the "Reply-To" field of a message. 508cdf0e10cSrcweir string MessageReplyTo 509cdf0e10cSrcweir 510cdf0e10cSrcweir // contains the recipient(s) of a message. 511cdf0e10cSrcweir string MessageTo 512cdf0e10cSrcweir 513cdf0e10cSrcweir // contains the name(s) of the newsgroup(s) into which a message 514cdf0e10cSrcweir // was posted. 515cdf0e10cSrcweir string NewsGroups 516cdf0e10cSrcweir 517cdf0e10cSrcweir // contains a password (e.g. needed to access a POP3-Server). 518cdf0e10cSrcweir string Password 519cdf0e10cSrcweir 520cdf0e10cSrcweir // contains a priority (i.e. of a message). 521cdf0e10cSrcweir <type>Priority</type> Priority 522cdf0e10cSrcweir 523cdf0e10cSrcweir // contains the "References" field of a news article. 524cdf0e10cSrcweir string References 525cdf0e10cSrcweir 526cdf0e10cSrcweir // contains the rules set for a content. 527cdf0e10cSrcweir <type>RuleSet</type> Rules 528cdf0e10cSrcweir 529cdf0e10cSrcweir // contains the count of seen/read subcontents of a folder content. 530cdf0e10cSrcweir long SeenCount 531cdf0e10cSrcweir 532cdf0e10cSrcweir // contains the base directory to use on a server. (e.g. Setting 533cdf0e10cSrcweir // the server base of an FTP-Account to "/pub/incoming" 534cdf0e10cSrcweir // will result in showing contents from that directory and not from 535cdf0e10cSrcweir // server's root directory) 536cdf0e10cSrcweir string ServerBase 537cdf0e10cSrcweir 538cdf0e10cSrcweir // contains a server name (e.g. The name of the server to use for 539cdf0e10cSrcweir // a POP3-Account). 540cdf0e10cSrcweir string ServerName 541cdf0e10cSrcweir 542cdf0e10cSrcweir // contains a numeric server port. 543cdf0e10cSrcweir short ServerPort 544cdf0e10cSrcweir 545cdf0e10cSrcweir // contains the size (usually in bytes) of an object. 546cdf0e10cSrcweir hyper Size 547cdf0e10cSrcweir 548cdf0e10cSrcweir // contains a size limit for an object. (e.g. One may specify the 549cdf0e10cSrcweir // maximum size of the HTTP-Cache) 550cdf0e10cSrcweir hyper SizeLimit 551cdf0e10cSrcweir 552cdf0e10cSrcweir // contains the count of subscribed contents of a folder. 553cdf0e10cSrcweir long SubscribedCount 554cdf0e10cSrcweir 555cdf0e10cSrcweir // contains the policy to use when synchronizing two objects. 556cdf0e10cSrcweir <type>SynchronizePolicy</type> SynchronizePolicy 557cdf0e10cSrcweir 558cdf0e10cSrcweir // contains information about the target frame to use when displaying 559cdf0e10cSrcweir // an object. 560cdf0e10cSrcweir 561cdf0e10cSrcweir <p>The value is a string containing three tokens, separated by ";" 562cdf0e10cSrcweir (A semicolon):<br/> 563cdf0e10cSrcweir <dl> 564cdf0e10cSrcweir <dt>1st token 565cdf0e10cSrcweir </dt><dd>Behavior on "select" ( single click ) 566cdf0e10cSrcweir </dd><dt>2nd token 567cdf0e10cSrcweir </dt><dd>Behavior on "open" ( double click ) 568cdf0e10cSrcweir </dd><dt>3rd token 569cdf0e10cSrcweir </dt><dd>Behavior on "open in new task" ( double click + CTRL key ) 570cdf0e10cSrcweir </dd></dl> 571cdf0e10cSrcweir </p> 572cdf0e10cSrcweir <p> Each token may contain the following values:<br/> 573cdf0e10cSrcweir <dl> 574cdf0e10cSrcweir <dt>"_beamer" 575cdf0e10cSrcweir </dt><dd>Show in "Beamer" 576cdf0e10cSrcweir </dd><dt>"_top" 577cdf0e10cSrcweir </dt><dd>Show in current frame (replaces old) 578cdf0e10cSrcweir </dd><dt>"_blank" 579cdf0e10cSrcweir </dt><dd>Show in new task 580cdf0e10cSrcweir </dd></dl> 581cdf0e10cSrcweir </p> 582cdf0e10cSrcweir string TargetFrames 583cdf0e10cSrcweir 584cdf0e10cSrcweir // for contents that are links to other contents, contains the URL of 585cdf0e10cSrcweir // the target content 586cdf0e10cSrcweir string TargetURL 587cdf0e10cSrcweir 588cdf0e10cSrcweir // contains the value to use if the property "IsTimeLimitedStore" is set. 589cdf0e10cSrcweir short TimeLimitStore; 590cdf0e10cSrcweir 591cdf0e10cSrcweir // contains a user name. (e.g. the user name needed to access a 592cdf0e10cSrcweir // POP3-Account) 593cdf0e10cSrcweir string UserName 594cdf0e10cSrcweir 595cdf0e10cSrcweir // describes a verification policy. 596cdf0e10cSrcweir <type>VerificationMode</type> VerificationMode 597cdf0e10cSrcweir 598cdf0e10cSrcweir // contains the types of Contents a Content object can create via 599cdf0e10cSrcweir // command "createNewContent". 600cdf0e10cSrcweir // 601cdf0e10cSrcweir // If the property value can be a non-empty sequence, the Content must 602cdf0e10cSrcweir // also support command "createNewContent". 603cdf0e10cSrcweir // 604cdf0e10cSrcweir // Note: This property is part of the replacement for the deprecated 605cdf0e10cSrcweir // interface <type>XContentCreator</type>. 606cdf0e10cSrcweir sequence <type>ContentInfo</type> CreatableContentsInfo 607cdf0e10cSrcweir 608cdf0e10cSrcweir </pre> 609cdf0e10cSrcweir */ 610cdf0e10cSrcweir interface com::sun::star::ucb::XCommandProcessor; 611cdf0e10cSrcweir 612cdf0e10cSrcweir //------------------------------------------------------------------------- 613cdf0e10cSrcweir /** is an enhanced version of <type>XCommandProcessor</type> that has an 614cdf0e10cSrcweir additional method for releasing command identifiers obtained via 615cdf0e10cSrcweir <member>XCommandProcessor::createCommandIdentifier</member> to avoid 616cdf0e10cSrcweir resource leaks. For a detailed description of the problem refer to 617cdf0e10cSrcweir <member>XCommandProcessor2::releaseCommandIdentifier</member>. 618cdf0e10cSrcweir 619cdf0e10cSrcweir <p>Where many existing <type>Content</type> implementations do not 620cdf0e10cSrcweir (yet), every new implementation should support this interface. 621cdf0e10cSrcweir */ 622cdf0e10cSrcweir [optional] interface com::sun::star::ucb::XCommandProcessor2; 623cdf0e10cSrcweir 624cdf0e10cSrcweir //------------------------------------------------------------------------- 625cdf0e10cSrcweir /** notifies changes of property values to listeners registered for 626cdf0e10cSrcweir those properties. 627cdf0e10cSrcweir 628cdf0e10cSrcweir <p>This interface is required. 629cdf0e10cSrcweir */ 630cdf0e10cSrcweir interface com::sun::star::beans::XPropertiesChangeNotifier; 631cdf0e10cSrcweir 632cdf0e10cSrcweir //------------------------------------------------------------------------- 633cdf0e10cSrcweir /** can be used to add new properties to the content and to remove 634cdf0e10cSrcweir properties from the content dynamically. 635cdf0e10cSrcweir 636cdf0e10cSrcweir <p>Note that the dynamic properties must be kept persistent. The 637cdf0e10cSrcweir service <type>Store</type> (UCB persistence service) may be used to 638cdf0e10cSrcweir implement this. 639cdf0e10cSrcweir 640cdf0e10cSrcweir <p><b>Important:</b> The implementation of 641cdf0e10cSrcweir <method scope="com::sun::star::beans">XPropertyContainer::addProperty</method> 642cdf0e10cSrcweir must at least support adding properties of the following basic data 643cdf0e10cSrcweir types: 644cdf0e10cSrcweir 645cdf0e10cSrcweir <p> 646cdf0e10cSrcweir <ul> 647cdf0e10cSrcweir <li>boolean 648cdf0e10cSrcweir <li>char 649cdf0e10cSrcweir <li>byte 650cdf0e10cSrcweir <li>string 651cdf0e10cSrcweir <li>short 652cdf0e10cSrcweir <li>long 653cdf0e10cSrcweir <li>hyper 654cdf0e10cSrcweir <li>float 655cdf0e10cSrcweir <li>double 656cdf0e10cSrcweir </ul> 657cdf0e10cSrcweir 658cdf0e10cSrcweir <p>If a property with an unsupported type shall be added a 659cdf0e10cSrcweir <type scope="com::sun::star::beans">IllegalTypeException</type> must 660cdf0e10cSrcweir be raised. 661cdf0e10cSrcweir */ 662cdf0e10cSrcweir interface com::sun::star::beans::XPropertyContainer; 663cdf0e10cSrcweir 664cdf0e10cSrcweir //------------------------------------------------------------------------- 665cdf0e10cSrcweir /** can be used to notify properties removed from or added to the 666cdf0e10cSrcweir content's property set. 667cdf0e10cSrcweir 668cdf0e10cSrcweir <p>This interface must be implemented, if the implementation can 669cdf0e10cSrcweir dynamically change it's property set ( e.g. because it implements 670cdf0e10cSrcweir the interface 671cdf0e10cSrcweir <type scope="com::sun::star::beans">XPropertyContainer</type>. ) 672cdf0e10cSrcweir */ 673cdf0e10cSrcweir [optional] interface com::sun::star::beans::XPropertySetInfoChangeNotifier; 674cdf0e10cSrcweir 675cdf0e10cSrcweir //------------------------------------------------------------------------- 676cdf0e10cSrcweir /** can be used to notify commands removed from or added to the 677cdf0e10cSrcweir content's command set. 678cdf0e10cSrcweir 679cdf0e10cSrcweir <p>This interface must be implemented, if the implementation can 680cdf0e10cSrcweir dynamically change it's command set ( e.g. because the set of 681cdf0e10cSrcweir available commands depends on the value of a property of the 682cdf0e10cSrcweir content ). 683cdf0e10cSrcweir 684cdf0e10cSrcweir <p>This interface is optional. 685cdf0e10cSrcweir */ 686cdf0e10cSrcweir [optional] interface com::sun::star::ucb::XCommandInfoChangeNotifier; 687cdf0e10cSrcweir 688cdf0e10cSrcweir //------------------------------------------------------------------------- 689cdf0e10cSrcweir /** creates new contents (i.e. creates a new folder in another folder 690cdf0e10cSrcweir somewhere in the local file system). 691cdf0e10cSrcweir 692cdf0e10cSrcweir <p>A content is "new", if it does not physically exist before creating 693cdf0e10cSrcweir it using this interface. 694cdf0e10cSrcweir 695cdf0e10cSrcweir <p>This interface is optional. It should be implemented by contents 696cdf0e10cSrcweir which shall be able to create new objects. 697cdf0e10cSrcweir 698cdf0e10cSrcweir @deprecated 699cdf0e10cSrcweir 700cdf0e10cSrcweir <p>This interface is <b>deprecated</b>. Use property 701cdf0e10cSrcweir "CreatableContentsInfo" and command "createNewContent" instead. 702cdf0e10cSrcweir */ 703cdf0e10cSrcweir [optional] interface com::sun::star::ucb::XContentCreator; 704cdf0e10cSrcweir 705cdf0e10cSrcweir //------------------------------------------------------------------------- 706cdf0e10cSrcweir /** provides access to the parent content of this content. 707cdf0e10cSrcweir 708cdf0e10cSrcweir <p>The object returned by the implementation of the method 709cdf0e10cSrcweir <member scope="com::sun::star::container">XChild::getParent()</member> 710cdf0e10cSrcweir must implement the service <type>Content</type>. If the content is a 711cdf0e10cSrcweir root object, an empty interface may be returned. 712cdf0e10cSrcweir 713cdf0e10cSrcweir <p>This interface must be implemented by a content which is a (logical) 714cdf0e10cSrcweir child of a content. 715cdf0e10cSrcweir */ 716cdf0e10cSrcweir [optional] interface com::sun::star::container::XChild; 717cdf0e10cSrcweir}; 718cdf0e10cSrcweir 719cdf0e10cSrcweir//============================================================================= 720cdf0e10cSrcweir 721cdf0e10cSrcweir}; }; }; }; 722cdf0e10cSrcweir 723cdf0e10cSrcweir#endif 724*7c6ca970SHerbert Dürr 725