C# 클래스 NContrib.Extensions.StreamExtensions

파일 보기 프로젝트 열기: veracross/ncontrib

공개 메소드들

메소드 설명
GetMime ( this stream ) : string

Use MIME magic to find the MIME type for this stream.

256 bytes (or the total number of bytes in the stream if 256 are not available) are read from the current stream location to detect the MIME type. If the stream support seeking, the stream position will be moved back after the sample is taken.

ReadAllBytes ( this stream, int bufferSize = 32768 ) : byte[]

Reads the entire contents of a stream into a byte array

메소드 상세

GetMime() 공개 정적인 메소드

Use MIME magic to find the MIME type for this stream.
256 bytes (or the total number of bytes in the stream if 256 are not available) are read from the current stream location to detect the MIME type. If the stream support seeking, the stream position will be moved back after the sample is taken.
public static GetMime ( this stream ) : string
stream this
리턴 string

ReadAllBytes() 공개 정적인 메소드

Reads the entire contents of a stream into a byte array
public static ReadAllBytes ( this stream, int bufferSize = 32768 ) : byte[]
stream this
bufferSize int
리턴 byte[]