if (ix == -1 || ix == name.length()-1) {
if("/".equals(jar) || (name.startsWith(jar) && name.length()>jar.length())) {
dirp.add(je);
}
}
if (!registerSelect(context, selector, obj, ioObj, SelectionKey.OP_WRITE)) {
if ((ioObj.openFile.getMode() & OpenFile.WRITABLE) != 0) {
unselectable_writes.add(obj);
}
}
Clone fragments detected by clone detection tool
File path: /jruby-1.4.0/src/org/jruby/util/Dir.java
|
|
File path: /jruby-1.4.0/src/org/jruby/RubyIO.java
|
Method name: int glob_helper(String, byte[], int, int, int, int, GlobFunc, GlobArgs)
|
|
Method name: IRubyObject select_static(ThreadContext, Ruby, IRubyObject[])
|
Number of AST nodes: 3
|
|
Number of AST nodes: 3
|
|
1 | if (ix == -1 || ix == name.length()-1) {↵ | | 1 | if (↵
|
2 | if("/".equals(jar) || (name.startsWith(jar) && name.length()>jar.length())↵ | | 2 | !registerSelect(context, selector, obj, ioObj, SelectionKey.OP_WRITE)) {↵
|
3 | ) {↵ | | 3 | if ((ioObj.openFile.getMode() & OpenFile.WRITABLE) != 0) {↵
|
4 | dirp.add(je);↵ | | 4 | ↵
|
5 | ↵ | | 5 | unselectable_writes.add(obj);↵
|
6 | }↵ | | 6 | ↵
|
7 | ↵ | | 7 | }↵
|
8 | } | | 8 | }
|
See real code fragment |
|
See real code fragment |
Summary
Number of common nesting structure subtrees | 0 |
Number of refactorable cases | 0 |
Number of non-refactorable cases | 0 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.2 |
Clones location | Clones are in different classes |
Number of node comparisons | 1 |