public void Init() { PIWebApiClient client = PIWebApiClientGenerator.GenerateInstance(); instance = client.Configuration; configElement = AFObject.FindObject(Constants.PIWEBAPI_CONFIGURATION_ELEMENT_PATH) as AFElement; corsExpHeaders = configElement.Attributes[Constants.PIWEBAPI_CONFIGURATION_CORSEXPHEADERS].GetValue().Value.ToString(); corsMethods = configElement.Attributes[Constants.PIWEBAPI_CONFIGURATION_CORSMETHODS].GetValue().Value.ToString(); scanSearchInterval = configElement.Attributes[Constants.PIWEBAPI_CONFIGURATION_CORSEACHSCANINTERVALS].GetValue().ValueAsInt32(); corsMethodsAttribute = configElement.Attributes[Constants.PIWEBAPI_CONFIGURATION_CORSMETHODS]; }
/// <summary> /// Initialises a new instance of the <see cref="GenreApi"/> class. /// </summary> /// <param name="configurationApi">The configuration API.</param> public GenreApi(IConfigurationApi configurationApi) { _configurationApi = configurationApi; }
/// <summary> /// Initialises a new instance of the <see cref="MovieApi"/> class. /// </summary> /// <param name="configurationApi">The configuration API.</param> /// <param name="imageHelper">The image helper.</param> public MovieApi(IConfigurationApi configurationApi, ImageUrlHelper imageHelper) { _configurationApi = configurationApi; _imageHelper = imageHelper; }