Re: Can I store a C# Class Instance to the Server Cache?
- From: "John Saunders" <john.saunders at trizetto.com>
- Date: Wed, 14 Feb 2007 17:38:12 -0500
"Joseph Geretz" <jgeretz@xxxxxxxxxx> wrote in message
news:%23Rre6xHUHHA.528@xxxxxxxxxxxxxxxxxxxxxxx
Hi John,
Thanks for your response. I'm not sure what you mean by serializable. Do
you mean that I need to serialize this explicitly into the Cache, or that
the Framework will take care of the serialization for me if the class is
serializable?
Here is that class which I am caching.
internal class SessionCache
{
public string SID;
public string UID;
public string PWD;
public DataTable Profile;
}
I know this is 'working' since I'm able to retrieve this from the cache on
successive Web Method requests. Is this actually being serialized into the
cache for me 'under the hood'? Does it need to be? Do I need to do
anything explicitly to serialize this into the cache?
Joseph, I'm sorry, I wasn't thinking clearly. I was thinking about
ViewState, which _does_ require instances to be serializable. Clearly, the
ASP.NET Cache object doesn't need anything more than your class provides.
John
.
- Follow-Ups:
- Re: Can I store a C# Class Instance to the Server Cache?
- From: Joseph Geretz
- Re: Can I store a C# Class Instance to the Server Cache?
- References:
- Can I store a C# Class Instance to the Server Cache?
- From: Joseph Geretz
- Re: Can I store a C# Class Instance to the Server Cache?
- From: John Saunders
- Re: Can I store a C# Class Instance to the Server Cache?
- From: Joseph Geretz
- Can I store a C# Class Instance to the Server Cache?
- Prev by Date: Implementing a common SOAP Header across multiple Web Service Pages
- Next by Date: Re: Implementing a common SOAP Header across multiple Web Service Pages
- Previous by thread: Re: Can I store a C# Class Instance to the Server Cache?
- Next by thread: Re: Can I store a C# Class Instance to the Server Cache?
- Index(es):
Relevant Pages
|