org.mizartools.system.utility.AbstractSignature abstractSignature,
org.mizartools.system.xml.Pattern pattern)
throws DliException {
ArticleId articleId = new ArticleId(pattern.getAid());
ItemType itemType = null;
ItemDefinition itemDefinition = null;
SymbolId symbolId1 = Adapter.getSymbolId1(pattern);
Loci loci = Adapter.getLoci(abstractSignature, pattern.getArgTypes());
Format format = Adapter.getFormat(pattern.getFormat());
Visible visible = Adapter.getVisible(pattern.getVisible());
Constructor constructor = Adapter.getConstructor(abstractSignature, pattern);
Synonym synonym = null;
Antonym antonym = null;
org.mizartools.system.xml.Pattern.Kind kind = pattern.getKind();
switch (kind) {
case M :
if (pattern.getRedefnr() != null) synonym = new Synonym();
Abbreviation abbreviation = Adapter.getAbbreviation(abstractSignature, pattern.getExpansion());
itemDefinition = new ModeNotation(symbolId1, loci, format, visible, constructor, abbreviation, synonym);
itemType = ItemType.modenot;
break;
case R :
if (pattern.getAntonymic() != null) antonym = new Antonym();
if (pattern.getRedefnr() != null) synonym = new Synonym();
if (antonym != null && synonym != null) synonym = null;
itemDefinition = new PredicateNotation(symbolId1, loci, format, visible, constructor, antonym, synonym);
itemType = ItemType.prednot;
break;
case K :
if (pattern.getRedefnr() != null) synonym = new Synonym();
SymbolId symbolId2 = Adapter.getSymbolId2(pattern);
itemDefinition = new FunctorNotation(symbolId1, symbolId2, loci, format, visible, constructor, synonym);
itemType = ItemType.funcnot;
break;
case V :
if (pattern.getAntonymic() != null) antonym = new Antonym();
if (antonym == null && pattern.getRedefnr() != null) synonym = new Synonym();
itemDefinition = new AttributeNotation(symbolId1, loci, format, visible, constructor, antonym, synonym);
itemType = ItemType.attrnot;
break;
case G :
itemDefinition = new AggregateNotation(symbolId1, loci, format, visible, constructor, synonym);
itemType = ItemType.aggrnot;
break;
case L :
itemDefinition = new StructureNotation(symbolId1, loci, format, visible, constructor, synonym);
itemType = ItemType.structnot;
break;
case U :
itemDefinition = new SelectorNotation(symbolId1, loci, format, visible, constructor, synonym);
itemType = ItemType.selnot;
break;
case J :
itemDefinition = new ForgNotation(symbolId1, loci, format, visible, constructor, synonym);
itemType = ItemType.forgnot;
break;
default :
}
if (itemDefinition == null) itemDefinition = new ItemDefinition("?");
int nr = pattern.getNr();
ItemId itemId = new ItemId(articleId, itemType, nr);
DecodedLibraryItem decodedLibraryItem = new DecodedLibraryItem(itemId, itemDefinition);