Class ResourceUtilities
Encapsulates methods for finding and extracting WebDriver resources.
public static class ResourceUtilities
- Inheritance
-
ResourceUtilities
- Inherited Members
Methods
GetResourceStream(string, string)
Gets a Stream that contains the resource to use.
public static Stream GetResourceStream(string fileName, string resourceId)
Parameters
fileName
stringA file name in the file system containing the resource to use.
resourceId
stringA string representing the resource name embedded in the executing assembly, if it is not found in the file system.
Returns
- Stream
A Stream from which the resource can be read.
Remarks
The GetResourceStream method searches for the specified resource using the following algorithm:
Exceptions
- WebDriverException
Thrown if neither the file nor the embedded resource can be found.
IsValidResourceName(string)
Returns a value indicating whether a resource exists with the specified ID.
public static bool IsValidResourceName(string resourceId)
Parameters
resourceId
stringID of the embedded resource to check for.