Skip to content

Instantly share code, notes, and snippets.

Avatar

Anthony D. Green AnthonyDGreen

View GitHub Profile
View RestDemo.vb
Imports System.Net.Http
Imports Newtonsoft.Json.Linq
Module RestDemo
Async Function RunAsync() As Task
Dim client As New HttpClient With {.BaseAddress = New Uri("https://api.github.com")}
#Region " Initialize HttpClient headers "
With client.DefaultRequestHeaders
.UserAgent.Add("JsonDemo", "0.1")
@AnthonyDGreen
AnthonyDGreen / whats-next-for-anthony.md
Last active Feb 12, 2019
An update on how my 2018 return to Chicago went and what's next for me in 2019
View whats-next-for-anthony.md

What’s Next for Anthony

Recap

It’s been a year since my last update. Relocating my life from Seattle back to Chicago was no small feat. All in all, I’d say it took just under 10 months.

  • 3 months to ready (read: repair) the condo I was living in for a new family to live in and pack all my stuff up

  • 3.5 months to find the spot I wanted to call home in Chicago and to get it ready (read: repaired and cleaned) for me to live in; during which I was couch surfing and living out of hotels.

@AnthonyDGreen
AnthonyDGreen / homeward-bound.md
Last active Nov 15, 2018
(Former) Program Manager for Visual Basic details why he's leaving Redmond and moving back to Chicago.
View homeward-bound.md

This is my family tree:

22136890_558639237233_2226452117892069088_o

I drew this diagram from memory (it's not complete) on the whiteboard in my office last year to illustrate a point to a colleague: family is everything to me. Those shapes aren't just entries in a historical record, they're people who I've known and who have surrounded me my entire life. Not being near to them is as unnatural to me as not including my middle initial/name in my signature*. The shapes inside the circle are all in Chicago. And it's for that reason that I've always known my time at Microsoft and in Seattle could never be forever.

Since arriving in Seattle 8-years ago I've flown across the country (and to Canada once) for weddings, birthdays, graduations, almost every major US holiday (can you imagine having to call all those people if you miss Christmas?), a couple of drivers tests, and for one particular relation for

View Main.vb
Sub Main()
Dim injector As New Mother
Dim serviceObject = injector.GetDrinkService()
Dim clientObject As New Child(serviceObject)
clientObject.Drink()
Console.ReadLine()
View Mother.vb
Public Class Mother
Public Function GetDrinkService() As IDrinkService
Return New MilkDrinkService()
End Function
End Class
View Child.vb
Public Class Child
Private ReadOnly _drinkService As IDrinkService
Public Sub New(drinkService As IDrinkService)
_drinkService = drinkService
End Sub
Public Sub Drink()
_drinkService.Drink()
View AppleJuiceDrinkService.vb
Public Class AppleJuiceDrinkService
Implements IDrinkService
Public Sub Drink() Implements IDrinkService.Drink
Console.WriteLine("Drink a bottle of apple juice")
End Sub
End Class
View OrangeJuiceDrinkService.vb
Public Class OrangeJuiceDrinkService
Implements IDrinkService
Public Sub Drink() Implements IDrinkService.Drink
Console.WriteLine("Drink a glass of orange juice")
End Sub
End Class
View MilkDrinkService.vb
Public Class MilkDrinkService
Implements IDrinkService
Public Sub Drink() Implements IDrinkService.Drink
Console.WriteLine("Drink a cup of milk")
End Sub
End Class
View IDrinkService.vb
Public Interface IDrinkService
Sub Drink()
End Interface
You can’t perform that action at this time.