MySQL 5.6.14 Source Code Document
Main Page
Related Pages
Modules
Namespaces
Classes
Files
Examples
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
table_ews_by_thread_by_event_name.h
Go to the documentation of this file.
1
/* Copyright (c) 2010, 2011, Oracle and/or its affiliates. All rights reserved.
2
3
This program is free software; you can redistribute it and/or modify
4
it under the terms of the GNU General Public License as published by
5
the Free Software Foundation; version 2 of the License.
6
7
This program is distributed in the hope that it will be useful,
8
but WITHOUT ANY WARRANTY; without even the implied warranty of
9
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10
GNU General Public License for more details.
11
12
You should have received a copy of the GNU General Public License
13
along with this program; if not, write to the Free Software
14
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
15
16
#ifndef TABLE_EWS_BY_THREAD_BY_EVENT_NAME_H
17
#define TABLE_EWS_BY_THREAD_BY_EVENT_NAME_H
18
24
#include "
pfs_column_types.h
"
25
#include "
pfs_engine_table.h
"
26
#include "
pfs_instr_class.h
"
27
#include "
pfs_instr.h
"
28
#include "
table_helper.h
"
29
39
struct
row_ews_by_thread_by_event_name
40
{
42
ulonglong
m_thread_internal_id
;
44
PFS_event_name_row
m_event_name
;
46
PFS_stat_row
m_stat
;
47
};
48
56
struct
pos_ews_by_thread_by_event_name
57
:
public
PFS_triple_index
,
public
PFS_instrument_view_constants
58
{
59
pos_ews_by_thread_by_event_name
()
60
:
PFS_triple_index
(0, FIRST_VIEW, 1)
61
{}
62
63
inline
void
reset(
void
)
64
{
65
m_index_1
= 0;
66
m_index_2
= FIRST_VIEW;
67
m_index_3
= 1;
68
}
69
70
inline
bool
has_more_thread(
void
)
71
{
return
(
m_index_1
<
thread_max
); }
72
73
inline
void
next_thread(
void
)
74
{
75
m_index_1
++;
76
m_index_2
= FIRST_VIEW;
77
m_index_3
= 1;
78
}
79
80
inline
bool
has_more_view(
void
)
81
{
return
(
m_index_2
<= LAST_VIEW); }
82
83
inline
void
next_view(
void
)
84
{
85
m_index_2
++;
86
m_index_3
= 1;
87
}
88
};
89
91
class
table_ews_by_thread_by_event_name
:
public
PFS_engine_table
92
{
93
public
:
95
static
PFS_engine_table_share
m_share
;
96
static
PFS_engine_table
* create();
97
static
int
delete_all_rows();
98
99
virtual
int
rnd_next
();
100
virtual
int
rnd_pos
(
const
void
*pos);
101
virtual
void
reset_position
(
void
);
102
103
protected
:
104
virtual
int
read_row_values
(
TABLE
*
table
,
105
unsigned
char
*
buf
,
106
Field
**fields,
107
bool
read_all);
108
109
table_ews_by_thread_by_event_name
();
110
111
public
:
112
~
table_ews_by_thread_by_event_name
()
113
{}
114
115
protected
:
116
void
make_row(
PFS_thread
*thread,
PFS_instr_class
*klass);
117
118
private
:
120
static
THR_LOCK
m_table_lock;
122
static
TABLE_FIELD_DEF
m_field_def;
123
125
row_ews_by_thread_by_event_name
m_row;
127
bool
m_row_exists;
129
pos_ews_by_thread_by_event_name
m_pos;
131
pos_ews_by_thread_by_event_name
m_next_pos;
132
};
133
135
#endif
storage
perfschema
table_ews_by_thread_by_event_name.h
Generated on Sat Nov 9 2013 01:28:40 for MySQL 5.6.14 Source Code Document by
1.8.1.2