Deck 5: Working With Xslt and Xpath

Full screen (f)
exit full mode
Question
Curly braces cannot be nested within the attribute value.
Use Space or
up arrow
down arrow
to flip the card.
Question
A(n) predicate result element is any element that is not part of the XSLT vocabulary but is sent directly into the result document as raw text.
Question
XSL-FO (Extensible Stylesheet Language - Formatting Objects) is used to transform the contents of an XML document into another document format.
Question
XSLT style sheets are XML documents.
Question
The xsl:choose element provides a condition from which to choose.
Question
Any node found at a level below another node is referred to as a(n) sibling of that node.
Question
The match attribute of the xsl:template element is used to design the output format for the specified node set.
Question
The relative path .. refers to the parent of the context node.
Question
The simplest way to view a web page generated by an XSLT 1.0 style sheet is to open the source document in your web browser.
Question
A(n) predicate can also indicate the position of a node in the node tree.
Question
The xsl:otherwise element is applied when no conditions are satisfied.
Question
Set the indent attribute to yes to make the code in your result document easier to read.
Question
If there are multiple nodes that match the location path, you can create a style for each matching node using the for-each instruction.
Question
You can test for the presence or absence of an attribute or element by entering the attribute or element name without any comparison operator.
Question
You can reduce errors and speed up processing by using the indent=" yes " attribute with the  tag.
Question
The xsl:value-of element applies a template for the selected nodes.
Question
Simply creating a template forces the XSLT processor to use it with the result document.
Question
Like many other programming languages, XSLT supports an else-if construction.
Question
The root document contains the data that will be transformed using a style sheet.
Question
If the root element in the result document is the XHTML element, then the result document will be created as an XHTML file.
Question
To apply a template, use the _____ instruction.

A) match
B) insert-template
C) select
D) apply-templates
Question
<strong>  In the node tree shown in the accompanying figure, date is a(n) _____ node of stock.</strong> A) parent B) child C) sibling D) ancestor <div style=padding-top: 35px>
In the node tree shown in the accompanying figure, "date" is a(n) _____ node of "stock."

A) parent
B) child
C) sibling
D) ancestor
Question
The fundamental template in the XSLT style sheet is the _____ template, which defines styles for the source document's root node.

A) root
B) ancestor
C) parent
D) source
Question
_____ was released in 1999 and enjoys universal support with XML processors and web browsers.

A) XPath 1.0
B) XPath 2.0
C) XPath 3.0
D) XPath 4.0
Question
If there are multiple nodes that match the location path, you can create a style for each matching node using the _____ instruction.

A) value-of
B) select
C) for-each
D) if-else
Question
The _____ element is used to define the format of the result document.

A) source
B) template
C) output
D) predicate
Question
XPath supports the wildcard character ( _____ ) to reference nodes of any type or name.

A) %
B) *
C) #
D) $
Question
The _____ document contains the data that will be transformed using a style sheet.

A) source
B) template
C) output
D) predicate
Question
To display a data value from a node in the source document, XSLT employs the _____ element.

A) data-value
B) value-of
C) select
D) apply-value
Question
_____ result elements are any elements that are not part of the XSLT vocabulary but instead are sent directly to the result document as raw text.

A) Rendered
B) Literal
C) Output
D) Conditional
Question
The _____ template defines styles for the source document's root node.

A) source
B) root
C) output
D) predicate
Question
When the _____ attribute is omitted the apply-templates instruction automatically processes all of the children of the context node, including any text nodes.

A) match
B) insert
C) uri
D) select
Question
A(n) _____ path is a path that always starts from the root node and descends down through the node tree to a particular node or node set.

A) absolute
B) relative
C) root
D) source
Question
In the root element for an XSLT document, the stylesheet element needs to be placed in the http://www.w3.org/1999/XSL/ _____ namespace.

A) Transform
B) Stylesheet
C) Template
D) Translate
Question
<strong>  In the node tree shown in the accompanying figure, portfolio is a _____ node of author.</strong> A) parent B) child C) sibling D) descendant <div style=padding-top: 35px>
In the node tree shown in the accompanying figure, "portfolio" is a _____ node of "author."

A) parent
B) child
C) sibling
D) descendant
Question
Which of the following XPath expressions for relative paths refers to the context node itself?

