Documentation Center

  • Trial Software
  • Product Updates

Contents

H5P.get_fclose_degree

File close degree

Syntax

degree = H5P.get_fclose_degree(fapl_id)

Description

degree = H5P.get_fclose_degree(fapl_id) returns the current setting of the file close degree property fc_degree in the file access property list specified by fapl_id. Possible return values are: H5F_CLOSE_DEFAULT, H5F_CLOSE_WEAK, H5F_CLOSE_SEMI, or H5F_CLOSE_STRONG.

Examples

fid = H5F.open('example.h5');
fapl = H5F.get_access_plist(fid);
degree = H5P.get_fclose_degree(fapl);
switch(degree)
    case H5ML.get_constant_value('H5F_CLOSE_DEFAULT')
        fprintf('file close degree is default\n');
    case H5ML.get_constant_value('H5F_CLOSE_WEAK')
        fprintf('file close degree is weak\n');
    case H5ML.get_constant_value('H5F_CLOSE_SEMI')
        fprintf('close degree is semi\n');
    case H5ML.get_constant_value('H5F_CLOSE_STRONG')
        fprintf('close degree is strong\n');
end
H5P.close(fapl);
H5F.close(fid);

See Also

Was this topic helpful?