Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
7
Task/JSON/PowerShell/json-1.psh
Normal file
7
Task/JSON/PowerShell/json-1.psh
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
# JSON input is being stored in ordered hashtable.
|
||||
# Ordered hashtable is available in PowerShell v3 and higher.
|
||||
[ordered]@{ "foo"= 1; "bar"= 10, "apples" } | ConvertTo-Json
|
||||
|
||||
# ConvertFrom-Json converts a JSON-formatted string to a custom object.
|
||||
# If you use the Invoke-RestMethod cmdlet there is not need for the ConvertFrom-Json cmdlet
|
||||
Invoke-WebRequest -Uri "http://date.jsontest.com" | ConvertFrom-Json
|
||||
11
Task/JSON/PowerShell/json-2.psh
Normal file
11
Task/JSON/PowerShell/json-2.psh
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
{
|
||||
"foo": 1,
|
||||
"bar": [
|
||||
10,
|
||||
"apples"
|
||||
]
|
||||
}
|
||||
|
||||
time milliseconds_since_epoch date
|
||||
---- ------------------------ ----
|
||||
12:25:25 PM 1414326325923 10-26-2014
|
||||
Loading…
Add table
Add a link
Reference in a new issue