Software Engineering Transformations Quiz

TimeHonoredLiberty avatar
TimeHonoredLiberty
·
·
Download

Start Quiz

Study Flashcards

Questions and Answers

What are the two spaces between design and implementation mentioned in the text?

Model space and code space

Which of the following is NOT one of the 4 different types of transformations mentioned in the text?

System model transformation

In the example provided, what field is pulled up during the refactoring process?

email

What is the new class hierarchy after the refactoring process in the given example?

<p>Player extends User, LeagueOwner extends User</p> Signup and view all the answers

What type of transformation involves creating a new system model based on an existing program in Java?

<p>Reverse engineering</p> Signup and view all the answers

What is the purpose of forward engineering as mentioned in the text?

<p>To transform a model into source code</p> Signup and view all the answers

In the transformed source code, how is the one-to-one association between Advertiser and Account represented?

<p>The Advertiser class has an Account object and the Account class does not have an Advertiser attribute</p> Signup and view all the answers

What is the purpose of the User's 'notify' method in the transformed source code?

<p>To notify the users of any changes</p> Signup and view all the answers

In the transformed source code, how is the one-to-many association between Advertiser and Account represented?

<p>The Advertiser class has a list of Account objects</p> Signup and view all the answers

What does the 'getMaxNumLeagues' method in the LeagueOwner class return?

<p>The maximum number of leagues allowed</p> Signup and view all the answers

In the transformed source code, what does the 'notify' method in the User class do?

<p>Notifies users of any changes</p> Signup and view all the answers

How is inheritance represented in the transformed source code?

<p>Through extending and implementing classes</p> Signup and view all the answers

What is the purpose of the 'setEmail' method in the User class?

<p>To set a new email for the user</p> Signup and view all the answers

What does the 'getAccount' method in the Advertiser class return?

<p>The account object</p> Signup and view all the answers

What does the 'getOwner' method in the Account class return?

<p>The account owner's details</p> Signup and view all the answers

What type of association is represented by a bidirectional many-to-many association?

<p>Many-to-many association</p> Signup and view all the answers

Study Notes

Summary of Transformations and Refactoring

  • Two spaces between design and implementation mentioned are: problem space and solution space.

Transformations

  • Four types of transformations mentioned: renovation, migration, integration, and modernization.
  • NOT one of the 4 different types of transformations is renovation.

Refactoring Example

  • Field pulled up during the refactoring process: email.

Refactored Class Hierarchy

  • New class hierarchy after refactoring: Advertiser -> Account -> User, League -> LeagueOwner -> User.

Transformation Types

  • Type of transformation that involves creating a new system model based on an existing program in Java: modernization.

Forward Engineering

  • Purpose of forward engineering: to create a new system model based on an existing program.

Associations in Transformed Source Code

  • One-to-one association between Advertiser and Account: Advertiser has a reference to an Account object.
  • One-to-many association between Advertiser and Account: Advertiser has a list of Account objects.

notify Method and Inheritance

  • Purpose of the User's 'notify' method: to notify the user of something.
  • notify method in the User class: sends a notification to the user.
  • Inheritance in the transformed source code: the LeagueOwner class inherits from the User class.

Getter and Setter Methods

  • getMaxNumLeagues method in the LeagueOwner class: returns the maximum number of leagues.
  • setEmail method in the User class: sets the email address of the user.
  • getAccount method in the Advertiser class: returns the associated Account object.
  • getOwner method in the Account class: returns the associated User object.

Associations

  • Bidirectional many-to-many association: represents an association between two classes where each instance of one class is related to multiple instances of the other class, and vice versa.

Studying That Suits You

Use AI to generate personalized quizzes and flashcards to suit your learning preferences.

Quiz Team
Use Quizgecko on...
Browser
Browser