Ruby 2.1.0 リファレンスマニュアル > ライブラリ一覧 > rexml/documentライブラリ > REXML::Attributesクラス
クラス・モジュールの継承リスト: REXML::Attributes < Hash < Enumerable < Object < Kernel < BasicObject
属性の集合を表すクラスです。
REXML::Element#attributes はこのクラスのオブジェクトを返します。各属性には REXML::Attributes#[] でアクセスします。
定義 | 説明 | |
---|---|---|
new(element) -> REXML::Attributes
|
空の Attributes オブジェクトを生成します。 |
定義 | 説明 | |
---|---|---|
add(attribute) -> ()
|
属性を追加/更新します。 |
|
self[name] -> String | nil
|
属性名nameの属性値を返します。 |
|
self[name] = value
|
指定した属性を更新します。 |
|
delete(attribute) -> REXML::Element
|
指定した属性を取り除きます。 |
|
delete_all(name) -> [REXML::Attribute]
|
name という名前を持つ属性をすべて削除します。 |
|
each {|name, value| ... } -> ()
|
各属性の名前と値に対しブロックを呼び出します。 |
|
each_attribute {|attribute| ... } -> ()
|
各属性に対しブロックを呼び出します。 |
|
get_attribute(name) -> Attribute | nil
|
name という名前の属性を取得します。 |
|
get_attribute_ns(namespace, name) -> REXML::Attribute | nil
|
namespace と name で特定される属性を返します。 |
|
length -> Integer
|
属性の個数を返します。 |
|
namespaces -> { String => String }
|
self の中で宣言されている名前空間の集合を返します。 |
|
prefixes -> [String]
|
self の中で宣言されている prefix の集合を文字列の配列で返します。 |
|
to_a -> [Attribute]
|
属性の配列を返します。 |
!
!=
__id__
__send__
instance_eval
instance_exec
method_missing
singleton_method_added
singleton_method_removed
singleton_method_undefined
all?
any?
chunk
chunk_while
collect
collect_concat
count
cycle
detect
drop
drop_while
each_cons
each_entry
each_slice
each_with_index
each_with_object
entries
find_all
find_index
first
grep
grep_v
group_by
include?
inject
lazy
max
max_by
min
min_by
minmax
minmax_by
none?
one?
partition
reject
reverse_each
slice_after
slice_before
slice_when
sort
sort_by
sum
take
take_while
to_h
to_set
uniq
zip
==
[]=
assoc
clear
clone
compare_by_identity
compare_by_identity?
default
default=
default_proc
default_proc=
delete_if
each
each_key
each_value
empty?
equal?
fetch
flatten
has_key?
has_value?
hash
index
inspect
invert
keep_if
keys
merge
merge!
rassoc
rehash
replace
shift
to_hash
values
values_at
.[]
.try_convert
!~
<=>
=~
_dump
class
define_singleton_method
display
enum_for
extend
freeze
frozen?
initialize
initialize_copy
instance_of?
instance_variable_defined?
instance_variable_get
instance_variable_set
instance_variables
is_a?
itself
marshal_dump
marshal_load
method
methods
must_be
must_be_close_to
must_be_empty
must_be_instance_of
must_be_kind_of
must_be_nil
must_be_same_as
must_be_within_epsilon
must_equal
must_include
must_match
must_raise
must_respond_to
must_send
must_throw
nil?
object_id
pretty_inspect
pretty_print
pretty_print_cycle
pretty_print_inspect
pretty_print_instance_variables
private_methods
protected_methods
psych_to_yaml
public_method
public_methods
public_send
remove_instance_variable
respond_to?
respond_to_missing?
send
singleton_class
singleton_method
singleton_methods
taint
tainted?
tap
to_ary
to_int
to_io
to_proc
to_regexp
to_str
trust
untaint
untrust
untrusted?
.yaml_tag
::ARGF
::ARGV
::DATA
::ENV
::FALSE
::NIL
::RUBY_COPYRIGHT
::RUBY_DESCRIPTION
::RUBY_ENGINE
::RUBY_PATCHLEVEL
::RUBY_PLATFORM
::RUBY_RELEASE_DATE
::RUBY_REVISION
::RUBY_VERSION
::SCRIPT_LINES__
::STDERR
::STDIN
::STDOUT
::TOPLEVEL_BINDING
::TRUE