CUBRID Engine  latest
load_sa_loader.hpp
Go to the documentation of this file.
1 /*
2  * Copyright 2008 Search Solution Corporation
3  * Copyright 2016 CUBRID Corporation
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  */
18 
19 /*
20  * load_sa_loader.hpp: Loader client definitions. Updated using design from fast loaddb prototype
21  */
22 
23 #ifndef _LOAD_SA_LOADER_HPP_
24 #define _LOAD_SA_LOADER_HPP_
25 
26 #include "load_common.hpp"
27 
28 namespace cubload
29 {
30 
32  {
33  public:
34  sa_class_installer () = default;
35  ~sa_class_installer () override = default;
36 
37  void set_class_id (class_id clsid) override;
38 
39  void check_class (const char *class_name, int class_id) override;
40  int install_class (const char *class_name) override;
41  void install_class (string_type *class_name, class_command_spec_type *cmd_spec) override;
42  };
43 
45  {
46  public:
47  sa_object_loader () = default;
48  ~sa_object_loader () override = default;
49 
50  void init (class_id clsid) override;
51  void destroy () override;
52 
53  void start_line (int object_id) override;
54  void process_line (constant_type *cons) override;
55  void finish_line () override;
56  void flush_records () override;
57  std::size_t get_rows_number () override;
58  };
59 }
60 
61 /* start load functions */
62 void ldr_sa_load (cubload::load_args *args, int *status, bool *interrupted);
63 
64 /* log functions */
65 void print_log_msg (int verbose, const char *fmt, ...);
66 
68 void ldr_increment_fails ();
69 
70 #endif /* _LOAD_SA_LOADER_HPP_ */
void print_log_msg(int verbose, const char *fmt,...)
Definition: load_db.c:82
void ldr_increment_fails()
~sa_class_installer() override=default
void ldr_increment_err_total()
void ldr_sa_load(cubload::load_args *args, int *status, bool *interrupted)
void set_class_id(class_id clsid) override
void check_class(const char *class_name, int class_id) override
int install_class(const char *class_name) override
int class_id
Definition: load_common.hpp:40