// add the AgentData map
OSDMap agentIDmap = new OSDMap(2);
agentIDmap.put("AgentID", OSD.FromUUID(AgentID));
agentIDmap.put("QueryID", OSD.FromUUID(QueryID));
OSDArray agentDataArray = new OSDArray();
agentDataArray.add(agentIDmap);
map.put("AgentData", agentDataArray);
// add the QueryData map
OSDArray dataBlocksArray = new OSDArray(QueryDataBlocks.length);
for (int i = 0; i < QueryDataBlocks.length; i++)
{
OSDMap queryDataMap = new OSDMap(14);
queryDataMap.put("ActualArea", OSD.FromInteger(QueryDataBlocks[i].ActualArea));
queryDataMap.put("BillableArea", OSD.FromInteger(QueryDataBlocks[i].BillableArea));
queryDataMap.put("Desc", OSD.FromString(QueryDataBlocks[i].Description));
queryDataMap.put("Dwell", OSD.FromReal(QueryDataBlocks[i].Dwell));
queryDataMap.put("Flags", OSD.FromInteger(QueryDataBlocks[i].Flags));
queryDataMap.put("GlobalX", OSD.FromReal(QueryDataBlocks[i].GlobalX));
queryDataMap.put("GlobalY", OSD.FromReal(QueryDataBlocks[i].GlobalY));
queryDataMap.put("GlobalZ", OSD.FromReal(QueryDataBlocks[i].GlobalZ));
queryDataMap.put("Name", OSD.FromString(QueryDataBlocks[i].Name));
queryDataMap.put("OwnerID", OSD.FromUUID(QueryDataBlocks[i].OwnerID));
queryDataMap.put("Price", OSD.FromInteger(QueryDataBlocks[i].Price));
queryDataMap.put("SimName", OSD.FromString(QueryDataBlocks[i].SimName));
queryDataMap.put("SnapshotID", OSD.FromUUID(QueryDataBlocks[i].SnapShotID));
queryDataMap.put("ProductSKU", OSD.FromString(QueryDataBlocks[i].ProductSku));
dataBlocksArray.add(queryDataMap);
}
map.put("QueryData", dataBlocksArray);
// add the TransactionData map
OSDMap transMap = new OSDMap(1);
transMap.put("TransactionID", OSD.FromUUID(TransactionID));
OSDArray transArray = new OSDArray();
transArray.add(transMap);
map.put("TransactionData", transArray);
return map;
}