コード例 #1
0
 /**
  *
  * <!-- begin-user-doc -->
  * <!-- end-user-doc -->
  *
  * @param eClassifier the {@link EClassifier}
  * @return the class implementing a specific {@link EClass}.
  * @generated
  */
 @Override
 public Class<?> getEClassifierClass(EClassifier eClassifier) {
   switch (eClassifier.getClassifierID()) {
     case INCLUDE1_CLASSIFIER_ID:
       return Include1.class;
     case INCLUDE2_CLASSIFIER_ID:
       return Include2.class;
     default:
       throw new IllegalArgumentException(
           "The EClassifier '" + eClassifier + "' is not defined in this EPackage");
   }
 }
コード例 #2
0
 /**
  *
  * <!-- begin-user-doc -->
  * <!-- end-user-doc -->
  *
  * @param eClassifier the {@link EClassifier}
  * @return the class implementing a specific {@link EClass}.
  * @generated
  */
 @Override
 public Class<?> getEClassifierClass(EClassifier eClassifier) {
   switch (eClassifier.getClassifierID()) {
     case A_CLASSIFIER_ID:
       return A.class;
     case B_CLASSIFIER_ID:
       return B.class;
     case C_CLASSIFIER_ID:
       return C.class;
     case TESTANY_CLASSIFIER_ID:
       return TestAny.class;
     default:
       throw new IllegalArgumentException(
           "The EClassifier '" + eClassifier + "' is not defined in this EPackage");
   }
 }
コード例 #3
0
 /**
  *
  * <!-- begin-user-doc -->
  * <!-- end-user-doc -->
  *
  * @param eClassifier the {@link EClassifier}
  * @return the class implementing a specific {@link EClass}.
  * @generated
  */
 @Override
 public Class<?> getEClassifierClass(EClassifier eClassifier) {
   switch (eClassifier.getClassifierID()) {
     case DESCRIBABLEIDENTIFIABLECONCRETE_CLASSIFIER_ID:
       return DescribableIdentifiableConcrete.class;
     case DESCRIBABLE_CLASSIFIER_ID:
       return Describable.class;
     case IDENTIFIEDTYPE_CLASSIFIER_ID:
       return IdentifiedType.class;
     case DESCRIBABLECONCRETE_CLASSIFIER_ID:
       return DescribableConcrete.class;
     case IDENTIFIABLECONCRETE_CLASSIFIER_ID:
       return IdentifiableConcrete.class;
     default:
       throw new IllegalArgumentException(
           "The EClassifier '" + eClassifier + "' is not defined in this EPackage");
   }
 }
コード例 #4
0
 /**
  *
  * <!-- begin-user-doc -->
  * <!-- end-user-doc -->
  *
  * @param eClassifier the {@link EClassifier}
  * @return the class implementing a specific {@link EClass}.
  * @generated
  */
 @Override
 public Class<?> getEClassifierClass(EClassifier eClassifier) {
   switch (eClassifier.getClassifierID()) {
     case STATESBYCOUNTRY_CLASSIFIER_ID:
       return StatesByCountry.class;
     case STATELIST_CLASSIFIER_ID:
       return List.class;
     case STATE_CLASSIFIER_ID:
       return String.class;
     case SIXSTATESLIST_CLASSIFIER_ID:
       return List.class;
     case ZIPUNIONTYPE_CLASSIFIER_ID:
       return String.class;
     case ZIPUNIONSTYPE_CLASSIFIER_ID:
       return String.class;
     case SIMPLEUNIONTYPE_CLASSIFIER_ID:
       return Object.class;
     case SIMPLESTRINGUNIONTYPE_CLASSIFIER_ID:
       return String.class;
     case SIMPLESTRINGUNIONTYPEMEMBER0_CLASSIFIER_ID:
       return String.class;
     case SIMPLESTRINGUNIONTYPEMEMBER1_CLASSIFIER_ID:
       return String.class;
     case SIMPLEUNIONTYPEMEMBER0_CLASSIFIER_ID:
       return BigInteger.class;
     case SIMPLEUNIONTYPEMEMBER1_CLASSIFIER_ID:
       return SimpleUnionTypeMember1.class;
     case SIMPLEUNIONTYPEMEMBER1OBJECT_CLASSIFIER_ID:
       return SimpleUnionTypeMember1.class;
     case STRINGLIST_CLASSIFIER_ID:
       return List.class;
     case ZIPCODE_CLASSIFIER_ID:
       return String.class;
     default:
       throw new IllegalArgumentException(
           "The EClassifier '" + eClassifier + "' is not defined in this EPackage");
   }
 }
  /* (non-Javadoc)
   * @see com.metamatrix.modeler.core.metamodel.aspect.MetamodelAspectFactory#create(org.eclipse.emf.ecore.EClassifier, com.metamatrix.modeler.core.metamodel.aspect.MetamodelEntity)
   */
  public MetamodelAspect create(EClassifier classifier, MetamodelEntity entity) {
    switch (classifier.getClassifierID()) {
      case RelationshipPackage.FILE_REFERENCE:
      case RelationshipPackage.ISTATUS:
      case RelationshipPackage.LIST:
      case RelationshipPackage.PLACEHOLDER_REFERENCE:
      case RelationshipPackage.URI_REFERENCE:
      case RelationshipPackage.RELATIONSHIP_ENTITY:
        return null;
      case RelationshipPackage.RELATIONSHIP:
        return createRelationshipAspect(entity);
      case RelationshipPackage.RELATIONSHIP_ROLE:
        return createRelationshipRoleAspect(entity);
      case RelationshipPackage.RELATIONSHIP_TYPE:
        return createRelationshipTypeAspect(entity);

      default:
        throw new IllegalArgumentException(
            RelationshipMetamodelPlugin.Util.getString(
                "RelationshipAspectFactoryImpl.Invalid_Classifer_ID,_for_creating_Relationship_Metamodel_Aspect_{0}._1",
                classifier)); //$NON-NLS-1$
    }
  }