Showing 231 of 426 total issues
Method removeLocalPreset
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring. Open
public void removeLocalPreset(String presetName, Runnable onSuccess, Runnable onFailure) {
if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.N_MR1) {
ShortcutManager shortcutManager = activity.getSystemService(ShortcutManager.class);
if (shortcutManager != null) {
shortcutManager.removeDynamicShortcuts(Arrays.asList(presetName));
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method fadeIn
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring. Open
public void fadeIn(final int id, final int delay, final long duration, String handlerName, View parentView, Activity activity) {
final AlphaAnimation fadeIn = new AlphaAnimation(0.0f, 1.0f);
final View view = parentView.findViewById(id);
view.setVisibility(View.INVISIBLE);
PowerManager powerManager = (PowerManager) activity.getSystemService(POWER_SERVICE);
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method fadeOutInvisible
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring. Open
public void fadeOutInvisible(final int id, final int delay, final long duration, View parentView, Activity activity) {
final AlphaAnimation fadeOut = new AlphaAnimation(1.0f, 0.0f);
final View view = parentView.findViewById(id);
PowerManager powerManager = (PowerManager) activity.getSystemService(POWER_SERVICE);
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method fadeOut
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring. Open
public void fadeOut(final int id, final int delay, final long duration, View parentView, Activity activity) {
final AlphaAnimation fadeOut = new AlphaAnimation(1.0f, 0.0f);
final View view = parentView.findViewById(id);
PowerManager powerManager = (PowerManager) activity.getSystemService(POWER_SERVICE);
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method deleteRecursive
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring. Open
public boolean deleteRecursive(File fileOrDirectory) {
boolean recursive = true;
if (fileOrDirectory.isDirectory())
if (fileOrDirectory.listFiles() != null && fileOrDirectory.listFiles().length > 0)
for (File child : fileOrDirectory.listFiles())
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method fade
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring. Open
public void fade(final int id, final float startAlpha, final float endAlpha, final int delay, final long duration, String handlerName, Activity activity) {
final AlphaAnimation fade = new AlphaAnimation(startAlpha, endAlpha);
final View view = activity.findViewById(id);
PowerManager powerManager = (PowerManager) activity.getSystemService(POWER_SERVICE);
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method fadeIn
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring. Open
public void fadeIn(final int id, final int delay, final long duration, String handlerName, Activity activity) {
final AlphaAnimation fadeIn = new AlphaAnimation(0.0f, 1.0f);
final View view = activity.findViewById(id);
view.setVisibility(View.INVISIBLE);
PowerManager powerManager = (PowerManager) activity.getSystemService(POWER_SERVICE);
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method fadeOutInvisible
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring. Open
public void fadeOutInvisible(final int id, final int delay, final long duration, Activity activity) {
final AlphaAnimation fadeOut = new AlphaAnimation(1.0f, 0.0f);
final View view = activity.findViewById(id);
PowerManager powerManager = (PowerManager) activity.getSystemService(POWER_SERVICE);
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method fadeIn
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring. Open
public void fadeIn(final View view, final int delay, final long duration, String handlerName, Activity activity) {
final AlphaAnimation fadeIn = new AlphaAnimation(0.0f, 1.0f);
view.setVisibility(View.INVISIBLE);
PowerManager powerManager = (PowerManager) activity.getSystemService(POWER_SERVICE);
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method intentSharedElementWithExtra
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
public void intentSharedElementWithExtra(final Activity activity, final String targetName, final int start_element_id, final String transitionName, final String extraName, final int extra, int delay) {
Method intentSharedElementWithExtra
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
public void intentSharedElementWithExtra(final Activity activity, final String targetName, final int start_element_id, final String transitionName, final String extraName, final String extra, int delay) {
Method circularRevealTouch
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
public void circularRevealTouch(View touch_view, final int reveal_view,
final TimeInterpolator interpolator, final Runnable onClick,
final int duration, final int delay, final Activity activity) {
Method scaleOut
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
public void scaleOut(final int id, int touchX, int touchY, final int delay, final long duration, String handlerName, Activity activity) {
Method getGesturePadFromArray
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
private GesturePad getGesturePadFromArray(String soundPaths[],
SoundPool soundPool,
int deck,
View buttonView,
int color, int colorDef,
Method scaleIn
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
public void scaleIn(final int id, int touchX, int touchY, final int delay, final long duration, String handlerName, Activity activity) {
Method scaleOut
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
public void scaleOut(final View view, int touchX, int touchY, final int delay, final long duration, String handlerName, Activity activity) {
Method scaleIn
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
public void scaleIn(final View view, int touchX, int touchY, final int delay, final long duration, String handlerName, Activity activity) {
Method fade
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
public void fade(final int id, final float startAlpha, final float endAlpha, final int delay, final long duration, String handlerName, Activity activity) {
Method circularRevealTouch
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
public void circularRevealTouch(int touch_view, final int reveal_view,
final TimeInterpolator interpolator, final Runnable onClick,
final int duration, final int delay, final Activity activity) {
Method setMarginRelativePX
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
public void setMarginRelativePX(int id, int left, int top, int right, int bottom, Activity activity) {