Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
 package com.yammer.dropwizard.jetty;
 
A wrapper for com.yammer.dropwizard.lifecycle.Managed instances which ties them to a Jetty org.eclipse.jetty.util.component.LifeCycle.
 
public class JettyManaged extends AbstractLifeCycle implements Managed {
    private final Managed managed;

    
Creates a new JettyManaged wrapping managed.

Parameters:
managed a com.yammer.dropwizard.lifecycle.Managed instance to be wrapped
    public JettyManaged(Managed managed) {
        this. = managed;
    }
    @Override
    protected void doStart() throws Exception {
        .start();
    }
    @Override
    protected void doStop() throws Exception {
        .stop();
    }
    @Override
    public String toString() {
        //Delegate to the wrapped instance
        return .toString();
    }
New to GrepCode? Check out our FAQ X