Skip to content

Instantly share code, notes, and snippets.

@ps06756
Created September 30, 2017 08:35
Show Gist options
  • Save ps06756/40222cfd7e07bf2a38dc62c793a18886 to your computer and use it in GitHub Desktop.
Save ps06756/40222cfd7e07bf2a38dc62c793a18886 to your computer and use it in GitHub Desktop.
package com.example;
import com.google.inject.Injector;
import com.google.inject.Guice;
public class Main {
public static void main(String[] args) {
Injector injector = Guice.createInjector(new PhysicsClassroomModule());
Classroom classroom = injector.getInstance(Classroom.class);
classroom.printStudent();
classroom.printTeacher();
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment