Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-12426

Add Field::type_handler()

    XMLWordPrintable

Details

    Description

      Under terms of this task we'll add a new method into the class Field, for symmetry with the class Item:

      virtual const Type_handler *type_handler() const;
      

      We'll also change methods Field::type(), Field::real_type(), Field::cmp_type(), Field::result_type() to be non-virtual, they will use the corresponding type_handler() methods as follows:

      enum_field_types type() const
      {
        return type_handler()->field_type();
      }
      enum_field_types real_type() const
      {
        return type_handler()->real_field_type();
      }
      Item_result result_type () const
      {
        return type_handler()->result_type();
      }
      Item_result cmp_type () const
      {
        return type_handler()->cmp_type();
      }
      

      We'll also move the virtual method Field::cast_to_int_type_handler() from Field to Type_handler.

      We won't change or move Field::binlog_type() for now. It will be done in a separate task.

      Attachments

        Issue Links

          Activity

            People

              bar Alexander Barkov
              bar Alexander Barkov
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Git Integration

                  Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.