public static <T extends Assignable> T create(final Class<T> type) throws IllegalArgumentException,
        UnknownExtensionTypeException {
        // Precondition checks
        if (type == null) {
            throw new IllegalArgumentException("Type must be specified");
        }

        // Delegate to the default domain's archive factory for creation
        return ShrinkWrap.getDefaultDomain().getArchiveFactory().create(type);
    }
public static < T extends Assignable > T create ( final Class < T > type ) throws IllegalArgumentException , UnknownExtensionTypeException { if ( type == null ) { throw new IllegalArgumentException ( "Type must be specified" ) ; } return ShrinkWrap . getDefaultDomain ( ) . getArchiveFactory ( ) . create ( type ) ; }
Creates a new archive of the specified type. The archive will be be backed by the default {@link Configuration}.
specific to this {@link ArchiveFactory}. Generates a random name for the archive and adds proper extension based
on the service descriptor properties file if extension property is present (e.g.
shrinkwrap/impl-base/src/main/resources/META-INF/services/org.jboss.shrinkwrap.api.spec.JavaArchive)

Invoking this method is functionally equivalent to calling {@link ArchiveFactory#create(Class)} upon
{@link Domain#getArchiveFactory()} upon the domain returned by {@link ShrinkWrap#getDefaultDomain()}.

@param type
The type of the archive e.g. {@link WebArchive}
@return An {@link Assignable} archive base
@throws IllegalArgumentException
if type is not specified
@throws UnknownExtensionTypeException
If no extension mapping is found for the specified type