mayconbordin / cdr-gen

A Call Detail Record (CDR) generator
MIT License
32 stars 21 forks source link

Fields Identification #5

Open daniziz opened 5 years ago

daniziz commented 5 years ago

Hi,

Really nice work, I've managed to modify my pom.xml file and I can tell for now this is the only one CDR generator that works for me!!!

Is it possible to identify the fields of the data generated? Maybe on the readme, i'm not very skilled at Java so i cant check what file generates the output: 0,01794666666,0,01799999999,16/10/2017,16/10/2017,14:55:00,15:22:00,Local,27.0

I can figure this: 0, Register ID 01794666666, Caller 0, unknown 01799999999, called 16/10/2017, start date? 16/10/2017, end date? 14:55:00, start time? 15:22:00, end time? Local, call type (this is clear) 27.0, cost?

regards!

daniziz commented 5 years ago

Hi,

Really nice work, I've managed to modify my pom.xml file and I can tell for now this is the only one CDR generator that works for me!!!

Is it possible to identify the fields of the data generated? Maybe on the readme, i'm not very skilled at Java so i cant check what file generates the output: 0,01794666666,0,01799999999,16/10/2017,16/10/2017,14:55:00,15:22:00,Local,27.0

I can figure this: 0, Register ID 01794666666, Caller 0, unknown 01799999999, called 16/10/2017, start date? 16/10/2017, end date? 14:55:00, start time? 15:22:00, end time? Local, call type (this is clear) 27.0, cost?

regards!

I've found it:

 for (Person p : customers) {
                for (Call c : p.getCalls()) {
                    fw.append(c.getId() + ","
                            + p.getPhoneNumber() + ","
                            + c.getLine() + ","
                            + c.getDestPhoneNumber() + ","
                            + c.getTime().getStart().toString(dateFormatter) + "," 
                            + c.getTime().getEnd().toString(dateFormatter) + "," 
                            + c.getTime().getStart().toString(timeFormatter) + "," 
                            + c.getTime().getEnd().toString(timeFormatter) + ","
                            + c.getType() + ","
                            + c.getCost()
                            + newLine);
                }
            }

So, 0 unknown is the line of the user configured in JSON file...

Thank you very much!