internal static DataSyncException AnotherSyncInProgressError(string source, string helpLink) { DataSyncException dataSyncException = new DataSyncException(SyncResource.GetString("SyncAlreadyStarted"), (Exception)null); dataSyncException.SyncSource = source; dataSyncException.HelpLink = helpLink; dataSyncException.SyncStage = SyncStage.ReadingMetadata; dataSyncException.ErrorNumber = SyncErrorNumber.SyncInProgress; SyncTracer.Warning("{0}", new object[1] { (object)dataSyncException }); return(dataSyncException); }
internal static DataSyncException EnumeratingChangesError(string source, string helpLink, Exception inner, SyncStage stage) { DataSyncException dataSyncException = new DataSyncException(SyncResource.GetString("ClientSyncProvider_GetChanges_Failed"), inner); dataSyncException.SyncSource = source; dataSyncException.SyncStage = stage; dataSyncException.ErrorNumber = SyncErrorNumber.StoreException; dataSyncException.HelpLink = helpLink; SyncTracer.Warning("{0}", new object[1] { (object)dataSyncException }); return(dataSyncException); }
internal static SchemaException MissingSelectStatementError(string tableName, string source, string helpLink) { SchemaException schemaException = new SchemaException(SyncResource.GetString("SyncAdapter_FillSchema_SelectCommandMissing")); schemaException.SyncSource = source; schemaException.SyncStage = SyncStage.ReadingSchema; schemaException.ErrorNumber = SyncErrorNumber.MissingSelectCommand; schemaException.TableName = tableName; schemaException.HelpLink = helpLink; SyncTracer.Warning("{0}", new object[1] { (object)schemaException }); return(schemaException); }
internal static SchemaException InvalidSchemaDataSetError(string tableName, string source, string helpLink) { SchemaException schemaException = new SchemaException(SyncResource.GetString("ServerSyncProvider_Invalid_Schema_dataset")); schemaException.SyncSource = source; schemaException.SyncStage = SyncStage.ReadingSchema; schemaException.ErrorNumber = SyncErrorNumber.InvalidSchemaDataSet; schemaException.TableName = tableName; schemaException.HelpLink = helpLink; SyncTracer.Warning("{0}", new object[1] { (object)schemaException }); return(schemaException); }
internal static AnchorException ReadingAnchorError(SyncGroupMetadata metadata, SyncSession session, string source, string helpLink, Exception inner) { AnchorException anchorException = new AnchorException(SyncResource.GetString("GetNewServerAnchorFailed"), inner); anchorException.SyncSource = source; anchorException.SyncStage = SyncStage.DownloadingChanges; anchorException.ErrorNumber = SyncErrorNumber.StoreException; anchorException.GroupMetadata = metadata; anchorException.HelpLink = helpLink; anchorException.Session = session; SyncTracer.Warning("{0}", new object[1] { (object)anchorException }); return(anchorException); }
internal static string FormatString(string key, params object[] a1) { return(string.Format((IFormatProvider)CultureInfo.InvariantCulture, SyncResource.GetString(key), a1)); }
internal static ArgumentException MaxSizeOfCustomParameter() { return(SyncExpt.Argument(SyncResource.GetString("MaxSizeOfCustomParameter"))); }
internal static ArgumentException InvalidConnectionArgument() { return(SyncExpt.Argument(SyncResource.GetString("InvalidConnectionArgument"))); }
internal static InvalidOperationException DynamicSQLNoTableInfo() { InvalidOperationException operationException = new InvalidOperationException(SyncResource.GetString("DynamicSQLNoTableInfo")); SyncTracer.Warning("{0}", new object[1] { (object)operationException }); return(operationException); }
internal static SessionVariableException FailedToMapOriginatorId(SyncStage stage, string source, string helpLink) { SessionVariableException variableException = new SessionVariableException(SyncResource.GetString("FailedToMapOriginatorId")); variableException.ErrorNumber = SyncErrorNumber.MissingSessionVariable; variableException.SyncSource = source; variableException.HelpLink = helpLink; variableException.SyncStage = stage; SyncTracer.Warning("{0}", new object[1] { (object)variableException }); return(variableException); }
internal static InvalidOperationException NoTableNameError() { InvalidOperationException operationException = new InvalidOperationException(SyncResource.GetString("NoTableName")); SyncTracer.Warning("{0}", new object[1] { (object)operationException }); return(operationException); }
internal static Exception InvalidSyncParameterObject() { return((Exception)SyncExpt.Argument(SyncResource.GetString("InvalidParamObject"))); }
internal static Exception InvalidSyncAdapterObject() { return((Exception)SyncExpt.Argument(SyncResource.GetString("SyncAdapterCollection_Add_InvalidType"))); }
internal static Exception InvalidSyncGroupName() { return((Exception)SyncExpt.Argument(SyncResource.GetString("InvalidGroupName"), "GroupName")); }