Permalink
Browse files

More Rosyln updates

  • Loading branch information...
1 parent 2382e96 commit 175efb23bedfd33390ec5f27646890937af4fc67 @dfinke committed Jun 9, 2012
Showing with 15 additions and 15 deletions.
  1. +14 −14 {chapter08 → chapter06}/GetStackOverflowUser.ps1
  2. +1 −1 chapter08/ShowGetSyntaxTreeRoot.ps1
@@ -1,14 +1,14 @@
-function Get-StackOverflowUser ($id) {
-
- $url = "http://api.stackoverflow.com/1.1/users/$id"
- $data = (New-Object Net.WebClient).DownloadData($url)
- $memoryStream = New-Object System.IO.MemoryStream(,$data)
- $decompress = New-Object `
- System.IO.Compression.GZipStream($memoryStream,"Decompress")
- $reader = New-Object System.IO.StreamReader($decompress)
- $ret = $reader.ReadToEnd()
-
- ($ret | ConvertFrom-Json).Users
-}
-
-Get-StackOverflowUser –id 110865
+function Get-StackOverflowUser ($id) {
+
+ $url = "http://api.stackoverflow.com/1.1/users/$id"
+ $data = (New-Object Net.WebClient).DownloadData($url)
+ $memoryStream = New-Object System.IO.MemoryStream(,$data)
+ $decompress = New-Object `
+ System.IO.Compression.GZipStream($memoryStream,"Decompress")
+ $reader = New-Object System.IO.StreamReader($decompress)
+ $ret = $reader.ReadToEnd()
+
+ ($ret | ConvertFrom-Json).Users
+}
+
+Get-StackOverflowUser –id 110865
@@ -9,4 +9,4 @@ $FirstDocument = $FirstProject.Documents |
Select -First 1
$cancelToken = New-Object System.Threading.CancellationToken
-$FirstDocument.GetSyntaxTree($cancelToken).Root
+$FirstDocument.GetSyntaxTree($cancelToken).GetRoot($cancelToken)

0 comments on commit 175efb2

Please sign in to comment.