org.netbeans.modules.j2ee.dd/1 1.13.0 2

org.netbeans.modules.j2ee.dd.api.common
Interface RootInterface

All Superinterfaces:
CommonDDBean, ComponentInterface, CreateCapability, DescriptionInterface, DisplayNameInterface, FindCapability, IconInterface
All Known Subinterfaces:
AppClient, Application, EjbJar, WebApp

public interface RootInterface
extends ComponentInterface

Interface representing the root of interfaces bean tree structure.

Important note: Do not provide an implementation of this interface unless you are a DD API provider!


Field Summary
static int MERGE_INTERSECT
          Used in merge(org.netbeans.modules.j2ee.dd.api.common.RootInterface, int) method.
The result of merge operation is the intersection of graphs.
static int MERGE_UNION
          Used in merge(org.netbeans.modules.j2ee.dd.api.common.RootInterface, int) method.
The result of merge operation is the union of graphs.
static int MERGE_UPDATE
          Used in merge(org.netbeans.modules.j2ee.dd.api.common.RootInterface, int) method.
The result of merge operation is the first graph updated with the changes in another graph.
 
Method Summary
 void merge(RootInterface root, int mode)
          Merging two bean tree structures together.
 void write(FileObject fo)
          Writes the deployment descriptor data from deployment descriptor bean graph to file object.
This is more convenient method than CommonDDBean.write(java.io.OutputStream) method.
The locking problems are solved for the user in this method.
 
Methods inherited from interface org.netbeans.modules.j2ee.dd.api.common.CommonDDBean
addPropertyChangeListener, clone, getId, getValue, removePropertyChangeListener, setId, write
 
Methods inherited from interface org.netbeans.modules.j2ee.dd.api.common.DescriptionInterface
getAllDescriptions, getDefaultDescription, getDescription, removeAllDescriptions, removeDescription, removeDescriptionForLocale, setAllDescriptions, setDescription, setDescription
 
Methods inherited from interface org.netbeans.modules.j2ee.dd.api.common.DisplayNameInterface
getAllDisplayNames, getDefaultDisplayName, getDisplayName, removeAllDisplayNames, removeDisplayName, removeDisplayNameForLocale, setAllDisplayNames, setDisplayName, setDisplayName
 
Methods inherited from interface org.netbeans.modules.j2ee.dd.api.common.CreateCapability
addBean, addBean, createBean
 
Methods inherited from interface org.netbeans.modules.j2ee.dd.api.common.FindCapability
findBeanByName
 
Methods inherited from interface org.netbeans.modules.j2ee.dd.api.common.IconInterface
getAllIcons, getDefaultIcon, getLargeIcon, getLargeIcon, getSmallIcon, getSmallIcon, removeAllIcons, removeIcon, removeIcon, removeLargeIcon, removeLargeIcon, removeSmallIcon, removeSmallIcon, setAllIcons, setIcon, setLargeIcon, setLargeIcon, setSmallIcon, setSmallIcon
 

Field Detail

MERGE_INTERSECT

static final int MERGE_INTERSECT
Used in merge(org.netbeans.modules.j2ee.dd.api.common.RootInterface, int) method.
The result of merge operation is the intersection of graphs.

See Also:
Constant Field Values

MERGE_UNION

static final int MERGE_UNION
Used in merge(org.netbeans.modules.j2ee.dd.api.common.RootInterface, int) method.
The result of merge operation is the union of graphs.

See Also:
Constant Field Values

MERGE_UPDATE

static final int MERGE_UPDATE
Used in merge(org.netbeans.modules.j2ee.dd.api.common.RootInterface, int) method.
The result of merge operation is the first graph updated with the changes in another graph.

See Also:
Constant Field Values
Method Detail

write

void write(FileObject fo)
           throws IOException
Writes the deployment descriptor data from deployment descriptor bean graph to file object.
This is more convenient method than CommonDDBean.write(java.io.OutputStream) method.
The locking problems are solved for the user in this method.

Parameters:
fo - File Object where to write the content of depl.descriptor holding in bean tree structure
Throws:
IOException

merge

void merge(RootInterface root,
           int mode)
Merging two bean tree structures together.

There are several ways odf merging :

        Let's define:
                G1 the current graph and G2 the new graph we want to merge
                E1 the set of element of G1 that don't exist anymore in G2.
                E2 the set of new elements of G2 that don't exist in G1.

        Then,
                MERGE_UPDATE is         G1 - E1 + E2    (G1 becomes G2)
                MERGE_UNION is  G1 U G2 <=> G1 + E2
                MERGE_INTERSECT is      G1 n G2 <=> (G1 U G2) - E1 - E2

Parameters:
bean - root of the bean graph that is merged with actual bean graph
mode - type of merging (INTERSECT, UNION, UPDATE)

org.netbeans.modules.j2ee.dd/1 1.13.0 2

Built on December 1 2008.  |  Portions Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.