Dodatkowe przykłady dopasowywane są do haseł w zautomatyzowany sposób - nie gwarantujemy ich poprawności.
Postcondition: The board will have changed back to the state it was in before the last move.
But the same precondition and postcondition apply in all cases.
A postcondition specifies what the effects of performing the action are.
Postcondition code can be placed in the finally section.
A rule consists of three main parts: precondition, action and postcondition.
The reward for the caller's effort is expressed in the called routine's postcondition.
Design by contract also includes notions of postcondition and class invariant.
You can test postcondition with assertions in both public and nonpublic methods.
Each method is annotated with a precondition and a postcondition.
There is then that postcondition of actually accepting that Grace.
The postcondition can be strengthened and/or the precondition weakened in this process.
Defines a postcondition for when a given Exception is thrown by the method that follows.
A more constrained function specification is arrived at by strengthening the postcondition.
The postcondition characterizes the result rather than defining an algorithm for obtaining it.
This rule allows to strengthen the precondition and/or to weaken the postcondition.
Occasionally it is necessary to save some data prior to performing a computation in order to check a postcondition.
Here the postcondition does not define a method for calculating the result but states what properties can be assumed to hold of it.
Defines a postcondition on the method that follows.
The precondition records the assumptions under which the function guarantees to return a result satisfying the postcondition.
Public member functions should define precondition and postcondition to help ensure the class invariant.
The precondition and postcondition together form a contract that to be satisfied by any program claiming to implement the function.
Finally, the clause is a postcondition, which specifies that the value is incremented by one.
The known input should test a precondition and the expected output should test a postcondition.
The assert statement is appropriate for nonpublic precondition, postcondition and class invariant checking.
The postcondition for any routine is a declaration of the properties which are guaranteed upon completion of the routine's execution.