NumberFormat.ParseStrict Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
<strong>[icu]</strong> Returns whether strict parsing is in effect. -or- <strong>[icu]</strong> Sets whether strict parsing is in effect.
public virtual bool ParseStrict { [Android.Runtime.Register("isParseStrict", "()Z", "GetIsParseStrictHandler", ApiSince=24)] get; [Android.Runtime.Register("setParseStrict", "(Z)V", "GetSetParseStrict_ZHandler", ApiSince=24)] set; }
[<get: Android.Runtime.Register("isParseStrict", "()Z", "GetIsParseStrictHandler", ApiSince=24)>]
[<set: Android.Runtime.Register("setParseStrict", "(Z)V", "GetSetParseStrict_ZHandler", ApiSince=24)>]
member this.ParseStrict : bool with get, set
Property Value
true if strict parsing is in effect
- Attributes
Remarks
Property getter documentation:
<strong>[icu]</strong> Returns whether strict parsing is in effect.
Java documentation for android.icu.text.NumberFormat.isParseStrict()
.
Property setter documentation:
<strong>[icu]</strong> Sets whether strict parsing is in effect. When this is true, the string is required to be a stronger match to the pattern than when lenient parsing is in effect. More specifically, the following conditions cause a parse failure relative to lenient mode (examples use the pattern "#,##0.#"):<ul> <li>The presence and position of special symbols, including currency, must match the pattern.<br> '+123' fails (there is no plus sign in the pattern)</li> <li>Leading or doubled grouping separators<br> ',123' and '1,,234" fail</li> <li>Groups of incorrect length when grouping is used<br> '1,23' and '1234,567' fail, but '1234' passes</li> <li>Grouping separators used in numbers followed by exponents<br> '1,234E5' fails, but '1234E5' and '1,234E' pass ('E' is not an exponent when not followed by a number)</li> </ul> When strict parsing is off, all grouping separators are ignored. This is the default behavior.
Java documentation for android.icu.text.NumberFormat.setParseStrict(boolean)
.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.