নোডের প্রত্যক্ষ বা পরোক্ষ সন্তান যে সমস্ত নোডের পাঠ্য মান পায়, সেগুলি নথিতে প্রদর্শিত ক্রমে।
বিস্তারিত ডকুমেন্টেশন
as Cdata()
স্বয়ংসম্পূর্ণের উদ্দেশ্যে নোডটিকে CDATASection নোড হিসাবে কাস্ট করে। যদি নোডের Content Type ইতিমধ্যে CDATA না থাকে, তাহলে এই পদ্ধতিটি null প্রদান করে।
স্বয়ংসম্পূর্ণের উদ্দেশ্যে নোডটিকে একটি Comment নোড হিসাবে কাস্ট করে। যদি নোডের Content Type ইতিমধ্যেই COMMENT না থাকে, তাহলে এই পদ্ধতিটি null প্রদান করে।
প্রত্যাবর্তন
Comment — Comment নোড, বা null যদি নোডের বিষয়বস্তুর ধরনটি COMMENT না হয়
as Doc Type()
স্বয়ংসম্পূর্ণের উদ্দেশ্যে নোডটিকে একটি Document Type নোড হিসাবে কাস্ট করে৷ যদি নোডের Content Type ইতিমধ্যে DOCTYPE না থাকে, তাহলে এই পদ্ধতিটি null প্রদান করে।
স্বয়ংসম্পূর্ণের উদ্দেশ্যে নোডটিকে একটি Element নোড হিসাবে কাস্ট করে। যদি নোডের Content Type ইতিমধ্যে ELEMENT না থাকে, তাহলে এই পদ্ধতিটি null প্রদান করে।
স্বয়ংসম্পূর্ণের উদ্দেশ্যে নোডটিকে Entity Reference নোড হিসাবে কাস্ট করে। যদি নোডের Content Type ইতিমধ্যে ENTITYREF না হয়, তাহলে এই পদ্ধতিটি null প্রদান করে।
স্বয়ংসম্পূর্ণের উদ্দেশ্যে নোডটিকে একটি Processing Instruction নোড হিসাবে কাস্ট করে। যদি নোডের Content Type ইতিমধ্যেই PROCESSINGINSTRUCTION না থাকে, তাহলে এই পদ্ধতিটি null প্রদান করে।
[[["সহজে বোঝা যায়","easyToUnderstand","thumb-up"],["আমার সমস্যার সমাধান হয়েছে","solvedMyProblem","thumb-up"],["অন্যান্য","otherUp","thumb-up"]],[["এতে আমার প্রয়োজনীয় তথ্য নেই","missingTheInformationINeed","thumb-down"],["খুব জটিল / অনেক ধাপ","tooComplicatedTooManySteps","thumb-down"],["পুরনো","outOfDate","thumb-down"],["অনুবাদ সংক্রান্ত সমস্যা","translationIssue","thumb-down"],["নমুনা / কোড সংক্রান্ত সমস্যা","samplesCodeIssue","thumb-down"],["অন্যান্য","otherDown","thumb-down"]],["2025-07-24 UTC-তে শেষবার আপডেট করা হয়েছে।"],[[["\u003cp\u003e\u003ccode\u003eContent\u003c/code\u003e is a generic representation of an XML node in Google Apps Script and provides methods to interact with it.\u003c/p\u003e\n"],["\u003cp\u003eIt offers various methods to cast the node into specific types like \u003ccode\u003eElement\u003c/code\u003e, \u003ccode\u003eText\u003c/code\u003e, \u003ccode\u003eComment\u003c/code\u003e, etc., for easier manipulation.\u003c/p\u003e\n"],["\u003cp\u003eYou can detach a node from its parent, get its parent element, or retrieve its content type using dedicated methods.\u003c/p\u003e\n"],["\u003cp\u003e\u003ccode\u003egetValue()\u003c/code\u003e helps retrieve the combined text value of all the node's children, providing a way to access its content.\u003c/p\u003e\n"],["\u003cp\u003eImplementing classes include \u003ccode\u003eCdata\u003c/code\u003e, \u003ccode\u003eComment\u003c/code\u003e, \u003ccode\u003eDocType\u003c/code\u003e, \u003ccode\u003eElement\u003c/code\u003e, \u003ccode\u003eEntityRef\u003c/code\u003e, \u003ccode\u003eProcessingInstruction\u003c/code\u003e, and \u003ccode\u003eText\u003c/code\u003e, representing different XML node types.\u003c/p\u003e\n"]]],["This content details a generic XML node and its interactions. It outlines seven specific XML node types: Cdata, Comment, DocType, Element, EntityRef, ProcessingInstruction, and Text. Key actions include casting a node to a specific type using `asType()` methods, which return `null` if the type is incorrect. Other actions involve `detach()` to remove a node from its parent, `getParentElement()` to find the parent, `getType()` to retrieve the content type, and `getValue()` to get the combined text value of child nodes.\n"],null,["# Interface Content\n\nContent\n\nA representation of a generic XML node.\n\n### Implementing classes\n\n| Name | Brief description |\n|------------------------------------------------------------------------------------|------------------------------------------------------------|\n| [Cdata](/apps-script/reference/xml-service/cdata) | A representation of an XML `CDATASection` node. |\n| [Comment](/apps-script/reference/xml-service/comment) | A representation of an XML `Comment` node. |\n| [DocType](/apps-script/reference/xml-service/doc-type) | A representation of an XML `Document``Type` node. |\n| [Element](/apps-script/reference/xml-service/element) | A representation of an XML `Element` node. |\n| [EntityRef](/apps-script/reference/xml-service/entity-ref) | A representation of an XML `Entity``Reference` node. |\n| [ProcessingInstruction](/apps-script/reference/xml-service/processing-instruction) | A representation of an XML `Processing``Instruction` node. |\n| [Text](/apps-script/reference/xml-service/text) | A representation of an XML `Text` node. |\n\n### Methods\n\n| Method | Return type | Brief description |\n|---------------------------------------------------------|------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------|\n| [asCdata()](#asCdata()) | [Cdata](/apps-script/reference/xml-service/cdata) | Casts the node as a [CDATASection](/apps-script/reference/xml-service/cdata) node for the purposes of autocomplete. |\n| [asComment()](#asComment()) | [Comment](/apps-script/reference/xml-service/comment) | Casts the node as a [Comment](/apps-script/reference/xml-service/comment) node for the purposes of autocomplete. |\n| [asDocType()](#asDocType()) | [DocType](/apps-script/reference/xml-service/doc-type) | Casts the node as a [DocumentType](/apps-script/reference/xml-service/doc-type) node for the purposes of autocomplete. |\n| [asElement()](#asElement()) | [Element](/apps-script/reference/xml-service/element) | Casts the node as an [Element](/apps-script/reference/xml-service/element) node for the purposes of autocomplete. |\n| [asEntityRef()](#asEntityRef()) | [EntityRef](/apps-script/reference/xml-service/entity-ref) | Casts the node as a [EntityReference](/apps-script/reference/xml-service/entity-ref) node for the purposes of autocomplete. |\n| [asProcessingInstruction()](#asProcessingInstruction()) | [ProcessingInstruction](/apps-script/reference/xml-service/processing-instruction) | Casts the node as a [ProcessingInstruction](/apps-script/reference/xml-service/processing-instruction) node for the purposes of autocomplete. |\n| [asText()](#asText()) | [Text](/apps-script/reference/xml-service/text) | Casts the node as a [Text](/apps-script/reference/xml-service/text) node for the purposes of autocomplete. |\n| [detach()](#detach()) | [Content](#) | Detaches the node from its parent [Element](/apps-script/reference/xml-service/element) node. |\n| [getParentElement()](#getParentElement()) | [Element](/apps-script/reference/xml-service/element) | Gets the node's parent [Element](/apps-script/reference/xml-service/element) node. |\n| [getType()](#getType()) | [ContentType](/apps-script/reference/xml-service/content-type) | Gets the node's content type. |\n| [getValue()](#getValue()) | `String` | Gets the text value of all nodes that are direct or indirect children of the node, in the order they appear in the document. |\n\nDetailed documentation\n----------------------\n\n### `as``Cdata()`\n\nCasts the node as a [CDATASection](/apps-script/reference/xml-service/cdata) node for the purposes of autocomplete. If the\nnode's [ContentType](/apps-script/reference/xml-service/content-type) is not already `CDATA`, this method returns `null`.\n\n#### Return\n\n\n[Cdata](/apps-script/reference/xml-service/cdata) --- the `CDATASection` node\n\n*** ** * ** ***\n\n### `as``Comment()`\n\nCasts the node as a [Comment](/apps-script/reference/xml-service/comment) node for the purposes of autocomplete. If the node's\n[ContentType](/apps-script/reference/xml-service/content-type) is not already `COMMENT`, this method returns `null`.\n\n#### Return\n\n\n[Comment](/apps-script/reference/xml-service/comment) --- the `Comment` node, or `null` if the node's content type is not [COMMENT](/apps-script/reference/xml-service/content-type)\n\n*** ** * ** ***\n\n### `as``Doc``Type()`\n\nCasts the node as a [DocumentType](/apps-script/reference/xml-service/doc-type) node for the purposes of autocomplete. If\nthe node's [ContentType](/apps-script/reference/xml-service/content-type) is not already `DOCTYPE`, this method returns `null`.\n\n#### Return\n\n\n[DocType](/apps-script/reference/xml-service/doc-type) --- the `Document``Type` node\n\n*** ** * ** ***\n\n### `as``Element()`\n\nCasts the node as an [Element](/apps-script/reference/xml-service/element) node for the purposes of autocomplete. If the node's\n[ContentType](/apps-script/reference/xml-service/content-type) is not already `ELEMENT`, this method returns `null`.\n\n#### Return\n\n\n[Element](/apps-script/reference/xml-service/element) --- the `Element` node\n\n*** ** * ** ***\n\n### `as``Entity``Ref()`\n\nCasts the node as a [EntityReference](/apps-script/reference/xml-service/entity-ref) node for the purposes of autocomplete.\nIf the node's [ContentType](/apps-script/reference/xml-service/content-type) is not already `ENTITYREF`, this method returns\n`null`.\n\n#### Return\n\n\n[EntityRef](/apps-script/reference/xml-service/entity-ref) --- the `Entity``Reference` node\n\n*** ** * ** ***\n\n### `as``Processing``Instruction()`\n\nCasts the node as a [ProcessingInstruction](/apps-script/reference/xml-service/processing-instruction) node for the purposes of autocomplete. If\nthe node's [ContentType](/apps-script/reference/xml-service/content-type) is not already `PROCESSINGINSTRUCTION`, this method\nreturns `null`.\n\n#### Return\n\n\n[ProcessingInstruction](/apps-script/reference/xml-service/processing-instruction) --- the `Processing``Instruction` node\n\n*** ** * ** ***\n\n### `as``Text()`\n\nCasts the node as a [Text](/apps-script/reference/xml-service/text) node for the purposes of autocomplete. If the node's [ContentType](/apps-script/reference/xml-service/content-type) is not already `TEXT`, this method returns `null`.\n\n#### Return\n\n\n[Text](/apps-script/reference/xml-service/text) --- the `Text` node\n\n*** ** * ** ***\n\n### `detach()`\n\nDetaches the node from its parent [Element](/apps-script/reference/xml-service/element) node. If the node does not have a parent,\nthis method has no effect.\n\n#### Return\n\n\n[Content](#) --- the detached node\n\n*** ** * ** ***\n\n### `get``Parent``Element()`\n\nGets the node's parent [Element](/apps-script/reference/xml-service/element) node. If the node does not have a parent, this method\nreturns `null`.\n\n#### Return\n\n\n[Element](/apps-script/reference/xml-service/element) --- the parent `Element` node\n\n*** ** * ** ***\n\n### `get``Type()`\n\nGets the node's content type.\n\n#### Return\n\n\n[ContentType](/apps-script/reference/xml-service/content-type) --- the node's content type\n\n*** ** * ** ***\n\n### `get``Value()`\n\nGets the text value of all nodes that are direct or indirect children of the node, in the order\nthey appear in the document.\n\n#### Return\n\n\n`String` --- the text value of all nodes that are direct or indirect children of the node"]]