@Test void toBundleSet() { Iterator<Workload.JWTBundlesResponse> iterator = Collections.emptyIterator(); try { GrpcConversionUtils.toBundleSet(iterator); } catch (JwtBundleException e) { assertEquals("JWT Bundle response from the Workload API is empty", e.getMessage()); } }
static JwtBundleSet toBundleSet(final Iterator<Workload.JWTBundlesResponse> bundlesResponseIterator) throws JwtBundleException { if (!bundlesResponseIterator.hasNext()) { throw new JwtBundleException("JWT Bundle response from the Workload API is empty"); } val bundlesResponse = bundlesResponseIterator.next(); return toBundleSet(bundlesResponse); }
GrpcConversionUtils { static JwtBundleSet toBundleSet(final Iterator<Workload.JWTBundlesResponse> bundlesResponseIterator) throws JwtBundleException { if (!bundlesResponseIterator.hasNext()) { throw new JwtBundleException("JWT Bundle response from the Workload API is empty"); } val bundlesResponse = bundlesResponseIterator.next(); return toBundleSet(bundlesResponse); } }
GrpcConversionUtils { static JwtBundleSet toBundleSet(final Iterator<Workload.JWTBundlesResponse> bundlesResponseIterator) throws JwtBundleException { if (!bundlesResponseIterator.hasNext()) { throw new JwtBundleException("JWT Bundle response from the Workload API is empty"); } val bundlesResponse = bundlesResponseIterator.next(); return toBundleSet(bundlesResponse); } private  GrpcConversionUtils(); }
GrpcConversionUtils { static JwtBundleSet toBundleSet(final Iterator<Workload.JWTBundlesResponse> bundlesResponseIterator) throws JwtBundleException { if (!bundlesResponseIterator.hasNext()) { throw new JwtBundleException("JWT Bundle response from the Workload API is empty"); } val bundlesResponse = bundlesResponseIterator.next(); return toBundleSet(bundlesResponse); } private  GrpcConversionUtils();  }
GrpcConversionUtils { static JwtBundleSet toBundleSet(final Iterator<Workload.JWTBundlesResponse> bundlesResponseIterator) throws JwtBundleException { if (!bundlesResponseIterator.hasNext()) { throw new JwtBundleException("JWT Bundle response from the Workload API is empty"); } val bundlesResponse = bundlesResponseIterator.next(); return toBundleSet(bundlesResponse); } private  GrpcConversionUtils();   }