Ask Question, Ask an Expert

+61-413 786 465

info@mywordsolution.com

Ask Computer Engineering Expert

Project Part 1

 

Use this Assignment resource to submit Part 1 of your Final Project.

 

This Final Project will be an ongoing project throughout this course. Its goal is to tie together different aspects of how XML and all of its constituent parts can be tied together. During this project, files for XSD, XSLT, CSS, and XHTML will be used to transform the data in XML into formats that allow for the parsing of this data as well as visualization and styling of the data.

 

The example that will be used here will be the translating of measurements, both distance and weight, from one measurement standard to another. The distance measurements will translate from Imperial mile to Metric Kilometer. The weight measurements will translate from Troy Ounce to Metric Gram.

 

For this first part of the project, you will turn in 4 files:

 

  • measurements1.html
  • measurements1.xml
  • measurements1.xsd
  • measurements1.xslt

 

You will be creating the xml, xsd, and the xslt files using any text editor you want. The html file will be created for you using the saxon tool.

 

1. Use the measurements1.xsd file from the previous assignment.

 

2. Build an XML document based on the schema in measurements1.xsd. Name this document measurements1.xml.

 

a. This XML document should have a root of measurements.

 

b. This XML document should have at least 3 child elements to measurements.

 

3. Create an XSLT style sheet to display the contents in the measurements1.xml file. Name this file measurements1.xslt.

 

a. The first template should match the root of the document.

 

i. Inside the template, create an html document that outputs the total number of items in the measurements1.xml file and how many of each type are in the file.

 

ii. There should also be an apply-templates call that matches the measurement element.

 

b. The second template should match measurement.

 

i. In this template, choose between weight and distance based on the attribute typeOfMeasurement

 

ii. For distanceType, you should output the distance/@measureDistance attribute, as well as the distance element.

 

iii. For weightType, you should output the weight@measureWeight attribute, as well as the weight element.

 

4. Run these through the sax processor with the command

 

Transform.exe -sa -s:measurements1.xml -xsl:measurements1.xslt -xsd:measurements1.xsd -o:measurements1.html

 

This should result in an html file that outputs something similar to:

 

The 3 measurements that I want transformed.

 

There are 2 distance measurements

 

There is 1 weight measurement.

 

A distance measurement using the imperial scale is:

 

The length of the distance is 1.45

 

A weight measurement using the troy scale is:

 

The amount of the weight is .6

 

A distance measurement using the metric scale is:

 

The length of distance is 25

 

Computer Engineering, Engineering

  • Category:- Computer Engineering
  • Reference No.:- M92059130

Have any Question?


Related Questions in Computer Engineering

Assignment week 2 documenting the project

Assignment: Week 2 Documenting the Project Lifecycle Well-written project documentation clarifies intent, documents decisions and results, and allows project managers to assess project progress (and report it, as necessa ...

Taskwrite an essay according to the following

Task Write an essay according to the following instructions. Your lecturer will provide few links for relevant articles and/or case studies. These will be available to you just after your second assignment submission dat ...

A set of coins makes change fornbspnnbspif the sum of the

A set of coins makes change for n if the sum of the values of the coins is n. For example, if you have 1-cent, 2-cent and 4-cent coins, the following sets make change for 7: 7 1-cent coins 5 1-cent, 1 2-cent coins 3 1-ce ...

Question suppose we have a packet switched network in which

Question : Suppose we have a packet switched network in which two stations A and B are always separated by four intermediate nodes/switches, i.e., the two are 5 hops apart. Suppose station A wishes to transmit 1 MB (1024 ...

A sample of 40 songs from a students itunes playlist showed

A sample of 40 songs from a student's iTunes playlist showed a mean length of 3.542 minutes with a standard deviation of 0.311 minute. Construct a 95% confidence interval for the population standard deviation.  (Round yo ...

A measurement of etch depth has standard deviation of 2 um

A measurement of etch depth has standard deviation of 2 um. The specifications are 150 to 200 um. If k = 6, what is the P/T ratio of the measurement? Please show the formula/steps taken to receive the answer.

Can someone help me identify how intrustion detection

Can someone help me identify how Intrustion detection system and intrusion prevent system can help protect confidentiality, integrity and availability

We have seen how dynamic arrays enable arrays to grow while

We have seen how dynamic arrays enable arrays to grow while still achieving constant-time amortized performance. This problem concerns extending dynamic arrays to let them both grow and shrink on demand. a) Consider an u ...

String utilitiesimplement the following methods write a

String Utilities Implement the following methods: // Write a method that returns true if s has leading or trailing whitespace, false otherwise public static boolean needsTrim(String s) // Write a method that swaps the fi ...

Assignmentthe results of the spec cpu2006 bzip2 benchmark

Assignment The results of the SPEC CPU2006 bzip2 benchmark running on an AMD Barcelona has an instruction count of 2.389E12, an execution time of 750 s, and a reference time of 9650 s. 1) Find the CPI if the clock cycle ...

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

Why might a bank avoid the use of interest rate swaps even

Why might a bank avoid the use of interest rate swaps, even when the institution is exposed to significant interest rate

Describe the difference between zero coupon bonds and

Describe the difference between zero coupon bonds and coupon bonds. Under what conditions will a coupon bond sell at a p

Compute the present value of an annuity of 880 per year

Compute the present value of an annuity of $ 880 per year for 16 years, given a discount rate of 6 percent per annum. As

Compute the present value of an 1150 payment made in ten

Compute the present value of an $1,150 payment made in ten years when the discount rate is 12 percent. (Do not round int

Compute the present value of an annuity of 699 per year

Compute the present value of an annuity of $ 699 per year for 19 years, given a discount rate of 6 percent per annum. As