APR provide member function for implement read and write file.Apr_xml.h,Apr_xml.cpp,ReadXML.cpp.Three file for read and lock file.APR have member function for show status "apr_status_t".If programs can read and lock data,It's return zero value.See below for example.
From
Read and lock step by
apr_file_open( &fp, fName, APR_READ,
APR_OS_DEFAULT,
mp ))
If you observe APR_READ macro,It's can change to write step by "APR_WRITE".
Reference : APR tutorial


