Beispiel #1
0
 public BindableObjectClassWithIdentity(
     Type concreteType,
     BindableObjectProvider businessObjectProvider,
     BindableObjectGlobalizationService bindableObjectGlobalizationService,
     IEnumerable <PropertyBase> properties)
     : base(concreteType, businessObjectProvider, bindableObjectGlobalizationService, properties)
 {
     _getObjectServiceType = GetGetObjectServiceType();
 }
Beispiel #2
0
        public ClassReflector(
            Type targetType,
            BindableObjectProvider businessObjectProvider,
            IMetadataFactory metadataFactory,
            BindableObjectGlobalizationService bindableObjectGlobalizationService)
        {
            ArgumentUtility.CheckNotNull("targetType", targetType);
            ArgumentUtility.CheckNotNull("businessObjectProvider", businessObjectProvider);
            ArgumentUtility.CheckNotNull("metadataFactory", metadataFactory);
            ArgumentUtility.CheckNotNull("bindableObjectGlobalizationService", bindableObjectGlobalizationService);

            _targetType                         = targetType;
            _concreteType                       = BindableObjectProvider.GetConcreteTypeForBindableObjectImplementation(_targetType);
            _businessObjectProvider             = businessObjectProvider;
            _metadataFactory                    = metadataFactory;
            _bindableObjectGlobalizationService = bindableObjectGlobalizationService;
        }
Beispiel #3
0
        public BindableObjectClass(
            Type concreteType,
            BindableObjectProvider businessObjectProvider,
            BindableObjectGlobalizationService bindableObjectGlobalizationService,
            IEnumerable <PropertyBase> properties)
        {
            ArgumentUtility.CheckNotNull("concreteType", concreteType);
            Assertion.IsFalse(concreteType.IsValueType, "mixed types cannot be value types");
            ArgumentUtility.CheckNotNull("businessObjectProvider", businessObjectProvider);
            ArgumentUtility.CheckNotNull("bindableObjectGlobalizationService", bindableObjectGlobalizationService);
            ArgumentUtility.CheckNotNull("properties", properties);

            _targetType                         = MixinTypeUtility.GetUnderlyingTargetType(concreteType);
            _concreteType                       = concreteType;
            _businessObjectProvider             = businessObjectProvider;
            _businessObjectProviderAttribute    = AttributeUtility.GetCustomAttribute <BusinessObjectProviderAttribute> (concreteType, true);
            _properties                         = new PropertyCollection(properties);
            _bindableObjectGlobalizationService = bindableObjectGlobalizationService;

            foreach (PropertyBase property in _properties.ToArray())
            {
                property.SetReflectedClass(this);
            }
        }
Beispiel #4
0
        public BindableObjectMetadataFactory(BindableObjectGlobalizationService bindableObjectGlobalizationService)
        {
            ArgumentUtility.CheckNotNull("bindableObjectGlobalizationService", bindableObjectGlobalizationService);

            _bindableObjectGlobalizationService = bindableObjectGlobalizationService;
        }