Package com.blackhillsoftware.dcollect


package com.blackhillsoftware.dcollect
Classes for processing DCOLLECT data. DCOLLECT records are not SMF records, so they are processed slightly differently.

Instead of using the SmfRecordReader class to read records, use VRecordReader which is a generalized class for reading variable length records.

Then create DcollectRecords using DcollectRecord.from(com.blackhillsoftware.smf.VRecord).

You can then use DcollectRecord.dcurctyp() to check the record type and create the specific type as required e.g. ActiveDataset.from(com.blackhillsoftware.smf.VRecord)

 
 try (VRecordReader reader = VRecordReader.fromName("//DD:INPUT"))             
 {
     for (VRecord record : reader)           
     {
         DcollectRecord dcr = DcollectRecord.from(record);
         if (dcr.dcurctyp() == DcollectType.A)
         {
             ActiveDataset ds x = ActiveDataset.from(dcr);
             // process record                    
         }             
     }
 }
 
 

Space Calculations

Some DCOLLECT space fields are specified in KB, some in MB, and some in either KB or MB depending on a flag.

Fields that are (or may be) specified in KB have an equivalent method with a MB suffix providing the value in MB (i.e. KB / 1024) for convenience. These methods return floating point values to avoid rounding to zero for small KB values.

Examples: