Class RedundantCastUtility
- java.lang.Object
-
- com.strobel.decompiler.languages.java.utilities.RedundantCastUtility
-
public final class RedundantCastUtility extends java.lang.Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description private static class
RedundantCastUtility.CastCollector
private static class
RedundantCastUtility.IsRedundantVisitor
-
Constructor Summary
Constructors Constructor Description RedundantCastUtility()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static java.util.List<CastExpression>
getRedundantCastsInside(Function<AstNode,ResolveResult> resolver, AstNode site)
static boolean
isCastRedundant(Function<AstNode,ResolveResult> resolver, CastExpression cast)
static void
removeCast(CastExpression castExpression)
private static Expression
removeParentheses(Expression e)
private static AstNode
skipParenthesesUp(AstNode e)
-
-
-
Method Detail
-
getRedundantCastsInside
@NotNull public static java.util.List<CastExpression> getRedundantCastsInside(Function<AstNode,ResolveResult> resolver, AstNode site)
-
isCastRedundant
public static boolean isCastRedundant(Function<AstNode,ResolveResult> resolver, CastExpression cast)
-
removeCast
public static void removeCast(CastExpression castExpression)
-
removeParentheses
@Nullable private static Expression removeParentheses(Expression e)
-
-