i knew that strings are immutable and that we should use Stringbuilder.
but the method String.Intern(inputString) i didnt know!
- the method looks up the intern string pool for inputString.
- if it founds it, it assigns the reference to thisone.
and it will be not created a new instance of the inputString.
consider memory consumption vs. performance !!!
we have more the performance problem than the memory consumption problem.
Link: Bob On Development » Optimize Memory Consumption Using String Interning
String.Intern() Method
Labels: .NET
Latest Posts
Popular Posts
-
It's easy I thought, just select the Property of the EntityType and set the Default Value in the Properties window to: DateTime.Now ...
-
Had some discussions about Lists and controls, like Listbox and Listview, and sometimes its difficult to distinguish those. System.Win...
-
*Updated* 26. September 2010: Updated with comments from Adam Cogan *Updated* 27. September 2010: Updated the comparison between anonymo...


No comments:
Post a Comment