25 October 2012

Programming: Assertion (Definitions)

"A constraint that is not attached to a table but is instead a distinct database object. It can therefore be used to enforce rules that apply to multiple tables or to verify that tables are not empty." (Jan L Harrington, "SQL Clearly Explained" 3rd Ed., 2010)

"A declaration or statement, often without support." (Janice M Roehl-Anderson, "IT Best Practices for Financial Managers", 2010)

"A statement about a program that the code claims to be true." (Rod Stephens, "Start Here!™ Fundamentals of Microsoft® .NET Programming", 2011)

"A statement that the code claims is true. If the statement is false, the program stops running so you can decide whether a bug occurred." (Rod Stephens, "Stephens' Visual Basic® Programming 24-Hour Trainer", 2011)

"A component of a regular expression that must be true for the pattern to match but does not necessarily match any characters itself. Often used specifically to mean a zero-width assertion." (Jon Orwant et al, "Programming Perl" 4th Ed., 2012)

"A statement about the program and its data that is supposed to be true. If the statement isn’t true, the assertion throws an exception to tell you that something is wrong." (Rod Stephens, "Beginning Software Engineering", 2015)

"A language feature used to test for conditions that should be guaranteed by program logic. If a condition checked by an assertion is found to be false, a fatal error is thrown. For added performance, assertions can be disabled when an application is deployed." (Daniel Leuck et al, "Learning Java" 5th Ed., 2020)

"A way of ensuring that a method has access to a particular resource, even if the method's callers do not have the required permission. During a stack walk, if a stack frame asserting the required permission is encountered, a security check for that permission will succeed without proceeding further. To perform an assertion of a permission, code must not only have that permission, but also be granted the SecurityPermission.Assertion permission. Unwise use of assertions can create security holes, so they should be used only with the utmost caution." (Damien Watkins et al, "Programming in the .NET Environment", 2002)

No comments:

Related Posts Plugin for WordPress, Blogger...

About Me

My photo
Koeln, NRW, Germany
IT Professional with more than 24 years experience in IT in the area of full life-cycle of Web/Desktop/Database Applications Development, Software Engineering, Consultancy, Data Management, Data Quality, Data Migrations, Reporting, ERP implementations & support, Team/Project/IT Management, etc.