Example #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="LexEntry"/> class.
 /// </summary>
 public LexEntry()
 {
     MprFeatures = new MprFeatureSet();
     SyntacticFeatureStruct = FeatureStruct.New().Value;
     _allomorphs = new ObservableCollection<RootAllomorph>();
     _allomorphs.CollectionChanged += AllomorphsChanged;
 }
 public AffixProcessAllomorph()
 {
     _lhs = new List<Pattern<Word, ShapeNode>>();
     _rhs = new List<MorphologicalOutputAction>();
     _requiredMprFeatures = new MprFeatureSet();
     _excludedMprFeatures = new MprFeatureSet();
     _outMprFeatures = new MprFeatureSet();
     RequiredSyntacticFeatureStruct = FeatureStruct.New().Value;
 }
Example #3
0
 public RewriteSubrule()
 {
     Rhs = Pattern<Word, ShapeNode>.New().Value;
     LeftEnvironment = Pattern<Word, ShapeNode>.New().Value;
     RightEnvironment = Pattern<Word, ShapeNode>.New().Value;
     RequiredSyntacticFeatureStruct = FeatureStruct.New().Value;
     _requiredMprFeatures = new MprFeatureSet();
     _excludedMprFeatures = new MprFeatureSet();
 }
Example #4
0
 public AffixProcessAllomorph()
 {
     _lhs = new List <Pattern <Word, ShapeNode> >();
     _rhs = new List <MorphologicalOutputAction>();
     _requiredMprFeatures           = new MprFeatureSet();
     _excludedMprFeatures           = new MprFeatureSet();
     _outMprFeatures                = new MprFeatureSet();
     RequiredSyntacticFeatureStruct = FeatureStruct.New().Value;
 }
Example #5
0
        public CompoundingSubrule()
        {
            _headLhs    = new List <Pattern <Word, ShapeNode> >();
            _nonHeadLhs = new List <Pattern <Word, ShapeNode> >();
            _rhs        = new List <MorphologicalOutputAction>();

            _requiredMprFeatures = new MprFeatureSet();
            _excludedMprFeatures = new MprFeatureSet();
            _outMprFeatures      = new MprFeatureSet();
        }
        public CompoundingSubrule()
        {
            _headLhs = new List<Pattern<Word, ShapeNode>>();
            _nonHeadLhs = new List<Pattern<Word, ShapeNode>>();
            _rhs = new List<MorphologicalOutputAction>();

            _requiredMprFeatures = new MprFeatureSet();
            _excludedMprFeatures = new MprFeatureSet();
            _outMprFeatures = new MprFeatureSet();
        }
Example #7
0
        public RewriteSubrule()
        {
            Rhs = Pattern <Word, ShapeNode> .New().Value;

            LeftEnvironment = Pattern <Word, ShapeNode> .New().Value;

            RightEnvironment = Pattern <Word, ShapeNode> .New().Value;

            RequiredSyntacticFeatureStruct = FeatureStruct.New().Value;
            _requiredMprFeatures           = new MprFeatureSet();
            _excludedMprFeatures           = new MprFeatureSet();
        }
Example #8
0
		private static XElement CreateMprFeaturesFailureElement(bool required, MprFeatureGroup group, MprFeatureSet feats, Word input)
		{
			return new XElement("FailureReason", new XAttribute("type", "mprFeatures"),
				new XElement("MatchType", required ? "required" : "excluded"),
				new XElement("Group", group),
				new XElement("MprFeatures", input.MprFeatures.Where(mf => mf.Group == group).Select(f => new XElement("MprFeature", f))),
				new XElement("ConstrainingMprFeatrues", feats.Where(mf => mf.Group == group).Select(f => new XElement("MprFeature", f))));
		}
Example #9
0
 private static XElement CreateMprFeaturesFailureElement(bool required, MprFeatureGroup group, MprFeatureSet feats, Word input)
 {
     return(new XElement("FailureReason", new XAttribute("type", "mprFeatures"),
                         new XElement("MatchType", required ? "required" : "excluded"),
                         new XElement("Group", group),
                         new XElement("MprFeatures", input.MprFeatures.Where(mf => mf.Group == group).Select(f => new XElement("MprFeature", f))),
                         new XElement("ConstrainingMprFeatrues", feats.Where(mf => mf.Group == group).Select(f => new XElement("MprFeature", f)))));
 }