Package com.opengamma.engine.cache.msg

Examples of com.opengamma.engine.cache.msg.IdentifierLookupResponse


  }

  @Override
  public long getIdentifier(final ValueSpecification spec) {
    final IdentifierLookupRequest request = new IdentifierLookupRequest(Collections.singleton(spec));
    final IdentifierLookupResponse response = getRemoteCacheClient().sendGetMessage(request, IdentifierLookupResponse.class);
    return response.getIdentifier().get(0);
  }
View Full Code Here


  }

  @Override
  public Object2LongMap<ValueSpecification> getIdentifiers(Collection<ValueSpecification> specs) {
    final IdentifierLookupRequest request = new IdentifierLookupRequest(specs);
    final IdentifierLookupResponse response = getRemoteCacheClient().sendGetMessage(request, IdentifierLookupResponse.class);
    final List<Long> identifiers = response.getIdentifier();
    final Object2LongMap<ValueSpecification> identifierMap = new Object2LongOpenHashMap<ValueSpecification>();
    int i = 0;
    for (ValueSpecification spec : request.getSpecification()) {
      identifierMap.put(spec, identifiers.get(i++));
    }
View Full Code Here

      identifiers = new ArrayList<Long>(identifierMap.size());
      for (ValueSpecification specEntry : spec) {
        identifiers.add(identifierMap.get(specEntry));
      }
    }
    final IdentifierLookupResponse response = new IdentifierLookupResponse(identifiers);
    return response;
  }
View Full Code Here

TOP

Related Classes of com.opengamma.engine.cache.msg.IdentifierLookupResponse

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.