package testSubtypingA.structure;
/*Generated by MPS */
import jetbrains.mps.smodel.runtime.BaseStructureAspectDescriptor;
import jetbrains.mps.smodel.runtime.ConceptDescriptor;
import java.util.Collection;
import java.util.Arrays;
import org.jetbrains.annotations.Nullable;
import jetbrains.mps.smodel.adapter.ids.SConceptId;
import org.jetbrains.mps.openapi.language.SAbstractConcept;
import jetbrains.mps.smodel.runtime.impl.ConceptDescriptorBuilder2;
import jetbrains.mps.smodel.runtime.ConceptKind;
import jetbrains.mps.smodel.runtime.StaticScope;
public class StructureAspectDescriptor extends BaseStructureAspectDescriptor {
/*package*/ final ConceptDescriptor myConceptWrapperType = createDescriptorForWrapperType();
private final LanguageConceptSwitch myConceptIndex;
public StructureAspectDescriptor() {
myConceptIndex = new LanguageConceptSwitch();
}
@Override
public Collection<ConceptDescriptor> getDescriptors() {
return Arrays.asList(myConceptWrapperType);
}
@Override
@Nullable
public ConceptDescriptor getDescriptor(SConceptId id) {
switch (myConceptIndex.index(id)) {
case LanguageConceptSwitch.WrapperType:
return myConceptWrapperType;
default:
return null;
}
}
/*package*/ int internalIndex(SAbstractConcept c) {
return myConceptIndex.index(c);
}
private static ConceptDescriptor createDescriptorForWrapperType() {
ConceptDescriptorBuilder2 b = new ConceptDescriptorBuilder2("testSubtypingA", "WrapperType", 0x36a4d1c56ec1426fL, 0x81921875a7cc48deL, 0x1cd6df1ae5a17c9cL);
b.class_(false, false, false);
b.super_("jetbrains.mps.baseLanguage.structure.Type", 0xf3061a5392264cc5L, 0xa443f952ceaf5816L, 0xf8c37f506dL);
b.origin("r:8811bffd-1bca-4bc6-88be-53c5eda0c75c(testSubtypingA.structure)/2078093584692771996");
b.aggregate("wrapped", 0x1cd6df1ae5a1e20fL).target(0xf3061a5392264cc5L, 0xa443f952ceaf5816L, 0xf8c37f506dL).optional(true).ordered(true).multiple(false).origin("2078093584692797967").done();
b.kind(ConceptKind.INTERFACE, StaticScope.GLOBAL);
b.alias("*");
return b.create();
}
}