Filters

Prev Next

Get-LiquitFilter

Synopsis

This command displays a list of filters belonging to a filter set.

Syntax

 Get-LiquitFilter 
    [-FilterSet] <FilterSet> 
    [-LiquitContext <LiquitContext>]  
    [<CommonParameters>]

 Get-LiquitFilter 
    [-FilterSet] <FilterSet> 
    [-Type] <string[]> 
    [-LiquitContext <LiquitContext>]  
    [<CommonParameters>]

 Get-LiquitFilter 
    [-FilterSet] <FilterSet> 
    [-ID] <guid[]> 
    [-LiquitContext <LiquitContext>]  
    [<CommonParameters>]

 Get-LiquitFilter 
    [-FilterSet] <FilterSet> 
    [-EntityRef] <EntityRef[]> 
    [-LiquitContext <LiquitContext>]  
    [<CommonParameters>]

Examples

Example 1: Get-LiquitFilter

 $package = Get-LiquitPackage -id 00000000-0000-0000-0000-000000000000
 $snapshot = Get-LiquitPackageSnapshot -id 00000000-0000-0000-0000-000000000000 -package $package
 $filterset  = Get-LiquitFilterSet -Snapshot $snapshot -id 00000000-0000-0000-0000-000000000000
 $filter = Get-LiquitFilter -FilterSet $filterset

This command lists all filters belonging to the specified filter set.

Example 2: Get-LiquitFilter

 $package = Get-LiquitPackage -id 00000000-0000-0000-0000-000000000000
 $snapshot = Get-LiquitPackageSnapshot -id 00000000-0000-0000-0000-000000000000 -package $package
 $filterset  = Get-LiquitFilterSet -Snapshot $snapshot -id 00000000-0000-0000-0000-000000000000
 $filter = Get-LiquitFilter -FilterSet $filterset -type subnet

This command will display all the filters belonging to the specified filter set of the Subnet type.

New-LiquitFilter

Synopsis

This command creates a new filter.

Syntax

 New-LiquitFilter 
    [-FilterSet] <FilterSet[]> 
    [-Type] <string> 
    [-Operator {Equal | NotEqual | Contains | NotContains | StartsWith | EndsWith | GreaterThan | LessThan}] 
    [-Value <string>]
    [-Context {Device | User}]
    [-Settings <hashtable>] 
    [-LiquitContext <LiquitContext>] 
    [-WhatIf] 
    [-Confirm]  
    [<CommonParameters>]

Example

 $package = Get-LiquitPackage -id 00000000-0000-0000-0000-000000000000
 $snapshot = Get-LiquitPackageSnapshot -id 00000000-0000-0000-0000-000000000000 -package $package
 $filterset = New-LiquitFilterSet -Snapshot $snapshot
 new-LiquitFilter -FilterSet $filterset -type fileexists -Settings @{path = "C:\windows\settings.ini"} -Value "True"

This command creates a new filter in the selected filter set.

Parameters

Name Value Description Required Default value
FilterSet <FilterSet[]> The filter set where the filter needs to be added. Entityfilter only
Type <string> The type of filter you want to apply. Yes
Operator {Equal | NotEqual | Contains | NotContains | StartsWith | EndsWith | GreaterThan | LessThan} The operator used to evaluate the filter. No
Value <string> Determines whether the filter set should be true or not. Yes
Context {Device | User} Define when a package is available for a user/device. Device
Settings <hashtable> The settings for the filter.
LiquitContext <LiquitContext> Determines the selected zone. No Default

Remove-LiquitFilter

Synopsis

This command removes a filter from the Application Workspace.

Syntax

  Remove-LiquitFilter 
    [-Filter] <Filter[]> 
    [-LiquitContext <LiquitContext>] 
    [-WhatIf] 
    [-Confirm]  
    [<CommonParameters>]

Example

 $package = Get-LiquitPackage -id 00000000-0000-0000-0000-000000000000
 $snapshot = Get-LiquitPackageSnapshot -id 00000000-0000-0000-0000-000000000000 -package $package
 $actionset = Get-LiquitActionSet -Snapshot $snapshot
 $action = Get-LiquitAction -id 00000000-0000-0000-0000-000000000000 -ActionSet $actionset
 $filterset = Get-LiquitFilterSet -Action $action -id 00000000-0000-0000-0000-000000000000
 $filter = Get-LiquitFilter -FilterSet $filterset -id 00000000-0000-0000-0000-000000000000
 Remove-LiquitFilter -Filter $filter 

This command removes the selected filter from the Application Workspace.

Parameters

Name Value Description Required Default value
Filter <Filter[]> The filter(s) that should be removed. Yes
LiquitContext <LiquitContext> Determines the selected zone. No Default

Further reading

Filters