Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Answer completely and carefully based on web services for thumbs up. We want to develop a RESTful web service to allow students to rate the

Answer completely and carefully based on web services for thumbs up.

image text in transcribed

image text in transcribed

image text in transcribed

image text in transcribed

We want to develop a RESTful web service to allow students to rate the teaching of professors in various modules on a scale from 1 to 5. The service must provide all the required web API's to allow client applications to provide the functionality described below. The service maintains data about professors, modules, and the rating of professors by different users (students). Information about modules and professors are manually added by the admin of the service using the admin site. The admin site is automatically created by the web development framework. A module may be: Taught by different professors in different academic years. Taught by different professors in different semesters. Taught by more than one professor at the same time (for example each teaching some part of the module). Since an academic year spans two calendar years (e.g. 2018-19), an academic year will be given by its first year only (hence 2018-19 is given as 2018). Users of the service (students) can rate professors but cannot add or change module information. Before they can rate professors, users must register by providing a username, email, and password. Users can only rate professors when they are logged in to the service. The overall rating of a professor is the average of the professor's rating by all users across all module instances taught by this professor. A module instance is a module taught in a certain year and semester by one or more professors. Any decimal fraction in the average is rounded to the nearest integer. A client application connected to the service will provide the user with the following options: Option 1. View a list of all module instances and the professor(s) teaching each of them. Here is an example of a possible client application output for this option: Code Taught by JE1, Professor J. Excellent VS1, Professor V. Smart Semester Name Year CD1 Computing for Dummies 2017 JE1, Professor J. Excellent CD1 2018 2 Computing for Dummies PG1 2017 2 TT1, Professor T. Terrible Programming for the Gifted Note that modules and professors are given unique identifiers in the web service to avoid any possible mix-up between names. Option 2. View the rating of all professors. Here is an example of a possible client application output for this option. The rating of Professor J. Excellent (JE1) is ***** The rating of Professor T. Terrible (TT1) is The rating of Professor V. Smart (VS1) is ** Option 3. View the average rating of a certain professor in a certain module: The rating of Professor V. Smart (VS1) in module Computing for Dummies (CD1) is *** Option 4. Rate the teaching of a certain professor in a certain module instance. Note that all filtering of data and calculations should be done by the server, i.e. the client application does not process incoming data; the application simply displays the data returned by the service in a human readable format. c) Write pseudocode for a handler function (called a view function in Django) that processes the request to get the rating of a certain professor in a certain module. We want to develop a RESTful web service to allow students to rate the teaching of professors in various modules on a scale from 1 to 5. The service must provide all the required web API's to allow client applications to provide the functionality described below. The service maintains data about professors, modules, and the rating of professors by different users (students). Information about modules and professors are manually added by the admin of the service using the admin site. The admin site is automatically created by the web development framework. A module may be: Taught by different professors in different academic years. Taught by different professors in different semesters. Taught by more than one professor at the same time (for example each teaching some part of the module). Since an academic year spans two calendar years (e.g. 2018-19), an academic year will be given by its first year only (hence 2018-19 is given as 2018). Users of the service (students) can rate professors but cannot add or change module information. Before they can rate professors, users must register by providing a username, email, and password. Users can only rate professors when they are logged in to the service. The overall rating of a professor is the average of the professor's rating by all users across all module instances taught by this professor. A module instance is a module taught in a certain year and semester by one or more professors. Any decimal fraction in the average is rounded to the nearest integer. A client application connected to the service will provide the user with the following options: Option 1. View a list of all module instances and the professor(s) teaching each of them. Here is an example of a possible client application output for this option: Code Taught by JE1, Professor J. Excellent VS1, Professor V. Smart Semester Name Year CD1 Computing for Dummies 2017 JE1, Professor J. Excellent CD1 2018 2 Computing for Dummies PG1 2017 2 TT1, Professor T. Terrible Programming for the Gifted Note that modules and professors are given unique identifiers in the web service to avoid any possible mix-up between names. Option 2. View the rating of all professors. Here is an example of a possible client application output for this option. The rating of Professor J. Excellent (JE1) is ***** The rating of Professor T. Terrible (TT1) is The rating of Professor V. Smart (VS1) is ** Option 3. View the average rating of a certain professor in a certain module: The rating of Professor V. Smart (VS1) in module Computing for Dummies (CD1) is *** Option 4. Rate the teaching of a certain professor in a certain module instance. Note that all filtering of data and calculations should be done by the server, i.e. the client application does not process incoming data; the application simply displays the data returned by the service in a human readable format. c) Write pseudocode for a handler function (called a view function in Django) that processes the request to get the rating of a certain professor in a certain module

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

OCA Oracle Database SQL Exam Guide Exam 1Z0-071

Authors: Steve O'Hearn

1st Edition

1259585492, 978-1259585494

More Books

Students also viewed these Databases questions

Question

What does this public think about this issue?

Answered: 1 week ago

Question

What benefits can you offer this public?

Answered: 1 week ago

Question

How free does this public see itself to act on this issue?

Answered: 1 week ago