/**
 *  Generated with Tigerstripe(tm) Tigerstripe Workbench Feature 2.2.0.v20070419-1556-GFEkmUll2-0111E.
 *
 *  Tigerstripe(tm) is a registered trademark of Tigerstripe, Inc.
 *
 *  Plugin  : Sun Microsystems Inc./SunJavaSpecificationPlugin(1.0) (1.0)
 *
 *  DO NOT EDIT THIS CODE WAS AUTOMATICALLY GENERATED
 *
 *  Generated from source Tigerstipe Artifact :
 *        javax.oss.cbe.AssociationRule
 *
 *  Using template :
 *        templates/1.3/datatypeInterface.vm
 *
 * Copyright 2002-2007 The Members of the OSS through Java(TM) Initiative.
 * All rights reserved. Use is subject to license terms.
 */
package javax.oss.cbe;

import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
import javax.xml.bind.annotation.XmlType;

import ossj.common.cbe.AssociationRuleAdapter;

@XmlType
@XmlJavaTypeAdapter(value=AssociationRuleAdapter.class)

/**
 *  Public interface definition for AssociationRule.
 *
 * An association rule defines the constraints for the corresponding association type.
 * An association rule should be provided for every concrete association type.
 * <p>
 *
 * <p>
 * Association Rules define:
 * <ul>
 * <li>the roles at each association end
 * <li>the cardinality of the association at each association end
 * <li>the type of entities or specifications involved at each association end
 * <li>the constraints applicable to this association
 * </ul>
 * <p>
 * If the constraints defined in an association rule are not respected during an
 * update operation (e.g. a creation of an association or a set operation on an
 * entity involved in the association) an <CODE>AssociationRuleViolationException</CODE>
 * is thrown.
 *
 */
