Sha256: 7677f64eb6e2cafa429a0578b5aed2133072bb1c63af6082cc5df99b904949d7

Contents?: true

Size: 1.1 KB

Versions: 32

Compression:

Stored size: 1.1 KB

Contents

#include "Data_Type.hpp"

Rice::Data_Type_Base::Casters * Rice::Data_Type_Base::casters_ = 0;

Rice::Data_Type_Base::
Data_Type_Base()
  : Module_impl<Class, Data_Type_Base>()
{
}

Rice::Data_Type_Base::
Data_Type_Base(VALUE v)
  : Module_impl<Class, Data_Type_Base>(v)
{
}

Rice::Data_Type_Base::
~Data_Type_Base()
{
}

Rice::Data_Type_Base::Casters &
Rice::Data_Type_Base::
casters()
{
  // Initialize the casters_ if it is null
  if (!casters_)
  {
    // First, see if it has been previously registered with the
    // interpreter (possibly by another extension)
    Class object(rb_cObject);
    Object casters_object(object.attr_get("__rice_casters__"));

    if (casters_object.is_nil())
    {
      // If it is unset, then set it for the first time
      Data_Object<Casters> casters(
          new Casters,
          rb_cObject);
      object.iv_set("__rice_casters__", casters);
      casters_ = casters.get();
    }
    else
    {
      // If it is set, then use the existing value
      Data_Object<Casters> casters(
          casters_object);
      casters_ = casters.get();
    }
  }

  return *casters_;
}

Version data entries

32 entries across 32 versions & 5 rubygems

Version Path
rice-3.0.0 rice/Data_Type.cpp
rice2-2.2.1 rice/Data_Type.cpp
rice2-2.2.0 rice/Data_Type.cpp
rice-2.2.0 rice/Data_Type.cpp
rice-2.1.3 rice/Data_Type.cpp
rice-2.1.2 rice/Data_Type.cpp
rice-2.1.1 rice/Data_Type.cpp
rice-2.1.0 rice/Data_Type.cpp
rice-2.0.0 rice/Data_Type.cpp
rice-1.7.0 rice/Data_Type.cpp
rice-1.6.3 rice/Data_Type.cpp
rice-1.6.2 rice/Data_Type.cpp
rice-1.6.1 rice/Data_Type.cpp
rice-1.6.0 rice/Data_Type.cpp
rice-1.6.0.pre rice/Data_Type.cpp
rice-1.5.3 rice/Data_Type.cpp
rice-1.5.2 rice/Data_Type.cpp
keyme-rice-1.5.1.keyme1 rice/Data_Type.cpp
keyme-rice-1.5.1.keyme rice/Data_Type.cpp
rice-1.5.1 rice/Data_Type.cpp