From 7fd88267896a40a7a33cfa58f8877fe672c7d11c Mon Sep 17 00:00:00 2001 From: Shahram Najm Date: Tue, 17 Mar 2015 14:01:14 +0000 Subject: [PATCH] ECC-86: Rename all grib related API examples (Part 2) --- doxygen/examples.dox | 4 ++-- doxygen/grib_examples.dox | 4 ++-- examples/C/CMakeLists.txt | 4 ++-- examples/C/Makefile.am | 10 +++++----- examples/C/{clone.c => grib_clone.c} | 2 +- examples/C/{clone.sh => grib_clone.sh} | 4 ++-- examples/F90/CMakeLists.txt | 2 +- examples/F90/Makefile.am | 4 ++-- examples/F90/{clone.f90 => grib_clone.f90} | 2 +- examples/F90/{clone.sh => grib_clone.sh} | 2 +- examples/python/CMakeLists.txt | 2 +- examples/python/Makefile.am | 4 ++-- examples/python/{clone.py => grib_clone.py} | 0 examples/python/{clone.sh => grib_clone.sh} | 2 +- fortran/grib_f90_tail.f90 | 2 +- python/gribapi.py | 4 ++-- 16 files changed, 26 insertions(+), 26 deletions(-) rename examples/C/{clone.c => grib_clone.c} (98%) rename examples/C/{clone.sh => grib_clone.sh} (84%) rename examples/F90/{clone.f90 => grib_clone.f90} (98%) rename examples/F90/{clone.sh => grib_clone.sh} (91%) rename examples/python/{clone.py => grib_clone.py} (100%) rename examples/python/{clone.sh => grib_clone.sh} (61%) diff --git a/doxygen/examples.dox b/doxygen/examples.dox index 839ea06a9..5f3ccd1c2 100644 --- a/doxygen/examples.dox +++ b/doxygen/examples.dox @@ -22,7 +22,7 @@ defined in a message and how to iterate through them. \example set_missing.f90 How to set a missing value in the header. \example set_pv.f90 How to set the list of levels. \example samples.f90 How to create a new message from a samples. -\example clone.f90 How to clone a message. +\example grib_clone.f90 How to clone a message. \example copy_message.f90 How to copy a message in memory and create a new message. \example keys_iterator.f90 How to get the names of all the keys defined in a message and how to iterate through them. @@ -49,7 +49,7 @@ defined in a message and how to iterate through them. \example set_missing.py How to set a missing value in the header. \example count_messages.py How to count the messages in a file and loop through them. \example samples.py How to create a new message from a sample. -\example clone.py How to clone a message. +\example grib_clone.py How to clone a message. \example iterator.py How to use an iterator on latitude, longitude, values. \example keys_iterator.py How to get the names of all the keys. \example multi_write.py How to encode a multi grib message. diff --git a/doxygen/grib_examples.dox b/doxygen/grib_examples.dox index 43fa32143..eabb899cc 100644 --- a/doxygen/grib_examples.dox +++ b/doxygen/grib_examples.dox @@ -12,7 +12,7 @@ that can be taken as a starting point to write more complex programs.\n - \ref set_missing.py "set_missing.py" How to set a missing value in the header. - \ref count_messages.py "count_messages.py" How to count the messages in a file and loop through them. - \ref samples.py "samples.py" How to create a new message from a sample. -- \ref clone.py "clone.py" How to clone a message. +- \ref grib_clone.py "grib_clone.py" How to clone a message. - \ref iterator.py "iterator.py" How to use an iterator on latitude, longitude, values. - \ref keys_iterator.py "keys_iterator.py" How to get the names of all the keys. - \ref multi_write.py "multi_write.py" How to encode a multi grib message. @@ -30,7 +30,7 @@ that can be taken as a starting point to write more complex programs.\n - \ref set_missing.f90 "set_missing.f90" how to set a missing value in the header. - \ref set_pv.f90 "set_pv.f90" how to set the list of levels. - \ref samples.f90 "samples.f90" how to create a new message from a template. -- \ref clone.f90 "clone.f90" how to clone a message. +- \ref grib_clone.f90 "grib_clone.f90" how to clone a message. - \ref copy_message.f90 "copy_message.f90" how to copy a message in memory and create a new message. - \ref keys_iterator.f90 "keys_iterator.f90" how to get the names of all the keys defined in a message and how to iterate through them. diff --git a/examples/C/CMakeLists.txt b/examples/C/CMakeLists.txt index ea9a0a81a..e0d90c8eb 100644 --- a/examples/C/CMakeLists.txt +++ b/examples/C/CMakeLists.txt @@ -29,7 +29,7 @@ list( APPEND test_bins sections_copy iterator_bitmap large_grib1 - clone + grib_clone check_gaussian_grid ensemble_index get_product_kind @@ -68,7 +68,7 @@ list( APPEND tests large_grib1 get_data set_missing - clone + grib_clone sections_copy set_pv check_gaussian_grids diff --git a/examples/C/Makefile.am b/examples/C/Makefile.am index 3eea5bc98..46471dab3 100644 --- a/examples/C/Makefile.am +++ b/examples/C/Makefile.am @@ -2,7 +2,7 @@ AM_CFLAGS = @WARN_PEDANTIC@ @WERROR@ TESTS = iterator.sh grib_get_keys.sh print_data.sh set.sh keys_iterator.sh multi.sh multi_write.sh \ - precision.sh list.sh large_grib1.sh get_data.sh sections_copy.sh set_missing.sh clone.sh set_pv.sh \ + precision.sh list.sh large_grib1.sh get_data.sh sections_copy.sh set_missing.sh grib_clone.sh set_pv.sh \ check_gaussian_grids.sh \ bufr_attributes.sh bufr_clone.sh bufr_expanded.sh bufr_get_keys.sh bufr_read_header.sh bufr_read_synop.sh \ bufr_set_keys.sh bufr_subset.sh bufr_keys_iterator.sh bufr_missing.sh bufr_read_temp.sh \ @@ -10,7 +10,7 @@ TESTS = iterator.sh grib_get_keys.sh print_data.sh set.sh keys_iterator.sh multi noinst_PROGRAMS = nearest set_bitmap iterator grib_get_keys print_data set set_missing keys_iterator \ set_data mars_param values_check box multi multi2 multi_write precision \ - set_pv list sections_copy large_grib1 get_data iterator_bitmap clone new_sample \ + set_pv list sections_copy large_grib1 get_data iterator_bitmap grib_clone new_sample \ check_gaussian_grid ensemble_index points \ bufr_attributes bufr_clone bufr_expanded bufr_get_keys bufr_read_header bufr_read_synop \ bufr_get_keys bufr_subset bufr_keys_iterator bufr_set_keys bufr_missing bufr_read_temp \ @@ -40,11 +40,11 @@ list_SOURCES = list.c sections_copy_SOURCES = sections_copy.c large_grib1_SOURCES = large_grib1.c get_data_SOURCES = get_data.c -clone_SOURCES = clone.c +grib_clone_SOURCES = grib_clone.c new_sample_SOURCES = new_sample.c check_gaussian_grid_SOURCES = check_gaussian_grid.c -ensemble_index_SOURCES = ensemble_index.c -bufr_attributes_SOURCES = bufr_attributes.c +ensemble_index_SOURCES = ensemble_index.c +bufr_attributes_SOURCES = bufr_attributes.c bufr_clone_SOURCES = bufr_clone.c bufr_expanded_SOURCES = bufr_expanded.c bufr_get_keys_SOURCES = bufr_get_keys.c diff --git a/examples/C/clone.c b/examples/C/grib_clone.c similarity index 98% rename from examples/C/clone.c rename to examples/C/grib_clone.c index 1b1181ed6..5dd6c4716 100644 --- a/examples/C/clone.c +++ b/examples/C/grib_clone.c @@ -9,7 +9,7 @@ */ /* - * C Implementation: clone + * C Implementation: grib_clone * * Description: How to create a new GRIB message by cloning * an existing message. diff --git a/examples/C/clone.sh b/examples/C/grib_clone.sh similarity index 84% rename from examples/C/clone.sh rename to examples/C/grib_clone.sh index 57f163453..8cf6f8c65 100755 --- a/examples/C/clone.sh +++ b/examples/C/grib_clone.sh @@ -12,11 +12,11 @@ TEMP=cloned.grib INPUT=${data_dir}/reduced_gaussian_pressure_level.grib1 -${examples_dir}clone ${INPUT} ${TEMP} > /dev/null +${examples_dir}grib_clone ${INPUT} ${TEMP} > /dev/null ${tools_dir}grib_compare ${INPUT} ${TEMP} INPUT=${data_dir}/sample.grib2 -${examples_dir}clone ${INPUT} ${TEMP} > /dev/null +${examples_dir}grib_clone ${INPUT} ${TEMP} > /dev/null ${tools_dir}grib_compare ${INPUT} ${TEMP} rm -f ${TEMP} diff --git a/examples/F90/CMakeLists.txt b/examples/F90/CMakeLists.txt index 4f8427f56..5ea3af93e 100644 --- a/examples/F90/CMakeLists.txt +++ b/examples/F90/CMakeLists.txt @@ -28,7 +28,7 @@ list( APPEND tests read_message read_from_file get_set_uuid - clone + grib_clone bufr_attributes bufr_clone bufr_expanded diff --git a/examples/F90/Makefile.am b/examples/F90/Makefile.am index a5e04ece3..99d71c744 100644 --- a/examples/F90/Makefile.am +++ b/examples/F90/Makefile.am @@ -10,7 +10,7 @@ TESTS = copy_message.sh grib_get_keys.sh get_data.sh get_pl.sh get_pv.sh keys_it noinst_PROGRAMS = f_index f_copy_message f_grib_get_keys f_get_data f_get_pl f_get_pv f_keys_iterator \ f_multi_write f_multi f_nearest f_precision f_print_data f_set f_set_bitmap f_set_missing \ f_set_pv f_samples f_count_messages f_read_message f_read_from_file f_new_from_file \ - f_copy_namespace f_get_set_uuid f_set_gvc f_clone f_bufr_clone f_bufr_expanded f_bufr_get_keys \ + f_copy_namespace f_get_set_uuid f_set_gvc f_grib_clone f_bufr_clone f_bufr_expanded f_bufr_get_keys \ f_bufr_print_header f_bufr_print_data f_bufr_set_keys f_bufr_keys_iterator f_bufr_subset f_bufr_attributes \ f_get_product_kind f_bufr_read_temp @@ -38,7 +38,7 @@ f_new_from_file_SOURCES=new_from_file.f90 f_copy_namespace_SOURCES=copy_namespace.f90 f_get_set_uuid_SOURCES=get_set_uuid.f90 f_set_gvc_SOURCES=set_gvc.f90 -f_clone_SOURCES=clone.f90 +f_grib_clone_SOURCES=grib_clone.f90 f_bufr_attributes_SOURCES=bufr_attributes.f90 f_bufr_clone_SOURCES=bufr_clone.f90 f_bufr_expanded_SOURCES=bufr_expanded.f90 diff --git a/examples/F90/clone.f90 b/examples/F90/grib_clone.f90 similarity index 98% rename from examples/F90/clone.f90 rename to examples/F90/grib_clone.f90 index 88cc1dc2d..49f681ffb 100644 --- a/examples/F90/clone.f90 +++ b/examples/F90/grib_clone.f90 @@ -7,12 +7,12 @@ ! virtue of its status as an intergovernmental organisation nor does it submit to any jurisdiction. ! ! +! FOTRAN 90 Implementation: grib_clone ! ! Description: how to create a new GRIB message by cloning ! an existing message. ! ! -! program clone use eccodes implicit none diff --git a/examples/F90/clone.sh b/examples/F90/grib_clone.sh similarity index 91% rename from examples/F90/clone.sh rename to examples/F90/grib_clone.sh index 9f104ceda..bc2c006c1 100755 --- a/examples/F90/clone.sh +++ b/examples/F90/grib_clone.sh @@ -9,5 +9,5 @@ . ./include.sh -${examples_dir}f_clone > /dev/null +${examples_dir}f_grib_clone > /dev/null rm -f out.clone.grib1 diff --git a/examples/python/CMakeLists.txt b/examples/python/CMakeLists.txt index 62f6aa07a..94f9c3085 100644 --- a/examples/python/CMakeLists.txt +++ b/examples/python/CMakeLists.txt @@ -25,7 +25,7 @@ endforeach() # Now add each test ################################################# list( APPEND tests - clone + grib_clone count_messages grib_get_keys index diff --git a/examples/python/Makefile.am b/examples/python/Makefile.am index 8d334d036..8bbfa5e11 100644 --- a/examples/python/Makefile.am +++ b/examples/python/Makefile.am @@ -1,7 +1,7 @@ if WITH_PYTHON AM_CFLAGS = @WARN_PEDANTIC@ @WERROR@ -TESTS = clone.sh count_messages.sh grib_get_keys.sh index.sh iterator.sh keys_iterator.sh multi_write.sh nearest.sh print_data.sh \ +TESTS = grib_clone.sh count_messages.sh grib_get_keys.sh index.sh iterator.sh keys_iterator.sh multi_write.sh nearest.sh print_data.sh \ samples.sh set.sh set_missing.sh binary_message.sh set_bitmap.sh bufr_print_header.sh bufr_print_data.sh \ bufr_clone.sh bufr_get_keys.sh bufr_set_keys.sh bufr_expanded.sh bufr_keys_iterator.sh bufr_subset.sh \ bufr_attributes.sh get_product_kind.sh bufr_read_temp.sh @@ -16,7 +16,7 @@ INCLUDES = -I$(top_builddir)/src LDADD = $(top_builddir)/src/libeccodes.la DEPENDENCIES = $(LDADD) -EXTRA_DIST = $(TESTS) include.sh clone.py count_messages.py grib_get_keys.py index.py iterator.py keys_iterator.py multi_write.py \ +EXTRA_DIST = $(TESTS) include.sh grib_clone.py count_messages.py grib_get_keys.py index.py iterator.py keys_iterator.py multi_write.py \ nearest.py print_data.py samples.py set.py set_missing.py binary_message.py set_pv.py set_bitmap.py \ bufr_print_header.py bufr_print_data.py bufr_clone.py bufr_get_keys.py bufr_set_keys.py \ bufr_expanded.py bufr_keys_iterator.py bufr_subset.py bufr_attributes.py \ diff --git a/examples/python/clone.py b/examples/python/grib_clone.py similarity index 100% rename from examples/python/clone.py rename to examples/python/grib_clone.py diff --git a/examples/python/clone.sh b/examples/python/grib_clone.sh similarity index 61% rename from examples/python/clone.sh rename to examples/python/grib_clone.sh index 40b93a613..f4a363548 100755 --- a/examples/python/clone.sh +++ b/examples/python/grib_clone.sh @@ -3,5 +3,5 @@ . ./include.sh REDIRECT=/dev/null -$PYTHON clone.py 2> $REDIRECT > $REDIRECT +$PYTHON grib_clone.py 2> $REDIRECT > $REDIRECT rm -f out.clone.grib || true diff --git a/fortran/grib_f90_tail.f90 b/fortran/grib_f90_tail.f90 index d99547ba4..bc132cad1 100644 --- a/fortran/grib_f90_tail.f90 +++ b/fortran/grib_f90_tail.f90 @@ -1462,7 +1462,7 @@ !> gathered with @ref grib_get_error_string. !> !> - !> \b Examples: \ref clone.f90 "clone.f90" + !> \b Examples: \ref grib_clone.f90 "grib_clone.f90" !> !> @param gribid_src grib to be cloned !> @param gribid_dest new grib returned diff --git a/python/gribapi.py b/python/gribapi.py index 7020f6b5c..30c6ebaa3 100644 --- a/python/gribapi.py +++ b/python/gribapi.py @@ -744,7 +744,7 @@ def grib_clone(gribid_src): Create a copy of a given message (\em gribid_src) resulting in a new message in memory (\em gribid_dest) identical to the original one. - \b Examples: \ref clone.py "clone.py" + \b Examples: \ref grib_clone.py "grib_clone.py" @param gribid_src id of grib to be cloned @return id of clone @@ -1496,7 +1496,7 @@ def grib_set_values(gribid,values): The elements of the input sequence need to be convertible to a double. - \b Examples: \ref clone.py "clone.py", \ref samples.py "samples.py" + \b Examples: \ref grib_clone.py "grib_clone.py", \ref samples.py "samples.py" @param gribid id of the grib loaded in memory @param values array of values to set as tuple, list, array or numpy.ndarray