BinaryReaderとは? わかりやすく解説

BinaryReader クラス

プリミティブ データ型特定のエンコーディングバイナリ値として読み取ります。

名前空間: System.IO
アセンブリ: mscorlib (mscorlib.dll 内)
構文構文

<ComVisibleAttribute(True)> _
Public Class BinaryReader
    Implements IDisposable
[ComVisibleAttribute(true)] 
public class BinaryReader : IDisposable
[ComVisibleAttribute(true)] 
public ref class BinaryReader : IDisposable
/** @attribute ComVisibleAttribute(true) */ 
public class BinaryReader implements IDisposable
ComVisibleAttribute(true) 
public class BinaryReader implements IDisposable
解説解説
使用例使用例

アプリケーション設定ファイル保存する方法ファイルか取得する方法の例を次に示します

Imports Microsoft.VisualBasic
Imports System
Imports System.IO
Imports System.Security.Permissions

Public Class Test

    Shared Sub Main()

        ' Load application settings.
        Dim appSettings As New
 AppSettings()
        Console.WriteLine("App settings." & vbcrLf
 & "Aspect " & _
            "Ratio: {0}, Lookup directory: {1}," &
 vbcrLf & "Auto " & _
            "save time: {2} minutes, Show status bar: {3}"
 & vbCrLf, _
            New Object(3){appSettings.AspectRatio.ToString(),
 _
            appSettings.LookupDir, _
            appSettings.AutoSaveTime.ToString(), _
            appSettings.ShowStatusBar.ToString()})

        ' Change the settings.
        appSettings.AspectRatio   = 1.250
        appSettings.LookupDir     = "C:\Temp"
        appSettings.AutoSaveTime  = 10
        appSettings.ShowStatusBar = True

        ' Save the new settings.
        appSettings.Close()
   
    End Sub
End Class

' Store and retrieve application settings.
Public Class AppSettings

    Const fileName As String
 = "AppSettings#@@#.dat"
    Dim aspRatio As Single
    Dim lkupDir As String
    Dim saveTime As Integer
    Dim statusBar As Boolean

    Property AspectRatio As Single
        Get
            Return aspRatio
        End Get
        Set
            aspRatio = Value
        End Set
    End Property
   
    Property LookupDir As String
        Get
            Return lkupDir
        End Get
        Set
            lkupDir = Value
        End Set
    End Property
   
    Property AutoSaveTime As Integer
        Get
            Return saveTime
        End Get
        Set
            saveTime = Value
        End Set
    End Property
   
    Property ShowStatusBar As Boolean
        Get
            Return statusBar
        End Get
        Set
            statusBar = Value
        End Set
    End Property

    Sub New()

        ' Create default application settings.
        aspRatio   = 1.3333
        lkupDir     = "C:\AppDirectory"
        saveTime  = 30
        statusBar = False

        If File.Exists(fileName) Then
            Dim binReader As New
 BinaryReader( _
                File.Open(fileName, FileMode.Open))
            Try

                ' If the file is not empty, 
                ' read the application settings.
                If binReader.PeekChar() <> -1 Then
                    aspRatio   = binReader.ReadSingle()
                    lkupDir     = binReader.ReadString()
                    saveTime  = binReader.ReadInt32()
                    statusBar = binReader.ReadBoolean()
                    Return
                End If

            ' If the end of the stream is reached before reading
            ' the four data values, ignore the error and use the
            ' default settings for the remaining values.
            Catch ex As EndOfStreamException
                Console.WriteLine("{0} caught and ignored. "
 & _ 
                    "Using default values.", ex.GetType().Name)
            Finally
                binReader.Close()
            End Try
        End If

    End Sub

    ' Create a file and store the application settings.
    Sub Close()
        Dim binWriter As New
 BinaryWriter( _
            File.Open(fileName, FileMode.Create))
        Try
            binWriter.Write(aspRatio)
            binWriter.Write(lkupDir)
            binWriter.Write(saveTime)
            binWriter.Write(statusBar)
        Finally
            binWriter.Close()
        End Try
    End Sub

