DSConnect {DatastreamR}R Documentation

initializer

Description

initializer

initializer

Public fields

Config

: config file path

Username

: Your id

Password

: Your Password

Proxies

: Proxy Server details (if any)

SslCert

: ssl Certifactes file path

Url

: internal parameter set by application

RequestUrl

: internal parameter set up by application

Token

: Token received on successfull logon

TokenExpiry

: Expiry time of the token

Timeout

: Max Timeout set in Configuartion for the process to complete

Version

: Application Version

AppID

: Application Id

Methods

Public methods


Method new()

DSConnect connects to the Datastream web service on behalf of derived classes and helps to send and retrieve data

DSConnect connects to the Datastream web service on behalf of derived classes

Usage
DSConnect$new(
  config = NULL,
  username = NA,
  password = NA,
  proxies = NULL,
  sslCert = NULL,
  service = NULL
)
Arguments
config

: config path

username

: your username

password

: your password

proxies

: proxy url, if any

sslCert

: path to ssl cert file

service

: internally set by the application

Details

user details can be supplied from a config file or passed directly as parameters in the constructor of the derived user object type class.

   1) Using ini file (e.g. config.ini) with format

   [credentials]
   username=YourID
   password=YourPwd

   [proxies]
   url=Your Proxy Url
   port=Proxy port
   username=Proxy Username
   password=Proxy Password

   [cert]
   sslCertFile=YourCertFile
   #only read if no sslCertFile entry
   sslCertPath=YourCertPath

Method getJsonResponse()

This method makes the query against the API service and does some basic error handling

Usage
DSConnect$getJsonResponse(requestUrl, request)
Arguments
requestUrl

: Url used to send the Post request

request

: Raw Datastream request


Method getToken()

getToken uses you credentials to try and obtain a token to be used in subsequent request for data. The returned token is valid for 24 hours

Usage
DSConnect$getToken()

Method IsValid()

IsValid checks whether the token is valid against the token expiry time

Usage
DSConnect$IsValid()

Method CheckToken()

CheckToken checks whether the token is valid against the token expiry time and generates new token if the token has expired.

Usage
DSConnect$CheckToken()

Method clone()

The objects of this class are cloneable with this method.

Usage
DSConnect$clone(deep = FALSE)
Arguments
deep

Whether to make a deep clone.


[Package DatastreamR version 2.0.4 Index]