private static IRelativityContext VerifyContext(IRelativityContext context) { if (context.WorkspaceId <= 0) { throw new ArgumentException("Context does not contain a valid WorkspaceId"); } return(context); }
public RsapiClientFactory(IHelper helper, IRelativityContext context, ExecutionIdentity defaultExecutionIdentity) : base(helper, defaultExecutionIdentity) { this.context = context; }
public RsapiClientFactory(IHelper helper, IRelativityContext context) : base(helper) { this.context = context; }
/// <summary> /// Initializes a new instance of the <see cref="RelativityConnectionFactoryBase"/> class. /// </summary> /// <param name="helper">The Relativity helper for the instance.</param> /// <param name="context">The workspace wanted.</param> protected RelativityConnectionFactoryBase(IHelper helper, IRelativityContext context) { this.helper = helper; this.context = context; }
/// <summary> /// Initializes a new instance of the <see cref="RelativityWorkspaceConnectionFactory"/> class. /// </summary> /// <param name="helper">The Relativity helper for the instance.</param> /// <param name="context">The workspace wanted.</param> public RelativityWorkspaceConnectionFactory(IHelper helper, IRelativityContext context) : base(helper, VerifyContext(context)) { }
/// <summary> /// Initializes a new instance of the <see cref="RelativityInstanceConnectionFactory"/> class. /// </summary> /// <param name="helper">The Relativity helper for the instance.</param> /// <param name="context">The workspace wanted.</param> public RelativityInstanceConnectionFactory(RelativityAPI.IHelper helper, IRelativityContext context) : base(helper, context.GetInstanceContext()) { }