copyWith method
ARLight
copyWith({
- String? id,
- ARLightType? type,
- Vector3? position,
- Quaternion? rotation,
- Vector3? direction,
- double? intensity,
- LightIntensityUnit? intensityUnit,
- Vector3? color,
- double? range,
- double? innerConeAngle,
- double? outerConeAngle,
- bool? isEnabled,
- bool? castShadows,
- ShadowQuality? shadowQuality,
- ShadowFilterMode? shadowFilterMode,
- double? shadowBias,
- double? shadowNormalBias,
- double? shadowNearPlane,
- double? shadowFarPlane,
- DateTime? createdAt,
- DateTime? lastModified,
- Map<
String, dynamic> ? metadata,
Create a copy with modified properties
Implementation
ARLight copyWith({
String? id,
ARLightType? type,
Vector3? position,
Quaternion? rotation,
Vector3? direction,
double? intensity,
LightIntensityUnit? intensityUnit,
Vector3? color,
double? range,
double? innerConeAngle,
double? outerConeAngle,
bool? isEnabled,
bool? castShadows,
ShadowQuality? shadowQuality,
ShadowFilterMode? shadowFilterMode,
double? shadowBias,
double? shadowNormalBias,
double? shadowNearPlane,
double? shadowFarPlane,
DateTime? createdAt,
DateTime? lastModified,
Map<String, dynamic>? metadata,
}) {
return ARLight(
id: id ?? this.id,
type: type ?? this.type,
position: position ?? this.position,
rotation: rotation ?? this.rotation,
direction: direction ?? this.direction,
intensity: intensity ?? this.intensity,
intensityUnit: intensityUnit ?? this.intensityUnit,
color: color ?? this.color,
range: range ?? this.range,
innerConeAngle: innerConeAngle ?? this.innerConeAngle,
outerConeAngle: outerConeAngle ?? this.outerConeAngle,
isEnabled: isEnabled ?? this.isEnabled,
castShadows: castShadows ?? this.castShadows,
shadowQuality: shadowQuality ?? this.shadowQuality,
shadowFilterMode: shadowFilterMode ?? this.shadowFilterMode,
shadowBias: shadowBias ?? this.shadowBias,
shadowNormalBias: shadowNormalBias ?? this.shadowNormalBias,
shadowNearPlane: shadowNearPlane ?? this.shadowNearPlane,
shadowFarPlane: shadowFarPlane ?? this.shadowFarPlane,
createdAt: createdAt ?? this.createdAt,
lastModified: lastModified ?? this.lastModified,
metadata: metadata ?? this.metadata,
);
}