當前位置: 首頁>>代碼示例>>Java>>正文


Java DisconnectFromNetworkCmd類代碼示例

本文整理匯總了Java中com.github.dockerjava.api.command.DisconnectFromNetworkCmd的典型用法代碼示例。如果您正苦於以下問題:Java DisconnectFromNetworkCmd類的具體用法?Java DisconnectFromNetworkCmd怎麽用?Java DisconnectFromNetworkCmd使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


DisconnectFromNetworkCmd類屬於com.github.dockerjava.api.command包,在下文中一共展示了DisconnectFromNetworkCmd類的12個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: run

import com.github.dockerjava.api.command.DisconnectFromNetworkCmd; //導入依賴的package包/類
@Override
protected Void run() throws Exception {
  DisconnectFromNetworkCmd disconnectCmd = dockerClient.disconnectFromNetworkCmd();
  disconnectCmd.withNetworkId(networkName).withContainerId(containerId);

  try  {
    return disconnectCmd.exec();
  } catch (Exception e) {
    return null;
  } finally {
    disconnectCmd.close();
  }
}
 
開發者ID:Qorr,項目名稱:Hvalspik,代碼行數:14,代碼來源:DisconnectNetworkCommand.java

示例2: createDisconnectFromNetworkCmdExec

import com.github.dockerjava.api.command.DisconnectFromNetworkCmd; //導入依賴的package包/類
@Override
public DisconnectFromNetworkCmd.Exec createDisconnectFromNetworkCmdExec() {

    return new DisconnectFromNetworkCmdExec(getBaseResource(), getDockerClientConfig());
}
 
開發者ID:docker-java,項目名稱:docker-java,代碼行數:6,代碼來源:JerseyDockerCmdExecFactory.java

示例3: disconnectFromNetworkCmd

import com.github.dockerjava.api.command.DisconnectFromNetworkCmd; //導入依賴的package包/類
@Override
public DisconnectFromNetworkCmd disconnectFromNetworkCmd() {
    return new DisconnectFromNetworkCmdImpl(getDockerCmdExecFactory().createDisconnectFromNetworkCmdExec());
}
 
開發者ID:docker-java,項目名稱:docker-java,代碼行數:5,代碼來源:DockerClientImpl.java

示例4: createDisconnectFromNetworkCmdExec

import com.github.dockerjava.api.command.DisconnectFromNetworkCmd; //導入依賴的package包/類
@Override
public DisconnectFromNetworkCmd.Exec createDisconnectFromNetworkCmdExec() {
    return new DisconnectFromNetworkCmdExec(getBaseResource(), getDockerClientConfig());
}
 
開發者ID:docker-java,項目名稱:docker-java,代碼行數:5,代碼來源:AbstractDockerCmdExecFactory.java

示例5: DisconnectFromNetworkCmdImpl

import com.github.dockerjava.api.command.DisconnectFromNetworkCmd; //導入依賴的package包/類
public DisconnectFromNetworkCmdImpl(DockerCmdSyncExec<DisconnectFromNetworkCmd, Void> execution) {
    super(execution);
}
 
開發者ID:docker-java,項目名稱:docker-java,代碼行數:4,代碼來源:DisconnectFromNetworkCmdImpl.java

示例6: withNetworkId

import com.github.dockerjava.api.command.DisconnectFromNetworkCmd; //導入依賴的package包/類
@Override
public DisconnectFromNetworkCmd withNetworkId(String networkId) {
    this.networkId = networkId;
    return this;
}
 
開發者ID:docker-java,項目名稱:docker-java,代碼行數:6,代碼來源:DisconnectFromNetworkCmdImpl.java

示例7: withContainerId

import com.github.dockerjava.api.command.DisconnectFromNetworkCmd; //導入依賴的package包/類
@Override
public DisconnectFromNetworkCmd withContainerId(String containerId) {
    this.containerId = containerId;
    return this;
}
 
開發者ID:docker-java,項目名稱:docker-java,代碼行數:6,代碼來源:DisconnectFromNetworkCmdImpl.java

示例8: withForce

import com.github.dockerjava.api.command.DisconnectFromNetworkCmd; //導入依賴的package包/類
@Override
public DisconnectFromNetworkCmd withForce(Boolean force) {
    this.force = force;
    return this;
}
 
開發者ID:docker-java,項目名稱:docker-java,代碼行數:6,代碼來源:DisconnectFromNetworkCmdImpl.java

示例9: createDisconnectFromNetworkCmdExec

import com.github.dockerjava.api.command.DisconnectFromNetworkCmd; //導入依賴的package包/類
@Override
public DisconnectFromNetworkCmd.Exec createDisconnectFromNetworkCmdExec() {
    return delegate.createDisconnectFromNetworkCmdExec();
}
 
開發者ID:docker-java,項目名稱:docker-java,代碼行數:5,代碼來源:TestDockerCmdExecFactory.java

示例10: execute

import com.github.dockerjava.api.command.DisconnectFromNetworkCmd; //導入依賴的package包/類
@Override
protected Void execute(DisconnectFromNetworkCmd command) {

    WebTarget webTarget = getBaseResource().path("/networks/" + command.getNetworkId() + "/disconnect");

    LOGGER.trace("POST: {}", webTarget);
    webTarget.request().post(entity(command, MediaType.APPLICATION_JSON));

    return null;
}
 
開發者ID:docker-java,項目名稱:docker-java,代碼行數:11,代碼來源:DisconnectFromNetworkCmdExec.java

示例11: execute

import com.github.dockerjava.api.command.DisconnectFromNetworkCmd; //導入依賴的package包/類
@Override
protected Void execute(DisconnectFromNetworkCmd command) {

    WebTarget webTarget = getBaseResource().path("/networks/" + command.getNetworkId() + "/disconnect");

    LOGGER.trace("POST: {}", webTarget);
    webTarget.request().post(command);

    return null;
}
 
開發者ID:docker-java,項目名稱:docker-java,代碼行數:11,代碼來源:DisconnectFromNetworkCmdExec.java

示例12: disconnectFromNetworkCmd

import com.github.dockerjava.api.command.DisconnectFromNetworkCmd; //導入依賴的package包/類
DisconnectFromNetworkCmd disconnectFromNetworkCmd(); 
開發者ID:docker-java,項目名稱:docker-java,代碼行數:2,代碼來源:DockerClient.java


注:本文中的com.github.dockerjava.api.command.DisconnectFromNetworkCmd類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。