BrightSide Workbench Full Report + Source Code
org.turro.interest.Interest Class Reference

Public Member Functions

 Interest (ParticipationReason reason, IElephantEntity entity, boolean reversed)
 
ParticipationReason getReason ()
 
IElephantEntity getEntity ()
 
boolean isReversed ()
 
String getLabel ()
 
int hashCode ()
 
boolean equals (Object obj)
 

Detailed Description

Author
Lluis TurrĂ³ Cutiller lluis.nosp@m.@tur.nosp@m.ro.or.nosp@m.g

Definition at line 29 of file Interest.java.

Constructor & Destructor Documentation

◆ Interest()

org.turro.interest.Interest.Interest ( ParticipationReason  reason,
IElephantEntity  entity,
boolean  reversed 
)

Definition at line 35 of file Interest.java.

35  {
36  this.reason = reason;
37  this.entity = entity;
38  this.reversed = reversed;
39  }
Here is the caller graph for this function:

Member Function Documentation

◆ equals()

boolean org.turro.interest.Interest.equals ( Object  obj)

Definition at line 70 of file Interest.java.

70  {
71  if (this == obj) {
72  return true;
73  }
74  if (obj == null) {
75  return false;
76  }
77  if (getClass() != obj.getClass()) {
78  return false;
79  }
80  final Interest other = (Interest) obj;
81  if (this.reason != other.reason) {
82  return false;
83  }
84  return Objects.equals(this.entity.getPath(), other.entity.getPath());
85  }
Interest(ParticipationReason reason, IElephantEntity entity, boolean reversed)
Definition: Interest.java:35
Here is the call graph for this function:
Here is the caller graph for this function:

◆ getEntity()

IElephantEntity org.turro.interest.Interest.getEntity ( )

Definition at line 45 of file Interest.java.

45  {
46  return entity;
47  }
Here is the caller graph for this function:

◆ getLabel()

String org.turro.interest.Interest.getLabel ( )

Definition at line 53 of file Interest.java.

53  {
54  return Optional.ofNullable(entity)
55  .map(e -> e.getLabel())
56  .orElse("**");
57  }

◆ getReason()

ParticipationReason org.turro.interest.Interest.getReason ( )

Definition at line 41 of file Interest.java.

41  {
42  return reason;
43  }

◆ hashCode()

int org.turro.interest.Interest.hashCode ( )

Definition at line 62 of file Interest.java.

62  {
63  int hash = 7;
64  hash = 71 * hash + Objects.hashCode(this.reason);
65  hash = 71 * hash + Objects.hashCode(this.entity.getPath());
66  return hash;
67  }
Here is the call graph for this function:

◆ isReversed()

boolean org.turro.interest.Interest.isReversed ( )

Definition at line 49 of file Interest.java.

49  {
50  return reversed;
51  }

The documentation for this class was generated from the following file: