Log lower Than Or Equal message - Android App

Android examples for App:Log

Description

Log lower Than Or Equal message

Demo Code


//package com.java2s;
import android.util.Log;

public class Main {
    public static void lowerThanOrEqual(int value, int end, String message) {
        if (value > end) {
            Log.d("TTT", "Value : " + value + " | Compared: " + end);
            throw new IllegalArgumentException(message);
        }//from w  w  w  .j a  v a2  s  .  c om
    }

    public static void lowerThanOrEqual(int value, int end) {
        lowerThanOrEqual(value, end, null);
    }
}

Related Tutorials