590件ヒット
[501-590件を表示]
(0.156秒)
ライブラリ
- ビルトイン (190)
-
fiddle
/ import (77) -
json
/ add / ostruct (11) - mkmf (22)
- openssl (22)
- ostruct (147)
- rake (11)
-
rexml
/ document (33) -
rexml
/ parsers / pullparser (11) -
rexml
/ sax2listener (11) - socket (55)
クラス
- Addrinfo (22)
- Array (19)
-
Fiddle
:: CStruct (11) -
OpenSSL
:: ASN1 :: Constructive (22) - OpenStruct (158)
-
REXML
:: Instruction (33) -
REXML
:: Parsers :: PullEvent (11) -
Rake
:: Application (11) -
RubyVM
:: InstructionSequence (44) -
Socket
:: Option (33) - String (11)
- Struct (110)
- TracePoint (6)
モジュール
-
Fiddle
:: Importer (66) - Kernel (22)
-
REXML
:: SAX2Listener (11)
キーワード
- == (22)
- [] (22)
-
absolute
_ path (11) - content (11)
-
create
_ value (11) - data (11)
-
delete
_ field (11) - dig (9)
- each (11)
-
each
_ pair (44) - eql? (22)
-
first
_ lineno (11) - hash (22)
-
have
_ struct _ member (22) - inspect (33)
- instruction? (11)
-
instruction
_ sequence (6) - linger (11)
- members (11)
- modifiable (11)
-
new
_ ostruct _ member (11) -
node
_ type (11) - pack (19)
- path (11)
-
processing
_ instruction (11) - sizeof (11)
- tagging (11)
- target (11)
-
to
_ h (17) -
to
_ json (11) -
to
_ ptr (11) -
to
_ s (44) -
to
_ sockaddr (11) - typealias (11)
- union (11)
- unpack (11)
- value (11)
-
values
_ at (11)
検索結果
先頭5件
-
Fiddle
:: Importer # union(signature) -> Class (3107.0) -
C の共用体型に対応する Ruby のクラスを構築して返します。
...ddle::Importer#struct と
ほぼ同様です。C における
typedef union epoll_data
{
void *ptr;
int fd;
uint32_t u32;
uint64_t u64;
} epoll_data_t;
は、Ruby上では
require 'fiddle/import'
module M
extend Fiddle::Importer
dlload "libc.so.6"
typealias("......uint32_t", "unsigned int")
typealias("uint64_t", "unsigned long long")
EPollData = union(["void *ptr",
"int fd",
"uint32_t u32",
"uint64_t u64",
])
end
となります。
返されるクラスは......Fiddle::CUnion を継承しています。
1.9.x ではこのメソッドで返されるクラスは正しく動作しません。
2.0以降では修正されています。
@param signature 共用体の各要素を文字列で表現したものの配列... -
REXML
:: Instruction # content -> String | nil (3107.0) -
XML 処理命令の内容を返します。
...ersion="1.0" encoding="utf-8" ?>
<?xml-stylesheet type="text/css" href="style.css"?>
<?foobar?>
<root />
EOS
doc[2] # => <?p-i xml-stylesheet ...?>
doc[2].target # => "xml-stylesheet"
doc[2].content # => "type=\"text/css\" href=\"style.css\""
doc[4].target # => "foobar"
doc[4].content # => nil
//}... -
REXML
:: Instruction # target -> String (3107.0) -
XML 処理命令のターゲットを返します。
...quire 'rexml/document'
doc = REXML::Document.new(<<EOS)
<?xml version="1.0" encoding="utf-8" ?>
<?xml-stylesheet type="text/css" href="style.css"?>
<root />
EOS
doc[2] # => <?p-i xml-stylesheet ...?>
doc[2].target # => "xml-stylesheet"
doc[2].content # => "type=\"text/css\" href=\"style.css\""
//}... -
RubyVM
:: InstructionSequence # first _ lineno -> Integer (3107.0) -
self が表す命令シーケンスの 1 行目の行番号を返します。
...の 1 行目の行番号を返します。
例1:irb で実行した場合
RubyVM::InstructionSequence.compile('num = 1 + 2').first_lineno
# => 1
例2:
# /tmp/method.rb
require "foo-library"
def foo
p :foo
end
RubyVM::InstructionSequence.of(method(:foo)).first_lineno
# => 2... -
Socket
:: Option # data -> String (3107.0) -
オプションのデータ(内容)を文字列で返します。
...のデータ(内容)を文字列で返します。
内容が整数や真偽値、もしくは struct linger であることがわかっている場合には、
Socket::Option#int, Socket::Option#bool, Socket::Option#linger
を用いて
to_s は過去との互換性のために存在します。... -
Socket
:: Option # linger -> [bool , Integer] (3107.0) -
オプションが SOL_SOCKET/SO_LINGER である場合に、 オプションのデータ(内容)を真偽値と整数のペアとして返します。
...ションのデータ(内容)を真偽値と整数のペアとして返します。
@raise TypeError dataのバイト数が不適切である(sizeof(struct linger)と異なる)場合や、
level/optname が SOL_SOCKET/SO_LINGER でないに発生します
@see Socket::Option#data... -
Socket
:: Option # to _ s -> String (3107.0) -
オプションのデータ(内容)を文字列で返します。
...のデータ(内容)を文字列で返します。
内容が整数や真偽値、もしくは struct linger であることがわかっている場合には、
Socket::Option#int, Socket::Option#bool, Socket::Option#linger
を用いて
to_s は過去との互換性のために存在します。... -
Addrinfo
# to _ s -> String (123.0) -
struct sockaddr をパックした形式の文字列に変換します。
...
struct sockaddr をパックした形式の文字列に変換します。
require 'socket'
Addrinfo.tcp("localhost", 80).to_sockaddr
#=> "\x02\x00\x00P\x7F\x00\x00\x01\x00\x00\x00\x00\x00\x00\x00\x00"... -
Addrinfo
# to _ sockaddr -> String (123.0) -
struct sockaddr をパックした形式の文字列に変換します。
...
struct sockaddr をパックした形式の文字列に変換します。
require 'socket'
Addrinfo.tcp("localhost", 80).to_sockaddr
#=> "\x02\x00\x00P\x7F\x00\x00\x01\x00\x00\x00\x00\x00\x00\x00\x00"...