A) )
B) ).
C) )//
D) )./..
Question
In a _____ transformation, a client requests retrieval of both a source document and a style sheet from the server.

A) server-side
B) client-side
C) local scope
D) conditional
Question
_____ is used to transform the contents of an XML document into another document format.

A) XSL-FO
B) XHTML
C) MSXML
D) XSLT
Question
<strong>  In the node tree shown in the accompanying figure, sName is a(n) _____ node of portfolio.</strong> A) parent B) sibling C) ancestor D) descendant <div style=padding-top: 35px>
In the node tree shown in the accompanying figure, "sName" is a(n) _____ node of "portfolio."

A) parent
B) sibling
C) ancestor
D) descendant
Question
Which of the following parts of a source document is NOT considered a node?

A) A comment statement
B) The text contained within an element
C) A defined namespace
D) An entity reference
Question
Which of the following XPath expressions for relative paths refers to the parent of the parent of the context node?

A) )./parent
B) ).
C) )
D) )./..
Question
The _____ attribute of the output element sets the URI for the public identifier in the declaration

A) doctype-public
B) encoding
C) version
D) doctype-system
Question
<strong>  In the sort instruction shown in the accompanying figure, the _____ attribute defines the language used to determine sort order.</strong> A) lang B) data-type C) case-order D) select <div style=padding-top: 35px>
In the sort instruction shown in the accompanying figure, the _____ attribute defines the language used to determine sort order.

A) lang
B) data-type
C) case-order
D) select
Question
New elements can be combined with predicates, conditional statements, and the _____ instruction to create a subset of the original source document in a new structure.

A) else-if
B) value-of
C) for-each
D) output
Question
Attributes can also be included in a location path using the XPath expression: _____ @attribute .

A) node
B) match
C) path
D) uri
Question
A _____ node is the text contained within an element.

A) text
B) comment
C) content
D) string
Question
The _____ attribute of the output element defines the output format.

A) encoding
B) version
C) doctype-system
D) method
Question
Multiple nodes sets can be combined into a single location path using the union ( _____ )  operator.

A) &
B) +
C) |
D) ^
Question
The sort instruction can only be used within the _____ tag.

A)
B)
C) Either a. or b.
D) Neither a. nor b.
Question
The _____ element provides a condition to choose from.

A) xsl:otherwise
B) xsl:when
C) xsl:test
D) xsl:choose
Question
The _____ element is applied when no conditions are satisfied.

A) xsl:otherwise
B) xsl:when
C) xsl:test
D) xsl:choose
Question
The _____ comparison operator combines two expressions, returning a value of true only if both expressions are true.

A) or
B) not
C) &=
D) and
Question
The _____ element chooses among different possible styles to apply to the result  document.

A) xsl:otherwise
B) xsl:when
C) xsl:test
D) xsl:choose
Question
The _____ attribute tests whether the XPath expression returns a value of true or false; if it is true the enclosed style is applied.

A) when
B) test
C) choose
D) if
Question
Which of the following XPath expressions for relative paths refers to the parent of the context node?

A) )
B) ).
C) //
D) )./..
Question
You can test for the presence or absence of an attribute or element by entering the attribute or element name without any _____ operator.

A) comparison
B) conditional
C) node
D) choose
Question
When writing a value to an XML attribute, you must enclose the XPath expression within _____.

A) curly braces
B) angle brackets
C) parentheses
D) double quotes
Question
<strong>  In the sort instruction shown in the accompanying figure, _____ is an XPath expression that returns a set of nodes.</strong> A) data-type B) case-order C) node set D) lang <div style=padding-top: 35px>
In the sort instruction shown in the accompanying figure, _____ is an XPath expression that returns a set of nodes.

A) data-type
B) case-order
C) node set
D) lang
Question
A(n) _____ is part of a location path that restricts the node set to only those nodes that fulfill a specified condition.

A) absolute path
B) predicate
C) attribute
D) template
Question
When using the sort instruction, if no attribute values are specified then the nodes are sorted in ascending order with _____ characters sorted first and the language determined by the operating system.

