473,385 Members | 1,772 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

XMLPool: The c# XML Database Webservice

Wow, I just figured out some cool stuff thanks to Ken Kolda in
m.p.d.f.remoting

Now I have my multiuser XmlDocument set to load once at startup using a
static invocation of a class.

Next I'll apply my mutex and build out the Xpath query methods (!)


public class xmlPoolDoc
{

XmlDocument xd = new XmlDocument();

public xmlPoolDoc(XmlReader xr)
{
//
// TODO: Add constructor logic here
//
xd.Load(xr);

}

public void insertNodes()
{
}

public string selectNodes()
{
return xd.InnerText;
}

public void updateNodes()
{
}

public void deleteNodes()
{
}


}


public class DataBourse : System.Web.Services.WebService
{
static XmlTextReader reader = new XmlTextReader (@"c:\xmlbase\pool.xml");
static xmlPoolDoc xPdoc = new xmlPoolDoc(reader);
static DataBourse()
{
//doc.Load(reader);
}


public DataBourse()
{
//CODEGEN: This call is required by the ASP.NET Web Services Designer
InitializeComponent();
}

#region Component Designer generated code

//Required by the Web Services Designer
private IContainer components = null;

/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
}

/// <summary>
/// Clean up any resources being used.
/// </summary>
protected override void Dispose( bool disposing )
{
if(disposing && components != null)
{
components.Dispose();
}
base.Dispose(disposing);
}

#endregion

// WEB SERVICE EXAMPLE
// The HelloWorld() example service returns the string Hello World
// To build, uncomment the following lines then save and build the project
// To test this web service, press F5

// [WebMethod]
// public string HelloWorld()
// {
// return "Hello World";
// }
[WebMethod]
public string SelectFromPool(string query)
{
return xPdoc.selectNodes();
}

[WebMethod]
public string UpdateSelectedNodeInPool()
{
return "Hello World";
}

[WebMethod]
public string InsertNewNodeAtPointInPool()
{
return "Hello World";
}

}

Nov 21 '05 #1
0 1972

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
by: kenneth fleckenstein nielsen | last post by:
hi guru's I want to restart my webservice when ever it throws an exception that isn't cought. can i do that by web.config or iss or how ??
6
by: Carlos Lozano | last post by:
Hi, as a background I have an Windows application developed with VS 2003 (c#) that needs to transfer securely data to a MySQL database located on a Linux server. I have created a PHP...
8
by: Maxi | last post by:
Hello, i'm sorry my bad english :( I have CR9 Webservice, how to change databadse name and User_name into Webservice method? (not Viewer Control) Tks!! -- --------------------------
1
by: NN | last post by:
Hello, I have a question. I have a program made in VB6 that caputure the images that are transmitted by a webcam and records it in a database in MySQL. I want to do a WebService in .NET that...
1
by: NN | last post by:
Hello, I have a question. I have a program made in VB6 that caputure the images that are transmitted by a webcam and records it in a database in MySQL. I want to do a WebService in .NET that...
0
by: ananth | last post by:
Hi all, I have an webservice written in Lotus Notes and now i am calling this webservice in visual basic to pass data from visual basic to lotus notes database .I am using a MSSOAP tool kit...
14
Sakalicek
by: Sakalicek | last post by:
Hi all, could you please help me with my big problem? I have WebService on IIS. This WebService has methods to control database stored on server. I am using Postgre database and to access to...
0
by: Wendi Turner | last post by:
ASP.NET 2.0 C# WebService Connect to Database: Sql Server 2005 --------------------------------------------------------------------------------------------------- I have successfully created a...
2
by: Wendi Turner | last post by:
ASP.NET 2.0 C# WebService Connect to Database: Sql Server 2005 --------------------------------------------------------------------------------------------------- I have successfully created a...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.