Home Page > > Details

Help With data Programming,Help With Java/c++ Programming

0University of Leicester SOA: Service-oriented
Architectures
Spring 2022
This is assessed individual work worth 20% of the module mark. You are not allowed to share any part of your solution with other students, or copy from theirs, otherwise you risk significant penalties. See Prof Hongji Yang’s lecture on plagiarism for more information.
Coursework1: Data Mapping to XML and JSON
This task continues the development of Groupwork Tasks 2 and 3 on Data Modelling by considering additional requirements for data exchange and their implementation in XML and JSON. We now represent Assessment and Module as separate classes rather than including their data into the Submission. We also record which students are enrolled on which modules.

We consider two operations requiring different data to be exported and transmitted.
The staff interface contains an operation getAllSubmissions that returns submission records across all modules, i.e., which students submitted to which assessments on which modules. (The motivation is to detect cases of missed submissions, which indicate lack of engagement, but this is not part of this assignment.)

The student interface offers an operation getMySubmissions providing a student with a list of their submissions to all assessments across all modules.

Your task is to map the relevant parts of the data model below to a DTD and a JSON schema to specify the data required for returning:
as XML, all submissions by all students as returned by getAllSubmissions
as JSON, all submissions by a given student in reply to getMySubmissions

The getAllSubmissions operation downloads a potentially large number of records, including information on the students who made these submissions, the assessments, and modules they were submitted to, which we do not want to duplicate in our XML representation.

By contrast, getMySubmissions returns a smaller amount of data for a single student, so we are not worried about the size of the JSON representation or potential redundancy but need our data to easy to display in a web page or email. (The actual rendering of the data in html or other human-readable formats is not part of the assignment.)

The problems in Tasks A and B are independent of each other. While they use the same original data models and share some requirements, they are concerned with different operations, scenarios, and target languages. Therefore, some of your design choices to A and B should be different, too.

Task A: XML Mapping – similar to Groupwork Task 2
Design a DTD that could supports the data returned by an invocation of
getAllSubmissions(“AY2021-22_Sem2”)
for the 2nd Semester of the academic year 2021-22, following the steps below. Take care to create a solution that minimises redundancy to ensure a compact representation of the data.

1.Create a reduced class diagram containing only the elements relevant to this task. Justify your choices.
2.Create an XML-specific class diagram and justify the chosen document structure using the requirements from the scenario. Justify your choices.
3.Derive the DTD and justify the style of mapping you have chosen for the attributes.
4.Is the mapping from the class diagram in 2. to the DTD data-preserving? Please justify your answer. In particular
a.If the mapping does not extend the data capacity, provide a valid object diagram as counterexample and explain why there is no corresponding valid XML instance.
b.If the mapping does not reflect data capacity, provide a valid XML instance as counterexample and explain why there is no corresponding valid object diagram.
5.Use the XML validator in the project template to check your XML instance against your DTD schema and include a screenshot of the Eclipse console with the numeric code generated as proof of successful validation. (Consult the companion document for detailed instructions.)

Task B: JSON Mapping – based on Groupwork Task 3
Create a sample JSON object to be returned as a result of invoking
getMySubmissions ()
in the following steps.

6.Create a reduced class diagram containing only the elements relevant to this task. Justify your choices.
7.Create a class diagram defining the structure you want to use to represent the data in JSON. This is analogous to an XML-specific class diagram, except that the target language is JSON. What is the structure of the mapping you decided to use?
8.Derive a JSON Schema, aiming to capture the same data and constraints as your JSON-specific class diagram in 7.
9.Create the sample JSON object following your JSON schema. Use your own student ID and data, selecting 2 modules you are registered for with 3 selected assessments in total, and 2 real or imaginary submissions.
10.Use the JSON validator in the project template to check your JSON object against your schema and include a screenshot of the Eclipse console with the numeric code generated as proof of successful validation. (Consult the companion document for detailed instructions.)

Submit your solution on Blackboard as a single zip file containing
-the complete project folder with all your code and document files
-including in the main folder a single pdf document with answers to all questions, including all DTD, XML, JSON, and JSON schema code, and screenshots of Eclipse console with the two numeric codes (XML and JSON validations).

Contact Us - Email:99515681@qq.com    WeChat:codinghelp
Programming Assignment Help!