/** * Gets the security identifier. * <p> * This identifier uniquely identifies the security within the system. * * @return the security identifier */ public default SecurityId getSecurityId() { return getInfo().getId(); }
/** * Gets the currency that the security is traded in. * * @return the trading currency */ public default Currency getCurrency() { return getInfo().getPriceInfo().getCurrency(); }
Optional<String> securityInfoPropertyName = security.getInfo().propertyNames().stream() .filter(p -> p.equalsIgnoreCase(firstToken)) .findFirst(); if (securityInfoPropertyName.isPresent()) { Object propertyValue = security.getInfo().property(securityInfoPropertyName.get()).get(); return propertyValue != null ? EvaluationResult.success(propertyValue, remainingTokens) : Optional<String> securityPriceInfoPropertyName = security.getInfo().getPriceInfo().propertyNames().stream() .filter(p -> p.equalsIgnoreCase(firstToken)) .findFirst(); if (securityPriceInfoPropertyName.isPresent()) { Object propertyValue = security.getInfo().getPriceInfo().property(securityPriceInfoPropertyName.get()).get(); return propertyValue != null ? EvaluationResult.success(propertyValue, remainingTokens) :