I have a derived class that uses a method from a value object. My
value object has first, last names, so I added a concatenation for
full name and other variations for Find() criteria.

The abbreviated version is shown below. My goal is to be able to do
something like the following p => p.Person.FullName.Contains("John
Doe");

I am using Nhibernate.Linq and Linq.Specifications. I was trying to
write a specification that included the

That fails. Is there a fluent nhibernate way that I can accomplish
this, or will the solution lie more in nhibernate?

Thanks,

Kurt

<code>
public class User : AbstractUser{
}

public abstract AbstractUser
{
        public virtual Person Person {get; private set:}
}

public class Person{
        public virtual string LastName {get; private set;}
        public virtual string FirstName {get; private set;}

        public Person (string firstName, string lastName){
                FirstName = firstName;
                LastName = lastName;
        }

        public string FullName{
                get{
                        return string.Format("{0} {1}, FirstName, LastName");
                }
        }
}
</code>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Fluent NHibernate" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/fluent-nhibernate?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to