Restlet Framework 2.2.1
Java Standard Edition

org.restlet.ext.guice
Class RestletGuice

java.lang.Object
  extended by org.restlet.ext.guice.RestletGuice

public class RestletGuice
extends Object

Guice dependency injection for Restlet.

Author:
Tim Peierls

Nested Class Summary
static class RestletGuice.Module
          A Guice module that implements FinderFactory.
 
Constructor Summary
RestletGuice()
           
 
Method Summary
static com.google.inject.Injector createInjector(Iterable<com.google.inject.Module> modules)
          Creates an instance of Injector from the given modules with FinderFactory bound to an implementation that uses the injector's bindings to create Finder instances.
static com.google.inject.Injector createInjector(com.google.inject.Module... modules)
          Creates an instance of Injector from the given modules with FinderFactory bound to an implementation that uses the injector's bindings to create Finder instances.
static com.google.inject.Injector createInjector(com.google.inject.Stage stage, Iterable<com.google.inject.Module> modules)
          Creates an instance of Injector in the given Stage from the given modules with FinderFactory bound to an implementation that uses the injector's bindings to create Finder instances.
static com.google.inject.Injector createInjector(com.google.inject.Stage stage, com.google.inject.Module... modules)
          Creates an instance of Injector in the given Stage from the given modules with FinderFactory bound to an implementation that uses the injector's bindings to create Finder instances.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RestletGuice

public RestletGuice()
Method Detail

createInjector

public static com.google.inject.Injector createInjector(com.google.inject.Module... modules)
Creates an instance of Injector from the given modules with FinderFactory bound to an implementation that uses the injector's bindings to create Finder instances.

Parameters:
modules - The list of modules.
Returns:
The injector for the list of modules.

createInjector

public static com.google.inject.Injector createInjector(Iterable<com.google.inject.Module> modules)
Creates an instance of Injector from the given modules with FinderFactory bound to an implementation that uses the injector's bindings to create Finder instances.

Parameters:
modules - The collection of modules.
Returns:
The injector for the list of modules.

createInjector

public static com.google.inject.Injector createInjector(com.google.inject.Stage stage,
                                                        com.google.inject.Module... modules)
Creates an instance of Injector in the given Stage from the given modules with FinderFactory bound to an implementation that uses the injector's bindings to create Finder instances.

Parameters:
stage - The Stage.
modules - The list of modules.
Returns:
The injector for the list of modules in the given stage.

createInjector

public static com.google.inject.Injector createInjector(com.google.inject.Stage stage,
                                                        Iterable<com.google.inject.Module> modules)
Creates an instance of Injector in the given Stage from the given modules with FinderFactory bound to an implementation that uses the injector's bindings to create Finder instances.

Parameters:
stage - The Stage.
modules - The list of modules.
Returns:
The injector for the list of modules in the given stage.

Restlet Framework 2.2.1
Java Standard Edition

Copyright © 2005-2014 Restlet.