blockly > FieldImage > doClassValidation_
FieldImage.doClassValidation_() method
Ensure that the input value (the source URL) is a string.
Signature:
protected doClassValidation_(newValue?: any): string | null;
Parameters
Parameter |
Type |
Description |
newValue |
any |
(Optional) The input value. |
Returns:
string | null
A string, or null if invalid.
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-09-18 UTC.
[null,null,["Last updated 2024-09-18 UTC."],[[["`FieldImage.doClassValidation_` is a protected method used to validate the source URL provided to a FieldImage block."],["This method ensures the input value is a string and returns the validated URL or null if invalid."],["Developers working with custom Blockly blocks can leverage this method to ensure data integrity for image fields."]]],[]]