How is encapsulation achieved in Object-Oriented COBOL?
- By bundling data and methods within a class
- By separating data and procedures
- Through external subroutine calls
- Through the use of global variables
Encapsulation in Object-Oriented COBOL is achieved by bundling data and methods within a class. This means that the internal details of the class, such as data structures and implementation details, are hidden from the outside world, promoting information hiding and reducing complexity.
Loading...
Related Quiz
- What does the CLOSE verb with the REEL and UNIT clauses signify when used in COBOL file handling?
- In a COBOL program for processing inventory records, how would you handle exceptions when an item is out of stock and cannot be shipped?
- To prevent duplicate records from being inserted into an indexed file, you can use the _____ clause in the file description.
- ________ is a technique used in COBOL to ensure data integrity during exceptional situations.
- The _____ section in the DATA DIVISION is used for defining variables with a scope that spans the entire program.