Question 1. What Is Xpath?
XPath is an important and core component of XSLT standard. It is used to traverse the elements and attributes in an XML document.
Question 2. What Are The Main Features Of Xpath?
- XPath is a major element in the XSLT standard.
- It is syntax for defining parts of an XML document.
- XPATH stands for XML Path Language.
- It is used for navigating in XML documents.
- It can be used to query data from XML documents.
- It uses path expressions to navigate in XML documents.
- XPATH expressions are case sensitive.
Question 3. What Do You Mean By Xpath Expressions?
XPath defines a pattern or path expression to select nodes or node sets in an XML document. These patterns are used by XSLT to perform transformations. XPath specifies seven types of nodes that can be output of the execution of the XPath expression.
- Processing Instruction
Question 4. What Do You Mean By Xpath Nodes?
A node is an XML document which is specified in the tree structure.
Question 5. How Many Types Of Nodes In Xpath?
There are seven kinds of nodes in XPath:
- Document nodes
Question 6. What Is Xpath Syntax?
The XPath syntax specifies the different nodes, path expressions, path notation, predicates and URLs which are used to define the XML document.
Question 7. What Are The Different Types Of Location Paths In Xpath?
There are two types of location paths used to specify the location of node in XML documents. These paths are absolute or relative path.
Question 8. What Is The Meaning Of Absolute Path In Xpath?
An absolute path starts with root node or with ‘/’.
/company/employee- It will select employee nodes within class root node.
Question 9. What Do You Mean By Xpath Relative Path?
A path is known as relative path if it is started with the node that we’ve selected.
Question 10. What Do You Mean By Xpath Axes?
XPath axes are used to identify elements by their relationship like parent, child, sibling, etc. in the same manner like path defines the location of the node.
Question 11. What Do You Mean By Xpath Operators?
XPath defines operators and functions on nodes. An XPath expression returns either a node-set, a string, a Boolean, or a number.
Question 12. What Are The Different Types Of Operators In Xpath?
XPath operators can be categorized in different category according to their property.
Following are the different types of XPath operators:
- Comparison Operators
- Boolean Operators
- Number Functions/Operators
- String Functions
- Node Functions/Operators
Question 13. What Do You Understand By Xpath Comparison Operator?
XPath comparison operator is used to compare one value to another.
There are different type of comparison operators:
Question 14. What Do You Mean By Xpath Boolean Operatos?
Boolean operators are simple words AND, OR, NOT etc. used to combine or exclude keywords. They connect your search words together to either concise or expand your set of results.
Question 15. What Do You Understand By Xpath Number Operators?
The XPath number operators are used to do mathematical operations on different keywords.
There are five number operators in XPath:
Question 16. What Do You Understand By Xpath Number Functions?
In XPath, number functions are used to fetch the different type of values from the expressions. For example, ceiling value, floor value etc.
There are four types of number functions in XPath:
Question 17. What Do You Know By Xpath String Functions?
The XPath string functions specify some rules which are used to get strings according to your preferences.
Question 18. How To Define Relationship Among Nodes?
There are following types of nodes in XPath. These nodes are related to each other to form a tree like structure.
These nodes are:
Question 19. What Are The Different Standard Functions In Xpath?
XPath has more than 101 build-in functions. These built-in functions are used in Boolean values, string values, numeric values, date and time comparison, sequence manipulation etc.
Question 20. What Are The Different Xpath Axes?
XPath axes are used to set relation of current node with another node.
A list of XPath axes to set relation with other nodes are:
ancestor: It is used to get all ancestor (parent, grandparent etc) of current node.
ancestor-or-self: It is used to get all ancestors (parent, grandparent, etc.) of the current node and also the current node.
attribute: It is used to get all attributes of the current node.
child : It is used to retrieve all children of the current node.
descendant: It is used to get all descendants (children, grandchildren, etc.) of the current node.
namespace: It is used to get all namespace nodes of the current node.
preceding: It is used to get everything in the document that is comes before the start tag of the current node.
Question 21. What Is An Atomic Value In Xpath?
Nodes that has no parent node or child node are called as Atomic values.
Question 22. What Happens About The Presence Of The Top-level Element In Xslt?
- The top-level elements don’t have any effect on the behaviour of XSLT elements.
- The functions that are defined with it also don’t have any affect in the document.
- The top-level elements are not permitted to be used by specifying the xsl:apply templates.
- XSLT process is provided to ignore the top-level elements and ignore some of it if an error occurs.
- XSLT top-element element doesn’t recognize the namespace URI and can be provided using other sources.
C Interview Questions
Oracle Interview Questions
C Interview Questions
Document Type Definition (DTD) Tutorial
Service Oriented Architecture (SOA) Tutorial