Get employment objects from the Swedish employment service
    Build PowerShell objects from the Swedish employment service. This is a example module
    that is used to demonstrate the use of PowerShell 5 and object based on classes.
    What type of Job you look for? (default is "Restaurant")
    In what part of Sweden do you look for job? (default is 1=Stockholms Län)
    Id Name
    -- ----
    10 Blekinge län
    20 Dalarnas län
     9 Gotlands län
    21 Gävleborgs län
    13 Hallands län
    23 Jämtlands län
     6 Jönköpings län
     8 Kalmar län
     7 Kronobergs län
    25 Norrbottens län
    12 Skåne län
     1 Stockholms län
     4 Södermanlands län
     3 Uppsala län
    17 Värmlands län
    24 Västerbottens län
    22 Västernorrlands län
    19 Västmanlands län
    14 Västra Götalands län
    18 Örebro län
     5 Östergötlands län
    90 Ospecificerad arbetsort
    PS C:\> Get-NonPsJob
    List all employment objects
    PS C:\> Get-NonPsJob | ? {$_.Workplace -like "*McDon*"}
    Gets all job that should come frome McDonalds.
    PS C:\>Get-NonPSJob | ? {$_.Workplace -like "*McDo*" -and $_.Location -like "*stock*"}
    Gets all job that should come frome McDonalds and location is Stockholm
    PS C:\>$Jobs = Get-NonPSJob | ? {$_.Workplace -like "*McDo*" -and $_.Location -like "*stock*"}
    PS C:\>$Jobs[0].ApplyForJob()
    Demos that the Objects are built in PowerShell 5 Classes and use it´s own object methods.
    GitHub project

Function Get-NonPSJob{

            HelpMessage="What type of job do you search for?"
        [string]$Category = "Restaurangbitr%C3%A4de",

            HelpMessage="In what region do you want to search?"
        [string]$Region = "1",

        [string]$NumberOf = "300"            

        $Header      = @{  
        $Query       = "$Region&nyckelord=$Category&antalrader=$NumberOf"           
        $QueryResult = Invoke-RestMethod -Uri $Query -Method Get -Headers $Header | 
                       Select-Object -ExpandProperty matchningslista | 
                       Select-Object -ExpandProperty matchningdata
        $Result = @()

        #TODO: Fix if there are no query objects...

        ForEach ($r in $QueryResult){

            $NonPSJobObject   = New-Object NonPSJob -Property @{
                Title         = $($r.annonsrubrik)
                Workplace     = $($r.arbetsplatsnamn)
                Location      = $($r.kommunnamn)
                Category      = $($r.yrkesbenamning)
                NumberOfSeats = $($r.antalplatser)
                Url           = $($r.annonsurl)
            $Result += $NonPSJobObject

        Return  $Result