Question is... can I stack multiple PageAdapter(s) in my ASP.NET website? I have a project which has already its own PageAdapter classes applied but I need to add one to move viewstate so that is persisted on server (disk, db, cache, whatever). My doubt is... If I create a page adapter for "default" browser (so for every browser) and that project already has its adapters for different browsers for some stuff, will my adapter stack flawlessly with those or there can be only one page adapter at time?
Adapters are stored in HttpCapabilitiesBase.Adapters
property as Hashtable
. If you will observe this collection in debug you will see that the key for this Hashtable
is a fully qualified name of the page/control type.
So it is not possible to stack control adapters, there is always one adapter per control at a time. And the default browser definition always wins (of course except the cases when you are filling page adapters collection manually).