CloneSet236


Previous CloneSetNext CloneSetBack to Main Report
Clone
Mass
Clones in
CloneSet
Parameter
Count
Clone
Similarity
Syntax Category
[Sequence Length]
19320.995class_member
Clone AbstractionParameter Bindings
Clone Instance
(Click to see clone)
Line CountSource Line
Source File
119149
administrator/components/com_redirect/models/link.php
219178
administrator/components/com_redirect/models/link.php
319207
administrator/components/com_redirect/models/link.php
Clone Instance
1
Line Count
19
Source Line
149
Source File
administrator/components/com_redirect/models/link.php

        /**
         * Method to publish links.
         *
         * @access      public
         * @param       array   The ids of the items to publish.
         * @return      boolean True on success.
         * @since       1.6
         */
        function publish($linkId) {

                // Sanitize the ids.
                $linkId=  (array) $linkId;
                JArrayHelper::toInteger($linkId);

                // Get the current user object.
                $user=  & JFactory::getUser();

                // Get a link row instance.
                $table=  &$this-> getTable('Link', 'RedirectTable');

                // Attempt to publish the items.
                if (!$table->publish($linkId, 1, $user->get('id'))) {
                        $this->setError($table->getError());
                        return FALSE;
                      }

                return TRUE;
              }


Clone Instance
2
Line Count
19
Source Line
178
Source File
administrator/components/com_redirect/models/link.php

        /**
         * Method to unpublish links.
         *
         * @access      public
         * @param       array   The ids of the items to unpublish.
         * @return      boolean True on success.
         * @since       1.6
         */
        function unpublish($linkId) {

                // Sanitize the ids.
                $linkId=  (array) $linkId;
                JArrayHelper::toInteger($linkId);

                // Get the current user object.
                $user=  & JFactory::getUser();

                // Get a link row instance.
                $table=  &$this-> getTable('Link', 'RedirectTable');

                // Attempt to unpublish the items.
                if (!$table->publish($linkId, 0, $user->get('id'))) {
                        $this->setError($table->getError());
                        return FALSE;
                      }

                return TRUE;
              }


Clone Instance
3
Line Count
19
Source Line
207
Source File
administrator/components/com_redirect/models/link.php

        /**
         * Method to archive links.
         *
         * @access      public
         * @param       array   The ids of the items to unpublish.
         * @return      boolean True on success.
         * @since       1.6
         */
        function archive($linkId) {

                // Sanitize the ids.
                $linkId=  (array) $linkId;
                JArrayHelper::toInteger($linkId);

                // Get the current user object.
                $user=  & JFactory::getUser();

                // Get a link row instance.
                $table=  &$this-> getTable('Link', 'RedirectTable');

                // Attempt to unpublish the items.
                if (!$table->publish($linkId, 2, $user->get('id'))) {
                        $this->setError($table->getError());
                        return FALSE;
                      }

                return TRUE;
              }


Clone AbstractionParameter Count: 2Parameter Bindings

/**
         * Method to archive links.
         *
         * @access      public
         * @param       array   The ids of the items to unpublish.
         * @return      boolean True on success.
         * @since       1.6
         */
/**
         * Method to unpublish links.
         *
         * @access      public
         * @param       array   The ids of the items to unpublish.
         * @return      boolean True on success.
         * @since       1.6
         */
/**
         * Method to publish links.
         *
         * @access      public
         * @param       array   The ids of the items to publish.
         * @return      boolean True on success.
         * @since       1.6
         */
function [[#variable52344ae0]]($linkId) {
  // Sanitize the ids.
  $linkId= (array) $linkId;
  JArrayHelper::toInteger($linkId);
  // Get the current user object.
  $user= &JFactory::getUser();
  // Get a link row instance.
  $table= &$this->getTable('Link','RedirectTable');
  // Attempt to unpublish the items.
  // Attempt to publish the items.
  if (!$table->publish($linkId, [[#variable52344ac0]],$user->get('id'))) {
    $this->setError($table->getError());
    return FALSE;
  }
  return TRUE;
}
 

CloneAbstraction
Parameter Bindings
Parameter
Index
Clone
Instance
Parameter
Name
Value
11[[#52344ae0]]
archive 
12[[#52344ae0]]
unpublish 
13[[#52344ae0]]
publish 
21[[#52344ac0]]
2 
22[[#52344ac0]]
0 
23[[#52344ac0]]
1