A) uppercase
B) lowercase
C) numeric
D) symbol
Question
The various nodes from the source document are organized into a(n) _____.
Question
<strong>    Hue is developing an XSLT style sheet to display data from a research survey. The structure of the surveys.xml file is shown in the accompanying figure. She comes to you for assistance in preparing the final file. Hue would like to display the value of the date element in her result document. Which of the following do you tell her shows the correct code to use to display this information?</strong> A) <xsl:value-of select=surveys/survey/date /> B) <xsl:select value-of=surveys/survey/date /> C) <xsl:value-of select=date /> D) <xsl:select value-of=date /> <div style=padding-top: 35px>  
Hue is developing an XSLT style sheet to display data from a research survey. The structure of the surveys.xml file is shown in the accompanying figure. She comes to you for assistance in preparing the final file.
Hue would like to display the value of the date element in her result document. Which of the following do you tell her shows the correct code to use to display this information?

A)
B)
C)
D)
Question
Jeremy has been using XML to organize data for a company that manufactures medical devices. He knows you have experience writing XML data to an output file using XSLT and XPath, and asks for your help improving the display of his data. Jeremy has installed the .NET framework and the Saxon XSLT processor. He has developed a style sheet named devices.xsl, and would like to use it to transform his devices.xml file into a web page named devices.html he can display in a browser. However, he is unsure which command to enter to execute this process. Which command do you tell him to use to transform the file correctly?

A) java net.sf.saxon.Transform devices.xml devices.xsl -o:devices.html
B) Transform devices.xml devices.xsl -o:devices.html
C) java net.sf.saxon.Transform devices -s:.*xml -xsl:*.xsl -o:*.html
D) Transform devices -s:.*xml -xsl:*.xsl -o:*.html
Question
The _____ attribute of the output element sets the system identifier in the declaration.

A) doctype-public
B) encoding
C) version
D) doctype-system
Question
In a(n) _____ transformation, a server receives a request from a client to generate the result document.
Question
The _____ attribute of the output element specifies whether the output should be indented to better display its structure.

A) standalone
B) indent
C) encoding
D) version
Question
Jeremy has been using XML to organize data for a company that manufactures medical devices. He knows you have experience writing XML data to an output file using XSLT and XPath, and asks for your help improving the display of his data. Jeremy has been asked to create an output document written in HTML5, but is not sure how to insure the final file will meet this requirement. Which output element do you suggest he use to generate a file that will conform to valid HTML5 standards?

A) Encoding="UTF-8"
Indent="yes" />
B) Encoding="UTF-8"
Indent="yes" />
C) Encoding="HTML5"
Indent="yes" />
D) Encoding="UTF-8"
Indent="yes" />
Question
The result of the transformation of the source document appears in a(n) _____ document.
Question
<strong>    Hue is developing an XSLT style sheet to display data from a research survey. The structure of the surveys.xml file is shown in the accompanying figure. She comes to you for assistance in preparing the final file. Hue would like to define a location path that matches both the surveyID and staffID elements nested within the survey element. Which of the following templates do you tell her properly matches both elements?</strong> A) <xsl:template match=@surveyID|@staffID>   <td><xsl:value-of select=. /></td> </xsl:template> B) <xsl:template match=.>   <td><xsl:value-of select=@surveyID|@staffID /></td> </xsl:template> C) <xsl:template match=@surveyID|staffID>   <td><xsl:value-of select=. /></td> </xsl:template> D) <xsl:template match=@surveyID&@staffID>   <td><xsl:value-of select=. /></td> </xsl:template> <div style=padding-top: 35px>  
Hue is developing an XSLT style sheet to display data from a research survey. The structure of the surveys.xml file is shown in the accompanying figure. She comes to you for assistance in preparing the final file.
Hue would like to define a location path that matches both the surveyID and staffID elements nested within the survey element. Which of the following templates do you tell her properly matches both elements?

A)  

B)  

C)  

D)  
Question
The _____ document contains the data that will be transformed using a style sheet.
Question
Jeremy has been using XML to organize data for a company that manufactures medical devices. He knows you have experience writing XML data to an output file using XSLT and XPath, and asks for your help improving the display of his data. Jeremy has installed Java and the Saxon XSLT processor. He has developed a style sheet named devices.xsl , and would like to use it to transform his devices.xml file into a web page named devices.html he can display in a browser. However, he is unsure which command to enter to execute this process. Which command do you tell him to use to transform the file correctly?

