internal ServiceSingleEdgeUpdateDefinition(SingleEdgeUpdateDefinition myUpdateDefinition)
        {
            this.CommentUpdate = myUpdateDefinition.CommentUpdate;
            this.EdgeTypeID = myUpdateDefinition.EdgeTypeID;

            this.UpdatedStructuredProperties = (myUpdateDefinition.UpdatedStructuredProperties.Updated == null)
                ? null : myUpdateDefinition.UpdatedStructuredProperties.Updated.ToDictionary(k => k.Key, v => (object)v.Value);

            this.DeletedStructuredProperties = (myUpdateDefinition.UpdatedStructuredProperties.Deleted == null)
                ? null : myUpdateDefinition.UpdatedStructuredProperties.Deleted.ToList();

            this.UpdatedUnstructuredProperties = (myUpdateDefinition.UpdatedUnstructuredProperties.Updated == null)
                ? null : myUpdateDefinition.UpdatedUnstructuredProperties.Updated.ToDictionary(k => k.Key, v => (object)v.Value);

            this.DeletedUnstructuredProperties = (myUpdateDefinition.UpdatedUnstructuredProperties.Deleted == null)
                ? null : myUpdateDefinition.UpdatedUnstructuredProperties.Deleted.ToList();

            this.SourceVertex = new ServiceVertexInformation(myUpdateDefinition.SourceVertex);
            this.TargetVertex = new ServiceVertexInformation(myUpdateDefinition.TargetVertex);
        }
Exemplo n.º 2
0
        /// <summary>
        /// Adds a edge update definition.
        /// </summary>
        /// <param name="myEdgeUpdateDefinition">The name of the edge to be inserted</param>
        /// <returns>The reference of the current object. (fluent interface).</returns>
        public RequestUpdate UpdateEdge(SingleEdgeUpdateDefinition myEdgeUpdateDefinition)
        {
            UpdateOutgoingEdgesProperties = 
                UpdateOutgoingEdgesProperties ?? new List<SingleEdgeUpdateDefinition>();

            UpdateOutgoingEdgesProperties.Add(myEdgeUpdateDefinition);

            return this;
        }