Design and implement a web interface

Assignment Help Web Project
Reference no: EM131329703

Use Spring MVC framework

Coursework Description

Your task is to design and implement a web interface and RESTful web services backend for the Universal Modelling Editor (UME). UME is a web application that allows users to build a classes hierarchy, define attributes and relations between classes, as well as to create, store and search instances of user-defined classes.

UME consists of two main components: Taxonomy Builder and the Object Repository.

Taxonomy Builder: classes can be defined and organised into a superclass-subclass hierarchy, which is also known as taxonomy. A class definition includes the class name and properties. Properties can be attributes of primitive data types or relationships to other classes.

Object Repository: objects are instances of classes. The object repository provides a flexible data entry interface, which allows users to create instances of any user-defined class with dynamically generated form fields based on the class definition.

Note: some Java domain class templates are provided (see Appendix 1.3). You may use these classes in the implementation and you are allowed to modify them. However, you may choose not to use these classes.

Part 1: RESTFul Web Service:

Taxonomy Builder allows users to edit classes and properties, as well as organise class hierarchy. Your first task is to implement the following RESTful services to provide backend support for the web interface.

(1) GET /rest/class/create?classname=Postgraduate&superclass=Student

Create a subclass with a given superclass. Considering the example above, this request will create a class "Postgraduate", which is a subclass of "Student". The service should return true if the operation is successful, otherwise false is returned. If the superclass is not explicitly specified then the class will be created as a top-level class. If the class already exists, the service should add a new superclass to this class (multiple inheritance is allowed. e.g. TeachingAssistant can be a subclass of both Postgraduate and Staff)

Consider the following HTTP GET requests:

GET /rest/class/create?classname=Root

GET /rest/class/create?classname=Person&superclass=Root GET /rest/class/create?classname=Staff&superclass=Person GET /rest/class/create?classname=Student&superclass=Person GET /rest/class/create?classname=Lectuer&superclass=Staff

GET /rest/class/create?classname=TeachingAssistant&superclass=Staff GET /rest/class/create?classname=Undergraduate&superclass=Student GET /rest/class/create?classname=Postgraduate&superclass=Student

GET /rest/class/create?classname=TeachingAssistant&superclass=Postgraduate GET /rest/class/create?classname=Module&superclass=Root

GET /rest/class/create?classname=MScModule&superclass=Module GET /rest/class/create?classname=BScModule&superclass=Module

A class hierarchy will be created as follows:

(2) GET /rest/class/delete?classname=Student

Delete a class from the hierarchy. When a class is deleted, all its subclasses will also be deleted, all its instances (including instances of its subclasses) will be deleted too. For example, the request above will delete class "Student" and all its subclasses including "Postgraduate", "Undergraduate", "TeachingAssistant" and any instances of these classes will also be deleted. The service should return true if the operation is successful, otherwise false is returned.

(3) GET /rest/class/hierarchy?classname=Student

Return a hierarchical JSON string reflects a sub-tree structure in the class hierarchy with the given root. For example, the request above should return a JSON object in response:

(4) GET /rest/class/getSubclassList?classname=Student&direct=true

Return all subclass of the given class, with the boolean flag direct set to true for direct subclasses,
false for direct and inferred (indirect) subclasses. For example, the request above should return:

If direct is set to false, the response should be:

Note: the order in which the subclasses are listed is not important.

(5) GET /rest/class/createHierarchy? construct={Staff{Lecturer,TeachingAssistant},Student{Undergraduate,Postgraduate{ TeachingAssistant}}}&root=Person

This service will construct a substree from the given string. For example, the above request adds a subtree hierarchy to the "Person" class. The service returns true if the operation is successful, otherwise false is returned. (Hints: write a simple string parser using recursion or stack)

Note:
You may need to design and implement other RESTful web service to complete Part 2 and Part 3.

Part 2: Web Interface for Taxonomy Builder

Creating Classes and Class Hierarchy

The web interface should support the following features:

- Show the class hierarchy in a TreeView. (See Appendix for more information on TreeView)
- Create new subclasses with the selected superclass.
- Rename or delete existing class from the hierarchy.
- TreeView should be refreshed when the hierarchy is updated.
- List all properties that are available for a class to use, including properties inherited from the superclass.

Assume that

- All classes have distinct names. For example, all occurrences of TeachingAssistant in Figure (1) are referring to the same class.
- When a class is deleted, all its subclasses will also be deleted.
- Multiple inheritance is allowed. For example, TeachingAssistant can be a subclass of class
Postgraduate and Staff.

Defining Properties

Properties represent attributes and relationships of classes. The web interface should support allow us to:

- Create a new property
- Delete an existing property
- Specify the classes to which the property belongs
- Specify the data type of the property.

Assume that
- All properties have distinct names.
- Property types may be primitive data types or user-defined classes.
- Only four primitive types are supported: String, int, double, and boolean.
- Nested and recursive class definition are supported. For example, class Person may have a property called "spouse" of type Person.
- A property might be reused in several classes. For example, property name (of type String) can be
used in class Module and class Person.
- All of the properties are optional (not mandatory).
- A subclass always inherits all of the properties of its superclass. For example, if property employeeId is defined in class Staff then all its subclasses (e.g. Lecturer and TeachingAssistant) should also contain employeeId property.