A) java net.sf.saxon.Transform devices.xml devices.xsl -o:devices.html
B) Transform devices.xml devices.xsl -o:devices.html
C) java net.sf.saxon.Transform devices -s:.*xml -xsl:*.xsl -o:*.html
D) Transform devices -s:.*xml -xsl:*.xsl -o:*.html
Question
One of the functions of XPath is to translate this hierarchical structure into an expression called a(n) _____ that references a specific node or node set from the source document.
Question
The _____ language, which was introduced by W3C, is used to access and navigate the contents of a data tree.
Question
Jeremy has been using XML to organize data for a company that manufactures medical devices. He knows you have experience writing XML data to an output file using XSLT and XPath, and asks for your help improving the display of his data. Jeremy would like to reference all the nodes in the node tree, and asks if it will be necessary to type them all out individually. You reassure him that he can select all the nodes in the node tree using the short path expression _____.

A) )*
B) //*
C) )/*
D) *//
Question
An XSLT _____ is an XML document used to transform the contents of the source document into a new format, which appears in the result document.
Question
A collection of nodes is called a(n) _____.
Question
<strong>    Hue is developing an XSLT style sheet to display data from a research survey. The structure of the surveys.xml file is shown in the accompanying figure. She comes to you for assistance in preparing the final file. Hue would like to access the response attribute of the question element. Which of the following do you tell her represents the absolute reference to this attribute?</strong> A) /surveys/survey/question/response B) /surveys/survey/question/@response C) question/@response D) response <div style=padding-top: 35px>  
Hue is developing an XSLT style sheet to display data from a research survey. The structure of the surveys.xml file is shown in the accompanying figure. She comes to you for assistance in preparing the final file.
Hue would like to access the response attribute of the question element. Which of the following do you tell her represents the absolute reference to this attribute?

A) /surveys/survey/question/response
B) /surveys/survey/question/@response
C) question/@response
D) response
Question
<strong>    Hue is developing an XSLT style sheet to display data from a research survey. The structure of the surveys.xml file is shown in the accompanying figure. She comes to you for assistance in preparing the final file. Hue would like to access the response attribute of the question element. Assume the question element is the context node. Which of the following do you tell her represents the relative path to this attribute?</strong> A) /surveys/survey/question/response B) /surveys/survey/question/@response C) question/@response D) /@response <div style=padding-top: 35px>  
Hue is developing an XSLT style sheet to display data from a research survey. The structure of the surveys.xml file is shown in the accompanying figure. She comes to you for assistance in preparing the final file.
Hue would like to access the response attribute of the question element. Assume the question element is the context node. Which of the following do you tell her represents the relative path to this attribute?

A) /surveys/survey/question/response
B) /surveys/survey/question/@response
C) question/@response
D) /@response
Question
<strong>    Hue is developing an XSLT style sheet to display data from a research survey. The structure of the surveys.xml file is shown in the accompanying figure. She comes to you for assistance in preparing the final file. Hue has created an XSLT style sheet named survey.xsl . She would like to link this style sheet to her XML source document. Which of the following do you tell her shows the correct form of the processing instruction she should use?</strong> A) <?xml-stylesheet type=text/xsl uri=survey.xsl ?> B) <?xsl-stylesheet type=text/xsl href=survey.xsl ?> C) <?xml-stylesheet type=text/xsl href=survey.xsl ?> D) <?xsl-stylesheet type=text/xsl uri=survey.xsl ?> <div style=padding-top: 35px>  
Hue is developing an XSLT style sheet to display data from a research survey. The structure of the surveys.xml file is shown in the accompanying figure. She comes to you for assistance in preparing the final file.
Hue has created an XSLT style sheet named survey.xsl . She would like to link this style sheet to her XML source document. Which of the following do you tell her shows the correct form of the processing instruction she should use?

A)
B)
C)
D)
Question
Jeremy has been using XML to organize data for a company that manufactures medical devices. He knows you have experience writing XML data to an output file using XSLT and XPath, and asks for your help improving the display of his data. Jeremy would like to begin by creating a template for the root node. Which of the following do you tell him shows the correct code to use to create the root node template?

A) styles

B) styles

C) styles

