UML Basic Interview Questions Part-4



What is the influence of rule-sets in object assertions?

Class invariant allows a single but quantified logical statement of any subset to be true all the times. Invariants are also called rules and it defines the cardinality constraints on attributes that are given as invariants. Ruleset is an unordered set of class invariants and assertions that brings the attributes together and define the rules for them. The external rulesets in this expresses a second level information whereas, Internal rulesets defines the first level of information with defined sets of invariants. Object assertions are made to include the rulesets that are defined using the logics provided with the objects only.

What are the different types of implementation terms in UML?

There are many implementation terms that need to be known before starting anything on UML are as:
Type: type is a term that defines that a class with no implementation. It is the full assertion that is given to provide the instances and all its rulesets.
Class: is a construct that is used as a blueprint to create instances of the classes.
Interface: it is a list of the messages that is sent to an object with their parameters and return types. This can include get and set operations and their attributes.
Invariant is a type of constraint that consists of a single rule that is followed by all the objects that lies in the scope of its.

What are the rules specified for invariants in first order and second order information?

The rules are specified for first order and second order information and it is provided for the first order as that internal attribute values are not stored explicitly and there is always a database trigger that will represent the objects.
The operations has to be in non-procedural language and it will represent the objects and the control will be done from here only.
The second order rules specifies the dependencies that exist between attributes .
Global pre-conditions and post-conditions will be applied to all the operations.
Rules will help the invariants to make an object’s semantics explicit and make it visible for all the object. This helps in describing the information in the repository and allow the business rules to be implemented properly.

How does the rule chaining concept works in UML?

Rule chaining is based on some rules based system that is non-procedural and the ordering of the rules doesn't affect the interpretation of it. Rules are grouped together into rulesets with the derivation of all the values of some objects. It includes the rule of another object and allow the developers to also include their own rules to identify the objects uniquely. The following example will show the following work flow:
Regime = ‘Backward’;
Goal = product;
If client.status is ‘Retired’
then product is ‘Annuity’;

If client.status is ‘Young’
and client.preference is not ‘Risk’
then product: is ‘Endowment’;

If Client.Children: > 0
then client.preference is ‘Risk’;

What does state model represent?

State model defines the state transition diagrams that are useful to create UML state charts. These diagrams are used to capture the dynamic nature of each object that are related in the object model. It defines the effective specification of operations and assertions. This represents the possible sequence of state change from one state to another. The transition is the change in state from one to another. This can have very complex design and it represent the state of the object from start till end. It captures the information about the business and the system on which it is implemented. The use case model is used to define the state model in which there is always a start state and an end state. The transactions are represented by the communication that is happening in between.

What are the roles played by packages, modules and wrappers in UML?

Packages are used to organize the classes at one place. It uses modelling to describe the system with less complexity and provide many strategies to incorporate in the model. The unit of package as the classes in the same package are closely related. These keeps all the classes together that are related to each other and uses the association and different use cases to create models.
Modules are also known as component diagrams that includes nodes as physical computers and displays several packages inside a component. Modules are used to hold the packages together in one and can be used together.
Wrappers are used to constitute a package that consists of contents of the package. It deploys client-server or architectural layers that are connected using the API that are predefined. Wrappers use the components that consists of object and allow fall back on standard UML model.

No comments:

Post a Comment