LibreOffice LibreOffice 25.8 SDK API Reference

Public Member Functions | List of all members
XSimpleFileAccess2 Interface Referencepublished

This is an extension to the interface XSimpleFileAccess. More...

`import"XSimpleFileAccess2.idl";`

Inheritance diagram for XSimpleFileAccess2:

## Public Member Functions
void | writeFile ([in] string FileURL, [in] com::sun::star::io::XInputStream data) raises ( com::sun::star::uno::Exception )
| Overwrites the file content with the given data. More...
Public Member Functions inherited from XSimpleFileAccess
void | copy ([in] string SourceURL, [in] string DestURL) raises ( com::sun::star::ucb::CommandAbortedException, com::sun::star::uno::Exception )
| Copies a file. More...
void | move ([in] string SourceURL, [in] string DestURL) raises ( com::sun::star::ucb::CommandAbortedException, com::sun::star::uno::Exception )
| Moves a file. More...
void | kill ([in] string FileURL) raises ( com::sun::star::ucb::CommandAbortedException, com::sun::star::uno::Exception )
| Removes a file. More...
boolean | isFolder ([in] string FileURL) raises ( com::sun::star::ucb::CommandAbortedException, com::sun::star::uno::Exception )
| Checks if a URL represents a folder. More...
boolean | isReadOnly ([in] string FileURL) raises ( com::sun::star::ucb::CommandAbortedException, com::sun::star::uno::Exception )
| Checks if a file is "read only". More...
void | setReadOnly ([in] string FileURL, [in] boolean bReadOnly) raises ( com::sun::star::ucb::CommandAbortedException, com::sun::star::uno::Exception )
| Sets the "read only" of a file according to the boolean parameter, if the actual process has the right to do so. More...
void | createFolder ([in] string NewFolderURL) raises ( com::sun::star::ucb::CommandAbortedException, com::sun::star::uno::Exception )
| Creates a new Folder. More...
long | getSize ([in] string FileURL) raises ( com::sun::star::ucb::CommandAbortedException, com::sun::star::uno::Exception )
| Returns the size of a file. More...
string | getContentType ([in] string FileURL) raises ( com::sun::star::ucb::CommandAbortedException, com::sun::star::uno::Exception )
| Returns the content type of a file. More...
::com::sun::star::util::DateTime | getDateTimeModified ([in] string FileURL) raises ( com::sun::star::ucb::CommandAbortedException, com::sun::star::uno::Exception )
| Returns the last modified date for the file. More...
sequence< string > | getFolderContents ([in] string FolderURL, [in] boolean bIncludeFolders) raises ( com::sun::star::ucb::CommandAbortedException, com::sun::star::uno::Exception )
| Returns the contents of a folder. More...
boolean | exists ([in] string FileURL) raises ( com::sun::star::ucb::CommandAbortedException, com::sun::star::uno::Exception )
| Checks if a file exists. More...
com::sun::star::io::XInputStream | openFileRead ([in] string FileURL) raises ( com::sun::star::ucb::CommandAbortedException, com::sun::star::uno::Exception )
| Opens file to read. More...
com::sun::star::io::XOutputStream | openFileWrite ([in] string FileURL) raises ( com::sun::star::ucb::CommandAbortedException, com::sun::star::uno::Exception )
| Opens file to write. More...
com::sun::star::io::XStream | openFileReadWrite ([in] string FileURL) raises ( com::sun::star::ucb::CommandAbortedException, com::sun::star::uno::Exception )
| Opens file to read and write. More...
void | setInteractionHandler ([in] com::sun::star::task::XInteractionHandler Handler)
| Sets an interaction handler to be used for further operations. More...
Public Member Functions inherited from XInterface
any | queryInterface ([in] type aType)
| queries for a new interface to an existing UNO object. More...
void | acquire ()
| increases the reference counter by one. More...
void | release ()
| decreases the reference counter by one. More...

## Detailed Description

This is an extension to the interface XSimpleFileAccess.

## Member Function Documentation

## ◆ writeFile()

void writeFile | ( | [in] string | FileURL,
|  | [in] com::sun::star::io::XInputStream | data
| ) |  |
raises | ( | com::sun::star::uno::Exception
| ) |  |

Overwrites the file content with the given data.

If the file does not exist, it will be created.

Parameters

  FileURL | File to write
  data | A stream containing the data for the file to be (over-)written

The documentation for this interface was generated from the following file:

- com/sun/star/ucb/XSimpleFileAccess2.idl