ss_prop_t *
ss_blob_get_2pio(ss_blob_t *blob, /* Optional blob whose file settings are to be retreived. If no blob is specified then
* the library-wide defaults are returned. */
ss_prop_t *props /* Optional property list to hold the results. Only the properties defined in the list
* will be returned. If no property list is specified then a new one is created and
* all two-phase I/O properties are returned. See [Aggregation Properties]. */
)
{
SS_ENTER(ss_blob_get_2pio, ss_prop_tP);
ss_blob_2pio_t *agg=NULL;
ss_scope_t topscope=SS_SCOPE_NULL;
ss_gblob_t *gblob=NULL;
/* Get the property list */
if (!props) {
if (NULL==(props=ss_blob_init_2pio(NULL, "defaults"))) SS_ERROR(FAILED);
} else {
SS_ASSERT_TYPE(props, ss_prop_t);
}
/* Get the property values */
if (!blob) {
agg = &ss_blob_2pio_g;
} else {
if (!ss_mpi_extras((ss_pers_t**)&blob, &topscope)) SS_ERROR(FAILED);
gblob = SS_GFILE_LINK(&topscope)->gblob;
agg = &(gblob->agg);
}
/* Set the property values */
if (ss_prop_has(props, "minbufsize") && ss_prop_set_u(props, "minbufsize", agg->minbufsize)<0) SS_ERROR(FAILED);
if (ss_prop_has(props, "alignment") && ss_prop_set_u(props, "alignment", agg->alignment)<0) SS_ERROR(FAILED);
if (ss_prop_has(props, "maxaggtasks") && ss_prop_set_u(props, "maxaggtasks", agg->maxaggtasks)<0) SS_ERROR(FAILED);
if (ss_prop_has(props, "sendqueue") && ss_prop_set_u(props, "sendqueue", agg->sendqueue)<0) SS_ERROR(FAILED);
if (ss_prop_has(props, "aggbuflimit") && ss_prop_set_u(props, "aggbuflimit", agg->aggbuflimit)<0) SS_ERROR(FAILED);
if (ss_prop_has(props, "asynchdf5") && ss_prop_set_i(props, "asynchdf5", agg->asynchdf5)<0) SS_ERROR(FAILED);
if (ss_prop_has(props, "aggbase") && ss_prop_set_i(props, "aggbase", agg->aggbase)<0) SS_ERROR(FAILED);
if (ss_prop_has(props, "tpn") && ss_prop_set_i(props, "tpn", agg->tpn)<0) SS_ERROR(FAILED);
SS_CLEANUP:
SS_LEAVE(props);
}