1.StringUtilsä¸ isNotEmpty åisNotBlankçåºå«
StringUtilsä¸ isNotEmpty åisNotBlankçåºå«
源码snapkit源码 1ãææä¸ä¸æ ·源码snapkit源码isNotEmptyå°ç©ºæ ¼ä¹ä½ä¸ºåæ°ï¼isNotBlankåæé¤ç©ºæ ¼åæ°ã
源码snapkit源码2ãæä½æ¹æ³ä¸ä¸æ ·
源码snapkit源码StringUtilsæ¹æ³çæä½å¯¹è±¡æ¯java.lang.Stringç±»åç对象ï¼æ¯JDKæä¾çStringç±»åæä½æ¹æ³çè¡¥å ï¼å¹¶ä¸æ¯nullå®å ¨ç(å³å¦æè¾å ¥åæ°String为nullåä¸ä¼æåºNullPointerExceptionï¼èæ¯åäºç¸åºå¤çï¼ä¾å¦ï¼å¦æè¾å ¥ä¸ºnullåè¿åä¹æ¯nullçï¼å ·ä½å¯ä»¥æ¥çæºä»£ç )ã
源码snapkit源码3ãèå´ä¸ä¸æ ·
源码snapkit源码StringUtilsä¸ä¸å ±æå¤ä¸ªæ¹æ³ï¼å¹¶ä¸é½æ¯staticçï¼æ以æ们å¯ä»¥è¿æ ·è°ç¨StringUtils.xxx()
源码snapkit源码public static boolean isEmpty(String str)å¤ææå符串æ¯å¦ä¸ºç©ºï¼ä¸ºç©ºçæ åæ¯str==nullæstr.length()==0
源码snapkit源码public static boolean isNotEmpty(String str)å¤ææå符串æ¯å¦é空ï¼çäº!isEmpty(String str)
源码snapkit源码源码snapkit源码