mirror of
				https://github.com/Telecominfraproject/wlan-lanforge-scripts.git
				synced 2025-10-31 18:58:01 +00:00 
			
		
		
		
	 25d40a7a6a
			
		
	
	25d40a7a6a
	
	
	
		
			
			This allows py-scripts and py-json modules to access this logic independent of the lanforge_api.py module. Signed-off-by: Jed Reynolds <jed@bitratchet.com>
		
			
				
	
	
		
			21 lines
		
	
	
		
			395 B
		
	
	
	
		
			Python
		
	
	
	
	
	
			
		
		
	
	
			21 lines
		
	
	
		
			395 B
		
	
	
	
		
			Python
		
	
	
	
	
	
| def iss(text: str) -> bool:
 | |
|     """
 | |
| 
 | |
|     :param text: string to test
 | |
|     :return: true if text is at lease one non-whitespace character
 | |
|     """
 | |
|     if text is None:
 | |
|         return False
 | |
|     if (len(text) == 0) or (text.strip() == ""):
 | |
|         return False
 | |
|     return True
 | |
| 
 | |
| 
 | |
| def nott(text: str) -> bool:
 | |
|     """
 | |
| 
 | |
|     :param text:
 | |
|     :return: opposite of is
 | |
|     """
 | |
|     return not iss(text=text)
 |