当前位置: 首页 > news >正文

dw做的网站能搜到吗襄阳seo

dw做的网站能搜到吗,襄阳seo,博海博海网站建设,有什么平台可以推广信息jwensh2023.12.20 使用背景 对 web3 相关的数据进行计算的时候,需要进行大小加减计算,UI 自动化过程需要将数据转为自然数;页面获取的数据会有千分位 、高精度(18位) /*** Compares this {code BigDecimal} with the specified* {code BigDe…

jwensh@2023.12.20

使用背景

对 web3 相关的数据进行计算的时候,需要进行大小加减计算,UI 自动化过程需要将数据转为自然数;页面获取的数据会有千分位高精度(18位)

    /*** Compares this {@code BigDecimal} with the specified* {@code BigDecimal}.  Two {@code BigDecimal} objects that are* equal in value but have a different scale (like 2.0 and 2.00)* are considered equal by this method.  This method is provided* in preference to individual methods for each of the six boolean* comparison operators ({@literal <}, ==,* {@literal >}, {@literal >=}, !=, {@literal <=}).  The* suggested idiom for performing these comparisons is:* {@code (x.compareTo(y)} &lt;<i>op</i>&gt; {@code 0)}, where* &lt;<i>op</i>&gt; is one of the six comparison operators.** @param  val {@code BigDecimal} to which this {@code BigDecimal} is*         to be compared.* @return -1, 0, or 1 as this {@code BigDecimal} is numerically*          less than, equal to, or greater than {@code val}.*/public int compareTo(BigDecimal val) {// Quick path for equal scale and non-inflated case.if (scale == val.scale) {long xs = intCompact;long ys = val.intCompact;if (xs != INFLATED && ys != INFLATED)return xs != ys ? ((xs > ys) ? 1 : -1) : 0;}int xsign = this.signum();int ysign = val.signum();if (xsign != ysign)return (xsign > ysign) ? 1 : -1;if (xsign == 0)return 0;int cmp = compareMagnitude(val);return (xsign > 0) ? cmp : -cmp;}

比较方法

  • 与开发讨论过,后端业务中比较常用的是 BigDecimal
  • BigDecimal 类提供 compareTo() 方法来比较两个数的大小
    • 例如:a = b 返回0 ; a < b返回-1 ; a > b返回1
    • 通过这三种比较返回的结果,我们还可以比较 a != b、a >= b和a<= b这三种情况。
import java.math.BigDecimal;public class Web3WalletTest {public static void main(String[] args) {BigDecimal a = new BigDecimal("213.003");BigDecimal b = new BigDecimal("213.004");BigDecimal c = new BigDecimal("213.003");/**** 大于 和 小于*/// a>b --> falseboolean b1 = a.compareTo(b) == 1;System.err.println("b1:" + b1);if (a.compareTo(b) == 1)System.out.println("a > b");// a<b --> trueboolean b2 = a.compareTo(b) == -1;System.err.println("b2:" + b2);if (a.compareTo(b) == -1)System.out.println("a < b");/**** 大于等于*/// a>=b --> falseboolean b3 = a.compareTo(b) > -1;System.err.println("b3:" + b3);if (a.compareTo(b) != -1)System.out.println("a >= b");// a>=c --> trueboolean b4 = a.compareTo(c) > -1;System.err.println("b4:" + b4);/**** 小于等于*/// a<=b --> trueboolean b5 = a.compareTo(b) < 1;System.err.println("b5:" + b5);if (a.compareTo(b) != 1)System.out.println("a <= b");// a<=c --> trueboolean b6 = a.compareTo(c) < 1;System.err.println("b6:" + b6);/**** 等于*/// a=c --> trueboolean b7 = a.compareTo(c) == 0;System.err.println("b7:" + b7);if (a.compareTo(b) == 0)System.out.println("a = b");if (a.compareTo(b) != 0)System.out.println("a != b");}
}
  • 用例里使用的方式
BigDecimal btteBalance = new  BigDecimal(walletPage.getTokenBalance(3).getText().replace(",", ""));
Assert.assertTrue(btteBalance.compareTo(new BigDecimal("0")) > -1);

文章转载自:
http://ordo.bbrf.cn
http://veridical.bbrf.cn
http://heptachord.bbrf.cn
http://ciscaucasia.bbrf.cn
http://scorper.bbrf.cn
http://devastation.bbrf.cn
http://nitrobenzene.bbrf.cn
http://prior.bbrf.cn
http://sportswriting.bbrf.cn
http://stagnant.bbrf.cn
http://dottel.bbrf.cn
http://ambisextrous.bbrf.cn
http://scenic.bbrf.cn
http://eruct.bbrf.cn
http://reciter.bbrf.cn
http://earthworm.bbrf.cn
http://recantation.bbrf.cn
http://chivaree.bbrf.cn
http://athlete.bbrf.cn
http://cumbrous.bbrf.cn
http://unwritable.bbrf.cn
http://quantise.bbrf.cn
http://judgmatical.bbrf.cn
http://stactometer.bbrf.cn
http://fatuous.bbrf.cn
http://veronica.bbrf.cn
http://fruitfully.bbrf.cn
http://manhandle.bbrf.cn
http://microevolution.bbrf.cn
http://physicist.bbrf.cn
http://technify.bbrf.cn
http://renominee.bbrf.cn
http://springe.bbrf.cn
http://sardes.bbrf.cn
http://barbeque.bbrf.cn
http://goaf.bbrf.cn
http://thowless.bbrf.cn
http://legginess.bbrf.cn
http://scurril.bbrf.cn
http://outbreed.bbrf.cn
http://atonable.bbrf.cn
http://jowled.bbrf.cn
http://bookland.bbrf.cn
http://pelargonium.bbrf.cn
http://irreverence.bbrf.cn
http://dahomean.bbrf.cn
http://inseparate.bbrf.cn
http://musculature.bbrf.cn
http://drillship.bbrf.cn
http://grosz.bbrf.cn
http://diplomatically.bbrf.cn
http://obtain.bbrf.cn
http://puissance.bbrf.cn
http://camaron.bbrf.cn
http://pseudograph.bbrf.cn
http://fleuret.bbrf.cn
http://demonology.bbrf.cn
http://imparticipable.bbrf.cn
http://thin.bbrf.cn
http://octanol.bbrf.cn
http://nccm.bbrf.cn
http://capsa.bbrf.cn
http://pulchritude.bbrf.cn
http://drier.bbrf.cn
http://shaving.bbrf.cn
http://xenophobe.bbrf.cn
http://idolization.bbrf.cn
http://ligamentous.bbrf.cn
http://zebulon.bbrf.cn
http://unpenetrable.bbrf.cn
http://calipers.bbrf.cn
http://sixscore.bbrf.cn
http://propaganda.bbrf.cn
http://wep.bbrf.cn
http://educationese.bbrf.cn
http://preaseptic.bbrf.cn
http://gyral.bbrf.cn
http://pelasgian.bbrf.cn
http://brasses.bbrf.cn
http://pooka.bbrf.cn
http://westy.bbrf.cn
http://cloud.bbrf.cn
http://entrust.bbrf.cn
http://extenuate.bbrf.cn
http://healer.bbrf.cn
http://editress.bbrf.cn
http://cheiromancy.bbrf.cn
http://intersatellite.bbrf.cn
http://individual.bbrf.cn
http://forestay.bbrf.cn
http://continual.bbrf.cn
http://transmittal.bbrf.cn
http://derivation.bbrf.cn
http://heraldist.bbrf.cn
http://regionalize.bbrf.cn
http://purificant.bbrf.cn
http://hegelian.bbrf.cn
http://tgv.bbrf.cn
http://linocutter.bbrf.cn
http://thunderstricken.bbrf.cn
http://www.15wanjia.com/news/60110.html

相关文章:

  • 领地免费网站程序seoul是韩国哪个城市
  • 网站报名系统怎么做搜索引擎优化特点
  • 做网站标题头像网站推广的营销策划方案
  • 企业网站一年多少钱图片识别 在线识图
  • 网站做多长时间才会成功域名购买平台
  • 什么网站可以找试卷做百度指数批量
  • 给人做阉割手术的网站营销运营主要做什么
  • VPS如何做镜像网站如何做好线上推广和引流
  • 合肥网站开发公司电话重庆放心seo整站优化
  • jsp做的网站效果怎么搭建属于自己的网站
  • app大全软件下载苏州seo网站推广哪家好
  • 南宁做网站的有几家独立网站和平台网站
  • 武汉网站建设公司 排名百度应用市场app下载安装
  • 域名停靠盘他app网站网络营销就是seo正确吗
  • 手机网站模版南京seo整站优化技术
  • 可信网站认证 技术支持单位网络营销策划的概念
  • 为公司做网站广州网站推广软件
  • 上海网站制作价格最近一周的新闻大事10条
  • 方维网站建设营销型网站建设专家
  • 网站制作企业有哪些公司2345浏览器
  • 明星个人flash网站源码百度大全下载
  • 长春网站建设开发的有哪些地推拉新app推广怎么做
  • 什么网站可以做字体效果软文媒体发稿平台
  • 课题组网站怎么做外贸推广平台怎么做
  • 网站如何做微信支付链接小程序推广50个方法
  • 中国建设报官方网站哪里可以代写软文
  • 青岛做模板网站的公司品牌广告
  • 东营网站建设优化佛山做网站推广的公司
  • 开个做网站的公司怎样有效的做网上宣传
  • 建设官方网站查询推广赚钱app