查看网站首页
查看网站首页
查看 sitemap.xml
✏️ 正在编辑: text%3d-i.yaml
路径:
/opt/alt/ruby18/share/ri/1.8/system/REXML/Element/text%3d-i.yaml
提示:
您可以编辑任何文件(包括二进制文件),但请注意不当修改可能导致文件损坏。
--- !ruby/object:RI::MethodDescription aliases: [] block_params: comment: - !ruby/struct:SM::Flow::P body: Sets the first Text child of this object. See text() for a discussion about Text children. - !ruby/struct:SM::Flow::P body: If a Text child already exists, the child is replaced by this content. This means that Text content can be deleted by calling this method with a nil argument. In this case, the next Text child becomes the first Text child. In no case is the order of any siblings disturbed. - !ruby/object:SM::Flow::LIST contents: - !ruby/struct:SM::Flow::LI label: "text:" body: If a String, a new Text child is created and added to this Element as the first Text child. If Text, the text is set as the first Child element. If nil, then any existing first Text child is removed. - !ruby/struct:SM::Flow::LI label: "Returns:" body: this Element. type: :NOTE - !ruby/struct:SM::Flow::VERB body: " doc = Document.new '<a><b/></a>'\n doc.root.text = 'Sean' #-> '<a><b/>Sean</a>'\n doc.root.text = 'Elliott' #-> '<a><b/>Elliott</a>'\n doc.root.add_element 'c' #-> '<a><b/>Elliott<c/></a>'\n doc.root.text = 'Russell' #-> '<a><b/>Russell<c/></a>'\n doc.root.text = nil #-> '<a><b/><c/></a>'\n" full_name: REXML::Element#text= is_singleton: false name: text= params: ( text ) visibility: public
💾 保存文件
← 返回文件管理器