End Class
using System;
using System.IO;
using System.Security.Permissions;

class Test
{
    static void Main()
    {
        // Load application settings.
        AppSettings appSettings = new AppSettings();
        Console.WriteLine("App settings.\nAspect Ratio: {0}, " +
            "Lookup directory: {1},\nAuto save time: {2} minutes, " +
            "Show status bar: {3}\n", 
            new Object[4]{appSettings.AspectRatio.ToString(),
 
            appSettings.LookupDir, appSettings.AutoSaveTime.ToString(),
            appSettings.ShowStatusBar.ToString()});

        // Change the settings.
        appSettings.AspectRatio   = 1.250F;
        appSettings.LookupDir     = @"C:\Temp";
        appSettings.AutoSaveTime  = 10;
        appSettings.ShowStatusBar = true;

        // Save the new settings.
        appSettings.Close();
    }
}

// Store and retrieve application settings.
class AppSettings
{
    const string fileName = "AppSettings#@@#.dat";
    float  aspectRatio;
    string lookupDir;
    int    autoSaveTime;
    bool   showStatusBar;

    public float AspectRatio
    {
        get{ return aspectRatio; }
        set{ aspectRatio = value; }
    }

    public string LookupDir
    {
        get{ return lookupDir; }
        set{ lookupDir = value; }
    }

    public int AutoSaveTime
    {
        get{ return autoSaveTime; }
        set{ autoSaveTime = value; }
    }

    public bool ShowStatusBar
    {
        get{ return showStatusBar; }
        set{ showStatusBar = value; }
    }

    public AppSettings()
    {
        // Create default application settings.
        aspectRatio   = 1.3333F;
        lookupDir     = @"C:\AppDirectory";
        autoSaveTime  = 30;
        showStatusBar = false;

        if(File.Exists(fileName))
        {
            BinaryReader binReader = 
                new BinaryReader(File.Open(fileName, FileMode.Open));
            try
            {
                // If the file is not empty, 
                // read the application settings.
                if(binReader.PeekChar() != -1)
                {
                    aspectRatio   = binReader.ReadSingle();
                    lookupDir     = binReader.ReadString();
                    autoSaveTime  = binReader.ReadInt32();
                    showStatusBar = binReader.ReadBoolean();
                }
            }

            // If the end of the stream is reached before reading
            // the four data values, ignore the error and use the
            // default settings for the remaining values.
            catch(EndOfStreamException e)
            {
                Console.WriteLine("{0} caught and ignored. " + 
                    "Using default values.", e.GetType().Name);
            }
            finally
            {
                binReader.Close();
            }
        }

    }

    // Create a file and store the application settings.
    public void Close()
    {
        using(BinaryWriter binWriter = 
            new BinaryWriter(File.Open(fileName, FileMode.Create)))
        {
            binWriter.Write(aspectRatio);
            binWriter.Write(lookupDir);
            binWriter.Write(autoSaveTime);
            binWriter.Write(showStatusBar);
        }
    }
}
using namespace System;
using namespace System::IO;
using namespace System::Security::Permissions;

