/// <summary> /// Initializes a new instance of the <see cref="CatalystPreparedStatement"/> class. /// </summary> /// <param name="adapter">The adapter.</param> /// <param name="instanceId">The instance id.</param> /// <param name="id">The id.</param> public CatalystPreparedStatement(Catalyst adapter, string instanceId, string id) { Adapter = adapter; Instance = adapter.GetInstance(instanceId); InstanceId = instanceId; Id = id; }
/// <summary> /// Initializes a new instance of the <see cref="CatalystAdministrator"/> class. /// </summary> /// <param name="adapter">The catalyst adapter.</param> /// <param name="instanceId">The instance id.</param> public CatalystAdministrator(Catalyst adapter, string instanceId) { _adapter = adapter; _statementTable = new Dictionary <string, WeakReference <CatalystStatement> >(); _webChannelFactory = adapter.WebChannelFactory; _instanceId = instanceId; }
/// <summary> /// Initializes a new instance of the <see cref="CatalystRuntime"/> class. /// </summary> /// <param name="adapter">The catalyst adapter.</param> /// <param name="administrator">The administrator.</param> /// <param name="instanceDescriptor">The instance descriptor.</param> public CatalystRuntime(Catalyst adapter, CatalystAdministrator administrator, InstanceDescriptor instanceDescriptor) { _adapter = adapter; _administrator = administrator; _webChannelFactory = adapter.WebChannelFactory; _instanceDescriptor = instanceDescriptor; _dataPublisher = instanceDescriptor.DataPublicationEndpoints .Where(endpoint => endpoint != null) .Select(endpoint => adapter.DataPublisherFactory.CreatePublisher(endpoint)) .FirstOrDefault(publisherFactory => publisherFactory != null); }
/// <summary> /// Initializes a new instance of the <see cref="CatalystInstance"/> class. /// </summary> /// <param name="adapter">The catalyst adapter.</param> /// <param name="instanceDescriptor">The instance descriptor.</param> internal CatalystInstance(Catalyst adapter, InstanceDescriptor instanceDescriptor) { Adapter = adapter; Administrator = new CatalystAdministrator(adapter, instanceDescriptor.Id); Runtime = new CatalystRuntime(adapter, (CatalystAdministrator)Administrator, instanceDescriptor); }
/// <summary> /// Initializes a new instance of the <see cref="CatalystStatement"/> class. /// </summary> /// <param name="adapter"></param> /// <param name="statementDescriptor">The statement descriptor.</param> /// <param name="userObject">The user object.</param> public CatalystStatement(Catalyst adapter, StatementDescriptor statementDescriptor, object userObject) { Adapter = adapter; StatementDescriptor = statementDescriptor; UserObject = userObject; }
/// <summary> /// Initializes a new instance of the <see cref="CatalystStatement"/> class. /// </summary> /// <param name="adapter"></param> /// <param name="statementDescriptor">The statement descriptor.</param> public CatalystStatement(Catalyst adapter, StatementDescriptor statementDescriptor) { Adapter = adapter; StatementDescriptor = statementDescriptor; }