/// <summary> /// Creates <see cref="Credentials"/> based on a Google login. /// </summary> /// <param name="googleToken">A Google authentication token, obtained by logging into Google.</param> /// <returns>An instance of <see cref="Credentials"/> that can be used in <see cref="User.LoginAsync"/></returns> public static Credentials Google(string googleToken) { RealmPCLHelpers.ThrowProxyShouldNeverBeUsed(); return(null); }
/// <summary> /// Creates <see cref="Credentials"/> based on a login with a username and a password. /// </summary> /// <param name="username">The username of the user.</param> /// <param name="password">The user's password.</param> /// <param name="createUser"><c>true</c> if the user should be created, <c>false</c> otherwise. It is not possible to create a user twice when logging in, so this flag should only be set to true the first time a user logs in.</param> /// <returns>An instance of <see cref="Credentials"/> that can be used in <see cref="User.LoginAsync"/></returns> public static Credentials UsernamePassword(string username, string password, bool createUser) { RealmPCLHelpers.ThrowProxyShouldNeverBeUsed(); return(null); }
/// <summary> /// Creates an instance of <see cref="Credentials"/> to be used during development. Not enabled for Realm Object Server configured for production. /// </summary> /// <returns>An instance of <see cref="Credentials"/> that can be used in <see cref="User.LoginAsync"/></returns> public static Credentials Debug() { RealmPCLHelpers.ThrowProxyShouldNeverBeUsed(); return(null); }
/// <summary> /// Creates <see cref="Credentials"/> based on a Facebook login. /// </summary> /// <param name="facebookToken">A Facebook authentication token, obtained by logging into Facebook.</param> /// <returns>An instance of <see cref="Credentials"/> that can be used in <see cref="User.LoginAsync"/></returns> public static Credentials Facebook(string facebookToken) { RealmPCLHelpers.ThrowProxyShouldNeverBeUsed(); return(null); }
/// <summary> /// Creates an instance of <see cref="Credentials"/> with a custom provider and user identifier. /// </summary> /// <param name="identityProvider">Provider used to verify the credentials.</param> /// <param name="userIdentifier">String identifying the user. Usually a username of id.</param> /// <param name="userInfo">Data describing the user further or null if the user does not have any extra data. The data will be serialized to JSON, so all values must be mappable to a valid JSON data type.</param> /// <returns>An instance of <see cref="Credentials"/> that can be used in <see cref="User.LoginAsync"/></returns> public static Credentials Custom(string identityProvider, string userIdentifier, IDictionary <string, object> userInfo) { RealmPCLHelpers.ThrowProxyShouldNeverBeUsed(); return(null); }
/// <summary> /// Simulates a progress update. /// </summary> /// <param name="session">Session which will report progress.</param> /// <param name="downloadedBytes">Downloaded bytes.</param> /// <param name="downloadableBytes">Downloadable bytes.</param> /// <param name="uploadedBytes">Uploaded bytes.</param> /// <param name="uploadableBytes">Uploadable bytes.</param> /// <remarks> /// Use this method to test your progress handling code without connecting to a Realm Object Server. /// Some throttling may occur at a native level, so it is recommended to use <c>Task.Delay()</c> between invocations. /// </remarks> public static void SimulateProgress(this Session session, ulong downloadedBytes, ulong downloadableBytes, ulong uploadedBytes, ulong uploadableBytes) { RealmPCLHelpers.ThrowProxyShouldNeverBeUsed(); }
/// <summary> /// Simulates a session error. /// </summary> /// <param name="session">The session where the simulated error will occur.</param> /// <param name="errorCode">Error code.</param> /// <param name="message">Error message.</param> /// <param name="isFatal">If set to <c>true</c> the error will be marked as fatal.</param> /// <remarks> /// Use this method to test your error handling code without connecting to a Realm Object Server. /// Some error codes, such as <see cref="ErrorCode.OtherSessionError"/> will be ignored and will not be reported /// to <see cref="Session.Error"/> subscribers. /// </remarks> public static void SimulateError(this Session session, ErrorCode errorCode, string message, bool isFatal = false) { RealmPCLHelpers.ThrowProxyShouldNeverBeUsed(); }
/// <summary> /// Gets an <see cref="IObservable{T}"/> that can be used to track upload or download progress. /// </summary> /// <remarks> /// To start receiving notifications, you should call <see cref="IObservable{T}.Subscribe"/> on the returned object. /// The token returned from <see cref="IObservable{T}.Subscribe"/> should be retained as long as progress /// notifications are desired. To stop receiving notifications, call <see cref="IDisposable.Dispose"/> /// on the token. /// You don't need to keep a reference to the observable itself. /// The progress callback will always be called once immediately upon subscribing in order to provide /// the latest available status information. /// </remarks> /// <returns>An observable that you can subscribe to and receive progress updates.</returns> /// <param name="direction">The transfer direction (upload or download) to track in the subscription callback.</param> /// <param name="mode">The desired behavior of this progress notification block.</param> /// <example> /// <code> /// class ProgressNotifyingViewModel /// { /// private IDisposable notificationToken; /// /// public void ShowProgress() /// { /// var observable = session.GetProgressObservable(ProgressDirection.Upload, ProgressMode.ReportIndefinitely); /// notificationToken = observable.Subscribe(progress => /// { /// // Update relevant properties by accessing /// // progress.TransferredBytes and progress.TransferableBytes /// }); /// } /// /// public void HideProgress() /// { /// notificationToken?.Dispose(); /// notificationToken = null; /// } /// } /// </code> /// In this example we're using <see href="https://msdn.microsoft.com/en-us/library/ff402849(v=vs.103).aspx">ObservableExtensions.Subscribe</see> /// found in the <see href="https://github.com/Reactive-Extensions/Rx.NET">Reactive Extensions</see> class library. /// If you prefer not to take a dependency on it, you can create a class that implements <see cref="IObserver{T}"/> /// and use it to subscribe instead. /// </example> public IObservable <SyncProgress> GetProgressObservable(ProgressDirection direction, ProgressMode mode) { RealmPCLHelpers.ThrowProxyShouldNeverBeUsed(); return(null); }
public SyncConfiguration(User user, Uri serverUri) { RealmPCLHelpers.ThrowProxyShouldNeverBeUsed(); }