EwfVolume Class (Standard 7 SP1)
7/8/2014
The EwfVolume class is used to change the configuration of an Enhanced Write Filter volume.
The following syntax is simplified from Managed Object Format (MOF) code and includes all of the inherited properties.
Syntax
class EwfVolume
{
string DriveLetter;
string Name;
};
Members
The EwfVolume class defines the following types of members:
- Methods
- Properties
Methods
The EwfVolume class defines the following methods.
Methods |
Description |
---|---|
Adds an overlay level for the specified protected volume. |
|
Clears any pending commands that would have occurred on the next restart. |
|
Commits all current level data in the overlay to the protected volume. |
|
Commits all current data in the overlay to the protected volume and then disables Enhanced Write Filter. For EWF RAM and RAM Reg overlays only. |
|
Commits a single file to the protected volume. The size of the file or its location must not have changed before the file is committed. |
|
Disables a currently enabled overlay for the specified protected volume. |
|
Enables a currently disabled overlay for the specified protected volume. |
|
Restores one overlay level for the specified protected volume, discarding all changes in the current level. |
|
Sets the overlay level on a protected volume. |
Properties
The EwfVolume class defines the following properties.
DriveLetter
Data type: string
Access type: Read-only
Returns the drive letter of the volume.
Name
Data type: string
Access type: Read-only
Qualifiers: Key
Returns the name of the volume.
Example
This example can be used to list all the methods for EwfVolume.
Windows PowerShell
$ComputerName = "localhost" # or "remote-machine-name"
$Namespace = "root\Microsoft\WriteFilters"
$Class = "EwfVolume"
Write-Host "Retrieving EWF volume methods..."
Get-WmiObject `
-ComputerName $ComputerName `
-Namespace $Namespace `
-Class $Class `
| Get-Member * | Format-List Name, Definition
VBScript
strComputer = "localhost" ' or "remote-machine-name"
strNamespace = "\root\Microsoft\WriteFilters"
strClass = "EwfVolume"
WScript.Echo "Retrieving EWF volume methods..."
On Error Resume Next
Set EwfVolume = GetObject("WINMGMTS:\\" & strComputer & strNamespace & ":" & strClass)
If Err.number <> 0 Then
WScript.Echo "Method exited with error code: 0x" & Hex(Err.number)
WScript.Echo Err.source & " - " & Err.Description
WScript.Quit(1)
End If
For Each M In EwfVolume.Methods_
WScript.Echo "Method: ", M.Name
WScript.Echo "Description: ", M.Qualifiers_("Description")
If (M.InParameters Is Nothing) Then
WScript.Echo "No input parameters"
Else
For Each Param In M.InParameters.Properties_
WScript.Echo "Parameter Name: ", Param.Name
WScript.Echo "Parameter Type: ", TypeName(Param.CIMType)
Next
End If
Next
Function GetTypeName(typeNumber)
Select Case typeNumber
Case 2 GetTypeName = "16 bit Integer"
Case 3 GetTypeName = "32 bit Integer"
Case 4 GetTypeName = "32 bit Real Number"
Case 5 GetTypeName = "64 bit Real Number"
Case 8 GetTypeName = "String"
Case 11 GetTypeName = "Boolean"
Case 13 GetTypeName = "CIM Object"
Case 16 GetTypeName = "signed 8 bit Integer"
Case 17 GetTypeName = "unsigned 8 bit Integer"
Case 18 GetTypeName = "unsigned 16 bit Integer"
Case 19 GetTypeName = "unsigned 32 bit Integer"
Case 20 GetTypeName = "signed 64 bit Integer"
Case 21 GetTypeName = "unsigned 64 bit Integer"
Case 101 GetTypeName = "Date/time value"
Case 103 GetTypeName = "16 bit Char"
Case Else
GetTypeName = "Not supported"
End Select
End Function
Requirements
Supported clients |
Windows XP Embedded SP3 |
MOF |
EWFProvider.mof |
Namespace |
\root\Microsoft\WriteFilters |