dxFeed .Net API  7.1.0
dxFeed .Net API library intended to provide market data access for DX clients
com.dxfeed.ipf.InstrumentProfileReader Class Reference

Reads instrument profiles from the stream using Simple File Format. Please see Instrument Profile Format documentation for complete description. This reader automatically uses data formats as specified in the stream. Use InstrumentProfileConnection if support for streaming updates of instrument profiles is needed. More...

Public Member Functions

DateTime GetLastModified ()
 Returns last modification time (in milliseconds) from last ReadFromFile operation or zero if it is unknown. More...
 
IList< InstrumentProfileReadFromFile (string address)
 Reads and returns instrument profiles from specified file. This method recognizes popular data compression formats "zip" and "gzip" by analyzing file name. If file name ends with ".zip" then all compressed files will be read independently one by one in their order of appearing and total concatenated list of instrument profiles will be returned. If file name ends with ".gz" then compressed content will be read and returned. In other cases file will be considered uncompressed and will be read as is. More...
 
IList< InstrumentProfileReadFromFile (string address, string user, string password)
 Reads and returns instrument profiles from specified address with a specified basic user and password credentials. This method recognizes popular data compression formats "zip" and "gzip" by analyzing file name. If file name ends with ".zip" then all compressed files will be read independently one by one in their order of appearing and total concatenated list of instrument profiles will be returned. If file name ends with ".gz" then compressed content will be read and returned. In other cases file will be considered uncompressed and will be read as is. More...
 
IList< InstrumentProfileReadFromFile (string address, string token)
 Reads and returns instrument profiles from specified address with a specified token. This method recognizes popular data compression formats "zip" and "gzip" by analyzing file name. If file name ends with ".zip" then all compressed files will be read independently one by one in their order of appearing and total concatenated list of instrument profiles will be returned. If file name ends with ".gz" then compressed content will be read and returned. In other cases file will be considered uncompressed and will be read as is. More...
 
IList< InstrumentProfileRead (Stream inputStream, string name)
 Reads and returns instrument profiles from specified stream using specified name to select data compression format. This method recognizes popular data compression formats "zip" and "gzip" by analyzing file name. If file name ends with ".zip" then all compressed files will be read independently one by one in their order of appearing and total concatenated list of instrument profiles will be returned. If file name ends with ".gz" then compressed content will be read and returned. In other cases file will be considered uncompressed and will be read as is. More...
 
IList< InstrumentProfileRead (Stream inputStream)
 Reads and returns instrument profiles from specified stream. More...
 

Static Public Member Functions

static string ResolveSourceUrl (string address)
 Converts a specified string address specification into an URL that will be read by ReadFromFile method using URLInputStream. More...
 

Detailed Description

Reads instrument profiles from the stream using Simple File Format. Please see Instrument Profile Format documentation for complete description. This reader automatically uses data formats as specified in the stream. Use InstrumentProfileConnection if support for streaming updates of instrument profiles is needed.

Member Function Documentation

◆ GetLastModified()

DateTime com.dxfeed.ipf.InstrumentProfileReader.GetLastModified ( )
inline

Returns last modification time (in milliseconds) from last ReadFromFile operation or zero if it is unknown.

Returns
Last modification time (in milliseconds)

◆ Read() [1/2]

IList<InstrumentProfile> com.dxfeed.ipf.InstrumentProfileReader.Read ( Stream  inputStream,
string  name 
)
inline

Reads and returns instrument profiles from specified stream using specified name to select data compression format. This method recognizes popular data compression formats "zip" and "gzip" by analyzing file name. If file name ends with ".zip" then all compressed files will be read independently one by one in their order of appearing and total concatenated list of instrument profiles will be returned. If file name ends with ".gz" then compressed content will be read and returned. In other cases file will be considered uncompressed and will be read as is.

