001/* 002 * Licensed to the Apache Software Foundation (ASF) under one 003 * or more contributor license agreements. See the NOTICE file 004 * distributed with this work for additional information 005 * regarding copyright ownership. The ASF licenses this file 006 * to you under the Apache License, Version 2.0 (the 007 * "License"); you may not use this file except in compliance 008 * with the License. You may obtain a copy of the License at 009 * 010 * http://www.apache.org/licenses/LICENSE-2.0 011 * 012 * Unless required by applicable law or agreed to in writing, 013 * software distributed under the License is distributed on an 014 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 015 * KIND, either express or implied. See the License for the 016 * specific language governing permissions and limitations 017 * under the License. 018 */ 019package org.apache.maven.scm.command.mkdir; 020 021import java.util.List; 022 023import org.apache.maven.scm.ScmFile; 024import org.apache.maven.scm.ScmResult; 025 026/** 027 * Result of making directories in SCM. 028 * 029 * @author <a href="mailto:oching@apache.org">Maria Odea Ching</a> 030 */ 031public class MkdirScmResult extends ScmResult { 032 private static final long serialVersionUID = -8717329738246682608L; 033 034 private String revision; 035 036 private List<ScmFile> createdDirs; 037 038 public MkdirScmResult(ScmResult scmResult) { 039 super(scmResult); 040 } 041 042 public MkdirScmResult(String commandLine, String providerMessage, String commandOutput, boolean success) { 043 super(commandLine, providerMessage, commandOutput, success); 044 } 045 046 public MkdirScmResult(String commandLine, String revision) { 047 this(commandLine, null, null, true); 048 049 this.revision = revision; 050 } 051 052 public MkdirScmResult(String commandLine, List<ScmFile> createdDirs) { 053 this(commandLine, null, null, true); 054 055 this.createdDirs = createdDirs; 056 } 057 058 public MkdirScmResult(String revision, ScmResult result) { 059 super(result); 060 061 this.revision = revision; 062 } 063 064 public MkdirScmResult(List<ScmFile> createdDirs, ScmResult result) { 065 super(result); 066 067 this.createdDirs = createdDirs; 068 } 069 070 public String getRevision() { 071 return revision; 072 } 073 074 public List<ScmFile> getCreatedDirs() { 075 return createdDirs; 076 } 077}