C# Class Pchp.Library.Streams.SocketStream

An implementation of PhpStream as an encapsulation of System.Net.Socket transports.
Inheritance: PhpStream
Mostrar archivo Open project: iolevel/peachpie

Protected Properties

Property Type Description
eof bool
socket System.Net.Sockets.Socket

Public Methods

Method Description
GetValid ( PhpResource handle ) : SocketStream
SetParameter ( StreamParameterOptions option, PhpValue value ) : bool
SocketStream ( Context ctx, Socket socket, string openedPath, StreamContext context, bool isAsync = false ) : Pchp.Core

Protected Methods

Method Description
FreeManaged ( ) : void

PhpResource.FreeManaged overridden to get rid of the contained context on Dispose.

RawFlush ( ) : bool
RawRead ( byte buffer, int offset, int count ) : int
RawWrite ( byte buffer, int offset, int count ) : int

Method Details

FreeManaged() protected method

PhpResource.FreeManaged overridden to get rid of the contained context on Dispose.
protected FreeManaged ( ) : void
return void

GetValid() public static method

public static GetValid ( PhpResource handle ) : SocketStream
handle Pchp.Core.PhpResource
return SocketStream

RawFlush() protected method

protected RawFlush ( ) : bool
return bool

RawRead() protected method

protected RawRead ( byte buffer, int offset, int count ) : int
buffer byte
offset int
count int
return int

RawWrite() protected method

protected RawWrite ( byte buffer, int offset, int count ) : int
buffer byte
offset int
count int
return int

SetParameter() public method

public SetParameter ( StreamParameterOptions option, PhpValue value ) : bool
option StreamParameterOptions
value Pchp.Core.PhpValue
return bool

SocketStream() public method

public SocketStream ( Context ctx, Socket socket, string openedPath, StreamContext context, bool isAsync = false ) : Pchp.Core
ctx Pchp.Core.Context
socket System.Net.Sockets.Socket
openedPath string
context StreamContext
isAsync bool
return Pchp.Core

Property Details

eof protected_oe property

Result of the last read/write operation.
protected bool eof
return bool

socket protected_oe property

The encapsulated network socket.
protected Socket,System.Net.Sockets socket
return System.Net.Sockets.Socket