/** * This method return Type with a specified typeId, used by * ItemFacade.getItemType() * @param typeId * @return org.osid.shared.Type or null if no types of that id */ public Type getTypeById(Long typeId){ TypeFacade typeFacade = getTypeFacadeById(typeId); // SAM-1792 this could be a request for an unknown type if (typeFacade == null) { log.warn("Unable to find Item Type: " + typeId.toString()); return null; } TypeExtension type = new TypeExtension(typeFacade.getAuthority(), typeFacade.getDomain(), typeFacade.getKeyword(), typeFacade.getDescription()); return type; }
/** * This method return Type with a specified typeId, used by * ItemFacade.getItemType() * @param typeId * @return org.osid.shared.Type or null if no types of that id */ public Type getTypeById(Long typeId){ TypeFacade typeFacade = getTypeFacadeById(typeId); // SAM-1792 this could be a request for an unknown type if (typeFacade == null) { log.warn("Unable to find Item Type: " + typeId.toString()); return null; } TypeExtension type = new TypeExtension(typeFacade.getAuthority(), typeFacade.getDomain(), typeFacade.getKeyword(), typeFacade.getDescription()); return type; }