HighTechTalks DotNet Forums  

Simple WebService question

ASP.net Web Services microsoft.public.dotnet.framework.aspnet.webservices


Discuss Simple WebService question in the ASP.net Web Services forum.



Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old   
AT
 
Posts: n/a

Default Simple WebService question - 12-02-2003 , 04:41 AM






I'm wondering what happend when two separate clients create two
instances of the same remote web service.

I know that each client is essentially creating local stub
object/wrapper that will make the invocations on the web service on
the server side. But conceptually what happens to the instance
variables of the web service. Will there be two separate instances of
it.

Asumme I have class :
class Simple extends webservice..... {
public Integer x;
public Simple(int start) { x=start };
public Integer get() { return x; }
}

Will two clients creating two instances of the Simple class have two
seperate instances of Simple.x or are they shared?

kind regards.

Reply With Quote
  #2  
Old   
AT
 
Posts: n/a

Default Re: Simple WebService question - 12-02-2003 , 12:56 PM






There will be two instances of the Simple class created. This means
that the x member is different for the two instances. However, if I
understand the WebService container in IIS correctly then you can
share members by making them static. In addition I think, in your
Simple class example, there must be a default constructor for it to
work.

-Alfred

alibandali (AT) hotmail (DOT) com (Ali) wrote in message news:<f3fc6742.0312020141.68034636 (AT) posting (DOT) google.com>...
Quote:
I'm wondering what happend when two separate clients create two
instances of the same remote web service.

I know that each client is essentially creating local stub
object/wrapper that will make the invocations on the web service on
the server side. But conceptually what happens to the instance
variables of the web service. Will there be two separate instances of
it.

Asumme I have class :
class Simple extends webservice..... {
public Integer x;
public Simple(int start) { x=start };
public Integer get() { return x; }
}

Will two clients creating two instances of the Simple class have two
seperate instances of Simple.x or are they shared?

kind regards.

Reply With Quote
Reply




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.