Parameters
inputStreamStream from which read profiles.
nameProfile name.
Returns
Instrument profile list.
Exceptions
ArgumentExceptionStream does not support reading.
ArgumentNullExceptionStream is null.
IOExceptionIf an I/O error occurs.
InstrumentProfileFormatExceptionIf input stream does not conform to the Simple File Format.

◆ Read() [2/2]

IList<InstrumentProfile> com.dxfeed.ipf.InstrumentProfileReader.Read ( Stream  inputStream)
inline

Reads and returns instrument profiles from specified stream.

Parameters
inputStreamStream from which read profiles.
Returns
Instrument profiles from specified stream.
Exceptions
ArgumentExceptionStream does not support reading.
ArgumentNullExceptionStream is null.
IOExceptionIf an I/O error occurs.
InstrumentProfileFormatExceptionIf input stream does not conform to the Simple File Format.

◆ ReadFromFile() [1/3]

IList<InstrumentProfile> com.dxfeed.ipf.InstrumentProfileReader.ReadFromFile ( string  address)
inline

Reads and returns instrument profiles from specified file. This method recognizes popular data compression formats "zip" and "gzip" by analyzing file name. If file name ends with ".zip" then all compressed files will be read independently one by one in their order of appearing and total concatenated list of instrument profiles will be returned. If file name ends with ".gz" then compressed content will be read and returned. In other cases file will be considered uncompressed and will be read as is.

Authentication information can be supplied to this method as part of URL user info like "http://user:password@host:port/path/file.ipf".

This is a shortcut for ReadFromFile(address, null, null).

This operation updates GetLastModified().

Parameters
addressURL of file to read from.
Returns
List of instrument profiles.
Exceptions
IOExceptionIf an I/O error occurs.
InstrumentProfileFormatExceptionIf input stream does not conform to the Simple File Format.

◆ ReadFromFile() [2/3]

IList<InstrumentProfile> com.dxfeed.ipf.InstrumentProfileReader.ReadFromFile ( string  address,
string  user,
string  password 
)
inline

Reads and returns instrument profiles from specified address with a specified basic user and password credentials. This method recognizes popular data compression formats "zip" and "gzip" by analyzing file name. If file name ends with ".zip" then all compressed files will be read independently one by one in their order of appearing and total concatenated list of instrument profiles will be returned. If file name ends with ".gz" then compressed content will be read and returned. In other cases file will be considered uncompressed and will be read as is.

Specified user and password take precedence over authentication information that is supplied to this method as part of URL user info like "http://user:password@host:port/path/file.ipf".

This operation updates GetLastModified().

Parameters
addressURL of file or service output to read from.
userThe user name (may be null).
passwordThe password (may be null).
Returns
List of instrument profiles.
Exceptions
IOExceptionIf an I/O error occurs.
InstrumentProfileFormatExceptionIf input stream does not conform to the Simple File Format.

◆ ReadFromFile() [3/3]

IList<InstrumentProfile> com.dxfeed.ipf.InstrumentProfileReader.ReadFromFile ( string  address,
string  token 
)
inline

Reads and returns instrument profiles from specified address with a specified token. This method recognizes popular data compression formats "zip" and "gzip" by analyzing file name. If file name ends with ".zip" then all compressed files will be read independently one by one in their order of appearing and total concatenated list of instrument profiles will be returned. If file name ends with ".gz" then compressed content will be read and returned. In other cases file will be considered uncompressed and will be read as is.

This operation updates GetLastModified().

Parameters
addressURL of file or service output to read from.
tokenThe bearer token.
Returns
List of instrument profiles.
Exceptions
IOExceptionIf an I/O error occurs.
InstrumentProfileFormatExceptionIf input stream does not conform to the Simple File Format.

◆ ResolveSourceUrl()

static string com.dxfeed.ipf.InstrumentProfileReader.ResolveSourceUrl ( string  address)
inlinestatic

Converts a specified string address specification into an URL that will be read by ReadFromFile method using URLInputStream.

Parameters
addressAddress to convert.
Returns
A new resolved URL.

The documentation for this class was generated from the following file: