test_class.declarator: bitsProvider
test_class.modifier: private
test_class.original_string: private PrivilegeBitsProvider bitsProvider;
test_class.type: PrivilegeBitsProvider
test_class.var_name: bitsProvider
test_class.declarator: entryA
test_class.modifier: private
test_class.original_string: private AbstractEntry entryA;
test_class.type: AbstractEntry
test_class.var_name: entryA
test_class.declarator: entryB
test_class.modifier: private
test_class.original_string: private AbstractEntry entryB;
test_class.type: AbstractEntry
test_class.var_name: entryB
test_class.declarator: restriction
test_class.modifier: private
test_class.original_string: private Restriction restriction;
test_class.type: Restriction
test_class.var_name: restriction
test_class.file: oak-authorization-principalbased/src/test/java/org/apache/jackrabbit/oak/spi/security/authorization/principalbased/impl/AbstractEntryTest.java
test_class.identifier: AbstractEntryTest
test_class.superclass: extends AbstractPrincipalBasedTest
test_case.body: @Test
      public void testEquals() throws Exception {
          assertNotEquals(entryA, entryB);
          assertNotEquals(entryB, entryA);
  
          assertEquals(entryA, entryA);
  
          // equivalent entry -> equals
          assertEquals(entryA, new TestEntry(entryA));
          assertEquals(entryB, new TestEntry(entryB));
  
          // different restrictions -> different hash
          AbstractEntry differentRestriction = new TestEntry(entryA.getOakPath(), entryA.getPrincipal(), entryA.getPrivilegeBits(), restriction);
          assertNotEquals(entryA, differentRestriction);
  
          // different path -> different hash
          AbstractEntry differentPath = new TestEntry(PathUtils.ROOT_PATH, entryA.getPrincipal(), entryA.getPrivilegeBits(), entryA.getRestrictions().toArray(new Restriction[0]));
          assertNotEquals(entryA, differentPath);
  
          // different path -> different hash
          AbstractEntry differentPrincipal = new TestEntry(entryB.getOakPath(), EveryonePrincipal.getInstance(), entryB.getPrivilegeBits(), entryB.getRestrictions().toArray(new Restriction[0]));
          assertNotEquals(entryB, differentPath);
  
          // different path -> different hash
          AbstractEntry differentPrivs = new TestEntry(entryB.getOakPath(), entryB.getPrincipal(), bitsProvider.getBits(PrivilegeConstants.JCR_READ), entryB.getRestrictions().toArray(new Restriction[0]));
          assertNotEquals(entryB, differentPrivs);
      }
test_case.class_method_signature: AbstractEntryTest.testEquals()
test_case.full_signature: @Test public void testEquals()
test_case.identifier: testEquals
test_case.invocations: assertNotEquals assertNotEquals assertEquals assertEquals assertEquals getOakPath getPrincipal getPrivilegeBits assertNotEquals getPrincipal getPrivilegeBits toArray getRestrictions assertNotEquals getOakPath getInstance getPrivilegeBits toArray getRestrictions assertNotEquals getOakPath getPrincipal getBits toArray getRestrictions assertNotEquals
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testEquals()
focal_class.declarator: oakPath
focal_class.modifier: private final
focal_class.original_string: private final String oakPath;
focal_class.type: String
focal_class.var_name: oakPath
focal_class.declarator: hashCode
focal_class.modifier: private
focal_class.original_string: private int hashCode;
focal_class.type: int
focal_class.var_name: hashCode
focal_class.file: oak-authorization-principalbased/src/main/java/org/apache/jackrabbit/oak/spi/security/authorization/principalbased/impl/AbstractEntry.java
focal_class.identifier: AbstractEntry
focal_class.interfaces: implements PrincipalAccessControlList.Entry
focal_class.class_method_signature: AbstractEntry.AbstractEntry(@Nullable String oakPath, @NotNull Principal principal, @NotNull PrivilegeBits privilegeBits, @NotNull Set<Restriction> restrictions, @NotNull NamePathMapper namePathMapper)
focal_class.full_signature:   AbstractEntry(@Nullable String oakPath, @NotNull Principal principal, @NotNull PrivilegeBits privilegeBits, @NotNull Set<Restriction> restrictions, @NotNull NamePathMapper namePathMapper)
focal_class.identifier: AbstractEntry
focal_class.parameters: (@Nullable String oakPath, @NotNull Principal principal, @NotNull PrivilegeBits privilegeBits, @NotNull Set<Restriction> restrictions, @NotNull NamePathMapper namePathMapper)
focal_class.signature:  AbstractEntry(@Nullable String oakPath, @NotNull Principal principal, @NotNull PrivilegeBits privilegeBits, @NotNull Set<Restriction> restrictions, @NotNull NamePathMapper namePathMapper)
focal_class.class_method_signature: AbstractEntry.getOakPath()
focal_class.full_signature: @Nullable String getOakPath()
focal_class.identifier: getOakPath
focal_class.modifiers: @Nullable
focal_class.parameters: ()
focal_class.return: String
focal_class.signature: String getOakPath()
focal_class.class_method_signature: AbstractEntry.getNamePathMapper()
focal_class.full_signature: @NotNull abstract NamePathMapper getNamePathMapper()
focal_class.identifier: getNamePathMapper
focal_class.modifiers: @NotNull abstract
focal_class.parameters: ()
focal_class.return: NamePathMapper
focal_class.signature: NamePathMapper getNamePathMapper()
focal_class.class_method_signature: AbstractEntry.getEffectivePath()
focal_class.full_signature: @Override @Nullable public String getEffectivePath()
focal_class.identifier: getEffectivePath
focal_class.modifiers: @Override @Nullable public
focal_class.parameters: ()
focal_class.return: String
focal_class.signature: String getEffectivePath()
focal_class.class_method_signature: AbstractEntry.hashCode()
focal_class.full_signature: @Override public int hashCode()
focal_class.identifier: hashCode
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: int
focal_class.signature: int hashCode()
focal_class.class_method_signature: AbstractEntry.equals(Object obj)
focal_class.full_signature: @Override public boolean equals(Object obj)
focal_class.identifier: equals
focal_class.modifiers: @Override public
focal_class.parameters: (Object obj)
focal_class.return: boolean
focal_class.signature: boolean equals(Object obj)
focal_class.class_method_signature: AbstractEntry.equivalentPath(@Nullable String otherPath)
focal_class.full_signature: private boolean equivalentPath(@Nullable String otherPath)
focal_class.identifier: equivalentPath
focal_class.modifiers: private
focal_class.parameters: (@Nullable String otherPath)
focal_class.return: boolean
focal_class.signature: boolean equivalentPath(@Nullable String otherPath)
focal_class.superclass: extends ACE
focal_method.body: @Override
      public boolean equals(Object obj) {
          if (obj == this) {
              return true;
          }
          if (obj instanceof AbstractEntry) {
              AbstractEntry other = (AbstractEntry) obj;
              return equivalentPath(other.oakPath) && super.equals(obj);
          }
          return false;
      }
focal_method.class_method_signature: AbstractEntry.equals(Object obj)
focal_method.full_signature: @Override public boolean equals(Object obj)
focal_method.identifier: equals
focal_method.invocations: equivalentPath equals
focal_method.modifiers: @Override public
focal_method.parameters: (Object obj)
focal_method.return: boolean
focal_method.signature: boolean equals(Object obj)