1. OMG Mailing List
  2. DDS Java API (DDS-JAVA) 1.1 Revision Task Force mailing list

Open Issues

  • Issues not resolved
  • Name: dds-api-java-rtf
  • Issues Count: 1

Issues Summary

Issues Descriptions

DataReader.read should return an Iterable collection, not an Iterator

  • Status: open  
  • Source: Real-Time Innovations ( Alejandro Campos)
  • Summary:

    The current signature of read() (and take) is:

    public Sample.Iterator<TYPE> read();
    

    This operation should return an Interable collection, to be aligned with the C++PSM:

    public LoanedSamples<T> read();
    

    An Iterable collection can be used in a foreach loop, and it can be managed by a try-with-resources block to return the loan automatically. An Iterator doesn't take advantage of these features.

  • Reported: DDS-Java 1.0b2 — Wed, 24 Apr 2019 21:36 GMT
  • Updated: Wed, 24 Apr 2019 21:38 GMT