merge static method
Creates a Border that represents the addition of the two given Borders.
It is only valid to call this if BorderSide.canMerge returns true for the pairwise combination of each side on both Borders.
Implementation
static Border merge(Border a, Border b) {
assert(BorderSide.canMerge(a.top, b.top));
assert(BorderSide.canMerge(a.right, b.right));
assert(BorderSide.canMerge(a.bottom, b.bottom));
assert(BorderSide.canMerge(a.left, b.left));
return Border(
top: BorderSide.merge(a.top, b.top),
right: BorderSide.merge(a.right, b.right),
bottom: BorderSide.merge(a.bottom, b.bottom),
left: BorderSide.merge(a.left, b.left),
);
}