るりまサーチ (Ruby 2.3.0)

最速Rubyリファレンスマニュアル検索!
10件ヒット [1-10件を表示] (0.177秒)

別のキーワード

  1. rexml/document new
  2. rexml/document write
  3. rexml/document clone
  4. rexml/document to_s
  5. rexml/document node_type

ライブラリ

クラス

キーワード

検索結果

REXML::XMLDecl#standalone -> String | nil (69304.0)

スタンドアロン文書であるかどうかを "yes" "no" で 返します。

スタンドアロン文書であるかどうかを "yes" "no" で
返します。

nil(省略)を返す場合もあります。

REXML::XMLDecl#standalone=(value) (42304.0)

スタンドアロン文書であるかどうかを "yes" "no" で設定します。

スタンドアロン文書であるかどうかを "yes" "no" で設定します。

この属性を省略したい場合は nil を指定します。

@param value 設定値(文字列)

REXML::XMLDecl#xmldecl(version, encoding, standalone) -> () (24322.0)

内容を更新します。

内容を更新します。

@param version バージョン(文字列)
@param encoding エンコーディング(文字列 or nil)
@param standalone スタンドアロン文章かどうか("yes", "no", nil)

REXML::XMLDecl.new(version = REXML::XMLDecl::DEFAULT_VERSION, encoding = nil, standalone = nil) (24322.0)

新たな XMLDecl オブジェクトを生成して返します。

新たな XMLDecl オブジェクトを生成して返します。

version 以外は省略可能です。

@param version バージョン(文字列)
@param encoding エンコーディング(文字列 or nil)
@param standalone スタンドアロン文章かどうか("yes", "no", nil)

REXML::XMLDecl (24127.0)

XML 宣言を表すクラス。

XML 宣言を表すクラス。

文書から XML 宣言を取り出すには REXML::Document#xml_decl を使います。

//emlist[][ruby]{
require 'rexml/document'
doc = REXML::Document.new(<<EOS)
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<e />
EOS

xml_decl = doc.xml_decl
xml_decl.version # => "1.0"
xml_decl.encoding # => "UTF-8"
xml_de...

絞り込み条件を変える

REXML::Document#stand_alone? -> String (24085.0)

XML 宣言の standalone の値を文字列で返します。

XML 宣言の standalone の値を文字列で返します。

//emlist[][ruby]{
require 'rexml/document'
doc = REXML::Document.new(<<EOS)
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<e />
EOS
doc.stand_alone? # => "yes"
//}

REXML::Document#encoding -> String (24037.0)

XML 宣言に含まれている XML 文書のエンコーディングを返します。

XML 宣言に含まれている XML 文書のエンコーディングを返します。

文書が XML 宣言を持たない場合はデフォルトの値
(REXML::XMLDecl.defaultで宣言されているもの)を返します。

//emlist[][ruby]{
require 'rexml/document'
doc = REXML::Document.new(<<EOS)
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<e />
EOS
doc.encoding # => "UTF-8"
//}

REXML::Document#version -> String (24037.0)

XML 宣言に含まれている XML 文書のバージョンを返します。

XML 宣言に含まれている XML 文書のバージョンを返します。

文書が XML 宣言を持たない場合はデフォルトの値
(REXML::XMLDecl.defaultで宣言されているもの)を返します。

//emlist[][ruby]{
require 'rexml/document'
doc = REXML::Document.new(<<EOS)
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<e />
EOS
doc.version # => "1.0"
//}

REXML::XMLDecl#==(other) -> bool (24019.0)

self と other が同じであるならば真を返します。

self と other が同じであるならば真を返します。

「同じ」とは REXML::XMLDecl#version, REXML::XMLDecl#encoding,
REXML::XMLDecl#standalone が一致していることを意味します。

@param other 比較対象のオブジェクト

REXML::XMLDecl#stand_alone? -> String | nil (24004.0)

スタンドアロン文書であるかどうかを "yes" "no" で 返します。

スタンドアロン文書であるかどうかを "yes" "no" で
返します。

nil(省略)を返す場合もあります。

絞り込み条件を変える