るりまサーチ (Ruby 2.2.0)

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

別のキーワード

  1. socket int
  2. prime int_from_prime_division
  3. _builtin to_int
  4. mkmf convertible_int
  5. option int

モジュール

キーワード

検索結果

<< 1 2 3 ... > >>

Socket::AncillaryData#int -> Integer (54682.0)

自身が保持している cmsg data (データ) を整数の形で返します。

...異なります。

require 'socket'

ancdata = Socket::AncillaryData.int(:UNIX, :SOCKET, :RIGHTS, STDERR.fileno)
p ancdata.int #=> 2

@raise TypeError cmgs data のサイズが int のバイト数と異なる場合に発生します
@see Socket::AncillaryData.new Socket::AncillaryData.int...

Socket::AncillaryData.int(family, cmsg_level, cmsg_type, integer) -> Socket::AncillaryData (54628.0)

データとして整数を保持する Socket::AncillaryData オブジェクトを生成します。

...持する
Socket
::AncillaryData オブジェクトを生成します。

整数データのサイズおよびエンディアンは実行するホストによって異なります。

require 'socket'

p Socket::AncillaryData.int(:UNIX, :SOCKET, :RIGHTS, STDERR.fileno)
#=> #<Socket::AncillaryDa...
...ta: UNIX SOCKET RIGHTS 2>

@param family ソケットファミリー
@param cmsg_level プロトコル
@param cmsg_type 補助データの種類
@param integer データ内容

@see Socket::AncillaryData.new...

Socket::Option#int -> Integer (54628.0)

オプションのデータ(内容)を整数に変換して返します。

...オプションのデータ(内容)を整数に変換して返します。

@raise TypeError dataのバイト数が不適切である(sizeof(int)と異なる)場合に発生します
@see Socket::Option#data...

Socket::Option.int(family, level, optname, integer) -> Socket::Option (54610.0)

整数をデータとして持つ Socket::Option オブジェクト新たに生成し返します。

...整数をデータとして持つ Socket::Option オブジェクト新たに生成し返します。

family, level, optname には Socket::SOL_SOCKET のような整数の他、
文字列("SOL_SOCKET", "SOCKET")、シンボル(:SOL_SOCKET, :SOCKET)を
指定することができます。

@param f...

Socket::Constants::IFF_POINTOPOINT (36607.0)

point-to-point link

point-to-point link

絞り込み条件を変える

Socket::IFF_POINTOPOINT (36607.0)

point-to-point link

point-to-point link

Socket::Constants::EAI_BADHINTS -> Integer (18607.0)

Invalid value for hints

...Invalid value for hints

getaddrinfo(3), getnameinfo(3) などの
エラーコードです。
対応する Socket.getaddrinfo, Addrinfo.getaddrinfo などは
エラーを SocketError に変換するため、この定数は直接は利用しません。...

Socket::Constants::IP_MINTTL -> Integer (18607.0)

Minimum TTL allowed for received packets。 BasicSocket#getsockopt, BasicSocket#setsockopt の第2引数(optname)に使用します。

...Minimum TTL allowed for received packets。
BasicSocket#getsockopt, BasicSocket#setsockopt
の第2引数(optname)に使用します。

@see Socket::Constants::IPPROTO_IP, ip(4freebsd)...

Socket::Constants::SCM_BINTIME -> Integer (18607.0)

Timestamp (bintime).

...Timestamp (bintime).

Socket
::AncillaryData の type として利用します。

@see Socket::AncillaryData, Socket::AncillaryData#timestamp
BasicSocket#sendmsg, BasicSocket#recvmsg...

Socket::Constants::SOPRI_INTERACTIVE -> Integer (18607.0)

@todo Interactive socket priority

...@todo
Interactive socket priority...

絞り込み条件を変える

Socket::Constants::SO_BINTIME -> Integer (18607.0)

Timestamp (bintime)。 BasicSocket#getsockopt, BasicSocket#setsockopt の第2引数(optname)に使用します。

...Timestamp (bintime)。
BasicSocket#getsockopt, BasicSocket#setsockopt
の第2引数(optname)に使用します。

