コード例 #1
0
 private ExposedJsonBlockParser CreateExposedJsonBlockParser(IJsonBlockFactory <Block, ProxyJsonBlock> jsonBlockFactory = null)
 {
     return(new ExposedJsonBlockParser(jsonBlockFactory ?? _mockRepository.Create <IJsonBlockFactory <Block, ProxyJsonBlock> >().Object));
 }
コード例 #2
0
 private Mock <ExposedJsonBlockParser> CreateMockExposedJsonBlockParser(IJsonBlockFactory <Block, ProxyJsonBlock> jsonBlockFactory = null)
 {
     return(_mockRepository.Create <ExposedJsonBlockParser>(jsonBlockFactory ?? _mockRepository.Create <IJsonBlockFactory <Block, ProxyJsonBlock> >().Object));
 }
コード例 #3
0
 public ExposedJsonBlockParser(IJsonBlockFactory <Block, ProxyJsonBlock> jsonBlockFactory) : base(jsonBlockFactory)
 {
 }
コード例 #4
0
 /// <summary>
 /// Creates a <see cref="FlexiVideoBlockParser"/>.
 /// </summary>
 /// <param name="flexiPictureBlockFactory">The factory for building <see cref="FlexiVideoBlock"/>s.</param>
 /// <exception cref="ArgumentNullException">Thrown if <paramref name="flexiPictureBlockFactory"/> is <c>null</c>.</exception>
 public FlexiVideoBlockParser(IJsonBlockFactory <FlexiVideoBlock, ProxyJsonBlock> flexiPictureBlockFactory) : base(flexiPictureBlockFactory)
 {
     OpeningCharacters = new[] { 'v' };
 }
コード例 #5
0
 /// <summary>
 /// Creates a <see cref="JsonBlockParser{TMain, TProxy}"/>.
 /// </summary>
 /// <param name="JsonBlockFactory">The factory for creating JSON <see cref="Block"/>s.</param>
 /// <exception cref="ArgumentNullException">Thrown if <paramref name="JsonBlockFactory"/> is <c>null</c>.</exception>
 protected JsonBlockParser(IJsonBlockFactory <TMain, TProxy> JsonBlockFactory)
 {
     _jsonBlockFactory = JsonBlockFactory ?? throw new ArgumentNullException(nameof(JsonBlockFactory));
 }
コード例 #6
0
 /// <summary>
 /// Creates a <see cref="FlexiIncludeBlockParser"/>.
 /// </summary>
 /// <param name="flexiIncludeBlockFactory">The factory for building <see cref="FlexiIncludeBlock"/>s.</param>
 /// <exception cref="ArgumentNullException">Thrown if <paramref name="flexiIncludeBlockFactory"/> is <c>null</c>.</exception>
 public FlexiIncludeBlockParser(IJsonBlockFactory <FlexiIncludeBlock, ProxyJsonBlock> flexiIncludeBlockFactory) : base(flexiIncludeBlockFactory)
 {
     OpeningCharacters = new[] { 'i' };
 }
 /// <summary>
 /// Creates a <see cref="FlexiOptionsBlockParser"/>.
 /// </summary>
 /// <param name="flexiOptionsBlockFactory">The factory for building <see cref="FlexiOptionsBlock"/>s.</param>
 /// <exception cref="ArgumentNullException">Thrown if <paramref name="flexiOptionsBlockFactory"/> is <c>null</c>.</exception>
 public FlexiOptionsBlockParser(IJsonBlockFactory <FlexiOptionsBlock, ProxyJsonBlock> flexiOptionsBlockFactory) : base(flexiOptionsBlockFactory)
 {
     OpeningCharacters = new[] { 'o' };
 }