org.fujion.component.Label.setLabel()方法的使用及代码示例

x33g5p2x  于2022-01-24 转载在 其他  
字(8.5k)|赞(0)|评价(0)|浏览(130)

本文整理了Java中org.fujion.component.Label.setLabel()方法的一些代码示例,展示了Label.setLabel()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Label.setLabel()方法的具体详情如下:
包路径:org.fujion.component.Label
类名称:Label
方法名:setLabel

Label.setLabel介绍

暂无

代码示例

代码示例来源:origin: org.carewebframework/org.carewebframework.shell

/**
 * Sets the caption.
 *
 * @param caption The caption.
 */
public void setCaption(String caption) {
  lblTitle.setLabel(caption);
}

代码示例来源:origin: org.carewebframework/org.carewebframework.shell

/**
 * Sets the button's label text.
 *
 * @param value The label text.
 */
public void setLabel(String value) {
  label.setLabel(value);
}

代码示例来源:origin: org.hspconsortium.carewebframework/cwf-ui-reporting

private void updateLabel(Label label, String value) {
  if (label != null) {
    label.setLabel(value);
  }
}

代码示例来源:origin: org.hspconsortium.carewebframework/cwf-plugin-scenario

/**
 * Displays the specified message;
 *
 * @param msg Message to display.
 */
private void setMessage(String msg) {
  lblMessage.setLabel(msg);
}

代码示例来源:origin: org.carewebframework/org.carewebframework.plugin.eventtesting

private void info(String action, String eventName) {
  lblInfo.setLabel(action + " '" + eventName + " ' event.");
}

代码示例来源:origin: org.carewebframework/org.carewebframework.plugin.currentdatetime

private void updateTime() {
  Calendar cal = Calendar.getInstance(DateUtil.getLocalTimeZone());
  lblCurrentTime.setLabel(formatter == null ? "" : formatter.format(cal));
}

代码示例来源:origin: org.hspconsortium.carewebframework/cwf-plugin-patientheader

private void setLabel(Label label, String value, BaseUIComponent associatedComponent) {
  label.setLabel(value);
  label.setVisible(value != null && !value.isEmpty());
  if (associatedComponent != null) {
    associatedComponent.setVisible(label.isVisible());
  }
}

代码示例来源:origin: org.hspconsortium.carewebframework/cwf-ui-reporting

/**
 * Add a row containing the specified header (left column) and value (right column). If
 * log.isDebugEnabled() is false then don't add row for empty or null values
 *
 * @param header Text for header column
 * @param value Text for value column
 */
protected void addRow(String header, String value) {
  if ((value == null || value.length() == 0) && !debug) {
    return;
  }
  
  Label lbl = new Label();
  lbl.setLabel(value);
  lbl.setHint(value);
  addRow(header, lbl);
}

代码示例来源:origin: org.carewebframework/org.carewebframework.shell

/**
 * Displays the description information for a property.
 *
 * @param propertyName Property name.
 * @param propertyDescription Property description.
 */
private void setPropertyDescription(String propertyName, String propertyDescription) {
  propInfo.setTitle(StrUtil.formatMessage(propertyName));
  lblPropertyInfo.setLabel(StrUtil.formatMessage(propertyDescription));
}

代码示例来源:origin: org.carewebframework/org.carewebframework.help.core

/**
 * Displays the specified message. The list box is hidden if the message is not empty.
 *
 * @param message Message to display.
 */
private void showMessage(String message) {
  message = message == null ? null : StrUtil.getLabel(message);
  lblNoResultsFound.setLabel(message);
  lblNoResultsFound.setVisible(!StringUtils.isEmpty(message));
  tblSrchResults.setVisible(!lblNoResultsFound.isVisible());
}

代码示例来源:origin: org.carewebframework/org.carewebframework.ui.core

@EventHandler(value = "click", target = "btnUnlock")
private void onClick$btnUnlock() {
  String s = txtPassword.getValue();
  txtPassword.setValue(null);
  lblInfo.setLabel(null);
  txtPassword.focus();
  
  if (!StringUtils.isEmpty(s)) {
    if (securityService.validatePassword(s)) {
      setMode(Mode.BASELINE);
    } else {
      lblInfo.setLabel(StrUtil.getLabel("cwf.sessionmonitor.lock.badpassword.message"));
    }
  }
}

代码示例来源:origin: org.carewebframework/org.carewebframework.plugin.userheader

private void setUser(IUser user) {
  if (log.isDebugEnabled()) {
    log.debug("user: " + user);
  }
  if (currentUser != null && currentUser.equals(user)) {
    return;
  }
  currentUser = user;
  String text = user == null ? "" : user.getFullName();
  if (user != null && user.getSecurityDomain() != null) {
    text += "@" + user.getSecurityDomain().getName();
  }
  userHeader.setLabel(text);
  password.setVisible(SecurityUtil.getSecurityService().canChangePassword());
}

代码示例来源:origin: org.carewebframework/org.carewebframework.ui.core

private void updateCountdown() {
  if (state == State.COUNTDOWN) {
    String s = nextMode().getLabel(TIMEOUT_WARNING, DateUtil.formatDuration(countdown, TimeUnit.SECONDS));
    lblDuration.setLabel(s);
    timeoutPanel.addClass("alert:" + (countdown <= 10000 ? "alert-danger" : "alert-warning"));
  }
}

