Jump to content

Leaf class (computer programming)

From Wikipedia, the free encyclopedia
This is an old revision of this page, as edited by SecureJane (talk | contribs) at 11:59, 30 May 2022 (fixed extra whitespace in citation (url= ) using ARA). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.

In class-based object-oriented programming languages, a leaf class is a class that should not be subclassed. This can be enforced either by convention, or by using a language feature such as the final keyword in C++ or Java, or the sealed keyword in C#.

In Java, the Leaf node is an abstract class for all scene graph nodes that have no children. Leaf nodes specify lights, geometry, and sounds. They specify special linking and instancing capabilities for sharing scene graphs and provide a view platform for positioning and orienting a view in the virtual world.[1]

References

  1. ^ "Class Leaf". Docs.Oracle. 2 April 2001. Retrieved 23 May 2022.{{cite web}}: CS1 maint: url-status (link)