1 package org.synchronoss.cpo.core.meta;
2
3 /*-
4 * [[
5 * core
6 * ==
7 * Copyright (C) 2003 - 2026 Exaxis LLC, Synchronoss Technologies Inc
8 * ==
9 * This program is free software: you can redistribute it and/or modify
10 * it under the terms of the GNU Lesser General Public License as
11 * published by the Free Software Foundation, either version 3 of the
12 * License, or (at your option) any later version.
13 *
14 * This program is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 * GNU General Lesser Public License for more details.
18 *
19 * You should have received a copy of the GNU General Lesser Public
20 * License along with this program. If not, see
21 * <http://www.gnu.org/licenses/lgpl-3.0.html>.
22 * ]]
23 */
24
25 import java.io.File;
26 import java.io.OutputStream;
27 import java.io.Writer;
28 import org.synchronoss.cpo.core.CpoException;
29
30 /**
31 * {@code CpoMetaExportable} is implemented by metadata sources that can serialize their loaded
32 * {@code CpoClass} metadata back out to a CPO meta XML document.
33 *
34 * @author dberry
35 */
36 public interface CpoMetaExportable {
37
38 /**
39 * Performs an export of the metadata to the specified File
40 *
41 * @param file The file to export to
42 * @throws CpoException An error has occurred
43 */
44 void export(File file) throws CpoException;
45
46 /**
47 * Performs an export of the metadata to the specified Writer
48 *
49 * @param writer The writer to export to
50 * @throws CpoException An error has occurred
51 */
52 void export(Writer writer) throws CpoException;
53
54 /**
55 * Performs an export of the meta ata to the specified OutputStream
56 *
57 * @param outputStream The output stream to export to
58 * @throws CpoException An error has occurred
59 */
60 void export(OutputStream outputStream) throws CpoException;
61 }