D) styles
Unlock Deck
Sign up to unlock the cards in this deck!
Unlock Deck
Unlock Deck
1/91
auto play flashcards
Play
simple tutorial
Full screen (f)
exit full mode
Deck 5: Working With Xslt and Xpath
1
Curly braces cannot be nested within the attribute value.
True
2
A(n) predicate result element is any element that is not part of the XSLT vocabulary but is sent directly into the result document as raw text.
False
3
XSL-FO (Extensible Stylesheet Language - Formatting Objects) is used to transform the contents of an XML document into another document format.
False
4
XSLT style sheets are XML documents.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
5
The xsl:choose element provides a condition from which to choose.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
6
Any node found at a level below another node is referred to as a(n) sibling of that node.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
7
The match attribute of the xsl:template element is used to design the output format for the specified node set.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
8
The relative path .. refers to the parent of the context node.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
9
The simplest way to view a web page generated by an XSLT 1.0 style sheet is to open the source document in your web browser.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
10
A(n) predicate can also indicate the position of a node in the node tree.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
11
The xsl:otherwise element is applied when no conditions are satisfied.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
12
Set the indent attribute to yes to make the code in your result document easier to read.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
13
If there are multiple nodes that match the location path, you can create a style for each matching node using the for-each instruction.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
14
You can test for the presence or absence of an attribute or element by entering the attribute or element name without any comparison operator.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
15
You can reduce errors and speed up processing by using the indent=" yes " attribute with the  tag.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
16
The xsl:value-of element applies a template for the selected nodes.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
17
Simply creating a template forces the XSLT processor to use it with the result document.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
18
Like many other programming languages, XSLT supports an else-if construction.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
19
The root document contains the data that will be transformed using a style sheet.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
20
If the root element in the result document is the XHTML element, then the result document will be created as an XHTML file.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
21
To apply a template, use the _____ instruction.

A) match
B) insert-template
C) select
D) apply-templates
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
22
<strong>  In the node tree shown in the accompanying figure, date is a(n) _____ node of stock.</strong> A) parent B) child C) sibling D) ancestor
In the node tree shown in the accompanying figure, "date" is a(n) _____ node of "stock."

A) parent
B) child
C) sibling
D) ancestor
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
23
The fundamental template in the XSLT style sheet is the _____ template, which defines styles for the source document's root node.

A) root
B) ancestor
C) parent
D) source
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
24
_____ was released in 1999 and enjoys universal support with XML processors and web browsers.

A) XPath 1.0
B) XPath 2.0
C) XPath 3.0
D) XPath 4.0
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
25
If there are multiple nodes that match the location path, you can create a style for each matching node using the _____ instruction.

A) value-of
B) select
C) for-each
D) if-else
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
26
The _____ element is used to define the format of the result document.

A) source
B) template
C) output
D) predicate
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
27
XPath supports the wildcard character ( _____ ) to reference nodes of any type or name.

A) %
B) *
C) #
D) $
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
28
The _____ document contains the data that will be transformed using a style sheet.

A) source
B) template
C) output
D) predicate
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
29
To display a data value from a node in the source document, XSLT employs the _____ element.

A) data-value
B) value-of
C) select
D) apply-value
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
30
_____ result elements are any elements that are not part of the XSLT vocabulary but instead are sent directly to the result document as raw text.

A) Rendered
B) Literal
C) Output
D) Conditional
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
31
The _____ template defines styles for the source document's root node.

A) source
B) root
C) output
D) predicate
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
32
When the _____ attribute is omitted the apply-templates instruction automatically processes all of the children of the context node, including any text nodes.

A) match
B) insert
C) uri
D) select
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
33
A(n) _____ path is a path that always starts from the root node and descends down through the node tree to a particular node or node set.

A) absolute
B) relative
C) root
D) source
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
34
In the root element for an XSLT document, the stylesheet element needs to be placed in the http://www.w3.org/1999/XSL/ _____ namespace.

A) Transform
B) Stylesheet
C) Template
D) Translate
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
35
<strong>  In the node tree shown in the accompanying figure, portfolio is a _____ node of author.</strong> A) parent B) child C) sibling D) descendant
In the node tree shown in the accompanying figure, "portfolio" is a _____ node of "author."

A) parent
B) child
C) sibling
D) descendant
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
36
Which of the following XPath expressions for relative paths refers to the context node itself?