public interface AssociationRule 
	extends java.lang.Cloneable, java.io.Serializable {


    /**
     * Deep copy of this object.
     *
     * @return The cloned object
     */
    public Object clone();


    /**
     *
     * Attribute getter for associationType.
     *
     *
     * Set the association type.
     *
     * @return the value of the associationType field.
     *
     */
    public java.lang.String getAssociationType( );


    /**
     * Attribute setter for associationType.
     *
     *
     * Set the association type.
     * @param value - the value to use to set the associationType attribute.
     * @throws java.lang.IllegalArgumentException
     *         Thrown to report that a bad argument was provided to the method.
     *
     */
    public void setAssociationType(java.lang.String value)
        throws
        java.lang.IllegalArgumentException;

    /**
     *
     * Attribute getter for AEndRole.
     *
     *
     * Set the A end role.
     * For example, if an association value representing an
     * aggregation association has an attribute "<CODE>Aggregating</CODE>" with the corresponding
     * accessors "<CODE>getAggregating</CODE>" and "<CODE>setAggregating</CODE>", the association rule for
     * this association type has one of the roles defined as "<CODE>Aggregating</CODE>".
     *
     * @return the value of the AEndRole field.
     *
     */
    public java.lang.String getAEndRole( );


    /**
     * Attribute setter for AEndRole.
     *
     *
     * Set the A end role.
     * For example, if an association value representing an
     * aggregation association has an attribute "<CODE>Aggregating</CODE>" with the corresponding
     * accessors "<CODE>getAggregating</CODE>" and "<CODE>setAggregating</CODE>", the association rule for
     * this association type has one of the roles defined as "<CODE>Aggregating</CODE>".
     * @param value - the value to use to set the AEndRole attribute.
     * @throws java.lang.IllegalArgumentException
     *         Thrown to report that a bad argument was provided to the method.
     *
     */
    public void setAEndRole(java.lang.String value)
        throws
        java.lang.IllegalArgumentException;

    /**
     *
     * Attribute getter for ZEndRole.
     *
     *
     * Set the Z end role.
     * For example, if an association value representing an
     * aggregation association has an attribute "<CODE>Aggregating</CODE>" with the corresponding
     * accessors ("<CODE>getAggregating</CODE>" and "<CODE>setAggregating</CODE>") the association rule for
     * this association type has one of the roles defined as "<CODE>Aggregating</CODE>".
     *
     * @return the value of the ZEndRole field.
     *
     */
    public java.lang.String getZEndRole( );


    /**
     * Attribute setter for ZEndRole.
     *
     *
     * Set the Z end role.
     * For example, if an association value representing an
     * aggregation association has an attribute "<CODE>Aggregating</CODE>" with the corresponding
     * accessors ("<CODE>getAggregating</CODE>" and "<CODE>setAggregating</CODE>") the association rule for
     * this association type has one of the roles defined as "<CODE>Aggregating</CODE>".
     * @param value - the value to use to set the ZEndRole attribute.
     * @throws java.lang.IllegalArgumentException
     *         Thrown to report that a bad argument was provided to the method.
     *
     */
    public void setZEndRole(java.lang.String value)
        throws
        java.lang.IllegalArgumentException;

    /**
     *
     * Attribute getter for AEndCardinality.
     *
     *
     * Set the A end cardinality.
     *
     * @return the value of the AEndCardinality field.
     *
     */
    public javax.oss.cbe.Cardinality getAEndCardinality( );

    /**
     *
     * Attribute Type getter for AEndCardinality.
     *
     * 
     * @return the valid set of types for the AEndCardinality field.
     *
     */
    public String[] attributeTypeForAEndCardinality();

    /**
     * Attribute setter for AEndCardinality.
     *
     *
     * Set the A end cardinality.
     * @param value - the value to use to set the AEndCardinality attribute.
     * @throws java.lang.IllegalArgumentException
     *         Thrown to report that a bad argument was provided to the method.
     *
     */
    public void setAEndCardinality(javax.oss.cbe.Cardinality value)
        throws
        java.lang.IllegalArgumentException;

    /**
     *
     * Attribute getter for ZEndCardinality.
     *
     *
     * Set the Z end cardinality.
     *
     * @return the value of the ZEndCardinality field.
     *
     */
    public javax.oss.cbe.Cardinality getZEndCardinality( );

    /**
     *
     * Attribute Type getter for ZEndCardinality.
     *
     * 
     * @return the valid set of types for the ZEndCardinality field.
     *
     */
    public String[] attributeTypeForZEndCardinality();

    /**
     * Attribute setter for ZEndCardinality.
     *
     *
     * Set the Z end cardinality.
     * @param value - the value to use to set the ZEndCardinality attribute.
     * @throws java.lang.IllegalArgumentException
     *         Thrown to report that a bad argument was provided to the method.
     *
     */
    public void setZEndCardinality(javax.oss.cbe.Cardinality value)
        throws
        java.lang.IllegalArgumentException;

    /**
     *
     * Attribute getter for AEndType.
     *
     *
     * Set the entity or specification type for the A end.
     *
     * @return the value of the AEndType field.
     *
     */
    public java.lang.String getAEndType( );


    /**
     * Attribute setter for AEndType.
     *
     *
     * Set the entity or specification type for the A end.
     * @param value - the value to use to set the AEndType attribute.
     * @throws java.lang.IllegalArgumentException
     *         Thrown to report that a bad argument was provided to the method.
     *
     */
    public void setAEndType(java.lang.String value)
        throws
        java.lang.IllegalArgumentException;

    /**
     *
     * Attribute getter for ZEndType.
     *
     *
     * Set the entity or specification type for the Z end.
     *
     * @return the value of the ZEndType field.
     *
     */
    public java.lang.String getZEndType( );


    /**
     * Attribute setter for ZEndType.
     *
     *
     * Set the entity or specification type for the Z end.
     * @param value - the value to use to set the ZEndType attribute.
     * @throws java.lang.IllegalArgumentException
     *         Thrown to report that a bad argument was provided to the method.
     *
     */
    public void setZEndType(java.lang.String value)
        throws
        java.lang.IllegalArgumentException;


    /**
     * Factory method for Cardinality.
     *
     * @param typeToMake - name of the type to be made
     * @return a new instance of Cardinality
     *
     * @throws java.lang.IllegalArgumentException - if the argument is invalid
     */
    public javax.oss.cbe.Cardinality makeCardinality(String typeToMake)
        throws 
        java.lang.IllegalArgumentException;


}
