Package org.apache.archiva.metadata.generic

Examples of org.apache.archiva.metadata.generic.GenericMetadataFacet


        parent.setArtifactId( TEST_PARENT_ARTIFACT_ID );
        parent.setVersion( TEST_PARENT_VERSION );
        mavenProjectFacet.setParent( parent );
        model.addFacet( mavenProjectFacet );

        GenericMetadataFacet genericMetadataFacet = new GenericMetadataFacet( );
        Map<String, String> props = new HashMap<String, String>( );
        props.put( TEST_GENERIC_METADATA_PROPERTY_NAME, TEST_GENERIC_METADATA_PROPERTY_VALUE );
        genericMetadataFacet.setAdditionalProperties( props );
        model.addFacet( genericMetadataFacet );

        return model;
    }
View Full Code Here


    }

    private void updateProjectMetadata( ProjectVersionMetadata projectMetadata, MetadataRepository metadataRepository )
        throws MetadataRepositoryException
    {
        GenericMetadataFacet genericMetadataFacet = new GenericMetadataFacet();
        genericMetadataFacet.fromProperties( genericMetadata );

        projectMetadata.addFacet( genericMetadataFacet );

        metadataRepository.updateProjectVersion( repositoryId, groupId, artifactId, projectMetadata );
    }
View Full Code Here

        {
            properties.putAll( metadataFacet.toProperties() );
        }
        else
        {
            metadataFacet = new GenericMetadataFacet();
        }

        properties.put( key, value );

        metadataFacet.fromProperties( properties );
View Full Code Here

        if ( projectVersionMetadata == null )
        {
            return Boolean.FALSE;
        }

        GenericMetadataFacet metadataFacet =
            (GenericMetadataFacet) projectVersionMetadata.getFacet( GenericMetadataFacet.FACET_ID );

        if ( metadataFacet != null && metadataFacet.toProperties() != null )
        {
            Map<String, String> properties = metadataFacet.toProperties();
            properties.remove( key );
            metadataFacet.setAdditionalProperties( properties );
        }
        else
        {
            return Boolean.TRUE;
        }
View Full Code Here

        {
            properties.putAll( metadataFacet.toProperties() );
        }
        else
        {
            metadataFacet = new GenericMetadataFacet();
        }

        properties.put( key, value );

        metadataFacet.fromProperties( properties );
View Full Code Here

        if ( projectVersionMetadata == null )
        {
            return Boolean.FALSE;
        }

        GenericMetadataFacet metadataFacet =
            (GenericMetadataFacet) projectVersionMetadata.getFacet( GenericMetadataFacet.FACET_ID );

        if ( metadataFacet != null && metadataFacet.toProperties() != null )
        {
            Map<String, String> properties = metadataFacet.toProperties();
            properties.remove( key );
            metadataFacet.setAdditionalProperties( properties );
        }
        else
        {
            return Boolean.TRUE;
        }
View Full Code Here

        {
            properties.putAll( metadataFacet.toProperties() );
        }
        else
        {
            metadataFacet = new GenericMetadataFacet();
        }

        properties.put( key, value );

        metadataFacet.fromProperties( properties );
View Full Code Here

        if ( projectVersionMetadata == null )
        {
            return Boolean.FALSE;
        }

        GenericMetadataFacet metadataFacet =
            (GenericMetadataFacet) projectVersionMetadata.getFacet( GenericMetadataFacet.FACET_ID );

        if ( metadataFacet != null && metadataFacet.toProperties() != null )
        {
            Map<String, String> properties = metadataFacet.toProperties();
            properties.remove( key );
            metadataFacet.setAdditionalProperties( properties );
        }
        else
        {
            return Boolean.TRUE;
        }
View Full Code Here

    }

    private void updateProjectMetadata( ProjectVersionMetadata projectMetadata, MetadataRepository metadataRepository )
        throws MetadataRepositoryException
    {
        GenericMetadataFacet genericMetadataFacet = new GenericMetadataFacet();
        genericMetadataFacet.fromProperties( genericMetadata );

        projectMetadata.addFacet( genericMetadataFacet );

        metadataRepository.updateProjectVersion( repositoryId, groupId, artifactId, projectMetadata );
    }
View Full Code Here

    }

    private void updateProjectMetadata( ProjectVersionMetadata projectMetadata, MetadataRepository metadataRepository )
        throws MetadataRepositoryException
    {
        GenericMetadataFacet genericMetadataFacet = new GenericMetadataFacet();
        genericMetadataFacet.fromProperties( genericMetadata );

        projectMetadata.addFacet( genericMetadataFacet );

        metadataRepository.updateProjectVersion( repositoryId, groupId, artifactId, projectMetadata );
    }
View Full Code Here

TOP

Related Classes of org.apache.archiva.metadata.generic.GenericMetadataFacet

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.