A) )
B) ).
C) )//
D) )./..
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
37
In a _____ transformation, a client requests retrieval of both a source document and a style sheet from the server.

A) server-side
B) client-side
C) local scope
D) conditional
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
38
_____ is used to transform the contents of an XML document into another document format.

A) XSL-FO
B) XHTML
C) MSXML
D) XSLT
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
39
<strong>  In the node tree shown in the accompanying figure, sName is a(n) _____ node of portfolio.</strong> A) parent B) sibling C) ancestor D) descendant
In the node tree shown in the accompanying figure, "sName" is a(n) _____ node of "portfolio."

A) parent
B) sibling
C) ancestor
D) descendant
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
40
Which of the following parts of a source document is NOT considered a node?

A) A comment statement
B) The text contained within an element
C) A defined namespace
D) An entity reference
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
41
Which of the following XPath expressions for relative paths refers to the parent of the parent of the context node?

A) )./parent
B) ).
C) )
D) )./..
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
42
The _____ attribute of the output element sets the URI for the public identifier in the declaration

A) doctype-public
B) encoding
C) version
D) doctype-system
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
43
<strong>  In the sort instruction shown in the accompanying figure, the _____ attribute defines the language used to determine sort order.</strong> A) lang B) data-type C) case-order D) select
In the sort instruction shown in the accompanying figure, the _____ attribute defines the language used to determine sort order.

A) lang
B) data-type
C) case-order
D) select
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
44
New elements can be combined with predicates, conditional statements, and the _____ instruction to create a subset of the original source document in a new structure.

A) else-if
B) value-of
C) for-each
D) output
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
45
Attributes can also be included in a location path using the XPath expression: _____ @attribute .

A) node
B) match
C) path
D) uri
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
46
A _____ node is the text contained within an element.

A) text
B) comment
C) content
D) string
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
47
The _____ attribute of the output element defines the output format.

A) encoding
B) version
C) doctype-system
D) method
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
48
Multiple nodes sets can be combined into a single location path using the union ( _____ )  operator.

A) &
B) +
C) |
D) ^
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
49
The sort instruction can only be used within the _____ tag.

A)
B)
C) Either a. or b.
D) Neither a. nor b.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
50
The _____ element provides a condition to choose from.

A) xsl:otherwise
B) xsl:when
C) xsl:test
D) xsl:choose
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
51
The _____ element is applied when no conditions are satisfied.

A) xsl:otherwise
B) xsl:when
C) xsl:test
D) xsl:choose
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
52
The _____ comparison operator combines two expressions, returning a value of true only if both expressions are true.

A) or
B) not
C) &=
D) and
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
53
The _____ element chooses among different possible styles to apply to the result  document.

A) xsl:otherwise
B) xsl:when
C) xsl:test
D) xsl:choose
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
54
The _____ attribute tests whether the XPath expression returns a value of true or false; if it is true the enclosed style is applied.

A) when
B) test
C) choose
D) if
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
55
Which of the following XPath expressions for relative paths refers to the parent of the context node?

A) )
B) ).
C) //
D) )./..
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
56
You can test for the presence or absence of an attribute or element by entering the attribute or element name without any _____ operator.

A) comparison
B) conditional
C) node
D) choose
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
57
When writing a value to an XML attribute, you must enclose the XPath expression within _____.

A) curly braces
B) angle brackets
C) parentheses
D) double quotes
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
58
<strong>  In the sort instruction shown in the accompanying figure, _____ is an XPath expression that returns a set of nodes.</strong> A) data-type B) case-order C) node set D) lang
In the sort instruction shown in the accompanying figure, _____ is an XPath expression that returns a set of nodes.

A) data-type
B) case-order
C) node set
D) lang
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
59
A(n) _____ is part of a location path that restricts the node set to only those nodes that fulfill a specified condition.

A) absolute path
B) predicate
C) attribute
D) template
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
60
When using the sort instruction, if no attribute values are specified then the nodes are sorted in ascending order with _____ characters sorted first and the language determined by the operating system.

