2
* Copyright (c) 2007, 2011, Oracle and/or its affiliates. All rights reserved.
4
* This program is free software; you can redistribute it and/or
5
* modify it under the terms of the GNU General Public License as
6
* published by the Free Software Foundation; version 2 of the
9
* This program is distributed in the hope that it will be useful,
10
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
* GNU General Public License for more details.
14
* You should have received a copy of the GNU General Public License
15
* along with this program; if not, write to the Free Software
16
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
19
#ifndef _WORKBENCH_PHYSICAL_CONNECTION_IMPL_H_
20
#define _WORKBENCH_PHYSICAL_CONNECTION_IMPL_H_
22
#include "model_connection_impl.h"
23
#include "grts/structs.workbench.physical.h"
32
class WBPUBLICBACKEND_PUBLIC_FUNC workbench_physical_Connection::ImplData : public model_Connection::ImplData
34
typedef model_Connection::ImplData super;
37
boost::signals2::scoped_connection _realize_conn;
39
boost::signals2::scoped_connection _fk_member_changed_conn;
40
boost::signals2::scoped_connection _fk_changed_conn;
41
boost::signals2::scoped_connection _table_changed_conn;
45
void fk_changed(const db_ForeignKeyRef &fk);
46
void member_changed(const std::string &name, const grt::ValueRef &ovalue);
48
virtual bool realize();
49
virtual void unrealize();
51
void update_line_ends();
52
void layout_changed();
53
void table_changed(const std::string &detail);
55
virtual mdc::CanvasItem *get_start_canvas_item();
56
virtual mdc::CanvasItem *get_end_canvas_item();
58
virtual void caption_bounds_changed(const MySQL::Geometry::Rect &obounds, mdc::TextFigure *figure);
60
void fk_member_changed(const std::string &member, const grt::ValueRef &ovalue);
62
void object_realized(const model_ObjectRef &object);
64
void update_connected_tables();
67
ImplData(workbench_physical_Connection *self);
70
void set_highlighted(bool flag);
72
virtual void set_in_view(bool flag);
74
void set_foreign_key(const db_ForeignKeyRef &fk);
77
workbench_physical_Connection *self() const { return (workbench_physical_Connection*)_self; }