Пример #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="SerializableEntity"/> class.
 /// </summary>
 public SerializableEntity()
 {
     Attributes      = new SerializableAttributeCollection();
     FormattedValues = new SerializableFormattedValueCollection();
     RelatedEntities = new SerializableRelatedEntityCollection();
     KeyAttributes   = new SerializableKeyAttributeCollection();
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="SerializableEntityReference"/> class.
 /// </summary>
 /// <param name="entityReference">The entity reference.</param>
 public SerializableEntityReference(EntityReference entityReference)
 {
     Id            = entityReference.Id;
     LogicalName   = entityReference.LogicalName;
     Name          = entityReference.Name;
     KeyAttributes = new SerializableKeyAttributeCollection(entityReference.KeyAttributes);
     RowVersion    = entityReference.RowVersion;
 }
Пример #3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="SerializableEntity"/> class.
 /// </summary>
 /// <param name="entity">The entity.</param>
 public SerializableEntity(Entity entity)
 {
     Attributes      = new SerializableAttributeCollection(entity.Attributes);
     EntityState     = entity.EntityState;
     ExtensionData   = entity.ExtensionData;
     FormattedValues = new SerializableFormattedValueCollection(entity.FormattedValues);
     Id              = entity.Id;
     KeyAttributes   = new SerializableKeyAttributeCollection(entity.KeyAttributes);
     LogicalName     = entity.LogicalName;
     RelatedEntities = new SerializableRelatedEntityCollection(entity.RelatedEntities);
     RowVersion      = entity.RowVersion;
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="SerializableEntityReference"/> class.
 /// </summary>
 public SerializableEntityReference()
 {
     KeyAttributes = new SerializableKeyAttributeCollection();
 }