code: private void setBar(final double VALUE) {
          currentValueAngle = (VALUE - minValue) * angleStep;
          thresholdAngle    = (gauge.getThreshold() - minValue) * angleStep;
          double valueAngle = currentValueAngle > thresholdAngle ? thresholdAngle : currentValueAngle;
          dataBarOuterArc.setLargeArcFlag(valueAngle > 180);
          dataBarInnerArc.setLargeArcFlag(valueAngle > 180);
  
          dataBarOuterArc.setX(centerX + centerX * Math.sin(-Math.toRadians(valueAngle)));
          dataBarOuterArc.setY(centerY + centerX * Math.cos(-Math.toRadians(valueAngle)));
          dataBarLineToInnerArc.setX(centerX + (centerX - barWidth) * Math.sin(-Math.toRadians(valueAngle)));
          dataBarLineToInnerArc.setY(centerY + (centerX - barWidth) * Math.cos(-Math.toRadians(valueAngle)));
  
          double dataBarThresholdAngle = VALUE > gauge.getThreshold() ? currentValueAngle : thresholdAngle;
          dataBarThresholdOuterArc.setLargeArcFlag(dataBarThresholdAngle > 180 + thresholdAngle);
          dataBarThresholdInnerArc.setLargeArcFlag(dataBarThresholdAngle > 180 + thresholdAngle);
  
          dataBarThresholdOuterArc.setX(centerX + centerX * Math.sin(-Math.toRadians(dataBarThresholdAngle)));
          dataBarThresholdOuterArc.setY(centerY + centerX * Math.cos(-Math.toRadians(dataBarThresholdAngle)));
          dataBarThresholdLineToInnerArc.setX(centerX + (centerX - barWidth) * Math.sin(-Math.toRadians(dataBarThresholdAngle)));
          dataBarThresholdLineToInnerArc.setY(centerY + (centerX - barWidth) * Math.cos(-Math.toRadians(dataBarThresholdAngle)));
          dataBarThresholdInnerArc.setX(centerX + (centerX - barWidth) * Math.sin(-Math.toRadians(thresholdAngle)));
          dataBarThresholdInnerArc.setY(centerY + (centerX - barWidth) * Math.cos(-Math.toRadians(thresholdAngle)));
  
          valueText.setText(formatNumber(gauge.getLocale(), gauge.getFormatString(), gauge.getDecimals(), VALUE));
          resizeValueText();
      }
docs: ******************** Private Methods ***********************************