Jump to content

Skeleton (computer programming)

From Wikipedia, the free encyclopedia
This is an old revision of this page, as edited by 78.96.171.183 (talk) at 07:24, 19 November 2019. The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.

Skeleton programming is a style of computer programming based on simple high-level program structures and so called pseudo code. Program skeletons resemble pseudocode, but allow parsing, compilation and testing of the code. Dummy code is inserted in a program skeleton to simulate processing and avoid compilation error messages. It may involve empty function declarations, or functions that return a correct result only for a simple test case where the expected response of the code is known.

Skeleton programming facilitates a top-down design approach, where a partially functional system with complete high-level structures is designed and coded, and this system is then progressively expanded to fulfill the requirements of the project. Program skeletons are also sometimes used for high-level descriptions of algorithms. A program skeleton may also be utilized as a template that reflects syntax and structures commonly used in a wide class of problems.

Skeleton programs are utilized in the template method design pattern used in object-oriented programming. In object-oriented programming, dummy code corresponds to an abstract method, a method stub or a mock object. In the Java remote method invocation (Java RMI) nomenclature, a stub communicates on the client-side with a skeleton on the server-side.<ref>{{cite journal

| last1         = Freeman
| first1        = Eric
| authorlink1   = 
| last2         = Freeman
| first2        = Elisabeth 
| authorlink2   = 
| last3         = Kathy
| first3        = Sierra
| authorlink3   = 
| last4         = Bert
| first4        = Bates
| authorlink4   = 
| editor1-last  = Hendrickson
| editor1-first = Mike
| editor1-link  = 
| editor2-last  = Loukides
| editor2-first = Mike
| editor2-link  = 
| year          = 2004
| title         = Head First Design Patterns
| volume        = 1
| page          = 440
| publisher     = O'REILLY
| format        = paperback
| isbn          science)|method]]s, but does not implement them. The class is later implemented from

See also

References