XML::DB::Service::XUpdateQueryService - provides XUpdate queries |
XML::DB::Service::XUpdateQueryService - provides XUpdate queries
$service = $collection->getService('XUpdateQueryService', '1.0'); $service->update($xupdate); $service->updateResource($xupdate, $documentId);
Implements XML::DB::Service, to provide XUpdate queries of the collection it is derived from.
In principle, an xupdate should just be sent over the transport mechanism to be dealt with by the database, if it supports XUpdate. Where a database doesnt support XUpdate natively yet, it has to be done by fetching the files, applying the update, and then writing them back.
Updates do not return a node count as per spec (what is this useful for anyway?), since that would require interfering with the guts of XML::XUpdate::LibXML, or reimplementing it.
=head1 AUTHOR
Graham Seaman CPAN ID: GSEAMAN graham@opencollector.org
Copyright (c) 2002 Graham Seaman. All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
The full text of the license can be found in the LICENSE file included with this module.
perl(1).
Usage : $no_modified = $service->update($xupdate);
Purpose : Runs xupdate against whole collection and writes result back to database
Arguments : XUpdate XML string
Returns : Integer (count of modified nodes)
Usage : $no_modified = $service->update($resource_name, $xupdate);
Purpose : Runs xupdate against one Resource and writes result back to database
Arguments : String representing resource (id or name); XUpdate XML string
Returns : Integer (count of modified nodes)
Usage : Should only be called indirectly, from a Collection (see Synopsis)
Purpose : Constructor
XML::DB::Service::XUpdateQueryService - provides XUpdate queries |