KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > netbeans > api > xmi > XMIOutputConfig


1 /*
2  * The contents of this file are subject to the terms of the Common Development
3  * and Distribution License (the License). You may not use this file except in
4  * compliance with the License.
5  *
6  * You can obtain a copy of the License at http://www.netbeans.org/cddl.html
7  * or http://www.netbeans.org/cddl.txt.
8  *
9  * When distributing Covered Code, include this CDDL Header Notice in each file
10  * and include the License file at http://www.netbeans.org/cddl.txt.
11  * If applicable, add the following below the CDDL Header, with the fields
12  * enclosed by brackets [] replaced by your own identifying information:
13  * "Portions Copyrighted [year] [name of copyright owner]"
14  *
15  * The Original Software is NetBeans. The Initial Developer of the Original
16  * Software is Sun Microsystems, Inc. Portions Copyright 1997-2006 Sun
17  * Microsystems, Inc. All Rights Reserved.
18  */

19 package org.netbeans.api.xmi;
20
21 /** Configuration class for objects producing XMI as output (e.g. {@link XMIWriter}).
22  *
23  * @author Martin Matula
24  * @author Brian Smith
25  */

26 public abstract class XMIOutputConfig {
27     /** Sets a reference provider to be used by XMI writer/producer to generate XMI IDs and
28      * determine target document for a given object. If <code>null</code> is passed,
29      * the default reference provider will be used.
30      * For immutable configurations this method throws
31      * <code>UnsupportedOperationException</code>.
32      * @param provider Reference provider to be used.
33      */

34     public abstract void setReferenceProvider(XMIReferenceProvider provider);
35     
36     /** Returns a reference provider to be used by writer/producer to generate XMI IDs and
37      * determine target document for a given object. The method should never return
38      * <code>null</code> for a configuration associated with a writer/producer. Otherwise
39      * <code>null</code> means that the default reference provider will be used.
40      * @return Reference provider to be used or <code>null</code>.
41      */

42     public abstract XMIReferenceProvider getReferenceProvider();
43     
44     /** Sets an encoding to be used by XMI writer/producer to generate XMI documents.
45      * If <code>null</code> is passed, the default encoding will be used.
46      * For immutable configurations this method throws
47      * <code>UnsupportedOperationException</code>.
48      * @param encoding to be used.
49      */

50     public abstract void setEncoding(String JavaDoc encoding);
51     
52     /** Returns an encoding to be used by writer/producer to generate XMI documents.
53      * The method should never return <code>null</code> for a configuration associated
54      * with a writer/producer. Otherwise <code>null</code> means that the default
55      * encoding will be used.
56      * @return encoding to be used or <code>null</code>.
57      */

58     public abstract String JavaDoc getEncoding();
59 }
60
Popular Tags