Examples of YieldCurveSnapshot


Examples of com.opengamma.core.marketdatasnapshot.YieldCurveSnapshot

      s_logger.warn("Snapshot does not contain any Yield Curve Snapshots.");
      return;
    }

    for (Map.Entry<YieldCurveKey, YieldCurveSnapshot> entry : yieldCurves.entrySet()) {
      YieldCurveSnapshot curve = entry.getValue();
      Map<String, String> tempRow = new HashMap<>();
      tempRow.put(SnapshotColumns.TYPE.get(), SnapshotType.YIELD_CURVE.get());
      tempRow.put(SnapshotColumns.NAME.get(), entry.getKey().getName());
      tempRow.put(SnapshotColumns.YIELD_CURVE_CURRENCY.get(), entry.getKey().getCurrency().toString());
      tempRow.put(SnapshotColumns.INSTANT.get(), curve.getValuationTime().toString());
      //Row written via writeUnstructuredMarketDataSnapshot
      writeUnstructuredMarketDataSnapshot(tempRow, curve.getValues());
    }
  }
View Full Code Here

Examples of com.opengamma.core.marketdatasnapshot.YieldCurveSnapshot

    final ExternalId testValueId = ExternalId.of("TestScheme", "Value1");
    when(snapshot.getUniqueId()).thenReturn(snapshotId);
    when(snapshot.getGlobalValues()).thenReturn(generateUnstructured(testValueId, 234d));
    final UserMarketDataSnapshot userSnapshot = new UserMarketDataSnapshot(snapshot);
    userSnapshot.init();
    final YieldCurveSnapshot yieldCurveSnapshot = mock(YieldCurveSnapshot.class);
    when(yieldCurveSnapshot.getValues()).thenReturn(generateUnstructured(testValueId, 123d));
    final Map<YieldCurveKey, YieldCurveSnapshot> yieldCurveMap = ImmutableMap.of(new YieldCurveKey(Currency.USD, "testCurve"), yieldCurveSnapshot);
    when(snapshot.getYieldCurves()).thenReturn(yieldCurveMap);
    return userSnapshot;
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.