Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
小 白蛋
Intellij Community
Commits
7d4de5cb
Commit
7d4de5cb
authored
7 years ago
by
Sergey Ignatov
Browse files
Options
Download
Email Patches
Plain Diff
remove unused code
parent
931179bc
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
java/java-impl/src/com/intellij/psi/formatter/java/JavaFormatterUtil.java
+0
-29
...rc/com/intellij/psi/formatter/java/JavaFormatterUtil.java
with
0 additions
and
29 deletions
+0
-29
java/java-impl/src/com/intellij/psi/formatter/java/JavaFormatterUtil.java
+
0
-
29
View file @
7d4de5cb
...
...
@@ -17,9 +17,7 @@ package com.intellij.psi.formatter.java;
import
com.intellij.formatting.WrapType
;
import
com.intellij.lang.ASTNode
;
import
com.intellij.psi.PsiExpression
;
import
com.intellij.psi.PsiPolyadicExpression
;
import
com.intellij.psi.PsiWhiteSpace
;
import
com.intellij.psi.codeStyle.CommonCodeStyleSettings
;
import
com.intellij.psi.impl.source.tree.JavaElementType
;
import
com.intellij.psi.tree.IElementType
;
...
...
@@ -75,33 +73,6 @@ public class JavaFormatterUtil {
return
expression1
.
getOperationTokenType
()
==
expression2
.
getOperationTokenType
();
}
public
static
boolean
hasMultilineArguments
(
@NotNull
PsiExpression
[]
arguments
)
{
for
(
PsiExpression
argument:
arguments
)
{
ASTNode
node
=
argument
.
getNode
();
if
(
node
.
textContains
(
'\n'
))
return
true
;
}
return
false
;
}
public
static
boolean
isMultilineExceptArguments
(
@NotNull
PsiExpression
[]
arguments
)
{
for
(
PsiExpression
argument
:
arguments
)
{
ASTNode
beforeArgument
=
argument
.
getNode
().
getTreePrev
();
if
(
isWhiteSpaceWithLineFeed
(
beforeArgument
))
return
true
;
}
PsiExpression
lastArgument
=
arguments
[
arguments
.
length
-
1
];
ASTNode
afterLastArgument
=
lastArgument
.
getNode
().
getTreeNext
();
return
isWhiteSpaceWithLineFeed
(
afterLastArgument
);
}
private
static
boolean
isWhiteSpaceWithLineFeed
(
@NotNull
ASTNode
node
)
{
return
node
instanceof
PsiWhiteSpace
&&
node
.
textContains
(
'\n'
);
}
@NotNull
public
static
WrapType
getWrapType
(
int
wrap
)
{
switch
(
wrap
)
{
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment
Menu
Projects
Groups
Snippets
Help