예제 #1
0
        public IPropertyType Clone([NotNull] IPropertyTypesContainer container)
        {
            IPropertyType result = null;

            if (container is IPropertySchema schema)
            {
                result = new IdentityReferencePropertyType
                {
                    _id         = _id,
                    _schemaId   = schema.Id,
                    Name        = Name,
                    Description = Description,
                    Visible     = Visible,
                    Priority    = Priority
                };
                container.Add(result);
            }
            return(result);
        }
예제 #2
0
        public IPropertyType Clone([NotNull] IPropertyTypesContainer container)
        {
            IPropertyType result = null;

            if (container is IPropertySchema schema)
            {
                result = new IdentityReferencePropertyType
                {
                    _id                  = _id,
                    _schemaId            = schema.Id,
                    _model               = schema.Model,
                    _modelId             = schema.Model?.Id ?? Guid.Empty,
                    Name                 = Name,
                    Description          = Description,
                    Visible              = Visible,
                    DoNotPrint           = DoNotPrint,
                    CustomPropertyViewer = CustomPropertyViewer,
                    Priority             = Priority
                };
                container.Add(result);
            }
            return(result);
        }