Package org.apache.maven.archetype.source

Examples of org.apache.maven.archetype.source.ArchetypeDataSource


    private ArchetypeCatalog fetchArchetypeCatalogFromWiki()
        throws ArchetypeDataSourceException
    {
        // ArchetypeDataSource ads =  (ArchetypeDataSource) lookup( ArchetypeDataSource.ROLE, "wiki" );
        ArchetypeDataSource ads = new WikiArchetypeDataSource();

        // fetch and parse Wiki page content
        ArchetypeCatalog ac = ads.getArchetypeCatalog( new Properties() );

        for ( Archetype archetype : ac.getArchetypes() )
        {
            if ( "".equals( archetype.getRepository() )
                || ( archetype.getRepository() != null && archetype.getRepository().indexOf( CENTRAL.substring( 7 ) ) >= 0 ) )
View Full Code Here


    public ArchetypeCatalog getInternalCatalog()
    {
        try
        {
            ArchetypeDataSource source = archetypeSources.get( "internal-catalog" );

            return source.getArchetypeCatalog( new Properties() );
        }
        catch ( ArchetypeDataSourceException e )
        {
            return new ArchetypeCatalog();
        }
View Full Code Here

    {
        try
        {
            Properties properties = new Properties();
            properties.setProperty( "file", path );
            ArchetypeDataSource source = archetypeSources.get( "catalog" );

            return source.getArchetypeCatalog( properties );
        }
        catch ( ArchetypeDataSourceException e )
        {
            return new ArchetypeCatalog();
        }
View Full Code Here

    {
        try
        {
            Properties properties = new Properties();
            properties.setProperty( "repository", url );
            ArchetypeDataSource source = archetypeSources.get( "remote-catalog" );

            return source.getArchetypeCatalog( properties );
        }
        catch ( ArchetypeDataSourceException e )
        {
            return new ArchetypeCatalog();
        }
View Full Code Here

    {
        try
        {
            Properties properties = new Properties();
            properties.setProperty( "file", path );
            ArchetypeDataSource source = archetypeSources.get( "catalog" );

            source.updateCatalog( properties, archetype );
        }
        catch ( ArchetypeDataSourceException e )
        {
        }
    }
View Full Code Here

TOP

Related Classes of org.apache.maven.archetype.source.ArchetypeDataSource

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.