The stdclsdv package is designed for package writers who need to know what sectioning divsions are provided by the document's class. It also provides a version of \CheckCommand that sets a flag rather than printing a warning.