To install click the Add extension button. That's it.

The source code for the WIKI 2 extension is being checked by specialists of the Mozilla Foundation, Google, and Apple. You could also do it yourself at any point in time.

4,5
Kelly Slayton
Congratulations on this excellent venture… what a great idea!
Alexander Grigorievskiy
I use WIKI 2 every day and almost forgot how the original Wikipedia looks like.
What we do. Every page goes through several hundred of perfecting techniques; in live mode. Quite the same Wikipedia. Just better.
.
Leo
Newton
Brights
Milds

From Wikipedia, the free encyclopedia

A method stub or simply stub[1] in software development is a piece of code used to stand in for some other programming functionality. A stub may simulate the behavior of existing code (such as a procedure on a remote machine; such methods are often called mocks) or be a temporary substitute for yet-to-be-developed code. Stubs are therefore most useful in porting, distributed computing as well as general software development and testing.

An example of a stub in pseudocode might be as follows:

temperature = ThermometerRead(Outside)
if temperature > 40 then
    print "It is hot!"
end if
function ThermometerRead(Source insideOrOutside)
    return 28
end function

The above pseudocode utilises the function ThermometerRead, which returns a temperature. While ThermometerRead would be intended to read some hardware device, this function currently does not contain the necessary code. So ThermometerRead does not, in essence, simulate any process, yet it does return a legal value, allowing the main program to be at least partially tested. Although it accepts the parameter of type Source, which determines whether inside or outside temperature is needed, it does not use the actual value passed (argument insideOrOutside) by the caller in its logic.

A stub [2] is a routine that doesn't actually do anything other than declaring itself and the parameters it accepts and returning something that is usually the values expected in one of the "happy scenarios" for the caller. Stubs are used commonly as placeholders for implementation of a known interface, where the interface is finalized/known but the implementation is not yet known/finalized. The stub contains just enough code to allow it to be compiled and linked with the rest of the program. In RMI nomenclature, a stub on the client-side communicates with a skeleton on the server-side.[3]

In the context of DOS and Windows, the term stub is also used in a fashion like shim to describe the small areas of interface code left in conventional memory by self-relocating resident drivers which move most of themselves into upper memory, the high memory area, expanded or extended memory as well as similar stubs to allow the relocated code to communicate with real-mode DOS in conjunction with DOS extenders (like DPMI, DPMS, CLOAKING or NIOS).

The small pieces of dummy code branched into—so as to allow a graceful exit when invoking a fat binary in the wrong environment—are also called (code) stubs.

YouTube Encyclopedic

  • 1/3
    Views:
    3 386
    29 344
    30 958
  • openEMS - An Introduction and Overview Using an EM field solver to design antennas and PCBs
  • Component Object Models
  • RMI architecture | distributed system | Lec-23 | Bhanu Priya

Transcription

See also

References

  1. ^ Nell B. Dale; Chip Weems (2004). Programming in C++. Jones & Bartlett Learning. p. 308. ISBN 978-0-7637-3234-9.
  2. ^ "stub". WEBOPEDIA. 23 March 1998. Retrieved 2012-08-28.
  3. ^ Freeman, Eric; Freeman, Elisabeth; Kathy, Sierra; Bert, Bates (2004). Hendrickson, Mike; Loukides, Mike (eds.). Head First Design Patterns (paperback). Vol. 1. O'REILLY. p. 440. ISBN 978-0-596-00712-6. Retrieved 2012-08-28.

External links

This page was last edited on 19 February 2024, at 16:51
Basis of this page is in Wikipedia. Text is available under the CC BY-SA 3.0 Unported License. Non-text media are available under their specified licenses. Wikipedia® is a registered trademark of the Wikimedia Foundation, Inc. WIKI 2 is an independent company and has no affiliation with Wikimedia Foundation.