dayCounter, isInArrears);
}
@Override
public double indexFixing() {
final Settings settings = new Settings();
if (settings.isUseIndexedCoupon())
return index_.fixing(fixingDate());
if (isInArrears())
return index_.fixing(fixingDate());
else {
final Handle<YieldTermStructure> termStructure = index_.termStructure();
QL.require(termStructure != null , NULL_TERM_STRUCTURE); // QA:[RG]::verified
final Date today = settings.evaluationDate();
final Date fixing_date = fixingDate();
final IndexManager indexManager = IndexManager.getInstance();
if (fixing_date.lt(today)) {
final double pastFixing = indexManager.get (index_.name()).get(fixing_date);
QL.require(!Double.isNaN(pastFixing), "Missing fixing"); // TODO: message