A) uppercase
B) lowercase
C) numeric
D) symbol
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
61
The various nodes from the source document are organized into a(n) _____.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
62
<strong>    Hue is developing an XSLT style sheet to display data from a research survey. The structure of the surveys.xml file is shown in the accompanying figure. She comes to you for assistance in preparing the final file. Hue would like to display the value of the date element in her result document. Which of the following do you tell her shows the correct code to use to display this information?</strong> A) <xsl:value-of select=surveys/survey/date /> B) <xsl:select value-of=surveys/survey/date /> C) <xsl:value-of select=date /> D) <xsl:select value-of=date />  
Hue is developing an XSLT style sheet to display data from a research survey. The structure of the surveys.xml file is shown in the accompanying figure. She comes to you for assistance in preparing the final file.
Hue would like to display the value of the date element in her result document. Which of the following do you tell her shows the correct code to use to display this information?

A)
B)
C)
D)
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
63
Jeremy has been using XML to organize data for a company that manufactures medical devices. He knows you have experience writing XML data to an output file using XSLT and XPath, and asks for your help improving the display of his data. Jeremy has installed the .NET framework and the Saxon XSLT processor. He has developed a style sheet named devices.xsl, and would like to use it to transform his devices.xml file into a web page named devices.html he can display in a browser. However, he is unsure which command to enter to execute this process. Which command do you tell him to use to transform the file correctly?

A) java net.sf.saxon.Transform devices.xml devices.xsl -o:devices.html
B) Transform devices.xml devices.xsl -o:devices.html
C) java net.sf.saxon.Transform devices -s:.*xml -xsl:*.xsl -o:*.html
D) Transform devices -s:.*xml -xsl:*.xsl -o:*.html
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
64
The _____ attribute of the output element sets the system identifier in the declaration.

A) doctype-public
B) encoding
C) version
D) doctype-system
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
65
In a(n) _____ transformation, a server receives a request from a client to generate the result document.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
66
The _____ attribute of the output element specifies whether the output should be indented to better display its structure.

A) standalone
B) indent
C) encoding
D) version
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
67
Jeremy has been using XML to organize data for a company that manufactures medical devices. He knows you have experience writing XML data to an output file using XSLT and XPath, and asks for your help improving the display of his data. Jeremy has been asked to create an output document written in HTML5, but is not sure how to insure the final file will meet this requirement. Which output element do you suggest he use to generate a file that will conform to valid HTML5 standards?

A) Encoding="UTF-8"
Indent="yes" />
B) Encoding="UTF-8"
Indent="yes" />
C) Encoding="HTML5"
Indent="yes" />
D) Encoding="UTF-8"
Indent="yes" />
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
68
The result of the transformation of the source document appears in a(n) _____ document.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
69
<strong>    Hue is developing an XSLT style sheet to display data from a research survey. The structure of the surveys.xml file is shown in the accompanying figure. She comes to you for assistance in preparing the final file. Hue would like to define a location path that matches both the surveyID and staffID elements nested within the survey element. Which of the following templates do you tell her properly matches both elements?</strong> A) <xsl:template match=@surveyID|@staffID>   <td><xsl:value-of select=. /></td> </xsl:template> B) <xsl:template match=.>   <td><xsl:value-of select=@surveyID|@staffID /></td> </xsl:template> C) <xsl:template match=@surveyID|staffID>   <td><xsl:value-of select=. /></td> </xsl:template> D) <xsl:template match=@surveyID&@staffID>   <td><xsl:value-of select=. /></td> </xsl:template>  
Hue is developing an XSLT style sheet to display data from a research survey. The structure of the surveys.xml file is shown in the accompanying figure. She comes to you for assistance in preparing the final file.
Hue would like to define a location path that matches both the surveyID and staffID elements nested within the survey element. Which of the following templates do you tell her properly matches both elements?

A)  

B)  

C)  

D)  
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
70
The _____ document contains the data that will be transformed using a style sheet.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
71
Jeremy has been using XML to organize data for a company that manufactures medical devices. He knows you have experience writing XML data to an output file using XSLT and XPath, and asks for your help improving the display of his data. Jeremy has installed Java and the Saxon XSLT processor. He has developed a style sheet named devices.xsl , and would like to use it to transform his devices.xml file into a web page named devices.html he can display in a browser. However, he is unsure which command to enter to execute this process. Which command do you tell him to use to transform the file correctly?

