Exemplo n.º 1
0
  int checkForAdditionalDivident(
      CompanyActionVO actionVO, String rawActionLine, String otherDividentCode) {
    int st = rawActionLine.indexOf(otherDividentCode);
    if (st == -1) {
      return -1;
    }
    int en = rawActionLine.indexOf('/');
    if (en != -1 && en < st) {
      return -1;
    }

    NumberExtractor extractor = new NumberExtractor(rawActionLine.substring(st));
    if (extractor.hasMoreElements()) {
      actionVO.setDsbValue(actionVO.getDsbValue() + extractor.nextElement());
    }
    return extractor.getIndex();
  }