New Posts New Posts RSS Feed: ListVerifier
  FAQ FAQ  Forum Search   Calendar   Register Register  Login Login

Forum LockedListVerifier

 Post Reply Post Reply
Author
Louis View Drop Down
Newbie
Newbie


Joined: 28-Sep-2010
Posts: 5
Post Options Post Options   Quote Louis Quote  Post ReplyReply Direct Link To This Post Topic: ListVerifier
    Posted: 31-Jan-2012 at 8:40am
I am attempting to use the ListVerifier attribute.  We have version 6.1.4.0 of the IdeaBlade.Validation assembly.  Are there any working examples of its usage online?

Back to Top
sbelini View Drop Down
IdeaBlade
IdeaBlade
Avatar

Joined: 13-Aug-2010
Location: Oakland
Posts: 786
Post Options Post Options   Quote sbelini Quote  Post ReplyReply Direct Link To This Post Posted: 31-Jan-2012 at 4:51pm
Hi Louis,
 
We don't have any example in our samples, but here's a simple snippet showing how to use it in a verifier provider:
 
public class ModelVerifierProvider : IVerifierProvider {
  public IEnumerable<Verifier> GetVerifiers(object verifierProviderContext) {
    var verifiers = new List<Verifier>
      {
        new ListVerifier(typeof(Customer), Customer.PropertyMetadata.Country.Name,
                       true, new List<string>{ "Brazil", "EUA", "UK" })
      };
    return verifiers;
  }
}
 
Regards,
   Silvio.
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down