// Store and retrieve application settings.
ref class AppSettings
{
private:
   static String^ fileName =  "AppSettings#@@#.dat";
   float aspectRatio;
   String^ lookupDir;
   int autoSaveTime;
   Boolean showStatusBar;

public:

   property float AspectRatio 
   {
      float get()
      {
         return aspectRatio;
      }

      void set( float value
 )
      {
         aspectRatio = value;
      }

   }

   property String^ LookupDir 
   {
      String^ get()
      {
         return lookupDir;
      }

      void set( String^ value )
      {
         lookupDir = value;
      }

   }

   property int AutoSaveTime 
   {
      int get()
      {
         return autoSaveTime;
      }

      void set( int value
 )
      {
         autoSaveTime = value;
      }

   }

   property Boolean ShowStatusBar 
   {
      Boolean get()
      {
         return showStatusBar;
      }

      void set( Boolean value )
      {
         showStatusBar = value;
      }

   }
   AppSettings()
   {
      
      // Create default application settings.
      aspectRatio = 1.3333F;
      lookupDir =  "C:\\AppDirectory";
      autoSaveTime = 30;
      showStatusBar = false;
      if ( File::Exists( fileName ) )
      {
         
         BinaryReader^ binReader = gcnew BinaryReader( File::Open( fileName, FileMode::Open
 ) );
         try
         {
            
            // If the file is not empty, 
            // read the application settings.
            if ( binReader->PeekChar() != -1 )
            {
               aspectRatio = binReader->ReadSingle();
               lookupDir = binReader->ReadString();
               autoSaveTime = binReader->ReadInt32();
               showStatusBar = binReader->ReadBoolean();
               return;
            }
         }
         // If the end of the stream is reached before reading
         // the four data values, ignore the error and use the
         // default settings for the remaining values.
         catch ( EndOfStreamException^ e ) 
         {
            Console::WriteLine( "{0} caught and ignored. "
            "Using default values.", e->GetType()->Name
 );
         }
         finally
         {
            binReader->Close();
         }

         
      }
   }


   // Create a file and store the application settings.
   void Close()
   {
      
      BinaryWriter^ binWriter = gcnew BinaryWriter( File::Open( fileName, FileMode::Create
 ) );
      try
      {
         binWriter->Write( aspectRatio );
         binWriter->Write( lookupDir );
         binWriter->Write( autoSaveTime );
         binWriter->Write( showStatusBar );
      }
      finally
      {
         binWriter->Close();
      }

      
   }

};

int main()
{
   
   // Load application settings.
   AppSettings^ appSettings = gcnew AppSettings;
   array<Object^>^someObject = {appSettings->AspectRatio.ToString(),appSettings->LookupDir
,appSettings->AutoSaveTime.ToString(),appSettings->ShowStatusBar.ToString()};
   Console::WriteLine( "App settings.\nAspect Ratio: {0}, "
   "Lookup directory: {1},\nAuto save time: {2} minutes, "
   "Show status bar: {3}\n", someObject );
   
   // Change the settings.
   appSettings->AspectRatio = 1.250F;
   appSettings->LookupDir =  "C:\\Temp";
   appSettings->AutoSaveTime = 10;
   appSettings->ShowStatusBar = true;
   
   // Save the new settings.
   appSettings->Close();
}

import System.*;
import System.IO.*;
import System.Security.Permissions.*;

class Test
{   
    public static void main(String[]
 args)
    {        
        // Load application settings.
        AppSettings appSettings = new AppSettings();
        Console.WriteLine("App settings.\nAspect Ratio: {0}, "
            + "Lookup directory: {1},\nAuto save time: {2} minutes, "
            + "Show status bar: {3}\n",
            new Object[]{System.Convert.ToString(appSettings.get_AspectRatio())
,
            appSettings.get_LookupDir(),
            System.Convert.ToString(appSettings.get_AutoSaveTime()),
            System.Convert.ToString(appSettings.get_ShowStatusBar())});

        // Change the settings.
        appSettings.set_AspectRatio(1.25F);
        appSettings.set_LookupDir("C:\\Temp");
        appSettings.set_AutoSaveTime ( 10);
        appSettings.set_ShowStatusBar( true);

        // Save the new settings.
        appSettings.Close();
    } //main
} //Test

// Store and retrieve application settings.
class AppSettings
{
    private String fileName = "AppSettings#@@#.dat";
    private float aspectRatio;
    private String lookupDir;
    private int autoSaveTime;
    private boolean showStatusBar;

    /** @property 
     */
    public float get_AspectRatio()
    {
        return aspectRatio ;
    }//get_AspectRatio

