コード例 #1
0
 @Override
 public boolean equals(Object obj) {
   if (obj == this) {
     return true;
   }
   if (obj != null && obj.getClass() == this.getClass()) {
     ResultModelDefinition other = (ResultModelDefinition) obj;
     return JodaBeanUtils.equal(
             getAggregatePositionOutputMode(), other.getAggregatePositionOutputMode())
         && JodaBeanUtils.equal(getPositionOutputMode(), other.getPositionOutputMode())
         && JodaBeanUtils.equal(getTradeOutputMode(), other.getTradeOutputMode())
         && JodaBeanUtils.equal(getSecurityOutputMode(), other.getSecurityOutputMode())
         && JodaBeanUtils.equal(getPrimitiveOutputMode(), other.getPrimitiveOutputMode());
   }
   return false;
 }
コード例 #2
0
 /**
  * Tests whether the view has portfolio outputs enabled.
  *
  * @param viewDefinition the view definition
  * @return {@code true} if there is at least one portfolio target, {@code false} otherwise
  */
 private static boolean isPortfolioOutputEnabled(ViewDefinition viewDefinition) {
   ResultModelDefinition resultModelDefinition = viewDefinition.getResultModelDefinition();
   return resultModelDefinition.getPositionOutputMode() != ResultOutputMode.NONE
       || resultModelDefinition.getAggregatePositionOutputMode() != ResultOutputMode.NONE;
 }