Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /home/zhenxiangba/zhenxiangba.com/public_html/phproxy-improved-master/index.php on line 456
function rb_check_convert_type (Ruby 2.2.0)
[go: Go Back, main page]

Ruby 2.2.0 リファレンスマニュアル > 関数一覧 > rb_check_convert_type

function rb_check_convert_type

VALUE rb_check_convert_type(VALUE val, int type, const char *tname, const char *method)

val.method を実行してクラス tname のインスタンスを返します。 val がメソッド method を持たなければ nil を返します。

type は、T_ARRAY, T_STRING などの構造体を表す ID です。 method の結果の型が type でなければ例外 TypeError が発生します。