翻訳と辞書
Words near each other
・ Precoding
・ Precognition
・ Precognition (disambiguation)
・ Precognition (Scots law)
・ Precollection
・ Precolonial history of Angola
・ Precolonial Mauritania
・ Precommitment
・ Precompact set
・ Precompiled header
・ Precomposed character
・ Precomposition
・ Precompressor
・ Precomputation
・ Precomputed Radiance Transfer
Precondition
・ Preconditioner
・ Preconditioning (adaptation)
・ Preconditioning (disambiguation)
・ Preconization
・ Preconscious
・ Preconsolidation pressure
・ Precontinent
・ Precontract
・ Precooled jet engine
・ Precor
・ Precor StretchTrainer
・ Precordial catch syndrome
・ Precordial thump
・ Precordillera


Dictionary Lists
翻訳と辞書 辞書検索 [ 開発暫定版 ]
スポンサード リンク

Precondition : ウィキペディア英語版
Precondition

In computer programming, a precondition is a condition or predicate that must always be true just prior to the execution of some section of code or before an operation in a formal specification.
If a precondition is violated, the effect of the section of code becomes undefined and thus may or may not carry out its intended work. Security problems can arise due to incorrect preconditions.
Often, preconditions are simply included in the documentation of the affected section of code. Preconditions are sometimes tested using assertions within the code itself, and some languages have specific syntactic constructions for doing so.
For example: the factorial is only defined for integers greater than or equal to zero. So a program that calculates the factorial of an input number would have preconditions that the number be an integer and that it be greater than or equal to zero.
==In object-oriented programming==
Preconditions in object-oriented software development are an essential part of design by contract. Design by contract also includes notions of postcondition and class invariant.
The precondition for any routine defines any constraints on object state which are necessary for successful execution. From the program developer's viewpoint, this constitutes the routine caller's portion of the contract. The caller then is obligated to ensure that the precondition holds prior to calling the routine. The reward for the caller's effort is expressed in the called routine's postcondition.〔Meyer, Bertrand, ''Object-Oriented Software Construction, second edition,'' Prentice Hall, 1997, p. 342.〕

抄文引用元・出典: フリー百科事典『 ウィキペディア(Wikipedia)
ウィキペディアで「Precondition」の詳細全文を読む



スポンサード リンク
翻訳と辞書 : 翻訳のためのインターネットリソース

Copyright(C) kotoba.ne.jp 1997-2016. All Rights Reserved.