remove unused files from old mojo API

git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@169844 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Brett Leslie Porter 2005-05-12 16:41:44 +00:00
parent bc95d8eb35
commit 066938d5b9
4 changed files with 0 additions and 214 deletions

View File

@ -1,40 +0,0 @@
package org.apache.maven.plugin;
/*
* Copyright 2001-2004 The Apache Software Foundation.
*
* 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.
*/
/**
* @author <a href="mailto:jason@maven.org">Jason van Zyl</a>
* @version $Id$
*/
public abstract class FailureResponse
{
protected Object source;
protected FailureResponse( Object source )
{
this.source = source;
}
public abstract String shortMessage();
public abstract String longMessage();
public Object getSource()
{
return source;
}
}

View File

@ -1,49 +0,0 @@
package org.apache.maven.plugin;
/*
* Copyright 2001-2004 The Apache Software Foundation.
*
* 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.
*/
import java.util.Map;
/**
* @author <a href="mailto:jason@maven.org">Jason van Zyl</a>
* @version $Id$
* @deprecated
*/
public class MojoExecutionRequest
{
private Map parameters;
public MojoExecutionRequest( Map parameters )
{
this.parameters = parameters;
}
public Map getParameters()
{
return parameters;
}
public void setParameters( Map parameters )
{
this.parameters = parameters;
}
public Object getParameter( String key )
{
return parameters.get( key );
}
}

View File

@ -1,55 +0,0 @@
package org.apache.maven.plugin;
/*
* Copyright 2001-2004 The Apache Software Foundation.
*
* 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.
*/
/**
* @deprecated
* @author <a href="mailto:jason@maven.org">Jason van Zyl</a>
* @version $Id$
*/
public class MojoExecutionResponse
{
private FailureResponse failureResponse = null;
public boolean isExecutionFailure()
{
return failureResponse != null;
}
public void setExecutionFailure( FailureResponse failureResponse )
{
this.failureResponse = failureResponse;
}
/**
* @deprecated please use {@link #setExecutionFailure(FailureResponse)} as there is no need to set executionFailure to false if there is a failure response
*/
public void setExecutionFailure( boolean executionFailure, FailureResponse failureResponse )
{
if ( executionFailure == false )
{
throw new IllegalArgumentException( "executionFailure should be true when passing a failureResponse" );
}
setExecutionFailure( failureResponse );
}
public FailureResponse getFailureResponse()
{
return failureResponse;
}
}

View File

@ -1,70 +0,0 @@
package org.apache.maven.script.marmalade;
/*
* Copyright 2001-2004 The Apache Software Foundation.
*
* 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.
*/
import org.apache.maven.plugin.FailureResponse;
import org.codehaus.marmalade.runtime.MarmaladeExecutionException;
import java.io.PrintWriter;
import java.io.StringWriter;
/**
* @author jdcasey Created on Feb 8, 2005
*/
public class MarmaladeMojoFailureResponse
extends FailureResponse
{
private final String scriptLocation;
private final MarmaladeExecutionException error;
public MarmaladeMojoFailureResponse( String scriptLocation, MarmaladeExecutionException error )
{
super( scriptLocation );
this.scriptLocation = scriptLocation;
this.error = error;
}
public String shortMessage()
{
StringBuffer buffer = new StringBuffer();
buffer.append( "Script: " ).append( scriptLocation ).append( " failed to execute." );
buffer.append( "\nError: " ).append( error.getLocalizedMessage() );
return buffer.toString();
}
public String longMessage()
{
StringBuffer buffer = new StringBuffer();
buffer.append( "Script: " ).append( scriptLocation ).append( " failed to execute." );
buffer.append( "\nError:\n" );
StringWriter sWriter = new StringWriter();
PrintWriter pWriter = new PrintWriter( sWriter );
error.printStackTrace( pWriter );
buffer.append( sWriter.toString() );
pWriter.close();
return buffer.toString();
}
}