@see getsockopt(2freebsd), Socket::Constants::SOL_SOCKET
Socket
::Constants::SO_TIMESTAMP,
Socket
::AncillaryData#timestamp...

Socket::Constants::TCP_KEEPINTVL -> Integer (18607.0)

Time between keepalive probes。 BasicSocket#getsockopt, BasicSocket#setsockopt の第2引数(optname)に使用します。

...Time between keepalive probes。
BasicSocket#getsockopt, BasicSocket#setsockopt
の第2引数(optname)に使用します。

@see tcp(7linux)...

Socket::EAI_BADHINTS -> Integer (18607.0)

Invalid value for hints

...Invalid value for hints

getaddrinfo(3), getnameinfo(3) などの
エラーコードです。
対応する Socket.getaddrinfo, Addrinfo.getaddrinfo などは
エラーを SocketError に変換するため、この定数は直接は利用しません。...

Socket::IP_MINTTL -> Integer (18607.0)

Minimum TTL allowed for received packets。 BasicSocket#getsockopt, BasicSocket#setsockopt の第2引数(optname)に使用します。

...Minimum TTL allowed for received packets。
BasicSocket#getsockopt, BasicSocket#setsockopt
の第2引数(optname)に使用します。

@see Socket::Constants::IPPROTO_IP, ip(4freebsd)...

Socket::SCM_BINTIME -> Integer (18607.0)

Timestamp (bintime).

...Timestamp (bintime).

Socket
::AncillaryData の type として利用します。

@see Socket::AncillaryData, Socket::AncillaryData#timestamp
BasicSocket#sendmsg, BasicSocket#recvmsg...

絞り込み条件を変える

Socket::SOPRI_INTERACTIVE -> Integer (18607.0)

@todo Interactive socket priority

...@todo
Interactive socket priority...

Socket::SO_BINTIME -> Integer (18607.0)

Timestamp (bintime)。 BasicSocket#getsockopt, BasicSocket#setsockopt の第2引数(optname)に使用します。

...Timestamp (bintime)。
BasicSocket#getsockopt, BasicSocket#setsockopt
の第2引数(optname)に使用します。

@see getsockopt(2freebsd), Socket::Constants::SOL_SOCKET
Socket
::Constants::SO_TIMESTAMP,
Socket
::AncillaryData#timestamp...

Socket::TCP_KEEPINTVL -> Integer (18607.0)

Time between keepalive probes。 BasicSocket#getsockopt, BasicSocket#setsockopt の第2引数(optname)に使用します。

...Time between keepalive probes。
BasicSocket#getsockopt, BasicSocket#setsockopt
の第2引数(optname)に使用します。

@see tcp(7linux)...

BasicSocket#getpeereid -> [Integer, Integer] (607.0)

Unix ドメインソケットにおいて接続相手の euid と egid を 返します。

..., 2番目の要素が egid です。

ソケットが Unix ドメインソケットでない場合の返り値は
不定です。

require 'socket'

