| 総合手引 | セクション 9 | English | オプション |
#include <sys/endian.h>
be16toh(), be32toh() および be64toh() 関数はビッグエンディアンのバイトオーダの整数をシステムのネイティブな バイトオーダに変換して返します。 ビッグエンディアンのシステム上では、戻り値は引数と同じになります。
le16toh(), le32toh() および le64toh() 関数はリトルエンディアンのバイトオーダの整数をシステムのネイティブな バイトオーダに変換して返します。 リトルエンディアンのシステム上では、戻り値は引数と同じになります。
htobe16(), htobe32() および htobe64() 関数はシステムのネイティブなバイトオーダの整数をビッグエンディアンの バイトオーダに変換して返します。 ビッグエンディアンのシステム上では、戻り値は引数と同じになります。
htole16(), htole32() および htole64() 関数はシステムのネイティブなバイトオーダの整数をリトルエンディアンの バイトオーダに変換して返します。 リトルエンディアンのシステム上では、戻り値は引数と同じになります。
be16enc(), be16dec(), be32enc(), be32dec(), be64enc(), be64dec(), le16enc(), le16dec(), le32enc(), le32dec(), le64enc(), および le64dec() 関数はビッグ/リトルエンディアンのあらゆるアライメントの、 整数からバイトストリングへエンコードおよび バイトコードから整数へデコードを行います。
エンコード/デコード関数は FreeBSD 5.1 ではじめて登場しました。
| BYTEORDER (9) | April 29, 2002 |
| 総合手引 | セクション 9 | English | オプション |
このマニュアルページサービスについてのご意見は Ben Bullock にお知らせください。 Privacy policy.
| “ | Ken Thompson has an automobile which he helped design. Unlike most automobiles, it has neither speedometer, nor gas gauge, nor any of the other numerous idiot lights which plague the modern driver. Rather, if the driver makes a mistake, a giant “?” lights up in the center of the dashboard. “The experienced driver,” says Thompson, “will usually know what's wrong.” | ” |