00001 00002 #define SERVER_ROUTE_FIND_LISTEN_PORT 3333 00003 00004 #define SERVER_ROUTE_SEARCH_LISTEN_PORT 3334 00005 00006 #define SERVER_GET_MAP_LISTEN_PORT 3335 00007 00008 #define SERVER_GET_TEXT_LISTEN_PORT 3336 00009 00010 #define SERVER_FEEDBACK_LISTEN_PORT 3337 00011 00012 #define SERVER_QUEUE_SIZE 128 00013 #define SERVER_MAX_THREADS 33 00014 #define TIMEOUT_S 6 00015 00016 #define IP "cslab7h.cs.brown.edu" 00017 00019 struct testData{ 00020 int theInt; 00021 double theDouble; 00022 double secondDouble; 00023 } __attribute__ ((packed)); //no padding 00024 00025 // Struct to send strings for routeFindClient 00027 struct routeFindData{ 00028 bool isStartFinish; 00029 //the length of the char*'s which will be 00030 //stored in data (IN THIS ORDER) 00031 int start_street_len; 00032 int start_city_len; 00033 int start_state_len; 00034 int start_zip_len; 00035 int finish_street_len; 00036 int finish_city_len; 00037 int finish_state_len; 00038 int finish_zip_len; 00039 //some ratings 00040 int traffic; 00041 int difficulty; 00042 int finish_dist; 00043 //the strings... 00044 char data[1]; 00045 } __attribute__ ((packed)); //no padding 00046 00048 struct routeSearchData{ 00049 bool isLoop; 00050 int startid; 00051 int finishid; 00052 int dist; 00053 int difficulty; 00054 int mintraffic; 00055 } __attribute__ ((packed)); 00056