String typeName_Type = typeName + "_Type"; stringBuffer.append("/** "); stringBuffer.append(jg.nullBlank(td.getDescription())); stringBuffer.append("\n * Updated by JCasGen "); stringBuffer.append(jg.getDate());
stringBuilder.append(jg.nullBlank(td.getDescription())); stringBuilder.append("\n * Updated by JCasGen "); stringBuilder.append(jg.getDate());
stringBuffer.append(JcasGen.nullBlank(td.getDescription())); stringBuffer.append("\n * Updated by JCasGen "); stringBuffer.append(JcasGen.getDate());
descriptionUI.setText(convertNull(existingTd.getDescription())); typeNameUI.setText(originalTypeName = existingTd.getName()); supertypeNameUI.setText(convertNull(existingTd.getSupertypeName()));
if (each.getDescription() != null && !each.getDescription().trim().isEmpty()) { sb.append("<p>"); sb.append(each.getDescription()); sb.append("</p>");
private OntClass addType(OntModel ontModel, OntClass parent, Type type) { TypeDescription description = descriptions.getType(type.getName()); OntClass ontClass = ontModel.createClass(namespace + type.getShortName()); String comment = description.getDescription(); if (comment != null) { ontClass.addComment(comment, EN); } HashSet<FeatureDescription> features = new HashSet<>(); if (parent != null) { parent.addSubClass(ontClass); features.addAll(Arrays.asList(description.getFeatures())); } else { for (Feature feature : type.getFeatures()) { TypeDescription typeDescription = descriptions.getType(feature.getDomain().getName()); if (typeDescription != null) { features.addAll(Arrays.asList(typeDescription.getFeatures())); } } } for (FeatureDescription feature : features) { if (!ignoreProperties.contains(feature.getName())) { addFeature(ontModel, ontClass, feature); } } for (Type child : typeSystem.getDirectSubtypes(type)) { addType(ontModel, ontClass, child); } return ontClass; }
private OntClass addType(OntModel ontModel, OntClass parent, Type type) { TypeDescription description = descriptions.getType(type.getName()); OntClass ontClass = ontModel.createClass(namespace + type.getShortName()); String comment = description.getDescription(); if (comment != null) { ontClass.addComment(comment, EN); } HashSet<FeatureDescription> features = new HashSet<>(); if (parent != null) { parent.addSubClass(ontClass); features.addAll(Arrays.asList(description.getFeatures())); } else { for (Feature feature : type.getFeatures()) { TypeDescription typeDescription = descriptions.getType(feature.getDomain().getName()); if (typeDescription != null) { features.addAll(Arrays.asList(typeDescription.getFeatures())); } } } for (FeatureDescription feature : features) { if (!ignoreProperties.contains(feature.getName())) { addFeature(ontModel, ontClass, feature); } } for (Type child : typeSystem.getDirectSubtypes(type)) { addType(ontModel, ontClass, child); } return ontClass; }
/** * Type update. * * @param td the td * @param dialog the dialog */ private void typeUpdate(TypeDescription td, AddTypeDialog dialog) { td.setName(setValueChanged(dialog.typeName, td.getName())); td.setDescription(setValueChanged(multiLineFix(dialog.description), td.getDescription())); td.setSupertypeName(setValueChanged(dialog.supertypeName, td.getSupertypeName())); }
layer.setDescription(trimToNull(aTD.getDescription()));
layer.setDescription(trimToNull(aTD.getDescription()));
/** * Handle hover. * * @param event the event */ public void handleHover(Event event) { // next getItem call requires that table have SWT.FULL_SELECTION Style TableTreeItem item = tt.getItem(new Point(event.x, event.y)); if (null != item) { Object o = item.getData(); if (null == o) throw new InternalErrorCDE("invalid state"); if (o instanceof TypeDescription) { setToolTipText(tt, ((TypeDescription) o).getDescription()); } else if (o instanceof FeatureDescription) { FeatureDescription fd = (FeatureDescription) o; if (item.getBounds(MULTIPLE_REF_OK_COL).contains(event.x, event.y) && isArrayOrListType(fd.getRangeTypeName())) { Boolean mra = fd.getMultipleReferencesAllowed(); setToolTipText(tt, (mra != null && mra.booleanValue()) ? "Multiple References Allowed" : "Multiple References Not Allowed"); } else setToolTipText(tt, fd.getDescription()); } else if (o instanceof AllowedValue) { setToolTipText(tt, ((AllowedValue) o).getDescription()); } } else tt.setToolTipText(""); }
existingType.setDescription(type.getDescription()); existingType.setSupertypeName(supertypeName); existingType.setAllowedValues(type.getAllowedValues());