The description of a spatial object is controlled by the Open Geospatial Consortium http://www.opengeospatial.org/(OGC) and International Organization for Standardization (ISO) standard bodies. In particular, the ISO/IEC 13249-3 Part 3: Spatial (ISO 13249-3, Information technology - Database languages - SQL Multimedia and Application Packages - Part 3: Spatial.) and the related OGC Simple Features Access – Part 2: SQL Option (OpenGIS® Implementation Specification for Geographic information - Simple feature access - Part 2: SQL option, Version 1.1 and 1.2. Previously known as Simple Features–SQL) (known as SFA). These standards define how a polygon and its exterior and interior rings are defined and how it is to be encoded.
Similarly, these standards describe the functionality that must be made available for conforming implementations. But there are a number of functions not described or required by the current standards that are most useful...