This section includes 7 InterviewSolutions, each offering curated multiple-choice questions to sharpen your Current Affairs knowledge and support exam preparation. Choose a topic below to get started.
| 1. |
How You Define E4x? |
|
Answer» E4X stands for ECMAScript(European Computer MANUFACTURES Association) for XML(Extensible Markup Language). We can called as E4X is an programing language extension USED to adds the ECMAScript(like: ActionScript,DMDScript,E4X, JavaScript,JScript) to XML.
Example: VAR p = new XML() E4X stands for ECMAScript(European Computer Manufactures Association) for XML(Extensible Markup Language). We can called as E4X is an programing language extension used to adds the ECMAScript(like: ActionScript,DMDScript,E4X, JavaScript,JScript) to XML. Example: var p = new XML() |
|
| 2. |
How We Say Javascript As Same As Ecmascript? |
|
Answer» Because of some reasons we can say that JavaScript is same as ECMAScript.
Because of some reasons we can say that JavaScript is same as ECMAScript. |
|
| 3. |
What You Understand About Ecma? |
|
Answer» ECMA(The European Computer Manufacturers Association)international was founded in 1961. ECMA is an organization made to standardization of information and Communication Technology(ICT) and Consumer Electronics(CE). We use ECMA standard with
We use E4X to make JavaScript supported with XML. ECMA(The European Computer Manufacturers Association)international was founded in 1961. ECMA is an organization made to standardization of information and Communication Technology(ICT) and Consumer Electronics(CE). We use ECMA standard with We use E4X to make JavaScript supported with XML. |
|
| 4. |
Using E4x How Can We Define Xml Document As A Javascript Object? |
|
Answer» I have given you example to show XML document as JavaScript object.Example:I have you SIMPLE XML document. <MESSAGE> We can store this XML document in a string CALLES as message into an XML object variable vusing JavaScript.var V = new XML(message) or Assign the XML text to the XML object variable directly.var v = new XML()v=<message> Output:Sud I have given you example to show XML document as JavaScript object.Example:I have you simple XML document. <message> We can store this XML document in a string calles as message into an XML object variable vusing JavaScript.var v = new XML(message) or Assign the XML text to the XML object variable directly.var v = new XML()v=<message> Output:Sud |
|
| 5. |
Using E4x How Can We Make Xml Easier To Use? |
|
Answer» E4X makes easier to use JAVASCRIPT to parse and manipulate XML.This is also use to enable XML library or component to act with XML.On different browsers libraries and components perform with different syntax and work differently. I have given you EXAMPLE where I show how to load an existance XML document("message.xml")into XML parser and to show NOTE from message. Example: WITHOUT use of E4X. var xmlDoc//This code is made only for Internet Explorer. E4X makes easier to use JavaScript to parse and manipulate XML.This is also use to enable XML library or component to act with XML.On different browsers libraries and components perform with different syntax and work differently. I have given you example where I show how to load an existance XML document("message.xml")into XML parser and to show note from message. Example: Without use of E4X. var xmlDoc//This code is made only for Internet Explorer. |
|
| 6. |
Tell About Browser Compatibility With E4x? |
|
Answer» E4X support limited browsers.No,mainstream browser has supported by E4X.Mozilla ENGINE(1.8)(beta VERSION) is limited support to E4X.We can SAY that Firebox 1.1 is an first version that support E4X.E4X is also expected to the FUTURE version of INTERNET Explorer.Firefox 1.1: Firefox1.1 can support best for E4X as compare to other browsers. E4X support limited browsers.No,mainstream browser has supported by E4X.Mozilla engine(1.8)(beta version) is limited support to E4X.We can say that Firebox 1.1 is an first version that support E4X.E4X is also expected to the future version of Internet Explorer.Firefox 1.1: Firefox1.1 can support best for E4X as compare to other browsers. |
|
| 7. |
How To Use Of E4x With Xml? |
|
Answer» USING E4X we can EASILY use JAVASCRIPT with an XML. Example:I have written an XML document. <order> We can stroe this XML document as an string in variable order. var order = new XML(txt) or Assign the XML text to the XML object variable directly. var order = new XML() We can also calculate the price like that, var total=order.item.qty * order.item.priceCan we display the customers full name like that, document.write(order.customer.lastname) We can calculate the total price, when the order has many items like that, var price=0for each (i in order.item) Using E4X we can easily use JAvAScript with an XML. Example:I have written an XML document. <order> We can stroe this XML document as an string in variable order. var order = new XML(txt) or Assign the XML text to the XML object variable directly. var order = new XML() We can also calculate the price like that, var total=order.item.qty * order.item.priceCan we display the customers full name like that, document.write(order.customer.lastname) We can calculate the total price, when the order has many items like that, var price=0for each (i in order.item) |
|
| 8. |
Which Of The Following Options Would Be Returned By The Code Shown In The Code Snippet: Var F = <foo> <a> Text </a> <a> <b/> </a> </foo>; Alert(f.a[0].hascomplexcontent());// P Alert(f.a[1].hascomplexcontent());//q Alert(f.a[0].hassimplecontent());//r Alert(f.a[1].hassimplecontent());//s |
|
Answer» p-1,q-0,r-0,s-1 p-1,q-0,r-0,s-1 |
|
| 9. |
What Will Be The Output Of The Following Code Snippet? Var Customer = <customer> <phone Type="mobile">888-555-1212</phone> <phone Type="office">888-555-2121</phone> <preferred>mobile</preferred> </customer>; Alert(customer.childindex()); |
|
Answer» 0 0 |
|
| 10. |
Which Of The Following Is Not A Reserved Keyword In E4x And Javascript? |
|
Answer» super super |
|
| 11. |
Which Of The Following Is Not A Valid Built-in Method For Xmllist Objects In E4x? |
|
Answer» hasOwnProperty(PROPERTYNAME) hasOwnProperty(propertyName) |
|
| 12. |
What Is The Correct Way To Add A Method To An Xml.prototype In E4x? |
|
Answer» XML.prototype.method::[methodNameString] XML.prototype.method::[methodNameString] |
|
| 13. |
Which Of The Following Methods Would Give The Output Corresponding To The Code Snippet? Var Test = <type Name="joe"> <base Name="bob"></base> Example </type>; Output: <type Name="joe"> <base Name="bob"/> Example </type> |
|
Answer» ALERT(test.toXMLString()); , alert(test.elements()); alert(test.toXMLString()); , alert(test.elements()); |
|
| 14. |
Which Of The Following Are Not Global Methods And Properties In E4x? |
|
Answer» setNamespace() setNamespace() |
|
| 15. |
State Whether True Or False: The Qname.prototype.tostring() Method Throws A Typeerror Exception If Its Value Is Not A Qname Object? |
|
Answer» True True |
|
| 16. |
Which Of The Following Public Methods In E4x Has The Return Type Xml? |
|
Answer» PARENT() parent() |
|
| 17. |
Which Of The Following Is Not True Of The Namespace Constructor In E4x? |
|
Answer» If the value is a VALID XML name, the PREFIX property is SET to a string. If the value is a valid XML name, the prefix property is set to a string. |
|
| 18. |
Consider The Following Code Snippet. Which Of The Given Options Would Be Used In E4x To Change The Color Of The Descendant Node Chair? Var Element = <home> <room> <furniture> <chair Color="brown"/> <furniture> </room> </home> |
|
Answer» element.chair.color="LIGHT BROWN" element.chair.color="light brown" |
|
| 19. |
What Will Be The Output Of The Following Code Snippet? Element = <xhtml:p Xmlns:xhtml="http://www.example.org">kibology For All.</xhtml:p>; Elementname = Element.name(); Alert(elementname.localname); //1 Alert(elementname.uri); // 2 |
|
Answer» 1-p,2-http://www.example.org 1-p,2-http://www.example.org |
|
| 20. |
Which Of The Given Options Represents The Correct Length When Alert(emp..*.length()); Is Applied To The Following Code? Var Emp = <emp> <name>mark</name> <likes> <os>linux</os> <browser>firefox</browser> <language>javascript</language> <language>python</language> </likes> </emp> |
|
Answer» 12 12 |
|
| 21. |
Which Of The Following Operators Is Used For Inserting Xml Objects In The Context Of Their Parent In E4x? |
|
Answer» += += |
|
| 22. |
Which Of The Following Is The Correct Syntax For Calling The Namespace Constructor As A Function In E4x? |
|
Answer» NAMESPACE(), Namespace(uriValue). Namespace(), Namespace(uriValue). |
|
| 23. |
Which Of The Following Options Can Be Used For Adding Direct Support For Xml To Javascript? |
|
Answer» let. let. |
|
| 24. |
Which Of The Following Methods Is Not One Of The Global Methods And Properties In E4x? |
|
Answer» isScopeNamespaces(), removeNamespaces(). isScopeNamespaces(), removeNamespaces(). |
|
| 25. |
Which Of The Following Characters Are Treated As White Space Characters? |
|
Answer» Line feed, Tab. |
|
| 26. |
State Whether True Or False: An Arbitrary Xml File Can Be Loaded As An E4x Ready Object? |
|
Answer» True. True. |
|
| 27. |
Which Of The Following Is The Correct Way To Create An Xml Object In E4x? |
|
Answer» VAR LANGUAGES XML = NEW XML('JavaScriptPython'); var languages XML = new XML('JavaScriptPython'); |
|
| 28. |
Which Of The Following Options Can Be Used To Delete A Child Node Of An Xml Object In E4x? |
|
Answer» delete xmlobject.@attribute; |
|
| 29. |
What Is The Value Returned When The Input Parameter Type Of The Xmllist() Function In E4x Is Number? |
|
Answer» The VALUE is FIRST CONVERTED to a STRING and then converted to an XMLList object. The value is first converted to a string and then converted to an XMLList object. |
|