    /** @property 
     */
    public void set_AspectRatio ( float
 value )
    {
        aspectRatio = value;
    }//set_AspectRatio

    /** @property 
     */
    public String get_LookupDir()
    {
        return lookupDir ;
    }//get_LookupDir

    /** @property 
     */
    public void set_LookupDir ( String value
 )
    {
        lookupDir = value;
    }//set_LookupDir

    /** @property
     */
    public int get_AutoSaveTime()
    {
        return autoSaveTime ;
    }//get_AutoSaveTime

    /** @property
     */
    public void set_AutoSaveTime ( int
 value )
    {
        autoSaveTime = value;
    }//set_AutoSaveTime

    /** @property
     */
    public boolean get_ShowStatusBar()
    {
        return showStatusBar ;
    }//get_ShowStatusBar

    /** @property
     */
    public void set_ShowStatusBar ( boolean
 value )
    {
        showStatusBar = value;
    }//set_ShowStatusBar
   
    public AppSettings()
    {
        // Create default application settings.
        aspectRatio = 1.3333F;
        lookupDir = "C:\\AppDirectory";
        autoSaveTime = 30;
        showStatusBar = false;

        if ( File.Exists(fileName) ) {
            BinaryReader binReader =
                new BinaryReader(File.Open(fileName, FileMode.Open));
            try {
                // If the file is not empty, 
                // read the application settings.
                if ( binReader.PeekChar() !=-1  ) {
                    aspectRatio = binReader.ReadSingle();
                    lookupDir = binReader.ReadString();
                    autoSaveTime = binReader.ReadInt32();
                    showStatusBar = binReader.ReadBoolean();
                }
            }

            // If the end of the stream is reached before reading
            // the four data values, ignore the error and use the
            // default settings for the remaining values.
            catch(EndOfStreamException e) {
                Console.WriteLine("{0} caught and ignored. "
                    + "Using default values.", e.GetType().get_Name());
            }
            finally {
                binReader.Close();
            }
        }
    } //AppSettings
   
    // Create a file and store the application settings.
    public void Close()
    {
        BinaryWriter binWriter = 
            new BinaryWriter(File.Open(fileName, FileMode.Create));
        try {
            binWriter.Write(aspectRatio);
            binWriter.Write(lookupDir);
            binWriter.Write(autoSaveTime);
            binWriter.Write(showStatusBar);
        }
        finally {
            if ( binWriter != null ) {
                binWriter= null;
            }
        }
    } //Close 
} //AppSettings
継承階層継承階層
System.Object
  System.IO.BinaryReader
スレッド セーフスレッド セーフ
この型の public static (Visual Basic では Shared) メンバはすべて、スレッド セーフです。インスタンス メンバ場合は、スレッド セーフであるとは限りません。
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照

BinaryReader コンストラクタ (Stream)

指定したストリームを基にし、UTF8Encoding を使用して、BinaryReader クラス新しインスタンス初期化します。

名前空間: System.IO
アセンブリ: mscorlib (mscorlib.dll 内)
構文構文

例外例外
例外種類条件

ArgumentException

ストリーム読み取りサポートしていないか、null 参照 (Visual Basic では Nothing) であるか、または既に閉じてます。

解説解説
使用例使用例

このコード例は、BinaryReader クラストピック取り上げているコード例一部分です。

Dim binReader As New BinaryReader(
 _
    File.Open(fileName, FileMode.Open))
Try

    ' If the file is not empty, 
    ' read the application settings.
    If binReader.PeekChar() <> -1 Then
        aspRatio   = binReader.ReadSingle()
        lkupDir     = binReader.ReadString()
        saveTime  = binReader.ReadInt32()
        statusBar = binReader.ReadBoolean()
        Return
    End If

' If the end of the stream is reached before reading
' the four data values, ignore the error and use the
' default settings for the remaining values.
Catch ex As EndOfStreamException
    Console.WriteLine("{0} caught and ignored. " &
 _ 
        "Using default values.", ex.GetType().Name)
