Define a hierarchy of errors to implement, and use inheritance to ensure all children errors implement specific behaviors.