public String getDisplayName(User user) { String displayName = user.getProperties().getProperty(DISPLAY_NAME_PROPERTY); if (displayName != null && displayName.length() > 0) { return displayName; } return null; }
public String getDisplayName(User user) { String displayName = user.getProperties().getProperty(DISPLAY_NAME_PROPERTY); if (displayName != null && displayName.length() > 0) { return displayName; } return null; }
public String getDisplayId(User user) { String displayId = user.getProperties().getProperty(DISPLAY_ID_PROPERTY); if (displayId != null && displayId.length() > 0) { return displayId; } return null; }
/** * Determines if this ContentReview result is from a student's inline text */ public boolean isInline() { ResourceProperties props = contentResource.getProperties(); return "true".equals(props.getProperty(AssignmentConstants.PROP_INLINE_SUBMISSION)); } }
public String getDisplayId(User user) { String displayId = user.getProperties().getProperty(DISPLAY_ID_PROPERTY); if (displayId != null && displayId.length() > 0) { return displayId; } return null; }
@Override public boolean isInstitutionalNumericIdEnabled(Site site) { try { return (serverConfigurationService.getBoolean(SYSTEM_PROP_USE_INSTITUTIONAL_NUMERIC_ID, false) || (site != null && Boolean.parseBoolean(site.getProperties().getProperty(SITE_PROP_USE_INSTITUTIONAL_NUMERIC_ID)))); } catch(Exception e) { log.warn("Error on isInstitutionalNumericIdEnabled (sample) ", e); } return false; }
public boolean useInstitutionalAnonymousId(Site site) { log.debug("useInstitutionalAnonymousId from fallback provider"); try { return (serverConfigurationService.getBoolean(PROP_USE_INSTITUTIONAL_ANONYMOUS_ID, false) || (site != null && Boolean.parseBoolean(site.getProperties().getProperty(PROP_USE_INSTITUTIONAL_ANONYMOUS_ID)))); } catch(Exception ignore) {} return false; }
public void unlockGroup(String lock) { if(StringUtils.isBlank(lock)) { log.warn("unlockGroup: null or empty lock"); return; } //TODO : this should be changed by addPropertyToList (When implemented in Kernel) String prop = this.getProperties().getProperty(GROUP_PROP_LOCKED_BY); if(StringUtils.isNotBlank(prop)) { this.getProperties().addProperty(GROUP_PROP_LOCKED_BY, Arrays.stream(prop.split(GROUP_PROP_SEPARATOR)).filter(s -> !lock.equals(s)).collect(Collectors.joining(GROUP_PROP_SEPARATOR))); } }
public boolean isFiltered(ContentResource resource) { String addHtml = resource.getProperties().getProperty(ResourceProperties.PROP_ADD_HTML); return enabled && ("text/html".equals(resource.getContentType())) && ((addHtml == null) || (!addHtml.equals("no") || addHtml.equals("yes"))); }
public Object getPropertyValue(Object source) throws Exception { String propName = (String) super.getPropertyValue(source); if (source instanceof ContentResource) { return ((ContentResource) source).getProperties().getProperty(propName); } else if (source instanceof ContentCollection) { return ((ContentCollection) source).getProperties().getProperty(propName); } return null; } }
public boolean isAdditionalNotesEnabled(Site site) { try { return (serverConfigurationService.getBoolean(SYSTEM_PROP_DISPLAY_ADDITIONAL_INFORMATION, false) || (site != null && Boolean.parseBoolean(site.getProperties().getProperty(SITE_PROP_DISPLAY_ADDITIONAL_INFORMATION)))); } catch(Exception e) { log.warn("Error on isAdditionalNotesEnabled (sample) ", e); } return false; }
public boolean useInstitutionalAnonymousId(Site site) { try { return (serverConfigurationService.getBoolean(SYSTEM_PROP_USE_INSTITUTIONAL_ANONYMOUS_ID, false) || (site != null && Boolean.parseBoolean(site.getProperties().getProperty(SITE_PROP_USE_INSTITUTIONAL_ANONYMOUS_ID)))); } catch(Exception e) { log.warn("Error on useInstitutionalAnonymousId (sample) ", e); } return false; }
public boolean useInstitutionalAnonymousId(Site site) { log.debug("useInstitutionalAnonymousId from fallback provider"); try { return (serverConfigurationService.getBoolean(PROP_USE_INSTITUTIONAL_ANONYMOUS_ID, false) || (site != null && Boolean.parseBoolean(site.getProperties().getProperty(PROP_USE_INSTITUTIONAL_ANONYMOUS_ID)))); } catch(Exception ignore) {} return false; }
public boolean isAdditionalNotesEnabled(Site site) { try { return (serverConfigurationService.getBoolean(PROP_DISPLAY_ADDITIONAL_INFORMATION, false) || (site != null && Boolean.parseBoolean(site.getProperties().getProperty(PROP_DISPLAY_ADDITIONAL_INFORMATION)))); } catch(Exception ignore) {} return false; }
@Override public boolean isInstitutionalNumericIdEnabled(Site site) { try { return (serverConfigurationService.getBoolean(PROP_USE_INSTITUTIONAL_NUMERIC_ID, false) || (site != null && Boolean.parseBoolean(site.getProperties().getProperty(PROP_USE_INSTITUTIONAL_NUMERIC_ID)))); } catch(Exception ignore) {} return false; }
@Override public boolean isInstitutionalNumericIdEnabled(Site site) { try { return (serverConfigurationService.getBoolean(PROP_USE_INSTITUTIONAL_NUMERIC_ID, false) || (site != null && Boolean.parseBoolean(site.getProperties().getProperty(PROP_USE_INSTITUTIONAL_NUMERIC_ID)))); } catch(Exception ignore) {} return false; }
public ContentResourceArtifact(ContentResource base, Id id, Agent owner) { this.base = base; this.id = id; this.owner = owner; setDisplayName(base.getProperties().getProperty(ResourceProperties.PROP_DISPLAY_NAME)); }
/** * Get the official image data from the user properties, encoded in BASE64 * @param userUuid uuid of user * @return base64 encoded data, or null. */ private String getOfficialImageEncoded(final String userUuid) { User u = sakaiProxy.getUserById(userUuid); return u.getProperties().getProperty(sakaiProxy.getOfficialImageAttribute()); }
public Entity parse(String xml, byte[] blob) throws EntityParseException { BaseResourceEdit bre = new BaseResourceEdit(); resourceSerializer.parse(bre,blob); ResourceProperties props = bre.getProperties(); if(props != null) { String oldDisplayName = props.getProperty(ResourceProperties.PROP_DISPLAY_NAME); bre.setOldDisplayName(oldDisplayName); } return bre; } /* (non-Javadoc)
public Entity parse(Entity container, String xml, byte[] blob) throws EntityParseException { BaseResourceEdit bre = new BaseResourceEdit(); resourceSerializer.parse(bre,blob); ResourceProperties props = bre.getProperties(); if(props != null) { String oldDisplayName = props.getProperty(ResourceProperties.PROP_DISPLAY_NAME); bre.setOldDisplayName(oldDisplayName); } return bre; }