test_class.file: api/src/test/java/net/adamcin/oakpal/api/SimpleViolationTest.java
test_class.identifier: SimpleViolationTest
test_case.body: @Test
      public void testEquals() {
          final Severity severity = Severity.MINOR;
          final PackageId packId = PackageId.fromString("my_pack");
          final String description = "some description";
          final Violation violation = new Violation() {
              @Override
              public Severity getSeverity() {
                  return severity;
              }
  
              @Override
              public Collection<PackageId> getPackages() {
                  return Collections.singletonList(packId);
              }
  
              @Override
              public String getDescription() {
                  return description;
              }
          };
  
          final JsonObject json = violation.toJson();
          final SimpleViolation simpleViolation = SimpleViolation.fromJson(json);
          assertNotEquals("SimpleViolation not equal to Violation", simpleViolation, violation);
          final SimpleViolation simpleViolationCopy = SimpleViolation.fromReported(violation);
          assertEquals("SimpleViolation equal to copy SimpleViolation", simpleViolation, simpleViolationCopy);
  
          // also hashCode
          assertNotEquals("SimpleViolation hashCode not equal to Violation hashCode",
                  simpleViolation.hashCode(), violation.hashCode());
          assertEquals("SimpleViolation hashCode equal to copy SimpleViolation hashCode",
                  simpleViolation.hashCode(), simpleViolationCopy.hashCode());
      }
test_case.class_method_signature: SimpleViolationTest.testEquals()
test_case.full_signature: @Test public void testEquals()
test_case.identifier: testEquals
test_case.invocations: fromString singletonList toJson fromJson assertNotEquals fromReported assertEquals assertNotEquals hashCode hashCode assertEquals hashCode hashCode
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testEquals()
focal_class.declarator: severity
focal_class.modifier: private final
focal_class.original_string: private final Severity severity;
focal_class.type: Severity
focal_class.var_name: severity
focal_class.declarator: description
focal_class.modifier: private final
focal_class.original_string: private final String description;
focal_class.type: String
focal_class.var_name: description
focal_class.declarator: packages
focal_class.modifier: private final
focal_class.original_string: private final List<PackageId> packages;
focal_class.type: List<PackageId>
focal_class.var_name: packages
focal_class.file: api/src/main/java/net/adamcin/oakpal/api/SimpleViolation.java
focal_class.identifier: SimpleViolation
focal_class.interfaces: implements Violation
focal_class.class_method_signature: SimpleViolation.SimpleViolation(final Severity severity, final String description, final PackageId... packages)
focal_class.full_signature: public  SimpleViolation(final Severity severity, final String description, final PackageId... packages)
focal_class.identifier: SimpleViolation
focal_class.modifiers: public
focal_class.parameters: (final Severity severity, final String description, final PackageId... packages)
focal_class.signature:  SimpleViolation(final Severity severity, final String description, final PackageId... packages)
focal_class.class_method_signature: SimpleViolation.SimpleViolation(final Severity severity, final String description, final List<PackageId> packages)
focal_class.full_signature: public  SimpleViolation(final Severity severity, final String description, final List<PackageId> packages)
focal_class.identifier: SimpleViolation
focal_class.modifiers: public
focal_class.parameters: (final Severity severity, final String description, final List<PackageId> packages)
focal_class.signature:  SimpleViolation(final Severity severity, final String description, final List<PackageId> packages)
focal_class.class_method_signature: SimpleViolation.builder()
focal_class.full_signature: public static Builder builder()
focal_class.identifier: builder
focal_class.modifiers: public static
focal_class.parameters: ()
focal_class.return: Builder
focal_class.signature: Builder builder()
focal_class.class_method_signature: SimpleViolation.builder(final ResourceBundle resourceBundle)
focal_class.full_signature: public static Builder builder(final ResourceBundle resourceBundle)
focal_class.identifier: builder
focal_class.modifiers: public static
focal_class.parameters: (final ResourceBundle resourceBundle)
focal_class.return: Builder
focal_class.signature: Builder builder(final ResourceBundle resourceBundle)
focal_class.class_method_signature: SimpleViolation.getSeverity()
focal_class.full_signature: @Override public Severity getSeverity()
focal_class.identifier: getSeverity
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: Severity
focal_class.signature: Severity getSeverity()
focal_class.class_method_signature: SimpleViolation.getPackages()
focal_class.full_signature: @Override public Collection<PackageId> getPackages()
focal_class.identifier: getPackages
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: Collection<PackageId>
focal_class.signature: Collection<PackageId> getPackages()
focal_class.class_method_signature: SimpleViolation.getDescription()
focal_class.full_signature: @Override public String getDescription()
focal_class.identifier: getDescription
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: String
focal_class.signature: String getDescription()
focal_class.class_method_signature: SimpleViolation.fromReported(final Violation violation)
focal_class.full_signature: public static SimpleViolation fromReported(final Violation violation)
focal_class.identifier: fromReported
focal_class.modifiers: public static
focal_class.parameters: (final Violation violation)
focal_class.return: SimpleViolation
focal_class.signature: SimpleViolation fromReported(final Violation violation)
focal_class.class_method_signature: SimpleViolation.fromJson(final JsonObject jsonViolation)
focal_class.full_signature: public static SimpleViolation fromJson(final JsonObject jsonViolation)
focal_class.identifier: fromJson
focal_class.modifiers: public static
focal_class.parameters: (final JsonObject jsonViolation)
focal_class.return: SimpleViolation
focal_class.signature: SimpleViolation fromJson(final JsonObject jsonViolation)
focal_class.class_method_signature: SimpleViolation.toString()
focal_class.full_signature: @Override public String toString()
focal_class.identifier: toString
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: String
focal_class.signature: String toString()
focal_class.class_method_signature: SimpleViolation.equals(final Object o)
focal_class.full_signature: @Override public boolean equals(final Object o)
focal_class.identifier: equals
focal_class.modifiers: @Override public
focal_class.parameters: (final Object o)
focal_class.return: boolean
focal_class.signature: boolean equals(final Object o)
focal_class.class_method_signature: SimpleViolation.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_method.body: @Override
      public boolean equals(final Object o) {
          if (this == o) return true;
          if (o == null || getClass() != o.getClass()) return false;
          SimpleViolation that = (SimpleViolation) o;
          return severity == that.severity &&
                  Objects.equals(description, that.description) &&
                  packages.equals(that.packages);
      }
focal_method.class_method_signature: SimpleViolation.equals(final Object o)
focal_method.full_signature: @Override public boolean equals(final Object o)
focal_method.identifier: equals
focal_method.invocations: getClass getClass equals equals
focal_method.modifiers: @Override public
focal_method.parameters: (final Object o)
focal_method.return: boolean
focal_method.signature: boolean equals(final Object o)