Lines Matching defs:item
175 BundleItem item = new BundleItem(group,null,null);
210 item.setParentGroup(group);
216 o = descriptors.get("comment"); if (o != null) item.setComment((String) o);
217 o = descriptors.get("translated"); if (o != null) item.setTranslated(((String) o).equalsIgnoreCase("true"));
218 o = descriptors.get("creator"); if (o != null) item.setCreator((String) o);
219 o = descriptors.get("modifier"); if (o != null) item.setModifier((String) o);
220 o = descriptors.get("created"); if (o != null) item.setCreatedDate((String) o);
221 o = descriptors.get("modified"); if (o != null) item.setModifiedDate((String) o);
230 item.getLookups().put(lookup, descriptors.get(tag));
250 item.setKey(key);
253 item.setTranslation(line.substring(line.indexOf("=")+1,line.length()).trim());
254 else item.setTranslation(translation);
256 dict.addBundleItem(item);
257 item = new BundleItem(group,null,null);
286 item = new BundleItem(group,null,null);
312 item.setParentGroup(group);
318 o = descriptors.get("comment"); if (o != null) item.setComment((String) o);
319 o = descriptors.get("translated"); if (o != null) item.setTranslated(((String) o).equalsIgnoreCase("true"));
320 o = descriptors.get("creator"); if (o != null) item.setCreator((String) o);
321 o = descriptors.get("modifier"); if (o != null) item.setModifier((String) o);
322 o = descriptors.get("created"); if (o != null) item.setCreatedDate((String) o);
323 o = descriptors.get("modified"); if (o != null) item.setModifiedDate((String) o);
332 item.getLookups().put(lookup, descriptors.get(tag));
351 item.setKey(key);
354 item.setTranslation(line.substring(line.indexOf("=")+1,line.length()).trim());
355 else item.setTranslation(translation);
357 dict.addBundleItem(item);
358 item = new BundleItem(group,null,null);
461 * Given a BundleItem and some properties to change for that item, this method first checks to make sure the passed
462 * item is valid and if it is, the properties of that item are changed to reflect those passed in as parameters to this
467 public boolean editItem(BundleItem item, String name, String value, String groupName, String comment, Hashtable lookups) {
468 if (name == null || name.equals("") || groupName == null || groupName.equals("") || item == null) return false;
469 String oldName = item.getKey();
470 String oldComment = item.getComment();
471 String oldValue = item.getTranslation();
472 //String oldGroupName = item.getParentGroup().getName();
500 * Attempts to create a new item in each of the language files. The method first checks the base Resource Bundle
501 * to make sure that the item name does not all ready exist. If it does exist the item is not created.
502 * @param name The unique key of the item
503 * @param value The translation of the item for the base class
505 * @param comment An optional comment to be added to the item, can be <CODE>null</CODE>
541 BundleItem item = new BundleItem(group, name, value);
542 item.setCreator(currentUser);
543 item.setModifier(currentUser);
544 item.setComment(comment);
545 if (lookups != null) item.setLookups(lookups);
546 bundle.allItems.put(name, item);
547 bundle.addUntranslatedItem(item);
548 group.addBundleItem(item);
598 * knows about. This works by first removing the item from the protected vector of translated
614 BundleItem item = (BundleItem)items.nextElement();
615 if (item.getKey().equals(itemName)) {
616 bundle.allItems.remove(item);
617 item.getParentGroup().removeBundleItem(item.getKey());
678 BundleItem item = new BundleItem(bg, mainItem.getKey(), mainItem.getTranslation());
679 item.setComment(mainItem.getComment());
680 item.setCreator(mainItem.getCreator());
681 item.setModifier(mainItem.getModifier());
682 item.setLookups(new Hashtable());
688 item.getLookups().put(new String(name), new String(value));
690 bg.addBundleItem(item);
691 bundle.addUntranslatedItem(item);