| Previous CloneSet | Next CloneSet | Back to Main Report |
| Clone Mass | Clones in CloneSet | Parameter Count | Clone Similarity | Syntax Category [Sequence Length] |
|---|---|---|---|---|
| 21 | 2 | 0 | 1.000 | statement_sequence[6] |
| Clone Abstraction | Parameter Bindings |
| Clone Instance (Click to see clone) | Line Count | Source Line | Source File |
|---|---|---|---|
| 1 | 23 | 510 | administrator/components/com_content/models/article.php |
| 2 | 21 | 603 | administrator/components/com_menus/models/item.php |
| ||||
// $value comes as {menutype}.{parent_id}
$parts= explode('.', $value);
$menuType= $parts[0];
$parentId= (int) JArrayHelper::getValue($parts, 1, 0);
$table= &$this->getTable();
$db= &$this->getDbo();
// Check that the parent exists
if ($parentId)
{
if (!$table->load($parentId))
{
if ($error= $table->getError())
{
// Fatal error
$this->setError($error);
return FALSE;
}
else
{
// Non-fatal error
$this->setError(JText::_('Menus_Batch_Move_parent_not_found'));
$parentId= 0;
}
}
}
|
| ||||
// $value comes as {menutype}.{parent_id}
$parts= explode('.', $value);
$menuType= $parts[0];
$parentId= (int) JArrayHelper::getValue($parts, 1, 0);
$table= &$this->getTable();
$db= &$this->getDbo();
// Check that the parent exists.
if ($parentId)
{
if (!$table->load($parentId))
{
if ($error= $table->getError()) {
// Fatal error
$this->setError($error);
return FALSE;
}
else {
// Non-fatal error
$this->setError(JText::_('Menus_Batch_Move_parent_not_found'));
$parentId= 0;
}
}
}
|
| |||
// $value comes as {menutype}.{parent_id}
$parts=explode('.',$value);
$menuType=$parts[0];
$parentId= (int) JArrayHelper::getValue($parts,1,0);
$table= &$this->getTable();
$db= &$this->getDbo();
// Check that the parent exists.
// Check that the parent exists
if ($parentId) {
if (!$table->load($parentId)) {
if ($error=$table->getError()) {
// Fatal error
$this->setError($error);
return FALSE;
}
else {
// Non-fatal error
$this->setError(JText::_('Menus_Batch_Move_parent_not_found'));
$parentId=0;
}
}
}
|
| CloneAbstraction |
| Parameter Index | Clone Instance | Parameter Name | Value |
|---|---|---|---|
| None | |||