ensign/src/main/java/com/yem/wm/utils/ChineseUnit.java
2024-08-26 09:19:12 +08:00

49 lines
847 B
Java
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

package com.yem.wm.utils;
/**
* 中文单位帮助类
* @author zhangh
*
*/
public class ChineseUnit {
/**
* 中文权名称
*/
public final char name;
/**
* 10的倍数值
*/
public final int value;
/**
* 是否为节权位,它不是与之相邻的数字的倍数,而是整个小节的倍数。<br>
* 例如二十三万,万是节权位,与三无关,而和二十三关联
*/
public final boolean secUnit;
/**
* 构造
*
* @param name 名称
* @param value 值即10的倍数
* @param secUnit 是否为节权位
*/
public ChineseUnit(char name, int value, boolean secUnit) {
this.name = name;
this.value = value;
this.secUnit = secUnit;
}
public char getName() {
return name;
}
public boolean isSecUnit() {
return secUnit;
}
public int getValue() {
return value;
}
}