CFGLib.Production.Production C# (CSharp) Method

Production() public method

Returns a new production.
public Production ( Nonterminal lhs, Sentence rhs, double weight = 1.0 ) : System
lhs Nonterminal
rhs Sentence
weight double
return System
		public Production(Nonterminal lhs, Sentence rhs, double weight = 1.0) {
			if (lhs == null) {
				throw new ArgumentNullException("Lhs must be non-null");
			}
			if (rhs == null) {
				throw new ArgumentNullException("Rhs must be non-null");
			}
			this.Lhs = lhs;
			_rhs = rhs;
			this.Weight = weight;
		}

Same methods

Production::Production ( Nonterminal lhs, Word rhsOnlyWord, double weight = 1.0 ) : System
Production::Production ( string lhsName, Sentence rhs, double weight = 1.0 ) : System
Production::Production ( string lhsName, Word rhsOnlyWord, double weight = 1.0 ) : System