public virtual void getColumnTypes() { //JAVA TO C# CONVERTER WARNING: Java wildcard generics have no direct equivalent in .NET: //ORIGINAL LINE: com.google.common.collect.ArrayTable<int, int, com.opengamma.strata.collect.result.Result<?>> table = com.google.common.collect.ArrayTable.create(INDICES, INDICES); ArrayTable <int, int, Result <object> > table = ArrayTable.create(INDICES, INDICES); table.put(0, 0, Result.success(1)); table.put(0, 1, Result.success("abc")); table.put(1, 0, Result.success(2)); table.put(1, 1, Result.success("def")); IList <Type> columnTypes = TradeReportFormatter.INSTANCE.getColumnTypes(report(table)); assertThat(columnTypes).isEqualTo(ImmutableList.of(typeof(Integer), typeof(string))); }
public virtual void getColumnTypesWithAllFailures() { ImmutableList <int> indices = ImmutableList.of(0, 1); //JAVA TO C# CONVERTER WARNING: Java wildcard generics have no direct equivalent in .NET: //ORIGINAL LINE: com.google.common.collect.ArrayTable<int, int, com.opengamma.strata.collect.result.Result<?>> table = com.google.common.collect.ArrayTable.create(indices, indices); ArrayTable <int, int, Result <object> > table = ArrayTable.create(indices, indices); table.put(0, 0, Result.failure(FailureReason.ERROR, "fail")); table.put(0, 1, Result.failure(FailureReason.ERROR, "fail")); table.put(1, 0, Result.failure(FailureReason.ERROR, "fail")); table.put(1, 1, Result.failure(FailureReason.ERROR, "fail")); IList <Type> columnTypes = TradeReportFormatter.INSTANCE.getColumnTypes(report(table)); assertThat(columnTypes).isEqualTo(ImmutableList.of(typeof(object), typeof(object))); }