CloneSet315


Previous CloneSetNext CloneSetBack to Main Report
Clone
Mass
Clones in
CloneSet
Parameter
Count
Clone
Similarity
Syntax Category
[Sequence Length]
28230.967block
Clone AbstractionParameter Bindings
Clone Instance
(Click to see clone)
Line CountSource Line
Source File
128200
E:/TSE/Projects-CloneDR/apache-ant-1.7.0/src/org/apache/tools/ant/util/JavaEnvUtils.java
228241
E:/TSE/Projects-CloneDR/apache-ant-1.7.0/src/org/apache/tools/ant/util/JavaEnvUtils.java
Next
Last
Clone Instance
1
Line Count
28
Source Line
200
Source File
E:/TSE/Projects-CloneDR/apache-ant-1.7.0/src/org/apache/tools/ant/util/JavaEnvUtils.java

{
  if (IS_NETWARE) {
    // Extrapolating from:
    // "NetWare may have a "java" in that directory, but 99% of
    // the time, you don't want to execute it" -- Jeff Tulley
    // <JTULLEY@novell.com>
    return command;
  }
  File jExecutable = null;
  if (IS_AIX) {
    // On IBM's JDK 1.2 the directory layout is different, 1.3 follows
    // Sun's layout.
    jExecutable = findInDir(JAVA_HOME + "/sh", command);
  }
  if (jExecutable == null) {
    jExecutable = findInDir(JAVA_HOME + "/bin", command);
  }
  if (jExecutable != null) {
    return jExecutable.getAbsolutePath();
  }
  else {
    // Unfortunately on Windows java.home doesn't always refer
    // to the correct location, so we need to fall back to
    // assuming java is somewhere on the PATH.
    return addExtension(command);
  }
}


First
Previous
Clone Instance
2
Line Count
28
Source Line
241
Source File
E:/TSE/Projects-CloneDR/apache-ant-1.7.0/src/org/apache/tools/ant/util/JavaEnvUtils.java

{
  if (IS_NETWARE) {
    // Extrapolating from:
    // "NetWare may have a "java" in that directory, but 99% of
    // the time, you don't want to execute it" -- Jeff Tulley
    // <JTULLEY@novell.com>
    return command;
  }
  File jExecutable = null;
  if (IS_AIX) {
    // On IBM's JDK 1.2 the directory layout is different, 1.3 follows
    // Sun's layout.
    jExecutable = findInDir(JAVA_HOME + "/../sh", command);
  }
  if (jExecutable == null) {
    jExecutable = findInDir(JAVA_HOME + "/../bin", command);
  }
  if (jExecutable != null) {
    return jExecutable.getAbsolutePath();
  }
  else {
    // fall back to JRE bin directory, also catches JDK 1.0 and 1.1
    // where java.home points to the root of the JDK and Mac OS X where
    // the whole directory layout is different from Sun's
    return getJreExecutable(command);
  }
}


Clone AbstractionParameter Count: 3Parameter Bindings

{
  if (IS_NETWARE) {
    // Extrapolating from:
    // "NetWare may have a "java" in that directory, but 99% of
    // the time, you don't want to execute it" -- Jeff Tulley
    // <JTULLEY@novell.com>
    return command;
  }
  File jExecutable = null;
  if (IS_AIX) {
    // On IBM's JDK 1.2 the directory layout is different, 1.3 follows
    // Sun's layout.
    jExecutable = findInDir(JAVA_HOME +  [[#variable100dd2a0]], command);
  }
  if (jExecutable == null) {
    jExecutable = findInDir(JAVA_HOME +  [[#variable100dd000]], command);
  }
  if (jExecutable != null) {
    return jExecutable.getAbsolutePath();
  }
  else {
    // fall back to JRE bin directory, also catches JDK 1.0 and 1.1
    // where java.home points to the root of the JDK and Mac OS X where
    // the whole directory layout is different from Sun's
    // Unfortunately on Windows java.home doesn't always refer
    // to the correct location, so we need to fall back to
    // assuming java is somewhere on the PATH.
    return [[#variable100dd060]](command);
  }
}
 

CloneAbstraction
Parameter Bindings
Parameter
Index
Clone
Instance
Parameter
Name
Value
11[[#100dd2a0]]
"/sh" 
12[[#100dd2a0]]
"/../sh" 
21[[#100dd000]]
"/bin" 
22[[#100dd000]]
"/../bin" 
31[[#100dd060]]
addExtension 
32[[#100dd060]]
getJreExecutable