Give an example of enforcement in typing, Database Management System

Assignment Help:

Give an example of enforcement in Typing.

You can understand the idea of enforcement as it makes sure objects of dissimilar classes may not be interchanged as below:

 Example: Fruit f; Vegetable v; Mango m;  

This implies 'v' is variables of class Vegetable, 'm' of class Mango and 'f' of class Fruit. Typing ensures that value of 'f' never be assigned to 'v'.

However, if Mango extends Fruits, then 'f' may be assigned a value of 'm'. The variable of a sub class may be assigned to variable of super class, but not other way around while 'm' cannot be assigned a value of 'f'.

 


Related Discussions:- Give an example of enforcement in typing

Prepare an erd for the scenario, Question: (a) Prepare an ERD for the s...

Question: (a) Prepare an ERD for the scenario given below. (b) Convert the ER diagram produced in (a) above into its physical design. You have to choose an appropriate Pri

Object-based models - data models, Object-based Models: Use objects as key ...

Object-based Models: Use objects as key data representation components . Examples:-   Entity-Relationship Model: It is a collection of real world objects known as entitie

What is equi join, What is equi join? Equi Join - It generates all th...

What is equi join? Equi Join - It generates all the combinations of tuples from two relations which satisfy a join condition along with only equality comparison (=).

RDBMS, Benefits and limitations

Benefits and limitations

Define two phase commit, Define Two phase commit Two phase commit: To m...

Define Two phase commit Two phase commit: To make sure atomicity, all the sites where a transaction is being executed must agree on the final outcome of the execution. The tran

Why we use delegation to share implementation, Use Delegation to Share Impl...

Use Delegation to Share Implementation The delegation " Delegation comprises of catching an operation on one object and sending it to other object which is part, or related to

Creating views with replace option, Creating views with Replace option : Th...

Creating views with Replace option : This option is used to alter the definition of the view without recreating and dropping it or regranting object privileges previously granted o

What is the aim of object design, What is the aim of object design The ...

What is the aim of object design The aim of object design is to identify object which the system   contains and the interactions among them. The system implements specification

Design and build a data mart, You are required to design and build a data m...

You are required to design and build a data mart/data warehouse using Oracle. A national bank allocates funding every year for its local branches to provide temporary staff cove

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd