CloneSet426


Previous CloneSetNext CloneSetBack to Main Report
Clone
Mass
Clones in
CloneSet
Parameter
Count
Clone
Similarity
Syntax Category
[Sequence Length]
54220.981compilation_unit
Clone AbstractionParameter Bindings
Clone Instance
(Click to see clone)
Line CountSource Line
Source File
1541
E:/TSE/Projects-CloneDR/sql12/plugins/mysql/src/net/sourceforge/squirrel_sql/plugins/mysql/action/ExplainSelectTableCommand.java
2541
E:/TSE/Projects-CloneDR/sql12/plugins/mysql/src/net/sourceforge/squirrel_sql/plugins/mysql/action/ExplainTableCommand.java
Next
Last
Clone Instance
1
Line Count
54
Source Line
1
Source File
E:/TSE/Projects-CloneDR/sql12/plugins/mysql/src/net/sourceforge/squirrel_sql/plugins/mysql/action/ExplainSelectTableCommand.java

package net.sourceforge.squirrel_sql.plugins.mysql.action;

/*
 * Copyright (C) 2003 Colin Bell
 * colbell@users.sourceforge.net
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 2.1 of the License, or (at your option) any later version.
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 */
import net.sourceforge.squirrel_sql.client.session.ISession;
import net.sourceforge.squirrel_sql.fw.sql.IDatabaseObjectInfo;
import net.sourceforge.squirrel_sql.plugins.mysql.MysqlPlugin;

/**
 * This command will run a "EXPLAIN SELECT * FROM" over the
 * currently selected tables.
 *
 * @author <A HREF="mailto:colbell@users.sourceforge.net">Colin Bell</A>
 */
class ExplainSelectTableCommand extends AbstractMultipleSQLCommand {
  /**
   * Ctor.
   *
   * @throws      IllegalArgumentException
   *                      Thrown if a <TT>null</TT> <TT>ISession</TT>,
   *                      <TT>Resources</TT> or <TT>MysqlPlugin</TT> passed.
   */
  public ExplainSelectTableCommand(ISession session, MysqlPlugin plugin) {
    super(session, plugin);
  }

  /**
   * Retrieve the MySQL command to run.
   *
   *
   * @return      the MySQL command to run.
   */
  protected String getMySQLCommand(IDatabaseObjectInfo dbObj) {
    return "explain select * from " + dbObj.getQualifiedName();
  }
}




First
Previous
Clone Instance
2
Line Count
54
Source Line
1
Source File
E:/TSE/Projects-CloneDR/sql12/plugins/mysql/src/net/sourceforge/squirrel_sql/plugins/mysql/action/ExplainTableCommand.java

package net.sourceforge.squirrel_sql.plugins.mysql.action;

/*
 * Copyright (C) 2003 Colin Bell
 * colbell@users.sourceforge.net
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 2.1 of the License, or (at your option) any later version.
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 */
import net.sourceforge.squirrel_sql.client.session.ISession;
import net.sourceforge.squirrel_sql.fw.sql.IDatabaseObjectInfo;
import net.sourceforge.squirrel_sql.plugins.mysql.MysqlPlugin;

/**
 * This command will run a &quot;EXPLAIN&quot; over the
 * currently selected tables.
 *
 * @author <A HREF="mailto:colbell@users.sourceforge.net">Colin Bell</A>
 */
class ExplainTableCommand extends AbstractMultipleSQLCommand {
  /**
   * Ctor.
   *
   * @throws      IllegalArgumentException
   *                      Thrown if a <TT>null</TT> <TT>ISession</TT>,
   *                      <TT>Resources</TT> or <TT>MysqlPlugin</TT> passed.
   */
  public ExplainTableCommand(ISession session, MysqlPlugin plugin) {
    super(session, plugin);
  }

  /**
   * Retrieve the MySQL command to run.
   *
   *
   * @return      the MySQL command to run.
   */
  protected String getMySQLCommand(IDatabaseObjectInfo dbObj) {
    return "explain " + dbObj.getQualifiedName();
  }
}




Clone AbstractionParameter Count: 2Parameter Bindings

package net.sourceforge.squirrel_sql.plugins.mysql.action;

/*
 * Copyright (C) 2003 Colin Bell
 * colbell@users.sourceforge.net
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 2.1 of the License, or (at your option) any later version.
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 */
import net.sourceforge.squirrel_sql.client.session.ISession;
import net.sourceforge.squirrel_sql.fw.sql.IDatabaseObjectInfo;
import net.sourceforge.squirrel_sql.plugins.mysql.MysqlPlugin;

/**
 * This command will run a &quot;EXPLAIN&quot; over the
 * currently selected tables.
 *
 * @author <A HREF="mailto:colbell@users.sourceforge.net">Colin Bell</A>
 */
/**
 * This command will run a &quot;EXPLAIN SELECT * FROM&quot; over the
 * currently selected tables.
 *
 * @author <A HREF="mailto:colbell@users.sourceforge.net">Colin Bell</A>
 */
class [[#variable1ce39f80]]extends AbstractMultipleSQLCommand {
  /**
           * Ctor.
           *
           * @throws      IllegalArgumentException
           *                      Thrown if a <TT>null</TT> <TT>ISession</TT>,
           *                      <TT>Resources</TT> or <TT>MysqlPlugin</TT> passed.
           */
  public [[#variable1ce39f80]](ISession session, MysqlPlugin plugin) {
    super(session, plugin);
  }

  /**
           * Retrieve the MySQL command to run.
           *
           *
           * @return      the MySQL command to run.
           */
  protected String getMySQLCommand(IDatabaseObjectInfo dbObj) {
    return [[#variable1ce367e0]] + dbObj.getQualifiedName();
  }
}


 

CloneAbstraction
Parameter Bindings
Parameter
Index
Clone
Instance
Parameter
Name
Value
11[[#1ce39f80]]
ExplainSelectTableCommand 
12[[#1ce39f80]]
ExplainTableCommand 
21[[#1ce367e0]]
"explain select * from " 
22[[#1ce367e0]]
"explain "