Hi,
In our project for transporting data between the client and service we are using DTO objects.For populating the dto using projections available in llbl.
In my scenario i am designed a DTO class with the following hierarchial structure.
[DataContract]
public class PlanTree
{
private int activityId;
private int personId;
private DateTime planDate;
private List<PersonPerLocation> collPersonLocation = null;
[DataMember]
public int ActivityId
{
get { return activityId; }
set { activityId = value; }
}
[DataMember]
public int PersonId
{
get { return personId; }
set { personId = value; }
}
[DataMember]
public DateTime PlanDate
{
get { return planDate; }
set { planDate = value; }
}
**[DataMember]
public List<PersonPerLocation> CollPersonLocation
{
get { return collPersonLocation; }
set { collPersonLocation = value; }
}**
}
[DataContract]
public class PersonPerLocation
{
private int personId;
private int personLocationId;
private string personName;
private string locationName;
[DataMember]
public int PersonId
{
get { return personId; }
set { personId = value; }
}
[DataMember]
public int PersonLocationId
{
get { return personLocationId; }
set { personLocationId = value; }
}
[DataMember]
public string PersonName
{
get { return personName; }
set { personName = value; }
}
[DataMember]
public string LocationName
{
get { return locationName; }
set { locationName = value; }
}
}.
Is it possible to project data into the above structure since i am having a list of personlocations collections as an field inside the PlanTree dto. Please let me know how to proceed on this scenario instead of using EntityCollection option.
Regards
Prabhu