"</xu:insert-after>" +
"</xu:modifications>";
public static void main( String[] args ) throws Exception {
AdminService adminService = new AdminServiceLocator();
Admin admin = adminService.getAdmin();
QueryService queryService = new QueryServiceLocator();
Query query = queryService.getQuery();
String session = admin.connect("guest", "guest");
admin.store(session, document.getBytes(UTF_8), "UTF-8", XmldbURI.ROOT_COLLECTION + "/test/notes.xml", true);
admin.xupdateResource(session, XmldbURI.ROOT_COLLECTION + "/test/notes.xml", xupdate);
String data = query.getResource(session,
XmldbURI.ROOT_COLLECTION + "/test/notes.xml",
true, true);
System.out.println(data);
admin.disconnect(session);
}