Finally
    binReader.Close()
End Try
BinaryReader binReader = 
    new BinaryReader(File.Open(fileName, FileMode.Open));
try
{
    // If the file is not empty, 
    // read the application settings.
    if(binReader.PeekChar() != -1)
    {
        aspectRatio   = binReader.ReadSingle();
        lookupDir     = binReader.ReadString();
        autoSaveTime  = binReader.ReadInt32();
        showStatusBar = binReader.ReadBoolean();
    }
}

// If the end of the stream is reached before reading
// the four data values, ignore the error and use the
// default settings for the remaining values.
catch(EndOfStreamException e)
{
    Console.WriteLine("{0} caught and ignored. " + 
        "Using default values.", e.GetType().Name);
}
finally
{
    binReader.Close();
}
BinaryReader^ binReader = gcnew BinaryReader( File::Open( fileName, FileMode::Open
 ) );
try
{
   
   // If the file is not empty, 
   // read the application settings.
   if ( binReader->PeekChar() != -1 )
   {
      aspectRatio = binReader->ReadSingle();
      lookupDir = binReader->ReadString();
      autoSaveTime = binReader->ReadInt32();
      showStatusBar = binReader->ReadBoolean();
      return;
   }
}
// If the end of the stream is reached before reading
// the four data values, ignore the error and use the
// default settings for the remaining values.
catch ( EndOfStreamException^ e ) 
{
   Console::WriteLine( "{0} caught and ignored. "
   "Using default values.", e->GetType()->Name
 );
}
finally
{
   binReader->Close();
}


BinaryReader binReader =
    new BinaryReader(File.Open(fileName, FileMode.Open));
try {
    // If the file is not empty, 
    // read the application settings.
    if ( binReader.PeekChar() !=-1  ) {
        aspectRatio = binReader.ReadSingle();
        lookupDir = binReader.ReadString();
        autoSaveTime = binReader.ReadInt32();
        showStatusBar = binReader.ReadBoolean();
    }
}

// If the end of the stream is reached before reading
// the four data values, ignore the error and use the
// default settings for the remaining values.
catch(EndOfStreamException e) {
    Console.WriteLine("{0} caught and ignored. "
        + "Using default values.", e.GetType().get_Name());
}
finally {
    binReader.Close();
}
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照

BinaryReader コンストラクタ (Stream, Encoding)

供給されストリーム特定の文字エンコーディング基づいて、BinaryReader クラス新しインスタンス初期化します。

名前空間: System.IO
アセンブリ: mscorlib (mscorlib.dll 内)
構文構文

例外例外
例外種類条件

ArgumentException

ストリーム読み取りサポートしていないか、null 参照 (Visual Basic では Nothing) であるか、または既に閉じてます。

ArgumentNullException

encodingnull 参照 (Visual Basic では Nothing) です。

解説解説
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照

BinaryReader コンストラクタ


BinaryReader プロパティ


BinaryReader メソッド


パブリック メソッドパブリック メソッド

( プロテクト メソッド参照)
  名前 説明
