/** * Creates a new exception with the specified repository. * * @param repository The remote repository whose layout is not supported, may be {@code null}. */ public NoRepositoryLayoutException( RemoteRepository repository ) { this( repository, toMessage( repository ) ); }
public RepositoryLayout newInstance( RepositorySystemSession session, RemoteRepository repository ) throws NoRepositoryLayoutException { if ( !"default".equals( repository.getContentType() ) ) { throw new NoRepositoryLayoutException( repository ); } boolean forSignature = ConfigUtils.getBoolean( session, false, CONFIG_PROP_SIGNATURE_CHECKSUMS ); return forSignature ? Maven2RepositoryLayout.INSTANCE : Maven2RepositoryLayoutEx.INSTANCE; }
throw new NoRepositoryConnectorException( repository, e.getMessage(), e );
e.printStackTrace(); } catch (JsonParseException e) { e.printStackTrace();
public RepositoryLayout newInstance( RepositorySystemSession session, RemoteRepository repository ) throws NoRepositoryLayoutException { if ( !"default".equals( repository.getContentType() ) ) { throw new NoRepositoryLayoutException( repository ); } boolean forSignature = ConfigUtils.getBoolean( session, false, CONFIG_PROP_SIGNATURE_CHECKSUMS ); return forSignature ? Maven2RepositoryLayout.INSTANCE : Maven2RepositoryLayoutEx.INSTANCE; }
throw new NoRepositoryConnectorException( repository, e.getMessage(), e );
/** * Creates a new exception with the specified repository and cause. * * @param repository The remote repository whose layout is not supported, may be {@code null}. * @param cause The exception that caused this one, may be {@code null}. */ public NoRepositoryLayoutException( RemoteRepository repository, Throwable cause ) { this( repository, toMessage( repository ), cause ); }
throw new NoRepositoryLayoutException( repository, buffer.toString(), errors.size() == 1 ? errors.get( 0 ) : null );
/** * Creates a new exception with the specified repository. * * @param repository The remote repository whose layout is not supported, may be {@code null}. */ public NoRepositoryLayoutException( RemoteRepository repository ) { this( repository, toMessage( repository ) ); }
throw new NoRepositoryLayoutException( repository, buffer.toString(), errors.size() == 1 ? errors.get( 0 ) : null );
/** * Creates a new exception with the specified repository and cause. * * @param repository The remote repository whose layout is not supported, may be {@code null}. * @param cause The exception that caused this one, may be {@code null}. */ public NoRepositoryLayoutException( RemoteRepository repository, Throwable cause ) { this( repository, toMessage( repository ), cause ); }