return tagCheckers;
    private void makeTagCheckers(final Model model) {        TagChecker fieldChecker = new TagChecker() {            void isValid(String tagName, String objectIdentifier, String type,                         UserProfile userProfile) {                int dotIndex = objectIdentifier.indexOf('.');                if (dotIndex == -1) {                    throw new RuntimeException("tried to tag an unknown field: "                                               + objectIdentifier);                }                String className = objectIdentifier.substring(0, dotIndex);                String fieldName = objectIdentifier.substring(dotIndex + 1);                ClassDescriptor cd =                    model.getClassDescriptorByName(model.getPackageName() + "." + className);                if (cd == null) {                    throw new RuntimeException("unknown class name \"" + className                                               + "\" while tagging: " + objectIdentifier);                }                FieldDescriptor fd = cd.getFieldDescriptorByName(fieldName);                if (fd == null) {                    throw new RuntimeException("unknown field name \"" + fieldName                                               + "\" in class \"" + className                                               + "\" while tagging: " + objectIdentifier);                }                if (type.equals("collection") && !fd.isCollection()) {                    throw new RuntimeException(objectIdentifier + " is not a collection");                }                if (type.equals("reference") && !fd.isReference()) {                    throw new RuntimeException(objectIdentifier + " is not a reference");                }                if (type.equals("attribute") && !fd.isAttribute()) {                    throw new RuntimeException(objectIdentifier + " is not a attribute");                }            }        };        tagCheckers.put("collection", fieldChecker);        tagCheckers.put("reference", fieldChecker);        tagCheckers.put("attribute", fieldChecker);        TagChecker templateChecker = new TagChecker() {            void isValid(String tagName, String objectIdentifier, String type,                         UserProfile userProfile) {                // OK            }        };        tagCheckers.put("template", templateChecker);        TagChecker classChecker = new TagChecker() {            void isValid(String tagName, String objectIdentifier, String type,                         UserProfile userProfile) {                String className = objectIdentifier;                ClassDescriptor cd = model.getClassDescriptorByName(className);                if (cd == null) {                    throw new RuntimeException("unknown class name \"" + className                                               + "\" while tagging: " + objectIdentifier);                }            }        };        tagCheckers.put("class", classChecker);    }