XML

अब Quizwiz के साथ अपने होमवर्क और परीक्षाओं को एस करें!

# What would the browser display if it executed the following script? <SCRIPT LANGUAGE = "JavaScript"> var total = 0; nextLoop: for ( var i = 0; i < 5; ++i ) { for ( var j = 0; j < 2 ; ++j ) { if ( i < 2 ) continue nextLoop; total++; } total++; } total++; document.writeln( total ); </SCRIPT>

10

# Declaring an attribute as 'optional, -, -' means

Attribute may occur once and have any value

# What does the keyword SYSTEM indicate in the following code? <?xml version ="1.0"?> <!DOCTYPE Book SYSTEM "book.dtd">

Book.dtd is an external DTD

# What does the keyword SYSTEM indicate in the following code? <!DOCTYPE Book SYSTEM "book.dtd">

Book.dtd is an internal DTD

# What is the significance of the '+' sign in the code given below? <!ELEMENT BOOK (AUTHOR+)>

Indicates that AUTHOR tag must occur at least once inside the BOOK element

# Which of the following things is unspecified in the following line of code? <!DOCTYPE letter SYSTEM "letter.dtd">

The type of browser you are using.

# An XML document, which conforms to its DTD, is called a:

Well formed Document

# Which of the following is not a JavaScript keyword?

sub

# Call-by- ________ is the method of passing a copy of the argument's value to a function

value

# Which of the following is an illegal array initialization statement?

var n = new Array( 5 ); n = [ 10, 20, 30, 40, 50 ];

# Namespaces are defined using

xmlns:[prefix] attribute

# In XSL, an _____ instruction do contains the template, which is been applied to each node selected with the select attribute

xsl:for-each

# XSLT is:

Extensible Stylesheet Language Transformation

# Which of the following are disadvantages of using SAX parsers?

SAX is read-only

# Represents a collection of attribute nodes

XMLDOMNamedNodeMap

# Functions are invoked by writing the name of the function, followed by the function's ________ in closed parenthesis.

arguments

# Which DOMDocument method is used to create a new attribute?

createAttribute

# What is NOT true about StAX?

it is a "push" parser

# An attribute without a prefix is in default namespace?

true

# See the snipset below and choose one answer: <xsl:value-of select="floor(-2.3)"/>

-3

# Which of the following snippet deletes an attribute of an Element node

... root.removeAttributeNode(attr);

# What is the value of i after the following statements? i = 2; i- -; i- -;

0

# What will the browser display if the following script is executed? < SCRIPT LANGUAGE = "JavaScript" > var theArray = [ 1, 2, 3, 4, 5, 6, 7, 8, 9 ]; modifyArray( theArray[ 3 ] ); document.write( theArray.join( " " ) ); function modifyArray( i ) { i = 11; } </SCRIPT>

1 2 3 4 5 6 7 8 9

# What is the value of i after the following statements? i = 2; i++;

3

# What would the browser display if it executed the following script? <SCRIPT LANGUAGE = "JavaScript"> var total = 0; stop: { // labeled compound statement for ( var i = 0; i < 5; ++i ) { for ( var j = 0; j < 2 ; ++j ) { if ( i == 2 ) break stop; total++; } total++; } total++; } total++; document.writeln( total ); </SCRIPT>

7

# If the DTD is included in your XML source file, it should be wrapped in a DOCTYPE definition with the following syntax:

<!DOCTYPE root-element [element-declarations]>

# For the XML parser to ignore a certain section of your XML document, which syntax is correct?

<![CDATA[ Text to be ignored ]]>

# Which of these is the correct syntax to link a CSS file to an XML document?

<?xml-stylesheet type="text/css" href="url"?>

# What is a correct way of referring to a style sheet called "mystyle.xsl"?

<?xml-stylesheet type="text/xsl" href="mystyle.xsl"?>

# To prevent a type from being derived for defining new types you can specify

<complexType name="Address" final="restriction" />

# Which of the following are valid tags?

<fpt_university>

# To compose a schema with the same target namespace you can use

<include schemaLocation="..." />

# A Complex Type element can be defined using

<xsd:complexType name="..." />

# In XSL, an attributes can be accessed in the way similar to the elements. Notice ____ in front of the attribute name

@

# What statement is true when processing XML in a servlet or JSP?

A DTD or Schema must be provided for validation.

# Which of the following defines what is meant by a valid document?

A document which conforms to the rules of a DTD

# In a DTD, Attributes are declared with an _______ declaration

ATTLIST

# XSLT allows any kind of data to be tranformed into

Boolean

# XML generated by a servlet or JSP CANNOT be displayed by a browser in which one of the following ways?

By passing it from a browser to another servlet or JSP for reformatting

# Schemas can be documented in human readable format by using

Comments

# Builds the document as a in-memory data structures?

DOM

# Which of the following types of parsers is used for object-based parsing?

DOM

# Which object represents the top level of the XML source?

DOMDocument

# Which of the following statement about SAX is false?

Data parsing can be controlled through SAX