パブリック メソッド Close 現在のリーダーと基になるストリームクローズます。
パブリック メソッド Equals  オーバーロードされます2 つObject インスタンス等しかどうか判断します。 ( Object から継承されます。)
パブリック メソッド GetHashCode  特定の型のハッシュ関数として機能します。GetHashCode は、ハッシュ アルゴリズムや、ハッシュ テーブルのようなデータ構造での使用適してます。 ( Object から継承されます。)
パブリック メソッド GetType  現在のインスタンスType取得します。 ( Object から継承されます。)
パブリック メソッド PeekChar 読み取り可能な次の文字返しますバイト位置または文字位置変化しません。
パブリック メソッド Read オーバーロードされます。 基になるストリームから文字読み取りストリーム現在位置進めます
パブリック メソッド ReadBoolean 現在のストリームから Boolean 値を読み取りストリーム現在位置1 バイトだけ進めます
パブリック メソッド ReadByte 現在のストリームから次のバイト読み取りストリーム現在位置1 バイトだけ進めます
パブリック メソッド ReadBytes 現在のストリームからバイト配列count指定したバイト数分バイト読み取りcount指定したバイト数だけ現在位置進めます
パブリック メソッド ReadChar 現在のストリーム次の文字読み取り使用した Encodingストリームから読み取った特定の文字に従ってストリーム現在位置進めます
パブリック メソッド ReadChars 現在のストリームから count指定した文字数分の文字読み取り、そのデータ文字配列として返します使用した Encodingストリームから読み取った特定の文字に従って現在位置進めます
パブリック メソッド ReadDecimal 現在のストリームから 10 進数値を読み取りストリーム現在位置16 バイトだけ進めます
パブリック メソッド ReadDouble 現在のストリームから 8 バイト浮動小数点値を読み取りストリーム現在位置を 8 バイトだけ進めます
パブリック メソッド ReadInt16 現在のストリームから 2 バイト符号付き整数読み取りストリーム現在位置2 バイトだけ進めます
パブリック メソッド ReadInt32 現在のストリームから 4 バイト符号付き整数読み取りストリーム現在位置を 4 バイトだけ進めます
パブリック メソッド ReadInt64 現在のストリームから 8 バイト符号付き整数読み取りストリーム現在位置を 8 バイトだけ進めます
パブリック メソッド ReadSByte 現在のストリームから符号付きバイト読み取りストリーム現在位置1 バイトだけ進めます
パブリック メソッド ReadSingle 現在のストリームから 4 バイト浮動小数点値を読み取りストリーム現在位置を 4 バイトだけ進めます
パブリック メソッド ReadString 現在のストリームから文字列読み取ります。文字列先頭長さ付け、7 ビット整数としてまとめてエンコードます。
パブリック メソッド ReadUInt16 リトル エンディアン エンコーディング使用して現在のストリームから 2 バイト符号なし整数読み取りストリーム位置2 バイトだけ進めます
パブリック メソッド ReadUInt32 現在のストリームから 4 バイト符号なし整数読み取りストリーム位置を 4 バイトだけ進めます
パブリック メソッド ReadUInt64 現在のストリームから 8 バイト符号なし整数読み取りストリーム位置を 8 バイトだけ進めます
パブリック メソッド ReferenceEquals  指定した複数Object インスタンス同一かどうか判断します。 ( Object から継承されます。)
パブリック メソッド ToString  現在の Object を表す String返します。 ( Object から継承されます。)
プロテクト メソッドプロテクト メソッド
明示的インターフェイスの実装明示的インターフェイス実装
  名前 説明
インターフェイスの明示的な実装 System.IDisposable.Dispose BinaryWriter によって使用されているすべてのリソース解放します。
参照参照

BinaryReader メンバ

プリミティブ データ型特定のエンコーディングバイナリ値として読み取ります。

BinaryReader データ型公開されるメンバを以下の表に示します


パブリック コンストラクタパブリック コンストラクタ
パブリック プロパティパブリック プロパティ
  名前 説明
パブリック プロパティ BaseStream BinaryReader の基になるストリームへのアクセス公開します
パブリック メソッドパブリック メソッド
( プロテクト メソッド参照)
  名前 説明
