Can I use the term "Constant Object" in the place of the term "Immutable Object"? Though I get the feeling that Immutable for an Object is what Constant is for a variable, I am not
What I am looking for is a succinct way of ending up with an immutable two dimensional array X and one dimensional array Y without first scanning the file to find out the dimensions of the data.
I\'m doing some distributed computing in which several machines communicate under the assumption that they all have identical versions of various classes. Thus, it seems to be good design to make thes
Dictionary keys in C# (probably in most languages) must be immutable. I consider now the possiblity to make the value of my key to depend on some property of another object.
When an object is added to the .NET Sys开发者_开发知识库tem.Collections.Generic.Dictionary class the hashcode of the key is stored internally and used for later comparisons.When the hashcode changes a
Can someone e开发者_StackOverflow中文版xplain the following behaviour: class derivedset1(frozenset):
General question here: If I\'m making a new class, and it\'s only private field is a string, can I do something like this.privateString = argumentIn; in the constructor to set that private 开发者_开发
Although I have never needed this, it just struck me that making an immutable object in Python could be slightly tricky. You can\'t just override __setattr__, because then you can\'t even set attribut
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references,or expertise, but this question will likely solicit debate, a
Can anyone give me a list of languages where class immutability can be compiler enforced and tested easily ?