Assigning a Null Value
The value of single value Data Fields and Business Objects’ attributes and compositions can be cleared by assigning them the special value, null.
The following diagram and script illustrate this:
// Clear car’s model value (attribute) data.myCar.model = null; // Remove car’s roof value (composition) data.myCar.roof = null; // Clear myCar Data Field (Business Object) data.myCar = null; // Clear myNumber Data Field (Number) myNumber = null; |
For Data Fields or Business Object attributes and compositions that have a multiplicity greater than one, the assignment of null is not possible. Instead, values can be removed using the appropriate Array methods. For example, setting the Array length to 0, for the removal of all values. In the above example, this applies to Car’s wheels composition and the myDates data field.
Copyright © 2021. Cloud Software Group, Inc. All Rights Reserved.