Previous CloneSet | Next CloneSet | Back to Main Report |
Clone Mass | Clones in CloneSet | Parameter Count | Clone Similarity | Syntax Category [Sequence Length] |
---|---|---|---|---|
38 | 2 | 0 | 1.000 | statement_sequence[2] |
Clone Abstraction | Parameter Bindings |
Clone Instance (Click to see clone) | Line Count | Source Line | Source File |
---|---|---|---|
1 | 38 | 1274 | plugins/org.eclipse.jdt.core/formatter/org/eclipse/jdt/internal/formatter/CodeFormatterVisitor.java |
2 | 38 | 1359 | plugins/org.eclipse.jdt.core/formatter/org/eclipse/jdt/internal/formatter/CodeFormatterVisitor.java |
| ||||
if (arguments != null) { if (this.preferences.insert_space_after_opening_paren_in_method_invocation) { this.scribe.space(); } int argumentLength = arguments.length; Alignment argumentsAlignment = this.scribe.createAlignment( "messageArguments", //$NON-NLS-1$ this.preferences.alignment_for_arguments_in_method_invocation, Alignment.R_OUTERMOST, argumentLength, this.scribe.scanner.currentPosition ); this.scribe.enterAlignment(argumentsAlignment); boolean okForArguments = false; do { try { for (int j = 0; j < argumentLength; j++) { if (j > 0) { this.scribe.printNextToken(TerminalTokens.TokenNameCOMMA, this.preferences.insert_space_before_comma_in_method_invocation_arguments); this.scribe.printTrailingComment(); } this.scribe.alignFragment(argumentsAlignment, j); if (j > 0 && this.preferences.insert_space_after_comma_in_method_invocation_arguments) { this.scribe.space(); } arguments[j].traverse(this, scope); } okForArguments = true; } catch (AlignmentException e) { this.scribe.redoAlignment(e); } } while ( !okForArguments); this.scribe.exitAlignment(argumentsAlignment, true); this.scribe.printNextToken(TerminalTokens.TokenNameRPAREN, this.preferences.insert_space_before_closing_paren_in_method_invocation); } else { this.scribe.printNextToken(TerminalTokens.TokenNameRPAREN, this.preferences.insert_space_between_empty_parens_in_method_invocation); } if (numberOfParens > 0) { manageClosingParenthesizedExpression(currentMessageSend, numberOfParens); } |
| ||||
if (arguments != null) { if (this.preferences.insert_space_after_opening_paren_in_method_invocation) { this.scribe.space(); } int argumentLength = arguments.length; Alignment argumentsAlignment = this.scribe.createAlignment( "messageArguments", //$NON-NLS-1$ this.preferences.alignment_for_arguments_in_method_invocation, Alignment.R_OUTERMOST, argumentLength, this.scribe.scanner.currentPosition ); this.scribe.enterAlignment(argumentsAlignment); boolean okForArguments = false; do { try { for (int j = 0; j < argumentLength; j++) { if (j > 0) { this.scribe.printNextToken(TerminalTokens.TokenNameCOMMA, this.preferences.insert_space_before_comma_in_method_invocation_arguments); this.scribe.printTrailingComment(); } this.scribe.alignFragment(argumentsAlignment, j); if (j > 0 && this.preferences.insert_space_after_comma_in_method_invocation_arguments) { this.scribe.space(); } arguments[j].traverse(this, scope); } okForArguments = true; } catch (AlignmentException e) { this.scribe.redoAlignment(e); } } while ( !okForArguments); this.scribe.exitAlignment(argumentsAlignment, true); this.scribe.printNextToken(TerminalTokens.TokenNameRPAREN, this.preferences.insert_space_before_closing_paren_in_method_invocation); } else { this.scribe.printNextToken(TerminalTokens.TokenNameRPAREN, this.preferences.insert_space_between_empty_parens_in_method_invocation); } if (numberOfParens > 0) { manageClosingParenthesizedExpression(currentMessageSend, numberOfParens); } |
| |||
if (arguments != null) { if (this.preferences.insert_space_after_opening_paren_in_method_invocation) { this.scribe.space(); } int argumentLength = arguments.length; Alignment argumentsAlignment = this.scribe.createAlignment("messageArguments", //$NON-NLS-1$ this.preferences.alignment_for_arguments_in_method_invocation, Alignment.R_OUTERMOST, argumentLength, this.scribe.scanner.currentPosition); this.scribe.enterAlignment(argumentsAlignment); boolean okForArguments = false; do { try { for (int j = 0; j < argumentLength; j++) { if (j > 0) { this.scribe.printNextToken(TerminalTokens.TokenNameCOMMA, this.preferences.insert_space_before_comma_in_method_invocation_arguments); this.scribe.printTrailingComment(); } this.scribe.alignFragment(argumentsAlignment, j); if (j > 0 && this.preferences.insert_space_after_comma_in_method_invocation_arguments) { this.scribe.space(); } arguments[j].traverse(this, scope); } okForArguments = true; } catch (AlignmentException e) { this.scribe.redoAlignment(e); } } while ( !okForArguments); this.scribe.exitAlignment(argumentsAlignment, true); this.scribe.printNextToken(TerminalTokens.TokenNameRPAREN, this.preferences.insert_space_before_closing_paren_in_method_invocation); } else { this.scribe.printNextToken(TerminalTokens.TokenNameRPAREN, this.preferences.insert_space_between_empty_parens_in_method_invocation); } if (numberOfParens > 0) { manageClosingParenthesizedExpression(currentMessageSend, numberOfParens); } |
CloneAbstraction |
Parameter Index | Clone Instance | Parameter Name | Value |
---|---|---|---|
None |