Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
/*
* eXist Open Source Native XML Database
* Copyright (C) 2001-2015 The eXist Project
* http://exist-db.org
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program 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 for more details.
*
* You should have received a copy of the GNU Lesser General Public License
* along with this program; if not, write to the Free Software Foundation
* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
package org.exist.xmldb;
import java.net.URISyntaxException;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import org.apache.xmlrpc.client.XmlRpcClient;
import org.apache.xmlrpc.XmlRpcException;
import org.w3c.dom.Document;
import org.xmldb.api.base.Collection;
import org.xmldb.api.base.ErrorCodes;
import org.xmldb.api.base.XMLDBException;
public class RemoteCollectionManagementService extends AbstractRemote implements EXistCollectionManagementService {
private final XmlRpcClient client;
public RemoteCollectionManagementService(final XmlRpcClient client, final RemoteCollection parent) {
super(parent);
this.client = client;
}
@Override
public String getName() throws XMLDBException {
return "CollectionManagementService";
}
@Override
public String getVersion() throws XMLDBException {
return "1.0";
}
/**
* @deprecated {@link org.exist.xmldb.RemoteCollectionManagementService#createCollection(org.exist.xmldb.XmldbURI)}
*/
@Deprecated
@Override
public Collection createCollection(final String collName) throws XMLDBException {
return createCollection(collName, (Date) null);
}
@Override
public Collection createCollection(final XmldbURI collName) throws XMLDBException {
return createCollection(collName, null);
}
/**
* @deprecated {@link org.exist.xmldb.RemoteCollectionManagementService#createCollection(org.exist.xmldb.XmldbURI, java.util.Date)}
*/
@Deprecated
@Override
public Collection createCollection(final String collName, final Date created) throws XMLDBException {
try {
return createCollection(XmldbURI.xmldbUriFor(collName), created);
} catch (final URISyntaxException e) {
throw new XMLDBException(ErrorCodes.INVALID_URI, e);
}
}
@Override
public Collection createCollection(final XmldbURI name, final Date created) throws XMLDBException {
final XmldbURI collName = resolve(name);
final List