/usr/share/gtk-doc/html/libgda-5.0/GdaVconnectionDataModel.html is in libgda-5.0-doc 5.2.2-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 | <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>GNOME Data Access 5 manual: GdaVconnectionDataModel</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.78.1">
<link rel="home" href="index.html" title="GNOME Data Access 5 manual">
<link rel="up" href="virtual_connection.html" title="Virtual connections">
<link rel="prev" href="GdaVirtualConnection.html" title="GdaVirtualConnection">
<link rel="next" href="GdaVconnectionHub.html" title="GdaVconnectionHub">
<meta name="generator" content="GTK-Doc V1.20 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="10"><tr valign="middle">
<td width="100%" align="left" class="shortcuts">
<a href="#" class="shortcut">Top</a><span id="nav_description"> <span class="dim">|</span>
<a href="#GdaVconnectionDataModel.description" class="shortcut">Description</a></span><span id="nav_hierarchy"> <span class="dim">|</span>
<a href="#GdaVconnectionDataModel.object-hierarchy" class="shortcut">Object Hierarchy</a></span><span id="nav_interfaces"> <span class="dim">|</span>
<a href="#GdaVconnectionDataModel.implemented-interfaces" class="shortcut">Implemented Interfaces</a></span><span id="nav_signals"> <span class="dim">|</span>
<a href="#GdaVconnectionDataModel.signals" class="shortcut">Signals</a></span>
</td>
<td><a accesskey="h" href="index.html"><img src="home.png" width="16" height="16" border="0" alt="Home"></a></td>
<td><a accesskey="u" href="virtual_connection.html"><img src="up.png" width="16" height="16" border="0" alt="Up"></a></td>
<td><a accesskey="p" href="GdaVirtualConnection.html"><img src="left.png" width="16" height="16" border="0" alt="Prev"></a></td>
<td><a accesskey="n" href="GdaVconnectionHub.html"><img src="right.png" width="16" height="16" border="0" alt="Next"></a></td>
</tr></table>
<div class="refentry">
<a name="GdaVconnectionDataModel"></a><div class="titlepage"></div>
<div class="refnamediv"><table width="100%"><tr>
<td valign="top">
<h2><span class="refentrytitle"><a name="GdaVconnectionDataModel.top_of_page"></a>GdaVconnectionDataModel</span></h2>
<p>GdaVconnectionDataModel — Virtual connection based on a list of GdaDataModel</p>
</td>
<td class="gallery_image" valign="top" align="right"></td>
</tr></table></div>
<div class="refsect1">
<a name="GdaVconnectionDataModel.stability-level"></a><h2>Stability Level</h2>
Stable, unless otherwise indicated
</div>
<div class="refsect1">
<a name="GdaVconnectionDataModel.functions"></a><h2>Functions</h2>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="functions_return">
<col class="functions_name">
</colgroup>
<tbody>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<span class="c_punctuation">(</span><a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelFunc" title="GdaVconnectionDataModelFunc ()">*GdaVconnectionDataModelFunc</a><span class="c_punctuation">)</span> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="/usr/share/gtk-doc/html/glib/glib-Doubly-Linked-Lists.html#GList"><span class="returnvalue">GList</span></a> *
</td>
<td class="function_name">
<span class="c_punctuation">(</span><a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelCreateColumnsFunc" title="GdaVconnectionDataModelCreateColumnsFunc ()">*GdaVconnectionDataModelCreateColumnsFunc</a><span class="c_punctuation">)</span> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="GdaDataModel.html" title="GdaDataModel"><span class="returnvalue">GdaDataModel</span></a> *
</td>
<td class="function_name">
<span class="c_punctuation">(</span><a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelCreateModelFunc" title="GdaVconnectionDataModelCreateModelFunc ()">*GdaVconnectionDataModelCreateModelFunc</a><span class="c_punctuation">)</span> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<span class="c_punctuation">(</span><a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelParseFilterFunc" title="GdaVconnectionDataModelParseFilterFunc ()">*GdaVconnectionDataModelParseFilterFunc</a><span class="c_punctuation">)</span> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="GdaDataModel.html" title="GdaDataModel"><span class="returnvalue">GdaDataModel</span></a> *
</td>
<td class="function_name">
<span class="c_punctuation">(</span><a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelCreateFModelFunc" title="GdaVconnectionDataModelCreateFModelFunc ()">*GdaVconnectionDataModelCreateFModelFunc</a><span class="c_punctuation">)</span> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
</td>
<td class="function_name">
<a class="link" href="GdaVconnectionDataModel.html#gda-vconnection-data-model-add" title="gda_vconnection_data_model_add ()">gda_vconnection_data_model_add</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
</td>
<td class="function_name">
<a class="link" href="GdaVconnectionDataModel.html#gda-vconnection-data-model-add-model" title="gda_vconnection_data_model_add_model ()">gda_vconnection_data_model_add_model</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
</td>
<td class="function_name">
<a class="link" href="GdaVconnectionDataModel.html#gda-vconnection-data-model-remove" title="gda_vconnection_data_model_remove ()">gda_vconnection_data_model_remove</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *
</td>
<td class="function_name">
<a class="link" href="GdaVconnectionDataModel.html#gda-vconnection-data-model-get-table-name" title="gda_vconnection_data_model_get_table_name ()">gda_vconnection_data_model_get_table_name</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="GdaDataModel.html" title="GdaDataModel"><span class="returnvalue">GdaDataModel</span></a> *
</td>
<td class="function_name">
<a class="link" href="GdaVconnectionDataModel.html#gda-vconnection-data-model-get-model" title="gda_vconnection_data_model_get_model ()">gda_vconnection_data_model_get_model</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelSpec" title="struct GdaVconnectionDataModelSpec"><span class="returnvalue">GdaVconnectionDataModelSpec</span></a> *
</td>
<td class="function_name">
<a class="link" href="GdaVconnectionDataModel.html#gda-vconnection-data-model-get" title="gda_vconnection_data_model_get ()">gda_vconnection_data_model_get</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="GdaVconnectionDataModel.html#gda-vconnection-data-model-foreach" title="gda_vconnection_data_model_foreach ()">gda_vconnection_data_model_foreach</a> <span class="c_punctuation">()</span>
</td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect1">
<a name="GdaVconnectionDataModel.signals"></a><h2>Signals</h2>
<div class="informaltable"><table border="0">
<colgroup>
<col width="150px" class="signals_return">
<col width="300px" class="signals_name">
<col width="200px" class="signals_flags">
</colgroup>
<tbody>
<tr>
<td class="signal_type"><span class="returnvalue">void</span></td>
<td class="signal_name"><a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModel-vtable-created" title="The “vtable-created” signal">vtable-created</a></td>
<td class="signal_flags">Run Last</td>
</tr>
<tr>
<td class="signal_type"><span class="returnvalue">void</span></td>
<td class="signal_name"><a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModel-vtable-dropped" title="The “vtable-dropped” signal">vtable-dropped</a></td>
<td class="signal_flags">Run Last</td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect1">
<a name="GdaVconnectionDataModel.other"></a><h2>Types and Values</h2>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="name">
<col class="description">
</colgroup>
<tbody>
<tr>
<td class="datatype_keyword">struct</td>
<td class="function_name"><a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModel-struct" title="struct GdaVconnectionDataModel">GdaVconnectionDataModel</a></td>
</tr>
<tr>
<td class="datatype_keyword">struct</td>
<td class="function_name"><a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelSpec" title="struct GdaVconnectionDataModelSpec">GdaVconnectionDataModelSpec</a></td>
</tr>
<tr>
<td class="datatype_keyword">struct</td>
<td class="function_name"><a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelFilter" title="struct GdaVconnectionDataModelFilter">GdaVconnectionDataModelFilter</a></td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect1">
<a name="GdaVconnectionDataModel.object-hierarchy"></a><h2>Object Hierarchy</h2>
<pre class="screen"> <a href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObject">GObject</a>
<span class="lineart">╰──</span> <a class="link" href="GdaConnection.html" title="GdaConnection">GdaConnection</a>
<span class="lineart">╰──</span> <a class="link" href="GdaVirtualConnection.html" title="GdaVirtualConnection">GdaVirtualConnection</a>
<span class="lineart">╰──</span> GdaVconnectionDataModel
<span class="lineart">╰──</span> <a class="link" href="GdaVconnectionHub.html" title="GdaVconnectionHub">GdaVconnectionHub</a>
</pre>
</div>
<div class="refsect1">
<a name="GdaVconnectionDataModel.implemented-interfaces"></a><h2>Implemented Interfaces</h2>
<p>
GdaVconnectionDataModel implements
<a class="link" href="GdaLockable.html" title="GdaLockable">GdaLockable</a>.</p>
</div>
<div class="refsect1">
<a name="GdaVconnectionDataModel.description"></a><h2>Description</h2>
<p>The <a class="link" href="GdaVconnectionDataModel.html" title="GdaVconnectionDataModel"><span class="type">GdaVconnectionDataModel</span></a> is a virtual connection in which <a class="link" href="GdaDataModel.html" title="GdaDataModel"><span class="type">GdaDataModel</span></a> data models can be added
or removed, each representing a table in the connection, the <a class="link" href="GdaVconnectionDataModel.html#gda-vconnection-data-model-add-model" title="gda_vconnection_data_model_add_model ()"><code class="function">gda_vconnection_data_model_add_model()</code></a>
and <a class="link" href="GdaVconnectionDataModel.html#gda-vconnection-data-model-remove" title="gda_vconnection_data_model_remove ()"><code class="function">gda_vconnection_data_model_remove()</code></a> methods.</p>
<p>Furthermore it is possible to declare tables without any associated data model yet,
the real data model being automatically created when the
table's data is needed. This allows more dynamic table's contents and filtering optimizations.
See the <a class="link" href="GdaVconnectionDataModel.html#gda-vconnection-data-model-add" title="gda_vconnection_data_model_add ()"><code class="function">gda_vconnection_data_model_add()</code></a> and <a class="link" href="GdaVconnectionDataModel.html#gda-vconnection-data-model-remove" title="gda_vconnection_data_model_remove ()"><code class="function">gda_vconnection_data_model_remove()</code></a> methods. The
filtering optimizations are based on SQLite's virtual table optimisations see</p>
<a class="ulink" href="http://www.sqlite.org/cvstrac/wiki?p=VirtualTableBestIndexMethod" target="_top">SQLite's documentation</a><p>for some background information.</p>
</div>
<div class="refsect1">
<a name="GdaVconnectionDataModel.functions_details"></a><h2>Functions</h2>
<div class="refsect2">
<a name="GdaVconnectionDataModelFunc"></a><h3>GdaVconnectionDataModelFunc ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
<span class="c_punctuation">(</span>*GdaVconnectionDataModelFunc<span class="c_punctuation">)</span> (<em class="parameter"><code><a class="link" href="GdaDataModel.html" title="GdaDataModel"><span class="type">GdaDataModel</span></a> *Param1</code></em>,
<em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *Param2</code></em>,
<em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> Param3</code></em>);</pre>
<p>This function is called for every <a class="link" href="GdaDataModel.html" title="GdaDataModel"><span class="type">GdaDataModel</span></a> representing a table in a <a class="link" href="GdaVconnectionDataModel.html" title="GdaVconnectionDataModel"><span class="type">GdaVconnectionDataModel</span></a>
connection, when using the <a class="link" href="GdaVconnectionDataModel.html#gda-vconnection-data-model-foreach" title="gda_vconnection_data_model_foreach ()"><code class="function">gda_vconnection_data_model_foreach()</code></a> method.</p>
<div class="refsect3">
<a name="id-1.3.7.7.10.2.5"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>Param1</p></td>
<td class="parameter_description"><p> a pointer to a <a class="link" href="GdaDataModel.html" title="GdaDataModel"><span class="type">GdaDataModel</span></a>. </p></td>
<td class="parameter_annotations"><span class="annotation">[<a href="http://foldoc.org/allow-none"><span class="acronym">allow-none</span></a>]</span></td>
</tr>
<tr>
<td class="parameter_name"><p>Param2</p></td>
<td class="parameter_description"><p>the name of the table represented by <em class="parameter"><code>Param1</code></em>
</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>Param3</p></td>
<td class="parameter_description"><p>a data pointer, passed as last ergument to <a class="link" href="GdaVconnectionDataModel.html#gda-vconnection-data-model-foreach" title="gda_vconnection_data_model_foreach ()"><code class="function">gda_vconnection_data_model_foreach()</code></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
</div>
<hr>
<div class="refsect2">
<a name="GdaVconnectionDataModelCreateColumnsFunc"></a><h3>GdaVconnectionDataModelCreateColumnsFunc ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Doubly-Linked-Lists.html#GList"><span class="returnvalue">GList</span></a> *
<span class="c_punctuation">(</span>*GdaVconnectionDataModelCreateColumnsFunc<span class="c_punctuation">)</span>
(<em class="parameter"><code><a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelSpec" title="struct GdaVconnectionDataModelSpec"><span class="type">GdaVconnectionDataModelSpec</span></a> *Param1</code></em>,
<em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **Param2</code></em>);</pre>
<p>Function called to create the virtual table's columns, as <a class="link" href="GdaColumn.html" title="GdaDataModel columns"><span class="type">GdaColumn</span></a> objects.</p>
<div class="refsect3">
<a name="id-1.3.7.7.10.3.5"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>Param1</p></td>
<td class="parameter_description"><p>a pointer to a <a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelSpec" title="struct GdaVconnectionDataModelSpec"><span class="type">GdaVconnectionDataModelSpec</span></a> structure</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>Param2</p></td>
<td class="parameter_description"><p>a place to store errors, or <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.3.7.7.10.3.6"></a><h4>Returns</h4>
<p> a new list of <a class="link" href="GdaColumn.html" title="GdaDataModel columns"><span class="type">GdaColumn</span></a> objects. </p>
<p><span class="annotation">[<a href="http://foldoc.org/element-type"><span class="acronym">element-type</span></a> GdaColumn][<a href="http://foldoc.org/transfer%20full"><span class="acronym">transfer full</span></a>]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="GdaVconnectionDataModelCreateModelFunc"></a><h3>GdaVconnectionDataModelCreateModelFunc ()</h3>
<pre class="programlisting"><a class="link" href="GdaDataModel.html" title="GdaDataModel"><span class="returnvalue">GdaDataModel</span></a> *
<span class="c_punctuation">(</span>*GdaVconnectionDataModelCreateModelFunc<span class="c_punctuation">)</span>
(<em class="parameter"><code><a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelSpec" title="struct GdaVconnectionDataModelSpec"><span class="type">GdaVconnectionDataModelSpec</span></a> *Param1</code></em>);</pre>
<p>Function called to create a <a class="link" href="GdaDataModel.html" title="GdaDataModel"><span class="type">GdaDataModel</span></a> object, called when a virtual table's data need to
be accessed, and when optimization is not handled.</p>
<div class="refsect3">
<a name="id-1.3.7.7.10.4.5"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>Param1</p></td>
<td class="parameter_description"><p>a pointer to a <a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelSpec" title="struct GdaVconnectionDataModelSpec"><span class="type">GdaVconnectionDataModelSpec</span></a> structure</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.3.7.7.10.4.6"></a><h4>Returns</h4>
<p> a new <a class="link" href="GdaDataModel.html" title="GdaDataModel"><span class="type">GdaDataModel</span></a>. </p>
<p><span class="annotation">[<a href="http://foldoc.org/transfer%20full"><span class="acronym">transfer full</span></a>]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="GdaVconnectionDataModelParseFilterFunc"></a><h3>GdaVconnectionDataModelParseFilterFunc ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
<span class="c_punctuation">(</span>*GdaVconnectionDataModelParseFilterFunc<span class="c_punctuation">)</span>
(<em class="parameter"><code><a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelSpec" title="struct GdaVconnectionDataModelSpec"><span class="type">GdaVconnectionDataModelSpec</span></a> *Param1</code></em>,
<em class="parameter"><code><a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelFilter" title="struct GdaVconnectionDataModelFilter"><span class="type">GdaVconnectionDataModelFilter</span></a> *Param2</code></em>);</pre>
<p>This function actually analyses the proposed optimization and modified <em class="parameter"><code>Param2</code></em>
to tell the database
engine how (if applicable) it implements the optimization.</p>
<div class="refsect3">
<a name="id-1.3.7.7.10.5.5"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>Param1</p></td>
<td class="parameter_description"><p>a pointer to a <a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelSpec" title="struct GdaVconnectionDataModelSpec"><span class="type">GdaVconnectionDataModelSpec</span></a> structure</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>Param2</p></td>
<td class="parameter_description"><p>a pointer to a <a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelFilter" title="struct GdaVconnectionDataModelFilter"><span class="type">GdaVconnectionDataModelFilter</span></a> structure</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
</div>
<hr>
<div class="refsect2">
<a name="GdaVconnectionDataModelCreateFModelFunc"></a><h3>GdaVconnectionDataModelCreateFModelFunc ()</h3>
<pre class="programlisting"><a class="link" href="GdaDataModel.html" title="GdaDataModel"><span class="returnvalue">GdaDataModel</span></a> *
<span class="c_punctuation">(</span>*GdaVconnectionDataModelCreateFModelFunc<span class="c_punctuation">)</span>
(<em class="parameter"><code><a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelSpec" title="struct GdaVconnectionDataModelSpec"><span class="type">GdaVconnectionDataModelSpec</span></a> *Param1</code></em>,
<em class="parameter"><code><span class="type">int</span> Param2</code></em>,
<em class="parameter"><code>const <span class="type">char</span> *Param3</code></em>,
<em class="parameter"><code><span class="type">int</span> Param4</code></em>,
<em class="parameter"><code><a href="/usr/share/gtk-doc/html/gobject/gobject-Generic-values.html#GValue"><span class="type">GValue</span></a> **Param5</code></em>);</pre>
<p>Function called to create a <a class="link" href="GdaDataModel.html" title="GdaDataModel"><span class="type">GdaDataModel</span></a> object, called when a virtual table's data need to
be accessed, and when optimization is handled.</p>
<div class="refsect3">
<a name="id-1.3.7.7.10.6.5"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>Param1</p></td>
<td class="parameter_description"><p>a pointer to a <a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelSpec" title="struct GdaVconnectionDataModelSpec"><span class="type">GdaVconnectionDataModelSpec</span></a> structure</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>Param2</p></td>
<td class="parameter_description"><p>the index number chosen to actually execute the optimization (from <a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelFilter" title="struct GdaVconnectionDataModelFilter"><span class="type">GdaVconnectionDataModelFilter</span></a>'s <span class="type">idxNum</span> attribute)</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>Param3</p></td>
<td class="parameter_description"><p>corresponds to the <a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelFilter" title="struct GdaVconnectionDataModelFilter"><span class="type">GdaVconnectionDataModelFilter</span></a>'s <span class="type">idxPointer</span> attribute</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>Param4</p></td>
<td class="parameter_description"><p>size of <em class="parameter"><code>Param5</code></em>
</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>Param5</p></td>
<td class="parameter_description"><p>an array of <a href="/usr/share/gtk-doc/html/gobject/gobject-Generic-values.html#GValue"><span class="type">GValue</span></a>, as specified by the <a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelFilter" title="struct GdaVconnectionDataModelFilter"><span class="type">GdaVconnectionDataModelFilter</span></a>'s <span class="type">aConstraintUsage</span>'s <span class="type">argvIndex</span> value</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.3.7.7.10.6.6"></a><h4>Returns</h4>
<p> a new <a class="link" href="GdaDataModel.html" title="GdaDataModel"><span class="type">GdaDataModel</span></a>. </p>
<p><span class="annotation">[<a href="http://foldoc.org/transfer%20full"><span class="acronym">transfer full</span></a>]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="gda-vconnection-data-model-add"></a><h3>gda_vconnection_data_model_add ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
gda_vconnection_data_model_add (<em class="parameter"><code><a class="link" href="GdaVconnectionDataModel.html" title="GdaVconnectionDataModel"><span class="type">GdaVconnectionDataModel</span></a> *cnc</code></em>,
<em class="parameter"><code><a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelSpec" title="struct GdaVconnectionDataModelSpec"><span class="type">GdaVconnectionDataModelSpec</span></a> *spec</code></em>,
<em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Datasets.html#GDestroyNotify"><span class="type">GDestroyNotify</span></a> spec_free_func</code></em>,
<em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *table_name</code></em>,
<em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre>
<p>Create a new virtual table named <em class="parameter"><code>table_name</code></em>
in <em class="parameter"><code>cnc</code></em>
. The contents of that new table
is dictated by what's in <em class="parameter"><code>spec</code></em>
.</p>
<p>If there is just one <a class="link" href="GdaDataModel.html" title="GdaDataModel"><span class="type">GdaDataModel</span></a> to make appear as a table
then the <a class="link" href="GdaVconnectionDataModel.html#gda-vconnection-data-model-add-model" title="gda_vconnection_data_model_add_model ()"><code class="function">gda_vconnection_data_model_add_model()</code></a> method is easier to use.</p>
<p>The <em class="parameter"><code>spec_free_func</code></em>
can (depending on your code) be used to clean memory allocated for <em class="parameter"><code>spec</code></em>
or
<em class="parameter"><code>spec->data_model</code></em>
.</p>
<p>If an error occurs, then the <em class="parameter"><code>spec_free_func</code></em>
function is called using <em class="parameter"><code>spec</code></em>
as argument.</p>
<div class="refsect3">
<a name="id-1.3.7.7.10.7.8"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>cnc</p></td>
<td class="parameter_description"><p>a <a class="link" href="GdaVconnectionDataModel.html" title="GdaVconnectionDataModel"><span class="type">GdaVconnectionDataModel</span></a> connection</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>spec</p></td>
<td class="parameter_description"><p>a <a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelSpec" title="struct GdaVconnectionDataModelSpec"><span class="type">GdaVconnectionDataModelSpec</span></a> structure, used AS IS (not copied) and can be modified</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>spec_free_func</p></td>
<td class="parameter_description"><p> function to call when freeing <em class="parameter"><code>spec</code></em>
, or <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. </p></td>
<td class="parameter_annotations"><span class="annotation">[<a href="http://foldoc.org/allow-none"><span class="acronym">allow-none</span></a>]</span></td>
</tr>
<tr>
<td class="parameter_name"><p>table_name</p></td>
<td class="parameter_description"><p>the name of the table</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>error</p></td>
<td class="parameter_description"><p>a place to store errors, or <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.3.7.7.10.7.9"></a><h4>Returns</h4>
<p> <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if no error occurred</p>
<p></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="gda-vconnection-data-model-add-model"></a><h3>gda_vconnection_data_model_add_model ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
gda_vconnection_data_model_add_model (<em class="parameter"><code><a class="link" href="GdaVconnectionDataModel.html" title="GdaVconnectionDataModel"><span class="type">GdaVconnectionDataModel</span></a> *cnc</code></em>,
<em class="parameter"><code><a class="link" href="GdaDataModel.html" title="GdaDataModel"><span class="type">GdaDataModel</span></a> *model</code></em>,
<em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *table_name</code></em>,
<em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre>
<p>Make <em class="parameter"><code>model</code></em>
appear as a table named <em class="parameter"><code>table_name</code></em>
in the <em class="parameter"><code>cnc</code></em>
connection (as if a
"CREATE TABLE..." statement was executed, except that the data contained within <em class="parameter"><code>model</code></em>
is actually used when <em class="parameter"><code>table_name</code></em>
's contents is read or written).</p>
<p>For a more general approach, see the <a class="link" href="GdaVconnectionDataModel.html#gda-vconnection-data-model-add" title="gda_vconnection_data_model_add ()"><code class="function">gda_vconnection_data_model_add()</code></a> method.</p>
<div class="refsect3">
<a name="id-1.3.7.7.10.8.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>cnc</p></td>
<td class="parameter_description"><p>a <a class="link" href="GdaVconnectionDataModel.html" title="GdaVconnectionDataModel"><span class="type">GdaVconnectionDataModel</span></a> connection</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>model</p></td>
<td class="parameter_description"><p>a <a class="link" href="GdaDataModel.html" title="GdaDataModel"><span class="type">GdaDataModel</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>table_name</p></td>
<td class="parameter_description"><p>the name of the table</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>error</p></td>
<td class="parameter_description"><p>a place to store errors, or <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.3.7.7.10.8.7"></a><h4>Returns</h4>
<p> <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if no error occurred</p>
<p></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="gda-vconnection-data-model-remove"></a><h3>gda_vconnection_data_model_remove ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
gda_vconnection_data_model_remove (<em class="parameter"><code><a class="link" href="GdaVconnectionDataModel.html" title="GdaVconnectionDataModel"><span class="type">GdaVconnectionDataModel</span></a> *cnc</code></em>,
<em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *table_name</code></em>,
<em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre>
<p>Remove the table named <em class="parameter"><code>table_name</code></em>
in the <em class="parameter"><code>cnc</code></em>
connection (as if a "DROP TABLE..."
statement was executed, except that no data gets destroyed as the associated data model remains the same).</p>
<div class="refsect3">
<a name="id-1.3.7.7.10.9.5"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>cnc</p></td>
<td class="parameter_description"><p>a <a class="link" href="GdaVconnectionDataModel.html" title="GdaVconnectionDataModel"><span class="type">GdaVconnectionDataModel</span></a> connection</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>table_name</p></td>
<td class="parameter_description"><p>the name of the table to remove from <em class="parameter"><code>cnc</code></em>
</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>error</p></td>
<td class="parameter_description"><p>a place to store errors, or <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.3.7.7.10.9.6"></a><h4>Returns</h4>
<p> <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if no error occurred</p>
<p></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="gda-vconnection-data-model-get-table-name"></a><h3>gda_vconnection_data_model_get_table_name ()</h3>
<pre class="programlisting">const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *
gda_vconnection_data_model_get_table_name
(<em class="parameter"><code><a class="link" href="GdaVconnectionDataModel.html" title="GdaVconnectionDataModel"><span class="type">GdaVconnectionDataModel</span></a> *cnc</code></em>,
<em class="parameter"><code><a class="link" href="GdaDataModel.html" title="GdaDataModel"><span class="type">GdaDataModel</span></a> *model</code></em>);</pre>
<p>Find the name of the table associated to <em class="parameter"><code>model</code></em>
in <em class="parameter"><code>cnc</code></em>
</p>
<div class="refsect3">
<a name="id-1.3.7.7.10.10.5"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>cnc</p></td>
<td class="parameter_description"><p>a <a class="link" href="GdaVconnectionDataModel.html" title="GdaVconnectionDataModel"><span class="type">GdaVconnectionDataModel</span></a> connection</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>model</p></td>
<td class="parameter_description"><p>a <a class="link" href="GdaDataModel.html" title="GdaDataModel"><span class="type">GdaDataModel</span></a> representing a table within <em class="parameter"><code>cnc</code></em>
</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.3.7.7.10.10.6"></a><h4>Returns</h4>
<p> the table name, or <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if not found. </p>
<p><span class="annotation">[<a href="http://foldoc.org/transfer%20none"><span class="acronym">transfer none</span></a>][<a href="http://foldoc.org/allow-none"><span class="acronym">allow-none</span></a>]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="gda-vconnection-data-model-get-model"></a><h3>gda_vconnection_data_model_get_model ()</h3>
<pre class="programlisting"><a class="link" href="GdaDataModel.html" title="GdaDataModel"><span class="returnvalue">GdaDataModel</span></a> *
gda_vconnection_data_model_get_model (<em class="parameter"><code><a class="link" href="GdaVconnectionDataModel.html" title="GdaVconnectionDataModel"><span class="type">GdaVconnectionDataModel</span></a> *cnc</code></em>,
<em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *table_name</code></em>);</pre>
<p>Find the <a class="link" href="GdaDataModel.html" title="GdaDataModel"><span class="type">GdaDataModel</span></a> object representing the <em class="parameter"><code>table_name</code></em>
table in <em class="parameter"><code>cnc</code></em>
. it can return <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
either if no table named <em class="parameter"><code>table_name</code></em>
exists, or if that table actually exists but no <a class="link" href="GdaDataModel.html" title="GdaDataModel"><span class="type">GdaDataModel</span></a>
has yet been created. For a more general approach, use the <a class="link" href="GdaVconnectionDataModel.html#gda-vconnection-data-model-get" title="gda_vconnection_data_model_get ()"><code class="function">gda_vconnection_data_model_get()</code></a>.</p>
<div class="refsect3">
<a name="id-1.3.7.7.10.11.5"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>cnc</p></td>
<td class="parameter_description"><p>a <a class="link" href="GdaVconnectionDataModel.html" title="GdaVconnectionDataModel"><span class="type">GdaVconnectionDataModel</span></a> connection</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>table_name</p></td>
<td class="parameter_description"><p>a table name within <em class="parameter"><code>cnc</code></em>
</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.3.7.7.10.11.6"></a><h4>Returns</h4>
<p> the <a class="link" href="GdaDataModel.html" title="GdaDataModel"><span class="type">GdaDataModel</span></a>, or <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. </p>
<p><span class="annotation">[<a href="http://foldoc.org/transfer%20none"><span class="acronym">transfer none</span></a>][<a href="http://foldoc.org/allow-none"><span class="acronym">allow-none</span></a>]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="gda-vconnection-data-model-get"></a><h3>gda_vconnection_data_model_get ()</h3>
<pre class="programlisting"><a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelSpec" title="struct GdaVconnectionDataModelSpec"><span class="returnvalue">GdaVconnectionDataModelSpec</span></a> *
gda_vconnection_data_model_get (<em class="parameter"><code><a class="link" href="GdaVconnectionDataModel.html" title="GdaVconnectionDataModel"><span class="type">GdaVconnectionDataModel</span></a> *cnc</code></em>,
<em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *table_name</code></em>);</pre>
<p>Find the <a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelSpec" title="struct GdaVconnectionDataModelSpec"><span class="type">GdaVconnectionDataModelSpec</span></a> specifying how the table named <em class="parameter"><code>table_name</code></em>
is represented
in <em class="parameter"><code>cnc</code></em>
.</p>
<div class="refsect3">
<a name="id-1.3.7.7.10.12.5"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>cnc</p></td>
<td class="parameter_description"><p>a <a class="link" href="GdaVconnectionDataModel.html" title="GdaVconnectionDataModel"><span class="type">GdaVconnectionDataModel</span></a> connection</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>table_name</p></td>
<td class="parameter_description"><p>a table name within <em class="parameter"><code>cnc</code></em>
</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.3.7.7.10.12.6"></a><h4>Returns</h4>
<p> a <a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelSpec" title="struct GdaVconnectionDataModelSpec"><span class="type">GdaVconnectionDataModelSpec</span></a> pointer, of <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if there is no table named <em class="parameter"><code>table_name</code></em>
. </p>
<p><span class="annotation">[<a href="http://foldoc.org/transfer%20none"><span class="acronym">transfer none</span></a>][<a href="http://foldoc.org/allow-none"><span class="acronym">allow-none</span></a>]</span></p>
</div>
<p class="since">Since 4.2.6</p>
</div>
<hr>
<div class="refsect2">
<a name="gda-vconnection-data-model-foreach"></a><h3>gda_vconnection_data_model_foreach ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gda_vconnection_data_model_foreach (<em class="parameter"><code><a class="link" href="GdaVconnectionDataModel.html" title="GdaVconnectionDataModel"><span class="type">GdaVconnectionDataModel</span></a> *cnc</code></em>,
<em class="parameter"><code><a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelFunc" title="GdaVconnectionDataModelFunc ()"><span class="type">GdaVconnectionDataModelFunc</span></a> func</code></em>,
<em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> data</code></em>);</pre>
<p>Call <em class="parameter"><code>func</code></em>
for each table in <em class="parameter"><code>cnc</code></em>
. </p>
<p>Warning: <em class="parameter"><code>func</code></em>
will be called for any table present in <em class="parameter"><code>cnc</code></em>
even if no data
model represents the contents of the table (which means the 1st argument of <em class="parameter"><code>func</code></em>
may be <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>)</p>
<div class="refsect3">
<a name="id-1.3.7.7.10.13.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>cnc</p></td>
<td class="parameter_description"><p>a <a class="link" href="GdaVconnectionDataModel.html" title="GdaVconnectionDataModel"><span class="type">GdaVconnectionDataModel</span></a> connection</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>func</p></td>
<td class="parameter_description"><p>a <a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelFunc" title="GdaVconnectionDataModelFunc ()"><span class="type">GdaVconnectionDataModelFunc</span></a> function pointer</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>data</p></td>
<td class="parameter_description"><p>data to pass to <em class="parameter"><code>func</code></em>
calls</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
</div>
</div>
<div class="refsect1">
<a name="GdaVconnectionDataModel.other_details"></a><h2>Types and Values</h2>
<div class="refsect2">
<a name="GdaVconnectionDataModel-struct"></a><h3>struct GdaVconnectionDataModel</h3>
<pre class="programlisting">struct GdaVconnectionDataModel;</pre>
</div>
<hr>
<div class="refsect2">
<a name="GdaVconnectionDataModelSpec"></a><h3>struct GdaVconnectionDataModelSpec</h3>
<pre class="programlisting">struct GdaVconnectionDataModelSpec {
GdaDataModel *data_model;
GdaVconnectionDataModelCreateColumnsFunc create_columns_func;
GdaVconnectionDataModelCreateModelFunc create_model_func;
GdaVconnectionDataModelParseFilterFunc create_filter_func;
GdaVconnectionDataModelCreateFModelFunc create_filtered_model_func;
};
</pre>
<p>This structure holds all the information supplied to declare a virtual table using
<a class="link" href="GdaVconnectionDataModel.html#gda-vconnection-data-model-add" title="gda_vconnection_data_model_add ()"><code class="function">gda_vconnection_data_model_add()</code></a>. You don't need to provider pointers for all the functions and
for <em class="parameter"><code>data_model</code></em>
, but the following rules have to be respected:</p>
<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
<li class="listitem"><p><em class="parameter"><code>data_model</code></em> is not <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> and all the function pointers are <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>: this is the situation
when the virtual table's contents is defined once by <em class="parameter"><code>data_model</code></em></p></li>
<li class="listitem">
<p><em class="parameter"><code>data_model</code></em> is <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> and <em class="parameter"><code>create_columns_func</code></em> is not <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>:
</p>
<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: circle; ">
<li class="listitem"><p><em class="parameter"><code>create_filtered_model_func</code></em> is not <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>: this is the situation where the
virtual table's associated data model handles filter optimizations.
<em class="parameter"><code>create_model_func</code></em> is ignored in this case.
</p></li>
<li class="listitem"><p><em class="parameter"><code>create_model_func</code></em> is not <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>: this is the situation where the
virtual table's associated data model does not handle filter optimizations
</p></li>
</ul></div>
<p>
</p>
</li>
</ul></div>
<p>Note that if specifying a <em class="parameter"><code>create_filtered_model_func</code></em>
, you should also specifiy a <em class="parameter"><code>create_filter_func</code></em>
function which is actually responsible for analysing the optimization.</p>
<div class="refsect3">
<a name="id-1.3.7.7.11.3.7"></a><h4>Members</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="300px" class="struct_members_name">
<col class="struct_members_description">
<col width="200px" class="struct_members_annotations">
</colgroup>
<tbody>
<tr>
<td class="struct_member_name"><p><a class="link" href="GdaDataModel.html" title="GdaDataModel"><span class="type">GdaDataModel</span></a> *<em class="structfield"><code><a name="GdaVconnectionDataModelSpec.data-model"></a>data_model</code></em>;</p></td>
<td class="struct_member_description"><p> a <a class="link" href="GdaDataModel.html" title="GdaDataModel"><span class="type">GdaDataModel</span></a>, or <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. </p></td>
<td class="struct_member_annotations"><span class="annotation">[<a href="http://foldoc.org/allow-none"><span class="acronym">allow-none</span></a>]</span></td>
</tr>
<tr>
<td class="struct_member_name"><p><a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelCreateColumnsFunc" title="GdaVconnectionDataModelCreateColumnsFunc ()"><span class="type">GdaVconnectionDataModelCreateColumnsFunc</span></a> <em class="structfield"><code><a name="GdaVconnectionDataModelSpec.create-columns-func"></a>create_columns_func</code></em>;</p></td>
<td class="struct_member_description"><p> a pointer to a <a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelCreateColumnsFunc" title="GdaVconnectionDataModelCreateColumnsFunc ()"><span class="type">GdaVconnectionDataModelCreateColumnsFunc</span></a> function, or <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. </p></td>
<td class="struct_member_annotations"><span class="annotation">[<a href="http://foldoc.org/allow-none"><span class="acronym">allow-none</span></a>]</span></td>
</tr>
<tr>
<td class="struct_member_name"><p><a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelCreateModelFunc" title="GdaVconnectionDataModelCreateModelFunc ()"><span class="type">GdaVconnectionDataModelCreateModelFunc</span></a> <em class="structfield"><code><a name="GdaVconnectionDataModelSpec.create-model-func"></a>create_model_func</code></em>;</p></td>
<td class="struct_member_description"><p> a pointer to a <a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelCreateModelFunc" title="GdaVconnectionDataModelCreateModelFunc ()"><span class="type">GdaVconnectionDataModelCreateModelFunc</span></a> function, or <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. </p></td>
<td class="struct_member_annotations"><span class="annotation">[<a href="http://foldoc.org/allow-none"><span class="acronym">allow-none</span></a>]</span></td>
</tr>
<tr>
<td class="struct_member_name"><p><a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelParseFilterFunc" title="GdaVconnectionDataModelParseFilterFunc ()"><span class="type">GdaVconnectionDataModelParseFilterFunc</span></a> <em class="structfield"><code><a name="GdaVconnectionDataModelSpec.create-filter-func"></a>create_filter_func</code></em>;</p></td>
<td class="struct_member_description"><p> a pointer to a <a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelParseFilterFunc" title="GdaVconnectionDataModelParseFilterFunc ()"><span class="type">GdaVconnectionDataModelParseFilterFunc</span></a> function, or <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. </p></td>
<td class="struct_member_annotations"><span class="annotation">[<a href="http://foldoc.org/allow-none"><span class="acronym">allow-none</span></a>]</span></td>
</tr>
<tr>
<td class="struct_member_name"><p><a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelCreateFModelFunc" title="GdaVconnectionDataModelCreateFModelFunc ()"><span class="type">GdaVconnectionDataModelCreateFModelFunc</span></a> <em class="structfield"><code><a name="GdaVconnectionDataModelSpec.create-filtered-model-func"></a>create_filtered_model_func</code></em>;</p></td>
<td class="struct_member_description"><p> a pointer to a <a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelCreateFModelFunc" title="GdaVconnectionDataModelCreateFModelFunc ()"><span class="type">GdaVconnectionDataModelCreateFModelFunc</span></a> function, or <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. </p></td>
<td class="struct_member_annotations"><span class="annotation">[<a href="http://foldoc.org/allow-none"><span class="acronym">allow-none</span></a>]</span></td>
</tr>
</tbody>
</table></div>
</div>
</div>
<hr>
<div class="refsect2">
<a name="GdaVconnectionDataModelFilter"></a><h3>struct GdaVconnectionDataModelFilter</h3>
<pre class="programlisting">struct GdaVconnectionDataModelFilter {
/* Inputs */
int nConstraint; /* Number of entries in aConstraint */
struct GdaVirtualConstraint {
int iColumn; /* Column on left-hand side of constraint */
GdaSqlOperatorType op; /* Constraint operator, among _EQ, _LT, _LEQ, _GT, _GEQ, _REGEXP */
} *aConstraint; /* Table of WHERE clause constraints */
int nOrderBy; /* Number of terms in the ORDER BY clause */
struct GdaVirtualOrderby {
int iColumn; /* Column number */
gboolean desc; /* TRUE for DESC. FALSE for ASC. */
} *aOrderBy; /* The ORDER BY clause */
/* Outputs */
struct GdaVirtualConstraintUsage {
int argvIndex; /* if >0, constraint is part of argv to xFilter */
gboolean omit; /* Do not code a test for this constraint if TRUE */
} *aConstraintUsage;
int idxNum; /* Number used to identify the index */
gpointer idxPointer; /* Pointer used to identify the index */
gboolean orderByConsumed; /* TRUE if output is already ordered */
double estimatedCost; /* Estimated cost of using this index */
};
</pre>
<p>This structure contains data which should be analysed to produce a data model (used as data
for a virtual table) when a <a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelCreateFModelFunc" title="GdaVconnectionDataModelCreateFModelFunc ()"><span class="type">GdaVconnectionDataModelCreateFModelFunc</span></a> is called. The structure
contains an input part (which should not be modified) and and output part (it is
closely mapped with SQLite's sqlite3_index_info type).</p>
<p>A pointer to this structure is passed to the <a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelParseFilterFunc" title="GdaVconnectionDataModelParseFilterFunc ()"><span class="type">GdaVconnectionDataModelParseFilterFunc</span></a> function
and the function has to modify the variables in the output part (marked as *Outputs*).</p>
<p>The <em class="parameter"><code>idxNum</code></em>
and <em class="parameter"><code>idxPointer</code></em>
are passed to the <a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelCreateFModelFunc" title="GdaVconnectionDataModelCreateFModelFunc ()"><span class="type">GdaVconnectionDataModelCreateFModelFunc</span></a> function call
and they represent nothing specific except that the GdaVconnectionDataModelParseFilterFunc and
GdaVconnectionDataModelCreateFModelFunc functions need to agree on their meaning.</p>
<p>See the gda-vconnection-hub.c file for an usage example.</p>
</div>
</div>
<div class="refsect1">
<a name="GdaVconnectionDataModel.signal-details"></a><h2>Signal Details</h2>
<div class="refsect2">
<a name="GdaVconnectionDataModel-vtable-created"></a><h3>The <code class="literal">“vtable-created”</code> signal</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
user_function (<a class="link" href="GdaVconnectionDataModel.html" title="GdaVconnectionDataModel"><span class="type">GdaVconnectionDataModel</span></a> *cnc,
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *spec,
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data)</pre>
<p>Signal emitted when a new virtual table has been declared</p>
<div class="refsect3">
<a name="id-1.3.7.7.12.2.5"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>cnc</p></td>
<td class="parameter_description"><p>the <a class="link" href="GdaVconnectionDataModel.html" title="GdaVconnectionDataModel"><span class="type">GdaVconnectionDataModel</span></a> connection</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>spec</p></td>
<td class="parameter_description"><p>the <a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelSpec" title="struct GdaVconnectionDataModelSpec"><span class="type">GdaVconnectionDataModelSpec</span></a> for the new virtual table</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>user_data</p></td>
<td class="parameter_description"><p>user data set when the signal handler was connected.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p>Flags: Run Last</p>
</div>
<hr>
<div class="refsect2">
<a name="GdaVconnectionDataModel-vtable-dropped"></a><h3>The <code class="literal">“vtable-dropped”</code> signal</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
user_function (<a class="link" href="GdaVconnectionDataModel.html" title="GdaVconnectionDataModel"><span class="type">GdaVconnectionDataModel</span></a> *cnc,
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *spec,
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data)</pre>
<p>Signal emitted when a new virtual table has been undeclared</p>
<div class="refsect3">
<a name="id-1.3.7.7.12.3.5"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>cnc</p></td>
<td class="parameter_description"><p>the <a class="link" href="GdaVconnectionDataModel.html" title="GdaVconnectionDataModel"><span class="type">GdaVconnectionDataModel</span></a> connection</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>spec</p></td>
<td class="parameter_description"><p>the <a class="link" href="GdaVconnectionDataModel.html#GdaVconnectionDataModelSpec" title="struct GdaVconnectionDataModelSpec"><span class="type">GdaVconnectionDataModelSpec</span></a> for the new virtual table</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>user_data</p></td>
<td class="parameter_description"><p>user data set when the signal handler was connected.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p>Flags: Run Last</p>
</div>
</div>
<div class="refsect1">
<a name="GdaVconnectionDataModel.see-also"></a><h2>See Also</h2>
<p>The <a class="link" href="GdaVproviderDataModel.html" title="GdaVproviderDataModel"><span class="type">GdaVproviderDataModel</span></a> provider to use to create such connection objects.</p>
</div>
</div>
<div class="footer">
<hr>
Generated by GTK-Doc V1.20</div>
</body>
</html>
|