Skip to content

Compare Hashset

github-actions edited this page May 13, 2026 · 1 revision

external help file: ModernConveniences-help.xml Module Name: ModernConveniences online version: https://learn.microsoft.com/dotnet/api/system.collections.generic.hashset-1 schema: 2.0.0

Compare-Hashset

SYNOPSIS

Returns differences between sets.

SYNTAX

Compare-Hashset [-ReferenceObject] <Object> [-DifferenceObject] <Object> [-CaseInsensitive] [-ExcludeDifferent]
 [-IncludeEqual] [-ProgressAction <ActionPreference>] [<CommonParameters>]

DESCRIPTION

{{ Fill in the Description }}

EXAMPLES

EXAMPLE 1

Compare-Hashset @(1,2,4) @(2,3,4,5)

|Value SideIndicator |----- ------------- | 1 <= | 3 => | 5 =>

EXAMPLE 2

Compare-Hashset @(1,2,4) @(2,3,4,5) -IncludeEqual -ExcludeDifferent

|Value SideIndicator |----- ------------- | 2 == | 4 ==

PARAMETERS

-ReferenceObject

The base set to compare.

Type: Object
Parameter Sets: (All)
Aliases:

Required: True
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-DifferenceObject

The set to contrast with the base set.

Type: Object
Parameter Sets: (All)
Aliases:

Required: True
Position: 2
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-CaseInsensitive

Specifies that strings in the set will be compared ignoring case.

Type: SwitchParameter
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

-ExcludeDifferent

Indicates that differences should be skipped.

Type: SwitchParameter
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

-IncludeEqual

Indicates that matches should be included.

Type: SwitchParameter
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

-ProgressAction

{{ Fill ProgressAction Description }}

Type: ActionPreference
Parameter Sets: (All)
Aliases: proga

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

INPUTS

OUTPUTS

System.Management.Automation.PSObject with the properties:

* Value: The value found by the comparison.

* SideIndicator: Points left for values only in the reference object,

| points right for values only in the difference object.

NOTES

RELATED LINKS

https://learn.microsoft.com/dotnet/api/system.collections.generic.hashset-1

Clone this wiki locally