SASServer
public protocol SASServer : class
Public Interface to a SAS Server.
Instances are acquired by calling SASManager.verifySASServer()
or by calling SASManager.servers()
.
When a server is acquired by the SASManager API, it is retained, and made available across program
instances.
You can remove a SAS server by calling SASManager.removeSASServer()
.
Since
since 8.22-
The URL of this server.
Since
since 8.22Declaration
Swift
var url : URL?
-
Userid of the connection to this server. Can be nil if this server is connected as the guest user
Since
since 8.22Declaration
Swift
var userid : String?
-
The users password. Can be nil if connected as the guest user.
Since
since 8.22Declaration
Swift
var password : String?
-
Indicates if this server connected as guest.
Since
since 8.22Declaration
Swift
var guestMode : Bool
-
Indicates if this connection secure. secure is https (by default, port 443)
Since
since 8.22Declaration
Swift
var secure : Bool
-
Indicates if the
SASServer
automatically generates section previews for this report.Since
since 8.22Declaration
Swift
var generatesReportThumbnails : Bool
-
Connect to this server.
Since
since 8.22Declaration
Swift
func connect(_ completion : @escaping (_ error : NSError?) -> Void)
Parameters
completion
Completion block for the connection. The
error
will be nil if the connection is successful.Return Value
N/A
-
Get available reports.
Declaration
Swift
var subscribedReports : [SASReport]
Return Value
Array of reports
-
Get a report from its descriptor
Since
since 8.22Declaration
Swift
func getSubscribedReport(descriptor : SASReportDescriptor) -> SASReport?
Parameters
uniqueIdentifier
identifier for this report.
Return Value
report (nil if descriptor is invalid)
-
Subscribes to a report from the server.
Since
since 8.22Declaration
Swift
func subscribe( descriptor: SASReportDescriptor, completion : @escaping (_ report : SASReport?, _ error : NSError?) -> Void)
Parameters
descriptor
Descriptor for report.
completion
Callback for completion. either report or error will be nil.
-
Remove subscription to a report.
Since
since 8.22Declaration
Swift
func unsubscribe(descriptor:SASReportDescriptor)
Parameters
descriptor
Descriptor for report.