Class: NetCDF::VariableWriter
- Defined in:
- lib/netcdf/variable.rb
Overview
Instance Attribute Summary
Attributes inherited from Variable
#attributes, #dimensions, #index_iterator
Attributes inherited from CDMNode
Instance Method Summary collapse
-
#remove_attribute(attribute, ignore_case = false) ⇒ Object
———————————————————————————— Remove an Attribute : uses the attribute hashCode to find it.
-
#reset_dimensions ⇒ Object
———————————————————————————— Reset the dimension array.
-
#reset_shape ⇒ Object
———————————————————————————— Use when dimensions have changed, to recalculate the shape.
Methods inherited from Variable
#cached_data?, #caching=, #caching?, #coordinate_variable?, #create_new_cache, #extra_info, #find_attribute, #find_attributes, #find_dimension_index, #find_dimensions, #get_data_type, #get_description, #get_dimension, #get_dimensions_string, #get_element_size, #get_name_and_dimensions, #get_rank, #get_shape, #get_size, #get_units_string, #immutable?, #invalidate_cache, #metadata?, #print, #read, #read_scalar, #scalar?, #section, #set_cached_data, #to_string, #to_string_debug, #unlimited?, #unsigned?, #variable_length?
Methods inherited from CDMNode
#get_full_name, #get_short_name, #initialize
Constructor Details
This class inherits a constructor from NetCDF::CDMNode
Instance Method Details
#remove_attribute(attribute, ignore_case = false) ⇒ Object
Remove an Attribute : uses the attribute hashCode to find it.
415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 |
# File 'lib/netcdf/variable.rb', line 415 def remove_attribute(attribute, ignore_case = false) if (attribute.is_a? String) if (ignore_case) @netcdf_elmt.removeAttributeIgnoreCase(attribute) else @netcdf_elmt.removeAttribute(attribute) end elsif (attribute.is_a? NetCDF::Attribute) @netcdf_elmt.remove(attribute.netcdf_elmt) else raise "Given parameter is not an attribute: #{attribute}" end end |
#reset_dimensions ⇒ Object
Reset the dimension array.
435 436 437 |
# File 'lib/netcdf/variable.rb', line 435 def reset_dimensions @netcdf_elmt.resetDimensions() end |
#reset_shape ⇒ Object
Use when dimensions have changed, to recalculate the shape.
443 444 445 |
# File 'lib/netcdf/variable.rb', line 443 def reset_shape @netcdf_elmt.resetShape() end |