move enum{INT,DOUBLE,STRING,BIGINT}; to Dump class in dump.h
This commit is contained in:
@ -53,7 +53,6 @@ enum{ID,MOL,TYPE,ELEMENT,MASS,
|
||||
TQX,TQY,TQZ,SPIN,ERADIUS,ERVEL,ERFORCE,
|
||||
COMPUTE,FIX,VARIABLE};
|
||||
enum{LT,LE,GT,GE,EQ,NEQ};
|
||||
enum{INT,DOUBLE,STRING,BIGINT}; // same as in DumpCustom
|
||||
|
||||
/* ---------------------------------------------------------------------- */
|
||||
|
||||
@ -246,13 +245,13 @@ void DumpCustomMPIIO::init_style()
|
||||
if (format_column_user[i]) {
|
||||
vformat[i] = new char[strlen(format_column_user[i]) + 2];
|
||||
strcpy(vformat[i],format_column_user[i]);
|
||||
} else if (vtype[i] == INT && format_int_user) {
|
||||
} else if (vtype[i] == Dump::INT && format_int_user) {
|
||||
vformat[i] = new char[strlen(format_int_user) + 2];
|
||||
strcpy(vformat[i],format_int_user);
|
||||
} else if (vtype[i] == DOUBLE && format_float_user) {
|
||||
} else if (vtype[i] == Dump::DOUBLE && format_float_user) {
|
||||
vformat[i] = new char[strlen(format_float_user) + 2];
|
||||
strcpy(vformat[i],format_float_user);
|
||||
} else if (vtype[i] == BIGINT && format_bigint_user) {
|
||||
} else if (vtype[i] == Dump::BIGINT && format_bigint_user) {
|
||||
vformat[i] = new char[strlen(format_bigint_user) + 2];
|
||||
strcpy(vformat[i],format_bigint_user);
|
||||
} else {
|
||||
@ -618,11 +617,11 @@ int DumpCustomMPIIO::convert_string_omp(int n, double *mybuf)
|
||||
}
|
||||
for (int j = 0; j < size_one; j++) {
|
||||
|
||||
if (vtype[j] == INT)
|
||||
if (vtype[j] == Dump::INT)
|
||||
mpifhStringCountPerThread[tid] += sprintf(&(mpifh_buffer_line_per_thread[tid][mpifhStringCountPerThread[tid]]),vformat[j],static_cast<int> (mybuf[bufOffset[tid]+m]));
|
||||
else if (vtype[j] == DOUBLE)
|
||||
else if (vtype[j] == Dump::DOUBLE)
|
||||
mpifhStringCountPerThread[tid] += sprintf(&(mpifh_buffer_line_per_thread[tid][mpifhStringCountPerThread[tid]]),vformat[j],mybuf[bufOffset[tid]+m]);
|
||||
else if (vtype[j] == STRING)
|
||||
else if (vtype[j] == Dump::STRING)
|
||||
mpifhStringCountPerThread[tid] += sprintf(&(mpifh_buffer_line_per_thread[tid][mpifhStringCountPerThread[tid]]),vformat[j],typenames[(int) mybuf[bufOffset[tid]+m]]);
|
||||
m ++;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user