public ItemsController() { dataContext = new ExchaggleDbContext(); uploadManager = new UploadService(dataContext); itemManager = new ItemService(dataContext); global = new GlobalService(dataContext); }
[Test] //Bug 2849 public void TheVendorAPI_UploadBatchWithDuplicateRefD9Segments() { method = new StackTrace().GetFrame(0).GetMethod(); package = new VendorPackage(client, Document.CreateDocument(duplicateRefsBatch)); var results = UploadService.CallUploadService(package); try { Assert.AreEqual(true, results.thrownException); } catch (Exception) { verificationErrors.Append( "Expected Batch That Uploaded With Duplicate Ref D9s To Throw Exception But No Exceptions Were Thrown"); } try { Assert.AreEqual("Batch import failed. Batch contains claims with duplicate REF*D9 segments.", results.Exceptions[0].Message); } catch (AssertionException e) { verificationErrors.Append(e.Message); } endOfTest(); }
public SiteController(StarkitContext db, UserManager <User> userManager, IHostEnvironment environment, UploadService uploadService) { _db = db; _userManager = userManager; _environment = environment; _uploadService = uploadService; }
// The Watcher calls this method when a new file shows up in the watched folder. private async Task ProcessNewLocalFile(string fullPath, string name) { if (!userSession.IsLoggedIn) { StopMonitoring(); NotificationService.ShowBalloonError("Please log in and try again. Folder to Drive file deleted."); File.Delete(fullPath); return; } if (!File.Exists(fullPath)) { // Apparently there are times when more than one file-created event fires and the initial one happens // before the file is available; we're silently ignoring that situation return; } string fileId = await UploadService.UploadFile(fullPath, name, uploadDriveItemId); if (fileId == null) { NotificationService.ShowBalloonError("Folder to Drive upload failed: {0}", name); return; } // Only delete if file was successfully uploaded if (userSession.Settings.FolderToDriveDeleteFileAfterUpload) { File.Delete(fullPath); } }
public void TheVendorAPI_UploadSingleClaimBatch() { method = new StackTrace().GetFrame(0).GetMethod(); var results = UploadService.CallUploadService(new VendorPackage(client, Document.CreateDocument(claimNotFoundStatusBatch))); if (results.claimResults.Length == 0) { verificationErrors.Append("Vendor API Service Returned an Unexpected Result of Null or Empty"); Assert.Fail(); } try { Assert.AreEqual(true, results.noErrors); } catch (Exception) { verificationErrors.Append( "Expected VendorAPI Batch to Have No Errors Returned, But Error(s) were returned"); } try { Assert.AreEqual(ClaimDeletionStatus.ClaimNotFound, results.claimResults[0].ClaimDeletionStatus); } catch (Exception e) { verificationErrors.Append(e.Message); } var claimToDelete = results.claimResults[0].VendorClaimId; Helper.CleanUpVendorBatch(claimToDelete); endOfTest(); }
public async Task Test1() { var service = new UploadService("http://*****:*****@"Replays\UnsavedReplay-2018.10.17-20.22.26.replay"); Assert.Contains("success", content); }
public void TheVendorAPI_UploadClaimsWithoutRefD9Test() { method = new StackTrace().GetFrame(0).GetMethod(); var results = UploadService.CallUploadService(new VendorPackage(client, Document.CreateDocument(nonRefD9Batch))); if (results.thrownException == false) { verificationErrors.Append( "Uploaded Batch Excepted to Return Exceptions, but No Exception(s) Were Returned"); Assert.Fail(); } var exception = results.Exceptions[0]; bool matchExpectedExceptionMessage = Regex.IsMatch(exception.Message, "A Claim was sent without a Vendor Claim ID, No Claims Imported"); try { Assert.AreEqual(true, matchExpectedExceptionMessage); } catch (Exception e) { verificationErrors.Append( "Expected a Returned Error Message that Contained Correct Reason for Failed Uploaded, but Correct Message was Not Returned\n" + e.Message); } endOfTest(); }
public async Task <IActionResult> UploadImage(IFormFile imageFile, [FromForm] bool isNotifiableByEmail) { bool isUploaded = false; try { if (imageFile == null) { return(BadRequest("Nincs fogadott feltöltendő fájl")); } if (AccountKey == string.Empty || AccountName == string.Empty) { return(BadRequest("Nem tudjuk feloldani az Azure tárhelyed, csekkold hogy van megadva accountName és accountKey!")); } if (UploadService.IsImage(imageFile) && imageFile.Length > 0) { using (Stream stream = imageFile.OpenReadStream()) { isUploaded = await UploadService.UploadImageToPersonalBlobStorage(stream, DateTime.Now.ToString("yyMMddHHmmssffffff") + imageFile.FileName, AzureConnectionString, await GetCurrentUserIdAsync(), isNotifiableByEmail); } } else { return(new UnsupportedMediaTypeResult()); } return(new OkResult()); } catch (Exception ex) { return(BadRequest(ex.Message)); } }
public void TheVendorAPI_UploadVendorReImportedClaimsTest() { method = new StackTrace().GetFrame(0).GetMethod(); var results = UploadService.CallUploadService(new VendorPackage(client, Document.CreateDocument(SingleClaimNoErrors))); try { Assert.AreEqual(true, results.noErrors); } catch (Exception) { verificationErrors.Append("Expected Upload to throw No Exceptions but Exception(s) were Thrown"); } try { Assert.AreEqual(0, results.claimResults[0].Errors.Length); } catch (Exception) { verificationErrors.Append( "Expected 0 Errors Returned From Batch Upload, but Batch Upload Returned With " + results.claimResults[0].Errors.Length.ToString(CultureInfo.InvariantCulture) + " Errors"); } try { Assert.AreEqual(ClaimDeletionStatus.ClaimWasReimported, results.claimResults[0].ClaimDeletionStatus); } catch (Exception) { verificationErrors.Append("Unexpected ClaimDeletionStatus Value: Expected ClaimWasReimported but was " + results.claimResults[0].ClaimDeletionStatus.ToString()); } endOfTest(); }
// Use this for initialization public void Initialize() { //App42API.Initialize(KEY_API, KEY_SECRET); serviceAPI = new ServiceAPI(KEY_API, KEY_SECRET); uploadService = serviceAPI.BuildUploadService(); }
public async Task RightFileNull_Upload_ThrowException() { // Arrange const int id = 1; var data = new List <FileComparison>().AsQueryable(); var mockSet = await Task.Run(() => MockContextHelper.SetupMockSet(data)); var mockContext = await Task.Run(() => MockContextHelper.SetupMockContext(mockSet)); var uploadService = new UploadService(mockContext.Object); // Act var exceptionThrown = false; try { await uploadService.UploadRightAsync(id, null); } catch (ArgumentNullException) { exceptionThrown = true; } // Assert Assert.IsTrue(exceptionThrown, "ArgumentNullException was not thrown!"); }
static async Task Main(string[] args) { Server server = null; try { server = new Server() { Services = { GreetingService.BindService(new GreetingServiceImpl()), CalculatorService.BindService(new CalculatorServiceImpl()), CounterService.BindService(new CounterServiceImpl()), UploadService.BindService(new UploadServiceImpl()), ConversationService.BindService(new ConversationServiceImpl()) }, Ports = { new ServerPort("localhost", Port, ServerCredentials.Insecure) } }; server.Start(); Console.WriteLine($"The server is listening on the port : {Port}"); Console.ReadKey(); } catch (IOException ex) { Console.WriteLine($"The server failed to start : {ex.Message}"); throw; } finally { if (server != null) { await server.ShutdownAsync(); } } }
public override Task StartAsync(CancellationToken cancellationToken) { _logger.LogInformation($"Worker started at: {DateTime.Now}"); _settings = ReadJsonFile(); if (_settings.Username == null) { _logger.LogInformation("No username provided..."); throw new Exception("No username provided"); } _uploadService = new UploadService(_settings.Endpoint); _parseService = new ParseService(); _memCache = new MemoryCache(new MemoryCacheOptions()); _memCacheOptions = new MemoryCacheEntryOptions() .SetSlidingExpiration(TimeSpan.FromMilliseconds(CacheTimeMilliseconds)) .RegisterPostEvictionCallback(callback: OnRemovedFromCache, state: this); _watcher = new FileSystemWatcher(_settings.Path, _settings.FileExtension) { NotifyFilter = NotifyFilters.LastWrite }; _watcher.Changed += new FileSystemEventHandler(OnChanged); _watcher.EnableRaisingEvents = true; _logger.LogInformation("Started watching..."); return(base.StartAsync(cancellationToken)); }
public HomeController(PathProvider provider, IConfiguration config, UploadService upService, MailService mailService) { this.pathProvider = provider; this.Configuration = config; this.UpService = upService; this.MailService = mailService; }
public async Task <IActionResult> OnPostAsync(UploadInputModel model) { if (!ModelState.IsValid) { return(Page()); } var result = await UploadService.AddAnimation(new Application.Models.UploadModel() { Name = model.Name, Description = model.Description, Price = model.Price, File = await model.File.GetBytes(), UserId = IdentityService.GetUserId() ?? Guid.Empty }); if (result != null && result.Count > 0) { foreach (var error in result) { ModelState.AddModelError("", error); } } else { ShowSuccess = true; } return(Page()); }
public void Get_Upload_Data() { //Arrange var serviceProvider = new ServiceCollection() .AddLogging() .BuildServiceProvider(); var dbfactory = new ConnectionFactory(); var context = dbfactory.CreateContextForInMemory(); var factory = serviceProvider.GetService <ILoggerFactory>(); var logger = factory.CreateLogger <UploadService>(); UploadService _service = new UploadService(logger, context); var GUID = Guid.NewGuid().ToString(); var LocalFileName = "File Name_" + GUID + ".txt"; var FilePath = "App_Data/File Name_" + GUID + ".txt"; var upload = new Upload() { Guid = GUID, FileName = "File Name.txt", FileSize = 256, LocalFileName = LocalFileName, FilePath = FilePath, UploadDate = DateTime.Now }; //Act context.Uploads.Add(upload); context.SaveChanges(); List <Upload> uploads = _service.GetUploads(); //Assert Assert.IsTrue(uploads.Count > 0); }
/// <summary> /// Initializes a new instance of the <see cref="TodoistClient" /> class. /// </summary> /// <param name="token">The token.</param> /// <param name="restClient">The rest client.</param> /// <exception cref="System.ArgumentException">Value cannot be null or empty - token</exception> public TodoistClient(string token, ITodoistRestClient restClient) { if (string.IsNullOrEmpty(token)) { throw new ArgumentException("Value cannot be null or empty.", nameof(token)); } _token = token; _restClient = restClient; Projects = new ProjectsService(this); Templates = new TemplateService(this); Items = new ItemsService(this); Labels = new LabelsService(this); Notes = new NotesService(this); Uploads = new UploadService(this); Filters = new FiltersService(this); Activity = new ActivityService(this); Notifications = new NotificationsService(this); Backups = new BackupService(this); Reminders = new RemindersService(this); Users = new UsersService(this); Sharing = new SharingService(this); Emails = new EmailService(this); Sections = new SectionService(this); }
public void TheVendorAPI_CallUploadMultipleClaimsSomeWithoutRefD9Test() { method = new StackTrace().GetFrame(0).GetMethod(); package = new VendorPackage(client, Document.CreateDocument(halfRefBatch)); var results = UploadService.CallUploadService(package); try { Assert.AreEqual(true, results.thrownException); } catch (Exception) { verificationErrors.Append("Expected Exception To Be Thrown But No Exception Was Thrown"); } bool isMatch = Regex.IsMatch(results.Exceptions[0].Message, "Missing Vendor Claim Id: A Claim was sent without a Vendor Claim ID, No Claims Imported"); try { Assert.AreEqual(true, isMatch); } catch (Exception) { verificationErrors.Append( "Unexpected Exception Thrown From Upload Service, Expected Error, \"A Claim was sent without a Vendor Claim ID\""); } endOfTest(); }
public ApuntesController(EstudianteService estudianteService, UploadService uploadService, IHostingEnvironment environment) { this.estudianteService = estudianteService; this.uploadService = uploadService; this.Environment = environment; }
public ActionResult SaveGoodsImage() { var hash = new Hashtable(); if (Request.Files.Count == 0 || Request.Files[0] == null || Request.Files[0].ContentLength == 0) { hash["error"] = 1; hash["message"] = "上传的图片不能为空"; return(Json(hash, JsonRequestBehavior.AllowGet)); } string errMsg, savePath; if (!UploadService.UploadGoodsImage(Request.Files[0], out errMsg, out savePath)) { hash["error"] = 1; hash["message"] = errMsg; return(Json(hash, JsonRequestBehavior.AllowGet)); } else { hash["error"] = 0; hash["url"] = savePath; return(Json(hash, JsonRequestBehavior.AllowGet)); } }
public void TheVendorAPI_UploadLargeBatchTest() { method = new StackTrace().GetFrame(0).GetMethod(); package = new VendorPackage(client, Document.CreateDocument(hundredTwoClaimsBatch)); var results = UploadService.CallUploadService(package); try { Assert.AreEqual(true, results.thrownException); } catch (Exception) { verificationErrors.Append( "Expected 100 claim batch to throw exceptions, but no exception(s) were thrown"); } try { Assert.AreEqual("Max claims exceeded. Cannot accept more than 20 claims.", results.Exceptions[0].Message); } catch (VerificationException e) { verificationErrors.Append(e); } endOfTest(); }
private void SendContactInternal(TLMessageBase messageBase) { var message = messageBase as TLMessage34; if (message == null) { return; } var mediaContact = message.Media as TLMessageMediaContact; if (mediaContact == null) { return; } var inputMediaContact = new TLInputMediaContact82 { FirstName = mediaContact.FirstName, LastName = mediaContact.LastName, PhoneNumber = mediaContact.PhoneNumber, VCard = TLString.Empty }; message.InputMedia = inputMediaContact; UploadService.SendMediaInternal(message, MTProtoService, StateService, CacheService); }
public SourceManageController(GuideContext db, UserManager <User> userManager, IWebHostEnvironment environment, UploadService uploadService) { _db = db; _userManager = userManager; _environment = environment; _uploadService = uploadService; }
private void SendLocationInternal(TLMessageBase messageBase) { var message = messageBase as TLMessage34; if (message == null) { return; } var mediaGeo = message.Media as TLMessageMediaGeo; if (mediaGeo == null) { return; } var geoPoint = mediaGeo.Geo as TLGeoPoint; if (geoPoint == null) { return; } var inputMediaGeoPoint = new TLInputMediaGeoPoint { GeoPoint = new TLInputGeoPoint { Lat = geoPoint.Lat, Long = geoPoint.Long } }; message.InputMedia = inputMediaGeoPoint; UploadService.SendMediaInternal(message, MTProtoService, StateService, CacheService); }
public ActionResult UploadFiles() { foreach (string file in Request.Files) { var statuses = new BlueimpJsonResult(); statuses.files = new List <FileMetadata>(); var headers = Request.Headers; for (int i = 0; i < Request.Files.Count; i++) { var f = Request.Files[i]; f.SaveAs(Server.MapPath("~/UploadFiles/") + f.FileName); var uservice = new UploadService(); uservice.Create(f); statuses.files.Add(new FileMetadata() { name = f.FileName, size = f.ContentLength, url = "/UploadFiles/" + f.FileName, deleteUrl = "/Upload/DeleteFile?name=" + f.FileName, deleteType = "GET", thumbnailUrl = "null" }); } JsonResult result = Json(statuses); result.ContentType = "text/plain"; return(result); } return(Json(new List <FileMetadata>())); }
public HomeController(ILogger <HomeController> logger, UploadService upload, PostService postService, PersonService personService) { this.logger = logger; this.uploadService = upload; this.postService = postService; this.personService = personService; }
public void UploadAndDeleteTest() { //Arrange setUp(); var f = MockRepository.GenerateStub <HttpPostedFileBase>(); f.Stub(x => x.FileName).Return("foo.bar"); f.Stub(x => x.ContentLength).Return(100); //Act var u = new UploadService(); u.Create(f); //Assert var Repository = new DocuRepository(MockContext); Assert.AreEqual(Repository.GetDocuments(), 2); Assert.AreEqual(Repository.GetDocumentByName("foo.bar"), 1); Assert.AreEqual(Repository.GetDocumentByName("foo.bar").FileSize, 100); u.Delete("fileName/bar.foo"); Assert.AreEqual(Repository.GetDocuments(), 1); Assert.AreEqual(Repository.GetDocumentByName("bar.foo"), 0); }
// Constructor public MainPage() { InitializeComponent(); photoChooserTask = new PhotoChooserTask(); photoChooserTask.Completed += new EventHandler<PhotoResult>(photoChooserTask_Completed); uploadservice = serviceApi.BuildUploadService(); userService = serviceApi.BuildUserService(); }
public PublicationsController(MyInstagramContext db, IHostEnvironment environment, UploadService uploadService, UserService userService) { _db = db; _environment = environment; _uploadService = uploadService; _userService = userService; }
//Pre: N/A //Post: OnlineStorage class is initialized //Description: This method initializes the online storage class. public static void Initialize() { App42API.Initialize(KEY_API, KEY_SECRET); ServiceAPI api = new ServiceAPI(KEY_API, KEY_SECRET); uploadService = api.BuildUploadService(); }
public DishesController(StarkitContext db, IHostEnvironment environment, UploadService uploadService, UserManager <User> userManager) { _db = db; _environment = environment; _uploadService = uploadService; _userManager = userManager; }
/// <summary> /// SCORM Engine Service constructor that takes a single configuration parameter /// </summary> /// <param name="config">The Configuration object to be used to configure the Scorm Engine Service client</param> public ScormEngineService(Configuration config) { System.Net.ServicePointManager.Expect100Continue = false; configuration = config; courseService = new CourseService(configuration, this); dispatchService = new DispatchService(configuration, this); registrationService = new RegistrationService(configuration, this); invitationService = new InvitationService(configuration, this); uploadService = new UploadService(configuration, this); ftpService = new FtpService(configuration, this); exportService = new ExportService(configuration, this); reportingService = new ReportingService(configuration, this); debugService = new DebugService(configuration, this); }
public ServicesPage() { App42API.Initialize(Constants.apiKey,Constants.secretKey ); App42Log.SetDebug(true); InitializeComponent(); userService = App42API.BuildUserService(); storageService = App42API.BuildStorageService(); gameService = App42API.BuildGameService(); scoreBoardService = App42API.BuildScoreBoardService(); uploadService = App42API.BuildUploadService(); photoChooserTask = new PhotoChooserTask(); photoChooserTask.Completed += new EventHandler<PhotoResult>(photoChooserTask_Completed); photoChooserTask2 = new PhotoChooserTask(); photoChooserTask2.Completed += new EventHandler<PhotoResult>(photoChooserTask2_Completed); }
void fs_DownloadCompleted(object sender, UploadService.DownloadCompletedEventArgs e) { if (e.Error == null) { if (e.Result != null) { UploadService.PictureFile imageDownload = e.Result; stream = new MemoryStream(imageDownload.PictureStream); stream.WriteTo(outStream); outStream.Flush(); outStream.Close(); imageDownload.PictureStream = null; //stream.Close(); MessageBox.Show("Đã lưu file hướng dẫn !"); } else { MessageBox.Show("File help không tồn tại !"); } } }
void OnGUI() { GUILayout.BeginVertical(); GUILayout.Label(uploadedImage,GUILayout.Height(317),GUILayout.Width(150)); //======================================Loading_Message========================================== GUILayout.Label(loadingMessage2); //======================================Loading_Message========================================== //======================================File_Browser_Content========================================== if (m_fileBrowser != null) { GUI.skin = gameSkin; m_fileBrowser.OnGUI(); GUI.skin = null; } else { OnGUIMain(); } //======================================File_Browser_Content========================================== GUILayout.Label(path ?? "None selected"); GUILayout.BeginHorizontal(); //======================================UploadFile========================================== if (showAllFilesBtn == true && showUploadBtn == true && showBtn == true && GUILayout.Button("Upload File" , GUILayout.Width(150), GUILayout.Height(30))) { showUploadBtn = false; showBtn = false; Debug.Log("PATH IS ::: " + path); loadingMessage2 = "Please Wait..."; if(path ==null || path.Equals("")) { loadingMessage2 = "Please Select A File"; } fileName = "testFile11"+DateTime.Now.Millisecond; uploadService = sp.BuildUploadService(); // Initializing Upload Service. uploadService.UploadFile(fileName, path, "IMAGE", "Description", callBack); //Using App42 Unity UploadService. } //================================================================================ GUILayout.EndVertical(); GUILayout.Space(40); GUILayout.BeginArea(new Rect(155,5,200,371)); GUILayout.BeginVertical(); //========Setting Up ScrollView==================================================== scrollPosition = GUILayout.BeginScrollView(scrollPosition, GUILayout.Width(155)); if(listOfImages.Count > 1) { for(int i=0; i<listOfImages.Count; i++) { Texture2D myImage = (Texture2D)listOfImages[i]; GUILayout.Label(myImage,GUILayout.Height(100),GUILayout.Width(100)); } loadingMessage = ""; } GUILayout.EndScrollView(); //========ScrollView=============================================================== //======================================Loading_Message========================================== GUILayout.Label(loadingMessage); //======================================Loading_Message========================================== //======================================GetAllFiles=============================== if (showAllFilesBtn == true && GUILayout.Button("Get All Files" , GUILayout.Width(150), GUILayout.Height(30))) { loadingMessage = "Loading..."; uploadService = sp.BuildUploadService(); // Initializing Upload Service. uploadService.GetAllFiles(allFilesCallBack); } //================================================================================ GUILayout.EndHorizontal(); GUILayout.EndVertical(); GUILayout.EndArea(); }
//=============================GUI_CONTENT=========================================== // Use this for initialization void Start() { App42API.Initialize("APP_API_KEY","APP_SECRET_KEY"); uploadService = App42API.BuildUploadService(); // Initializing Upload Service. }
void fs_GetDateTimeCompleted(object sender, UploadService.GetDateTimeCompletedEventArgs e) { if (e.Error == null) { if (e.Result != null) { App.Current_d = e.Result; //if (App.Current_d.Day == 1 || App.Current_d.Day == 2 || Convert.ToInt16(App.Current_d.DayOfWeek)==1) // App.m_ngaymin = 2; //else // App.m_ngaymin = 1; App.Min_Date = App.Current_d.AddDays(-2); App.Min_Date = App.Min_Date.AddHours(-App.Min_Date.Hour); App.Min_Date = App.Min_Date.AddMinutes(-App.Min_Date.Minute); App.Min_Date = App.Min_Date.AddSeconds(-App.Min_Date.Second); } else { MessageBox.Show("Không lấy được thời gian trên server !"); } } }
void client_GetSessionTimeOutCompleted(object sender, UploadService.GetSessionTimeOutCompletedEventArgs e) { int result = e.Result; // MessageBox.Show("232"); }
//=============================GUI_CONTENT=========================================== // Use this for initialization void Start() { sp = new ServiceAPI("YOUR_API_KEY","YOUR_SECRET_KEY"); uploadService = sp.BuildUploadService(); // Initializing Upload Service. }
protected override void OnNavigatedTo(NavigationEventArgs e) { System.Diagnostics.Debug.WriteLine("On navigated to loading"); timeout = 0; MediaElementData[0] = t1; MediaElementData[1] = t2; Global.MyAudio[0] = App.GlobalMediaElement0; Global.MyAudio[1] = App.GlobalMediaElement1; Global.MyAudio[2] = App.GlobalMediaElement2; Global.MyAudio[3] = App.GlobalMediaElement3; Global.MyAudio[4] = App.GlobalMediaElement4; Global.opponentUsername = ""; Deployment.Current.Dispatcher.BeginInvoke(() => { ready.Text = Global.localUsername + " \nvs\n"; }); _dispatcherTimer = new DispatcherTimer { Interval = TimeSpan.FromSeconds(1) }; _dispatcherTimer.Tick += UpdateMediaData; _dispatcherTimer.Start(); i = 0; k = 0; B(false); requestCallback = this; App42API.Initialize(Constants.API_KEY, Constants.SECRET_KEY); App42Log.SetDebug(true); ServiceAPI api = new ServiceAPI(Constants.API_KEY, Constants.SECRET_KEY); storage = api.BuildStorageService(); uploadService = api.BuildUploadService(); System.Diagnostics.Debug.WriteLine("Before warp"); WarpClient.initialize(Constants.API_KEY, Constants.SECRET_KEY); WarpClient.setRecoveryAllowance(60); Global.warpClient = WarpClient.GetInstance(); //trivia if ((int)settings["trigger"] == 0) TriviaTB.Text = Global.TriviaB[(new Random()).Next(Global.TriviaB.Length)]; else TriviaTB.Text = Global.TriviaH[(new Random()).Next(Global.TriviaH.Length)]; Global.disconnectSuccess = false; Global.deleteSuccess = false; Global.conListenObj = new ConnectionListener(this); Global.roomReqListenerObj = new RoomReqListener(this); Global.zoneReqListenerObj = new ZoneRequestListener(this); Global.notificationListenerObj = new NotificationListener(this); Global.warpClient.AddConnectionRequestListener(Global.conListenObj); Global.warpClient.AddRoomRequestListener(Global.roomReqListenerObj); Global.warpClient.AddNotificationListener(Global.notificationListenerObj); Global.warpClient.AddZoneRequestListener(Global.zoneReqListenerObj); Global.warpClient.Connect(Global.localUsername); System.Diagnostics.Debug.WriteLine("after warp"); }