Hi all,
well,as far as I can remember we already noticed the lack of methods
for the create of new root collections as well as child collections.
To move forward I propose the addition of the following two methods:

1. for bootstrapping we need a way to create a root collection:

org.xmldb.api.base.Database.java:

        + Collection createRootCollection ( String uri )
                throws XMLDBException;

Use case:

        // load and register database driver
        Database database = (Database) Class.forName(
                "vendor_db" ).newInstance();
        // create root collection
        database.createRootCollection(
                "xmldb:vendor_db:db_host:db_port?root_collection" );

2. to create child collections we need a way to create one:

org.xmldb.api.base.Collection.java:

        + Collection createCollection ( String collectionName )
                throws XMLDBException;

Use case:

        // load and register database driver
        Database database = (Database) Class.forName(
                "vendor_db" ).newInstance();
        // create root collection
        Collection rootCollection = database.getCollection(
                "xmldb:vendor_db:db_host:db_port?root_collection" );
        // create child collection
        Collection childCollection = rootCollection(
                createCollection( "childCollection" ):

Of course, this implies methods for removing collections ....
Ideas?

Lars
--
______________________________________________________________________
Lars Martin                                    mailto:[EMAIL PROTECTED]
SMB GmbH                                        http://www.smb-tec.com


----------------------------------------------------------------------
Post a message:         mailto:[EMAIL PROTECTED]
Unsubscribe:            mailto:[EMAIL PROTECTED]
Contact adminstrator:   mailto:[EMAIL PROTECTED]
Read archived messages: http://archive.xmldb.org/
----------------------------------------------------------------------

Reply via email to