Package com.opengamma.livedata.msg

Examples of com.opengamma.livedata.msg.EntitlementResponse


    Map<LiveDataSpecification, Boolean> isEntitledMap = _delegate.isEntitled(entitlementRequest.getUser(), entitlementRequest.getLiveDataSpecifications());
   
    ArrayList<EntitlementResponse> responses = new ArrayList<EntitlementResponse>();
    for (LiveDataSpecification spec : entitlementRequest.getLiveDataSpecifications()) {
      boolean isEntitled = isEntitledMap.get(spec);
      EntitlementResponse response;
      if (isEntitled) {
        response = new EntitlementResponse(spec, true);
      } else {
        response = new EntitlementResponse(spec, false, entitlementRequest.getUser() + " is not entitled to " + spec);
      }
      responses.add(response);
    }
    EntitlementResponseMsg response = new EntitlementResponseMsg(responses);
    return response.toFudgeMsg(new FudgeSerializer(deserializer.getFudgeContext()));
  }
View Full Code Here

TOP

Related Classes of com.opengamma.livedata.msg.EntitlementResponse

Copyright © 2018 www.massapicom. 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.