Package org.apache.maven.artifact

Examples of org.apache.maven.artifact.InvalidArtifactRTException


    public String diagnose( Throwable error )
    {
        StringBuffer diagnosis = new StringBuffer();

        InvalidArtifactRTException e = (InvalidArtifactRTException) error;

        diagnosis.append( "An invalid artifact was detected.\n\n" )
            .append( "This artifact might be in your project's POM, " )
            .append( "or it might have been included transitively during the resolution process. " )
            .append( "Here is the information we do have for this artifact:\n" )
            .append( "\n    o GroupID:     " ).append( maybeFlag( e.getGroupId() ) )
            .append( "\n    o ArtifactID:  " ).append( maybeFlag( e.getArtifactId() ) )
            .append( "\n    o Version:     " ).append( maybeFlag( e.getVersion() ) )
            .append( "\n    o Type:        " ).append( maybeFlag( e.getType() ) )
            .append( "\n" );

        return diagnosis.toString();
    }
View Full Code Here


        this.parent = parent;

        if ( getId().equals( parent.getId() ) )
        {
            throw new InvalidArtifactRTException( parent.getGroupId(), parent.getArtifactId(), parent.getVersion(),
                                                  parent.getType(), "An attached artifact must have a different ID"
                                                      + " than its corresponding main artifact." );
        }
    }
View Full Code Here

        this.parent = parent;

        if ( getId().equals( parent.getId() ) )
        {
            throw new InvalidArtifactRTException( parent.getGroupId(), parent.getArtifactId(), parent.getVersion(),
                                                  parent.getType(), "An attached artifact must have a different ID"
                                                      + " than its corresponding main artifact." );
        }
    }
View Full Code Here

    public String diagnose( Throwable error )
    {
        StringBuffer diagnosis = new StringBuffer();

        InvalidArtifactRTException e = (InvalidArtifactRTException) error;

        diagnosis.append( "An invalid artifact was detected.\n\n" )
            .append( "This artifact might be in your project's POM, " )
            .append( "or it might have been included transitively during the resolution process. " )
            .append( "Here is the information we do have for this artifact:\n" )
            .append( "\n    o GroupID:     " ).append( maybeFlag( e.getGroupId() ) )
            .append( "\n    o ArtifactID:  " ).append( maybeFlag( e.getArtifactId() ) )
            .append( "\n    o Version:     " ).append( maybeFlag( e.getVersion() ) )
            .append( "\n    o Type:        " ).append( maybeFlag( e.getType() ) )
            .append( "\n" );

        return diagnosis.toString();
    }
View Full Code Here

       
        this.parent = parent;
       
        if ( getId().equals( parent.getId() ) )
        {
            throw new InvalidArtifactRTException( parent.getGroupId(), parent.getArtifactId(), parent.getVersion(), parent.getType(), "An attached artifact must have a different ID than its corresponding main artifact." );
        }
    }
View Full Code Here

    private void validateIdentity()
    {
        if ( empty( key.getGroupId() ) )
        {
            throw new InvalidArtifactRTException( key.getGroupId(), key.getArtifactId(), key.getVersion(), type,
                                                  "The groupId cannot be empty." );
        }

        if ( key.getArtifactId() == null )
        {
            throw new InvalidArtifactRTException( key.getGroupId(), key.getArtifactId(), key.getVersion(), type,
                                                  "The artifactId cannot be empty." );
        }

        if ( type == null )
        {
            throw new InvalidArtifactRTException( key.getGroupId(), key.getArtifactId(), key.getVersion(), type,
                                                  "The type cannot be empty." );
        }

        if ( key.getVersion() == null )
        {
            throw new InvalidArtifactRTException( key.getGroupId(), key.getArtifactId(), key.getVersion(), type,
                                                  "The version cannot be empty." );
        }
    }
View Full Code Here

            this.parent = parent;

            if ( getId().equals( parent.getId() ) )
            {
                throw new InvalidArtifactRTException( parent.getGroupId(), parent.getArtifactId(), parent.getVersion(),
                                                      parent.getType(),
                                                      "An attached artifact must have a different ID than its corresponding main artifact." );
            }
        }
View Full Code Here

       
        this.parent = parent;
       
        if ( getId().equals( parent.getId() ) )
        {
            throw new InvalidArtifactRTException( parent.getGroupId(), parent.getArtifactId(), parent.getVersion(), parent.getType(), "An attached artifact must have a different ID than its corresponding main artifact." );
        }
    }
View Full Code Here

       
        this.parent = parent;
       
        if ( getId().equals( parent.getId() ) )
        {
            throw new InvalidArtifactRTException( parent.getGroupId(), parent.getArtifactId(), parent.getVersion(), parent.getType(), "An attached artifact must have a different ID than its corresponding main artifact." );
        }
    }
View Full Code Here

TOP

Related Classes of org.apache.maven.artifact.InvalidArtifactRTException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.