Displaying all properties on all records

You can loop through all properties on all records and display their values.

Once a Property object is obtained, its name and value can be accessed with these calls:

Java example

if (eneResults.containsNavigation()) {
  Navigation nav = eneResults.getNavigation();
  ERecList erl = nav.getERecs();
  for (int i=0; i < erl.size(); i++) {
    // Get an individual record
    ERec rec = (ERec) erl.get(i);
    // Get property map for record
    PropertyMap propsMap = rec.getProperties();
    // Get property iterator for record
    Iterator props = propsMap.entrySet().iterator();
    // Loop over properties iterator
    while (props.hasNext()) {
      // Get individual record property
      Property prop = (Property)props.next();
      // Display property name and value
      %><tr>
      <td><%= prop.getKey() %>:&nbsp;</td>
      <td><%= prop.getValue() %></td>
      </tr><%
    }
  }
}

.NET example

Navigation nav = eneResults.Navigation;
ERecList recs = nav.ERecs;
// Loop over record list
for (int i=0; i<recs.Count; i++) {
  // Get individual record
  ERec rec = (ERec)recs[i];
  // Get property map for record
  PropertyMap propsMap = rec.Properties;
  System.Collections.IList props = propmap.EntrySet;
  // Loop over properties iterator
  for (int j =0; j < props.Count; j++) {
    Property prop = (Property)props[j];
    // Display property name and value
    %><tr>
    <td><%= prop.Key %>:&nbsp;</td>
    <td><%= prop.Value %></td>
    </tr><%
  }
}