Ejemplo n.º 1
0
        public TagPlan(ITagBuilder builder, IEnumerable <ITagModifier> modifiers, IElementNamingConvention elementNamingConvention)
        {
            Builder = builder;
            ElementNamingConvention = elementNamingConvention;

            _modifiers.AddRange(modifiers); // Important to force the enumerable to be executed no later than this point
        }
Ejemplo n.º 2
0
        public TagPlan(ITagBuilder builder, IEnumerable<ITagModifier> modifiers, IElementNamingConvention elementNamingConvention)
        {
            Builder = builder;
            ElementNamingConvention = elementNamingConvention;

            _modifiers.AddRange(modifiers); // Important to force the enumerable to be executed no later than this point
        }
Ejemplo n.º 3
0
 public void SetUp()
 {
     _page = MockRepository.GenerateStub<IFubuPage<ViewModel>>();
     _convention = MockRepository.GenerateStub<IElementNamingConvention>();
     _expression = (x=>x.Property);
     _accessor = _expression.ToAccessor();
     _convention.Stub(c => c.GetName(Arg<Type>.Is.Equal(typeof (ViewModel)), Arg<Accessor>.Is.Equal(_accessor))).Return("name");
     _page.Stub(p => p.Get<IElementNamingConvention>()).Return(_convention);
 }
Ejemplo n.º 4
0
 public void SetUp()
 {
     _page       = MockRepository.GenerateStub <IFubuPage <ViewModel> >();
     _convention = MockRepository.GenerateStub <IElementNamingConvention>();
     _expression = (x => x.Property);
     _accessor   = _expression.ToAccessor();
     _convention.Stub(c => c.GetName(Arg <Type> .Is.Equal(typeof(ViewModel)), Arg <Accessor> .Is.Equal(_accessor))).Return("name");
     _page.Stub(p => p.Get <IElementNamingConvention>()).Return(_convention);
 }
Ejemplo n.º 5
0
        public TagGenerator(TagProfileLibrary library, IElementNamingConvention namingConvention, IServiceLocator services)
        {
            ElementPrefix = string.Empty;

            _library          = library;
            _namingConvention = namingConvention;
            _services         = services;

            _profile = _library.DefaultProfile;
        }
Ejemplo n.º 6
0
 public BuilderSet()
 {
     _elementNamingConvention = new DefaultElementNamingConvention();
 }
Ejemplo n.º 7
0
 public void Import(BuilderSet other)
 {
     _policies.AddRange(other._policies);
     _modifiers.AddRange(other._modifiers);
     _elementNamingConvention = other._elementNamingConvention;
 }
Ejemplo n.º 8
0
 public void NamingConvention(IElementNamingConvention elementNamingConvention)
 => _elementNamingConvention = elementNamingConvention;
Ejemplo n.º 9
0
 public BuilderSet()
 {
     _elementNamingConvention = new DefaultElementNamingConvention();
 }
Ejemplo n.º 10
0
 public void Import(BuilderSet other)
 {
     _policies.AddRange(other._policies);
     _modifiers.AddRange(other._modifiers);
     _elementNamingConvention = other._elementNamingConvention;
 }
Ejemplo n.º 11
0
 public TagGenerator(IElementNamingConvention namingConvention, TagProfileExpression tagProfile)
 {
     ElementPrefix     = string.Empty;
     _namingConvention = namingConvention;
     _profile          = tagProfile.Profile;
 }
Ejemplo n.º 12
0
 public ElementRequestActivator(IFubuRequest request, IElementNamingConvention naming)
     : base(naming)
 {
     _request = request;
 }
 public static string GetName <TModel, TProperty>(
     this IElementNamingConvention elementNaming,
     Expression <Func <TModel, TProperty> > property)
 {
     return(elementNaming.GetName(typeof(TModel), property.ToAccessor()));
 }
Ejemplo n.º 14
0
 public void NamingConvention(IElementNamingConvention elementNamingConvention)
 {
     _elementNamingConvention = elementNamingConvention;
 }
Ejemplo n.º 15
0
 public void NamingConvention(IElementNamingConvention elementNamingConvention)
 => _set.NamingConvention(elementNamingConvention);
Ejemplo n.º 16
0
 public ElementIdActivator(IElementNamingConvention naming)
 {
     _naming = naming;
 }
Ejemplo n.º 17
0
 public ElementRequestActivator(IFubuRequest request, IElementNamingConvention naming)
     : base(naming)
 {
     _request = request;
 }