예제 #1
0
 /// <summary>Create a detached field with the specified initial value and configuration.</summary>
 /// <param name="config">Encoding configuration.</param>
 public FieldParser(ReadOnlyEncodingConfiguration config)
     : base(config)
 {
     _repetitions = new WeakReferenceCache<RepetitionParser>(CreateRepetition);
 }
예제 #2
0
 /// <summary>Create a root element with the specified encoding configuration.</summary>
 /// <param name="config"></param>
 protected Parser(ReadOnlyEncodingConfiguration config)
     : this()
 {
     _encodingConfiguration = new Lazy<ReadOnlyEncodingConfiguration>(() => config);
 }
예제 #3
0
 /// <summary>Create a detached repetition with the specified initial value and encoding configuration.</summary>
 /// <param name="config">Encoding configuration.</param>
 private RepetitionParser(ReadOnlyEncodingConfiguration config)
     : base(config)
 {
     _components = new WeakReferenceCache<ComponentParser>(CreateComponent);
 }
 /// <summary>Create a subcomponent root with the specified encoding configuration.</summary>
 /// <param name="config">Encoding configuration to use.</param>
 private SubcomponentParser(ReadOnlyEncodingConfiguration config)
     : base(config)
 {
 }
예제 #5
0
 /// <summary>Create a segment root with the specified encoding configuration.</summary>
 /// <param name="config"></param>
 private SegmentParser(ReadOnlyEncodingConfiguration config)
     : base(config)
 {
     _fields = new WeakReferenceCache<FieldParser>(CreateField);
 }
예제 #6
0
 /// <summary>Create a descendant element that is detached from an ancestor.</summary>
 /// <param name="config">Encoding configuration for the element.</param>
 protected DescendantParser(ReadOnlyEncodingConfiguration config)
     : base(config)
 {
 }