45件ヒット
[1-45件を表示]
(0.015秒)
種類
- インスタンスメソッド (12)
- モジュール関数 (12)
- モジュール (12)
- 文書 (9)
クラス
- String (12)
モジュール
- Kconv (12)
キーワード
-
NEWS for Ruby 3
. 0 . 0 (5) -
NEWS for Ruby 3
. 1 . 0 (4) - kconv (24)
検索結果
先頭5件
-
NKF (38132.0)
-
nkf(Network Kanji code conversion Filter, https://osdn.net/projects/nkf/) を Ruby から使うためのモジュールです。
...nkf(Network Kanji code conversion Filter, https://osdn.net/projects/nkf/) を
Ruby から使うためのモジュールです。
=== 使い方
以下は、漢字コード変換コマンドの例です。
//emlist[例][ruby]{
#!/usr/local/bin/ruby
require 'nkf'
opt = ''
opt = ARGV.shift if ARGV[...... NKF.nkf(opt, line)
end
//}
以下は、漢字コード判別コマンドの例です。
//emlist[例][ruby]{
#!/usr/local/bin/ruby
require 'nkf'
CODES = {
NKF::JIS => "JIS",
NKF::EUC => "EUC",
NKF::SJIS => "SJIS",
NKF::UTF8 => "UTF8",
NKF::BINARY => "BINARY",
NKF......::ASCII => "ASCII",
NKF::UNKNOWN => "UNKNOWN",
}
while file = ARGV.shift
str = open(file) {|io| io.gets(nil) }
printf "%-10s ", file
if str.nil?
puts "EMPTY"
else
puts CODES.fetch(NKF.guess(str))
end
end
//}
=== オプション文字列
-b 入力がバッファリン... -
Kconv
. # kconv(str , out _ code , in _ code = Kconv :: AUTO) -> String (274.0) -
文字列 str のエンコーディングを out_code に変換したものを 返します。in_code も指定されていたら str のエンコーディングが in_code だとして動作します。
...文字列 str のエンコーディングを out_code に変換したものを
返します。in_code も指定されていたら str のエンコーディングが
in_code だとして動作します。
このメソッドはMIME エンコードされた文字列を展開し、
いわゆる半角......カナを全角に変換します。
これらを変換したくない場合は、 NKF.#nkf を使ってください。
@param str 変換元の文字列
@param out_code 変換後のエンコーディング
@param in_code strのエンコーディング
@see String#kconv... -
String
# kconv(out _ code , in _ code = Kconv :: AUTO) -> String (274.0) -
self のエンコーディングを out_code に変換した文字列を 返します。 out_code in_code は Kconv の定数で指定します。
...out_code に変換した文字列を
返します。
out_code in_code は Kconv の定数で指定します。
このメソッドは MIME エンコードされた文字列を展開し、
いわゆる半角カナを全角に変換します。
これらを変換したくない場合は、 NKF.#nkf......を使ってください。
@param out_code 変換後のエンコーディングを Kconv の定数で指定します。
@param in_code 変換する文字列のエンコーディングを Kconv の定数で指定します。
@see Kconv.#kconv... -
NEWS for Ruby 3
. 0 . 0 (72.0) -
NEWS for Ruby 3.0.0 このドキュメントは前回リリース以降のバグ修正を除くユーザーに影響のある機能の変更のリストです。
...ストはリンク先を参照してください。
== 言語仕様の変更
* Keyword arguments are now separated from positional arguments.
Code that resulted in deprecation warnings in Ruby 2.7 will now
result in ArgumentError or different behavior. 14183
* Procs accepting a single......shown by default (since Ruby 2.7.2).
Turn them on with `-W:deprecated` (or with `-w` to show other warnings too).
16345
* `$SAFE` and `$KCODE` are now normal global variables with no special behavior.
C-API methods related to `$SAFE` have been removed.
16131 17136
* yield in sin......* weakref
* The following extensions are promoted to default gems from stdlib.
* digest
* io-nonblock
* io-wait
* nkf
* pathname
* syslog
* win32ole
* Bundled gems
* net-telnet and xmlrpc have been removed from the bundled gems. If you are i... -
NEWS for Ruby 3
. 1 . 0 (12.0) -
NEWS for Ruby 3.1.0 このドキュメントは前回リリース以降のバグ修正を除くユーザーに影響のある機能の変更のリストです。
...た。ハッシュを最初のメンバにするには、ハッシュリテラルを使用する必要があります。 16806
* String
* Unicodeと絵文字のバージョンが13.0.0に更新されました。 17750 18029
* String#unpack と String#unpack1 が任意のバイト数をス.......5.10
* io-wait 0.2.1
* ipaddr 1.2.3
* irb 1.4.1
* json 2.6.1
* logger 1.5.0
* net-http 0.2.0
* net-protocol 0.1.2
* nkf 0.1.1
* open-uri 0.2.0
* openssl 3.0.0
* optparse 0.2.0
* ostruct 0.5.2
* pathname 0.2.0
* pp 0.3.0
* prettyprint 0.1.1......emsに追加されました。高速なデバッガの実装で、リモートデバッグの多数の機能を提供、カラフルなREPL、IDE(VSCode)インテグレーション、など。標準ライブラリの lib/debug.rb は debug.gem で置き換えられました。
* デバッグ実行...