I read tutorial on Joomla.org about com development using database
in the link https://docs.joomla.org/Special:MyLanguage/J3.2:Developing_an_MVC_Component/Using_the_database.
on the file admin/tables/helloworld.php
I found a class I don't understand. this is the code.
<?php
/**
* @package Joomla.Administrator
* @subpackage com_helloworld
*
* @copyright Copyright (C) 2005 - 2018 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
// No direct access
defined('_JEXEC') or die('Restricted access');
/**
* Hello Table class
*
* @since 0.0.1
*/
class HelloWorldTableHelloWorld extends JTable
{
/**
* Constructor
*
* @param JDatabaseDriver &$db A database connector object
*/
function __construct(&$db)
{
parent::__construct('#__helloworld', 'id', $db);
}
}
in the class HelloWorldTableHelloWorld
there is only constructor
with 1 line parent::__construct('#__helloworld', 'id', $db);
and no other code. but I believe it does something I dont understand. can anyone explain this , thanks