/// <summary> /// Initializes a new instance of the <see cref="StoredFeature" /> class. /// </summary> /// <param name="driver">The driver.</param> /// <param name="identifier">The identifier.</param> /// <exception cref="System.ArgumentNullException"> /// The driver is null. /// or /// The identifier is null. /// </exception> public StoredFeature(IFeatureDriver driver, String identifier) { if (driver == null) { throw new ArgumentNullException(nameof(driver)); } this.Factory = new StoredFeatureFactory(driver); this.Identifier = identifier ?? throw new ArgumentNullException(nameof(identifier)); }
/// <summary> /// Initializes a new instance of the <see cref="StoredFeatureFactory" /> class. /// </summary> /// <param name="driver">The driver.</param> /// <exception cref="System.ArgumentNullException">The driver is null.</exception> public StoredFeatureFactory(IFeatureDriver driver) { this.Driver = driver ?? throw new ArgumentNullException(nameof(driver)); StoredAttributeCollectionFactory attributeFactory = new StoredAttributeCollectionFactory(driver.AttributeDriver); StoredGeometryFactory geometryFactory = new StoredGeometryFactory(driver.GeometryDriver); this.EnsureFactory <IAttributeCollectionFactory>(attributeFactory); this.EnsureFactory <IStoredAttributeCollectionFactory>(attributeFactory); this.EnsureFactory <IGeometryFactory>(geometryFactory); this.EnsureFactory <IStoredGeometryFactory>(geometryFactory); }