首页
学习
活动
专区
工具
TVP
发布
精选内容/技术社群/优惠产品,尽在小程序
立即前往

std::money_base

Defined in header <locale>

?

?

class money_base;

?

?

全班std::money_base提供继承和使用的常量。std::moneypunct,,,std::money_getstd::money_put面。

成员类型

Member type

Definition

enum part { none, space, symbol, sign, value };

unscoped enumeration type

struct pattern { char field4; };

the monetary format type

Enumeration constant

Definition

none

whitespace is permitted but not required except in the last position, where whitespace is not permitted

space

one or more whitespace characters are required

symbol

the sequence of characters returned by moneypunct::curr_symbol is required

sign

the first of the characters returned by moneypunct::positive_sign or moneypunct::negative_sign is required

value

the absolute numeric monetary value is required

注记

货币格式是由四个人组成的数组。charS可转换为std::money_base::part.在这个序列中,每一个symbol,,,sign,和value只出现一次spacenone出现在其余位置。价值none,如果是存在的,则不是第一位的;space如果存在,既不是第一,也不是最后。

的标准专门化返回的默认格式。std::moneypunct{symbol, sign, none, value}

另见

moneypunct

defines monetary formatting parameters used by std::money_get and std::money_put (class template)

money_get

parses and constructs a monetary value from an input character sequence (class template)

money_put

formats a monetary value for output as a character sequence (class template)

代码语言:txt
复制
 ? cppreference.com

在CreativeCommonsAttribution下授权-ShareAlike未移植许可v3.0。

扫码关注腾讯云开发者

领取腾讯云代金券

http://www.vxiaotou.com