# The DocumentBuilder object's parse method to parse an XML document and create a Java _____________ object

Document

# Which of the following is/are optional in the creation of an XML file?

Entities

# The entities that are used only in DTDs are referred to as

General entities

# What does the value string contain after the following code is executed? var string = "Good luck on the test"; string = string.split( " " );

Good luck on the test

# Consider the following HTML code. <HTML> <SCRIPT LANGUAGE = "JavaScript"> <!-- document.writeln("Hello World"); // --> </SCRIPT> </HTML> What would a browser capable of scripting display when executing this code?

Hello World

# Which of the following XML attribute names is invalid?

I am not valid

# ________ is an artificial and informal language that helps programmers develop algorithms.

Pseudocode

# You create a SAX parser by using the ________________object.

SAXParserFactory

# Which of the following is not an extension of XML?

SGML.

# SGML stand for

Standard Generalization Markup Language

# The property 'nextSibling' in DOMDocument Object contains the next node of the previous nodes in the parent's child list.

T

# Which of the following is/are optional in the creation of an XML file?

The <?xml version="1.0"?> statement

# #REQUIRED attributes value means:

The attribute value must be included in the element

# Which of the following is the proper method to apply the fliph filter to the following H1 element? <H1 ID = "test">This is a test</H1>

The filter cannot be applied to this element.

# Which of the following statement explain the characteristics of the methods used to modify nodes in a DOM tree?

The getChildNodes() returns a list of nodes containing all the child nodes of specific node

# Which of the following statements related to the TranformerFactoty class and its methods are false?

The getFeature(String name) method permits the user to set values for specific attributes

# Which of the following statement explains about the object relational mapping?

The object relational mapping uses the XML document as a tree of objects

# What is the significance of the second function argument in the following line? window.setInterval( "run()", 100 );

The value sets how often to run the function.

# Consider the following script. What is wrong with the following code? 1 <SCRIPT LANGUAGE = "JavaScript"> 2 var firstNumber, 3 secondNumber; 4 thirdNumber; 5 6 thirdNumber = 7 parseInt( window.prompt( "Enter an integer", 0 ) ); 8 document.write( thirdNumber ); 9 </SCRIPT>

The word var must be placed before thirdNumber in line 4.

# Which of the following statement about Attribute Node in DOM is true?

This node represents the property of an element

# Which of the following is the purpose of a schema?

To describe and constrain both the structure and data within the XML document

# An XML document, which conforms to its DTD, is called a:

Valid Document

# XML is a _______ Recommendation

W3C

# XML DOM is:

XML Document Object Model

# Which of the following statements are true in the case of XML?

XML describes its data along with its presentation

# Which of the following options describing the feature of XML transformations?

XSLT stylesheets use XPath to navigate between XML as SAX and DOM

# The StAX cursor API represents

a cursor with which you can walk an XML document from beginning to end.

# The StAX cursor API represents _______________.

a cursor with which you can walk an XML document from beginning to end.

# A procedure for solving a problem in terms of the actions to be executed and the order in which these actions are to be executed is called ________.

an algorithm

# Each object has ________ or data and ________ or behavior.

attributes, methods

# You can create the <child> element by using a Document object's ______________ method.

createElement

# Which of the following methods creates a node for inserting textual content in to it?

createTextNode()

# The xsl:template is used to

define a template that can be applied to a node to produce desired output

# Which of the following flowchart symbols indicates that a decision is to be made?

diamond

# A descendant having a new namespace cannot override the namespace defined by the parrent element?

false

# Ability to create one's own tags is XML's greatest disadvantage?

false

# Document Object Model is platform-dependent?

false

# External DTDs use the keyword URL to specify the location of the DTD?

false

# Parameter entities use ampersand (&) and semicolon (;) as delimiters?

false

# The word top in the term top-down stepwise refinement refers to which of the following?

he single statement that completely represents the program

# The best way to develop and maintain a large program is to construct it from small, simple pieces called ________.

modules

# Function definitions often contain ________ which are considered to be local variables and correspond with the arguments in the function call.

parameters

# In JavaScript, all objects and Arrays are passed to functions by ________.

reference

# Which of the following is not required for counter-controlled repetition?

sentinel

# Which of the following methods does the JavaScript Boolean object not possess?

toInt

# The DOM treats the XML document as

tree-structure

# SAX makes sequence of call to a handler function?

true

# The ContentHandler class provides implementations for the core interface of SAX

true

# XML parser checks for validity and well formed ness?

true

# What would the browser display if this script was executed? <SCRIPT LANGUAGE = "JavaScript"> var c = new Array(8); for( var i = 0; i < 8; i++ ) c[i] = i; document.write(c[8]); </SCRIPT>

undefined


संबंधित स्टडी सेट्स

NBDHE Practice Test MEGA-SET 💪🏻🦷

View Set

Colorado Property ExamFX Chapter 4

View Set

Chapter 9 - Real Estate Contracts

View Set

Semester 1 Final Unit 1-3 AP psyche

View Set

SOLE CH 18 Gastrointestinal Alterations

View Set