int getSelectionStart() { if(selection.size() != 1) return caret; return ((Selection)selection.elementAt(0)).getStart(); } //}}} //{{{ getSelectionStart() method /** * @deprecated Instead, obtain a Selection instance using * any means, and call its <code>getStart(int)</code> method */ public int getSelectionStart(int line) { if(selection.size() != 1) return caret; return ((Selection)selection.elementAt(0)).getStart( buffer,line); } //}}} //{{{ getSelectionStartLine() method /** * @deprecated Instead, obtain a Selection instance using * any means, and call its <code>getStartLine()</code> method */ public final int getSelectionStartLine() { if(selection.size() != 1) return caret; return ((Selection)selection.elementAt(0)).getStartLine(); }
int getSelectionEnd() { if(selection.size() != 1) return caret; return ((Selection)selection.elementAt(0)).getEnd(); } //}}} //{{{ getSelectionEnd() method /** * @deprecated Instead, obtain a Selection instance using * any means, and call its <code>getEnd(int)</code> method */ public int getSelectionEnd(int line) { if(selection.size() != 1) return caret; return ((Selection)selection.elementAt(0)).getEnd( buffer,line); } //}}} //{{{ getSelectionEndLine() method /** * @deprecated Instead, obtain a Selection instance using * any means, and call its <code>getEndLine()</code> method */ public final int getSelectionEndLine() { if(selection.size() != 1) return caret; return ((Selection)selection.elementAt(0)).getEndLine(); }
Clone fragments detected by clone detection tool
File path: /jEdit-4.2/src/org/gjt/sp/jedit/textarea/JEditTextArea.java File path: /jEdit-4.2/src/org/gjt/sp/jedit/textarea/JEditTextArea.java
Method name: Method name:
Number of AST nodes: 0 Number of AST nodes: 0
1
int getSelectionStart()
1
int getSelectionEnd()
2
	{
2
	{
3
		if(selection.size() != 1)
3
		if(selection.size() != 1)
4
			return caret;
4
			return caret;
5
		return ((Selection)selection.elementAt(0)).getStart();
5
		return ((Selection)selection.elementAt(0)).getEnd();
6
	} //}}}
6
	} //}}}
7
	//{{{ getSelectionStart() method
7
	//{{{ getSelectionEnd() method
8
	/**
8
	/**
9
	 * @deprecated Instead, obtain a Selection instance using
9
	 * @deprecated Instead, obtain a Selection instance using
10
	 * any means, and call its <code>getStart(int)</code> method
10
	 * any means, and call its <code>getEnd(int)</code> method
11
	 */
11
	 */
12
	public int getSelectionStart(int line)
12
	public int getSelectionEnd(int line)
13
	{
13
	{
14
		if(selection.size() != 1)
14
		if(selection.size() != 1)
15
			return caret;
15
			return caret;
16
		return ((Selection)selection.elementAt(0)).getStart(
16
		return ((Selection)selection.elementAt(0)).getEnd(
17
			buffer,line);
17
			buffer,line);
18
	} //}}}
18
	} //}}}
19
	//{{{ getSelectionStartLine() method
19
	//{{{ getSelectionEndLine() method
20
	/**
20
	/**
21
	 * @deprecated Instead, obtain a Selection instance using
21
	 * @deprecated Instead, obtain a Selection instance using
22
	 * any means, and call its <code>getStartLine()</code> method
22
	 * any means, and call its <code>getEndLine()</code> method
23
	 */
23
	 */
24
	public final int getSelectionStartLine()
24
	public final int getSelectionEndLine()
25
	{
25
	{
26
		if(selection.size() != 1)
26
		if(selection.size() != 1)
27
			return caret;
27
			return caret;
28
		return ((Selection)selection.elementAt(0)).getStartLine();
28
		return ((Selection)selection.elementAt(0)).getEndLine();
29
	}
29
	}
Summary
Number of common nesting structure subtrees0
Number of refactorable cases0
Number of non-refactorable cases0
Time elapsed for finding largest common nesting structure subtrees (ms)0.0
Clones location
Number of node comparisons0