org.carewebframework.common.StrUtil.toInt()方法的使用及代码示例

x33g5p2x  于2022-01-30 转载在 其他  
字(1.4k)|赞(0)|评价(0)|浏览(100)

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

StrUtil.toInt介绍

[英]Converts a text value to an integer.
[中]将文本值转换为整数。

代码示例

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

/**
 * Extracts an integer portion at the beginning of a string. Parsing stops when a non-digit
 * character or the end of the string is encountered.
 * 
 * @param value String value to parse
 * @return The integer value at the beginning of the string.
 */
public static int extractInt(String value) {
  return toInt(extractIntPrefix(value));
}

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

int testcnt = StrUtil.toInt(pcs[0]);
int datecnt = StrUtil.toInt(pcs[1]);
int datacnt = StrUtil.toInt(pcs[2]);
  pcs = StrUtil.split(data.next(), StrUtil.U, 3);
  int col = headers.get(pcs[0]);
  int row = StrUtil.toInt(pcs[1]) - 1;
  setValue(col, row, pcs[2], pcs[4]);

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

percentiles.clear();
String[] pcs = StrUtil.split(data.next(), StrUtil.U, 3);
int testcnt = StrUtil.toInt(pcs[0]);
int datecnt = StrUtil.toInt(pcs[1]);
int datacnt = StrUtil.toInt(pcs[2]);
  pcs = StrUtil.split(data.next(), StrUtil.U, 3);
  int col = headers.get(pcs[0]).getColumnIndex();
  int row = StrUtil.toInt(pcs[1]) - 1;
  setValue(col, row, StrUtil.strAppend(getValue(col, row), pcs[2], "; "), null);
  lstVitals.getItemAtIndex(row).setVisible(true);

相关文章