DCSIMG
Generics - Miscellaneous Debris

Miscellaneous Debris

Thoughts and Snippets

Browse by Tags

All Tags » Generics (RSS)
שלישיה חזקה
פיני דיין כותב בבלוג שלו על שני classים נידחים שמתחבאים להם ב-System.Web כדי לשמור צמדים ושלשות של אובייקטים: Pair ו- Triplet . אני חושב ששימוש באובייקטים הללו הוא רעיון רע, ועדיף שיקברו יחד עם ה-.NET Framework 1.0 שהוליד אותם. יש לי שתי סיבות: א) המחלקות הללו יושבות ב-System.Web.UI, שיושב תחת System.Web.dll. אם אני לא כותב מערכת Web, זה מיותר לחלוטין להוסיף Reference ל-System.Web רק בשבילהם. וזה גם בלי להזכיר שהם לא היו אמורים לשבת ב-Namespace הזה מלכתחילה – אין בהם שום קשר ל-UI. גם אין בקלאסים...
Dynamically creating a Sharepoint Web-Service proxy instance
In my current code, I find myself accessing many Sharepoint web services. In one run of code I can access 5-6 different web services on dozens of different sites, not necessarily even on the same server. Given that I find myself writing a lot of boilerplate code looking like this: using (SiteData siteDataWS = new SiteData()) { siteDataWS.Credentials = CredentialsCache.DefaultNetworkCredentials; siteDataWS.Url = currentSite.ToString() + "/_vti_bin/SiteData.asmx"; // Do something with the WS. } Seeing...