Java tutorial
//package com.java2s; //License from project: Open Source License public class Main { public static boolean isWholePositiveNumber(String value) { if (value == null) { return false; } for (char c : value.toCharArray()) { if (!Character.isDigit(c)) { return false; } } return true; } }