@Test public void testHashCode() { org.kie.workbench.common.stunner.bpmn.definition.property.diagram.DiagramSet a = new org.kie.workbench.common.stunner.bpmn.definition.property.diagram.DiagramSet(); org.kie.workbench.common.stunner.bpmn.definition.property.diagram.DiagramSet b = new org.kie.workbench.common.stunner.bpmn.definition.property.diagram.DiagramSet(); assertEquals(a.hashCode(), b.hashCode()); DefaultImport defaultImport = new DefaultImport("className"); WSDLImport wsdlImport = new WSDLImport("location", "namespace"); ImportsValue importsValue = new ImportsValue(); importsValue.addImport(defaultImport); importsValue.addImport(wsdlImport); org.kie.workbench.common.stunner.bpmn.definition.property.diagram.DiagramSet c = new org.kie.workbench.common.stunner.bpmn.definition.property.diagram.DiagramSet(); c.setImports(new Imports(importsValue)); org.kie.workbench.common.stunner.bpmn.definition.property.diagram.DiagramSet d = new org.kie.workbench.common.stunner.bpmn.definition.property.diagram.DiagramSet(); assertNotEquals(c.hashCode(), d.hashCode()); }
@Override public int hashCode() { return HashUtil.combineHashCodes(Objects.hashCode(name), Objects.hashCode(documentation), Objects.hashCode(id), Objects.hashCode(packageProperty), Objects.hashCode(processType), Objects.hashCode(version), Objects.hashCode(adHoc), Objects.hashCode(processInstanceDescription), Objects.hashCode(executable), Objects.hashCode(slaDueDate)); }
DiagramSet implements BaseDiagramSet { @Override public int hashCode() { return HashUtil.combineHashCodes(Objects.hashCode(name), Objects.hashCode(documentation), Objects.hashCode(id), Objects.hashCode(packageProperty), Objects.hashCode(processType), Objects.hashCode(version), Objects.hashCode(adHoc), Objects.hashCode(processInstanceDescription), Objects.hashCode(executable), Objects.hashCode(slaDueDate)); } }
DiagramSet implements BaseDiagramSet { @Override public int hashCode() { return HashUtil.combineHashCodes(Objects.hashCode(name), Objects.hashCode(documentation), Objects.hashCode(id), Objects.hashCode(packageProperty), Objects.hashCode(processType), Objects.hashCode(version), Objects.hashCode(adHoc), Objects.hashCode(processInstanceDescription), Objects.hashCode(executable), Objects.hashCode(slaDueDate)); } DiagramSet();  DiagramSet(final @MapsTo("name") Name name,
                      final @MapsTo("documentation") Documentation documentation,
                      final @MapsTo("id") Id id,
                      final @MapsTo("packageProperty") Package packageProperty,
                      final @MapsTo("processType") ProcessType processType,
                      final @MapsTo("version") Version version,
                      final @MapsTo("adHoc") AdHoc adHoc,
                      final @MapsTo("processInstanceDescription") ProcessInstanceDescription processInstanceDescription,
                      final @MapsTo("imports") Imports imports,
                      final @MapsTo("executable") Executable executable,
                      final @MapsTo("slaDueDate") SLADueDate slaDueDate);  DiagramSet(final String name); }
DiagramSet implements BaseDiagramSet { @Override public int hashCode() { return HashUtil.combineHashCodes(Objects.hashCode(name), Objects.hashCode(documentation), Objects.hashCode(id), Objects.hashCode(packageProperty), Objects.hashCode(processType), Objects.hashCode(version), Objects.hashCode(adHoc), Objects.hashCode(processInstanceDescription), Objects.hashCode(executable), Objects.hashCode(slaDueDate)); } DiagramSet();  DiagramSet(final @MapsTo("name") Name name,
                      final @MapsTo("documentation") Documentation documentation,
                      final @MapsTo("id") Id id,
                      final @MapsTo("packageProperty") Package packageProperty,
                      final @MapsTo("processType") ProcessType processType,
                      final @MapsTo("version") Version version,
                      final @MapsTo("adHoc") AdHoc adHoc,
                      final @MapsTo("processInstanceDescription") ProcessInstanceDescription processInstanceDescription,
                      final @MapsTo("imports") Imports imports,
                      final @MapsTo("executable") Executable executable,
                      final @MapsTo("slaDueDate") SLADueDate slaDueDate);  DiagramSet(final String name); @Override Name getName(); void setName(final Name name); @Override Documentation getDocumentation(); void setDocumentation(final Documentation documentation); @Override Id getId(); void setId(Id id); @Override Package getPackageProperty(); void setPackageProperty(final Package packageProperty); @Override ProcessType getProcessType(); void setProcessType(ProcessType processType); @Override Version getVersion(); void setVersion(final Version version); @Override AdHoc getAdHoc(); void setAdHoc(final AdHoc adHoc); @Override ProcessInstanceDescription getProcessInstanceDescription(); void setProcessInstanceDescription(final ProcessInstanceDescription processInstanceDescription); @Override Imports getImports(); void setImports(Imports imports); @Override Executable getExecutable(); void setExecutable(final Executable executable); @Override SLADueDate getSlaDueDate(); void setSlaDueDate(final SLADueDate slaDueDate); @Override int hashCode(); @Override boolean equals(Object o); }
DiagramSet implements BaseDiagramSet { @Override public int hashCode() { return HashUtil.combineHashCodes(Objects.hashCode(name), Objects.hashCode(documentation), Objects.hashCode(id), Objects.hashCode(packageProperty), Objects.hashCode(processType), Objects.hashCode(version), Objects.hashCode(adHoc), Objects.hashCode(processInstanceDescription), Objects.hashCode(executable), Objects.hashCode(slaDueDate)); } DiagramSet();  DiagramSet(final @MapsTo("name") Name name,
                      final @MapsTo("documentation") Documentation documentation,
                      final @MapsTo("id") Id id,
                      final @MapsTo("packageProperty") Package packageProperty,
                      final @MapsTo("processType") ProcessType processType,
                      final @MapsTo("version") Version version,
                      final @MapsTo("adHoc") AdHoc adHoc,
                      final @MapsTo("processInstanceDescription") ProcessInstanceDescription processInstanceDescription,
                      final @MapsTo("imports") Imports imports,
                      final @MapsTo("executable") Executable executable,
                      final @MapsTo("slaDueDate") SLADueDate slaDueDate);  DiagramSet(final String name); @Override Name getName(); void setName(final Name name); @Override Documentation getDocumentation(); void setDocumentation(final Documentation documentation); @Override Id getId(); void setId(Id id); @Override Package getPackageProperty(); void setPackageProperty(final Package packageProperty); @Override ProcessType getProcessType(); void setProcessType(ProcessType processType); @Override Version getVersion(); void setVersion(final Version version); @Override AdHoc getAdHoc(); void setAdHoc(final AdHoc adHoc); @Override ProcessInstanceDescription getProcessInstanceDescription(); void setProcessInstanceDescription(final ProcessInstanceDescription processInstanceDescription); @Override Imports getImports(); void setImports(Imports imports); @Override Executable getExecutable(); void setExecutable(final Executable executable); @Override SLADueDate getSlaDueDate(); void setSlaDueDate(final SLADueDate slaDueDate); @Override int hashCode(); @Override boolean equals(Object o);  }