| 
									
										
										
										
											2021-05-11 16:08:08 -04:00
										 |  |  | #ifndef _TA_UTILS_H
 | 
					
						
							|  |  |  | #define _TA_UTILS_H
 | 
					
						
							|  |  |  | #include <stdio.h>
 | 
					
						
							|  |  |  | #include <string.h>
 | 
					
						
							|  |  |  | #include <string>
 | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2022-01-17 17:44:17 -05:00
										 |  |  | #ifdef _MSC_VER
 | 
					
						
							|  |  |  | #include <BaseTsd.h>
 | 
					
						
							|  |  |  | typedef SSIZE_T ssize_t; | 
					
						
							|  |  |  | #endif
 | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2021-05-11 16:08:08 -04:00
										 |  |  | typedef std::string String; | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2021-05-17 20:18:59 -04:00
										 |  |  | #define MIN(a,b) (((a)<(b))?(a):(b))
 | 
					
						
							|  |  |  | #define MAX(a,b) (((a)>(b))?(a):(b))
 | 
					
						
							| 
									
										
										
										
											2021-05-17 16:36:14 -04:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2021-12-16 15:51:19 -05:00
										 |  |  | #ifdef _WIN32
 | 
					
						
							|  |  |  | typedef std::wstring WString; | 
					
						
							| 
									
										
										
										
											2021-05-28 16:25:55 -04:00
										 |  |  | #endif
 | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2021-06-09 04:33:03 -04:00
										 |  |  | struct TAParam { | 
					
						
							|  |  |  |   String shortName; | 
					
						
							|  |  |  |   String name; | 
					
						
							|  |  |  |   String valName; | 
					
						
							|  |  |  |   String desc; | 
					
						
							|  |  |  |   bool value; | 
					
						
							|  |  |  |   bool (*func)(String); | 
					
						
							|  |  |  |   TAParam(String sn, String n, bool v, bool (*f)(String), String vn, String d): | 
					
						
							|  |  |  |     shortName(sn), | 
					
						
							|  |  |  |     name(n), | 
					
						
							|  |  |  |     valName(vn), | 
					
						
							|  |  |  |     desc(d), | 
					
						
							|  |  |  |     value(v), | 
					
						
							|  |  |  |     func(f) {} | 
					
						
							|  |  |  | }; | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2021-05-17 16:36:14 -04:00
										 |  |  | #endif
 |