View Javadoc
1   /*
2    * Licensed to the Apache Software Foundation (ASF) under one
3    * or more contributor license agreements.  See the NOTICE file
4    * distributed with this work for additional information
5    * regarding copyright ownership.  The ASF licenses this file
6    * to you under the Apache License, Version 2.0 (the
7    * "License"); you may not use this file except in compliance
8    * with the License.  You may obtain a copy of the License at
9    *
10   *   http://www.apache.org/licenses/LICENSE-2.0
11   *
12   * Unless required by applicable law or agreed to in writing,
13   * software distributed under the License is distributed on an
14   * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15   * KIND, either express or implied.  See the License for the
16   * specific language governing permissions and limitations
17   * under the License.
18   */
19  package org.eclipse.aether.impl;
20  
21  import java.util.Collection;
22  
23  import org.eclipse.aether.RepositorySystemSession;
24  import org.eclipse.aether.collection.CollectRequest;
25  import org.eclipse.aether.deployment.DeployRequest;
26  import org.eclipse.aether.installation.InstallRequest;
27  import org.eclipse.aether.repository.LocalRepository;
28  import org.eclipse.aether.repository.RemoteRepository;
29  import org.eclipse.aether.resolution.ArtifactDescriptorRequest;
30  import org.eclipse.aether.resolution.ArtifactRequest;
31  import org.eclipse.aether.resolution.DependencyRequest;
32  import org.eclipse.aether.resolution.MetadataRequest;
33  import org.eclipse.aether.resolution.VersionRangeRequest;
34  import org.eclipse.aether.resolution.VersionRequest;
35  
36  /**
37   * Validator used by {@link org.eclipse.aether.RepositorySystem}. All method throw {@link IllegalArgumentException}.
38   */
39  public interface RepositorySystemValidator {
40      void validateVersionRequest(RepositorySystemSession session, VersionRequest request);
41  
42      void validateVersionRangeRequest(RepositorySystemSession session, VersionRangeRequest request);
43  
44      void validateArtifactDescriptorRequest(RepositorySystemSession session, ArtifactDescriptorRequest request);
45  
46      void validateArtifactRequests(RepositorySystemSession session, Collection<? extends ArtifactRequest> requests);
47  
48      void validateMetadataRequests(RepositorySystemSession session, Collection<? extends MetadataRequest> requests);
49  
50      void validateCollectRequest(RepositorySystemSession session, CollectRequest request);
51  
52      void validateDependencyRequest(RepositorySystemSession session, DependencyRequest request);
53  
54      void validateInstallRequest(RepositorySystemSession session, InstallRequest request);
55  
56      void validateDeployRequest(RepositorySystemSession session, DeployRequest request);
57  
58      void validateLocalRepositories(RepositorySystemSession session, Collection<LocalRepository> repositories);
59  
60      void validateRemoteRepositories(RepositorySystemSession session, Collection<RemoteRepository> repositories);
61  }