public MEGAApi(byte[] loginData) { if (loginData == null || loginData.Length == 0) { throw new System.IO.InvalidDataException("loginData can not be empty"); } user = MegaApi.Mega.LoadAccount(loginData); Init(); }
public MEGAApi(string UserEmail, string UserPassword) { if (String.IsNullOrEmpty(UserEmail) || String.IsNullOrEmpty(UserPassword)) { throw new System.IO.InvalidDataException("UserEmail and UserPassword can not be empty"); } else { user = new MegaApi.MegaUser(UserEmail, UserPassword); } Init(); }