C# 클래스 GitSharp.Core.Util.IO

Input/Output utilities
파일 보기 프로젝트 열기: jagregory/GitSharp

공개 메소드들

메소드 설명
ReadFully ( FileInfo path ) : byte[]

Read an entire local file into memory as a byte array.

ReadFully ( FileInfo path, int max ) : byte[]

Read an entire local file into memory as a byte array.

ReadFully ( Stream fd, byte dst, int off, int len ) : void

Read the entire byte array into memory, or throw an exception.

ReadFully ( Stream fd, long pos, byte dst, int off, int len ) : void

Read the entire byte array into memory, or throw an exception.

skipFully ( Stream fd, long toSkip ) : void

Skip an entire region of an input stream. The input stream's position is moved forward by the number of requested bytes, discarding them from the input. This method does not return until the exact number of bytes requested has been skipped.

메소드 상세

ReadFully() 공개 정적인 메소드

Read an entire local file into memory as a byte array.
/// The file exists, but its contents cannot be read. ///
public static ReadFully ( FileInfo path ) : byte[]
path System.IO.FileInfo Location of the file to read.
리턴 byte[]

ReadFully() 공개 정적인 메소드

Read an entire local file into memory as a byte array.
/// The file exists, but its contents cannot be Read. ///
public static ReadFully ( FileInfo path, int max ) : byte[]
path System.IO.FileInfo Location of the file to read.
max int /// Maximum number of bytes to Read, if the file is larger than /// this limit an IOException is thrown. ///
리턴 byte[]

ReadFully() 공개 정적인 메소드

Read the entire byte array into memory, or throw an exception.
/// The stream ended before was fully populated. /// /// There was an error reading from the stream. ///
public static ReadFully ( Stream fd, byte dst, int off, int len ) : void
fd Stream Input stream to read the data from.
dst byte buffer that must be fully populated
off int position within the buffer to start writing to.
len int number of bytes that must be read.
리턴 void

ReadFully() 공개 정적인 메소드

Read the entire byte array into memory, or throw an exception.
/// The ended before the requested number of /// bytes were read. /// /// The does not supports seeking. /// /// There was an error reading from the stream. ///
public static ReadFully ( Stream fd, long pos, byte dst, int off, int len ) : void
fd Stream Stream to read the data from.
pos long Position to read from the file at.
dst byte Buffer that must be fully populated, [off, off+len].
off int position within the buffer to start writing to.
len int number of bytes that must be read.
리턴 void

skipFully() 공개 정적인 메소드

Skip an entire region of an input stream. The input stream's position is moved forward by the number of requested bytes, discarding them from the input. This method does not return until the exact number of bytes requested has been skipped.
/// The stream ended before the requested number of bytes were /// skipped. /// /// There was an error reading from the stream. ///
public static skipFully ( Stream fd, long toSkip ) : void
fd Stream The stream to skip bytes from.
toSkip long /// Total number of bytes to be discarded. Must be >= 0. ///
리턴 void