パブリック メソッド Close 現在のリーダーと基になるストリームクローズます。
パブリック メソッド Equals  オーバーロードされます2 つObject インスタンス等しかどうか判断します。 (Object から継承されます。)
パブリック メソッド GetHashCode  特定の型のハッシュ関数として機能します。GetHashCode は、ハッシュ アルゴリズムや、ハッシュ テーブルのようなデータ構造での使用適してます。 (Object から継承されます。)
パブリック メソッド GetType  現在のインスタンスType取得します。 (Object から継承されます。)
パブリック メソッド PeekChar 読み取り可能な次の文字返しますバイト位置または文字位置変化しません。
パブリック メソッド Read オーバーロードされます。 基になるストリームから文字読み取りストリーム現在位置進めます
パブリック メソッド ReadBoolean 現在のストリームから Boolean 値を読み取りストリーム現在位置1 バイトだけ進めます
パブリック メソッド ReadByte 現在のストリームから次のバイト読み取りストリーム現在位置1 バイトだけ進めます
パブリック メソッド ReadBytes 現在のストリームからバイト配列count指定したバイト数分バイト読み取りcount指定したバイト数だけ現在位置進めます
パブリック メソッド ReadChar 現在のストリーム次の文字読み取り使用した Encodingストリームから読み取った特定の文字に従ってストリーム現在位置進めます
パブリック メソッド ReadChars 現在のストリームから count指定した文字数分の文字読み取り、そのデータ文字配列として返します使用した Encodingストリームから読み取った特定の文字に従って現在位置進めます
パブリック メソッド ReadDecimal 現在のストリームから 10 進数値を読み取りストリーム現在位置16 バイトだけ進めます
パブリック メソッド ReadDouble 現在のストリームから 8 バイト浮動小数点値を読み取りストリーム現在位置を 8 バイトだけ進めます
パブリック メソッド ReadInt16 現在のストリームから 2 バイト符号付き整数読み取りストリーム現在位置2 バイトだけ進めます
パブリック メソッド ReadInt32 現在のストリームから 4 バイト符号付き整数読み取りストリーム現在位置を 4 バイトだけ進めます
パブリック メソッド ReadInt64 現在のストリームから 8 バイト符号付き整数読み取りストリーム現在位置を 8 バイトだけ進めます
パブリック メソッド ReadSByte 現在のストリームから符号付きバイト読み取りストリーム現在位置1 バイトだけ進めます
パブリック メソッド ReadSingle 現在のストリームから 4 バイト浮動小数点値を読み取りストリーム現在位置を 4 バイトだけ進めます
パブリック メソッド ReadString 現在のストリームから文字列読み取ります。文字列先頭長さ付け、7 ビット整数としてまとめてエンコードます。
パブリック メソッド ReadUInt16 リトル エンディアン エンコーディング使用して現在のストリームから 2 バイト符号なし整数読み取りストリーム位置2 バイトだけ進めます
パブリック メソッド ReadUInt32 現在のストリームから 4 バイト符号なし整数読み取りストリーム位置を 4 バイトだけ進めます
パブリック メソッド ReadUInt64 現在のストリームから 8 バイト符号なし整数読み取りストリーム位置を 8 バイトだけ進めます
パブリック メソッド ReferenceEquals  指定した複数Object インスタンス同一かどうか判断します。 (Object から継承されます。)
パブリック メソッド ToString  現在の Object を表す String返します。 (Object から継承されます。)
プロテクト メソッドプロテクト メソッド
明示的インターフェイスの実装明示的インターフェイス実装
  名前 説明
インターフェイスの明示的な実装 System.IDisposable.Dispose BinaryWriter によって使用されているすべてのリソース解放します。
参照参照


このページでは「.NET Framework クラス ライブラリ リファレンス」からBinaryReaderを検索した結果を表示しています。
Weblioに収録されているすべての辞書からBinaryReaderを検索する場合は、下記のリンクをクリックしてください。
 全ての辞書からBinaryReader を検索

英和和英テキスト翻訳>> Weblio翻訳
英語⇒日本語日本語⇒英語
  

辞書ショートカット

すべての辞書の索引

「BinaryReader」の関連用語

BinaryReaderのお隣キーワード
検索ランキング

   

英語⇒日本語
日本語⇒英語
   



BinaryReaderのページの著作権
Weblio 辞書 情報提供元は 参加元一覧 にて確認できます。

   
日本マイクロソフト株式会社日本マイクロソフト株式会社
© 2024 Microsoft.All rights reserved.

©2024 GRAS Group, Inc.RSS