Answer the question
In order to leave comments, you need to log in
What is the difference between the terms Invariant and Property?
What is the difference between the concepts of invariant and property (unchanging)?
(Is the question formulated correctly?
What is the meaning of the difference between an invariant and a specification for a class that embodies some abstraction from the subject area?
)
I give examples below and, possibly, erroneous judgments:
1) Suppose there is a graph that can be visually displayed in different ways ( link list, vertex matrix, chain enumeration). The graph invariant is (or more correctly - are?) the number of vertices and edges.
2) Let's say there is a class and some class diagram that describes that instances of this class are persistent. The class, moreover, belongs to a certain inheritance hierarchy, in which the levels of inheritance are counted by natural numbers. Then:
Answer the question
In order to leave comments, you need to log in
From Wikipedia:
An invariant in object-oriented programming is an expression that defines a consistent internal state of an object.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question