コード例 #1
0
ファイル: ecl_file.c プロジェクト: akva2/ResInsight
static void file_map_load_all( file_map_type * file_map ) {
  int index;
  for (index = 0; index < vector_get_size( file_map->kw_list); index++) {
    ecl_file_kw_type * ikw = vector_iget( file_map->kw_list , index );
    ecl_file_kw_get_kw( ikw , file_map->fortio , file_map->inv_map);
  }
}
コード例 #2
0
ファイル: ecl_file.c プロジェクト: joelmheim/ResInsight
static ecl_kw_type * file_map_iget_named_kw( const file_map_type * file_map , const char * kw, int ith) {
  ecl_file_kw_type * file_kw = file_map_iget_named_file_kw( file_map , kw , ith);
  ecl_kw_type * ecl_kw = ecl_file_kw_get_kw_ptr( file_kw , file_map->fortio , file_map->inv_map );
  if (!ecl_kw) {
    if (fortio_assert_stream_open( file_map->fortio )) {
      
      ecl_kw = ecl_file_kw_get_kw( file_kw , file_map->fortio , file_map->inv_map);
      
      if (FILE_FLAGS_SET( file_map->flags , ECL_FILE_CLOSE_STREAM))
        fortio_fclose_stream( file_map->fortio );
    }
  }
  return ecl_kw;
}
コード例 #3
0
ファイル: ecl_file.c プロジェクト: joelmheim/ResInsight
static bool file_map_load_all( file_map_type * file_map ) {
  bool loadOK = false;
  
  if (fortio_assert_stream_open( file_map->fortio )) {
    int index;
    for (index = 0; index < vector_get_size( file_map->kw_list); index++) {
      ecl_file_kw_type * ikw = vector_iget( file_map->kw_list , index );
      ecl_file_kw_get_kw( ikw , file_map->fortio , file_map->inv_map);
    }
    loadOK = true;
  }

  if (FILE_FLAGS_SET( file_map->flags , ECL_FILE_CLOSE_STREAM))
    fortio_fclose_stream( file_map->fortio );

  return loadOK;
}
コード例 #4
0
ファイル: ecl_file.c プロジェクト: akva2/ResInsight
static ecl_kw_type * file_map_iget_named_kw( const file_map_type * file_map , const char * kw, int ith) {
  ecl_file_kw_type * file_kw = file_map_iget_named_file_kw( file_map , kw , ith);
  return ecl_file_kw_get_kw( file_kw , file_map->fortio , file_map->inv_map );
}
コード例 #5
0
ファイル: ecl_file.c プロジェクト: akva2/ResInsight
static ecl_kw_type * file_map_iget_kw( const file_map_type * file_map , int index) {
  ecl_file_kw_type * file_kw = file_map_iget_file_kw( file_map , index );
  ecl_kw_type * ecl_kw       = ecl_file_kw_get_kw( file_kw , file_map->fortio , file_map->inv_map);
  
  return ecl_kw;
}