referencias añadidas reparada forma de topologia

This commit is contained in:
Abraham
2025-07-30 22:29:28 -07:00
parent 730754930d
commit 8bbe7a53ff
16 changed files with 1959 additions and 4188 deletions

View File

@@ -0,0 +1,58 @@
class RolLogicoComponente {
final int id;
final String nombre;
final String? descripcion;
RolLogicoComponente({
required this.id,
required this.nombre,
this.descripcion,
});
factory RolLogicoComponente.fromMap(Map<String, dynamic> map) {
return RolLogicoComponente(
id: map['id'] ?? 0,
nombre: map['nombre'] ?? '',
descripcion: map['descripcion'],
);
}
Map<String, dynamic> toMap() {
return {
'id': id,
'nombre': nombre,
'descripcion': descripcion,
};
}
RolLogicoComponente copyWith({
int? id,
String? nombre,
String? descripcion,
}) {
return RolLogicoComponente(
id: id ?? this.id,
nombre: nombre ?? this.nombre,
descripcion: descripcion ?? this.descripcion,
);
}
@override
String toString() {
return 'RolLogicoComponente(id: $id, nombre: $nombre, descripcion: $descripcion)';
}
@override
bool operator ==(Object other) {
if (identical(this, other)) return true;
return other is RolLogicoComponente &&
other.id == id &&
other.nombre == nombre &&
other.descripcion == descripcion;
}
@override
int get hashCode {
return id.hashCode ^ nombre.hashCode ^ descripcion.hashCode;
}
}