/*******************************************************************************
 * Copyright (c) 2012-2015 Codenvy, S.A.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *   Codenvy, S.A. - initial API and implementation
 *******************************************************************************/
package org.eclipse.che.plugin.docker.machine;

import com.google.inject.assistedinject.Assisted;

import org.eclipse.che.api.core.util.LineConsumer;
import org.eclipse.che.api.machine.server.exception.MachineException;

import javax.annotation.Nullable;

/**
 * Provides Docker machine implementation instances.
 *
 * @author Alexander Garagatyi
 */
public interface DockerMachineFactory {
    DockerInstanceMetadata createInstanceMetadata(@Assisted String container) throws MachineException;

    DockerProcess createProcess(@Assisted("container") String container,
                                @Assisted("command") @Nullable String command,
                                @Assisted("pid_file_path") String pidFilePath,
                                @Assisted int pid) throws MachineException;

    DockerInstance createInstance(@Assisted("container") String containerId,
                                  @Assisted DockerNode node,
                                  @Assisted("workspace") String workspaceId,
                                  @Assisted boolean bindWorkspace,
                                  @Assisted LineConsumer outputConsumer) throws MachineException;

    DockerNode createNode(@Assisted String containerId) throws MachineException;
}

@@ -734,16 +734,199 @@
 ception;
+%0Aimport org.eclipse.che.api.machine.server.spi.Instance;%0Aimport org.eclipse.che.api.machine.server.spi.InstanceMetadata;%0Aimport org.eclipse.che.api.machine.server.spi.InstanceProcess;
 %0A%0Aimport
@@ -1089,30 +1089,24 @@
 ctory %7B%0A    
-Docker
 InstanceMeta
@@ -1191,22 +1191,24 @@
 n;%0A%0A    
-Docker
+Instance
 Process 
@@ -1286,32 +1286,34 @@
                 
+  
 @Assisted(%22comma
@@ -1343,16 +1343,18 @@
 ommand,%0A
+  
         
@@ -1448,32 +1448,34 @@
                 
+  
 @Assisted int pi
@@ -1507,22 +1507,16 @@
 n;%0A%0A    
-Docker
 Instance
@@ -1594,38 +1594,32 @@
                 
-      
 @Assisted Docker
@@ -1649,38 +1649,32 @@
                 
-    
-  
 @Assisted(%22works
@@ -1720,38 +1720,32 @@
                 
-      
 @Assisted boolea
@@ -1761,22 +1761,16 @@
 kspace,%0A
-      
         

fix assisted injection binding issue