(valueSets, options)
| 2256 | } |
| 2257 | |
| 2258 | static bulkBuild(valueSets, options) { |
| 2259 | options = { isNewRecord: true, ...options }; |
| 2260 | |
| 2261 | if (!options.includeValidated) { |
| 2262 | this._conformIncludes(options, this); |
| 2263 | if (options.include) { |
| 2264 | this._expandIncludeAll(options); |
| 2265 | this._validateIncludedElements(options); |
| 2266 | } |
| 2267 | } |
| 2268 | |
| 2269 | if (options.attributes) { |
| 2270 | options.attributes = options.attributes.map(attribute => Array.isArray(attribute) ? attribute[1] : attribute); |
| 2271 | } |
| 2272 | |
| 2273 | return valueSets.map(values => this.build(values, options)); |
| 2274 | } |
| 2275 | |
| 2276 | /** |
| 2277 | * Builds a new model instance and calls save on it. |
no test coverage detected