Part 3: Web Interface for Object Repository

Object Repository provide a web interface for users to store instances. Objects in the repository are instances of pre-defined classes created in the Taxonomy Builder. The interface should allow us to :

- Create an instance of the selected class.

- List instances by their class.

- Assign values to properties with a dynamically generated form.

- View all property values of an instance

Assume that

- deleting a class should also delete all its instances (including instances of its subclasses)

- Instances cannot change their type once created.

- Nested and recursive class definition are supported. For example, class Person may have a property called "spouse" of type Person.

- The structure of a class cannot be changed once an instance of such class has been created. (If this is
not the case then any changes to the class require all instances of the changed class to be modified so as to reflect the modified class structure)

Bonus Question

Use Google Charts API to visualise instances in a Treemap. Classes are displayed as a rectangles in Treemap, the sizes of the rectangles represent the number of instances of in this class. See the link below for more information.

Reference no: EM131329703

Questions Cloud

Find correlated equilibrium that maximizes the expected sum : Find the correlated equilibrium that maximizes the expected sum of the two players' payoffs.- Find the correlated equilibrium that minimizes the expected sum of the two players' payoffs.
Difference between mediation and arbitration : This assignment has two parts.  The first is to explain in your own words the difference between mediation and arbitration in the context of conflict resolution - giving a real world example of each.  The second is to explain in your own words why..
Three positive net present value opportunities : Kyle Electric has three positive net present value opportunities. Unfortunately, the firm has not been able to find financing for any of these projects. Which one of the following terms best fits the situation facing the firm? Sensitivity analysis Ca..
Important part of becoming a business professional : Discussion: Pricing-One of the 4 P's Being up to date with current events is an important part of becoming a business professional. In marketing, it is part of an important responsibility to continuously scan the external environment for opportuni..
Design and implement a web interface : CO3098-CO7098 - Mini Web Project and design and implement a web interface and RESTful web services backend for the Universal Modelling Editor (UME). UME is a web application that allows users to build a classes hierarchy, define attributes and rel..
What were the political implications of mass culture : To many Europeans, the turn of the 20th century was a time of optimism and confidence in progress. How did modernism represent a loss of confidence in order, traditions, and beliefs, and what were the political implications of mass culture
Management of expectations is strategy best defined : The management of expectations is a strategy best defined? by:
Intervention necessary to save institution : For the fall for washington mutual in the financial crisis of 2008, What is the probable future of the institution? Is (or was) government intervention necessary to save this institution?
Discuss about employee relations and avoiding litigation : Examine the major benefits to an organization that allocates organizational resources towards employee relations activities. Then, specify two employee relations activities that you believe would have the greatest impact on an organization. Provid..

Reviews

Write a Review

Web Project Questions & Answers

  Design your own simple and unique web application form

Create your own simple and unique Web application form. The form should include at least 2 different input types such textfield, textarea, radio button, check box, select (drop-down menu) and others of your choice.

  The emotional design model

The user experience framework can help designers constrain and scope the user experience of a given system. The user experience framework also informs about the relationship between a conceptual model and a user's understanding of it for past, c..

  Design a website on global concern

Design a website on your 'passion project'. This is some topic based on social or global concern to which you would like to raise awareness and bring about change.

  Logo for advertisements in mobile apps or websites

Logos are all around us - from the products we purchase and the commercials on television, to advertisements in mobile apps or websites. For this discussion, you must upload or embed at least two (2) images of different logos

  How to link damn things forgive me i am sixty my brains

I have created an HTML web page it sucks and 4 XML files and for the life of me can not remember how to link the damn things forgive me I'm 60 my brains a little slow!

  How the servertokens directive works by now

You should understand how the ServerTokens directive works by now. You can try two other settings, Major and Prod, and see that they reveal increasingly less detail.

  Discuss a range of client-side web and internet technologies

Introduction to Web Programming - CFT2111 - Choose your topic. Remember, the content must be licensed for re-use. Make sure you can source appropriate content for your site and create your HTML pages first, don't worry about CSS. This is often calle..

  Design and develop a web site for the bsit program

IT240 Web Fluency Group Project - Web Design Group Competition. Purpose: To design and develop a web site for the BSIT program offered by the MSIS Department of College of Management, UMass Boston to promote this program to potential students

  What are some strategies used to manage large sound files

What are some strategies used to manage large sound files in web applications (streaming, buffering, compression, etc.)?

  What is the new functionality

What are the main concepts and metaphors that have been used for each (think about the way time is conceptualized for each of them)?

  Create a business website

Create a business Website - The navigation buttons should be implemented as CSS buttons. You can use image sprites if you wish, or simply colours and text.

  Describe in detail the purpose of the website

Describe in detail the purpose of the website. Why is it needed? Who will benefit from the website? The purpose should relate to the target audience.

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