/** Creates an {@link InferredOWLOntologyID} using three OWLAPI {@link IRI}s. */
  public InferredOWLOntologyID(
      final IRI baseOntologyIRI, final IRI baseOntologyVersionIRI, final IRI inferredOntologyIRI) {
    super(baseOntologyIRI, baseOntologyVersionIRI);

    this.inferredOntologyIRI = inferredOntologyIRI;

    // Override hashcode if inferredOntologyIRI is not null, otherwise leave the hashcode to
    // match upstream
    if (inferredOntologyIRI != null) {
      // super uses 37, so to be distinct we need to use a different prime number here, ie, 41
      this.hashCode += 41 * inferredOntologyIRI.hashCode();
    }
  }
Beispiel #2
0
 @Override
 public int hashCode() {
   return resource.hashCode();
 }