Method: NumRu::NetCDFAtt#==

Defined in:
ext/netcdfraw.c

#==(Attb) ⇒ Object



1905
1906
1907
1908
1909
1910
1911
1912
1913
1914
1915
1916
1917
1918
1919
1920
1921
1922
1923
1924
1925
# File 'ext/netcdfraw.c', line 1905

VALUE
NetCDF_att_eql(VALUE Atta,VALUE Attb)
{
  struct NetCDFAtt *Netcdf_atta;
  struct NetCDFAtt *Netcdf_attb;
  
  if( rb_obj_is_kind_of(Attb, cNetCDFAtt) ){
      Data_Get_Struct(Atta,struct NetCDFAtt,Netcdf_atta);
      Data_Get_Struct(Attb,struct NetCDFAtt,Netcdf_attb);
  
      if(Netcdf_atta->ncid == Netcdf_atta->ncid && 
	 Netcdf_atta->varid == Netcdf_attb->varid && 
	 strcmp(Netcdf_atta->name,Netcdf_attb->name)==0){
	  return Qtrue;
      } else { 
	  return Qfalse;
      }
  } else {
      return Qfalse;
  }
}