The Active Network
ActiveMac Anonymous | Create a User | Reviews | News | Forums | Advertise  
 

  *  

  Properites vs. Methods...
Time: 19:17 EST/00:17 GMT | News Source: GotDotNet | Posted By: Jonathan Tigner

It is an age old debate… we have some fairly good guidelines, but they certainly leave room for improvement. Today at a WinFX API review (for some cool stuff that didn’t make it out in the PDC drop) we had the debate again… Today the APIs look like:

public DateTime GetDisconnectTime();
public TimeSpan GetIdleTime();
public DateTime GetLogonTime();
public SessionStates GetSessionStates();
public WindowsIdentity GetUserInformation();

My knee jerk is to make these properties…

public DateTime DisconnectTime {get; }
public TimeSpan IdleTime {get; }
public DateTime LogonTime {get; }
public SessionStates SessionStates {get; }
public WindowsIdentity UserInformation {get; }

the problem… well, the calls *could* be cross machine…. My worry is if they are cross machine making these guys properties will lead people to write inefficient code (and therefore bring down the wrath of Rico)…

So, my question for you… Based on this very limited data I have given you, what should we do here? Go for properties and hope for the best, or error on the safe side and use methods, something else?

Write Comment
Return to News

  Displaying 701 through 705 of 705
Prev | First
  The time now is 6:48:05 AM ET.
Any comment problems? E-mail us
#701 By 4240821 (178.217.45.42) at 11/23/2025 10:08:47 AM
https://sexonly.top/activgd3h144g1a
https://sexonly.top/activeehea53hae
https://lustful.su/activ45aa31bcac
https://sexonly.top/activ4b332bcega
https://sexonly.top/activ332fc5db5f
https://sluts.su/activ5c1bggd335
https://sexonly.top/activ32ggcch314
https://nsfw.su/activ3faagbdh33
https://lustful.su/activf5chc1f2ec
https://smutty.su/activ3eggcaecd5

#702 By 4240821 (178.217.45.42) at 11/23/2025 1:17:56 PM
https://lustful.su/activ543531b5bg
https://sexonly.top/activhgfedhhg5h
https://sexonly.su/activc3hah24d4b
https://sexonly.top/activ1f43abg53h
https://sluts.su/activcc1ef35e44
https://sexonly.su/activdh2cfcd3ea
https://sexonly.su/activ34b53ch1dc
https://smutty.su/activbh1eeacd13
https://lustful.su/activ2ge54a12f4
https://nsfw.su/activ32133ea1gd

#703 By 4240821 (85.195.101.122) at 11/23/2025 9:12:32 PM
https://sexonly.top/activb1deab2acd
https://lustful.su/activbd4cce545h
https://sluts.su/activg22334c1d5
https://lustful.su/activghbahcad21
https://sexonly.top/activfe4a1e12hc
https://sluts.su/activagagff5fgb
https://sexonly.top/activ4b3c3hb4h5
https://nsfw.su/activd1cebb31cg
https://sluts.su/activcgab5aghhc
https://sluts.su/activd12h2eh2da

#704 By 4240821 (82.115.4.230) at 11/24/2025 5:24:40 PM
https://sexonly.su/activ5a51gb231e
https://lustful.su/activgaghhb21fe
https://smutty.su/activ5g141cfadd
https://nsfw.su/activ15da33h1g4
https://sexonly.su/activh331bfe321
https://nsfw.su/activhf52gffbad
https://sluts.su/activ12ge2h2g22
https://sexonly.su/activgabh3c252c
https://sluts.su/activ4hdh2cagge
https://lustful.su/activfg1dd3df5h

#705 By 4240821 (45.192.45.37) at 11/24/2025 8:27:09 PM
https://telegra.ph/michael-d-higgins-shocks-nation-with-surprise-address-that-pundits-call-a-game-changer-11-20
https://telegra.ph/Schneefallgrenze-surges-above-record-levels-signaling-radical-climate-shift-11-20
https://telegra.ph/bucaramanga---santa-fe-ignites-a-cross-country-showdown-electrifying-fans-and-shaking-up-the-headlines-11-20
https://telegra.ph/Morgan-Freemans-Final-Film-A-Heartfelt-Farewell-to-Hollywood-11-20
https://telegra.ph/Clash-Set-to-Ignite-Raptors-Face-Off-Against-76ers-in-Epic-Showdown-11-20
https://telegra.ph/Gustav-Klimts-Masterpiece-Sells-for-Record-Breaking-130-Million-11-20
https://telegra.ph/nathalie-benko-stuns-at-gala-with-daring-look-igniting-a-social-media-firestorm-11-20
https://telegra.ph/darryl-brohman-ignites-social-media-with-blistering-post-match-take-11-19
https://telegra.ph/oman-erupts-onto-the-world-stage-as-bold-reforms-unleash-a-digital-gold-rush-11-19
https://telegra.ph/Nvidia-earnings-skyrocket-to-new-heights-redefining-industry-standards-11-19-3

Write Comment
Return to News
  Displaying 701 through 705 of 705
Prev | First
  The time now is 6:48:05 AM ET.
Any comment problems? E-mail us
User name and password:

 

  *  
  *   *