Factbites
 Where results make sense
About us   |   Why use us?   |   Reviews   |   PR   |   Contact us  

Topic: Immutable object


Related Topics

In the News (Tue 14 Feb 12)

  
  Java theory and practice: To mutate or not to mutate?
Immutable objects have a number of properties that make working with them easier, including relaxed synchronization requirements and the freedom to share and cache object references without concern for data corruption.
As long as immutable objects are constructed properly (which means not letting the object reference escape from the constructor), they are exempt from the requirement to synchronize access, becuase their state cannot be changed and therefore cannot have write-write or read-write conflicts.
Immutability is what enables the Flyweight pattern, which uses sharing to facilitate using objects to represent large numbers of fine-grained objects efficiently.
www.ibm.com /developerworks/java/library/j-jtp02183.html   (2124 words)

  
  Immutable object - TheBestLinks.com - Immutable objects, Computer science, C plus plus, Java programming language, ...
In computer science, an immutable object, as opposed to a mutable object, is a kind of object whose internal states cannot be modified in object oriented programming (OOP).
Immutability can also refer to those attributes of an object which are not to be modified, as in C++'s const member data attribute.
If an object is known to be immutable, then instead of creating copies of the entire object, only copies to a reference to it need be made.
www.thebestlinks.com /Immutable_objects.html   (639 words)

  
 [No title]
True, but if "immutable" is open to interpretation, I could easily imagine somone deciding that it's intended semantically that all Certificate instances are immutable, and any subclass that violates that is broken, and decide choice of provider shouldn't in theory matter, so it's OK to optimize all of them.
An object that generates events according to internal state changes that are not visible through the methods on the object would have observably different behavior depending on how it is copied.
An object is immutable if, after its constructor/initializer completes, it is impossible to modify the non-static fields of the object.
www.omg.org /issues/issue5991.txt   (7729 words)

  
  Immutable object at AllExperts
An object can be either entirely immutable or some attributes in the object may be declared immutable, for example using the const member data attribute in the C++ programming language.
For example, an object that uses memoization to cache the results of expensive computations could still be considered an immutable object.
Immutability does not imply that the object as stored in the computer's memory is unwriteable.
en.allexperts.com /e/i/im/immutable_object.htm   (1281 words)

  
 Object (Java 2 Platform SE v1.4.2)
By convention, the object returned by this method should be independent of this object (which is being cloned).
Typically, this means copying any mutable objects that comprise the internal "deep structure" of the object being cloned and replacing the references to these objects with references to the copies.
Otherwise, this method creates a new instance of the class of this object and initializes all its fields with exactly the contents of the corresponding fields of this object, as if by assignment; the contents of the fields are not themselves cloned.
java.sun.com /j2se/1.4.2/docs/api/java/lang/Object.html   (2133 words)

  
 Java theory and practice: To mutate or not to mutate?
Immutable objects have a number of properties that make working with them easier, including relaxed synchronization requirements and the freedom to share and cache object references without concern for data corruption.
As long as immutable objects are constructed properly (which means not letting the object reference escape from the constructor), they are exempt from the requirement to synchronize access, becuase their state cannot be changed and therefore cannot have write-write or read-write conflicts.
Immutability is what enables the Flyweight pattern, which uses sharing to facilitate using objects to represent large numbers of fine-grained objects efficiently.
www-128.ibm.com /developerworks/java/library/j-jtp02183.html   (2133 words)

  
 3.1 Objects, values and types
An object's type determines the operations that the object supports (e.g., ``does it have a length?'') and also defines the possible values for objects of that type.
So, immutability is not strictly the same as having an unchangeable value, it is more subtle.) An object's mutability is determined by its type; for instance, numbers, strings and tuples are immutable, while dictionaries and lists are mutable.
Even the importance of object identity is affected in some sense: for immutable types, operations that compute new values may actually return a reference to any existing object with the same type and value, while for mutable objects this is not allowed.
www.python.org /doc/current/ref/objects.html   (682 words)

  
 Bug ID: 4617197 RFE: Add Immutable types to Java
