Examples of atVersion()


Examples of com.opengamma.id.ObjectId.atVersion()

        ExchangeDocument doc = new ExchangeDocument(ex);
        doc.setVersionFromInstant(now.plus(1, MINUTES).plus(i * 20, SECONDS));
        replacement.add(doc);
      }

      _exgMaster.replaceVersion(baseOid.atVersion("no such uid"), replacement);
    } finally {
      _exgMaster.setClock(origClock);
    }
  }

View Full Code Here

Examples of com.opengamma.id.ObjectId.atVersion()

        ConfigDocument doc = new ConfigDocument(ConfigItem.of(val));
        doc.setVersionFromInstant(now.plus(1, MINUTES).plus(i * 20, SECONDS));
        replacement.add(doc);
      }

      _cfgMaster.replaceVersion(baseOid.atVersion("no such uid"), replacement);
    } finally {
      _cfgMaster.setClock(origClock);
    }
  }

View Full Code Here

Examples of com.opengamma.id.ObjectId.atVersion()

      @QueryParam("version") String version,
      @QueryParam("versionAsOf") String versionAsOf,
      @QueryParam("correctedTo") String correctedTo) {
    final ObjectId objectId = ObjectId.parse(idStr);
    if (version != null) {
      final Region result = getRegionSource().get(objectId.atVersion(version));
      return responseOkFudge(result);
    } else {
      final VersionCorrection vc = VersionCorrection.parse(versionAsOf, correctedTo);
      Region result = getRegionSource().get(objectId, vc);
      return responseOkFudge(result);
View Full Code Here

Examples of com.opengamma.id.ObjectId.atVersion()

      @QueryParam("versionAsOf") String versionAsOf,
      @QueryParam("correctedTo") String correctedTo) {
    final ObjectId objectId = ObjectId.parse(idStr);
    final VersionCorrection vc = VersionCorrection.parse(versionAsOf, correctedTo);
    if (version != null) {
      final Portfolio result = getPositionSource().getPortfolio(objectId.atVersion(version), vc);
      return responseOkFudge(result);
    } else {
      final Portfolio result = getPositionSource().getPortfolio(objectId, vc);
      return responseOkFudge(result);
    }
View Full Code Here

Examples of com.opengamma.id.ObjectId.atVersion()

      @QueryParam("version") String version,
      @QueryParam("versionAsOf") String versionAsOf,
      @QueryParam("correctedTo") String correctedTo) {
    final ObjectId objectId = ObjectId.parse(idStr);
    final VersionCorrection vc = VersionCorrection.parse(versionAsOf, correctedTo);
    final PortfolioNode result = getPositionSource().getPortfolioNode(objectId.atVersion(version), vc);
    return responseOkFudge(result);
  }

  @GET
  @Path("positions/{positionId}")
View Full Code Here

Examples of com.opengamma.id.ObjectId.atVersion()

      @QueryParam("versionAsOf") String versionAsOf,
      @QueryParam("correctedTo") String correctedTo) {
    final ObjectId objectId = ObjectId.parse(idStr);
    final Position result;
    if (version != null) {
      result = getPositionSource().getPosition(objectId.atVersion(version));
    } else {
      result = getPositionSource().getPosition(objectId, VersionCorrection.parse(versionAsOf, correctedTo));
    }
    return responseOkFudge(result);
  }
View Full Code Here

Examples of com.opengamma.id.ObjectId.atVersion()

  @Path("trades/{tradeId}")
  public Response getTrade(
      @PathParam("tradeId") String idStr,
      @QueryParam("version") String version) {
    final ObjectId objectId = ObjectId.parse(idStr);
    final Trade result = getPositionSource().getTrade(objectId.atVersion(version));
    return responseOkFudge(result);
  }

  //-------------------------------------------------------------------------
  /**
 
View Full Code Here

Examples of com.opengamma.id.ObjectId.atVersion()

      @QueryParam("version") String version,
      @QueryParam("versionAsOf") String versionAsOf,
      @QueryParam("correctedTo") String correctedTo) {
    final ObjectId objectId = ObjectId.parse(idStr);
    if (version != null) {
      final Exchange result = getExchangeSource().get(objectId.atVersion(version));
      return responseOkFudge(result);
    } else {
      final VersionCorrection vc = VersionCorrection.parse(versionAsOf, correctedTo);
      Exchange result = getExchangeSource().get(objectId, vc);
      return responseOkFudge(result);
View Full Code Here

Examples of com.opengamma.id.ObjectId.atVersion()

      @QueryParam(VERSION_AS_OF_PARAM) String versionAsOf,
      @QueryParam(CORRECTED_TO_PARAM) String correctedTo) {

    final ObjectId objectId = ObjectId.parse(idStr);
    if (version != null) {
      return responseOkFudge(_orgSource.get(objectId.atVersion(version)));
    } else {
      final VersionCorrection vc = VersionCorrection.parse(versionAsOf, correctedTo);
      return responseOkFudge(_orgSource.get(objectId, vc));
    }
  }
View Full Code Here

Examples of com.opengamma.id.ObjectId.atVersion()

  @Path("snapshots/{snapshotId}")
  public Response get(
      @PathParam("snapshotId") String idStr,
      @QueryParam("version") String version) {
    final ObjectId objectId = ObjectId.parse(idStr);
    final StructuredMarketDataSnapshot result = getMarketDataSnapshotSource().get(objectId.atVersion(version));
    return responseOkFudge(result);
  }

  //-------------------------------------------------------------------------
  /**
 
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.