Example #1
0
 public void ConfirmBookingReq(Action onComplete, Action <TException> onTException)
 {
     DirectionsProvider.GetRoutesAsync((json) => {
         ExceptionSafe(() => {
             CurrentReq.Details.RouteJson = json;
             using (var client = new RequestHandler.Client(GetThriftProtocol(PortOffsets.RequestHandler)))
             {
                 BookingId = client.submitBooking(CurrentReq.Details);
             }
             onComplete();
         }, onTException);
     }, CurrentReq.Src.Loc, CurrentReq.Dst.Loc);
 }
Example #2
0
        private AppCommon(string googleApiKeyNative, string googleApiKeyWeb, ILocationProvider locationProvider)
        {
            Inst               = this;
            IsLoggedIn         = false;
            GoogleApiKeyNative = googleApiKeyNative;
            GoogleApiKeyWeb    = googleApiKeyWeb;

            Log         = new Logger();
            IsPassenger = new DynProp <bool> (true);
            LoadAppData();
            PlacesProvider       = new PlacesProvider();
            DirectionsProvider   = new DirectionsProvider();
            LocationProvider     = locationProvider;
            NearestPointProvider = new NearestPointProvider();

            IsPassenger.Value = AppData.IsLastUserPassenger;
        }
Example #3
0
		private AppCommon(string googleApiKeyNative, string googleApiKeyWeb, ILocationProvider locationProvider)
		{
			Inst = this;
			IsLoggedIn = false;
			GoogleApiKeyNative = googleApiKeyNative;
			GoogleApiKeyWeb = googleApiKeyWeb;

			Log = new Logger ();
			IsPassenger = new DynProp<bool> (true); 
			LoadAppData ();
			PlacesProvider = new PlacesProvider ();
			DirectionsProvider = new DirectionsProvider ();
			LocationProvider = locationProvider;
			NearestPointProvider = new NearestPointProvider ();

			IsPassenger.Value = AppData.IsLastUserPassenger;
		}