Paul Vaillant

Get-PhoneNumberClass

Classifies phone numbers based on the gold/silver/bronze classifications

Syntax

Get-PhoneNumberClass.ps1 [-Number] <Int64> [-Details] [-Slow] [<CommonParameters>]Get-PhoneNumberClass.ps1 [-Pipeline <Int64[]>] [-Slow] [<CommonParameters>]Get-PhoneNumberClass.ps1 -Test [-RunSize <Int32>] [-Slow] [<CommonParameters>]

Parameters

NameDescriptionRequired?Pipeline Input?Default Value
NumberA phone number (digits only) to testtruefalse0
DetailsReturns detailed results for a single Number instead of just the classfalsefalseFalse
PipelineAn array of phone numbers to testfalsetrue (ByValue)
TesttruefalseFalse
RunSizefalsefalse100
SlowUses the alternate method of of classifying numbers that's slower. This is for demonstration and shouldn't ever
normally be used
falsefalseFalse

Notes

Version 1.0.1 (2015-05-19)
Written by Paul Vaillant
Classifications come from @StaleHansen from his #msignite presenatation

Examples

EXAMPLE 1

Get-PhoneNumberClass.ps1 7005551212

Figure out what the class is for a given number (7005551212 in this case)
This returns just the class of the specified number

EXAMPLE 2

Get-PhoneNumberClass.ps1 7005551212 -Details

Figure out what the class is for a given number (7005551212 in this case)
This returns an object with the Number, Class and Reason for classification

EXAMPLE 3

Get-ListOfPhoneNumbers | Get-PhoneNumberClass.ps1

Classifies all numbers returned by the Get-ListOfPhoneNumbers command
Returns an object for each of the numbers with the Number, Class and Reason for classification