EDU.utwente.CoCompose.translate
Class CompositeFormConstraintsVisitor

java.lang.Object
  |
  +--EDU.utwente.CoCompose.lang.ModelVisitor
        |
        +--EDU.utwente.CoCompose.translate.CompositeFormConstraintsVisitor
All Implemented Interfaces:
java.lang.Runnable

public class CompositeFormConstraintsVisitor
extends ModelVisitor

Checks the concept form constraints of the model. Supports incremental checking, i.e. only checks for concepts with determined concept forms. Composite checking part.

Version:
0.1.18, 22 November 2003
Author:
Dennis Wagelaar

Fields inherited from class EDU.utwente.CoCompose.lang.ModelVisitor
log
 
Constructor Summary
CompositeFormConstraintsVisitor(FormConstraintsVisitor parent)
          Constructs a CompositeFormConstraintsVisitor.
 
Method Summary
 void checkCompositeRole(CompositeRole role, ImplementationGenerator implementation)
          Checks a CompositeRole object.
 void checkConcept(Concept concept, CompositeRole role, ImplementationGenerator implementation)
          Checks a Concept object.
 void visitComposite(Composite composite)
          Checks the concept form constraints for the composite.
PRE: The model must be defined for this composite.
 void visitImplementationGenerator(ImplementationGenerator implementation)
          Check concept form constraints for this implementation generator.
PRE: The composite and model must be defined for this implementation generator.
 void visitImplementationRolePart(ImplementationRolePart rolepart)
          Check concept form constraints for this implementation generator's role part.
PRE: The implementation generator, composite and model must be defined for this role part.
 
Methods inherited from class EDU.utwente.CoCompose.lang.ModelVisitor
getUpdate, run, setErrorReporter, setLogger, setUpdate, startModel, visitAbstractConcept, visitCompositePartConcept, visitCompositeRole, visitConcept, visitConstrainedConcept, visitImplementation, visitLink, visitModel, visitPublishedConcept, visitSolutionPattern, visitSolutionRole
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CompositeFormConstraintsVisitor

public CompositeFormConstraintsVisitor(FormConstraintsVisitor parent)
Constructs a CompositeFormConstraintsVisitor.
Parameters:
parent - The parent visitor.
Method Detail

visitComposite

public void visitComposite(Composite composite)
                    throws CoComposeException
Checks the concept form constraints for the composite.
PRE: The model must be defined for this composite.
Overrides:
visitComposite in class ModelVisitor
Parameters:
composite - The composite to check the forms for.
Throws:
CoComposeException - if one of the model's constraints are not fulfilled or if the concept form constraints are not met.

visitImplementationGenerator

public void visitImplementationGenerator(ImplementationGenerator implementation)
                                  throws CoComposeException
Check concept form constraints for this implementation generator.
PRE: The composite and model must be defined for this implementation generator.
Overrides:
visitImplementationGenerator in class ModelVisitor
Parameters:
implementation - The implementation generator to check.
Throws:
CoComposeException - if one of the model's constraints are not fulfilled or if the concept form constraints are not met.

checkCompositeRole

public void checkCompositeRole(CompositeRole role,
                               ImplementationGenerator implementation)
                        throws CoComposeException
Checks a CompositeRole object.
Parameters:
role - The composite role to check.
implementation - The implementation generator to check.
Throws:
CoComposeException - if visiting operation failed.

checkConcept

public void checkConcept(Concept concept,
                         CompositeRole role,
                         ImplementationGenerator implementation)
                  throws CoComposeException
Checks a Concept object.
Parameters:
concept - The concept to check.
role - The composite role to check.
implementation - The implementation generator to check.
Throws:
CoComposeException - if visiting operation failed.

visitImplementationRolePart

public void visitImplementationRolePart(ImplementationRolePart rolepart)
                                 throws CoComposeException
Check concept form constraints for this implementation generator's role part.
PRE: The implementation generator, composite and model must be defined for this role part.
Overrides:
visitImplementationRolePart in class ModelVisitor
Parameters:
rolepart - The implementation generator role part to check.
Throws:
CoComposeException - if one of the model's constraints are not fulfilled or if the concept form constraints are not met.