2 // System.Web.UI.StaticPartialCachingControl.cs
5 // Andreas Nahr (ClassDevelopment@A-SoftTech.com)
7 // (C) 2003 Andreas Nahr
11 using System.ComponentModel;
13 namespace System.Web.UI
15 public class StaticPartialCachingControl : BasePartialCachingControl
18 private BuildMethod buildMethod;
20 public StaticPartialCachingControl (string ctrlID, string guid, int duration,
21 string varyByParams, string varyByControls, string varyByCustom,
22 BuildMethod buildMethod)
27 VaryByParams = varyByParams;
28 VaryByControls = varyByControls;
29 VaryByCustom = varyByCustom;
31 this.buildMethod = buildMethod;
34 public static void BuildCachedControl (Control parent, string ctrlID, string guid,
35 int duration, string varyByParams, string varyByControls,
36 string varyByCustom, BuildMethod buildMethod)
38 StaticPartialCachingControl NewControl =
39 new StaticPartialCachingControl (ctrlID, guid, duration,
40 varyByParams, varyByControls, varyByCustom,
43 parent.Controls.Add (NewControl);
46 internal override Control CreateControl()
48 return buildMethod ();