代码示例来源:origin: org.carewebframework/org.carewebframework.ui.sharedforms

protected void status(String message) {
  if (message != null) {
    grid.setVisible(false);
    status.setLabel(StrUtil.piece(message, "^"));
    status.setHint(StrUtil.piece(message, "^", 2, 999));
    status.setVisible(true);
  } else {
    status.setVisible(false);
    status.setLabel(null);
    status.setHint(null);
    grid.setVisible(true);
  }
}

代码示例来源:origin: org.hspconsortium.carewebframework/cwf-ui-reporting

/**
 * Displays a message to client.
 *
 * @param message Message to display to client. If null, message label is hidden.
 * @param isError If true, highlight the message to indicate an error.
 */
public void showMessage(String message, boolean isError) {
  showBusy(null);
  message = StrUtil.formatMessage(message);
  boolean show = message != null;
  
  if (lblMessage != null) {
    lblMessage.setVisible(show);
    lblMessage.setLabel(show ? message : "");
    lblMessage.toggleClass("alert-danger", "alert-warning", isError);
  }
  
  if (hideOnShowMessage != null) {
    hideOnShowMessage.setVisible(!show);
  }
}

代码示例来源:origin: org.hspconsortium.carewebframework/cwf-plugin-patientheader

private void setPatient(Patient patient) {
  this.patient = patient;
  hideLabels();
  needsDetail = true;
  pnlDetail.destroyChildren();
  if (log.isDebugEnabled()) {
    log.debug("patient: " + patient);
  }
  if (patient == null) {
    lblName.setLabel(noSelection);
    btnDetail.setDisabled(true);
    return;
  }
  btnDetail.setDisabled(false);
  patientName = FhirUtil.formatName(patient.getName());
  String mrn = FhirUtil.getMRNString(patient);
  lblName.setLabel(patientName + (mrn.isEmpty() ? "" : "  (" + mrn + ")"));
  setLabel(lblDOB, formatDateAndAge(patient.getBirthDate()), lblDOBLabel);
  setLabel(lblDOD, formatDOD(patient.getDeceased()), lblDODLabel);
  setLabel(lblGender, patient.hasGender() ? patient.getGender().getDisplay() : null, null);
}

代码示例来源:origin: org.carewebframework/org.carewebframework.shell

aboutParams = comp.getAttribute("params", AboutParams.class);
imgIcon.setSrc(aboutParams.icon == null ? defaultIcon : aboutParams.icon);
lblSource.setLabel(aboutParams.source == null ? defaultSource : aboutParams.source);
btnCustom.setLabel(aboutParams.custom);
btnCustom.setVisible(btnCustom.getLabel() != null);

代码示例来源:origin: org.carewebframework/org.carewebframework.shell

@Override
public void afterInitialized(BaseComponent root) {
  window = (Window) root;
  window.setTitle(StrUtil.formatMessage(root.getAttribute("title", "")));
  lblPrompt.setLabel(StrUtil.formatMessage(root.getAttribute("prompt", "")));
  LayoutIdentifier dfltLayout = root.getAttribute("dfltLayout", LayoutIdentifier.class);
  txtLayout.setValue(dfltLayout == null ? null : dfltLayout.name);
  boolean shared = dfltLayout == null ? LayoutManager.defaultIsShared() : dfltLayout.shared;
  (shared ? rbShared : rbPrivate).setChecked(true);
  radioGroup.setVisible(!root.getAttribute("hideScope", false));
  allowDups = root.getAttribute("allowDups", true);
}

代码示例来源:origin: org.carewebframework/org.carewebframework.ui.core

@Override
public void afterInitialized(BaseComponent root) {
  super.afterInitialized(root);
  page = root.getPage();
  session = page.getSession();
  noAutoLock = page.getAttribute(ATTR_NO_AUTO_LOCK, false);
  timeoutWindow = (BaseUIComponent) root;
  getEventManager().subscribe(SessionControl.EVENT_ROOT, applicationControlListener);
  IUser user = securityService.getAuthenticatedUser();
  lblLocked.setLabel(user == null ? null
      : Mode.BASELINE.getLabel(TIMEOUT_EXPIRATION, user.getFullName() + "@" + user.getSecurityDomain().getName()));
  setMode(Mode.BASELINE);
  session.addSessionListener(sessionListener);
}

代码示例来源:origin: org.carewebframework/org.carewebframework.shell

@Override
public void afterInitialized(BaseComponent root) {
  window = (Window) root;
  shared = defaultIsShared();
  boolean manage = root.getAttribute("manage", false);
  window.setTitle(StrUtil.formatMessage(manage ? CAP_LAYOUT_MANAGE : CAP_LAYOUT_LOAD));
  lblPrompt.setLabel(StrUtil.formatMessage(manage ? MSG_LAYOUT_MANAGE : MSG_LAYOUT_LOAD));
  modelAndView = lstLayouts.getModelAndView(String.class);
  modelAndView.setRenderer(renderer);
  pnlSelect.setVisible(!manage);
  tbManage.setVisible(manage);
  ((Radiobutton) radioGroup.getChildAt(shared ? 0 : 1)).setChecked(true);
  pnlScope.addClass(manage ? "pull-right" : "pull-left");
  upload.bind(btnImport);
  refresh(root.getAttribute("dflt", ""));
}

相关文章