Socket
.unix_server_loop("/tmp/sock") {|s|
begin
euid, egid = s.getpeereid

# Check the connected client is myself or not....

BasicSocket#sendmsg(mesg, flags=0, dest_sockaddr=nil, *controls) -> Integer (325.0)

sendmsg(2) を用いてメッセージを送ります。

...ンブロッキング方式で通信したい
場合は BasicSocket#sendmsg_nonblock を用います。

ソケットが connection-less の場合は dest_sockaddr で
通信先のアドレスを指定しなければなりません。Socket.sockaddr_in
の返り値や Addrinfo オブジェクトを...
...ます。
Socket
::AncillaryData のインスタンスや
3要素(cmsg_level, cmsg_type, cmsg_data) の配列を用いることができます。

送ったバイト数を返します。

# UnixSocket#send_io の実装例
# use Socket::AncillaryData.
require 'socket'

ancdata = Socket::Ancill...
...aryData.int(:UNIX, :SOCKET, :RIGHTS, io.fileno)
sock.sendmsg("a", 0, nil, ancdata)

# use 3-element array.
ancdata = [:SOCKET, :RIGHTS, [io.fileno].pack("i!")]
sock.sendmsg("\0", 0, nil, ancdata)


@param mesg メッセージ文字列
@param flags フラグ(Socket::MSG_* という定数の...

絞り込み条件を変える

Addrinfo#afamily -> Integer (307.0)

アドレスファミリーを整数で返します。

...アドレスファミリーを整数で返します。

require 'socket'

Addrinfo.tcp("localhost", 80).afamily == Socket::AF_INET #=> true...

Addrinfo#ip_port -> Integer (307.0)

ポート番号を整数で返します。

...ポート番号を整数で返します。

require 'socket'

Addrinfo.tcp("127.0.0.1", 80).ip_port #=> 80
Addrinfo.tcp("::1", 80).ip_port #=> 80

@see Addrinfo#ip_address, Addrinfo#ip_unpack...

Addrinfo#ip_unpack -> [String, Integer] (307.0)

IP アドレスとポート番号を 2 要素の配列で返します。

...IP アドレスとポート番号を 2 要素の配列で返します。

require 'socket'

Addrinfo.tcp("127.0.0.1", 80).ip_unpack #=> ["127.0.0.1", 80]
Addrinfo.tcp("::1", 80).ip_unpack #=> ["::1", 80]

@see Addrinfo#ip_address, Addrinfo#ip_port...

Addrinfo#pfamily -> Integer (307.0)

プロトコルファミリーを整数で返します。

...プロトコルファミリーを整数で返します。

require 'socket'

Addrinfo.tcp("localhost", 80).pfamily == Socket::PF_INET #=> true...

Addrinfo#protocol -> Integer (307.0)

ソケットプロトコルを整数で返します。

...ソケットプロトコルを整数で返します。

require 'socket'

Addrinfo.tcp("localhost", 80).protocol == Socket::IPPROTO_TCP #=> true...

絞り込み条件を変える

Addrinfo#socktype -> Integer (307.0)

ソケットタイプを整数で返します。

...ソケットタイプを整数で返します。

require 'socket'

Addrinfo.tcp("localhost", 80).socktype == Socket::SOCK_STREAM #=> true...

BasicSocket#recvmsg(maxmesglen=nil, flags=0, maxcontrollen=nil, opts={}) -> [String, Addrinfo, Integer, *Socket::AncillaryData] (307.0)

recvmsg(2) を用いてメッセージを受け取ります。

...ックします。ノンブロッキング方式で通信したい
場合は BasicSocket#recvmsg_nonblock を用います。

maxmesglen, maxcontrollen で受け取るメッセージおよび補助データ
(Socket::AncillaryData)の最大長をバイト単位で指定します。
省略した場合...
...は必要なだけ内部バッファを拡大して
データが切れないようにします。

flags では Socket::MSG_* という名前の定数の biwsise OR を取った
ものを渡します。

opts にはその他のオプションを渡します。今のところ :scm_right => bool
...
...します。詳しくは Socket::AncillaryData#unix_rights
を参照してください。

返り値は配列で得られます。

返り値の配列の最初の要素は受け取ったメッセージを表す文字列です。

2番目の要素は connection-less socket の場合には送り元の...

BasicSocket#recvmsg_nonblock(maxmesglen=nil, flags=0, maxcontrollen=nil, opts={}) -> [String, Addrinfo, Integer, *Socket::AncillaryData] (307.0)

recvmsg(2) を用いてノンブロッキング方式でメッセージを受け取ります。

...recvmsg(2) を用いてノンブロッキング方式でメッセージを受け取ります。

ブロッキングの有無以外は BasicSocket#recvmsg と同じです。
詳しくはそちらを参照してください。

@param maxmesglen 受け取るメッセージの最大長
@param flags...

BasicSocket#send(mesg, flags, dest_sockaddr = nil) -> Integer (307.0)

ソケットを介してデータを送ります。flags に関しては send(2) を参照してください。connect していないソケット に対しては送り先である dest_sockaddr を指定する必要があります。実際に送っ たデータの長さを返します。

...レス構造体を pack した文字列」を指定します。

@raise Errno::EXXX データの送信に失敗した場合に発生します。

例:

require 'socket'

s = UDPSocket.new
sockaddr = Socket.sockaddr_in("discard", "localhost")
s.send("The king has donkey ears!", 0, sockaddr)...

BasicSocket#sendmsg_nonblock(mesg, flags=0, dest_sockaddr=nil, *controls) -> Integer (307.0)

sendmsg(2) を用いてノンブロッキング方式でメッセージを送ります。

...cSocket#sendmsg を見てください。

@return 送ったバイト数
@param mesg メッセージ文字列
@param flags フラグ(Socket::MSG_* という定数の bitwise OR を取ったもの)
@param dest_sockaddr 通信先のアドレス
@param controls 補助データの配列
@see BasicSocket#...

絞り込み条件を変える

Socket.getservbyname(service, proto = "tcp") -> Integer (307.0)

service, protoに対応するポート番号を返 します。protoの省略値は"tcp"です。

service, protoに対応するポート番号を返
します。protoの省略値は"tcp"です。

@param service サービス名を文字列で指定します。例えば、"ftp", "telnet" が相当します。
@param proto プロトコル名を文字列で指定します。省略値は"tcp" です。

@return ポート番号を整数で返します。

Socket::AF_APPLETALK -> Integer (307.0)

Apple talk。 Socket.open の第一引数 domain に使用します。

...Apple talk。
Socket
.open の第一引数 domain に使用します。

@see socket(2linux), socket(2freebsd), ddp(7linux)...

Socket::AF_ATM -> Integer (307.0)

ATM。 Socket.open の第一引数 domain に使用します。

...ATM。
Socket
.open の第一引数 domain に使用します。

@see socket(2freebsd)...

Socket::AF_AX25 -> Integer (307.0)

ITU-T X.25 / ISO-8208。 Socket.open の第一引数 domain に使用します。

...ITU-T X.25 / ISO-8208。
Socket
.open の第一引数 domain に使用します。

@see socket(2linux)...

Socket::AF_CCITT -> Integer (307.0)

@todo CCITT プロトコル。 Socket.open の第一引数 domain に使用します。

...@todo
CCITT プロトコル。
Socket
.open の第一引数 domain に使用します。...

絞り込み条件を変える

Socket::AF_CHAOS -> Integer (307.0)

@todo MIT CHAOS プロトコル。 Socket.open の第一引数 domain に使用します。

...@todo
MIT CHAOS プロトコル。
Socket
.open の第一引数 domain に使用します。...

Socket::AF_CNT -> Integer (307.0)

@todo Computer Network Technology。 Socket.open の第一引数 domain に使用します。

...@todo
Computer Network Technology。
Socket
.open の第一引数 domain に使用します。...

Socket::AF_COIP -> Integer (307.0)

@todo connection-oriented IP。 Socket.open の第一引数 domain に使用します。

...@todo
connection-oriented IP。
Socket
.open の第一引数 domain に使用します。...

Socket::AF_DATAKIT -> Integer (307.0)

@todo datakit protocol。 Socket.open の第一引数 domain に使用します。

...@todo
datakit protocol。
Socket
.open の第一引数 domain に使用します。...

Socket::AF_DEC -> Integer (307.0)

@todo DECnet protocol。 Socket.open の第一引数 domain に使用します。

...@todo
DECnet protocol。
Socket
.open の第一引数 domain に使用します。...

絞り込み条件を変える

Socket::AF_DLI -> Integer (307.0)

@todo DEC Direct data link interface。 Socket.open の第一引数 domain に使用します。

...@todo
DEC Direct data link interface。
Socket
.open の第一引数 domain に使用します。...

Socket::AF_E164 -> Integer (307.0)

@todo CCITT E.164 recommendation。 Socket.open の第一引数 domain に使用します。

...@todo
CCITT E.164 recommendation。
Socket
.open の第一引数 domain に使用します。...

Socket::AF_ECMA -> Integer (307.0)

@todo European computer manufacturers。 Socket.open の第一引数 domain に使用します。

...@todo
European computer manufacturers。
Socket
.open の第一引数 domain に使用します。...

Socket::AF_HYLINK -> Integer (307.0)

@todo NSC Hyperchannel。 Socket.open の第一引数 domain に使用します。

...@todo
NSC Hyperchannel。
Socket
.open の第一引数 domain に使用します。...

Socket::AF_IMPLINK -> Integer (307.0)

@todo ARPANET IMP。 Socket.open の第一引数 domain に使用します。

...@todo
ARPANET IMP。
Socket
.open の第一引数 domain に使用します。...

絞り込み条件を変える

Socket::AF_INET -> Integer (307.0)

IPv4。 Socket.open の第一引数 domain に使用します。

...IPv4。
Socket
.open の第一引数 domain に使用します。

@see sys/socket.h(header), socket(2freebsd), ip(7linux)...

Socket::AF_INET6 -> Integer (307.0)

IPv6。 Socket.open の第一引数 domain に使用します。

...IPv6。
Socket
.open の第一引数 domain に使用します。

@see sys/socket.h(header), socket(2freebsd), ipv6(7linux)...

Socket::AF_IPX -> Integer (307.0)

IPX(Novell Internet Packet eXchange protocol)。 Socket.open の第一引数 domain に使用します。

...IPX(Novell Internet Packet eXchange protocol)。
Socket
.open の第一引数 domain に使用します。

@see socket(3linux)...

Socket::AF_ISDN -> Integer (307.0)

@todo Integrated Services Digital Network。 Socket.open の第一引数 domain に使用します。

...@todo
Integrated Services Digital Network。
Socket
.open の第一引数 domain に使用します。...

Socket::AF_ISO -> Integer (307.0)

@todo ISO Open Systems Interconnection protocols。 Socket.open の第一引数 domain に使用します。

...@todo
ISO Open Systems Interconnection protocols。
Socket
.open の第一引数 domain に使用します。...

絞り込み条件を変える

Socket::AF_LAT -> Integer (307.0)

@todo Local Area Transport protocol。 Socket.open の第一引数 domain に使用します。

...@todo
Local Area Transport protocol。
Socket
.open の第一引数 domain に使用します。...

Socket::AF_LINK -> Integer (307.0)

@todo Link layer interface。 Socket.open の第一引数 domain に使用します。

...@todo
Link layer interface。
Socket
.open の第一引数 domain に使用します。...

Socket::AF_LOCAL -> Integer (307.0)

Unix domain socket。 Socket.open の第一引数 domain に使用します。

...Unix domain socket
Socket
.open の第一引数 domain に使用します。

@see sys/socket.h(header), unix(7linux)...

Socket::AF_MAX -> Integer (307.0)

対象のプラットフォーム上でのアドレスファミリーの最大の数値。

...対象のプラットフォーム上でのアドレスファミリーの最大の数値。

@see Socket::Constants::PF_MAX...

Socket::AF_NATM -> Integer (307.0)

@todo Native ATM access。 Socket.open の第一引数 domain に使用します。

...@todo
Native ATM access。
Socket
.open の第一引数 domain に使用します。...

絞り込み条件を変える

Socket::AF_NDRV -> Integer (307.0)

@todo Network driver raw access。 Socket.open の第一引数 domain に使用します。

...@todo
Network driver raw access。
Socket
.open の第一引数 domain に使用します。...

Socket::AF_NETBIOS -> Integer (307.0)

@todo NetBIOS。 Socket.open の第一引数 domain に使用します。

...@todo
NetBIOS。
Socket
.open の第一引数 domain に使用します。...

Socket::AF_NETGRAPH -> Integer (307.0)

Netgraph sockets。 Socket.open の第一引数 domain に使用します。

...Netgraph sockets。
Socket
.open の第一引数 domain に使用します。

@see socket(2freebsd)...

Socket::AF_NS -> Integer (307.0)

@todo XEROX NS protocol。 Socket.open の第一引数 domain に使用します。

...@todo
XEROX NS protocol。
Socket
.open の第一引数 domain に使用します。...

Socket::AF_OSI -> Integer (307.0)

@todo ISO Open Systems Interconnection protocols。 Socket.open の第一引数 domain に使用します。

...@todo
ISO Open Systems Interconnection protocols。
Socket
.open の第一引数 domain に使用します。...

絞り込み条件を変える

Socket::AF_PACKET -> Integer (307.0)

デバイスレベルインターフェース。 Socket.open の第一引数 domain に使用します。

...デバイスレベルインターフェース。
Socket
.open の第一引数 domain に使用します。

@see socket(2linux), packet(7linux)...

Socket::AF_PPP -> Integer (307.0)

@todo Point-to-Point Protocol。 Socket.open の第一引数 domain に使用します。

...@todo
Point-to-Point Protocol。
Socket
.open の第一引数 domain に使用します。...

Socket::AF_PUP -> Integer (307.0)

PUP(PARC Universal Packet)。 Socket.open の第一引数 domain に使用します。

...PUP(PARC Universal Packet)。
Socket
.open の第一引数 domain に使用します。

@see socket(2freebsd)...

Socket::AF_ROUTE -> Integer (307.0)

@todo Internal Routing protocol。 Socket.open の第一引数 domain に使用します。

...@todo
Internal Routing protocol。
Socket
.open の第一引数 domain に使用します。

@todo...

Socket::AF_SIP -> Integer (307.0)

@todo Simple Internet Protocol。 Socket.open の第一引数 domain に使用します。

...@todo
Simple Internet Protocol。
Socket
.open の第一引数 domain に使用します。...

絞り込み条件を変える

Socket::AF_SNA -> Integer (307.0)

@todo IBM SNA protocol。 Socket.open の第一引数 domain に使用します。

...@todo
IBM SNA protocol。
Socket
.open の第一引数 domain に使用します。...

Socket::AF_SYSTEM -> Integer (307.0)

@todo

...@todo

Socket
.open の第一引数 domain に使用します。...

Socket::AF_UNIX -> Integer (307.0)

Unix domain socket。 Socket.open の第一引数 domain に使用します。

...Unix domain socket
Socket
.open の第一引数 domain に使用します。

@see sys/socket.h(header), unix(7linux)...

Socket::AF_UNSPEC -> Integer (307.0)

アドレスファミリー不定。

...アドレスファミリー不定。

@see Socket.open, sys/socket.h(header)...

Socket::AI_ADDRCONFIG -> Integer (307.0)

Accept only if any address is assigned。

...Accept only if any address is assigned。

Socket
.getaddrinfo, Addrinfo.getaddrinfo の引数 flags に渡す
定数です。

@see getaddrinfo(3)...

絞り込み条件を変える

Socket::AI_ALL -> Integer (307.0)

Allow all addresses。

...Allow all addresses。

Socket
.getaddrinfo, Addrinfo.getaddrinfo の引数 flags に渡す
定数です。

@see getaddrinfo(3)...

Socket::AI_CANONNAME -> Integer (307.0)

Fill in the canonical name。

...Fill in the canonical name。

Socket
.getaddrinfo, Addrinfo.getaddrinfo の引数 flags に渡す
定数です。

@see getaddrinfo(3)...

Socket::AI_DEFAULT -> Integer (307.0)

Default flags for getaddrinfo。

...Default flags for getaddrinfo。

Socket
.getaddrinfo, Addrinfo.getaddrinfo の引数 flags に渡す
定数です。

@see getipnodebyname(3freebsd)...

Socket::AI_MASK -> Integer (307.0)

@todo

@todo

Socket::AI_NUMERICHOST -> Integer (307.0)

Prevent host name resolution。

...Prevent host name resolution。

Socket
.getaddrinfo, Addrinfo.getaddrinfo の引数 flags に渡す
定数です。

@see getaddrinfo(3)...

絞り込み条件を変える

Socket::AI_NUMERICSERV -> Integer (307.0)

Prevent server name resolution。

...Prevent server name resolution。

Socket
.getaddrinfo, Addrinfo.getaddrinfo の引数 flags に渡す
定数です。

@see getaddrinfo(3)...

Socket::AI_PASSIVE -> Integer (307.0)

Get address to use with bind。

...Get address to use with bind。

Socket
.getaddrinfo, Addrinfo.getaddrinfo の引数 flags に渡す
定数です。

@see getaddrinfo(3)...

Socket::AI_V4MAPPED -> Integer (307.0)

Accept IPv4-mapped IPv6 addresses。

...Accept IPv4-mapped IPv6 addresses。

Socket
.getaddrinfo, Addrinfo.getaddrinfo の引数 flags に渡す
定数です。

@see getaddrinfo(3)...

Socket::AI_V4MAPPED_CFG -> Integer (307.0)

Accept IPv4 mapped addresses if the kernel supports it。

...Accept IPv4 mapped addresses if the kernel supports it。

Socket
.getaddrinfo, Addrinfo.getaddrinfo の引数 flags に渡す
定数です。

@see getipnodebyname(3freebsd)...

Socket::AncillaryData#family -> Integer (307.0)

自身が保持している socket family を返します。

...自身が保持している socket family を返します。

require 'socket'

p Socket::AncillaryData.new(:INET6, :IPV6, :PKTINFO, "").family
#=> 10

@see Socket::AncillaryData.new...

絞り込み条件を変える

Socket::AncillaryData#ip_pktinfo -> [Addrinfo, Integer, Addrinfo] (307.0)

自身の type が IP_PKTINFO である場合、保持しているデータ (アドレス、インターフェースのインデックス、ローカルアドレス) を3要素の配列で返します。

...張であり、システムによっては使えない場合があります。

require 'socket'

addr = Addrinfo.ip("127.0.0.1")
ifindex = 0
spec_dest = Addrinfo.ip("127.0.0.1")
ancdata = Socket::AncillaryData.ip_pktinfo(addr, ifindex, spec_dest)
p ancdata.ip_pktinfo
#=> [#<Addrinfo:...
...127.0.0.1>, 0, #<Addrinfo: 127.0.0.1>]

@raise TypeError level, type が IPPROTO_IP, IP_PKTINFO でない場合に
発生します。
@see Socket::AncillaryData.ip_pktinfo,
Socket
::Constants::IP_PKTINFO...

Socket::AncillaryData#ipv6_pktinfo -> [Addrinfo, Integer] (307.0)

自身の type が IPV6_PKTINFO である場合、保持しているデータ (アドレス、インターフェースのインデックス) を2要素の配列で返します。

...

require 'socket'

addr = Addrinfo.ip("::1")
ifindex = 0
ancdata = Socket::AncillaryData.ipv6_pktinfo(addr, ifindex)
p ancdata.ipv6_pktinfo #=> [#<Addrinfo: ::1>, 0]

@see Socket::AncillaryData.ipv6_pktinfo,
Socket
::AncillaryData#ipv6_pktinfo_addr,
Socket
::AncillaryData#ipv...
...6_pktinfo_ifindex,
Socket
::Constants::IPV6_PKTINFO...

Socket::AncillaryData#ipv6_pktinfo_ifindex -> Integer (307.0)

自身の type が IPV6_PKTINFO である場合、保持しているデータ (アドレス、インターフェースのインデックス) のインデックスを返します。

...e 'socket'

addr = Addrinfo.ip("::1")
ifindex = 0
ancdata = Socket::AncillaryData.ipv6_pktinfo(addr, ifindex)
p ancdata.ipv6_pktinfo_ifindex #=> 0

@see Socket::AncillaryData.ipv6_pktinfo,
Socket
::AncillaryData#ipv6_pktinfo,
Socket
::AncillaryData#ipv6_pktinfo_addr,
Socket
::C...

Socket::AncillaryData#level -> Integer (307.0)

自身が保持している cmsg level (元プロトコル) を返します。

...自身が保持している cmsg level (元プロトコル) を返します。

require 'socket'

p Socket::AncillaryData.new(:INET6, :IPV6, :PKTINFO, "").level
#=> 41

@see Socket::AncillaryData.new...

Socket::AncillaryData#type -> Integer (307.0)

自身が保持している cmsg type (種類) を返します。

...自身が保持している cmsg type (種類) を返します。

require 'socket'

p Socket::AncillaryData.new(:INET6, :IPV6, :PKTINFO, "").type
#=> 2

@see Socket::AncillaryData.new...

絞り込み条件を変える

Socket::Constants::AF_APPLETALK -> Integer (307.0)

Apple talk。 Socket.open の第一引数 domain に使用します。

...Apple talk。
Socket
.open の第一引数 domain に使用します。

@see socket(2linux), socket(2freebsd), ddp(7linux)...

Socket::Constants::AF_ATM -> Integer (307.0)

ATM。 Socket.open の第一引数 domain に使用します。

...ATM。
Socket
.open の第一引数 domain に使用します。

@see socket(2freebsd)...

Socket::Constants::AF_AX25 -> Integer (307.0)

ITU-T X.25 / ISO-8208。 Socket.open の第一引数 domain に使用します。

...ITU-T X.25 / ISO-8208。
Socket
.open の第一引数 domain に使用します。

@see socket(2linux)...

Socket::Constants::AF_CCITT -> Integer (307.0)

@todo CCITT プロトコル。 Socket.open の第一引数 domain に使用します。

...@todo
CCITT プロトコル。
Socket
.open の第一引数 domain に使用します。...

Socket::Constants::AF_CHAOS -> Integer (307.0)

@todo MIT CHAOS プロトコル。 Socket.open の第一引数 domain に使用します。

...@todo
MIT CHAOS プロトコル。
Socket
.open の第一引数 domain に使用します。...

絞り込み条件を変える

Socket::Constants::AF_CNT -> Integer (307.0)

@todo Computer Network Technology。 Socket.open の第一引数 domain に使用します。

...@todo
Computer Network Technology。
Socket
.open の第一引数 domain に使用します。...

Socket::Constants::AF_COIP -> Integer (307.0)

@todo connection-oriented IP。 Socket.open の第一引数 domain に使用します。

...@todo
connection-oriented IP。
Socket
.open の第一引数 domain に使用します。...

Socket::Constants::AF_DATAKIT -> Integer (307.0)

@todo datakit protocol。 Socket.open の第一引数 domain に使用します。

...@todo
datakit protocol。
Socket
.open の第一引数 domain に使用します。...

Socket::Constants::AF_DEC -> Integer (307.0)

@todo DECnet protocol。 Socket.open の第一引数 domain に使用します。

...@todo
DECnet protocol。
Socket
.open の第一引数 domain に使用します。...

Socket::Constants::AF_DLI -> Integer (307.0)

@todo DEC Direct data link interface。 Socket.open の第一引数 domain に使用します。

...@todo
DEC Direct data link interface。
Socket
.open の第一引数 domain に使用します。...

絞り込み条件を変える

Socket::Constants::AF_E164 -> Integer (307.0)

@todo CCITT E.164 recommendation。 Socket.open の第一引数 domain に使用します。

...@todo
CCITT E.164 recommendation。
Socket
.open の第一引数 domain に使用します。...

Socket::Constants::AF_ECMA -> Integer (307.0)

@todo European computer manufacturers。 Socket.open の第一引数 domain に使用します。

...@todo
European computer manufacturers。
Socket
.open の第一引数 domain に使用します。...

Socket::Constants::AF_HYLINK -> Integer (307.0)

@todo NSC Hyperchannel。 Socket.open の第一引数 domain に使用します。

...@todo
NSC Hyperchannel。
Socket
.open の第一引数 domain に使用します。...

Socket::Constants::AF_IMPLINK -> Integer (307.0)

@todo ARPANET IMP。 Socket.open の第一引数 domain に使用します。

...@todo
ARPANET IMP。
Socket
.open の第一引数 domain に使用します。...

Socket::Constants::AF_INET -> Integer (307.0)

IPv4。 Socket.open の第一引数 domain に使用します。

...IPv4。
Socket
.open の第一引数 domain に使用します。

@see sys/socket.h(header), socket(2freebsd), ip(7linux)...

絞り込み条件を変える

<< 1 2 3 ... > >>