Writes all discovery documents, XML Schema Definition (XSD) schemas, and Service Descriptions in the DiscoveryClientProtocol.Documents property to the supplied directory and creates a file in that directory.
- directory
- The directory in which to save all documents currently in the DiscoveryClientProtocol.Documents property.
- topLevelFilename
- The name of the file to create or overwrite containing a map of all documents saved.
A System.Web.Services.Discovery.DiscoveryClientResultCollection containing the results of all files saved.
The file created with the name of the topLevelFilename parameter in the directory specified by the directory parameter contains a map of saved discovery documents, XML Schema Definition (XSD) schemas and service descriptions. This file can be read in using the DiscoveryClientProtocol.ReadAll(string) method to populate the DiscoveryClientProtocol.References and DiscoveryClientProtocol.Documents properties. The format of the file is XML containing an serialized version of the System.Web.Services.Discovery.DiscoveryClientProtocol.DiscoveryClientResultsFile class.
If a file exists with the same name as the topLevelFilename parameter in the directory parameter, that file is overwritten by the DiscoveryClientProtocol.WriteAll(string, string) method. The topLevelFilename parameter must include the fully qualified path if the file does not exist in the current directory.