The Connect method is used to establish a connection to the FileRepositoryService in the server machine.
Namespace – ABSuite.AccessLayer.Connector.Core
Assembly – Unisys.ABSuite.AccessLayer.Connector.Core (in Unisys.ABSuite.AccessLayer.Connector.Core.dll)
Syntax
bool Connect(
FileRepositoryConnectionDetails details
)
Argument
details – ABSuite.AccessLayer.Connector.Core.FileRepositoryConnectionDetails
This argument provides the connection details for the FileRepositoryService.
Refer to the details argument in the Connect() method of the IConnection interface for more information.
Return Value
If this method succeeds in establishing a connection, it returns true; otherwise, it returns false.
Using the IFileRepositoryService Interface for the Connect Method
The following code is an example of using the Connect method to establish a connection with the FileRepositoryService:
// Declare the FileRepositoryService IFileRepositoryService fileRepos = FileRepositoryServiceFactory.Create(); // Specify the connection details for the repository access ConnectionDetails fDetails = new ConnectionDetails(); fDetails.FileRepositoryDirectory = "\\\\MyMachineName\\FREPOS"; // Connect to the File Repository Service fileRepos.Connect(fDetails);