Extending Error Object

Extending Error Object

Question:
I want to create a system error object that will take care of system errors and database errors. Should I inherit it from the error object, or should I create NVO?

Answer:
One advantage of inheriting from the error object is that you can change the datatype in your application object to use your new object, and all your existing code that was built in PowerBuilder code will use the new object.

I would recommend inheriting the error object and changing the global type.

devxblackblue

About Our Editorial Process

At DevX, we’re dedicated to tech entrepreneurship. Our team closely follows industry shifts, new products, AI breakthroughs, technology trends, and funding announcements. Articles undergo thorough editing to ensure accuracy and clarity, reflecting DevX’s style and supporting entrepreneurs in the tech sphere.

See our full editorial policy.

About Our Journalist