/************************************************************************* * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * Copyright 2009 by Sun Microsystems, Inc. * * OpenOffice.org - a multi-platform office productivity suite * * This file is part of OpenOffice.org. * * OpenOffice.org is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License version 3 * only, as published by the Free Software Foundation. * * OpenOffice.org is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Lesser General Public License version 3 for more details * (a copy is included in the LICENSE file that accompanied this code). * * You should have received a copy of the GNU Lesser General Public License * version 3 along with OpenOffice.org. If not, see * * for a copy of the LGPLv3 License. ************************************************************************/ #ifndef __offapcom_sun_star_document_XDocumentRecovery_idl__ #define __offapcom_sun_star_document_XDocumentRecovery_idl__ #include #include #include //============================================================================= module com { module sun { module star { module document { //============================================================================= /** is the interface to be implemented by documents who wish to participate in the document emergency-save / recovery process. */ interface XDocumentRecovery { /** does an emergency save of the document @param TargetLocation specifies the URL of the location to which the document should be emergency-saved. @param MediaDescriptor contains additional arguments for the save process, for instance an StatusIndicator. @see MediaDescriptor */ void doEmergencySave( [in] string TargetLocation, [in] sequence< ::com::sun::star::beans::PropertyValue > MediaDescriptor ) raises ( ::com::sun::star::io::IOException, ::com::sun::star::lang::WrappedTargetException ); /** recovers the document after a previous emergency save. The document itself has previously been created, but not loaded (via XLoadable::load) or initialized (via XLoadable::initNew). @param SourceLocation specifies the URL of the location to which the document was previously emergency-saved. @param SalvagedFile specifies the original URL of the file which had been emergency-saved. @param MediaDescriptor contains additional arguments for the load process, for instance an StatusIndicator. @see MediaDescriptor */ void recoverDocument( [in] string SourceLocation, [in] string SalvagedFile, [in] sequence< ::com::sun::star::beans::PropertyValue > MediaDescriptor ) raises ( ::com::sun::star::io::IOException, ::com::sun::star::lang::WrappedTargetException ); }; //============================================================================= }; }; }; }; //============================================================================= #endif