Immutability is a property of the object itself, and constness is a property of the view of the object (which is effectively the reference to the object in Java.) It is conceivable that access through a const reference might cause update to the internal state of the object (e.g.
Immutability of objects is defined by whether they change between one look at them and another, and in general might only be true over a restricted timespan or through some particular set of views.
Immutable classes have to be final (or have all their methods final a less satisfactory solution) otherwise they could have a method overridden to return a mutable value.
bugs.sun.com /bugdatabase/view_bug.do?bug_id=4617197   (11512 words)

  
 Immutable Classes
This chapter illustrates how immutable classes may be defined, and highlights the peculiarities in their usage that may trip up a beginning user.
For experienced C programmers the difference between immutable and reference classes is similar to the difference between structs (immutable types) and pointers to structs (reference types).
The initial value of an immutable object is defined to have all its fields set to the 'void' value and this is defined to be the 'void' value of the immutable object.
www.gnu.org /software/sather/docs-1.2/tutorial/immutable.html   (753 words)

  
 Immutable object - Definition, explanation
In computer science, an immutable object, as opposed to a mutable object, is a kind of object whose internal states cannot be modified after it was created.
Immutable objects are often useful because when an object is known to be immutable, some of costly operations for copying and comparing may be omitted altogether, simplyfing the program code and speeding up its execution.
If an object is known to be immutable, then instead of creating copies of the entire object, only copies to a reference to it need be made.
www.calsky.com /lexikon/en/txt/i/im/immutable_object.php   (1068 words)

  
 Java theory and practice: To mutate or not to mutate?
Immutable objects have a number of properties that make working with them easier, including relaxed synchronization requirements and the freedom to share and cache object references without concern for data corruption.
As long as immutable objects are constructed properly (which means not letting the object reference escape from the constructor), they are exempt from the requirement to synchronize access, becuase their state cannot be changed and therefore cannot have write-write or read-write conflicts.
Immutability is what enables the Flyweight pattern, which uses sharing to facilitate using objects to represent large numbers of fine-grained objects efficiently.
www-106.ibm.com /developerworks/java/library/j-jtp02183.html   (2124 words)

  
 Object Serialization -- web-calculus
When an object class is upgraded, propagating the update to all users of the object class or upgrading all serialized instances of the old object class may not be possible.
Immutable object graph cycles are encoded by breaking the cycles at the promise objects.
The receiving object deserialization code is then responsible for re-resolving the promise once it receives all of the immutable acyclic sub-graphs of the overall cyclic object graph.
www.waterken.com /dev/Web/Object   (1106 words)

  
 Design Pattern Synopses
The Composite pattern also allows the objects in the tree to be manipulated in a consistent manner, by requiring all of the objects in the tree to have a common superclass or interface.
If an object is expensive to instantiate and may not be needed, it may be advantageous to postpone its instantiation until the object is needed.
When the objects that make up a chain of responsibility are part of a larger organization built using the Composite pattern, the Template Method pattern is often used to organize the behavior of individual objects.
www.mindspring.com /~mgrand/pattern_synopses.htm   (4381 words)

  
 Definition of Immutable object
In computer science, an immutable object, as opposed to a mutable object, is a kind of object whose internal states cannot be modified.
The initial state of an immutable object is mostly set at its inception, but it can be set right before actual use of the object.
If an object is known to be immutable, then instead of creating copies of the entire object, only copies to a reference to it need be made.
www.wordiq.com /definition/Immutable_object   (738 words)

  
 Practical Java Praxis 63: Define and Implement Immutable Classes Judiciously > Practical Java Praxis 63: Define and ...   (Site not responding. Last check: )
By definition, an immutable object is an object and any object it references that does not change after construction.
Immutable classes are commonly used to represent strings, colors, and numeric values.
Furthermore, before a reference to any mutable object may be passed to the constructor or returned from a getter method, the object must be cloned first.
www.informit.com /content/index.asp?product_id={8290DB60-956E-4FD9-861A-75F10D4C2312}   (857 words)

  
 TWiki . Javapedia . ImmutableObject
Objects have identity (location in memory), state (data), and behavior (methods).
Immutable objects greatly simplify your program, since they
In this case, the state of this mutable field * is to be changed only by this class.
wiki.java.net /bin/view/Javapedia/ImmutableObject   (368 words)

  
 Pattern: Immutable Object   (Site not responding. Last check: )
Replace any operations that would have changed the object's state with operations that create a new object with the required state.
Immutable objects do not need to be locked, and so the overhead of enforcing Mutual Exclusion is avoided.
Threads cannot use an Immutable Object to communicate because, instead of changing the state of the object, each thread makes its own new copy of the object, with a different state, that is not readily visible to other threads.
www.doc.ic.ac.uk /~np2/patterns/concurrency/immutable-object.html   (186 words)

  
 immutable concept from the Object Oriented Software Engineering knowledge base
An immutable object is an object which has a state that never changes after creation.
An important reason for using an immutable object is that other objects can trust its content to not unexpectedly change.
Ensure that the constructor of the immutable class is the only place where the values of instance variables are set or modified.
www.site.uottawa.ca:4321 /oose/immutable.html   (288 words)

  
 The Memory Management Glossary: I
For instance, no immutable object may contain a reference to an object younger than itself, and no immutable object will appear in a remembered set.
This means that, although objects might be immutable at the language level, they are not immutable at the implementation level, and may contain references to younger objects.
A value object or immutable object is an object whose identity depends solely upon its value or magnitude.
www.memorymanagement.org /glossary/i.html   (1505 words)

  
 Thomas J Du Plessis's Weblog : Weblog
An immutable object is an object whose state cannot change or be changed after it has been created.
Of course, it is possible to do all sorts of nastiness even to immutable objects using reflection, but when one adheres to the interface instead of mucking with the bits immutable objects do not change after they have been created.
One major advantage to immutable objects is that they can generally be shared, resulting in better performance and less memory use.
www.jroller.com /page/tomdupl?entry=what_is_an_immutable_object   (565 words)

  
 ACM OOPS Messenger 4, 4 (Oct 1993), 2-27
This model of object identity, which is analogous to the normal forms of relational algebra, provides cleaner semantics for the value-transmission operations and built-in primitive equality predicate of a programming language, and eliminates the confusion surrounding "call-by-value" and "call-by-reference" as well as the confusion of multiple equality predicates.
For example, an object with a functional attribute might represent the attribute directly if it is small and if it belongs to a type which can be represented in a number of bits which can be fixed at compile time; alternatively, it could represent the attribute through a pointer to another functional object.
Trivial mutable objects of this kind can be used for unforgeable keys, because the only way one could have gotten such a key is by communicating with some object which already had it, since the generator of such objects is guaranteed to produce a new, never-before-seen (modulo garbage collection) object.
home.pipeline.com /~hbaker1/ObjectIdentity.html   (15312 words)

  
 vesta-intro - Introduction to Vesta
A source object's mutable attributes are a set of (name, value) pairs that the repository attaches to the object.
Internally, a mutable file may be implemented as a link to an immutable file, with copy-on-write if a user attempts to edit the file, but this detail is not visible through the NFS interface.
The ghost preserves the knowledge that its name was used for a real (non-ghost) object in the past and must not be used for a different object in the future.
www.vestasys.org /doc/man/html/vesta-intro.1.html   (2317 words)

  
 immutable object concept from the Object Oriented Software Engineering knowledge base
Next object: instance of user interface class Up: object Previous object: occurrence
has definition an object that has a state which never changes after creation
is a subtopic of 6.10 - The Immutable Pattern
www.site.uottawa.ca:4321 /oose/immutableobject.html   (211 words)

  
 immutable : Java Glossary
The only way to change the value of the number inside the object wrapper is to create a new object and point to that instead.
Immutable objects are much better suited to be Hashtable keys.
If you change the value of an object that is used as a hash table key without removing it and re-adding it you lose the mapping.
www.mindprod.com /jgloss/immutable.html   (499 words)

  
 immutable : Java Glossary
The only way to change the value of the number inside the object wrapper is to create a new object and point to that instead.
Immutable objects are much better suited to be Hashtable keys.
If you change the value of an object that is used as a hash table key without removing it and re-adding it you lose the mapping.
mindprod.com /jgloss/immutable.html   (520 words)

  
 of the standard of taste
According to the disposition of the organs, the same object may be both sweet and bitter; and the proverb has justly determined it to be fruitless to dispute concerning tastes.
When objects of any kind are first presented to the eye or imagination, the sentiment which attends them is obscure and confused; and the mind is, in a great measure, incapable of pronouncing concerning their merits or defects.
The object of eloquence is to persuade, of history to instruct, of poetry to please, by means of the passions and the imagination.
www.ourcivilisation.com /smartboard/shop/humed/taste.htm   (6734 words)

Try your search on: Qwika (all wikis)

Factbites
  About us   |   Why use us?   |   Reviews   |   Press   |   Contact us  
Copyright © 2005-2007 www.factbites.com Usage implies agreement with terms.