Add Constraint and Validatetrans class docs.

This commit is contained in:
Chris PeBenito 2015-02-15 17:17:58 -05:00
parent a08873765c
commit 5983b87d5f

View File

@ -228,6 +228,8 @@ class BaseConstraint(symbol.PolicySymbol):
class Constraint(BaseConstraint):
"""A constraint rule (constrain/mlsconstrain)."""
def __str__(self):
rule_string = "{0.ruletype} {0.tclass} ".format(self)
@ -250,5 +252,7 @@ class Constraint(BaseConstraint):
class Validatetrans(BaseConstraint):
"""A validatetrans rule (validatetrans/mlsvalidatetrans)."""
def __str__(self):
return "{0.ruletype} {0.tclass}\n\t{1}\n);".format(self, self._build_expression())