C# Класс Pchp.Library.Streams.StreamContext

Resource type used for associating additional options with stream wrappers.
Stream Contexts are stored in a Resource to save useless deep-copying of the contained constant array.
Наследование: Pchp.Core.PhpResource
Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
Default StreamContext

Защищенные свойства (Protected)

Свойство Тип Описание
_data Pchp.Core.PhpArray
_parameters Pchp.Core.PhpArray

Открытые методы

Метод Описание
GetOption ( string scheme, string option ) : PhpValue

Gets a wrapper-specific option identified by the scheme and the option name.

GetValid ( PhpResource resource ) : StreamContext

Checks the context for validity, throws a warning it is not.

GetValid ( PhpResource resource, bool allowNull ) : StreamContext

Checks the context for validity, throws a warning it is not.

StreamContext ( ) : Pchp.Core

Create an empty StreamContext (allows lazy PhpArray instantiation).

StreamContext ( PhpArray data ) : Pchp.Core

Create a new context resource from an array of wrapper options.

Приватные методы

Метод Описание
StreamContext ( PhpArray data, bool registerInCtx ) : Pchp.Core

Create a new context resource from an array of wrapper options.

Описание методов

GetOption() публичный метод

Gets a wrapper-specific option identified by the scheme and the option name.
public GetOption ( string scheme, string option ) : PhpValue
scheme string The target wrapper scheme.
option string The option name.
Результат Pchp.Core.PhpValue

GetValid() публичный статический метод

Checks the context for validity, throws a warning it is not.
In case the context is invalid.
public static GetValid ( PhpResource resource ) : StreamContext
resource Pchp.Core.PhpResource Resource which should contain a StreamContext.
Результат StreamContext

GetValid() публичный статический метод

Checks the context for validity, throws a warning it is not.
In case the context is invalid.
public static GetValid ( PhpResource resource, bool allowNull ) : StreamContext
resource Pchp.Core.PhpResource Resource which should contain a StreamContext.
allowNull bool True to allow NULL context, that will be without any warning converted to Default .
Результат StreamContext

StreamContext() публичный метод

Create an empty StreamContext (allows lazy PhpArray instantiation).
public StreamContext ( ) : Pchp.Core
Результат Pchp.Core

StreamContext() публичный метод

Create a new context resource from an array of wrapper options.
public StreamContext ( PhpArray data ) : Pchp.Core
data Pchp.Core.PhpArray A 2-dimensional array of wrapper options
Результат Pchp.Core

Описание свойств

Default публичное статическое свойство

Default StreamContext. Cannot be null.
public static StreamContext,Pchp.Library.Streams Default
Результат StreamContext

_data защищенное свойство

protected PhpArray,Pchp.Core _data
Результат Pchp.Core.PhpArray

_parameters защищенное свойство

protected PhpArray,Pchp.Core _parameters
Результат Pchp.Core.PhpArray