public void PBToDTOVertex() { VertexDTO dtoStart = Misc.CreateVertexDTO(); PBVertex pb = dtoStart.ToPBVertex(); VertexDTO dtoEnd = pb.ToVertex(); Assert.True(dtoStart.CompareTo(dtoEnd) == 0); }
public static VertexDTO ToVertex(this PBVertex value) { //# Tested TinkarId tid = new TinkarId(new Guid(value.VertexId.Id.ToByteArray())); return(new VertexDTO(tid.Uuid, value.VertexIndex, value.Meaning.ToConcept(), value.Properties.ToImmutableDictionary())); throw new NotImplementedException(); }
public static PBVertex ToPBVertex(this VertexDTO value) { PBVertex retVal = new PBVertex { VertexId = value.VertexId.ToPBVertexId(), VertexIndex = value.VertexIndex, Meaning = value.Meaning.ToPBConcept() }; retVal.Properties.AddRange(value.Properties.ToPBProperties()); return(retVal); }