A) java net.sf.saxon.Transform devices.xml devices.xsl -o:devices.html
B) Transform devices.xml devices.xsl -o:devices.html
C) java net.sf.saxon.Transform devices -s:.*xml -xsl:*.xsl -o:*.html
D) Transform devices -s:.*xml -xsl:*.xsl -o:*.html
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
72
One of the functions of XPath is to translate this hierarchical structure into an expression called a(n) _____ that references a specific node or node set from the source document.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
73
The _____ language, which was introduced by W3C, is used to access and navigate the contents of a data tree.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
74
Jeremy has been using XML to organize data for a company that manufactures medical devices. He knows you have experience writing XML data to an output file using XSLT and XPath, and asks for your help improving the display of his data. Jeremy would like to reference all the nodes in the node tree, and asks if it will be necessary to type them all out individually. You reassure him that he can select all the nodes in the node tree using the short path expression _____.

A) )*
B) //*
C) )/*
D) *//
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
75
An XSLT _____ is an XML document used to transform the contents of the source document into a new format, which appears in the result document.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
76
A collection of nodes is called a(n) _____.
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
77
<strong>    Hue is developing an XSLT style sheet to display data from a research survey. The structure of the surveys.xml file is shown in the accompanying figure. She comes to you for assistance in preparing the final file. Hue would like to access the response attribute of the question element. Which of the following do you tell her represents the absolute reference to this attribute?</strong> A) /surveys/survey/question/response B) /surveys/survey/question/@response C) question/@response D) response  
Hue is developing an XSLT style sheet to display data from a research survey. The structure of the surveys.xml file is shown in the accompanying figure. She comes to you for assistance in preparing the final file.
Hue would like to access the response attribute of the question element. Which of the following do you tell her represents the absolute reference to this attribute?

A) /surveys/survey/question/response
B) /surveys/survey/question/@response
C) question/@response
D) response
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
78
<strong>    Hue is developing an XSLT style sheet to display data from a research survey. The structure of the surveys.xml file is shown in the accompanying figure. She comes to you for assistance in preparing the final file. Hue would like to access the response attribute of the question element. Assume the question element is the context node. Which of the following do you tell her represents the relative path to this attribute?</strong> A) /surveys/survey/question/response B) /surveys/survey/question/@response C) question/@response D) /@response  
Hue is developing an XSLT style sheet to display data from a research survey. The structure of the surveys.xml file is shown in the accompanying figure. She comes to you for assistance in preparing the final file.
Hue would like to access the response attribute of the question element. Assume the question element is the context node. Which of the following do you tell her represents the relative path to this attribute?

A) /surveys/survey/question/response
B) /surveys/survey/question/@response
C) question/@response
D) /@response
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
79
<strong>    Hue is developing an XSLT style sheet to display data from a research survey. The structure of the surveys.xml file is shown in the accompanying figure. She comes to you for assistance in preparing the final file. Hue has created an XSLT style sheet named survey.xsl . She would like to link this style sheet to her XML source document. Which of the following do you tell her shows the correct form of the processing instruction she should use?</strong> A) <?xml-stylesheet type=text/xsl uri=survey.xsl ?> B) <?xsl-stylesheet type=text/xsl href=survey.xsl ?> C) <?xml-stylesheet type=text/xsl href=survey.xsl ?> D) <?xsl-stylesheet type=text/xsl uri=survey.xsl ?>  
Hue is developing an XSLT style sheet to display data from a research survey. The structure of the surveys.xml file is shown in the accompanying figure. She comes to you for assistance in preparing the final file.
Hue has created an XSLT style sheet named survey.xsl . She would like to link this style sheet to her XML source document. Which of the following do you tell her shows the correct form of the processing instruction she should use?

A)
B)
C)
D)
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
80
Jeremy has been using XML to organize data for a company that manufactures medical devices. He knows you have experience writing XML data to an output file using XSLT and XPath, and asks for your help improving the display of his data. Jeremy would like to begin by creating a template for the root node. Which of the following do you tell him shows the correct code to use to create the root node template?

A) styles

B) styles

C) styles

D) styles
Unlock Deck
Unlock for access to all 91 flashcards in this deck.
Unlock Deck
k this deck
locked card icon
Unlock Deck
Unlock for access to all 91 flashcards in this deck.