Mobile API Reference  MicroStrategy 2019
WebServerList Class Reference

#import <WebServerList.h>

Inheritance diagram for WebServerList:

Instance Methods

(void) - add:
 
(WebServerConfiguration *) - getWebServer:
 
(void) - remove:
 
(NSUInteger) - size
 
(NSInteger) - indexOfWebServer:
 
(MSIProjectConfiguration *) - getProjectConfiguration:
 
(MSIProjectConfiguration *) - getProjectConfigurationByProjectID:
 
(MSIProjectConfiguration *) - getProjectConfigurationByProjectName:
 
(WebServerConfiguration *) - getWebServerConfiguration:
 
(void) - clear
 
(BOOL- hasProjects
 

Class Methods

(WebServerConfiguration *) + newWebServerConfiguration
 

Detailed Description

A WebServerList holds all of the connection info for the web servers and their projects. This info is often set from a ConnectionInfo.plist file. It can be set programmatically as well.

Method Documentation

◆ add:()

- (void) add: (WebServerConfiguration *)  webserver

Use this method to add new webserver to the configuration.

Parameters
webServernew webServer
Exceptions
NSInvalidArgumentExceptionif the webserver is nil

◆ clear()

- (void) clear

Use this method to remove all the webservers

◆ getProjectConfiguration:()

- (MSIProjectConfiguration*) getProjectConfiguration: (MSIProjectInfo *)  project

Use this method to get the ProjectConfiguration from the ProjectInfo object. If it is not found, returns nil.

◆ getProjectConfigurationByProjectID:()

- (MSIProjectConfiguration*) getProjectConfigurationByProjectID: (NSString *)  projectID

Use this method to get the ProjectConfiguration from the ProjectID. If it is not found, returns nil.

◆ getProjectConfigurationByProjectName:()

- (MSIProjectConfiguration*) getProjectConfigurationByProjectName: (NSString *)  projectName

Use this method to get the ProjectConfiguration from the ProjectName. If it is not found, returns nil.

◆ getWebServer:()

- (WebServerConfiguration*) getWebServer: (NSInteger)  index

Use this method to get the webServer at index. If the index is < 0 or beyond the last webserver, an exception is thrown.

Parameters
indexindex of the webserver needed
Returns
webServer at index
Exceptions
NSRangeExceptionif the index is out of range

◆ getWebServerConfiguration:()

- (WebServerConfiguration*) getWebServerConfiguration: (WebServerInfo *)  server

Use this method to get the WebServerConfiguration from the WebServerInfo object. If it is not found, returns nil.

◆ hasProjects()

- (BOOL) hasProjects

Use this method to check whether any projects are available

◆ indexOfWebServer:()

- (NSInteger) indexOfWebServer: (WebServerConfiguration *)  webserver

Use this method to get the index of particular webServer. If it is not found, returns NSNotFound.

Parameters
webserverwebServer
Returns
index of webServer

◆ newWebServerConfiguration()

+ (WebServerConfiguration *) newWebServerConfiguration

Use this method to get new web server configuration

Returns
web server configuration

◆ remove:()

- (void) remove: (NSInteger)  index

Use this method to remove webserver

Parameters
indexindex of the webserver to be removed. If the index is < 0 or beyond the last webserver, an exception is thrown.
Exceptions
NSRangeExceptionif index is out of range

◆ size()

- (NSUInteger) size

Use this method to get the count of the webservers

Returns
webServer count