Examples of BidirectionalRepositoryLayout


Examples of org.apache.maven.archiva.repository.layout.BidirectionalRepositoryLayout

    private File toFile( ArchivaArtifact artifact )
    {
        RepositoryConfiguration repoConfig = getRepository( artifact );

        BidirectionalRepositoryLayout layout = null;

        try
        {
            layout = layoutFactory.getLayout( artifact );
        }
        catch ( LayoutException e )
        {
            getLogger().warn( "Unable to determine layout of " + artifact + ": " + e.getMessage(), e );
            return null;
        }

        String path = layout.toPath( artifact );
        RepositoryURL url = new RepositoryURL( repoConfig.getUrl() );
        return new File( url.getPath(), path );
    }
View Full Code Here

Examples of org.apache.maven.archiva.repository.layout.BidirectionalRepositoryLayout

    private String toPath( ArchivaArtifact artifact )
    {
        try
        {
            BidirectionalRepositoryLayout layout = layoutFactory.getLayout( artifact );
            return layout.toPath( artifact );
        }
        catch ( LayoutException e )
        {
            getLogger().warn( "Unable to calculate path for artifact: " + artifact );
            return null;
View Full Code Here

Examples of org.apache.maven.archiva.repository.layout.BidirectionalRepositoryLayout

                + repo );
        }

        try
        {
            BidirectionalRepositoryLayout layout = layoutFactory.getLayout( repo.getLayoutType() );
            ProjectModelReader reader = project400Reader;

            if ( StringUtils.equals( "legacy", repo.getLayoutType() ) )
            {
                reader = project300Reader;
View Full Code Here

Examples of org.apache.maven.archiva.repository.layout.BidirectionalRepositoryLayout

        ArchivaRepository repo = new ArchivaRepository( "defaultTestRepo", "Default Test Repo", "file://"
            + defaultRepoDir.getAbsolutePath() );

        ProjectModelReader reader = new ProjectModel400Reader();
        BidirectionalRepositoryLayout layout = new DefaultBidirectionalRepositoryLayout();
        RepositoryProjectResolver resolver = new RepositoryProjectResolver( repo, reader, layout );

        return resolver;
    }
View Full Code Here

Examples of org.apache.maven.archiva.repository.layout.BidirectionalRepositoryLayout

    private String toPath( ArchivaArtifact artifact )
    {
        try
        {
            BidirectionalRepositoryLayout layout = layoutFactory.getLayout( artifact );
            return layout.toPath( artifact );
        }
        catch ( LayoutException e )
        {
            getLogger().warn( "Unable to calculate path for artifact: " + artifact );
            return "";
View Full Code Here

Examples of org.apache.maven.archiva.repository.layout.BidirectionalRepositoryLayout

    private File toFile( ArchivaArtifact artifact )
    {
        RepositoryConfiguration repoConfig = getRepository( artifact );

        BidirectionalRepositoryLayout layout = null;

        try
        {
            layout = layoutFactory.getLayout( artifact );
        }
        catch ( LayoutException e )
        {
            getLogger().warn( "Unable to determine layout of " + artifact + ": " + e.getMessage(), e );
            return null;
        }

        String path = layout.toPath( artifact );
        RepositoryURL url = new RepositoryURL( repoConfig.getUrl() );
        return new File( url.getPath(), path );
    }
View Full Code Here

Examples of org.apache.maven.archiva.repository.layout.BidirectionalRepositoryLayout

    private String toPath( ArchivaArtifact artifact )
    {
        try
        {
            BidirectionalRepositoryLayout layout = layoutFactory.getLayout( artifact );
            return layout.toPath( artifact );
        }
        catch ( LayoutException e )
        {
            getLogger().warn( "Unable to calculate path for artifact: " + artifact );
            return null;
View Full Code Here

Examples of org.apache.maven.archiva.repository.layout.BidirectionalRepositoryLayout

    private String toPath( ArchivaArtifact artifact )
    {
        try
        {
            BidirectionalRepositoryLayout layout = layoutFactory.getLayout( artifact );
            return layout.toPath( artifact );
        }
        catch ( LayoutException e )
        {
            getLogger().warn( "Unable to calculate path for artifact: " + artifact );
            return null;
View Full Code Here

Examples of org.apache.maven.archiva.repository.layout.BidirectionalRepositoryLayout

    }

    protected ArtifactReference createArtifactReference( String layoutType, String path )
        throws Exception
    {
        BidirectionalRepositoryLayout layout = layoutFactory.getLayout( layoutType );
        ArchivaArtifact artifact = layout.toArtifact( path );
        ArtifactReference ref = new ArtifactReference();
        ref.setGroupId( artifact.getGroupId() );
        ref.setArtifactId( artifact.getArtifactId() );
        ref.setVersion( artifact.getVersion() );
        ref.setClassifier( artifact.getClassifier() );
View Full Code Here

Examples of org.apache.maven.archiva.repository.layout.BidirectionalRepositoryLayout

    }

    protected ProjectReference createMetadataReference( String layoutType, String path )
        throws Exception
    {
        BidirectionalRepositoryLayout layout = layoutFactory.getLayout( layoutType );
        ProjectReference metadata = layout.toProjectReference( path );
        return metadata;
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.