Subversion Repositories DevTools

Rev

Rev 255 | Rev 361 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 255 Rev 261
Line 356... Line 356...
356
    #       Data needs to be easy to parse at far end
356
    #       Data needs to be easy to parse at far end
357
    #
357
    #
358
    $data->Dump('finish') if ($opt_verbose);
358
    $data->Dump('finish') if ($opt_verbose);
359
    $data->Dump() if ($opt_verbose);
359
    $data->Dump() if ($opt_verbose);
360
 
360
 
361
    open (PF, ">$opt_outfile") || Error ("Cannot create file: $opt_outfile", "Reason: $!");
361
    my $mdata = '';
362
    my $joiner = '';
362
    my $joiner = '';
-
 
363
 
363
    foreach my $name ( sort $data->enum() )
364
    foreach my $name ( sort $data->enum() )
364
    {
365
    {
365
        my $value = $data->getProperty($name);
366
        my $value = $data->getProperty($name);
366
 
367
 
367
        #
368
        #
Line 369... Line 370...
369
        #   make sure that we don't have the character within the data stream
370
        #   make sure that we don't have the character within the data stream
370
        #
371
        #
371
        Error ("Metric data  contains a '$joiner_char'",
372
        Error ("Metric data  contains a '$joiner_char'",
372
               "Name: $name, Value: $value" ) if ( $value =~ m~$joiner_char~ );
373
               "Name: $name, Value: $value" ) if ( $value =~ m~$joiner_char~ );
373
 
374
 
374
        print PF "$joiner$name=$value";
375
        $mdata .= "$joiner$name=$value";
375
        $joiner = $joiner_char;
376
        $joiner = $joiner_char;
376
    }
377
    }
377
    print PF "\n";
378
    
378
    close PF;
379
    FileCreate ( $opt_outfile, $mdata );
379
}
380
}
380
 
381
 
381
 
382
 
382
#-------------------------------------------------------------------------------
383
#-------------------------------------------------------------------------------
383
#   Documentation
384
#   Documentation