// Path: deploy-runner-common/src/main/java/jetbrains/buildServer/deployer/common/DeployerRunnerConstants.java
// public class DeployerRunnerConstants {
//   public static final String SSH_RUN_TYPE = "ssh-deploy-runner";
//   public static final String SMB_RUN_TYPE = "smb-deploy-runner";
//   public static final String SMB2_RUN_TYPE = "smb2-deploy-runner";
//   public static final String FTP_RUN_TYPE = "ftp-deploy-runner";
//   public static final String TOMCAT_RUN_TYPE = "tomcat-deploy-runner";
//   public static final String CARGO_RUN_TYPE = "cargo-deploy-runner";
// 
// 
//   public static final String PARAM_USERNAME = "jetbrains.buildServer.deployer.username";
//   public static final String PARAM_PASSWORD = "secure:jetbrains.buildServer.deployer.password";
//   @Deprecated
//   public static final String PARAM_PLAIN_PASSWORD = "jetbrains.buildServer.deployer.password";
//   @Deprecated
//   public static final String PARAM_DOMAIN = "jetbrains.buildServer.deployer.domain";
//   public static final String PARAM_TARGET_URL = "jetbrains.buildServer.deployer.targetUrl";
//   public static final String PARAM_SOURCE_PATH = "jetbrains.buildServer.deployer.sourcePath";
//   public static final String PARAM_CONTAINER_CONTEXT_PATH = "jetbrains.buildServer.deployer.container.contextPath";
//   public static final String PARAM_CONTAINER_TYPE = "jetbrains.buildServer.deployer.container.type";
// 
//   public static final String BUILD_PROBLEM_TYPE = "jetbrains.buildServer.deployer";
// }
// 
// Path: deploy-runner-server/src/main/java/jetbrains/buildServer/deployer/server/DeployerPropertiesProcessor.java
// public class DeployerPropertiesProcessor implements PropertiesProcessor {
//   @Override
//   public Collection<InvalidProperty> process(Map<String, String> properties) {
//     Collection<InvalidProperty> result = new HashSet<InvalidProperty>();
//     if (StringUtil.isEmptyOrSpaces(properties.get(DeployerRunnerConstants.PARAM_TARGET_URL))) {
//       result.add(new InvalidProperty(DeployerRunnerConstants.PARAM_TARGET_URL, "The target must be specified."));
//     }
// 
//     if (StringUtil.isEmptyOrSpaces(properties.get(DeployerRunnerConstants.PARAM_SOURCE_PATH))) {
//       result.add(new InvalidProperty(DeployerRunnerConstants.PARAM_SOURCE_PATH, "Artifact to deploy must be specified"));
//     }
//     return result;
//   }
// }


import jetbrains.buildServer.deployer.common.DeployerRunnerConstants;
import jetbrains.buildServer.deployer.server.DeployerPropertiesProcessor;
import jetbrains.buildServer.serverSide.InvalidProperty;
import jetbrains.buildServer.util.StringUtil;
import java.util.Collection;
import java.util.Map;
/*
 * Copyright 2000-2022 JetBrains s.r.o.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package jetbrains.buildServer.deployer.server.cargo;



/**
 * Created by Nikita.Skvortsov
 * date: 15.07.2016.
 */
class CargoPropertiesProcessor extends DeployerPropertiesProcessor {
  @Override
  public Collection<InvalidProperty> process(Map<String, String> properties) {
    Collection<InvalidProperty> result = super.process(properties);

// Path: deploy-runner-common/src/main/java/jetbrains/buildServer/deployer/common/DeployerRunnerConstants.java
// public class DeployerRunnerConstants {
//   public static final String SSH_RUN_TYPE = "ssh-deploy-runner";
//   public static final String SMB_RUN_TYPE = "smb-deploy-runner";
//   public static final String SMB2_RUN_TYPE = "smb2-deploy-runner";
//   public static final String FTP_RUN_TYPE = "ftp-deploy-runner";
//   public static final String TOMCAT_RUN_TYPE = "tomcat-deploy-runner";
//   public static final String CARGO_RUN_TYPE = "cargo-deploy-runner";
// 
// 
//   public static final String PARAM_USERNAME = "jetbrains.buildServer.deployer.username";
//   public static final String PARAM_PASSWORD = "secure:jetbrains.buildServer.deployer.password";
//   @Deprecated
//   public static final String PARAM_PLAIN_PASSWORD = "jetbrains.buildServer.deployer.password";
//   @Deprecated
//   public static final String PARAM_DOMAIN = "jetbrains.buildServer.deployer.domain";
//   public static final String PARAM_TARGET_URL = "jetbrains.buildServer.deployer.targetUrl";
//   public static final String PARAM_SOURCE_PATH = "jetbrains.buildServer.deployer.sourcePath";
//   public static final String PARAM_CONTAINER_CONTEXT_PATH = "jetbrains.buildServer.deployer.container.contextPath";
//   public static final String PARAM_CONTAINER_TYPE = "jetbrains.buildServer.deployer.container.type";
// 
//   public static final String BUILD_PROBLEM_TYPE = "jetbrains.buildServer.deployer";
// }
// 
// Path: deploy-runner-server/src/main/java/jetbrains/buildServer/deployer/server/DeployerPropertiesProcessor.java
// public class DeployerPropertiesProcessor implements PropertiesProcessor {
//   @Override
//   public Collection<InvalidProperty> process(Map<String, String> properties) {
//     Collection<InvalidProperty> result = new HashSet<InvalidProperty>();
//     if (StringUtil.isEmptyOrSpaces(properties.get(DeployerRunnerConstants.PARAM_TARGET_URL))) {
//       result.add(new InvalidProperty(DeployerRunnerConstants.PARAM_TARGET_URL, "The target must be specified."));
//     }
// 
//     if (StringUtil.isEmptyOrSpaces(properties.get(DeployerRunnerConstants.PARAM_SOURCE_PATH))) {
//       result.add(new InvalidProperty(DeployerRunnerConstants.PARAM_SOURCE_PATH, "Artifact to deploy must be specified"));
//     }
//     return result;
//   }
// }


// Path: deploy-runner-server/src/main/java/jetbrains/buildServer/deployer/server/cargo/CargoPropertiesProcessor.java
import jetbrains.buildServer.deployer.common.DeployerRunnerConstants;
import jetbrains.buildServer.deployer.server.DeployerPropertiesProcessor;
import jetbrains.buildServer.serverSide.InvalidProperty;
import jetbrains.buildServer.util.StringUtil;
import java.util.Collection;
import java.util.Map;

/*
 * Copyright 2000-2022 JetBrains s.r.o.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package jetbrains.buildServer.deployer.server.cargo;



/**
 * Created by Nikita.Skvortsov
 * date: 15.07.2016.
 */
class CargoPropertiesProcessor extends DeployerPropertiesProcessor {
  @Override
  public Collection<InvalidProperty> process(Map<String, String> properties) {
    Collection<InvalidProperty> result = super.process(properties);

    if (StringUtil.isEmptyOrSpaces(properties.get(DeployerRunnerConstants.PARAM_USERNAME))) {